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QZ,GACd0C,EAAO1C,GAASU,iBAAiBwC,IAAItC,GACrC8B,EAAO1C,GAASS,eAAee,OAAOZ,GACtC+B,EAAsB3C,EAC1B,EACH,C","sources":["../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/StyleOptionsState.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/Stylesheet.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/getVendorSettings.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/transforms/kebabRules.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/transforms/prefixRules.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/transforms/provideUnits.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/transforms/rtlifyRules.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/styleToClassName.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/tokenizeWithParentheses.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/mergeStyles.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.2.1/node_modules/@fluentui/merge-styles/lib/extractStyleParts.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/StyleOptionsState.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/Stylesheet.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/concatStyleSets.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/concatStyleSetsWithProps.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/extractStyleParts.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/fontFace.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/keyframes.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/mergeStyleSets.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/mergeStyles.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/shadowConfig.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/getVendorSettings.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/transforms/kebabRules.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/transforms/prefixRules.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/transforms/provideUnits.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/transforms/rtlifyRules.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/styleToClassName.js","../../../../node_modules/.pnpm/@fluentui+merge-styles@8.6.13/node_modules/@fluentui/merge-styles/lib/tokenizeWithParentheses.js","../../../../node_modules/.pnpm/@fluentui+priority-overflow@9.1.11/node_modules/@fluentui/priority-overflow/lib/consts.js","../../../../node_modules/.pnpm/@fluentui+priority-overflow@9.1.11/node_modules/@fluentui/priority-overflow/lib/priorityQueue.js","../../../../node_modules/.pnpm/@fluentui+priority-overflow@9.1.11/node_modules/@fluentui/priority-overflow/lib/overflowManager.js","../../../../node_modules/.pnpm/@fluentui+priority-overflow@9.1.11/node_modules/@fluentui/priority-overflow/lib/debounce.js","../../../../node_modules/.pnpm/@fluentui+priority-overflow@9.1.11/node_modules/@fluentui/priority-overflow/lib/createResizeObserver.js"],"sourcesContent":["/**\n * Sets the current RTL value.\n */\nexport function setRTL(isRTL) {\n    if (_rtl !== isRTL) {\n        _rtl = isRTL;\n    }\n}\n/**\n * Gets the current RTL value.\n */\nexport function getRTL() {\n    if (_rtl === undefined) {\n        _rtl =\n            typeof document !== 'undefined' &&\n                !!document.documentElement &&\n                document.documentElement.getAttribute('dir') === 'rtl';\n    }\n    return _rtl;\n}\n// This has been split into 2 lines because it was working in Fabric due to the code being transpiled to es5, so this\n// was converted to var while not working in Fluent that uses babel to transpile the code to be es6-like. Splitting the\n// logic into two lines, however, allows it to work in both scenarios.\nvar _rtl;\n_rtl = getRTL();\nexport function getStyleOptions() {\n    return {\n        rtl: getRTL(),\n    };\n}\n//# sourceMappingURL=StyleOptionsState.js.map","import { __assign } from \"tslib\";\nexport var InjectionMode = {\n    /**\n     * Avoids style injection, use getRules() to read the styles.\n     */\n    none: 0,\n    /**\n     * Inserts rules using the insertRule api.\n     */\n    insertNode: 1,\n    /**\n     * Appends rules using appendChild.\n     */\n    appendChild: 2,\n};\nvar STYLESHEET_SETTING = '__stylesheet__';\n/**\n * MSIE 11 doesn't cascade styles based on DOM ordering, but rather on the order that each style node\n * is created. As such, to maintain consistent priority, IE11 should reuse a single style node.\n */\nvar REUSE_STYLE_NODE = typeof navigator !== 'undefined' && /rv:11.0/.test(navigator.userAgent);\nvar _global = {};\n// Grab window.\ntry {\n    _global = window || {};\n}\ncatch (_a) {\n    /* leave as blank object */\n}\nvar _stylesheet;\n/**\n * Represents the state of styles registered in the page. Abstracts\n * the surface for adding styles to the stylesheet, exposes helpers\n * for reading the styles registered in server rendered scenarios.\n *\n * @public\n */\nvar Stylesheet = /** @class */ (function () {\n    function Stylesheet(config, serializedStylesheet) {\n        var _a, _b, _c, _d, _e, _f;\n        this._rules = [];\n        this._preservedRules = [];\n        this._counter = 0;\n        this._keyToClassName = {};\n        this._onInsertRuleCallbacks = [];\n        this._onResetCallbacks = [];\n        this._classNameToArgs = {};\n        this._config = __assign({ \n            // If there is no document we won't have an element to inject into.\n            injectionMode: typeof document === 'undefined' ? InjectionMode.none : InjectionMode.insertNode, defaultPrefix: 'css', namespace: undefined, cspSettings: undefined }, config);\n        this._classNameToArgs = (_a = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.classNameToArgs) !== null && _a !== void 0 ? _a : this._classNameToArgs;\n        this._counter = (_b = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.counter) !== null && _b !== void 0 ? _b : this._counter;\n        this._keyToClassName = (_d = (_c = this._config.classNameCache) !== null && _c !== void 0 ? _c : serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.keyToClassName) !== null && _d !== void 0 ? _d : this._keyToClassName;\n        this._preservedRules = (_e = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.preservedRules) !== null && _e !== void 0 ? _e : this._preservedRules;\n        this._rules = (_f = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.rules) !== null && _f !== void 0 ? _f : this._rules;\n    }\n    /**\n     * Gets the singleton instance.\n     */\n    Stylesheet.getInstance = function () {\n        _stylesheet = _global[STYLESHEET_SETTING];\n        if (!_stylesheet || (_stylesheet._lastStyleElement && _stylesheet._lastStyleElement.ownerDocument !== document)) {\n            var fabricConfig = (_global === null || _global === void 0 ? void 0 : _global.FabricConfig) || {};\n            var stylesheet = new Stylesheet(fabricConfig.mergeStyles, fabricConfig.serializedStylesheet);\n            _stylesheet = stylesheet;\n            _global[STYLESHEET_SETTING] = stylesheet;\n        }\n        return _stylesheet;\n    };\n    /**\n     * Serializes the Stylesheet instance into a format which allows rehydration on creation.\n     * @returns string representation of `ISerializedStylesheet` interface.\n     */\n    Stylesheet.prototype.serialize = function () {\n        return JSON.stringify({\n            classNameToArgs: this._classNameToArgs,\n            counter: this._counter,\n            keyToClassName: this._keyToClassName,\n            preservedRules: this._preservedRules,\n            rules: this._rules,\n        });\n    };\n    /**\n     * Configures the stylesheet.\n     */\n    Stylesheet.prototype.setConfig = function (config) {\n        this._config = __assign(__assign({}, this._config), config);\n    };\n    /**\n     * Configures a reset callback.\n     *\n     * @param callback - A callback which will be called when the Stylesheet is reset.\n     * @returns function which when called un-registers provided callback.\n     */\n    Stylesheet.prototype.onReset = function (callback) {\n        var _this = this;\n        this._onResetCallbacks.push(callback);\n        return function () {\n            _this._onResetCallbacks = _this._onResetCallbacks.filter(function (cb) { return cb !== callback; });\n        };\n    };\n    /**\n     * Configures an insert rule callback.\n     *\n     * @param callback - A callback which will be called when a rule is inserted.\n     * @returns function which when called un-registers provided callback.\n     */\n    Stylesheet.prototype.onInsertRule = function (callback) {\n        var _this = this;\n        this._onInsertRuleCallbacks.push(callback);\n        return function () {\n            _this._onInsertRuleCallbacks = _this._onInsertRuleCallbacks.filter(function (cb) { return cb !== callback; });\n        };\n    };\n    /**\n     * Generates a unique classname.\n     *\n     * @param displayName - Optional value to use as a prefix.\n     */\n    Stylesheet.prototype.getClassName = function (displayName) {\n        var namespace = this._config.namespace;\n        var prefix = displayName || this._config.defaultPrefix;\n        return \"\" + (namespace ? namespace + '-' : '') + prefix + \"-\" + this._counter++;\n    };\n    /**\n     * Used internally to cache information about a class which was\n     * registered with the stylesheet.\n     */\n    Stylesheet.prototype.cacheClassName = function (className, key, args, rules) {\n        this._keyToClassName[key] = className;\n        this._classNameToArgs[className] = {\n            args: args,\n            rules: rules,\n        };\n    };\n    /**\n     * Gets the appropriate classname given a key which was previously\n     * registered using cacheClassName.\n     */\n    Stylesheet.prototype.classNameFromKey = function (key) {\n        return this._keyToClassName[key];\n    };\n    /**\n     * Gets all classnames cache with the stylesheet.\n     */\n    Stylesheet.prototype.getClassNameCache = function () {\n        return this._keyToClassName;\n    };\n    /**\n     * Gets the arguments associated with a given classname which was\n     * previously registered using cacheClassName.\n     */\n    Stylesheet.prototype.argsFromClassName = function (className) {\n        var entry = this._classNameToArgs[className];\n        return entry && entry.args;\n    };\n    /**\n     * Gets the rules associated with a given classname which was\n     * previously registered using cacheClassName.\n     */\n    Stylesheet.prototype.insertedRulesFromClassName = function (className) {\n        var entry = this._classNameToArgs[className];\n        return entry && entry.rules;\n    };\n    /**\n     * Inserts a css rule into the stylesheet.\n     * @param preserve - Preserves the rule beyond a reset boundary.\n     */\n    Stylesheet.prototype.insertRule = function (rule, preserve) {\n        var injectionMode = this._config.injectionMode;\n        var element = injectionMode !== InjectionMode.none ? this._getStyleElement() : undefined;\n        if (preserve) {\n            this._preservedRules.push(rule);\n        }\n        if (element) {\n            switch (injectionMode) {\n                case InjectionMode.insertNode:\n                    var sheet = element.sheet;\n                    try {\n                        sheet.insertRule(rule, sheet.cssRules.length);\n                    }\n                    catch (e) {\n                        // The browser will throw exceptions on unsupported rules (such as a moz prefix in webkit.)\n                        // We need to swallow the exceptions for this scenario, otherwise we'd need to filter\n                        // which could be slower and bulkier.\n                    }\n                    break;\n                case InjectionMode.appendChild:\n                    element.appendChild(document.createTextNode(rule));\n                    break;\n            }\n        }\n        else {\n            this._rules.push(rule);\n        }\n        // eslint-disable-next-line deprecation/deprecation\n        if (this._config.onInsertRule) {\n            // eslint-disable-next-line deprecation/deprecation\n            this._config.onInsertRule(rule);\n        }\n        this._onInsertRuleCallbacks.forEach(function (callback) { return callback(); });\n    };\n    /**\n     * Gets all rules registered with the stylesheet; only valid when\n     * using InsertionMode.none.\n     */\n    Stylesheet.prototype.getRules = function (includePreservedRules) {\n        return (includePreservedRules ? this._preservedRules.join('') : '') + this._rules.join('');\n    };\n    /**\n     * Resets the internal state of the stylesheet. Only used in server\n     * rendered scenarios where we're using InsertionMode.none.\n     */\n    Stylesheet.prototype.reset = function () {\n        this._rules = [];\n        this._counter = 0;\n        this._classNameToArgs = {};\n        this._keyToClassName = {};\n        this._onResetCallbacks.forEach(function (callback) { return callback(); });\n    };\n    // Forces the regeneration of incoming styles without totally resetting the stylesheet.\n    Stylesheet.prototype.resetKeys = function () {\n        this._keyToClassName = {};\n    };\n    Stylesheet.prototype._getStyleElement = function () {\n        var _this = this;\n        if (!this._styleElement && typeof document !== 'undefined') {\n            this._styleElement = this._createStyleElement();\n            if (!REUSE_STYLE_NODE) {\n                // Reset the style element on the next frame.\n                window.requestAnimationFrame(function () {\n                    _this._styleElement = undefined;\n                });\n            }\n        }\n        return this._styleElement;\n    };\n    Stylesheet.prototype._createStyleElement = function () {\n        var head = document.head;\n        var styleElement = document.createElement('style');\n        var nodeToInsertBefore = null;\n        styleElement.setAttribute('data-merge-styles', 'true');\n        var cspSettings = this._config.cspSettings;\n        if (cspSettings) {\n            if (cspSettings.nonce) {\n                styleElement.setAttribute('nonce', cspSettings.nonce);\n            }\n        }\n        if (this._lastStyleElement) {\n            // If the `nextElementSibling` is null, then the insertBefore will act as a regular append.\n            // https://developer.mozilla.org/en-US/docs/Web/API/Node/insertBefore#Syntax\n            nodeToInsertBefore = this._lastStyleElement.nextElementSibling;\n        }\n        else {\n            var placeholderStyleTag = this._findPlaceholderStyleTag();\n            if (placeholderStyleTag) {\n                nodeToInsertBefore = placeholderStyleTag.nextElementSibling;\n            }\n            else {\n                nodeToInsertBefore = head.childNodes[0];\n            }\n        }\n        head.insertBefore(styleElement, head.contains(nodeToInsertBefore) ? nodeToInsertBefore : null);\n        this._lastStyleElement = styleElement;\n        return styleElement;\n    };\n    Stylesheet.prototype._findPlaceholderStyleTag = function () {\n        var head = document.head;\n        if (head) {\n            return head.querySelector('style[data-merge-styles]');\n        }\n        return null;\n    };\n    return Stylesheet;\n}());\nexport { Stylesheet };\n//# sourceMappingURL=Stylesheet.js.map","var _vendorSettings;\nexport function getVendorSettings() {\n    var _a;\n    if (!_vendorSettings) {\n        var doc = typeof document !== 'undefined' ? document : undefined;\n        var nav = typeof navigator !== 'undefined' ? navigator : undefined;\n        var userAgent = (_a = nav === null || nav === void 0 ? void 0 : nav.userAgent) === null || _a === void 0 ? void 0 : _a.toLowerCase();\n        if (!doc) {\n            _vendorSettings = {\n                isWebkit: true,\n                isMoz: true,\n                isOpera: true,\n                isMs: true,\n            };\n        }\n        else {\n            _vendorSettings = {\n                isWebkit: !!(doc && 'WebkitAppearance' in doc.documentElement.style),\n                isMoz: !!(userAgent && userAgent.indexOf('firefox') > -1),\n                isOpera: !!(userAgent && userAgent.indexOf('opera') > -1),\n                isMs: !!(nav && (/rv:11.0/i.test(nav.userAgent) || /Edge\\/\\d./i.test(navigator.userAgent))),\n            };\n        }\n    }\n    return _vendorSettings;\n}\n/**\n * Sets the vendor settings for prefixing and vendor specific operations.\n */\nexport function setVendorSettings(vendorSettings) {\n    _vendorSettings = vendorSettings;\n}\n//# sourceMappingURL=getVendorSettings.js.map","var rules = {};\nexport function kebabRules(rulePairs, index) {\n    var rule = rulePairs[index];\n    if (rule.charAt(0) !== '-') {\n        rulePairs[index] = rules[rule] = rules[rule] || rule.replace(/([A-Z])/g, '-$1').toLowerCase();\n    }\n}\n//# sourceMappingURL=kebabRules.js.map","import { getVendorSettings } from '../getVendorSettings';\nvar autoPrefixNames = {\n    'user-select': 1,\n};\nexport function prefixRules(rulePairs, index) {\n    var vendorSettings = getVendorSettings();\n    var name = rulePairs[index];\n    if (autoPrefixNames[name]) {\n        var value = rulePairs[index + 1];\n        if (autoPrefixNames[name]) {\n            if (vendorSettings.isWebkit) {\n                rulePairs.push('-webkit-' + name, value);\n            }\n            if (vendorSettings.isMoz) {\n                rulePairs.push('-moz-' + name, value);\n            }\n            if (vendorSettings.isMs) {\n                rulePairs.push('-ms-' + name, value);\n            }\n            if (vendorSettings.isOpera) {\n                rulePairs.push('-o-' + name, value);\n            }\n        }\n    }\n}\n//# sourceMappingURL=prefixRules.js.map","var NON_PIXEL_NUMBER_PROPS = [\n    'column-count',\n    'font-weight',\n    'flex',\n    'flex-grow',\n    'flex-shrink',\n    'fill-opacity',\n    'opacity',\n    'order',\n    'z-index',\n    'zoom',\n];\nexport function provideUnits(rulePairs, index) {\n    var name = rulePairs[index];\n    var value = rulePairs[index + 1];\n    if (typeof value === 'number') {\n        var isNonPixelProp = NON_PIXEL_NUMBER_PROPS.indexOf(name) > -1;\n        var isVariableOrPrefixed = name.indexOf('--') > -1;\n        var unit = isNonPixelProp || isVariableOrPrefixed ? '' : 'px';\n        rulePairs[index + 1] = \"\" + value + unit;\n    }\n}\n//# sourceMappingURL=provideUnits.js.map","var _a;\nvar LEFT = 'left';\nvar RIGHT = 'right';\nvar NO_FLIP = '@noflip';\nvar NAME_REPLACEMENTS = (_a = {},\n    _a[LEFT] = RIGHT,\n    _a[RIGHT] = LEFT,\n    _a);\nvar VALUE_REPLACEMENTS = {\n    'w-resize': 'e-resize',\n    'sw-resize': 'se-resize',\n    'nw-resize': 'ne-resize',\n};\n/**\n * RTLifies the rulePair in the array at the current index. This mutates the array for performance\n * reasons.\n */\nexport function rtlifyRules(options, rulePairs, index) {\n    if (options.rtl) {\n        var name_1 = rulePairs[index];\n        if (!name_1) {\n            return;\n        }\n        var value = rulePairs[index + 1];\n        if (typeof value === 'string' && value.indexOf(NO_FLIP) >= 0) {\n            rulePairs[index + 1] = value.replace(/\\s*(?:\\/\\*\\s*)?\\@noflip\\b(?:\\s*\\*\\/)?\\s*?/g, '');\n        }\n        else if (name_1.indexOf(LEFT) >= 0) {\n            rulePairs[index] = name_1.replace(LEFT, RIGHT);\n        }\n        else if (name_1.indexOf(RIGHT) >= 0) {\n            rulePairs[index] = name_1.replace(RIGHT, LEFT);\n        }\n        else if (String(value).indexOf(LEFT) >= 0) {\n            rulePairs[index + 1] = value.replace(LEFT, RIGHT);\n        }\n        else if (String(value).indexOf(RIGHT) >= 0) {\n            rulePairs[index + 1] = value.replace(RIGHT, LEFT);\n        }\n        else if (NAME_REPLACEMENTS[name_1]) {\n            rulePairs[index] = NAME_REPLACEMENTS[name_1];\n        }\n        else if (VALUE_REPLACEMENTS[value]) {\n            rulePairs[index + 1] = VALUE_REPLACEMENTS[value];\n        }\n        else {\n            switch (name_1) {\n                case 'margin':\n                case 'padding':\n                    rulePairs[index + 1] = flipQuad(value);\n                    break;\n                case 'box-shadow':\n                    rulePairs[index + 1] = negateNum(value, 0);\n                    break;\n            }\n        }\n    }\n}\n/**\n * Given a string value in a space delimited format (e.g. \"1 2 3 4\"), negates a particular value.\n */\nfunction negateNum(value, partIndex) {\n    var parts = value.split(' ');\n    var numberVal = parseInt(parts[partIndex], 10);\n    parts[0] = parts[0].replace(String(numberVal), String(numberVal * -1));\n    return parts.join(' ');\n}\n/**\n * Given a string quad, flips the left and right values.\n */\nfunction flipQuad(value) {\n    if (typeof value === 'string') {\n        var parts = value.split(' ');\n        if (parts.length === 4) {\n            return parts[0] + \" \" + parts[3] + \" \" + parts[2] + \" \" + parts[1];\n        }\n    }\n    return value;\n}\n//# sourceMappingURL=rtlifyRules.js.map","import { __spreadArrays } from \"tslib\";\nimport { Stylesheet } from './Stylesheet';\nimport { kebabRules } from './transforms/kebabRules';\nimport { prefixRules } from './transforms/prefixRules';\nimport { provideUnits } from './transforms/provideUnits';\nimport { rtlifyRules } from './transforms/rtlifyRules';\nimport { tokenizeWithParentheses } from './tokenizeWithParentheses';\nvar DISPLAY_NAME = 'displayName';\nfunction getDisplayName(rules) {\n    var rootStyle = rules && rules['&'];\n    return rootStyle ? rootStyle.displayName : undefined;\n}\nvar globalSelectorRegExp = /\\:global\\((.+?)\\)/g;\n/**\n * Finds comma separated selectors in a :global() e.g. \":global(.class1, .class2, .class3)\"\n * and wraps them each in their own global \":global(.class1), :global(.class2), :global(.class3)\"\n *\n * @param selectorWithGlobals The selector to process\n * @returns The updated selector\n */\nfunction expandCommaSeparatedGlobals(selectorWithGlobals) {\n    // We the selector does not have a :global() we can shortcut\n    if (!globalSelectorRegExp.test(selectorWithGlobals)) {\n        return selectorWithGlobals;\n    }\n    var replacementInfo = [];\n    var findGlobal = /\\:global\\((.+?)\\)/g;\n    var match = null;\n    // Create a result list for global selectors so we can replace them.\n    while ((match = findGlobal.exec(selectorWithGlobals))) {\n        // Only if the found selector is a comma separated list we'll process it.\n        if (match[1].indexOf(',') > -1) {\n            replacementInfo.push([\n                match.index,\n                match.index + match[0].length,\n                // Wrap each of the found selectors in :global()\n                match[1]\n                    .split(',')\n                    .map(function (v) { return \":global(\" + v.trim() + \")\"; })\n                    .join(', '),\n            ]);\n        }\n    }\n    // Replace the found selectors with their wrapped variants in reverse order\n    return replacementInfo\n        .reverse()\n        .reduce(function (selector, _a) {\n        var matchIndex = _a[0], matchEndIndex = _a[1], replacement = _a[2];\n        var prefix = selector.slice(0, matchIndex);\n        var suffix = selector.slice(matchEndIndex);\n        return prefix + replacement + suffix;\n    }, selectorWithGlobals);\n}\nfunction expandSelector(newSelector, currentSelector) {\n    if (newSelector.indexOf(':global(') >= 0) {\n        return newSelector.replace(globalSelectorRegExp, '$1');\n    }\n    else if (newSelector.indexOf(':') === 0) {\n        return currentSelector + newSelector;\n    }\n    else if (newSelector.indexOf('&') < 0) {\n        return currentSelector + ' ' + newSelector;\n    }\n    return newSelector;\n}\nfunction extractSelector(currentSelector, rules, selector, value) {\n    if (rules === void 0) { rules = { __order: [] }; }\n    if (selector.indexOf('@') === 0) {\n        selector = selector + '{' + currentSelector;\n        extractRules([value], rules, selector);\n    }\n    else if (selector.indexOf(',') > -1) {\n        expandCommaSeparatedGlobals(selector)\n            .split(',')\n            .map(function (s) { return s.trim(); })\n            .forEach(function (separatedSelector) {\n            return extractRules([value], rules, expandSelector(separatedSelector, currentSelector));\n        });\n    }\n    else {\n        extractRules([value], rules, expandSelector(selector, currentSelector));\n    }\n}\nfunction extractRules(args, rules, currentSelector) {\n    if (rules === void 0) { rules = { __order: [] }; }\n    if (currentSelector === void 0) { currentSelector = '&'; }\n    var stylesheet = Stylesheet.getInstance();\n    var currentRules = rules[currentSelector];\n    if (!currentRules) {\n        currentRules = {};\n        rules[currentSelector] = currentRules;\n        rules.__order.push(currentSelector);\n    }\n    for (var _i = 0, args_1 = args; _i < args_1.length; _i++) {\n        var arg = args_1[_i];\n        // If the arg is a string, we need to look up the class map and merge.\n        if (typeof arg === 'string') {\n            var expandedRules = stylesheet.argsFromClassName(arg);\n            if (expandedRules) {\n                extractRules(expandedRules, rules, currentSelector);\n            }\n            // Else if the arg is an array, we need to recurse in.\n        }\n        else if (Array.isArray(arg)) {\n            extractRules(arg, rules, currentSelector);\n        }\n        else {\n            for (var prop in arg) {\n                if (arg.hasOwnProperty(prop)) {\n                    var propValue = arg[prop];\n                    if (prop === 'selectors') {\n                        // every child is a selector.\n                        var selectors = arg.selectors;\n                        for (var newSelector in selectors) {\n                            if (selectors.hasOwnProperty(newSelector)) {\n                                extractSelector(currentSelector, rules, newSelector, selectors[newSelector]);\n                            }\n                        }\n                    }\n                    else if (typeof propValue === 'object') {\n                        // prop is a selector.\n                        if (propValue !== null) {\n                            extractSelector(currentSelector, rules, prop, propValue);\n                        }\n                    }\n                    else {\n                        if (propValue !== undefined) {\n                            // Else, add the rule to the currentSelector.\n                            if (prop === 'margin' || prop === 'padding') {\n                                expandQuads(currentRules, prop, propValue);\n                            }\n                            else {\n                                currentRules[prop] = propValue;\n                            }\n                        }\n                    }\n                }\n            }\n        }\n    }\n    return rules;\n}\nfunction expandQuads(currentRules, name, value) {\n    var parts = typeof value === 'string' ? tokenizeWithParentheses(value) : [value];\n    if (parts.length === 0) {\n        parts.push(value);\n    }\n    if (parts[parts.length - 1] === '!important') {\n        // Remove !important from parts, and append it to each part individually\n        parts = parts.slice(0, -1).map(function (p) { return p + ' !important'; });\n    }\n    currentRules[name + 'Top'] = parts[0];\n    currentRules[name + 'Right'] = parts[1] || parts[0];\n    currentRules[name + 'Bottom'] = parts[2] || parts[0];\n    currentRules[name + 'Left'] = parts[3] || parts[1] || parts[0];\n}\nfunction getKeyForRules(options, rules) {\n    var serialized = [options.rtl ? 'rtl' : 'ltr'];\n    var hasProps = false;\n    for (var _i = 0, _a = rules.__order; _i < _a.length; _i++) {\n        var selector = _a[_i];\n        serialized.push(selector);\n        var rulesForSelector = rules[selector];\n        for (var propName in rulesForSelector) {\n            if (rulesForSelector.hasOwnProperty(propName) && rulesForSelector[propName] !== undefined) {\n                hasProps = true;\n                serialized.push(propName, rulesForSelector[propName]);\n            }\n        }\n    }\n    return hasProps ? serialized.join('') : undefined;\n}\nfunction repeatString(target, count) {\n    if (count <= 0) {\n        return '';\n    }\n    if (count === 1) {\n        return target;\n    }\n    return target + repeatString(target, count - 1);\n}\nexport function serializeRuleEntries(options, ruleEntries) {\n    if (!ruleEntries) {\n        return '';\n    }\n    var allEntries = [];\n    for (var entry in ruleEntries) {\n        if (ruleEntries.hasOwnProperty(entry) && entry !== DISPLAY_NAME && ruleEntries[entry] !== undefined) {\n            allEntries.push(entry, ruleEntries[entry]);\n        }\n    }\n    // Apply transforms.\n    for (var i = 0; i < allEntries.length; i += 2) {\n        kebabRules(allEntries, i);\n        provideUnits(allEntries, i);\n        rtlifyRules(options, allEntries, i);\n        prefixRules(allEntries, i);\n    }\n    // Apply punctuation.\n    for (var i = 1; i < allEntries.length; i += 4) {\n        allEntries.splice(i, 1, ':', allEntries[i], ';');\n    }\n    return allEntries.join('');\n}\nexport function styleToRegistration(options) {\n    var args = [];\n    for (var _i = 1; _i < arguments.length; _i++) {\n        args[_i - 1] = arguments[_i];\n    }\n    var rules = extractRules(args);\n    var key = getKeyForRules(options, rules);\n    if (key) {\n        var stylesheet = Stylesheet.getInstance();\n        var registration = {\n            className: stylesheet.classNameFromKey(key),\n            key: key,\n            args: args,\n        };\n        if (!registration.className) {\n            registration.className = stylesheet.getClassName(getDisplayName(rules));\n            var rulesToInsert = [];\n            for (var _a = 0, _b = rules.__order; _a < _b.length; _a++) {\n                var selector = _b[_a];\n                rulesToInsert.push(selector, serializeRuleEntries(options, rules[selector]));\n            }\n            registration.rulesToInsert = rulesToInsert;\n        }\n        return registration;\n    }\n    return undefined;\n}\n/**\n * Insert style to stylesheet.\n * @param registration Style registration.\n * @param specificityMultiplier Number of times classname selector is repeated in the css rule.\n * This is to increase css specificity in case it's needed. Default to 1.\n */\nexport function applyRegistration(registration, specificityMultiplier) {\n    if (specificityMultiplier === void 0) { specificityMultiplier = 1; }\n    var stylesheet = Stylesheet.getInstance();\n    var className = registration.className, key = registration.key, args = registration.args, rulesToInsert = registration.rulesToInsert;\n    if (rulesToInsert) {\n        // rulesToInsert is an ordered array of selector/rule pairs.\n        for (var i = 0; i < rulesToInsert.length; i += 2) {\n            var rules = rulesToInsert[i + 1];\n            if (rules) {\n                var selector = rulesToInsert[i];\n                selector = selector.replace(/&/g, repeatString(\".\" + registration.className, specificityMultiplier));\n                // Insert. Note if a media query, we must close the query with a final bracket.\n                var processedRule = selector + \"{\" + rules + \"}\" + (selector.indexOf('@') === 0 ? '}' : '');\n                stylesheet.insertRule(processedRule);\n            }\n        }\n        stylesheet.cacheClassName(className, key, args, rulesToInsert);\n    }\n}\nexport function styleToClassName(options) {\n    var args = [];\n    for (var _i = 1; _i < arguments.length; _i++) {\n        args[_i - 1] = arguments[_i];\n    }\n    var registration = styleToRegistration.apply(void 0, __spreadArrays([options], args));\n    if (registration) {\n        applyRegistration(registration, options.specificityMultiplier);\n        return registration.className;\n    }\n    return '';\n}\n//# sourceMappingURL=styleToClassName.js.map","/**\n * Split a string into tokens separated by whitespace, except all text within parentheses\n * is treated as a single token (whitespace is ignored within parentheses).\n *\n * Unlike String.split(' '), multiple consecutive space characters are collapsed and\n * removed from the returned array (including leading and trailing spaces).\n *\n * For example:\n * `tokenizeWithParentheses(\"3px calc(var(--x) / 2) 9px    0 \")`\n *   => `[\"3px\", \"calc(var(--x) / 2)\", \"9px\", \"0\"]`\n *\n * @returns The array of tokens. Returns an empty array if the string was empty or contained only whitespace.\n */\nexport function tokenizeWithParentheses(value) {\n    var parts = [];\n    var partStart = 0;\n    var parens = 0;\n    for (var i = 0; i < value.length; i++) {\n        switch (value[i]) {\n            case '(':\n                parens++;\n                break;\n            case ')':\n                if (parens) {\n                    parens--;\n                }\n                break;\n            case '\\t':\n            case ' ':\n                if (!parens) {\n                    // Add the new part if it's not an empty string\n                    if (i > partStart) {\n                        parts.push(value.substring(partStart, i));\n                    }\n                    partStart = i + 1;\n                }\n                break;\n        }\n    }\n    // Add the last part\n    if (partStart < value.length) {\n        parts.push(value.substring(partStart));\n    }\n    return parts;\n}\n//# sourceMappingURL=tokenizeWithParentheses.js.map","import { extractStyleParts } from './extractStyleParts';\nimport { getStyleOptions } from './StyleOptionsState';\nimport { styleToClassName } from './styleToClassName';\n/**\n * Concatenation helper, which can merge class names together. Skips over falsey values.\n *\n * @public\n */\nexport function mergeStyles() {\n    var args = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        args[_i] = arguments[_i];\n    }\n    return mergeCss(args, getStyleOptions());\n}\n/**\n * Concatenation helper, which can merge class names together. Skips over falsey values.\n * Accepts a set of options that will be used when calculating styles.\n *\n * @public\n */\nexport function mergeCss(args, options) {\n    var styleArgs = args instanceof Array ? args : [args];\n    var _a = extractStyleParts(styleArgs), classes = _a.classes, objects = _a.objects;\n    if (objects.length) {\n        classes.push(styleToClassName(options || {}, objects));\n    }\n    return classes.join(' ');\n}\n//# sourceMappingURL=mergeStyles.js.map","import { Stylesheet } from './Stylesheet';\n/**\n * Separates the classes and style objects. Any classes that are pre-registered\n * args are auto expanded into objects.\n */\nexport function extractStyleParts() {\n    var args = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        args[_i] = arguments[_i];\n    }\n    var classes = [];\n    var objects = [];\n    var stylesheet = Stylesheet.getInstance();\n    function _processArgs(argsList) {\n        for (var _i = 0, argsList_1 = argsList; _i < argsList_1.length; _i++) {\n            var arg = argsList_1[_i];\n            if (arg) {\n                if (typeof arg === 'string') {\n                    if (arg.indexOf(' ') >= 0) {\n                        _processArgs(arg.split(' '));\n                    }\n                    else {\n                        var translatedArgs = stylesheet.argsFromClassName(arg);\n                        if (translatedArgs) {\n                            _processArgs(translatedArgs);\n                        }\n                        else {\n                            // Avoid adding the same class twice.\n                            if (classes.indexOf(arg) === -1) {\n                                classes.push(arg);\n                            }\n                        }\n                    }\n                }\n                else if (Array.isArray(arg)) {\n                    _processArgs(arg);\n                }\n                else if (typeof arg === 'object') {\n                    objects.push(arg);\n                }\n            }\n        }\n    }\n    _processArgs(args);\n    return {\n        classes: classes,\n        objects: objects,\n    };\n}\n//# sourceMappingURL=extractStyleParts.js.map","import { DEFAULT_SHADOW_CONFIG } from './shadowConfig';\n/**\n * Sets the current RTL value.\n */\nexport function setRTL(isRTL) {\n    if (_rtl !== isRTL) {\n        _rtl = isRTL;\n    }\n}\n/**\n * Gets the current RTL value.\n */\nexport function getRTL() {\n    if (_rtl === undefined) {\n        _rtl =\n            // eslint-disable-next-line no-restricted-globals\n            typeof document !== 'undefined' &&\n                // eslint-disable-next-line no-restricted-globals\n                !!document.documentElement &&\n                // eslint-disable-next-line no-restricted-globals\n                document.documentElement.getAttribute('dir') === 'rtl';\n    }\n    return _rtl;\n}\n// This has been split into 2 lines because it was working in Fabric due to the code being transpiled to es5, so this\n// was converted to var while not working in Fluent that uses babel to transpile the code to be es6-like. Splitting the\n// logic into two lines, however, allows it to work in both scenarios.\nvar _rtl;\n_rtl = getRTL();\nexport function getStyleOptions() {\n    return {\n        rtl: getRTL(),\n        shadowConfig: DEFAULT_SHADOW_CONFIG,\n    };\n}\n//# sourceMappingURL=StyleOptionsState.js.map","import { __assign } from \"tslib\";\nimport { GLOBAL_STYLESHEET_KEY, SHADOW_DOM_STYLESHEET_SETTING } from './shadowConfig';\nexport var InjectionMode = {\n    /**\n     * Avoids style injection, use getRules() to read the styles.\n     */\n    none: 0,\n    /**\n     * Inserts rules using the insertRule api.\n     */\n    insertNode: 1,\n    /**\n     * Appends rules using appendChild.\n     */\n    appendChild: 2,\n};\nexport var STYLESHEET_SETTING = '__stylesheet__';\n/**\n * MSIE 11 doesn't cascade styles based on DOM ordering, but rather on the order that each style node\n * is created. As such, to maintain consistent priority, IE11 should reuse a single style node.\n */\nvar REUSE_STYLE_NODE = typeof navigator !== 'undefined' && /rv:11.0/.test(navigator.userAgent);\nvar _global = {};\n// Grab window.\ntry {\n    // Why the cast?\n    // if compiled/type checked in same program with `@fluentui/font-icons-mdl2` which extends `Window` on global\n    // ( check packages/font-icons-mdl2/src/index.ts ) the definitions don't match! Thus the need of this extra assertion\n    _global = (window || {});\n}\ncatch (_a) {\n    /* leave as blank object */\n}\nvar _stylesheet;\n/**\n * Represents the state of styles registered in the page. Abstracts\n * the surface for adding styles to the stylesheet, exposes helpers\n * for reading the styles registered in server rendered scenarios.\n *\n * @public\n */\nvar Stylesheet = /** @class */ (function () {\n    function Stylesheet(config, serializedStylesheet) {\n        var _a, _b, _c, _d, _e, _f;\n        this._rules = [];\n        this._preservedRules = [];\n        this._counter = 0;\n        this._keyToClassName = {};\n        this._onInsertRuleCallbacks = [];\n        this._onResetCallbacks = [];\n        this._classNameToArgs = {};\n        // If there is no document we won't have an element to inject into.\n        this._config = __assign({ injectionMode: typeof document === 'undefined' ? InjectionMode.none : InjectionMode.insertNode, defaultPrefix: 'css', namespace: undefined, cspSettings: undefined }, config);\n        this._classNameToArgs = (_a = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.classNameToArgs) !== null && _a !== void 0 ? _a : this._classNameToArgs;\n        this._counter = (_b = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.counter) !== null && _b !== void 0 ? _b : this._counter;\n        this._keyToClassName = (_d = (_c = this._config.classNameCache) !== null && _c !== void 0 ? _c : serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.keyToClassName) !== null && _d !== void 0 ? _d : this._keyToClassName;\n        this._preservedRules = (_e = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.preservedRules) !== null && _e !== void 0 ? _e : this._preservedRules;\n        this._rules = (_f = serializedStylesheet === null || serializedStylesheet === void 0 ? void 0 : serializedStylesheet.rules) !== null && _f !== void 0 ? _f : this._rules;\n    }\n    /**\n     * Gets the singleton instance.\n     */\n    Stylesheet.getInstance = function (shadowConfig) {\n        _stylesheet = _global[STYLESHEET_SETTING];\n        if (_global[SHADOW_DOM_STYLESHEET_SETTING]) {\n            return _global[SHADOW_DOM_STYLESHEET_SETTING].getInstance(shadowConfig);\n        }\n        if (!_stylesheet || (_stylesheet._lastStyleElement && _stylesheet._lastStyleElement.ownerDocument !== document)) {\n            var fabricConfig = (_global === null || _global === void 0 ? void 0 : _global.FabricConfig) || {};\n            var stylesheet = new Stylesheet(fabricConfig.mergeStyles, fabricConfig.serializedStylesheet);\n            _stylesheet = stylesheet;\n            _global[STYLESHEET_SETTING] = stylesheet;\n        }\n        return _stylesheet;\n    };\n    /**\n     * Serializes the Stylesheet instance into a format which allows rehydration on creation.\n     * @returns string representation of `ISerializedStylesheet` interface.\n     */\n    Stylesheet.prototype.serialize = function () {\n        return JSON.stringify({\n            classNameToArgs: this._classNameToArgs,\n            counter: this._counter,\n            keyToClassName: this._keyToClassName,\n            preservedRules: this._preservedRules,\n            rules: this._rules,\n        });\n    };\n    /**\n     * Configures the stylesheet.\n     */\n    Stylesheet.prototype.setConfig = function (config) {\n        this._config = __assign(__assign({}, this._config), config);\n    };\n    /**\n     * Configures a reset callback.\n     *\n     * @param callback - A callback which will be called when the Stylesheet is reset.\n     * @returns function which when called un-registers provided callback.\n     */\n    Stylesheet.prototype.onReset = function (callback) {\n        var _this = this;\n        this._onResetCallbacks.push(callback);\n        return function () {\n            _this._onResetCallbacks = _this._onResetCallbacks.filter(function (cb) { return cb !== callback; });\n        };\n    };\n    /**\n     * Configures an insert rule callback.\n     *\n     * @param callback - A callback which will be called when a rule is inserted.\n     * @returns function which when called un-registers provided callback.\n     */\n    Stylesheet.prototype.onInsertRule = function (callback) {\n        var _this = this;\n        this._onInsertRuleCallbacks.push(callback);\n        return function () {\n            _this._onInsertRuleCallbacks = _this._onInsertRuleCallbacks.filter(function (cb) { return cb !== callback; });\n        };\n    };\n    /**\n     * Generates a unique classname.\n     *\n     * @param displayName - Optional value to use as a prefix.\n     */\n    Stylesheet.prototype.getClassName = function (displayName) {\n        var namespace = this._config.namespace;\n        var prefix = displayName || this._config.defaultPrefix;\n        return \"\".concat(namespace ? namespace + '-' : '').concat(prefix, \"-\").concat(this._counter++);\n    };\n    /**\n     * Used internally to cache information about a class which was\n     * registered with the stylesheet.\n     */\n    Stylesheet.prototype.cacheClassName = function (className, key, args, rules) {\n        this._keyToClassName[this._getCacheKey(key)] = className;\n        this._classNameToArgs[className] = {\n            args: args,\n            rules: rules,\n        };\n    };\n    /**\n     * Gets the appropriate classname given a key which was previously\n     * registered using cacheClassName.\n     */\n    Stylesheet.prototype.classNameFromKey = function (key) {\n        return this._keyToClassName[this._getCacheKey(key)];\n    };\n    /**\n     * Gets all classnames cache with the stylesheet.\n     */\n    Stylesheet.prototype.getClassNameCache = function () {\n        return this._keyToClassName;\n    };\n    /**\n     * Gets the arguments associated with a given classname which was\n     * previously registered using cacheClassName.\n     */\n    Stylesheet.prototype.argsFromClassName = function (className) {\n        var entry = this._classNameToArgs[className];\n        return entry && entry.args;\n    };\n    /**\n     * Gets the rules associated with a given classname which was\n     * previously registered using cacheClassName.\n     */\n    Stylesheet.prototype.insertedRulesFromClassName = function (className) {\n        var entry = this._classNameToArgs[className];\n        return entry && entry.rules;\n    };\n    /**\n     * Inserts a css rule into the stylesheet.\n     * @param preserve - Preserves the rule beyond a reset boundary.\n     */\n    Stylesheet.prototype.insertRule = function (rule, preserve, stylesheetKey) {\n        if (stylesheetKey === void 0) { stylesheetKey = GLOBAL_STYLESHEET_KEY; }\n        var injectionMode = this._config.injectionMode;\n        var element = injectionMode !== InjectionMode.none ? this._getStyleElement() : undefined;\n        if (preserve) {\n            this._preservedRules.push(rule);\n        }\n        if (element) {\n            switch (injectionMode) {\n                case InjectionMode.insertNode:\n                    this._insertRuleIntoSheet(element.sheet, rule);\n                    break;\n                case InjectionMode.appendChild:\n                    element.appendChild(document.createTextNode(rule));\n                    break;\n            }\n        }\n        else {\n            this._rules.push(rule);\n        }\n        // eslint-disable-next-line deprecation/deprecation\n        if (this._config.onInsertRule) {\n            // eslint-disable-next-line deprecation/deprecation\n            this._config.onInsertRule(rule);\n        }\n        this._onInsertRuleCallbacks.forEach(function (callback) {\n            return callback({ key: stylesheetKey, sheet: (element ? element.sheet : undefined), rule: rule });\n        });\n    };\n    /**\n     * Gets all rules registered with the stylesheet; only valid when\n     * using InsertionMode.none.\n     */\n    Stylesheet.prototype.getRules = function (includePreservedRules) {\n        return (includePreservedRules ? this._preservedRules.join('') : '') + this._rules.join('');\n    };\n    /**\n     * Resets the internal state of the stylesheet. Only used in server\n     * rendered scenarios where we're using InsertionMode.none.\n     */\n    Stylesheet.prototype.reset = function () {\n        this._rules = [];\n        this._counter = 0;\n        this._classNameToArgs = {};\n        this._keyToClassName = {};\n        this._onResetCallbacks.forEach(function (callback) { return callback(); });\n    };\n    // Forces the regeneration of incoming styles without totally resetting the stylesheet.\n    Stylesheet.prototype.resetKeys = function () {\n        this._keyToClassName = {};\n    };\n    Stylesheet.prototype._createStyleElement = function () {\n        var _a;\n        var doc = ((_a = this._config.window) === null || _a === void 0 ? void 0 : _a.document) || document;\n        var head = doc.head;\n        var styleElement = doc.createElement('style');\n        var nodeToInsertBefore = null;\n        styleElement.setAttribute('data-merge-styles', 'true');\n        var cspSettings = this._config.cspSettings;\n        if (cspSettings) {\n            if (cspSettings.nonce) {\n                styleElement.setAttribute('nonce', cspSettings.nonce);\n            }\n        }\n        if (this._lastStyleElement) {\n            // If the `nextElementSibling` is null, then the insertBefore will act as a regular append.\n            // https://developer.mozilla.org/en-US/docs/Web/API/Node/insertBefore#Syntax\n            nodeToInsertBefore = this._lastStyleElement.nextElementSibling;\n        }\n        else {\n            var placeholderStyleTag = this._findPlaceholderStyleTag();\n            if (placeholderStyleTag) {\n                nodeToInsertBefore = placeholderStyleTag.nextElementSibling;\n            }\n            else {\n                nodeToInsertBefore = head.childNodes[0];\n            }\n        }\n        head.insertBefore(styleElement, head.contains(nodeToInsertBefore) ? nodeToInsertBefore : null);\n        this._lastStyleElement = styleElement;\n        return styleElement;\n    };\n    Stylesheet.prototype._insertRuleIntoSheet = function (sheet, rule) {\n        if (!sheet) {\n            return false;\n        }\n        try {\n            sheet.insertRule(rule, sheet.cssRules.length);\n            return true;\n        }\n        catch (e) {\n            // The browser will throw exceptions on unsupported rules (such as a moz prefix in webkit.)\n            // We need to swallow the exceptions for this scenario, otherwise we'd need to filter\n            // which could be slower and bulkier.\n        }\n        return false;\n    };\n    Stylesheet.prototype._getCacheKey = function (key) {\n        return key;\n    };\n    Stylesheet.prototype._getStyleElement = function () {\n        var _this = this;\n        if (!this._styleElement) {\n            this._styleElement = this._createStyleElement();\n            if (!REUSE_STYLE_NODE) {\n                // Reset the style element on the next frame.\n                var win = this._config.window || window;\n                win.requestAnimationFrame(function () {\n                    _this._styleElement = undefined;\n                });\n            }\n        }\n        return this._styleElement;\n    };\n    Stylesheet.prototype._findPlaceholderStyleTag = function () {\n        var head = document.head;\n        if (head) {\n            return head.querySelector('style[data-merge-styles]');\n        }\n        return null;\n    };\n    return Stylesheet;\n}());\nexport { Stylesheet };\n//# sourceMappingURL=Stylesheet.js.map","import { __spreadArray } from \"tslib\";\nimport { isShadowConfig } from './shadowConfig';\n/**\n * Combine a set of styles together (but does not register css classes).\n * @param styleSets - One or more stylesets to be merged (each param can also be falsy).\n */\nexport function concatStyleSets() {\n    var styleSets = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        styleSets[_i] = arguments[_i];\n    }\n    if (styleSets &&\n        styleSets.length === 1 &&\n        styleSets[0] &&\n        !styleSets[0].subComponentStyles &&\n        !isShadowConfig(styleSets[0])) {\n        return styleSets[0];\n    }\n    var mergedSet = {};\n    // We process sub component styles in two phases. First we collect them, then we combine them into 1 style function.\n    var workingSubcomponentStyles = {};\n    for (var _a = 0, styleSets_1 = styleSets; _a < styleSets_1.length; _a++) {\n        var currentSet = styleSets_1[_a];\n        if (currentSet && !isShadowConfig(currentSet)) {\n            for (var prop in currentSet) {\n                if (currentSet.hasOwnProperty(prop)) {\n                    if (prop === 'subComponentStyles' && currentSet.subComponentStyles !== undefined) {\n                        // subcomponent styles - style functions or objects\n                        var currentComponentStyles = currentSet.subComponentStyles;\n                        for (var subCompProp in currentComponentStyles) {\n                            if (currentComponentStyles.hasOwnProperty(subCompProp)) {\n                                if (workingSubcomponentStyles.hasOwnProperty(subCompProp)) {\n                                    workingSubcomponentStyles[subCompProp].push(currentComponentStyles[subCompProp]);\n                                }\n                                else {\n                                    workingSubcomponentStyles[subCompProp] = [currentComponentStyles[subCompProp]];\n                                }\n                            }\n                        }\n                        continue;\n                    }\n                    // the as any casts below is a workaround for ts 2.8.\n                    // todo: remove cast to any in ts 2.9.\n                    var mergedValue = mergedSet[prop];\n                    var currentValue = currentSet[prop];\n                    if (mergedValue === undefined) {\n                        mergedSet[prop] = currentValue;\n                    }\n                    else {\n                        mergedSet[prop] = __spreadArray(__spreadArray([], (Array.isArray(mergedValue) ? mergedValue : [mergedValue]), true), (Array.isArray(currentValue) ? currentValue : [currentValue]), true);\n                    }\n                }\n            }\n        }\n    }\n    if (Object.keys(workingSubcomponentStyles).length > 0) {\n        mergedSet.subComponentStyles = {};\n        var mergedSubStyles = mergedSet.subComponentStyles;\n        var _loop_1 = function (subCompProp) {\n            if (workingSubcomponentStyles.hasOwnProperty(subCompProp)) {\n                var workingSet_1 = workingSubcomponentStyles[subCompProp];\n                mergedSubStyles[subCompProp] = function (styleProps) {\n                    return concatStyleSets.apply(void 0, workingSet_1.map(function (styleFunctionOrObject) {\n                        return typeof styleFunctionOrObject === 'function' ? styleFunctionOrObject(styleProps) : styleFunctionOrObject;\n                    }));\n                };\n            }\n        };\n        // now we process the subcomponent styles if there are any\n        for (var subCompProp in workingSubcomponentStyles) {\n            _loop_1(subCompProp);\n        }\n    }\n    return mergedSet;\n}\n//# sourceMappingURL=concatStyleSets.js.map","import { concatStyleSets } from './concatStyleSets';\n/**\n * Concatenates style sets into one, but resolves functional sets using the given props.\n * @param styleProps - Props used to resolve functional sets.\n * @param allStyles - Style sets, which can be functions or objects.\n */\nexport function concatStyleSetsWithProps(styleProps) {\n    var allStyles = [];\n    for (var _i = 1; _i < arguments.length; _i++) {\n        allStyles[_i - 1] = arguments[_i];\n    }\n    var result = [];\n    for (var _a = 0, allStyles_1 = allStyles; _a < allStyles_1.length; _a++) {\n        var styles = allStyles_1[_a];\n        if (styles) {\n            result.push(typeof styles === 'function' ? styles(styleProps) : styles);\n        }\n    }\n    if (result.length === 1) {\n        return result[0];\n    }\n    else if (result.length) {\n        // cliffkoh: I cannot figure out how to avoid the cast to any here.\n        // It is something to do with the use of Omit in IStyleSet.\n        // It might not be necessary once  Omit becomes part of lib.d.ts (when we remove our own Omit and rely on\n        // the official version).\n        return concatStyleSets.apply(void 0, result);\n    }\n    return {};\n}\n//# sourceMappingURL=concatStyleSetsWithProps.js.map","import { isShadowConfig } from './shadowConfig';\n/**\n * Separates the classes and style objects. Any classes that are pre-registered\n * args are auto expanded into objects.\n */\nexport function extractStyleParts(sheet) {\n    var args = [];\n    for (var _i = 1; _i < arguments.length; _i++) {\n        args[_i - 1] = arguments[_i];\n    }\n    var classes = [];\n    var objects = [];\n    var stylesheet = sheet;\n    function _processArgs(argsList) {\n        for (var _i = 0, argsList_1 = argsList; _i < argsList_1.length; _i++) {\n            var arg = argsList_1[_i];\n            if (arg && !isShadowConfig(arg)) {\n                if (typeof arg === 'string') {\n                    if (arg.indexOf(' ') >= 0) {\n                        _processArgs(arg.split(' '));\n                    }\n                    else {\n                        var translatedArgs = stylesheet.argsFromClassName(arg);\n                        if (translatedArgs) {\n                            _processArgs(translatedArgs);\n                        }\n                        else {\n                            // Avoid adding the same class twice.\n                            if (classes.indexOf(arg) === -1) {\n                                classes.push(arg);\n                            }\n                        }\n                    }\n                }\n                else if (Array.isArray(arg)) {\n                    _processArgs(arg);\n                }\n                else if (typeof arg === 'object') {\n                    objects.push(arg);\n                }\n            }\n        }\n    }\n    _processArgs(args);\n    return {\n        classes: classes,\n        objects: objects,\n    };\n}\n//# sourceMappingURL=extractStyleParts.js.map","import { getStyleOptions } from './StyleOptionsState';\nimport { Stylesheet } from './Stylesheet';\nimport { serializeRuleEntries } from './styleToClassName';\n/**\n * Registers a font face.\n * @public\n */\nexport function fontFace(font) {\n    var stylesheet = Stylesheet.getInstance();\n    var rule = serializeRuleEntries(getStyleOptions(), font);\n    var className = stylesheet.classNameFromKey(rule);\n    if (className) {\n        return;\n    }\n    var name = stylesheet.getClassName();\n    stylesheet.insertRule(\"@font-face{\".concat(rule, \"}\"), true);\n    stylesheet.cacheClassName(name, rule, [], ['font-face', rule]);\n}\n//# sourceMappingURL=fontFace.js.map","import { getStyleOptions } from './StyleOptionsState';\nimport { Stylesheet } from './Stylesheet';\nimport { serializeRuleEntries } from './styleToClassName';\n/**\n * Registers keyframe definitions.\n *\n * @public\n */\nexport function keyframes(timeline) {\n    var stylesheet = Stylesheet.getInstance();\n    var rulesArray = [];\n    for (var prop in timeline) {\n        if (timeline.hasOwnProperty(prop)) {\n            rulesArray.push(prop, '{', serializeRuleEntries(getStyleOptions(), timeline[prop]), '}');\n        }\n    }\n    var rules = rulesArray.join('');\n    var className = stylesheet.classNameFromKey(rules);\n    if (className) {\n        return className;\n    }\n    var name = stylesheet.getClassName();\n    stylesheet.insertRule(\"@keyframes \".concat(name, \"{\").concat(rules, \"}\"), true);\n    stylesheet.cacheClassName(name, rules, [], ['keyframes', rules]);\n    return name;\n}\n//# sourceMappingURL=keyframes.js.map","import { __assign } from \"tslib\";\nimport { concatStyleSets } from './concatStyleSets';\nimport { extractStyleParts } from './extractStyleParts';\nimport { getStyleOptions } from './StyleOptionsState';\nimport { applyRegistration, styleToRegistration } from './styleToClassName';\nimport { isShadowConfig } from './shadowConfig';\nimport { Stylesheet } from './Stylesheet';\n/**\n * Takes in one or more style set objects, each consisting of a set of areas,\n * each which will produce a class name. Using this is analogous to calling\n * `mergeStyles` for each property in the object, but ensures we maintain the\n * set ordering when multiple style sets are merged.\n *\n * @param styleSets - One or more style sets to be merged.\n */\nexport function mergeStyleSets() {\n    var styleSets = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        styleSets[_i] = arguments[_i];\n    }\n    return mergeCssSets(styleSets, getStyleOptions());\n}\n/**\n * Takes in one or more style set objects, each1consisting of a set of areas,\n * each which will produce a class name. Using this is analogous to calling\n * `mergeCss` for each property in the object, but ensures the\n * set ordering when multiple style sets are merged.\n *\n * @param styleSets - One or more style sets to be merged.\n * @param options - (optional) Options to use when creating rules.\n */\nexport function mergeCssSets(styleSets, options) {\n    var classNameSet = { subComponentStyles: {} };\n    var shadowConfig = undefined;\n    var styleSet;\n    if (isShadowConfig(styleSets[0])) {\n        shadowConfig = styleSets[0];\n        styleSet = styleSets[1];\n    }\n    else {\n        styleSet = styleSets[0];\n    }\n    shadowConfig !== null && shadowConfig !== void 0 ? shadowConfig : (shadowConfig = options === null || options === void 0 ? void 0 : options.shadowConfig);\n    var opts = __assign(__assign({}, options), { shadowConfig: shadowConfig });\n    if (!styleSet && styleSets.length <= 1) {\n        return { subComponentStyles: {} };\n    }\n    var sheet = Stylesheet.getInstance(shadowConfig);\n    opts.stylesheet = sheet;\n    var concatenatedStyleSet = concatStyleSets.apply(void 0, styleSets);\n    var registrations = [];\n    for (var styleSetArea in concatenatedStyleSet) {\n        if (concatenatedStyleSet.hasOwnProperty(styleSetArea)) {\n            if (styleSetArea === 'subComponentStyles') {\n                classNameSet.subComponentStyles = concatenatedStyleSet.subComponentStyles || {};\n                continue;\n            }\n            else if (styleSetArea === '__shadowConfig__') {\n                continue;\n            }\n            var styles = concatenatedStyleSet[styleSetArea];\n            var _a = extractStyleParts(sheet, styles), classes = _a.classes, objects = _a.objects;\n            if (objects === null || objects === void 0 ? void 0 : objects.length) {\n                var registration = styleToRegistration(opts || {}, { displayName: styleSetArea }, objects);\n                if (registration) {\n                    registrations.push(registration);\n                    classNameSet[styleSetArea] = classes.concat([registration.className]).join(' ');\n                }\n            }\n            else {\n                classNameSet[styleSetArea] = classes.join(' ');\n            }\n        }\n    }\n    for (var _i = 0, registrations_1 = registrations; _i < registrations_1.length; _i++) {\n        var registration = registrations_1[_i];\n        if (registration) {\n            applyRegistration(registration, options === null || options === void 0 ? void 0 : options.specificityMultiplier, shadowConfig);\n        }\n    }\n    return classNameSet;\n}\n//# sourceMappingURL=mergeStyleSets.js.map","import { extractStyleParts } from './extractStyleParts';\nimport { isShadowConfig } from './shadowConfig';\nimport { getStyleOptions } from './StyleOptionsState';\nimport { Stylesheet } from './Stylesheet';\nimport { styleToClassName } from './styleToClassName';\n/**\n * Concatenation helper, which can merge class names together. Skips over falsey values.\n *\n * @public\n */\nexport function mergeStyles() {\n    var args = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        args[_i] = arguments[_i];\n    }\n    return mergeCss(args, getStyleOptions());\n}\n/**\n * Concatenation helper, which can merge class names together. Skips over falsey values.\n * Accepts a set of options that will be used when calculating styles.\n *\n * @public\n */\nexport function mergeCss(args, options) {\n    var styleArgs = args instanceof Array ? args : [args];\n    var opts = options || {};\n    var hasShadowConfig = isShadowConfig(styleArgs[0]);\n    if (hasShadowConfig) {\n        opts.shadowConfig = styleArgs[0];\n    }\n    opts.stylesheet = Stylesheet.getInstance(opts.shadowConfig);\n    var _a = extractStyleParts(opts.stylesheet, styleArgs), classes = _a.classes, objects = _a.objects;\n    if (objects.length) {\n        classes.push(styleToClassName(opts, objects));\n    }\n    return classes.join(' ');\n}\n//# sourceMappingURL=mergeStyles.js.map","export var GLOBAL_STYLESHEET_KEY = '__global__';\nexport var SHADOW_DOM_STYLESHEET_SETTING = '__shadow_dom_stylesheet__';\nexport var DEFAULT_SHADOW_CONFIG = {\n    stylesheetKey: GLOBAL_STYLESHEET_KEY,\n    inShadow: false,\n    window: undefined,\n    __isShadowConfig__: true,\n};\nexport var makeShadowConfig = function (stylesheetKey, inShadow, window) {\n    return {\n        stylesheetKey: stylesheetKey,\n        inShadow: inShadow,\n        window: window,\n        __isShadowConfig__: true,\n    };\n};\nexport var isShadowConfig = function (value) {\n    if (!(value && isRecord(value))) {\n        return false;\n    }\n    return value.__isShadowConfig__ === true;\n};\nfunction isRecord(value) {\n    return value !== null && typeof value === 'object' && !Array.isArray(value);\n}\n//# sourceMappingURL=shadowConfig.js.map","var _vendorSettings;\nexport function getVendorSettings() {\n    var _a;\n    if (!_vendorSettings) {\n        // eslint-disable-next-line no-restricted-globals\n        var doc = typeof document !== 'undefined' ? document : undefined;\n        var nav = typeof navigator !== 'undefined' ? navigator : undefined;\n        var userAgent = (_a = nav === null || nav === void 0 ? void 0 : nav.userAgent) === null || _a === void 0 ? void 0 : _a.toLowerCase();\n        if (!doc) {\n            _vendorSettings = {\n                isWebkit: true,\n                isMoz: true,\n                isOpera: true,\n                isMs: true,\n            };\n        }\n        else {\n            _vendorSettings = {\n                isWebkit: !!(doc && 'WebkitAppearance' in doc.documentElement.style),\n                isMoz: !!(userAgent && userAgent.indexOf('firefox') > -1),\n                isOpera: !!(userAgent && userAgent.indexOf('opera') > -1),\n                isMs: !!(nav && (/rv:11.0/i.test(nav.userAgent) || /Edge\\/\\d./i.test(navigator.userAgent))),\n            };\n        }\n    }\n    return _vendorSettings;\n}\n/**\n * Sets the vendor settings for prefixing and vendor specific operations.\n */\nexport function setVendorSettings(vendorSettings) {\n    _vendorSettings = vendorSettings;\n}\n//# sourceMappingURL=getVendorSettings.js.map","var rules = {};\nexport function kebabRules(rulePairs, index) {\n    var rule = rulePairs[index];\n    if (rule.charAt(0) !== '-') {\n        rulePairs[index] = rules[rule] = rules[rule] || rule.replace(/([A-Z])/g, '-$1').toLowerCase();\n    }\n}\n//# sourceMappingURL=kebabRules.js.map","import { getVendorSettings } from '../getVendorSettings';\nvar autoPrefixNames = {\n    'user-select': 1,\n};\nexport function prefixRules(rulePairs, index) {\n    var vendorSettings = getVendorSettings();\n    var name = rulePairs[index];\n    if (autoPrefixNames[name]) {\n        var value = rulePairs[index + 1];\n        if (autoPrefixNames[name]) {\n            if (vendorSettings.isWebkit) {\n                rulePairs.push('-webkit-' + name, value);\n            }\n            if (vendorSettings.isMoz) {\n                rulePairs.push('-moz-' + name, value);\n            }\n            if (vendorSettings.isMs) {\n                rulePairs.push('-ms-' + name, value);\n            }\n            if (vendorSettings.isOpera) {\n                rulePairs.push('-o-' + name, value);\n            }\n        }\n    }\n}\n//# sourceMappingURL=prefixRules.js.map","var NON_PIXEL_NUMBER_PROPS = [\n    'column-count',\n    'font-weight',\n    'flex',\n    'flex-grow',\n    'flex-shrink',\n    'fill-opacity',\n    'opacity',\n    'order',\n    'z-index',\n    'zoom',\n];\nexport function provideUnits(rulePairs, index) {\n    var name = rulePairs[index];\n    var value = rulePairs[index + 1];\n    if (typeof value === 'number') {\n        var isNonPixelProp = NON_PIXEL_NUMBER_PROPS.indexOf(name) > -1;\n        var isVariableOrPrefixed = name.indexOf('--') > -1;\n        var unit = isNonPixelProp || isVariableOrPrefixed ? '' : 'px';\n        rulePairs[index + 1] = \"\".concat(value).concat(unit);\n    }\n}\n//# sourceMappingURL=provideUnits.js.map","var _a;\nvar LEFT = 'left';\nvar RIGHT = 'right';\nvar NO_FLIP = '@noflip';\nvar NAME_REPLACEMENTS = (_a = {},\n    _a[LEFT] = RIGHT,\n    _a[RIGHT] = LEFT,\n    _a);\nvar VALUE_REPLACEMENTS = {\n    'w-resize': 'e-resize',\n    'sw-resize': 'se-resize',\n    'nw-resize': 'ne-resize',\n};\n/**\n * RTLifies the rulePair in the array at the current index. This mutates the array for performance\n * reasons.\n */\nexport function rtlifyRules(options, rulePairs, index) {\n    if (options.rtl) {\n        var name_1 = rulePairs[index];\n        if (!name_1) {\n            return;\n        }\n        var value = rulePairs[index + 1];\n        if (typeof value === 'string' && value.indexOf(NO_FLIP) >= 0) {\n            rulePairs[index + 1] = value.replace(/\\s*(?:\\/\\*\\s*)?\\@noflip\\b(?:\\s*\\*\\/)?\\s*?/g, '');\n        }\n        else if (name_1.indexOf(LEFT) >= 0) {\n            rulePairs[index] = name_1.replace(LEFT, RIGHT);\n        }\n        else if (name_1.indexOf(RIGHT) >= 0) {\n            rulePairs[index] = name_1.replace(RIGHT, LEFT);\n        }\n        else if (String(value).indexOf(LEFT) >= 0) {\n            rulePairs[index + 1] = value.replace(LEFT, RIGHT);\n        }\n        else if (String(value).indexOf(RIGHT) >= 0) {\n            rulePairs[index + 1] = value.replace(RIGHT, LEFT);\n        }\n        else if (NAME_REPLACEMENTS[name_1]) {\n            rulePairs[index] = NAME_REPLACEMENTS[name_1];\n        }\n        else if (VALUE_REPLACEMENTS[value]) {\n            rulePairs[index + 1] = VALUE_REPLACEMENTS[value];\n        }\n        else {\n            switch (name_1) {\n                case 'margin':\n                case 'padding':\n                    rulePairs[index + 1] = flipQuad(value);\n                    break;\n                case 'box-shadow':\n                    rulePairs[index + 1] = negateNum(value, 0);\n                    break;\n            }\n        }\n    }\n}\n/**\n * Given a string value in a space delimited format (e.g. \"1 2 3 4\"), negates a particular value.\n */\nfunction negateNum(value, partIndex) {\n    var parts = value.split(' ');\n    var numberVal = parseInt(parts[partIndex], 10);\n    parts[0] = parts[0].replace(String(numberVal), String(numberVal * -1));\n    return parts.join(' ');\n}\n/**\n * Given a string quad, flips the left and right values.\n */\nfunction flipQuad(value) {\n    if (typeof value === 'string') {\n        var parts = value.split(' ');\n        if (parts.length === 4) {\n            return \"\".concat(parts[0], \" \").concat(parts[3], \" \").concat(parts[2], \" \").concat(parts[1]);\n        }\n    }\n    return value;\n}\n//# sourceMappingURL=rtlifyRules.js.map","import { __spreadArray } from \"tslib\";\nimport { Stylesheet } from './Stylesheet';\nimport { kebabRules } from './transforms/kebabRules';\nimport { prefixRules } from './transforms/prefixRules';\nimport { provideUnits } from './transforms/provideUnits';\nimport { rtlifyRules } from './transforms/rtlifyRules';\nimport { tokenizeWithParentheses } from './tokenizeWithParentheses';\nvar DISPLAY_NAME = 'displayName';\nfunction getDisplayName(rules) {\n    var rootStyle = rules && rules['&'];\n    return rootStyle ? rootStyle.displayName : undefined;\n}\nvar globalSelectorRegExp = /\\:global\\((.+?)\\)/g;\n/**\n * Finds comma separated selectors in a :global() e.g. \":global(.class1, .class2, .class3)\"\n * and wraps them each in their own global \":global(.class1), :global(.class2), :global(.class3)\"\n *\n * @param selectorWithGlobals The selector to process\n * @returns The updated selector\n */\nfunction expandCommaSeparatedGlobals(selectorWithGlobals) {\n    // We the selector does not have a :global() we can shortcut\n    if (!globalSelectorRegExp.test(selectorWithGlobals)) {\n        return selectorWithGlobals;\n    }\n    var replacementInfo = [];\n    var findGlobal = /\\:global\\((.+?)\\)/g;\n    var match = null;\n    // Create a result list for global selectors so we can replace them.\n    while ((match = findGlobal.exec(selectorWithGlobals))) {\n        // Only if the found selector is a comma separated list we'll process it.\n        if (match[1].indexOf(',') > -1) {\n            replacementInfo.push([\n                match.index,\n                match.index + match[0].length,\n                // Wrap each of the found selectors in :global()\n                match[1]\n                    .split(',')\n                    .map(function (v) { return \":global(\".concat(v.trim(), \")\"); })\n                    .join(', '),\n            ]);\n        }\n    }\n    // Replace the found selectors with their wrapped variants in reverse order\n    return replacementInfo\n        .reverse()\n        .reduce(function (selector, _a) {\n        var matchIndex = _a[0], matchEndIndex = _a[1], replacement = _a[2];\n        var prefix = selector.slice(0, matchIndex);\n        var suffix = selector.slice(matchEndIndex);\n        return prefix + replacement + suffix;\n    }, selectorWithGlobals);\n}\nfunction isSelector(potentialSelector) {\n    return potentialSelector.indexOf(':global(') >= 0 || potentialSelector.indexOf(':') === 0;\n}\nfunction expandSelector(newSelector, currentSelector) {\n    if (newSelector.indexOf(':global(') >= 0) {\n        return newSelector.replace(globalSelectorRegExp, '$1');\n    }\n    else if (newSelector.indexOf(':host(') === 0) {\n        return newSelector;\n    }\n    else if (newSelector.indexOf(':') === 0) {\n        return currentSelector + newSelector;\n    }\n    else if (newSelector.indexOf('&') < 0) {\n        return currentSelector + ' ' + newSelector;\n    }\n    return newSelector;\n}\nfunction extractSelector(currentSelector, rules, selector, value, stylesheet) {\n    if (rules === void 0) { rules = { __order: [] }; }\n    if (selector.indexOf('@') === 0) {\n        selector = selector + '{' + currentSelector;\n        extractRules([value], rules, selector, stylesheet);\n    }\n    else if (selector.indexOf(',') > -1) {\n        expandCommaSeparatedGlobals(selector)\n            .split(',')\n            .map(function (s) { return s.trim(); })\n            .forEach(function (separatedSelector) {\n            return extractRules([value], rules, expandSelector(separatedSelector, currentSelector), stylesheet);\n        });\n    }\n    else {\n        extractRules([value], rules, expandSelector(selector, currentSelector), stylesheet);\n    }\n}\nfunction extractRules(args, rules, currentSelector, stylesheet) {\n    if (rules === void 0) { rules = { __order: [] }; }\n    if (currentSelector === void 0) { currentSelector = '&'; }\n    var currentRules = rules[currentSelector];\n    if (!currentRules) {\n        currentRules = {};\n        rules[currentSelector] = currentRules;\n        rules.__order.push(currentSelector);\n    }\n    for (var _i = 0, args_1 = args; _i < args_1.length; _i++) {\n        var arg = args_1[_i];\n        // If the arg is a string, we need to look up the class map and merge.\n        if (typeof arg === 'string') {\n            var expandedRules = stylesheet.argsFromClassName(arg);\n            if (expandedRules) {\n                extractRules(expandedRules, rules, currentSelector, stylesheet);\n            }\n            // Else if the arg is an array, we need to recurse in.\n        }\n        else if (Array.isArray(arg)) {\n            extractRules(arg, rules, currentSelector, stylesheet);\n        }\n        else {\n            for (var prop in arg) {\n                if (arg.hasOwnProperty(prop)) {\n                    var propValue = arg[prop];\n                    if (prop === 'selectors') {\n                        // every child is a selector.\n                        var selectors = arg.selectors;\n                        for (var newSelector in selectors) {\n                            if (selectors.hasOwnProperty(newSelector)) {\n                                extractSelector(currentSelector, rules, newSelector, selectors[newSelector], stylesheet);\n                            }\n                        }\n                    }\n                    else if (typeof propValue === 'object' || isSelector(prop)) {\n                        // prop is a selector.\n                        if (propValue !== null && propValue !== undefined) {\n                            extractSelector(currentSelector, rules, prop, propValue, stylesheet);\n                        }\n                    }\n                    else {\n                        if (propValue !== undefined) {\n                            // Else, add the rule to the currentSelector.\n                            if (prop === 'margin' || prop === 'padding') {\n                                expandQuads(currentRules, prop, propValue);\n                            }\n                            else {\n                                currentRules[prop] = propValue;\n                            }\n                        }\n                    }\n                }\n            }\n        }\n    }\n    return rules;\n}\nfunction expandQuads(currentRules, name, value) {\n    var parts = typeof value === 'string' ? tokenizeWithParentheses(value) : [value];\n    if (parts.length === 0) {\n        parts.push(value);\n    }\n    if (parts[parts.length - 1] === '!important') {\n        // Remove !important from parts, and append it to each part individually\n        parts = parts.slice(0, -1).map(function (p) { return p + ' !important'; });\n    }\n    currentRules[name + 'Top'] = parts[0];\n    currentRules[name + 'Right'] = parts[1] || parts[0];\n    currentRules[name + 'Bottom'] = parts[2] || parts[0];\n    currentRules[name + 'Left'] = parts[3] || parts[1] || parts[0];\n}\nfunction getKeyForRules(options, rules) {\n    var serialized = [options.rtl ? 'rtl' : 'ltr'];\n    var hasProps = false;\n    for (var _i = 0, _a = rules.__order; _i < _a.length; _i++) {\n        var selector = _a[_i];\n        serialized.push(selector);\n        var rulesForSelector = rules[selector];\n        for (var propName in rulesForSelector) {\n            if (rulesForSelector.hasOwnProperty(propName) && rulesForSelector[propName] !== undefined) {\n                hasProps = true;\n                serialized.push(propName, rulesForSelector[propName]);\n            }\n        }\n    }\n    return hasProps ? serialized.join('') : undefined;\n}\nfunction repeatString(target, count) {\n    if (count <= 0) {\n        return '';\n    }\n    if (count === 1) {\n        return target;\n    }\n    return target + repeatString(target, count - 1);\n}\nexport function serializeRuleEntries(options, ruleEntries) {\n    if (!ruleEntries) {\n        return '';\n    }\n    var allEntries = [];\n    for (var entry in ruleEntries) {\n        if (ruleEntries.hasOwnProperty(entry) && entry !== DISPLAY_NAME && ruleEntries[entry] !== undefined) {\n            allEntries.push(entry, ruleEntries[entry]);\n        }\n    }\n    // Apply transforms.\n    for (var i = 0; i < allEntries.length; i += 2) {\n        kebabRules(allEntries, i);\n        provideUnits(allEntries, i);\n        rtlifyRules(options, allEntries, i);\n        prefixRules(allEntries, i);\n    }\n    // Apply punctuation.\n    for (var i = 1; i < allEntries.length; i += 4) {\n        allEntries.splice(i, 1, ':', allEntries[i], ';');\n    }\n    return allEntries.join('');\n}\nexport function styleToRegistration(options) {\n    var _a;\n    var args = [];\n    for (var _i = 1; _i < arguments.length; _i++) {\n        args[_i - 1] = arguments[_i];\n    }\n    var stylesheet = (_a = options.stylesheet) !== null && _a !== void 0 ? _a : Stylesheet.getInstance(options.shadowConfig);\n    var rules = extractRules(args, undefined, undefined, stylesheet);\n    var key = getKeyForRules(options, rules);\n    if (key) {\n        var registration = {\n            className: stylesheet.classNameFromKey(key),\n            key: key,\n            args: args,\n        };\n        if (!registration.className) {\n            registration.className = stylesheet.getClassName(getDisplayName(rules));\n            var rulesToInsert = [];\n            for (var _b = 0, _c = rules.__order; _b < _c.length; _b++) {\n                var selector = _c[_b];\n                rulesToInsert.push(selector, serializeRuleEntries(options, rules[selector]));\n            }\n            registration.rulesToInsert = rulesToInsert;\n        }\n        return registration;\n    }\n    return undefined;\n}\n/**\n * Insert style to stylesheet.\n * @param registration Style registration.\n * @param specificityMultiplier Number of times classname selector is repeated in the css rule.\n * This is to increase css specificity in case it's needed. Default to 1.\n */\nexport function applyRegistration(registration, specificityMultiplier, shadowConfig, sheet) {\n    if (specificityMultiplier === void 0) { specificityMultiplier = 1; }\n    var stylesheet = sheet !== null && sheet !== void 0 ? sheet : Stylesheet.getInstance(shadowConfig);\n    var className = registration.className, key = registration.key, args = registration.args, rulesToInsert = registration.rulesToInsert;\n    if (rulesToInsert) {\n        // rulesToInsert is an ordered array of selector/rule pairs.\n        for (var i = 0; i < rulesToInsert.length; i += 2) {\n            var rules = rulesToInsert[i + 1];\n            if (rules) {\n                var selector = rulesToInsert[i];\n                selector = selector.replace(/&/g, repeatString(\".\".concat(registration.className), specificityMultiplier));\n                // Insert. Note if a media query, we must close the query with a final bracket.\n                var processedRule = \"\".concat(selector, \"{\").concat(rules, \"}\").concat(selector.indexOf('@') === 0 ? '}' : '');\n                stylesheet.insertRule(processedRule);\n            }\n        }\n        stylesheet.cacheClassName(className, key, args, rulesToInsert);\n    }\n}\nexport function styleToClassName(options) {\n    var args = [];\n    for (var _i = 1; _i < arguments.length; _i++) {\n        args[_i - 1] = arguments[_i];\n    }\n    var registration = styleToRegistration.apply(void 0, __spreadArray([options], args, false));\n    if (registration) {\n        applyRegistration(registration, options.specificityMultiplier, options.shadowConfig, options.stylesheet);\n        return registration.className;\n    }\n    return '';\n}\n//# sourceMappingURL=styleToClassName.js.map","/**\n * Split a string into tokens separated by whitespace, except all text within parentheses\n * is treated as a single token (whitespace is ignored within parentheses).\n *\n * Unlike String.split(' '), multiple consecutive space characters are collapsed and\n * removed from the returned array (including leading and trailing spaces).\n *\n * For example:\n * `tokenizeWithParentheses(\"3px calc(var(--x) / 2) 9px    0 \")`\n *   => `[\"3px\", \"calc(var(--x) / 2)\", \"9px\", \"0\"]`\n *\n * @returns The array of tokens. Returns an empty array if the string was empty or contained only whitespace.\n */\nexport function tokenizeWithParentheses(value) {\n    var parts = [];\n    var partStart = 0;\n    var parens = 0;\n    for (var i = 0; i < value.length; i++) {\n        switch (value[i]) {\n            case '(':\n                parens++;\n                break;\n            case ')':\n                if (parens) {\n                    parens--;\n                }\n                break;\n            case '\\t':\n            case ' ':\n                if (!parens) {\n                    // Add the new part if it's not an empty string\n                    if (i > partStart) {\n                        parts.push(value.substring(partStart, i));\n                    }\n                    partStart = i + 1;\n                }\n                break;\n        }\n    }\n    // Add the last part\n    if (partStart < value.length) {\n        parts.push(value.substring(partStart));\n    }\n    return parts;\n}\n//# sourceMappingURL=tokenizeWithParentheses.js.map","export const DATA_OVERFLOWING = 'data-overflowing';\nexport const DATA_OVERFLOW_GROUP = 'data-overflow-group';\n","/**\n * @param compare - comparison function for items\n * @returns Priority queue implemented with a min heap\n */ export function createPriorityQueue(compare) {\n    const arr = [];\n    let size = 0;\n    const left = (i)=>{\n        return 2 * i + 1;\n    };\n    const right = (i)=>{\n        return 2 * i + 2;\n    };\n    const parent = (i)=>{\n        return Math.floor((i - 1) / 2);\n    };\n    const swap = (a, b)=>{\n        const tmp = arr[a];\n        arr[a] = arr[b];\n        arr[b] = tmp;\n    };\n    const heapify = (i)=>{\n        let smallest = i;\n        const l = left(i);\n        const r = right(i);\n        if (l < size && compare(arr[l], arr[smallest]) < 0) {\n            smallest = l;\n        }\n        if (r < size && compare(arr[r], arr[smallest]) < 0) {\n            smallest = r;\n        }\n        if (smallest !== i) {\n            swap(smallest, i);\n            heapify(smallest);\n        }\n    };\n    const dequeue = ()=>{\n        if (size === 0) {\n            throw new Error('Priority queue empty');\n        }\n        const res = arr[0];\n        arr[0] = arr[--size];\n        heapify(0);\n        return res;\n    };\n    const peek = ()=>{\n        if (size === 0) {\n            return null;\n        }\n        return arr[0];\n    };\n    const enqueue = (item)=>{\n        arr[size++] = item;\n        let i = size - 1;\n        let p = parent(i);\n        while(i > 0 && compare(arr[p], arr[i]) > 0){\n            swap(p, i);\n            i = p;\n            p = parent(i);\n        }\n    };\n    const contains = (item)=>{\n        const index = arr.indexOf(item);\n        return index >= 0 && index < size;\n    };\n    const remove = (item)=>{\n        const i = arr.indexOf(item);\n        if (i === -1 || i >= size) {\n            return;\n        }\n        arr[i] = arr[--size];\n        heapify(i);\n    };\n    const clear = ()=>{\n        size = 0;\n    };\n    const all = ()=>{\n        return arr.slice(0, size);\n    };\n    return {\n        all,\n        clear,\n        contains,\n        dequeue,\n        enqueue,\n        peek,\n        remove,\n        size: ()=>size\n    };\n}\n","import { DATA_OVERFLOWING, DATA_OVERFLOW_GROUP } from './consts';\nimport { observeResize } from './createResizeObserver';\nimport { debounce } from './debounce';\nimport { createPriorityQueue } from './priorityQueue';\n/**\n * @internal\n * @returns overflow manager instance\n */ export function createOverflowManager() {\n    // calls to `offsetWidth or offsetHeight` can happen multiple times in an update\n    // Use a cache to avoid causing too many recalcs and avoid scripting time to meausure sizes\n    const sizeCache = new Map();\n    let container;\n    let overflowMenu;\n    // Set as true when resize observer is observing\n    let observing = false;\n    // If true, next update will dispatch to onUpdateOverflow even if queue top states don't change\n    // Initially true to force dispatch on first mount\n    let forceDispatch = true;\n    const options = {\n        padding: 10,\n        overflowAxis: 'horizontal',\n        overflowDirection: 'end',\n        minimumVisible: 0,\n        onUpdateItemVisibility: ()=>undefined,\n        onUpdateOverflow: ()=>undefined\n    };\n    const overflowItems = {};\n    const overflowDividers = {};\n    let disposeResizeObserver = ()=>null;\n    const getNextItem = (queueToDequeue, queueToEnqueue)=>{\n        const nextItem = queueToDequeue.dequeue();\n        queueToEnqueue.enqueue(nextItem);\n        return overflowItems[nextItem];\n    };\n    const groupManager = createGroupManager();\n    function compareItems(lt, rt) {\n        if (!lt || !rt) {\n            return 0;\n        }\n        const lte = overflowItems[lt];\n        const rte = overflowItems[rt];\n        if (lte.priority !== rte.priority) {\n            return lte.priority > rte.priority ? 1 : -1;\n        }\n        const positionStatusBit = options.overflowDirection === 'end' ? Node.DOCUMENT_POSITION_FOLLOWING : Node.DOCUMENT_POSITION_PRECEDING;\n        // eslint-disable-next-line no-bitwise\n        return lte.element.compareDocumentPosition(rte.element) & positionStatusBit ? 1 : -1;\n    }\n    function getElementAxisSize(horizontal, vertical, el) {\n        if (!sizeCache.has(el)) {\n            sizeCache.set(el, options.overflowAxis === 'horizontal' ? el[horizontal] : el[vertical]);\n        }\n        return sizeCache.get(el);\n    }\n    const getOffsetSize = getElementAxisSize.bind(null, 'offsetWidth', 'offsetHeight');\n    const getClientSize = getElementAxisSize.bind(null, 'clientWidth', 'clientHeight');\n    const invisibleItemQueue = createPriorityQueue((a, b)=>-1 * compareItems(a, b));\n    const visibleItemQueue = createPriorityQueue(compareItems);\n    function occupiedSize() {\n        const totalItemSize = visibleItemQueue.all().map((id)=>overflowItems[id].element).map(getOffsetSize).reduce((prev, current)=>prev + current, 0);\n        const totalDividerSize = Object.entries(groupManager.groupVisibility()).reduce((acc, [id, state])=>acc + (state !== 'hidden' && overflowDividers[id] ? getOffsetSize(overflowDividers[id].element) : 0), 0);\n        const overflowMenuSize = invisibleItemQueue.size() > 0 && overflowMenu ? getOffsetSize(overflowMenu) : 0;\n        return totalItemSize + totalDividerSize + overflowMenuSize;\n    }\n    const showItem = ()=>{\n        const item = getNextItem(invisibleItemQueue, visibleItemQueue);\n        options.onUpdateItemVisibility({\n            item,\n            visible: true\n        });\n        if (item.groupId) {\n            groupManager.showItem(item.id, item.groupId);\n            if (groupManager.isSingleItemVisible(item.id, item.groupId)) {\n                var _overflowDividers_item_groupId;\n                (_overflowDividers_item_groupId = overflowDividers[item.groupId]) === null || _overflowDividers_item_groupId === void 0 ? void 0 : _overflowDividers_item_groupId.element.removeAttribute(DATA_OVERFLOWING);\n            }\n        }\n    };\n    const hideItem = ()=>{\n        const item = getNextItem(visibleItemQueue, invisibleItemQueue);\n        options.onUpdateItemVisibility({\n            item,\n            visible: false\n        });\n        if (item.groupId) {\n            if (groupManager.isSingleItemVisible(item.id, item.groupId)) {\n                var _overflowDividers_item_groupId;\n                (_overflowDividers_item_groupId = overflowDividers[item.groupId]) === null || _overflowDividers_item_groupId === void 0 ? void 0 : _overflowDividers_item_groupId.element.setAttribute(DATA_OVERFLOWING, '');\n            }\n            groupManager.hideItem(item.id, item.groupId);\n        }\n    };\n    const dispatchOverflowUpdate = ()=>{\n        const visibleItemIds = visibleItemQueue.all();\n        const invisibleItemIds = invisibleItemQueue.all();\n        const visibleItems = visibleItemIds.map((itemId)=>overflowItems[itemId]);\n        const invisibleItems = invisibleItemIds.map((itemId)=>overflowItems[itemId]);\n        options.onUpdateOverflow({\n            visibleItems,\n            invisibleItems,\n            groupVisibility: groupManager.groupVisibility()\n        });\n    };\n    const processOverflowItems = ()=>{\n        if (!container) {\n            return false;\n        }\n        sizeCache.clear();\n        const availableSize = getClientSize(container) - options.padding;\n        // Snapshot of the visible/invisible state to compare for updates\n        const visibleTop = visibleItemQueue.peek();\n        const invisibleTop = invisibleItemQueue.peek();\n        while(compareItems(invisibleItemQueue.peek(), visibleItemQueue.peek()) > 0){\n            hideItem(); // hide elements whose priority become smaller than the highest priority of the hidden one\n        }\n        // Run the show/hide step twice - the first step might not be correct if\n        // it was triggered by a new item being added - new items are always visible by default.\n        for(let i = 0; i < 2; i++){\n            // Add items until available width is filled - can result in overflow\n            while(occupiedSize() < availableSize && invisibleItemQueue.size() > 0 || invisibleItemQueue.size() === 1 // attempt to show the last invisible item hoping it's size does not exceed overflow menu size\n            ){\n                showItem();\n            }\n            // Remove items until there's no more overflow\n            while(occupiedSize() > availableSize && visibleItemQueue.size() > options.minimumVisible){\n                hideItem();\n            }\n        }\n        // only update when the state of visible/invisible items has changed\n        return visibleItemQueue.peek() !== visibleTop || invisibleItemQueue.peek() !== invisibleTop;\n    };\n    const forceUpdate = ()=>{\n        if (processOverflowItems() || forceDispatch) {\n            forceDispatch = false;\n            dispatchOverflowUpdate();\n        }\n    };\n    const update = debounce(forceUpdate);\n    const observe = (observedContainer, userOptions)=>{\n        Object.assign(options, userOptions);\n        observing = true;\n        Object.values(overflowItems).forEach((item)=>visibleItemQueue.enqueue(item.id));\n        container = observedContainer;\n        disposeResizeObserver = observeResize(container, (entries)=>{\n            if (!entries[0] || !container) {\n                return;\n            }\n            update();\n        });\n    };\n    const addItem = (item)=>{\n        if (overflowItems[item.id]) {\n            return;\n        }\n        overflowItems[item.id] = item;\n        // some options can affect priority which are only set on `observe`\n        if (observing) {\n            // Updates to elements might not change the queue tops\n            // i.e. new element is enqueued but the top of the queue stays the same\n            // force a dispatch on the next batched update\n            forceDispatch = true;\n            visibleItemQueue.enqueue(item.id);\n        }\n        if (item.groupId) {\n            groupManager.addItem(item.id, item.groupId);\n            item.element.setAttribute(DATA_OVERFLOW_GROUP, item.groupId);\n        }\n        update();\n    };\n    const addOverflowMenu = (el)=>{\n        overflowMenu = el;\n    };\n    const addDivider = (divider)=>{\n        if (!divider.groupId || overflowDividers[divider.groupId]) {\n            return;\n        }\n        divider.element.setAttribute(DATA_OVERFLOW_GROUP, divider.groupId);\n        overflowDividers[divider.groupId] = divider;\n    };\n    const removeOverflowMenu = ()=>{\n        overflowMenu = undefined;\n    };\n    const removeDivider = (groupId)=>{\n        if (!overflowDividers[groupId]) {\n            return;\n        }\n        const divider = overflowDividers[groupId];\n        if (divider.groupId) {\n            delete overflowDividers[groupId];\n            divider.element.removeAttribute(DATA_OVERFLOW_GROUP);\n        }\n    };\n    const removeItem = (itemId)=>{\n        if (!overflowItems[itemId]) {\n            return;\n        }\n        const item = overflowItems[itemId];\n        visibleItemQueue.remove(itemId);\n        invisibleItemQueue.remove(itemId);\n        if (item.groupId) {\n            groupManager.removeItem(item.id, item.groupId);\n            item.element.removeAttribute(DATA_OVERFLOW_GROUP);\n        }\n        sizeCache.delete(item.element);\n        delete overflowItems[itemId];\n        update();\n    };\n    const disconnect = ()=>{\n        disposeResizeObserver();\n        // reset flags\n        container = undefined;\n        observing = false;\n        forceDispatch = true;\n        // clear all entries\n        Object.keys(overflowItems).forEach((itemId)=>removeItem(itemId));\n        Object.keys(overflowDividers).forEach((dividerId)=>removeDivider(dividerId));\n        removeOverflowMenu();\n        sizeCache.clear();\n    };\n    return {\n        addItem,\n        disconnect,\n        forceUpdate,\n        observe,\n        removeItem,\n        update,\n        addOverflowMenu,\n        removeOverflowMenu,\n        addDivider,\n        removeDivider\n    };\n}\nconst createGroupManager = ()=>{\n    const groupVisibility = {};\n    const groups = {};\n    function updateGroupVisibility(groupId) {\n        const group = groups[groupId];\n        if (group.invisibleItemIds.size && group.visibleItemIds.size) {\n            groupVisibility[groupId] = 'overflow';\n        } else if (group.visibleItemIds.size === 0) {\n            groupVisibility[groupId] = 'hidden';\n        } else {\n            groupVisibility[groupId] = 'visible';\n        }\n    }\n    function isGroupVisible(groupId) {\n        return groupVisibility[groupId] === 'visible' || groupVisibility[groupId] === 'overflow';\n    }\n    return {\n        groupVisibility: ()=>groupVisibility,\n        isSingleItemVisible (itemId, groupId) {\n            return isGroupVisible(groupId) && groups[groupId].visibleItemIds.has(itemId) && groups[groupId].visibleItemIds.size === 1;\n        },\n        addItem (itemId, groupId) {\n            var _groups, _groupId;\n            var _;\n            (_ = (_groups = groups)[_groupId = groupId]) !== null && _ !== void 0 ? _ : _groups[_groupId] = {\n                visibleItemIds: new Set(),\n                invisibleItemIds: new Set()\n            };\n            groups[groupId].visibleItemIds.add(itemId);\n            updateGroupVisibility(groupId);\n        },\n        removeItem (itemId, groupId) {\n            groups[groupId].invisibleItemIds.delete(itemId);\n            groups[groupId].visibleItemIds.delete(itemId);\n            updateGroupVisibility(groupId);\n        },\n        showItem (itemId, groupId) {\n            groups[groupId].invisibleItemIds.delete(itemId);\n            groups[groupId].visibleItemIds.add(itemId);\n            updateGroupVisibility(groupId);\n        },\n        hideItem (itemId, groupId) {\n            groups[groupId].invisibleItemIds.add(itemId);\n            groups[groupId].visibleItemIds.delete(itemId);\n            updateGroupVisibility(groupId);\n        }\n    };\n};\n","/**\n * Microtask debouncer\n * https://developer.mozilla.org/en-US/docs/Web/API/HTML_DOM_API/Microtask_guide\n * @param fn - Function to debounce\n * @returns debounced function\n */ export function debounce(fn) {\n    let pending;\n    // React testing platforms will often output errors when state updates happen outside `act`\n    // Since there is nothing obvious to wait for we just avoid debouncing in unit test environments\n    if (process.env.NODE_ENV === 'test') {\n        return fn;\n    }\n    return ()=>{\n        if (!pending) {\n            pending = true;\n            queueMicrotask(()=>{\n                // Need to set pending to `false` before the debounced function is run.\n                // React can actually interrupt the function while it's running!\n                pending = false;\n                fn();\n            });\n        }\n    };\n}\n","/**\n * Helper function that creates a resize observer in the element's own window global\n * @param elementToObserve - Uses the element's window global to create the resize observer\n * @param callback\n * @returns function to cleanup the resize observer\n */ export function observeResize(elementToObserve, callback) {\n    var _elementToObserve_ownerDocument_defaultView;\n    const GlobalResizeObsever = (_elementToObserve_ownerDocument_defaultView = elementToObserve.ownerDocument.defaultView) === null || _elementToObserve_ownerDocument_defaultView === void 0 ? void 0 : _elementToObserve_ownerDocument_defaultView.ResizeObserver;\n    if (!GlobalResizeObsever) {\n        if (process.env.NODE_ENV !== 'production') {\n            // eslint-disable-next-line no-console\n            console.error('@fluentui/priority-overflow', 'ResizeObserver does not exist on container window');\n        }\n        return ()=>null;\n    }\n    let resizeObserver = new GlobalResizeObsever(callback);\n    resizeObserver.observe(elementToObserve);\n    return ()=>{\n        resizeObserver === null || resizeObserver === void 0 ? void 0 : resizeObserver.disconnect();\n        resizeObserver = undefined;\n    };\n}\n"],"names":["setRTL","isRTL","_rtl","getRTL","undefined","document","documentElement","getAttribute","_stylesheet","InjectionMode","STYLESHEET_SETTING","REUSE_STYLE_NODE","navigator","test","userAgent","_global","window","_a","Stylesheet","config","serializedStylesheet","_b","_c","_d","_e","_f","this","_rules","_preservedRules","_counter","_keyToClassName","_onInsertRuleCallbacks","_onResetCallbacks","_classNameToArgs","_config","injectionMode","defaultPrefix","namespace","cspSettings","classNameToArgs","counter","classNameCache","keyToClassName","preservedRules","rules","getInstance","_lastStyleElement","ownerDocument","fabricConfig","FabricConfig","stylesheet","mergeStyles","prototype","serialize","JSON","stringify","setConfig","onReset","callback","_this","push","filter","cb","onInsertRule","getClassName","displayName","cacheClassName","className","key","args","classNameFromKey","getClassNameCache","argsFromClassName","entry","insertedRulesFromClassName","insertRule","rule","preserve","element","_getStyleElement","sheet","cssRules","length","e","appendChild","createTextNode","forEach","getRules","includePreservedRules","join","reset","resetKeys","_styleElement","_createStyleElement","requestAnimationFrame","head","styleElement","createElement","nodeToInsertBefore","setAttribute","nonce","nextElementSibling","placeholderStyleTag","_findPlaceholderStyleTag","childNodes","insertBefore","contains","querySelector","_vendorSettings","kebabRules","rulePairs","index","charAt","replace","toLowerCase","autoPrefixNames","prefixRules","vendorSettings","doc","nav","isWebkit","style","isMoz","indexOf","isOpera","isMs","getVendorSettings","name","value","NON_PIXEL_NUMBER_PROPS","provideUnits","isNonPixelProp","isVariableOrPrefixed","unit","LEFT","RIGHT","NO_FLIP","NAME_REPLACEMENTS","VALUE_REPLACEMENTS","rtlifyRules","options","rtl","name_1","String","parts","split","flipQuad","partIndex","numberVal","parseInt","negateNum","DISPLAY_NAME","globalSelectorRegExp","expandSelector","newSelector","currentSelector","extractSelector","selector","__order","extractRules","selectorWithGlobals","replacementInfo","findGlobal","match","exec","map","v","trim","reverse","reduce","matchIndex","matchEndIndex","replacement","slice","expandCommaSeparatedGlobals","s","separatedSelector","currentRules","_i","args_1","arg","expandedRules","Array","isArray","prop","hasOwnProperty","propValue","selectors","expandQuads","partStart","parens","i","substring","tokenizeWithParentheses","p","repeatString","target","count","serializeRuleEntries","ruleEntries","allEntries","splice","styleToRegistration","arguments","serialized","hasProps","rulesForSelector","propName","getKeyForRules","registration","rootStyle","getDisplayName","rulesToInsert","styleToClassName","apply","specificityMultiplier","processedRule","applyRegistration","mergeCss","classes","objects","_processArgs","argsList","argsList_1","translatedArgs","extractStyleParts","getStyleOptions","shadowConfig","none","insertNode","prefix","concat","_getCacheKey","stylesheetKey","_insertRuleIntoSheet","concatStyleSets","styleSets","subComponentStyles","mergedSet","workingSubcomponentStyles","styleSets_1","currentSet","currentComponentStyles","subCompProp","mergedValue","currentValue","Object","keys","mergedSubStyles","_loop_1","workingSet_1","styleProps","styleFunctionOrObject","concatStyleSetsWithProps","allStyles","result","allStyles_1","styles","fontFace","font","keyframes","timeline","rulesArray","mergeStyleSets","mergeCssSets","styleSet","classNameSet","opts","concatenatedStyleSet","registrations","styleSetArea","registrations_1","styleArgs","GLOBAL_STYLESHEET_KEY","SHADOW_DOM_STYLESHEET_SETTING","DEFAULT_SHADOW_CONFIG","inShadow","__isShadowConfig__","makeShadowConfig","isShadowConfig","isRecord","potentialSelector","DATA_OVERFLOWING","DATA_OVERFLOW_GROUP","createPriorityQueue","compare","arr","size","parent","Math","floor","swap","a","b","tmp","heapify","smallest","l","left","r","right","all","clear","item","dequeue","Error","res","enqueue","peek","remove","createOverflowManager","sizeCache","Map","container","overflowMenu","observing","forceDispatch","padding","overflowAxis","overflowDirection","minimumVisible","onUpdateItemVisibility","onUpdateOverflow","overflowItems","overflowDividers","disposeResizeObserver","getNextItem","queueToDequeue","queueToEnqueue","nextItem","groupManager","createGroupManager","compareItems","lt","rt","lte","rte","priority","positionStatusBit","Node","DOCUMENT_POSITION_FOLLOWING","DOCUMENT_POSITION_PRECEDING","compareDocumentPosition","getElementAxisSize","horizontal","vertical","el","has","set","get","getOffsetSize","bind","getClientSize","invisibleItemQueue","visibleItemQueue","occupiedSize","id","prev","current","entries","groupVisibility","acc","state","showItem","_overflowDividers_item_groupId","visible","groupId","isSingleItemVisible","removeAttribute","hideItem","forceUpdate","availableSize","visibleTop","invisibleTop","processOverflowItems","visibleItemIds","invisibleItemIds","visibleItems","itemId","invisibleItems","dispatchOverflowUpdate","update","fn","pending","queueMicrotask","debounce","removeOverflowMenu","removeDivider","divider","removeItem","delete","addItem","disconnect","dividerId","observe","observedContainer","userOptions","assign","values","elementToObserve","_elementToObserve_ownerDocument_defaultView","GlobalResizeObsever","defaultView","ResizeObserver","resizeObserver","observeResize","addOverflowMenu","addDivider","groups","updateGroupVisibility","group","isGroupVisible","_groups","_groupId","_","Set","add"],"sourceRoot":""}