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IAAK7gB,KAAKmf,kBAAmBqB,EAAAA,EAAAA,GAAE,MAAO,CAAEI,MAAO7E,EAAW8E,IAAMrK,GAAaxW,KAAKwW,QAAUA,KAAagK,EAAAA,EAAAA,GAAE,MAAO,CAAEI,MAAO7E,IAAiByE,EAAAA,EAAAA,GAAE,OAAQ,QAC5J,CACG/O,SAAO,OAAOzR,IAAO,CACd8gB,sBAAa,MAAO,CAC7B,eAAkB,CAAC,+BACnB,eAAkB,CAAC,yBACnB,KAAQ,CAAC,eACT,mBAAsB,CAAC,6BACvB,UAAa,CAAC,oBACd,iBAAoB,CAAC,2BACnB,CACO5H,mBAAU,MA7KJ,sgHA6KwB,GACxC,CAAC,EAAG,kBAAmB,CACtB,aAAgB,CAAC,IAAK,kBACtB,MAAS,CAAC,GACV,eAAkB,CAAC,IAAK,mBACxB,eAAkB,CAAC,IAAK,mBACxB,KAAQ,CAAC,KACT,mBAAsB,CAAC,IAAK,uBAC5B,UAAa,CAAC,KACd,iBAAoB,CAAC,EAAG,qBACxB,0BAA6B,CAAC,IAC9B,WAAc,CAAC,OAEnB,SAAS6H,IACP,GAA8B,qBAAnBC,eACT,OAEiB,CAAC,mBACT7N,SAAQ4E,IAAa,GACzB,oBADiCA,EAE/BiJ,eAAexP,IAAIuG,IACtBiJ,eAAeC,OAAOlJ,EAASwG,EAHL,GAOjC,CACDwC","sources":["../node_modules/@arcgis/core/node_modules/@esri/calcite-components/dist/components/debounce.js","../node_modules/@arcgis/core/node_modules/@esri/calcite-components/dist/components/floating-ui.js","../node_modules/@arcgis/core/node_modules/@esri/calcite-components/dist/components/openCloseComponent.js","../node_modules/@arcgis/core/node_modules/@esri/calcite-components/dist/components/tooltip.js"],"sourcesContent":["/*!\n * All material copyright ESRI, All Rights Reserved, unless otherwise specified.\n * See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.\n * v1.0.8-next.4\n */\n/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\n/** Used for built-in method references. */\nvar objectProto$1 = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto$1.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString$1 = objectProto$1.toString;\n\n/** Built-in value references. */\nvar symToStringTag$1 = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag$1),\n tag = value[symToStringTag$1];\n\n try {\n value[symToStringTag$1] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString$1.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag$1] = tag;\n } else {\n delete value[symToStringTag$1];\n }\n }\n return result;\n}\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\n/** Used to match a single whitespace character. */\nvar reWhitespace = /\\s/;\n\n/**\n * Used by `_.trim` and `_.trimEnd` to get the index of the last non-whitespace\n * character of `string`.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {number} Returns the index of the last non-whitespace character.\n */\nfunction trimmedEndIndex(string) {\n var index = string.length;\n\n while (index-- && reWhitespace.test(string.charAt(index))) {}\n return index;\n}\n\n/** Used to match leading whitespace. */\nvar reTrimStart = /^\\s+/;\n\n/**\n * The base implementation of `_.trim`.\n *\n * @private\n * @param {string} string The string to trim.\n * @returns {string} Returns the trimmed string.\n */\nfunction baseTrim(string) {\n return string\n ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, '')\n : string;\n}\n\n/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** Used to detect bad signed hexadecimal string values. */\nvar reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n/** Used to detect binary string values. */\nvar reIsBinary = /^0b[01]+$/i;\n\n/** Used to detect octal string values. */\nvar reIsOctal = /^0o[0-7]+$/i;\n\n/** Built-in method references without a dependency on `root`. */\nvar freeParseInt = parseInt;\n\n/**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\nfunction toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = baseTrim(value);\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n}\n\n/**\n * Gets the timestamp of the number of milliseconds that have elapsed since\n * the Unix epoch (1 January 1970 00:00:00 UTC).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Date\n * @returns {number} Returns the timestamp.\n * @example\n *\n * _.defer(function(stamp) {\n * console.log(_.now() - stamp);\n * }, _.now());\n * // => Logs the number of milliseconds it took for the deferred invocation.\n */\nvar now = function() {\n return root.Date.now();\n};\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeMax = Math.max,\n nativeMin = Math.min;\n\n/**\n * Creates a debounced function that delays invoking `func` until after `wait`\n * milliseconds have elapsed since the last time the debounced function was\n * invoked. The debounced function comes with a `cancel` method to cancel\n * delayed `func` invocations and a `flush` method to immediately invoke them.\n * Provide `options` to indicate whether `func` should be invoked on the\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\n * with the last arguments provided to the debounced function. Subsequent\n * calls to the debounced function return the result of the last `func`\n * invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the debounced function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.debounce` and `_.throttle`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to debounce.\n * @param {number} [wait=0] The number of milliseconds to delay.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=false]\n * Specify invoking on the leading edge of the timeout.\n * @param {number} [options.maxWait]\n * The maximum time `func` is allowed to be delayed before it's invoked.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new debounced function.\n * @example\n *\n * // Avoid costly calculations while the window size is in flux.\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\n *\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\n * 'leading': true,\n * 'trailing': false\n * }));\n *\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\n * var source = new EventSource('/stream');\n * jQuery(source).on('message', debounced);\n *\n * // Cancel the trailing debounced invocation.\n * jQuery(window).on('popstate', debounced.cancel);\n */\nfunction debounce(func, wait, options) {\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = toNumber(wait) || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n timeWaiting = wait - timeSinceLastCall;\n\n return maxing\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\n : timeWaiting;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n clearTimeout(timerId);\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n}\n\nexport { Symbol as S, isSymbol as a, baseGetTag as b, isObjectLike as c, debounce as d, freeGlobal as f, isObject as i, root as r };\n","/*!\n * All material copyright ESRI, All Rights Reserved, unless otherwise specified.\n * See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.\n * v1.0.8-next.4\n */\nimport { Build } from '@stencil/core/internal/client/index.js';\nimport { c as getElementDir, r as closestElementCrossShadowBoundary } from './dom.js';\nimport { d as debounce } from './debounce.js';\n\nfunction getAlignment(placement) {\n return placement.split('-')[1];\n}\n\nfunction getLengthFromAxis(axis) {\n return axis === 'y' ? 'height' : 'width';\n}\n\nfunction getSide(placement) {\n return placement.split('-')[0];\n}\n\nfunction getMainAxisFromPlacement(placement) {\n return ['top', 'bottom'].includes(getSide(placement)) ? 'x' : 'y';\n}\n\nfunction computeCoordsFromPlacement(_ref, placement, rtl) {\n let {\n reference,\n floating\n } = _ref;\n const commonX = reference.x + reference.width / 2 - floating.width / 2;\n const commonY = reference.y + reference.height / 2 - floating.height / 2;\n const mainAxis = getMainAxisFromPlacement(placement);\n const length = getLengthFromAxis(mainAxis);\n const commonAlign = reference[length] / 2 - floating[length] / 2;\n const side = getSide(placement);\n const isVertical = mainAxis === 'x';\n let coords;\n switch (side) {\n case 'top':\n coords = {\n x: commonX,\n y: reference.y - floating.height\n };\n break;\n case 'bottom':\n coords = {\n x: commonX,\n y: reference.y + reference.height\n };\n break;\n case 'right':\n coords = {\n x: reference.x + reference.width,\n y: commonY\n };\n break;\n case 'left':\n coords = {\n x: reference.x - floating.width,\n y: commonY\n };\n break;\n default:\n coords = {\n x: reference.x,\n y: reference.y\n };\n }\n switch (getAlignment(placement)) {\n case 'start':\n coords[mainAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);\n break;\n case 'end':\n coords[mainAxis] += commonAlign * (rtl && isVertical ? -1 : 1);\n break;\n }\n return coords;\n}\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a reference element when it is given a certain positioning strategy.\n *\n * This export does not have any `platform` interface logic. You will need to\n * write one for the platform you are using Floating UI with.\n */\nconst computePosition$1 = async (reference, floating, config) => {\n const {\n placement = 'bottom',\n strategy = 'absolute',\n middleware = [],\n platform\n } = config;\n const validMiddleware = middleware.filter(Boolean);\n const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));\n let rects = await platform.getElementRects({\n reference,\n floating,\n strategy\n });\n let {\n x,\n y\n } = computeCoordsFromPlacement(rects, placement, rtl);\n let statefulPlacement = placement;\n let middlewareData = {};\n let resetCount = 0;\n for (let i = 0; i < validMiddleware.length; i++) {\n const {\n name,\n fn\n } = validMiddleware[i];\n const {\n x: nextX,\n y: nextY,\n data,\n reset\n } = await fn({\n x,\n y,\n initialPlacement: placement,\n placement: statefulPlacement,\n strategy,\n middlewareData,\n rects,\n platform,\n elements: {\n reference,\n floating\n }\n });\n x = nextX != null ? nextX : x;\n y = nextY != null ? nextY : y;\n middlewareData = {\n ...middlewareData,\n [name]: {\n ...middlewareData[name],\n ...data\n }\n };\n if (reset && resetCount <= 50) {\n resetCount++;\n if (typeof reset === 'object') {\n if (reset.placement) {\n statefulPlacement = reset.placement;\n }\n if (reset.rects) {\n rects = reset.rects === true ? await platform.getElementRects({\n reference,\n floating,\n strategy\n }) : reset.rects;\n }\n ({\n x,\n y\n } = computeCoordsFromPlacement(rects, statefulPlacement, rtl));\n }\n i = -1;\n continue;\n }\n }\n return {\n x,\n y,\n placement: statefulPlacement,\n strategy,\n middlewareData\n };\n};\n\nfunction expandPaddingObject(padding) {\n return {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0,\n ...padding\n };\n}\n\nfunction getSideObjectFromPadding(padding) {\n return typeof padding !== 'number' ? expandPaddingObject(padding) : {\n top: padding,\n right: padding,\n bottom: padding,\n left: padding\n };\n}\n\nfunction rectToClientRect(rect) {\n return {\n ...rect,\n top: rect.y,\n left: rect.x,\n right: rect.x + rect.width,\n bottom: rect.y + rect.height\n };\n}\n\n/**\n * Resolves with an object of overflow side offsets that determine how much the\n * element is overflowing a given clipping boundary on each side.\n * - positive = overflowing the boundary by that number of pixels\n * - negative = how many pixels left before it will overflow\n * - 0 = lies flush with the boundary\n * @see https://floating-ui.com/docs/detectOverflow\n */\nasync function detectOverflow(state, options) {\n var _await$platform$isEle;\n if (options === void 0) {\n options = {};\n }\n const {\n x,\n y,\n platform,\n rects,\n elements,\n strategy\n } = state;\n const {\n boundary = 'clippingAncestors',\n rootBoundary = 'viewport',\n elementContext = 'floating',\n altBoundary = false,\n padding = 0\n } = options;\n const paddingObject = getSideObjectFromPadding(padding);\n const altContext = elementContext === 'floating' ? 'reference' : 'floating';\n const element = elements[altBoundary ? altContext : elementContext];\n const clippingClientRect = rectToClientRect(await platform.getClippingRect({\n element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || (await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating))),\n boundary,\n rootBoundary,\n strategy\n }));\n const rect = elementContext === 'floating' ? {\n ...rects.floating,\n x,\n y\n } : rects.reference;\n const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));\n const offsetScale = (await (platform.isElement == null ? void 0 : platform.isElement(offsetParent))) ? (await (platform.getScale == null ? void 0 : platform.getScale(offsetParent))) || {\n x: 1,\n y: 1\n } : {\n x: 1,\n y: 1\n };\n const elementClientRect = rectToClientRect(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({\n rect,\n offsetParent,\n strategy\n }) : rect);\n return {\n top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,\n bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,\n left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,\n right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x\n };\n}\n\nconst min$1 = Math.min;\nconst max$1 = Math.max;\n\nfunction within(min$1$1, value, max$1$1) {\n return max$1(min$1$1, min$1(value, max$1$1));\n}\n\n/**\n * Provides data to position an inner element of the floating element so that it\n * appears centered to the reference element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = options => ({\n name: 'arrow',\n options,\n async fn(state) {\n // Since `element` is required, we don't Partial<> the type.\n const {\n element,\n padding = 0\n } = options || {};\n const {\n x,\n y,\n placement,\n rects,\n platform\n } = state;\n if (element == null) {\n return {};\n }\n const paddingObject = getSideObjectFromPadding(padding);\n const coords = {\n x,\n y\n };\n const axis = getMainAxisFromPlacement(placement);\n const length = getLengthFromAxis(axis);\n const arrowDimensions = await platform.getDimensions(element);\n const minProp = axis === 'y' ? 'top' : 'left';\n const maxProp = axis === 'y' ? 'bottom' : 'right';\n const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];\n const startDiff = coords[axis] - rects.reference[axis];\n const arrowOffsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(element));\n let clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0;\n if (clientSize === 0) {\n clientSize = rects.floating[length];\n }\n const centerToReference = endDiff / 2 - startDiff / 2;\n\n // Make sure the arrow doesn't overflow the floating element if the center\n // point is outside the floating element's bounds.\n const min = paddingObject[minProp];\n const max = clientSize - arrowDimensions[length] - paddingObject[maxProp];\n const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;\n const offset = within(min, center, max);\n\n // If the reference is small enough that the arrow's padding causes it to\n // to point to nothing for an aligned placement, adjust the offset of the\n // floating element itself. This stops `shift()` from taking action, but can\n // be worked around by calling it again after the `arrow()` if desired.\n const shouldAddOffset = getAlignment(placement) != null && center != offset && rects.reference[length] / 2 - (center < min ? paddingObject[minProp] : paddingObject[maxProp]) - arrowDimensions[length] / 2 < 0;\n const alignmentOffset = shouldAddOffset ? center < min ? min - center : max - center : 0;\n return {\n [axis]: coords[axis] - alignmentOffset,\n data: {\n [axis]: offset,\n centerOffset: center - offset\n }\n };\n }\n});\n\nconst sides = ['top', 'right', 'bottom', 'left'];\nconst allPlacements = /*#__PURE__*/sides.reduce((acc, side) => acc.concat(side, side + \"-start\", side + \"-end\"), []);\n\nconst oppositeSideMap = {\n left: 'right',\n right: 'left',\n bottom: 'top',\n top: 'bottom'\n};\nfunction getOppositePlacement(placement) {\n return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);\n}\n\nfunction getAlignmentSides(placement, rects, rtl) {\n if (rtl === void 0) {\n rtl = false;\n }\n const alignment = getAlignment(placement);\n const mainAxis = getMainAxisFromPlacement(placement);\n const length = getLengthFromAxis(mainAxis);\n let mainAlignmentSide = mainAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';\n if (rects.reference[length] > rects.floating[length]) {\n mainAlignmentSide = getOppositePlacement(mainAlignmentSide);\n }\n return {\n main: mainAlignmentSide,\n cross: getOppositePlacement(mainAlignmentSide)\n };\n}\n\nconst oppositeAlignmentMap = {\n start: 'end',\n end: 'start'\n};\nfunction getOppositeAlignmentPlacement(placement) {\n return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);\n}\n\nfunction getPlacementList(alignment, autoAlignment, allowedPlacements) {\n const allowedPlacementsSortedByAlignment = alignment ? [...allowedPlacements.filter(placement => getAlignment(placement) === alignment), ...allowedPlacements.filter(placement => getAlignment(placement) !== alignment)] : allowedPlacements.filter(placement => getSide(placement) === placement);\n return allowedPlacementsSortedByAlignment.filter(placement => {\n if (alignment) {\n return getAlignment(placement) === alignment || (autoAlignment ? getOppositeAlignmentPlacement(placement) !== placement : false);\n }\n return true;\n });\n}\n/**\n * Optimizes the visibility of the floating element by choosing the placement\n * that has the most space available automatically, without needing to specify a\n * preferred placement. Alternative to `flip`.\n * @see https://floating-ui.com/docs/autoPlacement\n */\nconst autoPlacement = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'autoPlacement',\n options,\n async fn(state) {\n var _middlewareData$autoP, _middlewareData$autoP2, _placementsThatFitOnE;\n const {\n rects,\n middlewareData,\n placement,\n platform,\n elements\n } = state;\n const {\n crossAxis = false,\n alignment,\n allowedPlacements = allPlacements,\n autoAlignment = true,\n ...detectOverflowOptions\n } = options;\n const placements = alignment !== undefined || allowedPlacements === allPlacements ? getPlacementList(alignment || null, autoAlignment, allowedPlacements) : allowedPlacements;\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const currentIndex = ((_middlewareData$autoP = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP.index) || 0;\n const currentPlacement = placements[currentIndex];\n if (currentPlacement == null) {\n return {};\n }\n const {\n main,\n cross\n } = getAlignmentSides(currentPlacement, rects, await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating)));\n\n // Make `computeCoords` start from the right place.\n if (placement !== currentPlacement) {\n return {\n reset: {\n placement: placements[0]\n }\n };\n }\n const currentOverflows = [overflow[getSide(currentPlacement)], overflow[main], overflow[cross]];\n const allOverflows = [...(((_middlewareData$autoP2 = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP2.overflows) || []), {\n placement: currentPlacement,\n overflows: currentOverflows\n }];\n const nextPlacement = placements[currentIndex + 1];\n\n // There are more placements to check.\n if (nextPlacement) {\n return {\n data: {\n index: currentIndex + 1,\n overflows: allOverflows\n },\n reset: {\n placement: nextPlacement\n }\n };\n }\n const placementsSortedByMostSpace = allOverflows.map(d => {\n const alignment = getAlignment(d.placement);\n return [d.placement, alignment && crossAxis ?\n // Check along the mainAxis and main crossAxis side.\n d.overflows.slice(0, 2).reduce((acc, v) => acc + v, 0) :\n // Check only the mainAxis.\n d.overflows[0], d.overflows];\n }).sort((a, b) => a[1] - b[1]);\n const placementsThatFitOnEachSide = placementsSortedByMostSpace.filter(d => d[2].slice(0,\n // Aligned placements should not check their opposite crossAxis\n // side.\n getAlignment(d[0]) ? 2 : 3).every(v => v <= 0));\n const resetPlacement = ((_placementsThatFitOnE = placementsThatFitOnEachSide[0]) == null ? void 0 : _placementsThatFitOnE[0]) || placementsSortedByMostSpace[0][0];\n if (resetPlacement !== placement) {\n return {\n data: {\n index: currentIndex + 1,\n overflows: allOverflows\n },\n reset: {\n placement: resetPlacement\n }\n };\n }\n return {};\n }\n };\n};\n\nfunction getExpandedPlacements(placement) {\n const oppositePlacement = getOppositePlacement(placement);\n return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];\n}\n\nfunction getSideList(side, isStart, rtl) {\n const lr = ['left', 'right'];\n const rl = ['right', 'left'];\n const tb = ['top', 'bottom'];\n const bt = ['bottom', 'top'];\n switch (side) {\n case 'top':\n case 'bottom':\n if (rtl) return isStart ? rl : lr;\n return isStart ? lr : rl;\n case 'left':\n case 'right':\n return isStart ? tb : bt;\n default:\n return [];\n }\n}\nfunction getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {\n const alignment = getAlignment(placement);\n let list = getSideList(getSide(placement), direction === 'start', rtl);\n if (alignment) {\n list = list.map(side => side + \"-\" + alignment);\n if (flipAlignment) {\n list = list.concat(list.map(getOppositeAlignmentPlacement));\n }\n }\n return list;\n}\n\n/**\n * Optimizes the visibility of the floating element by flipping the `placement`\n * in order to keep it in view when the preferred placement(s) will overflow the\n * clipping boundary. Alternative to `autoPlacement`.\n * @see https://floating-ui.com/docs/flip\n */\nconst flip = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'flip',\n options,\n async fn(state) {\n var _middlewareData$flip;\n const {\n placement,\n middlewareData,\n rects,\n initialPlacement,\n platform,\n elements\n } = state;\n const {\n mainAxis: checkMainAxis = true,\n crossAxis: checkCrossAxis = true,\n fallbackPlacements: specifiedFallbackPlacements,\n fallbackStrategy = 'bestFit',\n fallbackAxisSideDirection = 'none',\n flipAlignment = true,\n ...detectOverflowOptions\n } = options;\n const side = getSide(placement);\n const isBasePlacement = getSide(initialPlacement) === initialPlacement;\n const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));\n const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));\n if (!specifiedFallbackPlacements && fallbackAxisSideDirection !== 'none') {\n fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));\n }\n const placements = [initialPlacement, ...fallbackPlacements];\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const overflows = [];\n let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];\n if (checkMainAxis) {\n overflows.push(overflow[side]);\n }\n if (checkCrossAxis) {\n const {\n main,\n cross\n } = getAlignmentSides(placement, rects, rtl);\n overflows.push(overflow[main], overflow[cross]);\n }\n overflowsData = [...overflowsData, {\n placement,\n overflows\n }];\n\n // One or more sides is overflowing.\n if (!overflows.every(side => side <= 0)) {\n var _middlewareData$flip2, _overflowsData$filter;\n const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;\n const nextPlacement = placements[nextIndex];\n if (nextPlacement) {\n // Try next placement and re-run the lifecycle.\n return {\n data: {\n index: nextIndex,\n overflows: overflowsData\n },\n reset: {\n placement: nextPlacement\n }\n };\n }\n\n // First, find the candidates that fit on the mainAxis side of overflow,\n // then find the placement that fits the best on the main crossAxis side.\n let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;\n\n // Otherwise fallback.\n if (!resetPlacement) {\n switch (fallbackStrategy) {\n case 'bestFit':\n {\n var _overflowsData$map$so;\n const placement = (_overflowsData$map$so = overflowsData.map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$map$so[0];\n if (placement) {\n resetPlacement = placement;\n }\n break;\n }\n case 'initialPlacement':\n resetPlacement = initialPlacement;\n break;\n }\n }\n if (placement !== resetPlacement) {\n return {\n reset: {\n placement: resetPlacement\n }\n };\n }\n }\n return {};\n }\n };\n};\n\nfunction getSideOffsets(overflow, rect) {\n return {\n top: overflow.top - rect.height,\n right: overflow.right - rect.width,\n bottom: overflow.bottom - rect.height,\n left: overflow.left - rect.width\n };\n}\nfunction isAnySideFullyClipped(overflow) {\n return sides.some(side => overflow[side] >= 0);\n}\n/**\n * Provides data to hide the floating element in applicable situations, such as\n * when it is not in the same clipping context as the reference element.\n * @see https://floating-ui.com/docs/hide\n */\nconst hide = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'hide',\n options,\n async fn(state) {\n const {\n strategy = 'referenceHidden',\n ...detectOverflowOptions\n } = options;\n const {\n rects\n } = state;\n switch (strategy) {\n case 'referenceHidden':\n {\n const overflow = await detectOverflow(state, {\n ...detectOverflowOptions,\n elementContext: 'reference'\n });\n const offsets = getSideOffsets(overflow, rects.reference);\n return {\n data: {\n referenceHiddenOffsets: offsets,\n referenceHidden: isAnySideFullyClipped(offsets)\n }\n };\n }\n case 'escaped':\n {\n const overflow = await detectOverflow(state, {\n ...detectOverflowOptions,\n altBoundary: true\n });\n const offsets = getSideOffsets(overflow, rects.floating);\n return {\n data: {\n escapedOffsets: offsets,\n escaped: isAnySideFullyClipped(offsets)\n }\n };\n }\n default:\n {\n return {};\n }\n }\n }\n };\n};\n\nasync function convertValueToCoords(state, value) {\n const {\n placement,\n platform,\n elements\n } = state;\n const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));\n const side = getSide(placement);\n const alignment = getAlignment(placement);\n const isVertical = getMainAxisFromPlacement(placement) === 'x';\n const mainAxisMulti = ['left', 'top'].includes(side) ? -1 : 1;\n const crossAxisMulti = rtl && isVertical ? -1 : 1;\n const rawValue = typeof value === 'function' ? value(state) : value;\n\n // eslint-disable-next-line prefer-const\n let {\n mainAxis,\n crossAxis,\n alignmentAxis\n } = typeof rawValue === 'number' ? {\n mainAxis: rawValue,\n crossAxis: 0,\n alignmentAxis: null\n } : {\n mainAxis: 0,\n crossAxis: 0,\n alignmentAxis: null,\n ...rawValue\n };\n if (alignment && typeof alignmentAxis === 'number') {\n crossAxis = alignment === 'end' ? alignmentAxis * -1 : alignmentAxis;\n }\n return isVertical ? {\n x: crossAxis * crossAxisMulti,\n y: mainAxis * mainAxisMulti\n } : {\n x: mainAxis * mainAxisMulti,\n y: crossAxis * crossAxisMulti\n };\n}\n\n/**\n * Modifies the placement by translating the floating element along the\n * specified axes.\n * A number (shorthand for `mainAxis` or distance), or an axes configuration\n * object may be passed.\n * @see https://floating-ui.com/docs/offset\n */\nconst offset = function (value) {\n if (value === void 0) {\n value = 0;\n }\n return {\n name: 'offset',\n options: value,\n async fn(state) {\n const {\n x,\n y\n } = state;\n const diffCoords = await convertValueToCoords(state, value);\n return {\n x: x + diffCoords.x,\n y: y + diffCoords.y,\n data: diffCoords\n };\n }\n };\n};\n\nfunction getCrossAxis(axis) {\n return axis === 'x' ? 'y' : 'x';\n}\n\n/**\n * Optimizes the visibility of the floating element by shifting it in order to\n * keep it in view when it will overflow the clipping boundary.\n * @see https://floating-ui.com/docs/shift\n */\nconst shift = function (options) {\n if (options === void 0) {\n options = {};\n }\n return {\n name: 'shift',\n options,\n async fn(state) {\n const {\n x,\n y,\n placement\n } = state;\n const {\n mainAxis: checkMainAxis = true,\n crossAxis: checkCrossAxis = false,\n limiter = {\n fn: _ref => {\n let {\n x,\n y\n } = _ref;\n return {\n x,\n y\n };\n }\n },\n ...detectOverflowOptions\n } = options;\n const coords = {\n x,\n y\n };\n const overflow = await detectOverflow(state, detectOverflowOptions);\n const mainAxis = getMainAxisFromPlacement(getSide(placement));\n const crossAxis = getCrossAxis(mainAxis);\n let mainAxisCoord = coords[mainAxis];\n let crossAxisCoord = coords[crossAxis];\n if (checkMainAxis) {\n const minSide = mainAxis === 'y' ? 'top' : 'left';\n const maxSide = mainAxis === 'y' ? 'bottom' : 'right';\n const min = mainAxisCoord + overflow[minSide];\n const max = mainAxisCoord - overflow[maxSide];\n mainAxisCoord = within(min, mainAxisCoord, max);\n }\n if (checkCrossAxis) {\n const minSide = crossAxis === 'y' ? 'top' : 'left';\n const maxSide = crossAxis === 'y' ? 'bottom' : 'right';\n const min = crossAxisCoord + overflow[minSide];\n const max = crossAxisCoord - overflow[maxSide];\n crossAxisCoord = within(min, crossAxisCoord, max);\n }\n const limitedCoords = limiter.fn({\n ...state,\n [mainAxis]: mainAxisCoord,\n [crossAxis]: crossAxisCoord\n });\n return {\n ...limitedCoords,\n data: {\n x: limitedCoords.x - x,\n y: limitedCoords.y - y\n }\n };\n }\n };\n};\n\nfunction getWindow(node) {\n var _node$ownerDocument;\n return ((_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;\n}\n\nfunction getComputedStyle$1(element) {\n return getWindow(element).getComputedStyle(element);\n}\n\nconst min = Math.min;\nconst max = Math.max;\nconst round = Math.round;\n\nfunction getCssDimensions(element) {\n const css = getComputedStyle$1(element);\n let width = parseFloat(css.width);\n let height = parseFloat(css.height);\n const offsetWidth = element.offsetWidth;\n const offsetHeight = element.offsetHeight;\n const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;\n if (shouldFallback) {\n width = offsetWidth;\n height = offsetHeight;\n }\n return {\n width,\n height,\n fallback: shouldFallback\n };\n}\n\nfunction getNodeName(node) {\n return isNode(node) ? (node.nodeName || '').toLowerCase() : '';\n}\n\nlet uaString;\nfunction getUAString() {\n if (uaString) {\n return uaString;\n }\n const uaData = navigator.userAgentData;\n if (uaData && Array.isArray(uaData.brands)) {\n uaString = uaData.brands.map(item => item.brand + \"/\" + item.version).join(' ');\n return uaString;\n }\n return navigator.userAgent;\n}\n\nfunction isHTMLElement(value) {\n return value instanceof getWindow(value).HTMLElement;\n}\nfunction isElement(value) {\n return value instanceof getWindow(value).Element;\n}\nfunction isNode(value) {\n return value instanceof getWindow(value).Node;\n}\nfunction isShadowRoot(node) {\n // Browsers without `ShadowRoot` support.\n if (typeof ShadowRoot === 'undefined') {\n return false;\n }\n const OwnElement = getWindow(node).ShadowRoot;\n return node instanceof OwnElement || node instanceof ShadowRoot;\n}\nfunction isOverflowElement(element) {\n const {\n overflow,\n overflowX,\n overflowY,\n display\n } = getComputedStyle$1(element);\n return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !['inline', 'contents'].includes(display);\n}\nfunction isTableElement(element) {\n return ['table', 'td', 'th'].includes(getNodeName(element));\n}\nfunction isContainingBlock(element) {\n // TODO: Try to use feature detection here instead.\n const isFirefox = /firefox/i.test(getUAString());\n const css = getComputedStyle$1(element);\n const backdropFilter = css.backdropFilter || css.WebkitBackdropFilter;\n\n // This is non-exhaustive but covers the most common CSS properties that\n // create a containing block.\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n return css.transform !== 'none' || css.perspective !== 'none' || (backdropFilter ? backdropFilter !== 'none' : false) || isFirefox && css.willChange === 'filter' || isFirefox && (css.filter ? css.filter !== 'none' : false) || ['transform', 'perspective'].some(value => css.willChange.includes(value)) || ['paint', 'layout', 'strict', 'content'].some(value => {\n // Add type check for old browsers.\n const contain = css.contain;\n return contain != null ? contain.includes(value) : false;\n });\n}\n\n/**\n * Determines whether or not `.getBoundingClientRect()` is affected by visual\n * viewport offsets. In Safari, the `x`/`y` offsets are values relative to the\n * visual viewport, while in other engines, they are values relative to the\n * layout viewport.\n */\nfunction isClientRectVisualViewportBased() {\n // TODO: Try to use feature detection here instead. Feature detection for\n // this can fail in various ways, making the userAgent check the most\n // reliable:\n // • Always-visible scrollbar or not\n // • Width of \n\n // Is Safari.\n return /^((?!chrome|android).)*safari/i.test(getUAString());\n}\nfunction isLastTraversableNode(node) {\n return ['html', 'body', '#document'].includes(getNodeName(node));\n}\n\nfunction unwrapElement(element) {\n return !isElement(element) ? element.contextElement : element;\n}\n\nconst FALLBACK_SCALE = {\n x: 1,\n y: 1\n};\nfunction getScale(element) {\n const domElement = unwrapElement(element);\n if (!isHTMLElement(domElement)) {\n return FALLBACK_SCALE;\n }\n const rect = domElement.getBoundingClientRect();\n const {\n width,\n height,\n fallback\n } = getCssDimensions(domElement);\n let x = (fallback ? round(rect.width) : rect.width) / width;\n let y = (fallback ? round(rect.height) : rect.height) / height;\n\n // 0, NaN, or Infinity should always fallback to 1.\n\n if (!x || !Number.isFinite(x)) {\n x = 1;\n }\n if (!y || !Number.isFinite(y)) {\n y = 1;\n }\n return {\n x,\n y\n };\n}\n\nfunction getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {\n var _win$visualViewport, _win$visualViewport2;\n if (includeScale === void 0) {\n includeScale = false;\n }\n if (isFixedStrategy === void 0) {\n isFixedStrategy = false;\n }\n const clientRect = element.getBoundingClientRect();\n const domElement = unwrapElement(element);\n let scale = FALLBACK_SCALE;\n if (includeScale) {\n if (offsetParent) {\n if (isElement(offsetParent)) {\n scale = getScale(offsetParent);\n }\n } else {\n scale = getScale(element);\n }\n }\n const win = domElement ? getWindow(domElement) : window;\n const addVisualOffsets = isClientRectVisualViewportBased() && isFixedStrategy;\n let x = (clientRect.left + (addVisualOffsets ? ((_win$visualViewport = win.visualViewport) == null ? void 0 : _win$visualViewport.offsetLeft) || 0 : 0)) / scale.x;\n let y = (clientRect.top + (addVisualOffsets ? ((_win$visualViewport2 = win.visualViewport) == null ? void 0 : _win$visualViewport2.offsetTop) || 0 : 0)) / scale.y;\n let width = clientRect.width / scale.x;\n let height = clientRect.height / scale.y;\n if (domElement) {\n const win = getWindow(domElement);\n const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;\n let currentIFrame = win.frameElement;\n while (currentIFrame && offsetParent && offsetWin !== win) {\n const iframeScale = getScale(currentIFrame);\n const iframeRect = currentIFrame.getBoundingClientRect();\n const css = getComputedStyle(currentIFrame);\n iframeRect.x += (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;\n iframeRect.y += (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;\n x *= iframeScale.x;\n y *= iframeScale.y;\n width *= iframeScale.x;\n height *= iframeScale.y;\n x += iframeRect.x;\n y += iframeRect.y;\n currentIFrame = getWindow(currentIFrame).frameElement;\n }\n }\n return {\n width,\n height,\n top: y,\n right: x + width,\n bottom: y + height,\n left: x,\n x,\n y\n };\n}\n\nfunction getDocumentElement(node) {\n return ((isNode(node) ? node.ownerDocument : node.document) || window.document).documentElement;\n}\n\nfunction getNodeScroll(element) {\n if (isElement(element)) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n }\n return {\n scrollLeft: element.pageXOffset,\n scrollTop: element.pageYOffset\n };\n}\n\nfunction convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {\n let {\n rect,\n offsetParent,\n strategy\n } = _ref;\n const isOffsetParentAnElement = isHTMLElement(offsetParent);\n const documentElement = getDocumentElement(offsetParent);\n if (offsetParent === documentElement) {\n return rect;\n }\n let scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n let scale = {\n x: 1,\n y: 1\n };\n const offsets = {\n x: 0,\n y: 0\n };\n if (isOffsetParentAnElement || !isOffsetParentAnElement && strategy !== 'fixed') {\n if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n if (isHTMLElement(offsetParent)) {\n const offsetRect = getBoundingClientRect(offsetParent);\n scale = getScale(offsetParent);\n offsets.x = offsetRect.x + offsetParent.clientLeft;\n offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n }\n return {\n width: rect.width * scale.x,\n height: rect.height * scale.y,\n x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x,\n y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y\n };\n}\n\nfunction getWindowScrollBarX(element) {\n // If has a CSS width greater than the viewport, then this will be\n // incorrect for RTL.\n return getBoundingClientRect(getDocumentElement(element)).left + getNodeScroll(element).scrollLeft;\n}\n\n// Gets the entire size of the scrollable document area, even extending outside\n// of the `` and `` rect bounds if horizontally scrollable.\nfunction getDocumentRect(element) {\n const html = getDocumentElement(element);\n const scroll = getNodeScroll(element);\n const body = element.ownerDocument.body;\n const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);\n const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);\n let x = -scroll.scrollLeft + getWindowScrollBarX(element);\n const y = -scroll.scrollTop;\n if (getComputedStyle$1(body).direction === 'rtl') {\n x += max(html.clientWidth, body.clientWidth) - width;\n }\n return {\n width,\n height,\n x,\n y\n };\n}\n\nfunction getParentNode(node) {\n if (getNodeName(node) === 'html') {\n return node;\n }\n const result =\n // Step into the shadow DOM of the parent of a slotted node.\n node.assignedSlot ||\n // DOM Element detected.\n node.parentNode ||\n // ShadowRoot detected.\n isShadowRoot(node) && node.host ||\n // Fallback.\n getDocumentElement(node);\n return isShadowRoot(result) ? result.host : result;\n}\n\nfunction getNearestOverflowAncestor(node) {\n const parentNode = getParentNode(node);\n if (isLastTraversableNode(parentNode)) {\n // `getParentNode` will never return a `Document` due to the fallback\n // check, so it's either the or element.\n return parentNode.ownerDocument.body;\n }\n if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {\n return parentNode;\n }\n return getNearestOverflowAncestor(parentNode);\n}\n\nfunction getOverflowAncestors(node, list) {\n var _node$ownerDocument;\n if (list === void 0) {\n list = [];\n }\n const scrollableAncestor = getNearestOverflowAncestor(node);\n const isBody = scrollableAncestor === ((_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.body);\n const win = getWindow(scrollableAncestor);\n if (isBody) {\n return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : []);\n }\n return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor));\n}\n\nfunction getViewportRect(element, strategy) {\n const win = getWindow(element);\n const html = getDocumentElement(element);\n const visualViewport = win.visualViewport;\n let width = html.clientWidth;\n let height = html.clientHeight;\n let x = 0;\n let y = 0;\n if (visualViewport) {\n width = visualViewport.width;\n height = visualViewport.height;\n const visualViewportBased = isClientRectVisualViewportBased();\n if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {\n x = visualViewport.offsetLeft;\n y = visualViewport.offsetTop;\n }\n }\n return {\n width,\n height,\n x,\n y\n };\n}\n\n// Returns the inner client rect, subtracting scrollbars if present.\nfunction getInnerBoundingClientRect(element, strategy) {\n const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');\n const top = clientRect.top + element.clientTop;\n const left = clientRect.left + element.clientLeft;\n const scale = isHTMLElement(element) ? getScale(element) : {\n x: 1,\n y: 1\n };\n const width = element.clientWidth * scale.x;\n const height = element.clientHeight * scale.y;\n const x = left * scale.x;\n const y = top * scale.y;\n return {\n width,\n height,\n x,\n y\n };\n}\nfunction getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {\n let rect;\n if (clippingAncestor === 'viewport') {\n rect = getViewportRect(element, strategy);\n } else if (clippingAncestor === 'document') {\n rect = getDocumentRect(getDocumentElement(element));\n } else if (isElement(clippingAncestor)) {\n rect = getInnerBoundingClientRect(clippingAncestor, strategy);\n } else {\n const mutableRect = {\n ...clippingAncestor\n };\n if (isClientRectVisualViewportBased()) {\n var _win$visualViewport, _win$visualViewport2;\n const win = getWindow(element);\n mutableRect.x -= ((_win$visualViewport = win.visualViewport) == null ? void 0 : _win$visualViewport.offsetLeft) || 0;\n mutableRect.y -= ((_win$visualViewport2 = win.visualViewport) == null ? void 0 : _win$visualViewport2.offsetTop) || 0;\n }\n rect = mutableRect;\n }\n return rectToClientRect(rect);\n}\n\n// A \"clipping ancestor\" is an `overflow` element with the characteristic of\n// clipping (or hiding) child elements. This returns all clipping ancestors\n// of the given element up the tree.\nfunction getClippingElementAncestors(element, cache) {\n const cachedResult = cache.get(element);\n if (cachedResult) {\n return cachedResult;\n }\n let result = getOverflowAncestors(element).filter(el => isElement(el) && getNodeName(el) !== 'body');\n let currentContainingBlockComputedStyle = null;\n const elementIsFixed = getComputedStyle$1(element).position === 'fixed';\n let currentNode = elementIsFixed ? getParentNode(element) : element;\n\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {\n const computedStyle = getComputedStyle$1(currentNode);\n const containingBlock = isContainingBlock(currentNode);\n const shouldIgnoreCurrentNode = computedStyle.position === 'fixed';\n if (shouldIgnoreCurrentNode) {\n currentContainingBlockComputedStyle = null;\n } else {\n const shouldDropCurrentNode = elementIsFixed ? !containingBlock && !currentContainingBlockComputedStyle : !containingBlock && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && ['absolute', 'fixed'].includes(currentContainingBlockComputedStyle.position);\n if (shouldDropCurrentNode) {\n // Drop non-containing blocks.\n result = result.filter(ancestor => ancestor !== currentNode);\n } else {\n // Record last containing block for next iteration.\n currentContainingBlockComputedStyle = computedStyle;\n }\n }\n currentNode = getParentNode(currentNode);\n }\n cache.set(element, result);\n return result;\n}\n\n// Gets the maximum area that the element is visible in due to any number of\n// clipping ancestors.\nfunction getClippingRect(_ref) {\n let {\n element,\n boundary,\n rootBoundary,\n strategy\n } = _ref;\n const elementClippingAncestors = boundary === 'clippingAncestors' ? getClippingElementAncestors(element, this._c) : [].concat(boundary);\n const clippingAncestors = [...elementClippingAncestors, rootBoundary];\n const firstClippingAncestor = clippingAncestors[0];\n const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {\n const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);\n accRect.top = max(rect.top, accRect.top);\n accRect.right = min(rect.right, accRect.right);\n accRect.bottom = min(rect.bottom, accRect.bottom);\n accRect.left = max(rect.left, accRect.left);\n return accRect;\n }, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));\n return {\n width: clippingRect.right - clippingRect.left,\n height: clippingRect.bottom - clippingRect.top,\n x: clippingRect.left,\n y: clippingRect.top\n };\n}\n\nfunction getDimensions(element) {\n if (isHTMLElement(element)) {\n return getCssDimensions(element);\n }\n return element.getBoundingClientRect();\n}\n\nfunction getTrueOffsetParent(element, polyfill) {\n if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {\n return null;\n }\n if (polyfill) {\n return polyfill(element);\n }\n return element.offsetParent;\n}\nfunction getContainingBlock(element) {\n let currentNode = getParentNode(element);\n while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {\n if (isContainingBlock(currentNode)) {\n return currentNode;\n } else {\n currentNode = getParentNode(currentNode);\n }\n }\n return null;\n}\n\n// Gets the closest ancestor positioned element. Handles some edge cases,\n// such as table ancestors and cross browser bugs.\nfunction getOffsetParent(element, polyfill) {\n const window = getWindow(element);\n let offsetParent = getTrueOffsetParent(element, polyfill);\n while (offsetParent && isTableElement(offsetParent) && getComputedStyle$1(offsetParent).position === 'static') {\n offsetParent = getTrueOffsetParent(offsetParent, polyfill);\n }\n if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle$1(offsetParent).position === 'static' && !isContainingBlock(offsetParent))) {\n return window;\n }\n return offsetParent || getContainingBlock(element) || window;\n}\n\nfunction getRectRelativeToOffsetParent(element, offsetParent, strategy) {\n const isOffsetParentAnElement = isHTMLElement(offsetParent);\n const documentElement = getDocumentElement(offsetParent);\n const rect = getBoundingClientRect(element, true, strategy === 'fixed', offsetParent);\n let scroll = {\n scrollLeft: 0,\n scrollTop: 0\n };\n const offsets = {\n x: 0,\n y: 0\n };\n if (isOffsetParentAnElement || !isOffsetParentAnElement && strategy !== 'fixed') {\n if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n scroll = getNodeScroll(offsetParent);\n }\n if (isHTMLElement(offsetParent)) {\n const offsetRect = getBoundingClientRect(offsetParent, true);\n offsets.x = offsetRect.x + offsetParent.clientLeft;\n offsets.y = offsetRect.y + offsetParent.clientTop;\n } else if (documentElement) {\n offsets.x = getWindowScrollBarX(documentElement);\n }\n }\n return {\n x: rect.left + scroll.scrollLeft - offsets.x,\n y: rect.top + scroll.scrollTop - offsets.y,\n width: rect.width,\n height: rect.height\n };\n}\n\nconst platform = {\n getClippingRect,\n convertOffsetParentRelativeRectToViewportRelativeRect,\n isElement,\n getDimensions,\n getOffsetParent,\n getDocumentElement,\n getScale,\n async getElementRects(_ref) {\n let {\n reference,\n floating,\n strategy\n } = _ref;\n const getOffsetParentFn = this.getOffsetParent || getOffsetParent;\n const getDimensionsFn = this.getDimensions;\n return {\n reference: getRectRelativeToOffsetParent(reference, await getOffsetParentFn(floating), strategy),\n floating: {\n x: 0,\n y: 0,\n ...(await getDimensionsFn(floating))\n }\n };\n },\n getClientRects: element => Array.from(element.getClientRects()),\n isRTL: element => getComputedStyle$1(element).direction === 'rtl'\n};\n\n/**\n * Automatically updates the position of the floating element when necessary.\n * Should only be called when the floating element is mounted on the DOM or\n * visible on the screen.\n * @returns cleanup function that should be invoked when the floating element is\n * removed from the DOM or hidden from the screen.\n * @see https://floating-ui.com/docs/autoUpdate\n */\nfunction autoUpdate(reference, floating, update, options) {\n if (options === void 0) {\n options = {};\n }\n const {\n ancestorScroll: _ancestorScroll = true,\n ancestorResize = true,\n elementResize = true,\n animationFrame = false\n } = options;\n const ancestorScroll = _ancestorScroll && !animationFrame;\n const ancestors = ancestorScroll || ancestorResize ? [...(isElement(reference) ? getOverflowAncestors(reference) : reference.contextElement ? getOverflowAncestors(reference.contextElement) : []), ...getOverflowAncestors(floating)] : [];\n ancestors.forEach(ancestor => {\n ancestorScroll && ancestor.addEventListener('scroll', update, {\n passive: true\n });\n ancestorResize && ancestor.addEventListener('resize', update);\n });\n let observer = null;\n if (elementResize) {\n let initialUpdate = true;\n observer = new ResizeObserver(() => {\n if (!initialUpdate) {\n update();\n }\n initialUpdate = false;\n });\n isElement(reference) && !animationFrame && observer.observe(reference);\n if (!isElement(reference) && reference.contextElement && !animationFrame) {\n observer.observe(reference.contextElement);\n }\n observer.observe(floating);\n }\n let frameId;\n let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;\n if (animationFrame) {\n frameLoop();\n }\n function frameLoop() {\n const nextRefRect = getBoundingClientRect(reference);\n if (prevRefRect && (nextRefRect.x !== prevRefRect.x || nextRefRect.y !== prevRefRect.y || nextRefRect.width !== prevRefRect.width || nextRefRect.height !== prevRefRect.height)) {\n update();\n }\n prevRefRect = nextRefRect;\n frameId = requestAnimationFrame(frameLoop);\n }\n update();\n return () => {\n var _observer;\n ancestors.forEach(ancestor => {\n ancestorScroll && ancestor.removeEventListener('scroll', update);\n ancestorResize && ancestor.removeEventListener('resize', update);\n });\n (_observer = observer) == null ? void 0 : _observer.disconnect();\n observer = null;\n if (animationFrame) {\n cancelAnimationFrame(frameId);\n }\n };\n}\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a reference element when it is given a certain CSS positioning\n * strategy.\n */\nconst computePosition = (reference, floating, options) => {\n // This caches the expensive `getClippingElementAncestors` function so that\n // multiple lifecycle resets re-use the same result. It only lives for a\n // single call. If other functions become expensive, we can add them as well.\n const cache = new Map();\n const mergedOptions = {\n platform,\n ...options\n };\n const platformWithCache = {\n ...mergedOptions.platform,\n _c: cache\n };\n return computePosition$1(reference, floating, {\n ...mergedOptions,\n platform: platformWithCache\n });\n};\n\n/**\n * This module helps users provide custom configuration for component internals.\n *\n * @internal\n */\nconst configOverrides = globalThis[\"calciteComponentsConfig\"];\nconst config = {\n /**\n * We apply a custom fix to improve positioning for non-Chromium browsers.\n * The fix comes at a performance cost, so provides users a way to opt-out if necessary.\n *\n * @internal\n */\n floatingUINonChromiumPositioningFix: true,\n ...configOverrides\n};\n\nconst floatingUIBrowserCheck = patchFloatingUiForNonChromiumBrowsers();\nasync function patchFloatingUiForNonChromiumBrowsers() {\n function getUAData() {\n return navigator.userAgentData;\n }\n function getUAString() {\n const uaData = getUAData();\n return uaData?.brands\n ? uaData.brands.map(({ brand, version }) => `${brand}/${version}`).join(\" \")\n : navigator.userAgent;\n }\n function isChrome109OrAbove() {\n const uaData = getUAData();\n if (uaData?.brands) {\n return !!uaData.brands.find(({ brand, version }) => (brand === \"Google Chrome\" || brand === \"Chromium\") && Number(version) >= 109);\n }\n return !!navigator.userAgent.split(\" \").find((ua) => {\n const [browser, version] = ua.split(\"/\");\n return browser === \"Chrome\" && parseInt(version) >= 109;\n });\n }\n if (Build.isBrowser &&\n config.floatingUINonChromiumPositioningFix &&\n // ⚠️ browser-sniffing is not a best practice and should be avoided ⚠️\n (/firefox|safari/i.test(getUAString()) || isChrome109OrAbove())) {\n const { offsetParent } = await import('./utils4.js');\n const originalGetOffsetParent = platform.getOffsetParent;\n platform.getOffsetParent = (element) => originalGetOffsetParent(element, offsetParent);\n }\n}\n/**\n * Exported for testing purposes only\n */\nconst placementDataAttribute = \"data-placement\";\n/**\n * Exported for testing purposes only\n */\nconst repositionDebounceTimeout = 100;\nconst effectivePlacements = [\n \"top\",\n \"bottom\",\n \"right\",\n \"left\",\n \"top-start\",\n \"top-end\",\n \"bottom-start\",\n \"bottom-end\",\n \"right-start\",\n \"right-end\",\n \"left-start\",\n \"left-end\"\n];\nconst defaultMenuPlacement = \"bottom-start\";\nconst FloatingCSS = {\n animation: \"calcite-floating-ui-anim\",\n animationActive: \"calcite-floating-ui-anim--active\"\n};\nfunction getMiddleware({ placement, flipDisabled, flipPlacements, offsetDistance, offsetSkidding, arrowEl, type }) {\n const defaultMiddleware = [shift(), hide()];\n if (type === \"menu\") {\n return [\n ...defaultMiddleware,\n flip({\n fallbackPlacements: flipPlacements || [\"top-start\", \"top\", \"top-end\", \"bottom-start\", \"bottom\", \"bottom-end\"]\n })\n ];\n }\n if (type === \"popover\" || type === \"tooltip\") {\n const middleware = [\n ...defaultMiddleware,\n offset({\n mainAxis: typeof offsetDistance === \"number\" ? offsetDistance : 0,\n crossAxis: typeof offsetSkidding === \"number\" ? offsetSkidding : 0\n })\n ];\n if (placement === \"auto\" || placement === \"auto-start\" || placement === \"auto-end\") {\n middleware.push(autoPlacement({ alignment: placement === \"auto-start\" ? \"start\" : placement === \"auto-end\" ? \"end\" : null }));\n }\n else if (!flipDisabled) {\n middleware.push(flip(flipPlacements ? { fallbackPlacements: flipPlacements } : {}));\n }\n if (arrowEl) {\n middleware.push(arrow({\n element: arrowEl\n }));\n }\n return middleware;\n }\n return [];\n}\nfunction filterComputedPlacements(placements, el) {\n const filteredPlacements = placements.filter((placement) => effectivePlacements.includes(placement));\n if (filteredPlacements.length !== placements.length) {\n console.warn(`${el.tagName}: Invalid value found in: flipPlacements. Try any of these: ${effectivePlacements\n .map((placement) => `\"${placement}\"`)\n .join(\", \")\n .trim()}`, { el });\n }\n return filteredPlacements;\n}\nfunction getEffectivePlacement(floatingEl, placement) {\n const placements = [\"left\", \"right\"];\n if (getElementDir(floatingEl) === \"rtl\") {\n placements.reverse();\n }\n return placement.replace(/leading/gi, placements[0]).replace(/trailing/gi, placements[1]);\n}\n/**\n * Convenience function to manage `reposition` calls for FloatingUIComponents that use `positionFloatingUI.\n *\n * Note: this is not needed for components that use `calcite-popover`.\n *\n * @param component\n * @param options\n * @param options.referenceEl\n * @param options.floatingEl\n * @param options.overlayPositioning\n * @param options.placement\n * @param options.flipDisabled\n * @param options.flipPlacements\n * @param options.offsetDistance\n * @param options.offsetSkidding\n * @param options.arrowEl\n * @param options.type\n * @param delayed\n */\nasync function reposition(component, options, delayed = false) {\n if (!component.open) {\n return;\n }\n return delayed ? debouncedReposition(options) : positionFloatingUI(options);\n}\nconst debouncedReposition = debounce(positionFloatingUI, repositionDebounceTimeout, {\n leading: true,\n maxWait: repositionDebounceTimeout\n});\n/**\n * Positions the floating element relative to the reference element.\n *\n * **Note:** exported for testing purposes only\n *\n * @param root0\n * @param root0.referenceEl\n * @param root0.floatingEl\n * @param root0.overlayPositioning\n * @param root0.placement\n * @param root0.flipDisabled\n * @param root0.flipPlacements\n * @param root0.offsetDistance\n * @param root0.offsetSkidding\n * @param root0.arrowEl\n * @param root0.type\n * @param root0.includeArrow\n */\nasync function positionFloatingUI({ referenceEl, floatingEl, overlayPositioning = \"absolute\", placement, flipDisabled, flipPlacements, offsetDistance, offsetSkidding, includeArrow = false, arrowEl, type }) {\n if (!referenceEl || !floatingEl || (includeArrow && !arrowEl)) {\n return null;\n }\n await floatingUIBrowserCheck;\n const { x, y, placement: effectivePlacement, strategy: position, middlewareData } = await computePosition(referenceEl, floatingEl, {\n strategy: overlayPositioning,\n placement: placement === \"auto\" || placement === \"auto-start\" || placement === \"auto-end\"\n ? undefined\n : getEffectivePlacement(floatingEl, placement),\n middleware: getMiddleware({\n placement,\n flipDisabled,\n flipPlacements,\n offsetDistance,\n offsetSkidding,\n arrowEl,\n type\n })\n });\n if (middlewareData?.arrow) {\n const { x: arrowX, y: arrowY } = middlewareData.arrow;\n Object.assign(arrowEl.style, {\n left: arrowX != null ? `${arrowX}px` : \"\",\n top: arrowY != null ? `${arrowY}px` : \"\"\n });\n }\n const referenceHidden = middlewareData?.hide?.referenceHidden;\n const visibility = referenceHidden ? \"hidden\" : null;\n const pointerEvents = visibility ? \"none\" : null;\n floatingEl.setAttribute(placementDataAttribute, effectivePlacement);\n const transform = `translate(${Math.round(x)}px,${Math.round(y)}px)`;\n Object.assign(floatingEl.style, {\n visibility,\n pointerEvents,\n position,\n top: \"0\",\n left: \"0\",\n transform\n });\n}\n/**\n * Exported for testing purposes only\n *\n * @internal\n */\nconst cleanupMap = new WeakMap();\n/**\n * Helper to set up floating element interactions on connectedCallback.\n *\n * @param component\n * @param referenceEl\n * @param floatingEl\n */\nfunction connectFloatingUI(component, referenceEl, floatingEl) {\n if (!floatingEl || !referenceEl) {\n return;\n }\n disconnectFloatingUI(component, referenceEl, floatingEl);\n const position = component.overlayPositioning;\n // ensure position matches for initial positioning\n Object.assign(floatingEl.style, {\n visibility: \"hidden\",\n pointerEvents: \"none\",\n position\n });\n if (position === \"absolute\") {\n resetPosition(floatingEl);\n }\n const runAutoUpdate = Build.isBrowser\n ? autoUpdate\n : (_refEl, _floatingEl, updateCallback) => {\n updateCallback();\n return () => {\n /* noop */\n };\n };\n cleanupMap.set(component, runAutoUpdate(referenceEl, floatingEl, () => component.reposition()));\n}\n/**\n * Helper to tear down floating element interactions on disconnectedCallback.\n *\n * @param component\n * @param referenceEl\n * @param floatingEl\n */\nfunction disconnectFloatingUI(component, referenceEl, floatingEl) {\n if (!floatingEl || !referenceEl) {\n return;\n }\n getTransitionTarget(floatingEl).removeEventListener(\"transitionend\", handleTransitionElTransitionEnd);\n const cleanup = cleanupMap.get(component);\n if (cleanup) {\n cleanup();\n }\n cleanupMap.delete(component);\n}\nconst visiblePointerSize = 4;\n/**\n * Default offset the position of the floating element away from the reference element.\n *\n * @default 6\n */\nconst defaultOffsetDistance = Math.ceil(Math.hypot(visiblePointerSize, visiblePointerSize));\n/**\n * This utils applies floating element styles to avoid affecting layout when closed.\n *\n * This should be called when the closing transition will start.\n *\n * @param floatingEl\n */\nfunction updateAfterClose(floatingEl) {\n if (!floatingEl || floatingEl.style.position !== \"absolute\") {\n return;\n }\n getTransitionTarget(floatingEl).addEventListener(\"transitionend\", handleTransitionElTransitionEnd);\n}\nfunction getTransitionTarget(floatingEl) {\n // assumes floatingEl w/ shadowRoot is a FloatingUIComponent\n return floatingEl.shadowRoot || floatingEl;\n}\nfunction handleTransitionElTransitionEnd(event) {\n const floatingTransitionEl = event.target;\n if (\n // using any prop from floating-ui transition\n event.propertyName === \"opacity\" &&\n floatingTransitionEl.classList.contains(FloatingCSS.animation)) {\n const floatingEl = getFloatingElFromTransitionTarget(floatingTransitionEl);\n resetPosition(floatingEl);\n getTransitionTarget(floatingEl).removeEventListener(\"transitionend\", handleTransitionElTransitionEnd);\n }\n}\nfunction resetPosition(floatingEl) {\n // resets position to better match https://floating-ui.com/docs/computePosition#initial-layout\n floatingEl.style.transform = \"\";\n floatingEl.style.top = \"0\";\n floatingEl.style.left = \"0\";\n}\nfunction getFloatingElFromTransitionTarget(floatingTransitionEl) {\n return closestElementCrossShadowBoundary(floatingTransitionEl, `[${placementDataAttribute}]`);\n}\n\nexport { FloatingCSS as F, disconnectFloatingUI as a, defaultOffsetDistance as b, connectFloatingUI as c, defaultMenuPlacement as d, filterComputedPlacements as f, reposition as r, updateAfterClose as u };\n","/*!\n * All material copyright ESRI, All Rights Reserved, unless otherwise specified.\n * See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.\n * v1.0.8-next.4\n */\nimport { readTask } from '@stencil/core/internal/client/index.js';\n\nconst componentToTransitionListeners = new WeakMap();\nfunction transitionStart(event) {\n if (event.propertyName === this.openTransitionProp && event.target === this.transitionEl) {\n this.open ? this.onBeforeOpen() : this.onBeforeClose();\n }\n}\nfunction transitionEnd(event) {\n if (event.propertyName === this.openTransitionProp && event.target === this.transitionEl) {\n this.open ? this.onOpen() : this.onClose();\n }\n}\n/**\n * Helper to determine globally set transition duration on the given openTransitionProp, which is imported and set in the @Watch(\"open\").\n * Used to emit (before)open/close events both for when the opacity transition is present and when there is none (transition-duration is set to 0).\n *\n * @param component\n * @param nonOpenCloseComponent\n */\nfunction onToggleOpenCloseComponent(component, nonOpenCloseComponent = false) {\n readTask(() => {\n if (component.transitionEl) {\n const allTransitionPropsArray = getComputedStyle(component.transitionEl).transition.split(\" \");\n const openTransitionPropIndex = allTransitionPropsArray.findIndex((item) => item === component.openTransitionProp);\n const transitionDuration = allTransitionPropsArray[openTransitionPropIndex + 1];\n if (transitionDuration === \"0s\") {\n (nonOpenCloseComponent ? component[component.transitionProp] : component.open)\n ? component.onBeforeOpen()\n : component.onBeforeClose();\n (nonOpenCloseComponent ? component[component.transitionProp] : component.open)\n ? component.onOpen()\n : component.onClose();\n }\n else {\n component.transitionEl.addEventListener(\"transitionstart\", () => {\n (nonOpenCloseComponent ? component[component.transitionProp] : component.open)\n ? component.onBeforeOpen()\n : component.onBeforeClose();\n }, { once: true });\n component.transitionEl.addEventListener(\"transitionend\", () => {\n (nonOpenCloseComponent ? component[component.transitionProp] : component.open)\n ? component.onOpen()\n : component.onClose();\n }, { once: true });\n }\n }\n });\n}\n/**\n * Helper to keep track of transition listeners on setTransitionEl and connectedCallback on OpenCloseComponent components.\n *\n * For component which do not have open prop, use `onToggleOpenCloseComponent` implementation.\n *\n * @param component\n */\nfunction connectOpenCloseComponent(component) {\n disconnectOpenCloseComponent(component);\n if (component.transitionEl) {\n const boundOnTransitionStart = transitionStart.bind(component);\n const boundOnTransitionEnd = transitionEnd.bind(component);\n componentToTransitionListeners.set(component, [\n component.transitionEl,\n boundOnTransitionStart,\n boundOnTransitionEnd\n ]);\n component.transitionEl.addEventListener(\"transitionstart\", boundOnTransitionStart);\n component.transitionEl.addEventListener(\"transitionend\", boundOnTransitionEnd);\n }\n}\n/**\n * Helper to tear down transition listeners on disconnectedCallback on OpenCloseComponent components.\n *\n * @param component\n */\nfunction disconnectOpenCloseComponent(component) {\n if (!componentToTransitionListeners.has(component)) {\n return;\n }\n const [transitionEl, start, end] = componentToTransitionListeners.get(component);\n transitionEl.removeEventListener(\"transitionstart\", start);\n transitionEl.removeEventListener(\"transitionend\", end);\n componentToTransitionListeners.delete(component);\n}\n\nexport { connectOpenCloseComponent as c, disconnectOpenCloseComponent as d, onToggleOpenCloseComponent as o };\n","/*!\n * All material copyright ESRI, All Rights Reserved, unless otherwise specified.\n * See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.\n * v1.0.8-next.4\n */\nimport { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client/index.js';\nimport { u as queryElementRoots, i as isPrimaryPointerButton, t as toAriaBoolean } from './dom.js';\nimport { c as connectFloatingUI, b as defaultOffsetDistance, u as updateAfterClose, a as disconnectFloatingUI, r as reposition, F as FloatingCSS } from './floating-ui.js';\nimport { g as guid } from './guid.js';\nimport { c as connectOpenCloseComponent, d as disconnectOpenCloseComponent } from './openCloseComponent.js';\n\nconst CSS = {\n container: \"container\",\n arrow: \"arrow\"\n};\nconst TOOLTIP_DELAY_MS = 500;\nconst ARIA_DESCRIBED_BY = \"aria-describedby\";\n\nfunction getEffectiveReferenceElement(tooltip) {\n const { referenceElement } = tooltip;\n return ((typeof referenceElement === \"string\" ? queryElementRoots(tooltip, { id: referenceElement }) : referenceElement) ||\n null);\n}\n\nclass TooltipManager {\n constructor() {\n // --------------------------------------------------------------------------\n //\n // Private Properties\n //\n // --------------------------------------------------------------------------\n this.registeredElements = new WeakMap();\n this.hoverTimeout = null;\n this.registeredElementCount = 0;\n // --------------------------------------------------------------------------\n //\n // Private Methods\n //\n // --------------------------------------------------------------------------\n this.queryTooltip = (composedPath) => {\n const { registeredElements } = this;\n const registeredElement = composedPath.find((pathEl) => registeredElements.has(pathEl));\n return registeredElements.get(registeredElement);\n };\n this.keyDownHandler = (event) => {\n if (event.key === \"Escape\" && !event.defaultPrevented) {\n const { activeTooltipEl } = this;\n if (activeTooltipEl && activeTooltipEl.open) {\n this.clearHoverTimeout();\n this.toggleTooltip(activeTooltipEl, false);\n const referenceElement = getEffectiveReferenceElement(activeTooltipEl);\n if (referenceElement instanceof Element && referenceElement.contains(event.target)) {\n event.preventDefault();\n }\n }\n }\n };\n this.queryHoveredTooltip = (composedPath) => {\n const { activeTooltipEl } = this;\n if (activeTooltipEl && composedPath.includes(activeTooltipEl)) {\n this.clearHoverTimeout();\n return;\n }\n const tooltip = this.queryTooltip(composedPath);\n if (tooltip) {\n this.toggleHoveredTooltip(tooltip, true);\n }\n else if (activeTooltipEl) {\n this.toggleHoveredTooltip(activeTooltipEl, false);\n }\n };\n this.pointerMoveHandler = (event) => {\n const composedPath = event.composedPath();\n this.clearHoverTimeout();\n this.hoverTimeout = window.setTimeout(() => this.queryHoveredTooltip(composedPath), TOOLTIP_DELAY_MS );\n };\n this.pointerDownHandler = (event) => {\n if (!isPrimaryPointerButton(event)) {\n return;\n }\n const clickedTooltip = this.queryTooltip(event.composedPath());\n this.clickedTooltip = clickedTooltip;\n if (clickedTooltip?.closeOnClick) {\n this.toggleTooltip(clickedTooltip, false);\n this.clearHoverTimeout();\n }\n };\n this.focusInHandler = (event) => {\n this.queryFocusedTooltip(event, true);\n };\n this.focusOutHandler = (event) => {\n this.queryFocusedTooltip(event, false);\n };\n this.toggleHoveredTooltip = (tooltip, value) => {\n if (value) {\n this.closeExistingTooltip();\n }\n this.toggleTooltip(tooltip, value);\n };\n }\n // --------------------------------------------------------------------------\n //\n // Public Methods\n //\n // --------------------------------------------------------------------------\n registerElement(referenceEl, tooltip) {\n this.registeredElementCount++;\n this.registeredElements.set(referenceEl, tooltip);\n if (this.registeredElementCount === 1) {\n this.addListeners();\n }\n }\n unregisterElement(referenceEl) {\n if (this.registeredElements.delete(referenceEl)) {\n this.registeredElementCount--;\n }\n if (this.registeredElementCount === 0) {\n this.removeListeners();\n }\n }\n addListeners() {\n document.addEventListener(\"keydown\", this.keyDownHandler, { capture: true });\n document.addEventListener(\"pointermove\", this.pointerMoveHandler, { capture: true });\n document.addEventListener(\"pointerdown\", this.pointerDownHandler, { capture: true });\n document.addEventListener(\"focusin\", this.focusInHandler, { capture: true });\n document.addEventListener(\"focusout\", this.focusOutHandler, { capture: true });\n }\n removeListeners() {\n document.removeEventListener(\"keydown\", this.keyDownHandler, { capture: true });\n document.removeEventListener(\"pointermove\", this.pointerMoveHandler, { capture: true });\n document.removeEventListener(\"pointerdown\", this.pointerDownHandler, { capture: true });\n document.removeEventListener(\"focusin\", this.focusInHandler, { capture: true });\n document.removeEventListener(\"focusout\", this.focusOutHandler, { capture: true });\n }\n clearHoverTimeout() {\n window.clearTimeout(this.hoverTimeout);\n }\n closeExistingTooltip() {\n const { activeTooltipEl } = this;\n if (activeTooltipEl) {\n this.toggleTooltip(activeTooltipEl, false);\n }\n }\n toggleFocusedTooltip(tooltip, value) {\n this.closeExistingTooltip();\n if (value) {\n this.clearHoverTimeout();\n }\n this.toggleTooltip(tooltip, value);\n }\n toggleTooltip(tooltip, value) {\n tooltip.open = value;\n if (value) {\n this.activeTooltipEl = tooltip;\n }\n }\n queryFocusedTooltip(event, value) {\n const tooltip = this.queryTooltip(event.composedPath());\n if (!tooltip || tooltip === this.clickedTooltip) {\n this.clickedTooltip = null;\n return;\n }\n this.toggleFocusedTooltip(tooltip, value);\n }\n}\n\nconst tooltipCss = \"@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host{--calcite-floating-ui-z-index:var(--calcite-tooltip-z-index, 901);display:block;position:absolute;z-index:var(--calcite-floating-ui-z-index)}.calcite-floating-ui-anim{position:relative;transition:var(--calcite-floating-ui-transition);transition-property:transform, visibility, opacity;opacity:0;box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);z-index:1;border-radius:0.25rem}:host([data-placement^=bottom]) .calcite-floating-ui-anim{transform:translateY(-5px)}:host([data-placement^=top]) .calcite-floating-ui-anim{transform:translateY(5px)}:host([data-placement^=left]) .calcite-floating-ui-anim{transform:translateX(5px)}:host([data-placement^=right]) .calcite-floating-ui-anim{transform:translateX(-5px)}:host([data-placement]) .calcite-floating-ui-anim--active{opacity:1;transform:translate(0)}:host([calcite-hydrated-hidden]){visibility:hidden !important;pointer-events:none}.arrow,.arrow::before{position:absolute;inline-size:8px;block-size:8px;z-index:-1}.arrow::before{content:\\\"\\\";--tw-shadow:0 4px 8px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -1px rgba(0, 0, 0, 0.04);--tw-shadow-colored:0 4px 8px -1px var(--tw-shadow-color), 0 2px 4px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);transform:rotate(45deg);background:var(--calcite-ui-foreground-1)}:host([data-placement^=top]) .arrow{inset-block-end:-4px}:host([data-placement^=bottom]) .arrow{inset-block-start:-4px}:host([data-placement^=right]) .arrow,:host([data-placement^=left]) .arrow{direction:ltr;text-align:start}:host([data-placement^=left]) .arrow{inset-inline-end:-4px}:host([data-placement^=right]) .arrow{inset-inline-start:-4px}.container{position:relative;overflow:hidden;border-radius:0.25rem;background-color:var(--calcite-ui-foreground-1);padding-block:0.75rem;padding-inline:1rem;font-size:var(--calcite-font-size--2);line-height:1.375;font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1);max-inline-size:20rem;max-block-size:20rem;text-align:start}.calcite-floating-ui-anim{border-radius:0.25rem;border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-3);background-color:var(--calcite-ui-foreground-1)}.arrow::before{outline:1px solid var(--calcite-ui-border-3)}\";\n\nconst manager = new TooltipManager();\nconst Tooltip = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {\n constructor() {\n super();\n this.__registerHost();\n this.__attachShadow();\n this.calciteTooltipBeforeClose = createEvent(this, \"calciteTooltipBeforeClose\", 6);\n this.calciteTooltipClose = createEvent(this, \"calciteTooltipClose\", 6);\n this.calciteTooltipBeforeOpen = createEvent(this, \"calciteTooltipBeforeOpen\", 6);\n this.calciteTooltipOpen = createEvent(this, \"calciteTooltipOpen\", 6);\n this.guid = `calcite-tooltip-${guid()}`;\n this.hasLoaded = false;\n this.openTransitionProp = \"opacity\";\n this.setTransitionEl = (el) => {\n this.transitionEl = el;\n connectOpenCloseComponent(this);\n };\n this.setUpReferenceElement = (warn = true) => {\n this.removeReferences();\n this.effectiveReferenceElement = getEffectiveReferenceElement(this.el);\n connectFloatingUI(this, this.effectiveReferenceElement, this.el);\n const { el, referenceElement, effectiveReferenceElement } = this;\n if (warn && referenceElement && !effectiveReferenceElement) {\n console.warn(`${el.tagName}: reference-element id \"${referenceElement}\" was not found.`, {\n el\n });\n }\n this.addReferences();\n };\n this.getId = () => {\n return this.el.id || this.guid;\n };\n this.addReferences = () => {\n const { effectiveReferenceElement } = this;\n if (!effectiveReferenceElement) {\n return;\n }\n const id = this.getId();\n if (\"setAttribute\" in effectiveReferenceElement) {\n effectiveReferenceElement.setAttribute(ARIA_DESCRIBED_BY, id);\n }\n manager.registerElement(effectiveReferenceElement, this.el);\n };\n this.removeReferences = () => {\n const { effectiveReferenceElement } = this;\n if (!effectiveReferenceElement) {\n return;\n }\n if (\"removeAttribute\" in effectiveReferenceElement) {\n effectiveReferenceElement.removeAttribute(ARIA_DESCRIBED_BY);\n }\n manager.unregisterElement(effectiveReferenceElement);\n };\n this.closeOnClick = false;\n this.label = undefined;\n this.offsetDistance = defaultOffsetDistance;\n this.offsetSkidding = 0;\n this.open = false;\n this.overlayPositioning = \"absolute\";\n this.placement = \"auto\";\n this.referenceElement = undefined;\n this.effectiveReferenceElement = undefined;\n }\n offsetDistanceOffsetHandler() {\n this.reposition(true);\n }\n offsetSkiddingHandler() {\n this.reposition(true);\n }\n openHandler(value) {\n if (value) {\n this.reposition(true);\n }\n else {\n updateAfterClose(this.el);\n }\n }\n overlayPositioningHandler() {\n this.reposition(true);\n }\n placementHandler() {\n this.reposition(true);\n }\n referenceElementHandler() {\n this.setUpReferenceElement();\n }\n // --------------------------------------------------------------------------\n //\n // Lifecycle\n //\n // --------------------------------------------------------------------------\n connectedCallback() {\n connectOpenCloseComponent(this);\n this.setUpReferenceElement(this.hasLoaded);\n }\n componentDidLoad() {\n if (this.referenceElement && !this.effectiveReferenceElement) {\n this.setUpReferenceElement();\n }\n this.reposition(true);\n this.hasLoaded = true;\n }\n disconnectedCallback() {\n this.removeReferences();\n disconnectFloatingUI(this, this.effectiveReferenceElement, this.el);\n disconnectOpenCloseComponent(this);\n }\n // --------------------------------------------------------------------------\n //\n // Public Methods\n //\n // --------------------------------------------------------------------------\n /**\n * Updates the position of the component.\n *\n * @param delayed\n */\n async reposition(delayed = false) {\n const { el, effectiveReferenceElement, placement, overlayPositioning, offsetDistance, offsetSkidding, arrowEl } = this;\n return reposition(this, {\n floatingEl: el,\n referenceEl: effectiveReferenceElement,\n overlayPositioning,\n placement,\n offsetDistance,\n offsetSkidding,\n includeArrow: true,\n arrowEl,\n type: \"tooltip\"\n }, delayed);\n }\n // --------------------------------------------------------------------------\n //\n // Private Methods\n //\n // --------------------------------------------------------------------------\n onBeforeOpen() {\n this.calciteTooltipBeforeOpen.emit();\n }\n onOpen() {\n this.calciteTooltipOpen.emit();\n }\n onBeforeClose() {\n this.calciteTooltipBeforeClose.emit();\n }\n onClose() {\n this.calciteTooltipClose.emit();\n }\n // --------------------------------------------------------------------------\n //\n // Render Methods\n //\n // --------------------------------------------------------------------------\n render() {\n const { effectiveReferenceElement, label, open } = this;\n const displayed = effectiveReferenceElement && open;\n const hidden = !displayed;\n return (h(Host, { \"aria-hidden\": toAriaBoolean(hidden), \"aria-label\": label, \"aria-live\": \"polite\", \"calcite-hydrated-hidden\": hidden, id: this.getId(), role: \"tooltip\" }, h(\"div\", { class: {\n [FloatingCSS.animation]: true,\n [FloatingCSS.animationActive]: displayed\n }, ref: this.setTransitionEl }, h(\"div\", { class: CSS.arrow, ref: (arrowEl) => (this.arrowEl = arrowEl) }), h(\"div\", { class: CSS.container }, h(\"slot\", null)))));\n }\n get el() { return this; }\n static get watchers() { return {\n \"offsetDistance\": [\"offsetDistanceOffsetHandler\"],\n \"offsetSkidding\": [\"offsetSkiddingHandler\"],\n \"open\": [\"openHandler\"],\n \"overlayPositioning\": [\"overlayPositioningHandler\"],\n \"placement\": [\"placementHandler\"],\n \"referenceElement\": [\"referenceElementHandler\"]\n }; }\n static get style() { return tooltipCss; }\n}, [1, \"calcite-tooltip\", {\n \"closeOnClick\": [516, \"close-on-click\"],\n \"label\": [1],\n \"offsetDistance\": [514, \"offset-distance\"],\n \"offsetSkidding\": [514, \"offset-skidding\"],\n \"open\": [516],\n \"overlayPositioning\": [513, \"overlay-positioning\"],\n \"placement\": [513],\n \"referenceElement\": [1, \"reference-element\"],\n \"effectiveReferenceElement\": [32],\n \"reposition\": [64]\n }]);\nfunction defineCustomElement() {\n if (typeof customElements === \"undefined\") {\n return;\n }\n const components = [\"calcite-tooltip\"];\n components.forEach(tagName => { switch (tagName) {\n case \"calcite-tooltip\":\n if (!customElements.get(tagName)) {\n customElements.define(tagName, Tooltip);\n }\n break;\n } });\n}\ndefineCustomElement();\n\nexport { Tooltip as T, defineCustomElement as d };\n"],"names":["freeGlobal","global","Object","freeSelf","self","root","Function","Symbol","objectProto$1","prototype","hasOwnProperty","nativeObjectToString$1","toString","symToStringTag$1","toStringTag","undefined","nativeObjectToString","symToStringTag","baseGetTag","value","isOwn","call","tag","unmasked","e","result","getRawTag","objectToString","isObjectLike","isSymbol","reWhitespace","reTrimStart","baseTrim","string","slice","index","length","test","charAt","trimmedEndIndex","replace","isObject","type","reIsBadHex","reIsBinary","reIsOctal","freeParseInt","parseInt","toNumber","other","valueOf","isBinary","now","Date","nativeMax","Math","max","nativeMin","min","debounce","func","wait","options","lastArgs","lastThis","maxWait","timerId","lastCallTime","lastInvokeTime","leading","maxing","trailing","TypeError","invokeFunc","time","args","thisArg","apply","leadingEdge","setTimeout","timerExpired","shouldInvoke","timeSinceLastCall","trailingEdge","timeWaiting","remainingWait","debounced","isInvoking","arguments","this","clearTimeout","cancel","flush","getAlignment","placement","split","getLengthFromAxis","axis","getSide","getMainAxisFromPlacement","includes","computeCoordsFromPlacement","_ref","rtl","reference","floating","commonX","x","width","commonY","y","height","mainAxis","commonAlign","isVertical","coords","getSideObjectFromPadding","padding","top","right","bottom","left","expandPaddingObject","rectToClientRect","rect","async","detectOverflow","state","_await$platform$isEle","platform","rects","elements","strategy","boundary","rootBoundary","elementContext","altBoundary","paddingObject","element","clippingClientRect","getClippingRect","isElement","contextElement","getDocumentElement","offsetParent","getOffsetParent","offsetScale","getScale","elementClientRect","convertOffsetParentRelativeRectToViewportRelativeRect","min$1","max$1","within","min$1$1","max$1$1","sides","allPlacements","reduce","acc","side","concat","oppositeSideMap","getOppositePlacement","getAlignmentSides","alignment","mainAlignmentSide","main","cross","oppositeAlignmentMap","start","end","getOppositeAlignmentPlacement","autoPlacement","name","_middlewareData$autoP","_middlewareData$autoP2","_placementsThatFitOnE","middlewareData","crossAxis","allowedPlacements","autoAlignment","detectOverflowOptions","placements","filter","getPlacementList","overflow","currentIndex","currentPlacement","isRTL","reset","currentOverflows","allOverflows","overflows","nextPlacement","data","placementsSortedByMostSpace","map","d","v","sort","a","b","resetPlacement","every","flip","_middlewareData$flip","initialPlacement","checkMainAxis","checkCrossAxis","fallbackPlacements","specifiedFallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment","isBasePlacement","oppositePlacement","getExpandedPlacements","push","direction","list","isStart","lr","rl","tb","bt","getSideList","getOppositeAxisPlacements","overflowsData","_middlewareData$flip2","_overflowsData$filter","nextIndex","_overflowsData$map$so","getSideOffsets","isAnySideFullyClipped","some","hide","offsets","referenceHiddenOffsets","referenceHidden","escapedOffsets","escaped","offset","diffCoords","mainAxisMulti","crossAxisMulti","rawValue","alignmentAxis","convertValueToCoords","getWindow","node","_node$ownerDocument","ownerDocument","defaultView","window","getComputedStyle$1","getComputedStyle","round","getCssDimensions","css","parseFloat","offsetWidth","offsetHeight","shouldFallback","fallback","getNodeName","isNode","nodeName","toLowerCase","uaString","getUAString","uaData","navigator","userAgentData","Array","isArray","brands","item","brand","version","join","userAgent","isHTMLElement","HTMLElement","Element","Node","isShadowRoot","ShadowRoot","isOverflowElement","overflowX","overflowY","display","isTableElement","isContainingBlock","isFirefox","backdropFilter","WebkitBackdropFilter","transform","perspective","willChange","contain","isClientRectVisualViewportBased","isLastTraversableNode","unwrapElement","FALLBACK_SCALE","domElement","getBoundingClientRect","Number","isFinite","includeScale","isFixedStrategy","_win$visualViewport","_win$visualViewport2","clientRect","scale","win","addVisualOffsets","visualViewport","offsetLeft","offsetTop","offsetWin","currentIFrame","frameElement","iframeScale","iframeRect","clientLeft","paddingLeft","clientTop","paddingTop","document","documentElement","getNodeScroll","scrollLeft","scrollTop","pageXOffset","pageYOffset","getWindowScrollBarX","getParentNode","assignedSlot","parentNode","host","getNearestOverflowAncestor","body","getOverflowAncestors","scrollableAncestor","isBody","getClientRectFromClippingAncestor","clippingAncestor","html","clientWidth","clientHeight","visualViewportBased","getViewportRect","scroll","scrollWidth","scrollHeight","getDocumentRect","getInnerBoundingClientRect","mutableRect","getTrueOffsetParent","polyfill","position","currentNode","getContainingBlock","getRectRelativeToOffsetParent","isOffsetParentAnElement","offsetRect","elementClippingAncestors","cache","cachedResult","get","el","currentContainingBlockComputedStyle","elementIsFixed","computedStyle","containingBlock","ancestor","set","getClippingElementAncestors","_c","clippingAncestors","firstClippingAncestor","clippingRect","accRect","getDimensions","getOffsetParentFn","getDimensionsFn","getClientRects","from","autoUpdate","update","ancestorScroll","_ancestorScroll","ancestorResize","elementResize","animationFrame","ancestors","forEach","addEventListener","passive","frameId","observer","initialUpdate","ResizeObserver","observe","prevRefRect","frameLoop","nextRefRect","requestAnimationFrame","_observer","removeEventListener","disconnect","cancelAnimationFrame","computePosition","Map","mergedOptions","platformWithCache","config","middleware","validMiddleware","Boolean","getElementRects","statefulPlacement","resetCount","i","fn","nextX","nextY","computePosition$1","floatingUINonChromiumPositioningFix","globalThis","floatingUIBrowserCheck","getUAData","Build","find","ua","browser","isChrome109OrAbove","originalGetOffsetParent","patchFloatingUiForNonChromiumBrowsers","placementDataAttribute","effectivePlacements","FloatingCSS","animation","animationActive","getMiddleware","flipDisabled","flipPlacements","offsetDistance","offsetSkidding","arrowEl","defaultMiddleware","limiter","mainAxisCoord","crossAxisCoord","maxSide","limitedCoords","arrowDimensions","minProp","maxProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","center","shouldAddOffset","centerOffset","arrow","filterComputedPlacements","filteredPlacements","console","warn","tagName","trim","getEffectivePlacement","floatingEl","getElementDir","reverse","reposition","component","delayed","open","debouncedReposition","positionFloatingUI","referenceEl","overlayPositioning","includeArrow","effectivePlacement","arrowX","arrowY","assign","style","visibility","pointerEvents","setAttribute","cleanupMap","WeakMap","connectFloatingUI","disconnectFloatingUI","resetPosition","runAutoUpdate","_refEl","_floatingEl","updateCallback","getTransitionTarget","handleTransitionElTransitionEnd","cleanup","delete","defaultOffsetDistance","ceil","hypot","updateAfterClose","shadowRoot","event","floatingTransitionEl","target","propertyName","classList","contains","closestElementCrossShadowBoundary","getFloatingElFromTransitionTarget","componentToTransitionListeners","transitionStart","openTransitionProp","transitionEl","onBeforeOpen","onBeforeClose","transitionEnd","onOpen","onClose","connectOpenCloseComponent","disconnectOpenCloseComponent","boundOnTransitionStart","bind","boundOnTransitionEnd","has","CSS","ARIA_DESCRIBED_BY","getEffectiveReferenceElement","tooltip","referenceElement","queryElementRoots","id","manager","constructor","registeredElements","hoverTimeout","registeredElementCount","queryTooltip","composedPath","registeredElement","pathEl","keyDownHandler","key","defaultPrevented","activeTooltipEl","clearHoverTimeout","toggleTooltip","preventDefault","queryHoveredTooltip","toggleHoveredTooltip","pointerMoveHandler","pointerDownHandler","isPrimaryPointerButton","clickedTooltip","closeOnClick","focusInHandler","queryFocusedTooltip","focusOutHandler","closeExistingTooltip","registerElement","addListeners","unregisterElement","removeListeners","capture","toggleFocusedTooltip","Tooltip","proxyCustomElement","super","__registerHost","__attachShadow","calciteTooltipBeforeClose","createEvent","calciteTooltipClose","calciteTooltipBeforeOpen","calciteTooltipOpen","guid","hasLoaded","setTransitionEl","setUpReferenceElement","removeReferences","effectiveReferenceElement","addReferences","getId","removeAttribute","label","offsetDistanceOffsetHandler","offsetSkiddingHandler","openHandler","overlayPositioningHandler","placementHandler","referenceElementHandler","connectedCallback","componentDidLoad","disconnectedCallback","emit","render","displayed","hidden","h","Host","toAriaBoolean","role","class","ref","watchers","defineCustomElement","customElements","define"],"sourceRoot":""}