HEX
Server: LiteSpeed
System: Linux node612.namehero.net 4.18.0-553.121.1.lve.el8.x86_64 #1 SMP Thu Apr 30 16:40:41 UTC 2026 x86_64
User: dfwparty (1186)
PHP: 8.3.31
Disabled: NONE
Upload Files
File: /home/dfwparty/public_html/wp-content/plugins/ultimate-elementor/build/main.js.map
{"version":3,"file":"main.js","mappings":";gBACIA,EADAC,E,uBCUJ,IASIC,EAAS,aAGTC,EAAa,qBAGbC,EAAa,aAGbC,EAAY,cAGZC,EAAeC,SAGfC,EAA8B,iBAAV,EAAAC,GAAsB,EAAAA,GAAU,EAAAA,EAAOC,SAAWA,QAAU,EAAAD,EAGhFE,EAA0B,iBAARC,MAAoBA,MAAQA,KAAKF,SAAWA,QAAUE,KAGxEC,EAAOL,GAAcG,GAAYG,SAAS,cAATA,GAUjCC,EAPcL,OAAOM,UAOQC,SAG7BC,EAAYC,KAAKC,IACjBC,EAAYF,KAAKG,IAkBjBC,EAAM,WACR,OAAOV,EAAKW,KAAKD,KACnB,EA2MA,SAASE,EAASC,GAChB,IAAIC,SAAcD,EAClB,QAASA,IAAkB,UAARC,GAA4B,YAARA,EACzC,CA2EA,SAASC,EAASF,GAChB,GAAoB,iBAATA,EACT,OAAOA,EAET,GAhCF,SAAkBA,GAChB,MAAuB,iBAATA,GAtBhB,SAAsBA,GACpB,QAASA,GAAyB,iBAATA,CAC3B,CAqBKG,CAAaH,IAzTF,mBAyTYX,EAAee,KAAKJ,EAChD,CA6BMK,CAASL,GACX,OA3VM,IA6VR,GAAID,EAASC,GAAQ,CACnB,IAAIM,EAAgC,mBAAjBN,EAAMO,QAAwBP,EAAMO,UAAYP,EACnEA,EAAQD,EAASO,GAAUA,EAAQ,GAAMA,CAC3C,CACA,GAAoB,iBAATN,EACT,OAAiB,IAAVA,EAAcA,GAASA,EAEhCA,EAAQA,EAAMQ,QAAQhC,EAAQ,IAC9B,IAAIiC,EAAW/B,EAAWgC,KAAKV,GAC/B,OAAQS,GAAY9B,EAAU+B,KAAKV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AAMC,EAASz3G,SAASqkB,cAAc,OACtCozF,EAAOv4F,GAAK,mBACZs4F,EAAelzF,YAAYmzF,IAEP7tH,EAAAA,EAAAA,GAAW6tH,GACnBp4E,OAAOq+C,MAAAr5D,cAACqlE,GAAO,MAC5B,CACD,CAEF,E","sources":["webpack://uael/webpack/runtime/create fake namespace object","webpack://uael/./node_modules/lodash.debounce/index.js","webpack://uael/./node_modules/path-to-regexp/dist/index.js","webpack://uael/./node_modules/querystringify/index.js","webpack://uael/./node_modules/react-dom/client.js","webpack://uael/./node_modules/react/cjs/react-jsx-runtime.production.min.js","webpack://uael/./node_modules/react/jsx-runtime.js","webpack://uael/external window \"React\"","webpack://uael/external window \"ReactDOM\"","webpack://uael/./node_modules/classnames/index.js","webpack://uael/webpack/bootstrap","webpack://uael/webpack/runtime/compat get default export","webpack://uael/webpack/runtime/define property getters","webpack://uael/webpack/runtime/global","webpack://uael/webpack/runtime/hasOwnProperty shorthand","webpack://uael/webpack/runtime/make namespace object","webpack://uael/external window [\"wp\",\"domReady\"]","webpack://uael/./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/slicedToArray.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","webpack://uael/./node_modules/tailwind-merge/dist/bundle-mjs.mjs","webpack://uael/./node_modules/clsx/dist/clsx.mjs","webpack://uael/./node_modules/@bsf/force-ui/dist/utilities/functions.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/topbar/topbar.es.js","webpack://uael/./node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs","webpack://uael/./node_modules/@floating-ui/react/dist/floating-ui.react.utils.mjs","webpack://uael/./node_modules/tabbable/dist/index.esm.js","webpack://uael/./node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs","webpack://uael/./node_modules/@floating-ui/core/dist/floating-ui.core.mjs","webpack://uael/./node_modules/@floating-ui/dom/dist/floating-ui.dom.mjs","webpack://uael/./node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs","webpack://uael/./node_modules/@floating-ui/react/dist/floating-ui.react.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/components/create-proxy.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/utils/is-animation-controls.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/utils/is-keyframes-target.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/shallow-compare.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/is-variant-label.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/resolve-variants.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/resolve-dynamic-variants.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/variant-props.mjs","webpack://uael/./node_modules/motion-utils/dist/es/memo.mjs","webpack://uael/./node_modules/motion-dom/dist/es/utils/supports/scroll-timeline.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/controls/BaseGroup.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/controls/Group.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/utils/get-value-transition.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/generators/utils/calc-duration.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/generators/utils/is-generator.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/waapi/utils/attach-timeline.mjs","webpack://uael/./node_modules/motion-dom/dist/es/utils/is-bezier-definition.mjs","webpack://uael/./node_modules/motion-dom/dist/es/utils/supports/flags.mjs","webpack://uael/./node_modules/motion-dom/dist/es/utils/supports/memo.mjs","webpack://uael/./node_modules/motion-dom/dist/es/utils/supports/linear-easing.mjs","webpack://uael/./node_modules/motion-utils/dist/es/progress.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/waapi/utils/linear.mjs","webpack://uael/./node_modules/motion-dom/dist/es/animation/waapi/utils/easing.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/drag/state/is-active.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/utils/setup.mjs","webpack://uael/./node_modules/motion-dom/dist/es/utils/resolve-elements.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/hover.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/utils/is-node-or-child.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/utils/is-primary-pointer.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/press/utils/is-keyboard-accessible.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/press/utils/state.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/press/index.mjs","webpack://uael/./node_modules/motion-utils/dist/es/time-conversion.mjs","webpack://uael/./node_modules/motion-utils/dist/es/noop.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/keys-transform.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/keys-position.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/resolve-value.mjs","webpack://uael/./node_modules/framer-motion/dist/es/frameloop/batcher.mjs","webpack://uael/./node_modules/framer-motion/dist/es/frameloop/render-step.mjs","webpack://uael/./node_modules/framer-motion/dist/es/frameloop/frame.mjs","webpack://uael/./node_modules/framer-motion/dist/es/frameloop/sync-time.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/array.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/subscription-manager.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/velocity-per-second.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/setters.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/utils/is-motion-value.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/use-will-change/add-will-change.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/use-will-change/is.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/camel-to-dash.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/optimized-appear/data-id.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/optimized-appear/get-appear-id.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/use-instant-transition-state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/cubic-bezier.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/modifiers/mirror.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/modifiers/reverse.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/back.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/anticipate.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/circ.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/is-zero-value-string.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/utils/is-none.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/clamp.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/numbers/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/utils/sanitize.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/utils/float-regex.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/utils/single-color-regex.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/color/utils.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/utils/is-nullish.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/color/rgba.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/color/hex.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/numbers/units.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/color/hsla.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/color/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/utils/color-regex.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/complex/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/types/complex/filter.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/number-browser.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/transform.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/type-int.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/number.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/defaults.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/animatable-none.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/make-none-animatable.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/unit-conversion.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/KeyframesResolver.mjs","webpack://uael/./node_modules/motion-utils/dist/es/errors.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/is-numerical-string.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/is-css-variable.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/css-variables-conversion.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/test.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/dimensions.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/type-auto.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/DOMKeyframesResolver.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/utils/is-animatable.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/utils/can-animate.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/waapi/utils/get-final-keyframe.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/BaseAnimation.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/mix/number.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/hsla-to-rgba.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/mix/immediate.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/mix/color.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/pipe.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/mix/visibility.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/mix/complex.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/mix/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/generators/utils/velocity.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/generators/spring/defaults.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/generators/spring/find.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/generators/spring/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/generators/inertia.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/ease.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/utils/map.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/generators/keyframes.mjs","webpack://uael/./node_modules/framer-motion/dist/es/easing/utils/is-easing-array.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/offsets/time.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/offsets/default.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/offsets/fill.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/interpolate.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/drivers/driver-frameloop.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/MainThreadAnimation.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/utils/accelerated-values.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/waapi/utils/supports-waapi.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/AcceleratedAnimation.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animators/waapi/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/utils/default-transitions.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/interfaces/motion-value.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/utils/is-transition-defined.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/interfaces/visual-element-target.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/interfaces/visual-element-variant.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/get-variant-context.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/animation-state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/interfaces/visual-element.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/Feature.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/animation/exit.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/animations.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/animation/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/events/add-dom-event.mjs","webpack://uael/./node_modules/framer-motion/dist/es/events/event-info.mjs","webpack://uael/./node_modules/framer-motion/dist/es/events/add-pointer-event.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/distance.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/pan/PanSession.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/is-ref-object.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/delta-calc.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/models.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/utils/each-axis.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/conversion.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/utils/has-transform.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/delta-apply.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/utils/measure.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/get-context-window.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.mjs","webpack://uael/./node_modules/motion-dom/dist/es/gestures/drag/state/set-active.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/pan/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/PresenceContext.mjs","webpack://uael/./node_modules/framer-motion/dist/es/components/AnimatePresence/use-presence.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/LayoutGroupContext.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/SwitchLayoutGroupContext.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/node/state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/styles/scale-border-radius.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/styles/scale-box-shadow.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/styles/scale-correction.mjs","webpack://uael/./node_modules/framer-motion/dist/es/frameloop/microtask.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/layout/MeasureLayout.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/compare-by-depth.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/flat-tree.mjs","webpack://uael/./node_modules/framer-motion/dist/es/value/utils/resolve-motion-value.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/animation/mix-values.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/copy.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/delta-remove.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/geometry/utils.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/shared/stack.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/node/create-projection-node.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/is-svg-element.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/delay.mjs","webpack://uael/./node_modules/framer-motion/dist/es/animation/animate/single-value.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/styles/transform.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/node/DocumentProjectionNode.mjs","webpack://uael/./node_modules/framer-motion/dist/es/projection/node/HTMLProjectionNode.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/drag.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/drag/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/hover.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/press.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/viewport/observers.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/viewport/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/gestures.mjs","webpack://uael/./node_modules/framer-motion/dist/es/gestures/focus.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/layout.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/LazyContext.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/MotionConfigContext.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/MotionContext/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/is-controlling-variants.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/MotionContext/create.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/is-browser.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/definitions.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/utils/symbol.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/utils/use-motion-ref.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/use-isomorphic-effect.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/utils/use-visual-element.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/context/MotionContext/utils.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/features/load-features.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/lowercase-elements.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/is-svg-component.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/use-constant.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/utils/use-visual-state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/get-as-type.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/build-transform.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/build-styles.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/path.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/transform-origin.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/build-attrs.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/create-render-state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/is-svg-tag.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/render.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/camel-case-attrs.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/render.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/utils/is-forced-motion-value.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/utils/scrape-motion-values.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/scrape-motion-values.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/config-motion.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/utils/create-render-state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/config-motion.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/use-props.mjs","webpack://uael/./node_modules/framer-motion/dist/es/motion/utils/valid-prop.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/utils/filter-props.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/use-props.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/use-render.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/components/create-factory.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/reduced-motion/state.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/value-types/find.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/store.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/VisualElement.mjs","webpack://uael/./node_modules/framer-motion/dist/es/utils/reduced-motion/index.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/utils/motion-values.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/DOMVisualElement.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/html/HTMLVisualElement.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/svg/SVGVisualElement.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/dom/create-visual-element.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/components/motion/proxy.mjs","webpack://uael/./node_modules/framer-motion/dist/es/render/components/motion/create.mjs","webpack://uael/./node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs","webpack://uael/./node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs","webpack://uael/./node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs","webpack://uael/./node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/shared/src/utils.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/defaultAttributes.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/Icon.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/createLucideIcon.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/chevron-down.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/menu-item/menu-item.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/dropdown-menu/dropdown-menu.es.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/x.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/badge/badge.es.js","webpack://uael/./node_modules/lucide-react/dist/esm/shared/src/utils.js","webpack://uael/./node_modules/lucide-react/dist/esm/defaultAttributes.js","webpack://uael/./node_modules/lucide-react/dist/esm/Icon.js","webpack://uael/./node_modules/lucide-react/dist/esm/createLucideIcon.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/circle-help.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/file-text.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/headset.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/user.js","webpack://uael/external window [\"wp\",\"i18n\"]","webpack://uael/./src/admin/settings/routes.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/typeof.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/toPropertyKey.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/toPrimitive.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/createClass.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/defineProperty.js","webpack://uael/external window [\"wp\",\"element\"]","webpack://uael/./node_modules/history/index.js","webpack://uael/./src/router/utils.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/extends.js","webpack://uael/./src/router/context.js","webpack://uael/./src/router/route.js","webpack://uael/./src/router/link.js","webpack://uael/./src/router/index.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/classCallCheck.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/inherits.js","webpack://uael/./node_modules/whats-new-rss/dist/react/useWhatsNewRSS.js","webpack://uael/./src/Components/NavMenu.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/container/container-styles.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/container/container-utils.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/container/grid-container.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/container/container.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/title/title.es.js","webpack://uael/./src/Components/HeaderLine.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/label/label.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/switch/switch.es.js","webpack://uael/./node_modules/nanoid/index.browser.js","webpack://uael/./node_modules/nanoid/url-alphabet/index.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/info.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/check.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/triangle-alert.js","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/trash-2.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/button/button.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/toaster/utils.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/tooltip/tooltip.es.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/info.js","webpack://uael/external window [\"wp\",\"apiFetch\"]","webpack://uael/./src/Components/Dashboard/WidgetItem.jsx","webpack://uael/./src/Components/Dashboard/TemplateSection.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/headphones.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/notepad-text.js","webpack://uael/./src/Components/Dashboard/QuickAccess.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/plus.js","webpack://uael/./src/Components/Dashboard/WelcomeContainer.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/iterableToArray.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","webpack://uael/./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js","webpack://uael/external window \"regeneratorRuntime\"","webpack://uael/./node_modules/@bsf/force-ui/dist/components/dialog/dialog.es.js","webpack://uael/./src/Components/Dashboard/ExtendWebsiteWidget.jsx","webpack://uael/./node_modules/@bsf/force-ui/dist/components/skeleton/skeleton.es.js","webpack://uael/./src/Components/Dashboard/ExtendWebsite.jsx","webpack://uael/./node_modules/lucide-react/dist/esm/icons/chevron-left.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/chevron-right.js","webpack://uael/./src/Components/Dashboard/VideoTutorials.jsx","webpack://uael/./node_modules/lucide-react/dist/esm/icons/badge-check.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/settings-2.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/folder-kanban.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/wrench.js","webpack://uael/./src/Components/Dashboard/QuickSettings.jsx","webpack://uael/./node_modules/@bsf/force-ui/dist/components/toaster/controller.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/toaster/component-style.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/hoc/withSingleton.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/toaster/toaster.es.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/loader-circle.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/lock-open.js","webpack://uael/./src/Components/Dashboard/License.jsx","webpack://uael/./src/Components/Dashboard/Dashboard.jsx","webpack://uael/./node_modules/lucide-react/dist/esm/icons/search.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/trash-2.js","webpack://uael/./src/Components/Widgets/Features/FeatureWidgets.jsx","webpack://uael/./src/Components/Widgets/Features.jsx","webpack://uael/./src/Components/Settings/Sidebar.jsx","webpack://uael/./src/Components/Settings/Content.jsx","webpack://uael/./node_modules/goober/dist/goober.modern.js","webpack://uael/./node_modules/react-hot-toast/dist/index.mjs","webpack://uael/./src/Components/Settings/ThemeSupport.jsx","webpack://uael/./src/Components/Settings/VersionControl.jsx","webpack://uael/./src/Components/Settings/UsageTracking.jsx","webpack://uael/./src/Components/Settings/MyAccount.jsx","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/loader-circle.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/loader/loader.es.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/refresh-ccw.js","webpack://uael/./src/Components/Settings/Integrations.jsx","webpack://uael/./src/Components/Settings/Branding.jsx","webpack://uael/./src/Components/Dashboard/PostWidgetItem.jsx","webpack://uael/./src/Components/Settings/PostSkins.jsx","webpack://uael/./node_modules/lucide-react/dist/esm/icons/rotate-cw.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/sun.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/file-pen-line.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/server.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/clock.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/copy.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/external-link.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/check.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/sparkles.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/triangle-alert.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/lock.js","webpack://uael/./src/Components/Settings/AITools.jsx","webpack://uael/./src/Components/Settings/Settings.jsx","webpack://uael/./node_modules/@bsf/force-ui/node_modules/lucide-react/dist/esm/icons/plus.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/progress-steps/utils.es.js","webpack://uael/./node_modules/@bsf/force-ui/dist/components/progress-steps/progress-steps.es.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/x.js","webpack://uael/./node_modules/lucide-react/dist/esm/icons/arrow-right.js","webpack://uael/./src/Components/Dashboard/OnboardingWidgets.jsx","webpack://uael/./src/Components/Dashboard/WidgetsOnboarding.jsx","webpack://uael/./src/Components/Widgets/Features/FeatureWidgetsOnboarding.jsx","webpack://uael/./src/Components/Onboarding/index.js","webpack://uael/./src/Components/Onboarding/Welcome.jsx","webpack://uael/./src/Components/Onboarding/Configure.jsx","webpack://uael/./src/Components/Onboarding/Build.jsx","webpack://uael/./src/Components/Onboarding/Onboarding.jsx","webpack://uael/./src/router/customRouter.js","webpack://uael/./src/App.js","webpack://uael/./src/index.js"],"sourcesContent":["var getProto = Object.getPrototypeOf ? function(obj) { return Object.getPrototypeOf(obj); } : function(obj) { return obj.__proto__; };\nvar leafPrototypes;\n// create a fake namespace object\n// mode & 1: value is a module id, require it\n// mode & 2: merge all properties of value into the ns\n// mode & 4: return value when already ns object\n// mode & 16: return value when it's Promise-like\n// mode & 8|1: behave like require\n__webpack_require__.t = function(value, mode) {\n\tif(mode & 1) value = this(value);\n\tif(mode & 8) return value;\n\tif(typeof value === 'object' && value) {\n\t\tif((mode & 4) && value.__esModule) return value;\n\t\tif((mode & 16) && typeof value.then === 'function') return value;\n\t}\n\tvar ns = Object.create(null);\n\t__webpack_require__.r(ns);\n\tvar def = {};\n\tleafPrototypes = leafPrototypes || [null, getProto({}), getProto([]), getProto(getProto)];\n\tfor(var current = mode & 2 && value; (typeof current == 'object' || typeof current == 'function') && !~leafPrototypes.indexOf(current); current = getProto(current)) {\n\t\tObject.getOwnPropertyNames(current).forEach(function(key) { def[key] = function() { return value[key]; }; });\n\t}\n\tdef['default'] = function() { return value; };\n\t__webpack_require__.d(ns, def);\n\treturn ns;\n};","/**\n * lodash (Custom Build) <https://lodash.com/>\n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors <https://jquery.org/>\n * Released under MIT license <https://lodash.com/license>\n * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>\n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as the `TypeError` message for \"Functions\" methods. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/** Used as references for various `Number` constants. */\nvar NAN = 0 / 0;\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/** Used to match leading and trailing whitespace. */\nvar reTrim = /^\\s+|\\s+$/g;\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/** 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/** 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 objectToString = objectProto.toString;\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 * 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/**\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        result = wait - timeSinceLastCall;\n\n    return maxing ? nativeMin(result, maxWait - timeSinceLastInvoke) : result;\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        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\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 && (type == 'object' || type == 'function');\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 && typeof value == 'object';\n}\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) && objectToString.call(value) == symbolTag);\n}\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 = value.replace(reTrim, '');\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\nmodule.exports = debounce;\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.PathError = exports.TokenData = void 0;\nexports.parse = parse;\nexports.compile = compile;\nexports.match = match;\nexports.pathToRegexp = pathToRegexp;\nexports.stringify = stringify;\nconst DEFAULT_DELIMITER = \"/\";\nconst NOOP_VALUE = (value) => value;\nconst ID_START = /^[$_\\p{ID_Start}]$/u;\nconst ID_CONTINUE = /^[$\\u200c\\u200d\\p{ID_Continue}]$/u;\nconst SIMPLE_TOKENS = {\n    // Groups.\n    \"{\": \"{\",\n    \"}\": \"}\",\n    // Reserved.\n    \"(\": \"(\",\n    \")\": \")\",\n    \"[\": \"[\",\n    \"]\": \"]\",\n    \"+\": \"+\",\n    \"?\": \"?\",\n    \"!\": \"!\",\n};\n/**\n * Escape text for stringify to path.\n */\nfunction escapeText(str) {\n    return str.replace(/[{}()\\[\\]+?!:*\\\\]/g, \"\\\\$&\");\n}\n/**\n * Escape a regular expression string.\n */\nfunction escape(str) {\n    return str.replace(/[.+*?^${}()[\\]|/\\\\]/g, \"\\\\$&\");\n}\n/**\n * Tokenized path instance.\n */\nclass TokenData {\n    constructor(tokens, originalPath) {\n        this.tokens = tokens;\n        this.originalPath = originalPath;\n    }\n}\nexports.TokenData = TokenData;\n/**\n * ParseError is thrown when there is an error processing the path.\n */\nclass PathError extends TypeError {\n    constructor(message, originalPath) {\n        let text = message;\n        if (originalPath)\n            text += `: ${originalPath}`;\n        text += `; visit https://git.new/pathToRegexpError for info`;\n        super(text);\n        this.originalPath = originalPath;\n    }\n}\nexports.PathError = PathError;\n/**\n * Parse a string for the raw tokens.\n */\nfunction parse(str, options = {}) {\n    const { encodePath = NOOP_VALUE } = options;\n    const chars = [...str];\n    const tokens = [];\n    let index = 0;\n    let pos = 0;\n    function name() {\n        let value = \"\";\n        if (ID_START.test(chars[index])) {\n            do {\n                value += chars[index++];\n            } while (ID_CONTINUE.test(chars[index]));\n        }\n        else if (chars[index] === '\"') {\n            let quoteStart = index;\n            while (index++ < chars.length) {\n                if (chars[index] === '\"') {\n                    index++;\n                    quoteStart = 0;\n                    break;\n                }\n                // Increment over escape characters.\n                if (chars[index] === \"\\\\\")\n                    index++;\n                value += chars[index];\n            }\n            if (quoteStart) {\n                throw new PathError(`Unterminated quote at index ${quoteStart}`, str);\n            }\n        }\n        if (!value) {\n            throw new PathError(`Missing parameter name at index ${index}`, str);\n        }\n        return value;\n    }\n    while (index < chars.length) {\n        const value = chars[index];\n        const type = SIMPLE_TOKENS[value];\n        if (type) {\n            tokens.push({ type, index: index++, value });\n        }\n        else if (value === \"\\\\\") {\n            tokens.push({ type: \"escape\", index: index++, value: chars[index++] });\n        }\n        else if (value === \":\") {\n            tokens.push({ type: \"param\", index: index++, value: name() });\n        }\n        else if (value === \"*\") {\n            tokens.push({ type: \"wildcard\", index: index++, value: name() });\n        }\n        else {\n            tokens.push({ type: \"char\", index: index++, value });\n        }\n    }\n    tokens.push({ type: \"end\", index, value: \"\" });\n    function consumeUntil(endType) {\n        const output = [];\n        while (true) {\n            const token = tokens[pos++];\n            if (token.type === endType)\n                break;\n            if (token.type === \"char\" || token.type === \"escape\") {\n                let path = token.value;\n                let cur = tokens[pos];\n                while (cur.type === \"char\" || cur.type === \"escape\") {\n                    path += cur.value;\n                    cur = tokens[++pos];\n                }\n                output.push({\n                    type: \"text\",\n                    value: encodePath(path),\n                });\n                continue;\n            }\n            if (token.type === \"param\" || token.type === \"wildcard\") {\n                output.push({\n                    type: token.type,\n                    name: token.value,\n                });\n                continue;\n            }\n            if (token.type === \"{\") {\n                output.push({\n                    type: \"group\",\n                    tokens: consumeUntil(\"}\"),\n                });\n                continue;\n            }\n            throw new PathError(`Unexpected ${token.type} at index ${token.index}, expected ${endType}`, str);\n        }\n        return output;\n    }\n    return new TokenData(consumeUntil(\"end\"), str);\n}\n/**\n * Compile a string to a template function for the path.\n */\nfunction compile(path, options = {}) {\n    const { encode = encodeURIComponent, delimiter = DEFAULT_DELIMITER } = options;\n    const data = typeof path === \"object\" ? path : parse(path, options);\n    const fn = tokensToFunction(data.tokens, delimiter, encode);\n    return function path(params = {}) {\n        const [path, ...missing] = fn(params);\n        if (missing.length) {\n            throw new TypeError(`Missing parameters: ${missing.join(\", \")}`);\n        }\n        return path;\n    };\n}\nfunction tokensToFunction(tokens, delimiter, encode) {\n    const encoders = tokens.map((token) => tokenToFunction(token, delimiter, encode));\n    return (data) => {\n        const result = [\"\"];\n        for (const encoder of encoders) {\n            const [value, ...extras] = encoder(data);\n            result[0] += value;\n            result.push(...extras);\n        }\n        return result;\n    };\n}\n/**\n * Convert a single token into a path building function.\n */\nfunction tokenToFunction(token, delimiter, encode) {\n    if (token.type === \"text\")\n        return () => [token.value];\n    if (token.type === \"group\") {\n        const fn = tokensToFunction(token.tokens, delimiter, encode);\n        return (data) => {\n            const [value, ...missing] = fn(data);\n            if (!missing.length)\n                return [value];\n            return [\"\"];\n        };\n    }\n    const encodeValue = encode || NOOP_VALUE;\n    if (token.type === \"wildcard\" && encode !== false) {\n        return (data) => {\n            const value = data[token.name];\n            if (value == null)\n                return [\"\", token.name];\n            if (!Array.isArray(value) || value.length === 0) {\n                throw new TypeError(`Expected \"${token.name}\" to be a non-empty array`);\n            }\n            return [\n                value\n                    .map((value, index) => {\n                    if (typeof value !== \"string\") {\n                        throw new TypeError(`Expected \"${token.name}/${index}\" to be a string`);\n                    }\n                    return encodeValue(value);\n                })\n                    .join(delimiter),\n            ];\n        };\n    }\n    return (data) => {\n        const value = data[token.name];\n        if (value == null)\n            return [\"\", token.name];\n        if (typeof value !== \"string\") {\n            throw new TypeError(`Expected \"${token.name}\" to be a string`);\n        }\n        return [encodeValue(value)];\n    };\n}\n/**\n * Transform a path into a match function.\n */\nfunction match(path, options = {}) {\n    const { decode = decodeURIComponent, delimiter = DEFAULT_DELIMITER } = options;\n    const { regexp, keys } = pathToRegexp(path, options);\n    const decoders = keys.map((key) => {\n        if (decode === false)\n            return NOOP_VALUE;\n        if (key.type === \"param\")\n            return decode;\n        return (value) => value.split(delimiter).map(decode);\n    });\n    return function match(input) {\n        const m = regexp.exec(input);\n        if (!m)\n            return false;\n        const path = m[0];\n        const params = Object.create(null);\n        for (let i = 1; i < m.length; i++) {\n            if (m[i] === undefined)\n                continue;\n            const key = keys[i - 1];\n            const decoder = decoders[i - 1];\n            params[key.name] = decoder(m[i]);\n        }\n        return { path, params };\n    };\n}\nfunction pathToRegexp(path, options = {}) {\n    const { delimiter = DEFAULT_DELIMITER, end = true, sensitive = false, trailing = true, } = options;\n    const keys = [];\n    const flags = sensitive ? \"\" : \"i\";\n    const sources = [];\n    for (const input of pathsToArray(path, [])) {\n        const data = typeof input === \"object\" ? input : parse(input, options);\n        for (const tokens of flatten(data.tokens, 0, [])) {\n            sources.push(toRegExpSource(tokens, delimiter, keys, data.originalPath));\n        }\n    }\n    let pattern = `^(?:${sources.join(\"|\")})`;\n    if (trailing)\n        pattern += `(?:${escape(delimiter)}$)?`;\n    pattern += end ? \"$\" : `(?=${escape(delimiter)}|$)`;\n    const regexp = new RegExp(pattern, flags);\n    return { regexp, keys };\n}\n/**\n * Convert a path or array of paths into a flat array.\n */\nfunction pathsToArray(paths, init) {\n    if (Array.isArray(paths)) {\n        for (const p of paths)\n            pathsToArray(p, init);\n    }\n    else {\n        init.push(paths);\n    }\n    return init;\n}\n/**\n * Generate a flat list of sequence tokens from the given tokens.\n */\nfunction* flatten(tokens, index, init) {\n    if (index === tokens.length) {\n        return yield init;\n    }\n    const token = tokens[index];\n    if (token.type === \"group\") {\n        for (const seq of flatten(token.tokens, 0, init.slice())) {\n            yield* flatten(tokens, index + 1, seq);\n        }\n    }\n    else {\n        init.push(token);\n    }\n    yield* flatten(tokens, index + 1, init);\n}\n/**\n * Transform a flat sequence of tokens into a regular expression.\n */\nfunction toRegExpSource(tokens, delimiter, keys, originalPath) {\n    let result = \"\";\n    let backtrack = \"\";\n    let isSafeSegmentParam = true;\n    for (const token of tokens) {\n        if (token.type === \"text\") {\n            result += escape(token.value);\n            backtrack += token.value;\n            isSafeSegmentParam || (isSafeSegmentParam = token.value.includes(delimiter));\n            continue;\n        }\n        if (token.type === \"param\" || token.type === \"wildcard\") {\n            if (!isSafeSegmentParam && !backtrack) {\n                throw new PathError(`Missing text before \"${token.name}\" ${token.type}`, originalPath);\n            }\n            if (token.type === \"param\") {\n                result += `(${negate(delimiter, isSafeSegmentParam ? \"\" : backtrack)}+)`;\n            }\n            else {\n                result += `([\\\\s\\\\S]+)`;\n            }\n            keys.push(token);\n            backtrack = \"\";\n            isSafeSegmentParam = false;\n            continue;\n        }\n    }\n    return result;\n}\n/**\n * Block backtracking on previous text and ignore delimiter string.\n */\nfunction negate(delimiter, backtrack) {\n    if (backtrack.length < 2) {\n        if (delimiter.length < 2)\n            return `[^${escape(delimiter + backtrack)}]`;\n        return `(?:(?!${escape(delimiter)})[^${escape(backtrack)}])`;\n    }\n    if (delimiter.length < 2) {\n        return `(?:(?!${escape(backtrack)})[^${escape(delimiter)}])`;\n    }\n    return `(?:(?!${escape(backtrack)}|${escape(delimiter)})[\\\\s\\\\S])`;\n}\n/**\n * Stringify an array of tokens into a path string.\n */\nfunction stringifyTokens(tokens) {\n    let value = \"\";\n    let i = 0;\n    function name(value) {\n        const isSafe = isNameSafe(value) && isNextNameSafe(tokens[i]);\n        return isSafe ? value : JSON.stringify(value);\n    }\n    while (i < tokens.length) {\n        const token = tokens[i++];\n        if (token.type === \"text\") {\n            value += escapeText(token.value);\n            continue;\n        }\n        if (token.type === \"group\") {\n            value += `{${stringifyTokens(token.tokens)}}`;\n            continue;\n        }\n        if (token.type === \"param\") {\n            value += `:${name(token.name)}`;\n            continue;\n        }\n        if (token.type === \"wildcard\") {\n            value += `*${name(token.name)}`;\n            continue;\n        }\n        throw new TypeError(`Unknown token type: ${token.type}`);\n    }\n    return value;\n}\n/**\n * Stringify token data into a path string.\n */\nfunction stringify(data) {\n    return stringifyTokens(data.tokens);\n}\n/**\n * Validate the parameter name contains valid ID characters.\n */\nfunction isNameSafe(name) {\n    const [first, ...rest] = name;\n    return ID_START.test(first) && rest.every((char) => ID_CONTINUE.test(char));\n}\n/**\n * Validate the next token does not interfere with the current param name.\n */\nfunction isNextNameSafe(token) {\n    if (token && token.type === \"text\")\n        return !ID_CONTINUE.test(token.value[0]);\n    return true;\n}\n//# sourceMappingURL=index.js.map","'use strict';\n\nvar has = Object.prototype.hasOwnProperty\n  , undef;\n\n/**\n * Decode a URI encoded string.\n *\n * @param {String} input The URI encoded string.\n * @returns {String|Null} The decoded string.\n * @api private\n */\nfunction decode(input) {\n  try {\n    return decodeURIComponent(input.replace(/\\+/g, ' '));\n  } catch (e) {\n    return null;\n  }\n}\n\n/**\n * Attempts to encode a given input.\n *\n * @param {String} input The string that needs to be encoded.\n * @returns {String|Null} The encoded string.\n * @api private\n */\nfunction encode(input) {\n  try {\n    return encodeURIComponent(input);\n  } catch (e) {\n    return null;\n  }\n}\n\n/**\n * Simple query string parser.\n *\n * @param {String} query The query string that needs to be parsed.\n * @returns {Object}\n * @api public\n */\nfunction querystring(query) {\n  var parser = /([^=?#&]+)=?([^&]*)/g\n    , result = {}\n    , part;\n\n  while (part = parser.exec(query)) {\n    var key = decode(part[1])\n      , value = decode(part[2]);\n\n    //\n    // Prevent overriding of existing properties. This ensures that build-in\n    // methods like `toString` or __proto__ are not overriden by malicious\n    // querystrings.\n    //\n    // In the case if failed decoding, we want to omit the key/value pairs\n    // from the result.\n    //\n    if (key === null || value === null || key in result) continue;\n    result[key] = value;\n  }\n\n  return result;\n}\n\n/**\n * Transform a query string to an object.\n *\n * @param {Object} obj Object that should be transformed.\n * @param {String} prefix Optional prefix.\n * @returns {String}\n * @api public\n */\nfunction querystringify(obj, prefix) {\n  prefix = prefix || '';\n\n  var pairs = []\n    , value\n    , key;\n\n  //\n  // Optionally prefix with a '?' if needed\n  //\n  if ('string' !== typeof prefix) prefix = '?';\n\n  for (key in obj) {\n    if (has.call(obj, key)) {\n      value = obj[key];\n\n      //\n      // Edge cases where we actually want to encode the value to an empty\n      // string instead of the stringified value.\n      //\n      if (!value && (value === null || value === undef || isNaN(value))) {\n        value = '';\n      }\n\n      key = encode(key);\n      value = encode(value);\n\n      //\n      // If we failed to encode the strings, we should bail out as we don't\n      // want to add invalid strings to the query.\n      //\n      if (key === null || value === null) continue;\n      pairs.push(key +'='+ value);\n    }\n  }\n\n  return pairs.length ? prefix + pairs.join('&') : '';\n}\n\n//\n// Expose the module.\n//\nexports.stringify = querystringify;\nexports.parse = querystring;\n","'use strict';\n\nvar m = require('react-dom');\nif (process.env.NODE_ENV === 'production') {\n  exports.createRoot = m.createRoot;\n  exports.hydrateRoot = m.hydrateRoot;\n} else {\n  var i = m.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;\n  exports.createRoot = function(c, o) {\n    i.usingClientEntryPoint = true;\n    try {\n      return m.createRoot(c, o);\n    } finally {\n      i.usingClientEntryPoint = false;\n    }\n  };\n  exports.hydrateRoot = function(c, h, o) {\n    i.usingClientEntryPoint = true;\n    try {\n      return m.hydrateRoot(c, h, o);\n    } finally {\n      i.usingClientEntryPoint = false;\n    }\n  };\n}\n","/**\n * @license React\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var f=require(\"react\"),k=Symbol.for(\"react.element\"),l=Symbol.for(\"react.fragment\"),m=Object.prototype.hasOwnProperty,n=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,g){var b,d={},e=null,h=null;void 0!==g&&(e=\"\"+g);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(h=a.ref);for(b in a)m.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:k,type:c,key:e,ref:h,props:d,_owner:n.current}}exports.Fragment=l;exports.jsx=q;exports.jsxs=q;\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n  module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n  module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","module.exports = window[\"React\"];","module.exports = window[\"ReactDOM\"];","/*!\n\tCopyright (c) 2018 Jed Watson.\n\tLicensed under the MIT License (MIT), see\n\thttp://jedwatson.github.io/classnames\n*/\n/* global define */\n\n(function () {\n\t'use strict';\n\n\tvar hasOwn = {}.hasOwnProperty;\n\n\tfunction classNames () {\n\t\tvar classes = '';\n\n\t\tfor (var i = 0; i < arguments.length; i++) {\n\t\t\tvar arg = arguments[i];\n\t\t\tif (arg) {\n\t\t\t\tclasses = appendClass(classes, parseValue(arg));\n\t\t\t}\n\t\t}\n\n\t\treturn classes;\n\t}\n\n\tfunction parseValue (arg) {\n\t\tif (typeof arg === 'string' || typeof arg === 'number') {\n\t\t\treturn arg;\n\t\t}\n\n\t\tif (typeof arg !== 'object') {\n\t\t\treturn '';\n\t\t}\n\n\t\tif (Array.isArray(arg)) {\n\t\t\treturn classNames.apply(null, arg);\n\t\t}\n\n\t\tif (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes('[native code]')) {\n\t\t\treturn arg.toString();\n\t\t}\n\n\t\tvar classes = '';\n\n\t\tfor (var key in arg) {\n\t\t\tif (hasOwn.call(arg, key) && arg[key]) {\n\t\t\t\tclasses = appendClass(classes, key);\n\t\t\t}\n\t\t}\n\n\t\treturn classes;\n\t}\n\n\tfunction appendClass (value, newClass) {\n\t\tif (!newClass) {\n\t\t\treturn value;\n\t\t}\n\t\n\t\tif (value) {\n\t\t\treturn value + ' ' + newClass;\n\t\t}\n\t\n\t\treturn value + newClass;\n\t}\n\n\tif (typeof module !== 'undefined' && module.exports) {\n\t\tclassNames.default = classNames;\n\t\tmodule.exports = classNames;\n\t} else if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) {\n\t\t// register as 'classnames', consistent with npm package name\n\t\tdefine('classnames', [], function () {\n\t\t\treturn classNames;\n\t\t});\n\t} else {\n\t\twindow.classNames = classNames;\n\t}\n}());\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"domReady\"];","function _arrayLikeToArray(r, a) {\n  (null == a || a > r.length) && (a = r.length);\n  for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];\n  return n;\n}\nexport { _arrayLikeToArray as default };","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nfunction _unsupportedIterableToArray(r, a) {\n  if (r) {\n    if (\"string\" == typeof r) return arrayLikeToArray(r, a);\n    var t = {}.toString.call(r).slice(8, -1);\n    return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? arrayLikeToArray(r, a) : void 0;\n  }\n}\nexport { _unsupportedIterableToArray as default };","import arrayWithHoles from \"./arrayWithHoles.js\";\nimport iterableToArrayLimit from \"./iterableToArrayLimit.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableRest from \"./nonIterableRest.js\";\nfunction _slicedToArray(r, e) {\n  return arrayWithHoles(r) || iterableToArrayLimit(r, e) || unsupportedIterableToArray(r, e) || nonIterableRest();\n}\nexport { _slicedToArray as default };","function _arrayWithHoles(r) {\n  if (Array.isArray(r)) return r;\n}\nexport { _arrayWithHoles as default };","function _iterableToArrayLimit(r, l) {\n  var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"];\n  if (null != t) {\n    var e,\n      n,\n      i,\n      u,\n      a = [],\n      f = !0,\n      o = !1;\n    try {\n      if (i = (t = t.call(r)).next, 0 === l) {\n        if (Object(t) !== t) return;\n        f = !1;\n      } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);\n    } catch (r) {\n      o = !0, n = r;\n    } finally {\n      try {\n        if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return;\n      } finally {\n        if (o) throw n;\n      }\n    }\n    return a;\n  }\n}\nexport { _iterableToArrayLimit as default };","function _nonIterableRest() {\n  throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\nexport { _nonIterableRest as default };","const CLASS_PART_SEPARATOR = '-';\nconst createClassGroupUtils = config => {\n  const classMap = createClassMap(config);\n  const {\n    conflictingClassGroups,\n    conflictingClassGroupModifiers\n  } = config;\n  const getClassGroupId = className => {\n    const classParts = className.split(CLASS_PART_SEPARATOR);\n    // Classes like `-inset-1` produce an empty string as first classPart. We assume that classes for negative values are used correctly and remove it from classParts.\n    if (classParts[0] === '' && classParts.length !== 1) {\n      classParts.shift();\n    }\n    return getGroupRecursive(classParts, classMap) || getGroupIdForArbitraryProperty(className);\n  };\n  const getConflictingClassGroupIds = (classGroupId, hasPostfixModifier) => {\n    const conflicts = conflictingClassGroups[classGroupId] || [];\n    if (hasPostfixModifier && conflictingClassGroupModifiers[classGroupId]) {\n      return [...conflicts, ...conflictingClassGroupModifiers[classGroupId]];\n    }\n    return conflicts;\n  };\n  return {\n    getClassGroupId,\n    getConflictingClassGroupIds\n  };\n};\nconst getGroupRecursive = (classParts, classPartObject) => {\n  if (classParts.length === 0) {\n    return classPartObject.classGroupId;\n  }\n  const currentClassPart = classParts[0];\n  const nextClassPartObject = classPartObject.nextPart.get(currentClassPart);\n  const classGroupFromNextClassPart = nextClassPartObject ? getGroupRecursive(classParts.slice(1), nextClassPartObject) : undefined;\n  if (classGroupFromNextClassPart) {\n    return classGroupFromNextClassPart;\n  }\n  if (classPartObject.validators.length === 0) {\n    return undefined;\n  }\n  const classRest = classParts.join(CLASS_PART_SEPARATOR);\n  return classPartObject.validators.find(({\n    validator\n  }) => validator(classRest))?.classGroupId;\n};\nconst arbitraryPropertyRegex = /^\\[(.+)\\]$/;\nconst getGroupIdForArbitraryProperty = className => {\n  if (arbitraryPropertyRegex.test(className)) {\n    const arbitraryPropertyClassName = arbitraryPropertyRegex.exec(className)[1];\n    const property = arbitraryPropertyClassName?.substring(0, arbitraryPropertyClassName.indexOf(':'));\n    if (property) {\n      // I use two dots here because one dot is used as prefix for class groups in plugins\n      return 'arbitrary..' + property;\n    }\n  }\n};\n/**\n * Exported for testing only\n */\nconst createClassMap = config => {\n  const {\n    theme,\n    prefix\n  } = config;\n  const classMap = {\n    nextPart: new Map(),\n    validators: []\n  };\n  const prefixedClassGroupEntries = getPrefixedClassGroupEntries(Object.entries(config.classGroups), prefix);\n  prefixedClassGroupEntries.forEach(([classGroupId, classGroup]) => {\n    processClassesRecursively(classGroup, classMap, classGroupId, theme);\n  });\n  return classMap;\n};\nconst processClassesRecursively = (classGroup, classPartObject, classGroupId, theme) => {\n  classGroup.forEach(classDefinition => {\n    if (typeof classDefinition === 'string') {\n      const classPartObjectToEdit = classDefinition === '' ? classPartObject : getPart(classPartObject, classDefinition);\n      classPartObjectToEdit.classGroupId = classGroupId;\n      return;\n    }\n    if (typeof classDefinition === 'function') {\n      if (isThemeGetter(classDefinition)) {\n        processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme);\n        return;\n      }\n      classPartObject.validators.push({\n        validator: classDefinition,\n        classGroupId\n      });\n      return;\n    }\n    Object.entries(classDefinition).forEach(([key, classGroup]) => {\n      processClassesRecursively(classGroup, getPart(classPartObject, key), classGroupId, theme);\n    });\n  });\n};\nconst getPart = (classPartObject, path) => {\n  let currentClassPartObject = classPartObject;\n  path.split(CLASS_PART_SEPARATOR).forEach(pathPart => {\n    if (!currentClassPartObject.nextPart.has(pathPart)) {\n      currentClassPartObject.nextPart.set(pathPart, {\n        nextPart: new Map(),\n        validators: []\n      });\n    }\n    currentClassPartObject = currentClassPartObject.nextPart.get(pathPart);\n  });\n  return currentClassPartObject;\n};\nconst isThemeGetter = func => func.isThemeGetter;\nconst getPrefixedClassGroupEntries = (classGroupEntries, prefix) => {\n  if (!prefix) {\n    return classGroupEntries;\n  }\n  return classGroupEntries.map(([classGroupId, classGroup]) => {\n    const prefixedClassGroup = classGroup.map(classDefinition => {\n      if (typeof classDefinition === 'string') {\n        return prefix + classDefinition;\n      }\n      if (typeof classDefinition === 'object') {\n        return Object.fromEntries(Object.entries(classDefinition).map(([key, value]) => [prefix + key, value]));\n      }\n      return classDefinition;\n    });\n    return [classGroupId, prefixedClassGroup];\n  });\n};\n\n// LRU cache inspired from hashlru (https://github.com/dominictarr/hashlru/blob/v1.0.4/index.js) but object replaced with Map to improve performance\nconst createLruCache = maxCacheSize => {\n  if (maxCacheSize < 1) {\n    return {\n      get: () => undefined,\n      set: () => {}\n    };\n  }\n  let cacheSize = 0;\n  let cache = new Map();\n  let previousCache = new Map();\n  const update = (key, value) => {\n    cache.set(key, value);\n    cacheSize++;\n    if (cacheSize > maxCacheSize) {\n      cacheSize = 0;\n      previousCache = cache;\n      cache = new Map();\n    }\n  };\n  return {\n    get(key) {\n      let value = cache.get(key);\n      if (value !== undefined) {\n        return value;\n      }\n      if ((value = previousCache.get(key)) !== undefined) {\n        update(key, value);\n        return value;\n      }\n    },\n    set(key, value) {\n      if (cache.has(key)) {\n        cache.set(key, value);\n      } else {\n        update(key, value);\n      }\n    }\n  };\n};\nconst IMPORTANT_MODIFIER = '!';\nconst createParseClassName = config => {\n  const {\n    separator,\n    experimentalParseClassName\n  } = config;\n  const isSeparatorSingleCharacter = separator.length === 1;\n  const firstSeparatorCharacter = separator[0];\n  const separatorLength = separator.length;\n  // parseClassName inspired by https://github.com/tailwindlabs/tailwindcss/blob/v3.2.2/src/util/splitAtTopLevelOnly.js\n  const parseClassName = className => {\n    const modifiers = [];\n    let bracketDepth = 0;\n    let modifierStart = 0;\n    let postfixModifierPosition;\n    for (let index = 0; index < className.length; index++) {\n      let currentCharacter = className[index];\n      if (bracketDepth === 0) {\n        if (currentCharacter === firstSeparatorCharacter && (isSeparatorSingleCharacter || className.slice(index, index + separatorLength) === separator)) {\n          modifiers.push(className.slice(modifierStart, index));\n          modifierStart = index + separatorLength;\n          continue;\n        }\n        if (currentCharacter === '/') {\n          postfixModifierPosition = index;\n          continue;\n        }\n      }\n      if (currentCharacter === '[') {\n        bracketDepth++;\n      } else if (currentCharacter === ']') {\n        bracketDepth--;\n      }\n    }\n    const baseClassNameWithImportantModifier = modifiers.length === 0 ? className : className.substring(modifierStart);\n    const hasImportantModifier = baseClassNameWithImportantModifier.startsWith(IMPORTANT_MODIFIER);\n    const baseClassName = hasImportantModifier ? baseClassNameWithImportantModifier.substring(1) : baseClassNameWithImportantModifier;\n    const maybePostfixModifierPosition = postfixModifierPosition && postfixModifierPosition > modifierStart ? postfixModifierPosition - modifierStart : undefined;\n    return {\n      modifiers,\n      hasImportantModifier,\n      baseClassName,\n      maybePostfixModifierPosition\n    };\n  };\n  if (experimentalParseClassName) {\n    return className => experimentalParseClassName({\n      className,\n      parseClassName\n    });\n  }\n  return parseClassName;\n};\n/**\n * Sorts modifiers according to following schema:\n * - Predefined modifiers are sorted alphabetically\n * - When an arbitrary variant appears, it must be preserved which modifiers are before and after it\n */\nconst sortModifiers = modifiers => {\n  if (modifiers.length <= 1) {\n    return modifiers;\n  }\n  const sortedModifiers = [];\n  let unsortedModifiers = [];\n  modifiers.forEach(modifier => {\n    const isArbitraryVariant = modifier[0] === '[';\n    if (isArbitraryVariant) {\n      sortedModifiers.push(...unsortedModifiers.sort(), modifier);\n      unsortedModifiers = [];\n    } else {\n      unsortedModifiers.push(modifier);\n    }\n  });\n  sortedModifiers.push(...unsortedModifiers.sort());\n  return sortedModifiers;\n};\nconst createConfigUtils = config => ({\n  cache: createLruCache(config.cacheSize),\n  parseClassName: createParseClassName(config),\n  ...createClassGroupUtils(config)\n});\nconst SPLIT_CLASSES_REGEX = /\\s+/;\nconst mergeClassList = (classList, configUtils) => {\n  const {\n    parseClassName,\n    getClassGroupId,\n    getConflictingClassGroupIds\n  } = configUtils;\n  /**\n   * Set of classGroupIds in following format:\n   * `{importantModifier}{variantModifiers}{classGroupId}`\n   * @example 'float'\n   * @example 'hover:focus:bg-color'\n   * @example 'md:!pr'\n   */\n  const classGroupsInConflict = [];\n  const classNames = classList.trim().split(SPLIT_CLASSES_REGEX);\n  let result = '';\n  for (let index = classNames.length - 1; index >= 0; index -= 1) {\n    const originalClassName = classNames[index];\n    const {\n      modifiers,\n      hasImportantModifier,\n      baseClassName,\n      maybePostfixModifierPosition\n    } = parseClassName(originalClassName);\n    let hasPostfixModifier = Boolean(maybePostfixModifierPosition);\n    let classGroupId = getClassGroupId(hasPostfixModifier ? baseClassName.substring(0, maybePostfixModifierPosition) : baseClassName);\n    if (!classGroupId) {\n      if (!hasPostfixModifier) {\n        // Not a Tailwind class\n        result = originalClassName + (result.length > 0 ? ' ' + result : result);\n        continue;\n      }\n      classGroupId = getClassGroupId(baseClassName);\n      if (!classGroupId) {\n        // Not a Tailwind class\n        result = originalClassName + (result.length > 0 ? ' ' + result : result);\n        continue;\n      }\n      hasPostfixModifier = false;\n    }\n    const variantModifier = sortModifiers(modifiers).join(':');\n    const modifierId = hasImportantModifier ? variantModifier + IMPORTANT_MODIFIER : variantModifier;\n    const classId = modifierId + classGroupId;\n    if (classGroupsInConflict.includes(classId)) {\n      // Tailwind class omitted due to conflict\n      continue;\n    }\n    classGroupsInConflict.push(classId);\n    const conflictGroups = getConflictingClassGroupIds(classGroupId, hasPostfixModifier);\n    for (let i = 0; i < conflictGroups.length; ++i) {\n      const group = conflictGroups[i];\n      classGroupsInConflict.push(modifierId + group);\n    }\n    // Tailwind class not in conflict\n    result = originalClassName + (result.length > 0 ? ' ' + result : result);\n  }\n  return result;\n};\n\n/**\n * The code in this file is copied from https://github.com/lukeed/clsx and modified to suit the needs of tailwind-merge better.\n *\n * Specifically:\n * - Runtime code from https://github.com/lukeed/clsx/blob/v1.2.1/src/index.js\n * - TypeScript types from https://github.com/lukeed/clsx/blob/v1.2.1/clsx.d.ts\n *\n * Original code has MIT license: Copyright (c) Luke Edwards <luke.edwards05@gmail.com> (lukeed.com)\n */\nfunction twJoin() {\n  let index = 0;\n  let argument;\n  let resolvedValue;\n  let string = '';\n  while (index < arguments.length) {\n    if (argument = arguments[index++]) {\n      if (resolvedValue = toValue(argument)) {\n        string && (string += ' ');\n        string += resolvedValue;\n      }\n    }\n  }\n  return string;\n}\nconst toValue = mix => {\n  if (typeof mix === 'string') {\n    return mix;\n  }\n  let resolvedValue;\n  let string = '';\n  for (let k = 0; k < mix.length; k++) {\n    if (mix[k]) {\n      if (resolvedValue = toValue(mix[k])) {\n        string && (string += ' ');\n        string += resolvedValue;\n      }\n    }\n  }\n  return string;\n};\nfunction createTailwindMerge(createConfigFirst, ...createConfigRest) {\n  let configUtils;\n  let cacheGet;\n  let cacheSet;\n  let functionToCall = initTailwindMerge;\n  function initTailwindMerge(classList) {\n    const config = createConfigRest.reduce((previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig), createConfigFirst());\n    configUtils = createConfigUtils(config);\n    cacheGet = configUtils.cache.get;\n    cacheSet = configUtils.cache.set;\n    functionToCall = tailwindMerge;\n    return tailwindMerge(classList);\n  }\n  function tailwindMerge(classList) {\n    const cachedResult = cacheGet(classList);\n    if (cachedResult) {\n      return cachedResult;\n    }\n    const result = mergeClassList(classList, configUtils);\n    cacheSet(classList, result);\n    return result;\n  }\n  return function callTailwindMerge() {\n    return functionToCall(twJoin.apply(null, arguments));\n  };\n}\nconst fromTheme = key => {\n  const themeGetter = theme => theme[key] || [];\n  themeGetter.isThemeGetter = true;\n  return themeGetter;\n};\nconst arbitraryValueRegex = /^\\[(?:([a-z-]+):)?(.+)\\]$/i;\nconst fractionRegex = /^\\d+\\/\\d+$/;\nconst stringLengths = /*#__PURE__*/new Set(['px', 'full', 'screen']);\nconst tshirtUnitRegex = /^(\\d+(\\.\\d+)?)?(xs|sm|md|lg|xl)$/;\nconst lengthUnitRegex = /\\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\\b(calc|min|max|clamp)\\(.+\\)|^0$/;\nconst colorFunctionRegex = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\\(.+\\)$/;\n// Shadow always begins with x and y offset separated by underscore optionally prepended by inset\nconst shadowRegex = /^(inset_)?-?((\\d+)?\\.?(\\d+)[a-z]+|0)_-?((\\d+)?\\.?(\\d+)[a-z]+|0)/;\nconst imageRegex = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\\(.+\\)$/;\nconst isLength = value => isNumber(value) || stringLengths.has(value) || fractionRegex.test(value);\nconst isArbitraryLength = value => getIsArbitraryValue(value, 'length', isLengthOnly);\nconst isNumber = value => Boolean(value) && !Number.isNaN(Number(value));\nconst isArbitraryNumber = value => getIsArbitraryValue(value, 'number', isNumber);\nconst isInteger = value => Boolean(value) && Number.isInteger(Number(value));\nconst isPercent = value => value.endsWith('%') && isNumber(value.slice(0, -1));\nconst isArbitraryValue = value => arbitraryValueRegex.test(value);\nconst isTshirtSize = value => tshirtUnitRegex.test(value);\nconst sizeLabels = /*#__PURE__*/new Set(['length', 'size', 'percentage']);\nconst isArbitrarySize = value => getIsArbitraryValue(value, sizeLabels, isNever);\nconst isArbitraryPosition = value => getIsArbitraryValue(value, 'position', isNever);\nconst imageLabels = /*#__PURE__*/new Set(['image', 'url']);\nconst isArbitraryImage = value => getIsArbitraryValue(value, imageLabels, isImage);\nconst isArbitraryShadow = value => getIsArbitraryValue(value, '', isShadow);\nconst isAny = () => true;\nconst getIsArbitraryValue = (value, label, testValue) => {\n  const result = arbitraryValueRegex.exec(value);\n  if (result) {\n    if (result[1]) {\n      return typeof label === 'string' ? result[1] === label : label.has(result[1]);\n    }\n    return testValue(result[2]);\n  }\n  return false;\n};\nconst isLengthOnly = value =>\n// `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.\n// For example, `hsl(0 0% 0%)` would be classified as a length without this check.\n// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.\nlengthUnitRegex.test(value) && !colorFunctionRegex.test(value);\nconst isNever = () => false;\nconst isShadow = value => shadowRegex.test(value);\nconst isImage = value => imageRegex.test(value);\nconst validators = /*#__PURE__*/Object.defineProperty({\n  __proto__: null,\n  isAny,\n  isArbitraryImage,\n  isArbitraryLength,\n  isArbitraryNumber,\n  isArbitraryPosition,\n  isArbitraryShadow,\n  isArbitrarySize,\n  isArbitraryValue,\n  isInteger,\n  isLength,\n  isNumber,\n  isPercent,\n  isTshirtSize\n}, Symbol.toStringTag, {\n  value: 'Module'\n});\nconst getDefaultConfig = () => {\n  const colors = fromTheme('colors');\n  const spacing = fromTheme('spacing');\n  const blur = fromTheme('blur');\n  const brightness = fromTheme('brightness');\n  const borderColor = fromTheme('borderColor');\n  const borderRadius = fromTheme('borderRadius');\n  const borderSpacing = fromTheme('borderSpacing');\n  const borderWidth = fromTheme('borderWidth');\n  const contrast = fromTheme('contrast');\n  const grayscale = fromTheme('grayscale');\n  const hueRotate = fromTheme('hueRotate');\n  const invert = fromTheme('invert');\n  const gap = fromTheme('gap');\n  const gradientColorStops = fromTheme('gradientColorStops');\n  const gradientColorStopPositions = fromTheme('gradientColorStopPositions');\n  const inset = fromTheme('inset');\n  const margin = fromTheme('margin');\n  const opacity = fromTheme('opacity');\n  const padding = fromTheme('padding');\n  const saturate = fromTheme('saturate');\n  const scale = fromTheme('scale');\n  const sepia = fromTheme('sepia');\n  const skew = fromTheme('skew');\n  const space = fromTheme('space');\n  const translate = fromTheme('translate');\n  const getOverscroll = () => ['auto', 'contain', 'none'];\n  const getOverflow = () => ['auto', 'hidden', 'clip', 'visible', 'scroll'];\n  const getSpacingWithAutoAndArbitrary = () => ['auto', isArbitraryValue, spacing];\n  const getSpacingWithArbitrary = () => [isArbitraryValue, spacing];\n  const getLengthWithEmptyAndArbitrary = () => ['', isLength, isArbitraryLength];\n  const getNumberWithAutoAndArbitrary = () => ['auto', isNumber, isArbitraryValue];\n  const getPositions = () => ['bottom', 'center', 'left', 'left-bottom', 'left-top', 'right', 'right-bottom', 'right-top', 'top'];\n  const getLineStyles = () => ['solid', 'dashed', 'dotted', 'double', 'none'];\n  const getBlendModes = () => ['normal', 'multiply', 'screen', 'overlay', 'darken', 'lighten', 'color-dodge', 'color-burn', 'hard-light', 'soft-light', 'difference', 'exclusion', 'hue', 'saturation', 'color', 'luminosity'];\n  const getAlign = () => ['start', 'end', 'center', 'between', 'around', 'evenly', 'stretch'];\n  const getZeroAndEmpty = () => ['', '0', isArbitraryValue];\n  const getBreaks = () => ['auto', 'avoid', 'all', 'avoid-page', 'page', 'left', 'right', 'column'];\n  const getNumberAndArbitrary = () => [isNumber, isArbitraryValue];\n  return {\n    cacheSize: 500,\n    separator: ':',\n    theme: {\n      colors: [isAny],\n      spacing: [isLength, isArbitraryLength],\n      blur: ['none', '', isTshirtSize, isArbitraryValue],\n      brightness: getNumberAndArbitrary(),\n      borderColor: [colors],\n      borderRadius: ['none', '', 'full', isTshirtSize, isArbitraryValue],\n      borderSpacing: getSpacingWithArbitrary(),\n      borderWidth: getLengthWithEmptyAndArbitrary(),\n      contrast: getNumberAndArbitrary(),\n      grayscale: getZeroAndEmpty(),\n      hueRotate: getNumberAndArbitrary(),\n      invert: getZeroAndEmpty(),\n      gap: getSpacingWithArbitrary(),\n      gradientColorStops: [colors],\n      gradientColorStopPositions: [isPercent, isArbitraryLength],\n      inset: getSpacingWithAutoAndArbitrary(),\n      margin: getSpacingWithAutoAndArbitrary(),\n      opacity: getNumberAndArbitrary(),\n      padding: getSpacingWithArbitrary(),\n      saturate: getNumberAndArbitrary(),\n      scale: getNumberAndArbitrary(),\n      sepia: getZeroAndEmpty(),\n      skew: getNumberAndArbitrary(),\n      space: getSpacingWithArbitrary(),\n      translate: getSpacingWithArbitrary()\n    },\n    classGroups: {\n      // Layout\n      /**\n       * Aspect Ratio\n       * @see https://tailwindcss.com/docs/aspect-ratio\n       */\n      aspect: [{\n        aspect: ['auto', 'square', 'video', isArbitraryValue]\n      }],\n      /**\n       * Container\n       * @see https://tailwindcss.com/docs/container\n       */\n      container: ['container'],\n      /**\n       * Columns\n       * @see https://tailwindcss.com/docs/columns\n       */\n      columns: [{\n        columns: [isTshirtSize]\n      }],\n      /**\n       * Break After\n       * @see https://tailwindcss.com/docs/break-after\n       */\n      'break-after': [{\n        'break-after': getBreaks()\n      }],\n      /**\n       * Break Before\n       * @see https://tailwindcss.com/docs/break-before\n       */\n      'break-before': [{\n        'break-before': getBreaks()\n      }],\n      /**\n       * Break Inside\n       * @see https://tailwindcss.com/docs/break-inside\n       */\n      'break-inside': [{\n        'break-inside': ['auto', 'avoid', 'avoid-page', 'avoid-column']\n      }],\n      /**\n       * Box Decoration Break\n       * @see https://tailwindcss.com/docs/box-decoration-break\n       */\n      'box-decoration': [{\n        'box-decoration': ['slice', 'clone']\n      }],\n      /**\n       * Box Sizing\n       * @see https://tailwindcss.com/docs/box-sizing\n       */\n      box: [{\n        box: ['border', 'content']\n      }],\n      /**\n       * Display\n       * @see https://tailwindcss.com/docs/display\n       */\n      display: ['block', 'inline-block', 'inline', 'flex', 'inline-flex', 'table', 'inline-table', 'table-caption', 'table-cell', 'table-column', 'table-column-group', 'table-footer-group', 'table-header-group', 'table-row-group', 'table-row', 'flow-root', 'grid', 'inline-grid', 'contents', 'list-item', 'hidden'],\n      /**\n       * Floats\n       * @see https://tailwindcss.com/docs/float\n       */\n      float: [{\n        float: ['right', 'left', 'none', 'start', 'end']\n      }],\n      /**\n       * Clear\n       * @see https://tailwindcss.com/docs/clear\n       */\n      clear: [{\n        clear: ['left', 'right', 'both', 'none', 'start', 'end']\n      }],\n      /**\n       * Isolation\n       * @see https://tailwindcss.com/docs/isolation\n       */\n      isolation: ['isolate', 'isolation-auto'],\n      /**\n       * Object Fit\n       * @see https://tailwindcss.com/docs/object-fit\n       */\n      'object-fit': [{\n        object: ['contain', 'cover', 'fill', 'none', 'scale-down']\n      }],\n      /**\n       * Object Position\n       * @see https://tailwindcss.com/docs/object-position\n       */\n      'object-position': [{\n        object: [...getPositions(), isArbitraryValue]\n      }],\n      /**\n       * Overflow\n       * @see https://tailwindcss.com/docs/overflow\n       */\n      overflow: [{\n        overflow: getOverflow()\n      }],\n      /**\n       * Overflow X\n       * @see https://tailwindcss.com/docs/overflow\n       */\n      'overflow-x': [{\n        'overflow-x': getOverflow()\n      }],\n      /**\n       * Overflow Y\n       * @see https://tailwindcss.com/docs/overflow\n       */\n      'overflow-y': [{\n        'overflow-y': getOverflow()\n      }],\n      /**\n       * Overscroll Behavior\n       * @see https://tailwindcss.com/docs/overscroll-behavior\n       */\n      overscroll: [{\n        overscroll: getOverscroll()\n      }],\n      /**\n       * Overscroll Behavior X\n       * @see https://tailwindcss.com/docs/overscroll-behavior\n       */\n      'overscroll-x': [{\n        'overscroll-x': getOverscroll()\n      }],\n      /**\n       * Overscroll Behavior Y\n       * @see https://tailwindcss.com/docs/overscroll-behavior\n       */\n      'overscroll-y': [{\n        'overscroll-y': getOverscroll()\n      }],\n      /**\n       * Position\n       * @see https://tailwindcss.com/docs/position\n       */\n      position: ['static', 'fixed', 'absolute', 'relative', 'sticky'],\n      /**\n       * Top / Right / Bottom / Left\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      inset: [{\n        inset: [inset]\n      }],\n      /**\n       * Right / Left\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      'inset-x': [{\n        'inset-x': [inset]\n      }],\n      /**\n       * Top / Bottom\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      'inset-y': [{\n        'inset-y': [inset]\n      }],\n      /**\n       * Start\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      start: [{\n        start: [inset]\n      }],\n      /**\n       * End\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      end: [{\n        end: [inset]\n      }],\n      /**\n       * Top\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      top: [{\n        top: [inset]\n      }],\n      /**\n       * Right\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      right: [{\n        right: [inset]\n      }],\n      /**\n       * Bottom\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      bottom: [{\n        bottom: [inset]\n      }],\n      /**\n       * Left\n       * @see https://tailwindcss.com/docs/top-right-bottom-left\n       */\n      left: [{\n        left: [inset]\n      }],\n      /**\n       * Visibility\n       * @see https://tailwindcss.com/docs/visibility\n       */\n      visibility: ['visible', 'invisible', 'collapse'],\n      /**\n       * Z-Index\n       * @see https://tailwindcss.com/docs/z-index\n       */\n      z: [{\n        z: ['auto', isInteger, isArbitraryValue]\n      }],\n      // Flexbox and Grid\n      /**\n       * Flex Basis\n       * @see https://tailwindcss.com/docs/flex-basis\n       */\n      basis: [{\n        basis: getSpacingWithAutoAndArbitrary()\n      }],\n      /**\n       * Flex Direction\n       * @see https://tailwindcss.com/docs/flex-direction\n       */\n      'flex-direction': [{\n        flex: ['row', 'row-reverse', 'col', 'col-reverse']\n      }],\n      /**\n       * Flex Wrap\n       * @see https://tailwindcss.com/docs/flex-wrap\n       */\n      'flex-wrap': [{\n        flex: ['wrap', 'wrap-reverse', 'nowrap']\n      }],\n      /**\n       * Flex\n       * @see https://tailwindcss.com/docs/flex\n       */\n      flex: [{\n        flex: ['1', 'auto', 'initial', 'none', isArbitraryValue]\n      }],\n      /**\n       * Flex Grow\n       * @see https://tailwindcss.com/docs/flex-grow\n       */\n      grow: [{\n        grow: getZeroAndEmpty()\n      }],\n      /**\n       * Flex Shrink\n       * @see https://tailwindcss.com/docs/flex-shrink\n       */\n      shrink: [{\n        shrink: getZeroAndEmpty()\n      }],\n      /**\n       * Order\n       * @see https://tailwindcss.com/docs/order\n       */\n      order: [{\n        order: ['first', 'last', 'none', isInteger, isArbitraryValue]\n      }],\n      /**\n       * Grid Template Columns\n       * @see https://tailwindcss.com/docs/grid-template-columns\n       */\n      'grid-cols': [{\n        'grid-cols': [isAny]\n      }],\n      /**\n       * Grid Column Start / End\n       * @see https://tailwindcss.com/docs/grid-column\n       */\n      'col-start-end': [{\n        col: ['auto', {\n          span: ['full', isInteger, isArbitraryValue]\n        }, isArbitraryValue]\n      }],\n      /**\n       * Grid Column Start\n       * @see https://tailwindcss.com/docs/grid-column\n       */\n      'col-start': [{\n        'col-start': getNumberWithAutoAndArbitrary()\n      }],\n      /**\n       * Grid Column End\n       * @see https://tailwindcss.com/docs/grid-column\n       */\n      'col-end': [{\n        'col-end': getNumberWithAutoAndArbitrary()\n      }],\n      /**\n       * Grid Template Rows\n       * @see https://tailwindcss.com/docs/grid-template-rows\n       */\n      'grid-rows': [{\n        'grid-rows': [isAny]\n      }],\n      /**\n       * Grid Row Start / End\n       * @see https://tailwindcss.com/docs/grid-row\n       */\n      'row-start-end': [{\n        row: ['auto', {\n          span: [isInteger, isArbitraryValue]\n        }, isArbitraryValue]\n      }],\n      /**\n       * Grid Row Start\n       * @see https://tailwindcss.com/docs/grid-row\n       */\n      'row-start': [{\n        'row-start': getNumberWithAutoAndArbitrary()\n      }],\n      /**\n       * Grid Row End\n       * @see https://tailwindcss.com/docs/grid-row\n       */\n      'row-end': [{\n        'row-end': getNumberWithAutoAndArbitrary()\n      }],\n      /**\n       * Grid Auto Flow\n       * @see https://tailwindcss.com/docs/grid-auto-flow\n       */\n      'grid-flow': [{\n        'grid-flow': ['row', 'col', 'dense', 'row-dense', 'col-dense']\n      }],\n      /**\n       * Grid Auto Columns\n       * @see https://tailwindcss.com/docs/grid-auto-columns\n       */\n      'auto-cols': [{\n        'auto-cols': ['auto', 'min', 'max', 'fr', isArbitraryValue]\n      }],\n      /**\n       * Grid Auto Rows\n       * @see https://tailwindcss.com/docs/grid-auto-rows\n       */\n      'auto-rows': [{\n        'auto-rows': ['auto', 'min', 'max', 'fr', isArbitraryValue]\n      }],\n      /**\n       * Gap\n       * @see https://tailwindcss.com/docs/gap\n       */\n      gap: [{\n        gap: [gap]\n      }],\n      /**\n       * Gap X\n       * @see https://tailwindcss.com/docs/gap\n       */\n      'gap-x': [{\n        'gap-x': [gap]\n      }],\n      /**\n       * Gap Y\n       * @see https://tailwindcss.com/docs/gap\n       */\n      'gap-y': [{\n        'gap-y': [gap]\n      }],\n      /**\n       * Justify Content\n       * @see https://tailwindcss.com/docs/justify-content\n       */\n      'justify-content': [{\n        justify: ['normal', ...getAlign()]\n      }],\n      /**\n       * Justify Items\n       * @see https://tailwindcss.com/docs/justify-items\n       */\n      'justify-items': [{\n        'justify-items': ['start', 'end', 'center', 'stretch']\n      }],\n      /**\n       * Justify Self\n       * @see https://tailwindcss.com/docs/justify-self\n       */\n      'justify-self': [{\n        'justify-self': ['auto', 'start', 'end', 'center', 'stretch']\n      }],\n      /**\n       * Align Content\n       * @see https://tailwindcss.com/docs/align-content\n       */\n      'align-content': [{\n        content: ['normal', ...getAlign(), 'baseline']\n      }],\n      /**\n       * Align Items\n       * @see https://tailwindcss.com/docs/align-items\n       */\n      'align-items': [{\n        items: ['start', 'end', 'center', 'baseline', 'stretch']\n      }],\n      /**\n       * Align Self\n       * @see https://tailwindcss.com/docs/align-self\n       */\n      'align-self': [{\n        self: ['auto', 'start', 'end', 'center', 'stretch', 'baseline']\n      }],\n      /**\n       * Place Content\n       * @see https://tailwindcss.com/docs/place-content\n       */\n      'place-content': [{\n        'place-content': [...getAlign(), 'baseline']\n      }],\n      /**\n       * Place Items\n       * @see https://tailwindcss.com/docs/place-items\n       */\n      'place-items': [{\n        'place-items': ['start', 'end', 'center', 'baseline', 'stretch']\n      }],\n      /**\n       * Place Self\n       * @see https://tailwindcss.com/docs/place-self\n       */\n      'place-self': [{\n        'place-self': ['auto', 'start', 'end', 'center', 'stretch']\n      }],\n      // Spacing\n      /**\n       * Padding\n       * @see https://tailwindcss.com/docs/padding\n       */\n      p: [{\n        p: [padding]\n      }],\n      /**\n       * Padding X\n       * @see https://tailwindcss.com/docs/padding\n       */\n      px: [{\n        px: [padding]\n      }],\n      /**\n       * Padding Y\n       * @see https://tailwindcss.com/docs/padding\n       */\n      py: [{\n        py: [padding]\n      }],\n      /**\n       * Padding Start\n       * @see https://tailwindcss.com/docs/padding\n       */\n      ps: [{\n        ps: [padding]\n      }],\n      /**\n       * Padding End\n       * @see https://tailwindcss.com/docs/padding\n       */\n      pe: [{\n        pe: [padding]\n      }],\n      /**\n       * Padding Top\n       * @see https://tailwindcss.com/docs/padding\n       */\n      pt: [{\n        pt: [padding]\n      }],\n      /**\n       * Padding Right\n       * @see https://tailwindcss.com/docs/padding\n       */\n      pr: [{\n        pr: [padding]\n      }],\n      /**\n       * Padding Bottom\n       * @see https://tailwindcss.com/docs/padding\n       */\n      pb: [{\n        pb: [padding]\n      }],\n      /**\n       * Padding Left\n       * @see https://tailwindcss.com/docs/padding\n       */\n      pl: [{\n        pl: [padding]\n      }],\n      /**\n       * Margin\n       * @see https://tailwindcss.com/docs/margin\n       */\n      m: [{\n        m: [margin]\n      }],\n      /**\n       * Margin X\n       * @see https://tailwindcss.com/docs/margin\n       */\n      mx: [{\n        mx: [margin]\n      }],\n      /**\n       * Margin Y\n       * @see https://tailwindcss.com/docs/margin\n       */\n      my: [{\n        my: [margin]\n      }],\n      /**\n       * Margin Start\n       * @see https://tailwindcss.com/docs/margin\n       */\n      ms: [{\n        ms: [margin]\n      }],\n      /**\n       * Margin End\n       * @see https://tailwindcss.com/docs/margin\n       */\n      me: [{\n        me: [margin]\n      }],\n      /**\n       * Margin Top\n       * @see https://tailwindcss.com/docs/margin\n       */\n      mt: [{\n        mt: [margin]\n      }],\n      /**\n       * Margin Right\n       * @see https://tailwindcss.com/docs/margin\n       */\n      mr: [{\n        mr: [margin]\n      }],\n      /**\n       * Margin Bottom\n       * @see https://tailwindcss.com/docs/margin\n       */\n      mb: [{\n        mb: [margin]\n      }],\n      /**\n       * Margin Left\n       * @see https://tailwindcss.com/docs/margin\n       */\n      ml: [{\n        ml: [margin]\n      }],\n      /**\n       * Space Between X\n       * @see https://tailwindcss.com/docs/space\n       */\n      'space-x': [{\n        'space-x': [space]\n      }],\n      /**\n       * Space Between X Reverse\n       * @see https://tailwindcss.com/docs/space\n       */\n      'space-x-reverse': ['space-x-reverse'],\n      /**\n       * Space Between Y\n       * @see https://tailwindcss.com/docs/space\n       */\n      'space-y': [{\n        'space-y': [space]\n      }],\n      /**\n       * Space Between Y Reverse\n       * @see https://tailwindcss.com/docs/space\n       */\n      'space-y-reverse': ['space-y-reverse'],\n      // Sizing\n      /**\n       * Width\n       * @see https://tailwindcss.com/docs/width\n       */\n      w: [{\n        w: ['auto', 'min', 'max', 'fit', 'svw', 'lvw', 'dvw', isArbitraryValue, spacing]\n      }],\n      /**\n       * Min-Width\n       * @see https://tailwindcss.com/docs/min-width\n       */\n      'min-w': [{\n        'min-w': [isArbitraryValue, spacing, 'min', 'max', 'fit']\n      }],\n      /**\n       * Max-Width\n       * @see https://tailwindcss.com/docs/max-width\n       */\n      'max-w': [{\n        'max-w': [isArbitraryValue, spacing, 'none', 'full', 'min', 'max', 'fit', 'prose', {\n          screen: [isTshirtSize]\n        }, isTshirtSize]\n      }],\n      /**\n       * Height\n       * @see https://tailwindcss.com/docs/height\n       */\n      h: [{\n        h: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']\n      }],\n      /**\n       * Min-Height\n       * @see https://tailwindcss.com/docs/min-height\n       */\n      'min-h': [{\n        'min-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']\n      }],\n      /**\n       * Max-Height\n       * @see https://tailwindcss.com/docs/max-height\n       */\n      'max-h': [{\n        'max-h': [isArbitraryValue, spacing, 'min', 'max', 'fit', 'svh', 'lvh', 'dvh']\n      }],\n      /**\n       * Size\n       * @see https://tailwindcss.com/docs/size\n       */\n      size: [{\n        size: [isArbitraryValue, spacing, 'auto', 'min', 'max', 'fit']\n      }],\n      // Typography\n      /**\n       * Font Size\n       * @see https://tailwindcss.com/docs/font-size\n       */\n      'font-size': [{\n        text: ['base', isTshirtSize, isArbitraryLength]\n      }],\n      /**\n       * Font Smoothing\n       * @see https://tailwindcss.com/docs/font-smoothing\n       */\n      'font-smoothing': ['antialiased', 'subpixel-antialiased'],\n      /**\n       * Font Style\n       * @see https://tailwindcss.com/docs/font-style\n       */\n      'font-style': ['italic', 'not-italic'],\n      /**\n       * Font Weight\n       * @see https://tailwindcss.com/docs/font-weight\n       */\n      'font-weight': [{\n        font: ['thin', 'extralight', 'light', 'normal', 'medium', 'semibold', 'bold', 'extrabold', 'black', isArbitraryNumber]\n      }],\n      /**\n       * Font Family\n       * @see https://tailwindcss.com/docs/font-family\n       */\n      'font-family': [{\n        font: [isAny]\n      }],\n      /**\n       * Font Variant Numeric\n       * @see https://tailwindcss.com/docs/font-variant-numeric\n       */\n      'fvn-normal': ['normal-nums'],\n      /**\n       * Font Variant Numeric\n       * @see https://tailwindcss.com/docs/font-variant-numeric\n       */\n      'fvn-ordinal': ['ordinal'],\n      /**\n       * Font Variant Numeric\n       * @see https://tailwindcss.com/docs/font-variant-numeric\n       */\n      'fvn-slashed-zero': ['slashed-zero'],\n      /**\n       * Font Variant Numeric\n       * @see https://tailwindcss.com/docs/font-variant-numeric\n       */\n      'fvn-figure': ['lining-nums', 'oldstyle-nums'],\n      /**\n       * Font Variant Numeric\n       * @see https://tailwindcss.com/docs/font-variant-numeric\n       */\n      'fvn-spacing': ['proportional-nums', 'tabular-nums'],\n      /**\n       * Font Variant Numeric\n       * @see https://tailwindcss.com/docs/font-variant-numeric\n       */\n      'fvn-fraction': ['diagonal-fractions', 'stacked-fractions'],\n      /**\n       * Letter Spacing\n       * @see https://tailwindcss.com/docs/letter-spacing\n       */\n      tracking: [{\n        tracking: ['tighter', 'tight', 'normal', 'wide', 'wider', 'widest', isArbitraryValue]\n      }],\n      /**\n       * Line Clamp\n       * @see https://tailwindcss.com/docs/line-clamp\n       */\n      'line-clamp': [{\n        'line-clamp': ['none', isNumber, isArbitraryNumber]\n      }],\n      /**\n       * Line Height\n       * @see https://tailwindcss.com/docs/line-height\n       */\n      leading: [{\n        leading: ['none', 'tight', 'snug', 'normal', 'relaxed', 'loose', isLength, isArbitraryValue]\n      }],\n      /**\n       * List Style Image\n       * @see https://tailwindcss.com/docs/list-style-image\n       */\n      'list-image': [{\n        'list-image': ['none', isArbitraryValue]\n      }],\n      /**\n       * List Style Type\n       * @see https://tailwindcss.com/docs/list-style-type\n       */\n      'list-style-type': [{\n        list: ['none', 'disc', 'decimal', isArbitraryValue]\n      }],\n      /**\n       * List Style Position\n       * @see https://tailwindcss.com/docs/list-style-position\n       */\n      'list-style-position': [{\n        list: ['inside', 'outside']\n      }],\n      /**\n       * Placeholder Color\n       * @deprecated since Tailwind CSS v3.0.0\n       * @see https://tailwindcss.com/docs/placeholder-color\n       */\n      'placeholder-color': [{\n        placeholder: [colors]\n      }],\n      /**\n       * Placeholder Opacity\n       * @see https://tailwindcss.com/docs/placeholder-opacity\n       */\n      'placeholder-opacity': [{\n        'placeholder-opacity': [opacity]\n      }],\n      /**\n       * Text Alignment\n       * @see https://tailwindcss.com/docs/text-align\n       */\n      'text-alignment': [{\n        text: ['left', 'center', 'right', 'justify', 'start', 'end']\n      }],\n      /**\n       * Text Color\n       * @see https://tailwindcss.com/docs/text-color\n       */\n      'text-color': [{\n        text: [colors]\n      }],\n      /**\n       * Text Opacity\n       * @see https://tailwindcss.com/docs/text-opacity\n       */\n      'text-opacity': [{\n        'text-opacity': [opacity]\n      }],\n      /**\n       * Text Decoration\n       * @see https://tailwindcss.com/docs/text-decoration\n       */\n      'text-decoration': ['underline', 'overline', 'line-through', 'no-underline'],\n      /**\n       * Text Decoration Style\n       * @see https://tailwindcss.com/docs/text-decoration-style\n       */\n      'text-decoration-style': [{\n        decoration: [...getLineStyles(), 'wavy']\n      }],\n      /**\n       * Text Decoration Thickness\n       * @see https://tailwindcss.com/docs/text-decoration-thickness\n       */\n      'text-decoration-thickness': [{\n        decoration: ['auto', 'from-font', isLength, isArbitraryLength]\n      }],\n      /**\n       * Text Underline Offset\n       * @see https://tailwindcss.com/docs/text-underline-offset\n       */\n      'underline-offset': [{\n        'underline-offset': ['auto', isLength, isArbitraryValue]\n      }],\n      /**\n       * Text Decoration Color\n       * @see https://tailwindcss.com/docs/text-decoration-color\n       */\n      'text-decoration-color': [{\n        decoration: [colors]\n      }],\n      /**\n       * Text Transform\n       * @see https://tailwindcss.com/docs/text-transform\n       */\n      'text-transform': ['uppercase', 'lowercase', 'capitalize', 'normal-case'],\n      /**\n       * Text Overflow\n       * @see https://tailwindcss.com/docs/text-overflow\n       */\n      'text-overflow': ['truncate', 'text-ellipsis', 'text-clip'],\n      /**\n       * Text Wrap\n       * @see https://tailwindcss.com/docs/text-wrap\n       */\n      'text-wrap': [{\n        text: ['wrap', 'nowrap', 'balance', 'pretty']\n      }],\n      /**\n       * Text Indent\n       * @see https://tailwindcss.com/docs/text-indent\n       */\n      indent: [{\n        indent: getSpacingWithArbitrary()\n      }],\n      /**\n       * Vertical Alignment\n       * @see https://tailwindcss.com/docs/vertical-align\n       */\n      'vertical-align': [{\n        align: ['baseline', 'top', 'middle', 'bottom', 'text-top', 'text-bottom', 'sub', 'super', isArbitraryValue]\n      }],\n      /**\n       * Whitespace\n       * @see https://tailwindcss.com/docs/whitespace\n       */\n      whitespace: [{\n        whitespace: ['normal', 'nowrap', 'pre', 'pre-line', 'pre-wrap', 'break-spaces']\n      }],\n      /**\n       * Word Break\n       * @see https://tailwindcss.com/docs/word-break\n       */\n      break: [{\n        break: ['normal', 'words', 'all', 'keep']\n      }],\n      /**\n       * Hyphens\n       * @see https://tailwindcss.com/docs/hyphens\n       */\n      hyphens: [{\n        hyphens: ['none', 'manual', 'auto']\n      }],\n      /**\n       * Content\n       * @see https://tailwindcss.com/docs/content\n       */\n      content: [{\n        content: ['none', isArbitraryValue]\n      }],\n      // Backgrounds\n      /**\n       * Background Attachment\n       * @see https://tailwindcss.com/docs/background-attachment\n       */\n      'bg-attachment': [{\n        bg: ['fixed', 'local', 'scroll']\n      }],\n      /**\n       * Background Clip\n       * @see https://tailwindcss.com/docs/background-clip\n       */\n      'bg-clip': [{\n        'bg-clip': ['border', 'padding', 'content', 'text']\n      }],\n      /**\n       * Background Opacity\n       * @deprecated since Tailwind CSS v3.0.0\n       * @see https://tailwindcss.com/docs/background-opacity\n       */\n      'bg-opacity': [{\n        'bg-opacity': [opacity]\n      }],\n      /**\n       * Background Origin\n       * @see https://tailwindcss.com/docs/background-origin\n       */\n      'bg-origin': [{\n        'bg-origin': ['border', 'padding', 'content']\n      }],\n      /**\n       * Background Position\n       * @see https://tailwindcss.com/docs/background-position\n       */\n      'bg-position': [{\n        bg: [...getPositions(), isArbitraryPosition]\n      }],\n      /**\n       * Background Repeat\n       * @see https://tailwindcss.com/docs/background-repeat\n       */\n      'bg-repeat': [{\n        bg: ['no-repeat', {\n          repeat: ['', 'x', 'y', 'round', 'space']\n        }]\n      }],\n      /**\n       * Background Size\n       * @see https://tailwindcss.com/docs/background-size\n       */\n      'bg-size': [{\n        bg: ['auto', 'cover', 'contain', isArbitrarySize]\n      }],\n      /**\n       * Background Image\n       * @see https://tailwindcss.com/docs/background-image\n       */\n      'bg-image': [{\n        bg: ['none', {\n          'gradient-to': ['t', 'tr', 'r', 'br', 'b', 'bl', 'l', 'tl']\n        }, isArbitraryImage]\n      }],\n      /**\n       * Background Color\n       * @see https://tailwindcss.com/docs/background-color\n       */\n      'bg-color': [{\n        bg: [colors]\n      }],\n      /**\n       * Gradient Color Stops From Position\n       * @see https://tailwindcss.com/docs/gradient-color-stops\n       */\n      'gradient-from-pos': [{\n        from: [gradientColorStopPositions]\n      }],\n      /**\n       * Gradient Color Stops Via Position\n       * @see https://tailwindcss.com/docs/gradient-color-stops\n       */\n      'gradient-via-pos': [{\n        via: [gradientColorStopPositions]\n      }],\n      /**\n       * Gradient Color Stops To Position\n       * @see https://tailwindcss.com/docs/gradient-color-stops\n       */\n      'gradient-to-pos': [{\n        to: [gradientColorStopPositions]\n      }],\n      /**\n       * Gradient Color Stops From\n       * @see https://tailwindcss.com/docs/gradient-color-stops\n       */\n      'gradient-from': [{\n        from: [gradientColorStops]\n      }],\n      /**\n       * Gradient Color Stops Via\n       * @see https://tailwindcss.com/docs/gradient-color-stops\n       */\n      'gradient-via': [{\n        via: [gradientColorStops]\n      }],\n      /**\n       * Gradient Color Stops To\n       * @see https://tailwindcss.com/docs/gradient-color-stops\n       */\n      'gradient-to': [{\n        to: [gradientColorStops]\n      }],\n      // Borders\n      /**\n       * Border Radius\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      rounded: [{\n        rounded: [borderRadius]\n      }],\n      /**\n       * Border Radius Start\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-s': [{\n        'rounded-s': [borderRadius]\n      }],\n      /**\n       * Border Radius End\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-e': [{\n        'rounded-e': [borderRadius]\n      }],\n      /**\n       * Border Radius Top\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-t': [{\n        'rounded-t': [borderRadius]\n      }],\n      /**\n       * Border Radius Right\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-r': [{\n        'rounded-r': [borderRadius]\n      }],\n      /**\n       * Border Radius Bottom\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-b': [{\n        'rounded-b': [borderRadius]\n      }],\n      /**\n       * Border Radius Left\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-l': [{\n        'rounded-l': [borderRadius]\n      }],\n      /**\n       * Border Radius Start Start\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-ss': [{\n        'rounded-ss': [borderRadius]\n      }],\n      /**\n       * Border Radius Start End\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-se': [{\n        'rounded-se': [borderRadius]\n      }],\n      /**\n       * Border Radius End End\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-ee': [{\n        'rounded-ee': [borderRadius]\n      }],\n      /**\n       * Border Radius End Start\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-es': [{\n        'rounded-es': [borderRadius]\n      }],\n      /**\n       * Border Radius Top Left\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-tl': [{\n        'rounded-tl': [borderRadius]\n      }],\n      /**\n       * Border Radius Top Right\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-tr': [{\n        'rounded-tr': [borderRadius]\n      }],\n      /**\n       * Border Radius Bottom Right\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-br': [{\n        'rounded-br': [borderRadius]\n      }],\n      /**\n       * Border Radius Bottom Left\n       * @see https://tailwindcss.com/docs/border-radius\n       */\n      'rounded-bl': [{\n        'rounded-bl': [borderRadius]\n      }],\n      /**\n       * Border Width\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w': [{\n        border: [borderWidth]\n      }],\n      /**\n       * Border Width X\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-x': [{\n        'border-x': [borderWidth]\n      }],\n      /**\n       * Border Width Y\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-y': [{\n        'border-y': [borderWidth]\n      }],\n      /**\n       * Border Width Start\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-s': [{\n        'border-s': [borderWidth]\n      }],\n      /**\n       * Border Width End\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-e': [{\n        'border-e': [borderWidth]\n      }],\n      /**\n       * Border Width Top\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-t': [{\n        'border-t': [borderWidth]\n      }],\n      /**\n       * Border Width Right\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-r': [{\n        'border-r': [borderWidth]\n      }],\n      /**\n       * Border Width Bottom\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-b': [{\n        'border-b': [borderWidth]\n      }],\n      /**\n       * Border Width Left\n       * @see https://tailwindcss.com/docs/border-width\n       */\n      'border-w-l': [{\n        'border-l': [borderWidth]\n      }],\n      /**\n       * Border Opacity\n       * @see https://tailwindcss.com/docs/border-opacity\n       */\n      'border-opacity': [{\n        'border-opacity': [opacity]\n      }],\n      /**\n       * Border Style\n       * @see https://tailwindcss.com/docs/border-style\n       */\n      'border-style': [{\n        border: [...getLineStyles(), 'hidden']\n      }],\n      /**\n       * Divide Width X\n       * @see https://tailwindcss.com/docs/divide-width\n       */\n      'divide-x': [{\n        'divide-x': [borderWidth]\n      }],\n      /**\n       * Divide Width X Reverse\n       * @see https://tailwindcss.com/docs/divide-width\n       */\n      'divide-x-reverse': ['divide-x-reverse'],\n      /**\n       * Divide Width Y\n       * @see https://tailwindcss.com/docs/divide-width\n       */\n      'divide-y': [{\n        'divide-y': [borderWidth]\n      }],\n      /**\n       * Divide Width Y Reverse\n       * @see https://tailwindcss.com/docs/divide-width\n       */\n      'divide-y-reverse': ['divide-y-reverse'],\n      /**\n       * Divide Opacity\n       * @see https://tailwindcss.com/docs/divide-opacity\n       */\n      'divide-opacity': [{\n        'divide-opacity': [opacity]\n      }],\n      /**\n       * Divide Style\n       * @see https://tailwindcss.com/docs/divide-style\n       */\n      'divide-style': [{\n        divide: getLineStyles()\n      }],\n      /**\n       * Border Color\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color': [{\n        border: [borderColor]\n      }],\n      /**\n       * Border Color X\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-x': [{\n        'border-x': [borderColor]\n      }],\n      /**\n       * Border Color Y\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-y': [{\n        'border-y': [borderColor]\n      }],\n      /**\n       * Border Color S\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-s': [{\n        'border-s': [borderColor]\n      }],\n      /**\n       * Border Color E\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-e': [{\n        'border-e': [borderColor]\n      }],\n      /**\n       * Border Color Top\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-t': [{\n        'border-t': [borderColor]\n      }],\n      /**\n       * Border Color Right\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-r': [{\n        'border-r': [borderColor]\n      }],\n      /**\n       * Border Color Bottom\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-b': [{\n        'border-b': [borderColor]\n      }],\n      /**\n       * Border Color Left\n       * @see https://tailwindcss.com/docs/border-color\n       */\n      'border-color-l': [{\n        'border-l': [borderColor]\n      }],\n      /**\n       * Divide Color\n       * @see https://tailwindcss.com/docs/divide-color\n       */\n      'divide-color': [{\n        divide: [borderColor]\n      }],\n      /**\n       * Outline Style\n       * @see https://tailwindcss.com/docs/outline-style\n       */\n      'outline-style': [{\n        outline: ['', ...getLineStyles()]\n      }],\n      /**\n       * Outline Offset\n       * @see https://tailwindcss.com/docs/outline-offset\n       */\n      'outline-offset': [{\n        'outline-offset': [isLength, isArbitraryValue]\n      }],\n      /**\n       * Outline Width\n       * @see https://tailwindcss.com/docs/outline-width\n       */\n      'outline-w': [{\n        outline: [isLength, isArbitraryLength]\n      }],\n      /**\n       * Outline Color\n       * @see https://tailwindcss.com/docs/outline-color\n       */\n      'outline-color': [{\n        outline: [colors]\n      }],\n      /**\n       * Ring Width\n       * @see https://tailwindcss.com/docs/ring-width\n       */\n      'ring-w': [{\n        ring: getLengthWithEmptyAndArbitrary()\n      }],\n      /**\n       * Ring Width Inset\n       * @see https://tailwindcss.com/docs/ring-width\n       */\n      'ring-w-inset': ['ring-inset'],\n      /**\n       * Ring Color\n       * @see https://tailwindcss.com/docs/ring-color\n       */\n      'ring-color': [{\n        ring: [colors]\n      }],\n      /**\n       * Ring Opacity\n       * @see https://tailwindcss.com/docs/ring-opacity\n       */\n      'ring-opacity': [{\n        'ring-opacity': [opacity]\n      }],\n      /**\n       * Ring Offset Width\n       * @see https://tailwindcss.com/docs/ring-offset-width\n       */\n      'ring-offset-w': [{\n        'ring-offset': [isLength, isArbitraryLength]\n      }],\n      /**\n       * Ring Offset Color\n       * @see https://tailwindcss.com/docs/ring-offset-color\n       */\n      'ring-offset-color': [{\n        'ring-offset': [colors]\n      }],\n      // Effects\n      /**\n       * Box Shadow\n       * @see https://tailwindcss.com/docs/box-shadow\n       */\n      shadow: [{\n        shadow: ['', 'inner', 'none', isTshirtSize, isArbitraryShadow]\n      }],\n      /**\n       * Box Shadow Color\n       * @see https://tailwindcss.com/docs/box-shadow-color\n       */\n      'shadow-color': [{\n        shadow: [isAny]\n      }],\n      /**\n       * Opacity\n       * @see https://tailwindcss.com/docs/opacity\n       */\n      opacity: [{\n        opacity: [opacity]\n      }],\n      /**\n       * Mix Blend Mode\n       * @see https://tailwindcss.com/docs/mix-blend-mode\n       */\n      'mix-blend': [{\n        'mix-blend': [...getBlendModes(), 'plus-lighter', 'plus-darker']\n      }],\n      /**\n       * Background Blend Mode\n       * @see https://tailwindcss.com/docs/background-blend-mode\n       */\n      'bg-blend': [{\n        'bg-blend': getBlendModes()\n      }],\n      // Filters\n      /**\n       * Filter\n       * @deprecated since Tailwind CSS v3.0.0\n       * @see https://tailwindcss.com/docs/filter\n       */\n      filter: [{\n        filter: ['', 'none']\n      }],\n      /**\n       * Blur\n       * @see https://tailwindcss.com/docs/blur\n       */\n      blur: [{\n        blur: [blur]\n      }],\n      /**\n       * Brightness\n       * @see https://tailwindcss.com/docs/brightness\n       */\n      brightness: [{\n        brightness: [brightness]\n      }],\n      /**\n       * Contrast\n       * @see https://tailwindcss.com/docs/contrast\n       */\n      contrast: [{\n        contrast: [contrast]\n      }],\n      /**\n       * Drop Shadow\n       * @see https://tailwindcss.com/docs/drop-shadow\n       */\n      'drop-shadow': [{\n        'drop-shadow': ['', 'none', isTshirtSize, isArbitraryValue]\n      }],\n      /**\n       * Grayscale\n       * @see https://tailwindcss.com/docs/grayscale\n       */\n      grayscale: [{\n        grayscale: [grayscale]\n      }],\n      /**\n       * Hue Rotate\n       * @see https://tailwindcss.com/docs/hue-rotate\n       */\n      'hue-rotate': [{\n        'hue-rotate': [hueRotate]\n      }],\n      /**\n       * Invert\n       * @see https://tailwindcss.com/docs/invert\n       */\n      invert: [{\n        invert: [invert]\n      }],\n      /**\n       * Saturate\n       * @see https://tailwindcss.com/docs/saturate\n       */\n      saturate: [{\n        saturate: [saturate]\n      }],\n      /**\n       * Sepia\n       * @see https://tailwindcss.com/docs/sepia\n       */\n      sepia: [{\n        sepia: [sepia]\n      }],\n      /**\n       * Backdrop Filter\n       * @deprecated since Tailwind CSS v3.0.0\n       * @see https://tailwindcss.com/docs/backdrop-filter\n       */\n      'backdrop-filter': [{\n        'backdrop-filter': ['', 'none']\n      }],\n      /**\n       * Backdrop Blur\n       * @see https://tailwindcss.com/docs/backdrop-blur\n       */\n      'backdrop-blur': [{\n        'backdrop-blur': [blur]\n      }],\n      /**\n       * Backdrop Brightness\n       * @see https://tailwindcss.com/docs/backdrop-brightness\n       */\n      'backdrop-brightness': [{\n        'backdrop-brightness': [brightness]\n      }],\n      /**\n       * Backdrop Contrast\n       * @see https://tailwindcss.com/docs/backdrop-contrast\n       */\n      'backdrop-contrast': [{\n        'backdrop-contrast': [contrast]\n      }],\n      /**\n       * Backdrop Grayscale\n       * @see https://tailwindcss.com/docs/backdrop-grayscale\n       */\n      'backdrop-grayscale': [{\n        'backdrop-grayscale': [grayscale]\n      }],\n      /**\n       * Backdrop Hue Rotate\n       * @see https://tailwindcss.com/docs/backdrop-hue-rotate\n       */\n      'backdrop-hue-rotate': [{\n        'backdrop-hue-rotate': [hueRotate]\n      }],\n      /**\n       * Backdrop Invert\n       * @see https://tailwindcss.com/docs/backdrop-invert\n       */\n      'backdrop-invert': [{\n        'backdrop-invert': [invert]\n      }],\n      /**\n       * Backdrop Opacity\n       * @see https://tailwindcss.com/docs/backdrop-opacity\n       */\n      'backdrop-opacity': [{\n        'backdrop-opacity': [opacity]\n      }],\n      /**\n       * Backdrop Saturate\n       * @see https://tailwindcss.com/docs/backdrop-saturate\n       */\n      'backdrop-saturate': [{\n        'backdrop-saturate': [saturate]\n      }],\n      /**\n       * Backdrop Sepia\n       * @see https://tailwindcss.com/docs/backdrop-sepia\n       */\n      'backdrop-sepia': [{\n        'backdrop-sepia': [sepia]\n      }],\n      // Tables\n      /**\n       * Border Collapse\n       * @see https://tailwindcss.com/docs/border-collapse\n       */\n      'border-collapse': [{\n        border: ['collapse', 'separate']\n      }],\n      /**\n       * Border Spacing\n       * @see https://tailwindcss.com/docs/border-spacing\n       */\n      'border-spacing': [{\n        'border-spacing': [borderSpacing]\n      }],\n      /**\n       * Border Spacing X\n       * @see https://tailwindcss.com/docs/border-spacing\n       */\n      'border-spacing-x': [{\n        'border-spacing-x': [borderSpacing]\n      }],\n      /**\n       * Border Spacing Y\n       * @see https://tailwindcss.com/docs/border-spacing\n       */\n      'border-spacing-y': [{\n        'border-spacing-y': [borderSpacing]\n      }],\n      /**\n       * Table Layout\n       * @see https://tailwindcss.com/docs/table-layout\n       */\n      'table-layout': [{\n        table: ['auto', 'fixed']\n      }],\n      /**\n       * Caption Side\n       * @see https://tailwindcss.com/docs/caption-side\n       */\n      caption: [{\n        caption: ['top', 'bottom']\n      }],\n      // Transitions and Animation\n      /**\n       * Tranisition Property\n       * @see https://tailwindcss.com/docs/transition-property\n       */\n      transition: [{\n        transition: ['none', 'all', '', 'colors', 'opacity', 'shadow', 'transform', isArbitraryValue]\n      }],\n      /**\n       * Transition Duration\n       * @see https://tailwindcss.com/docs/transition-duration\n       */\n      duration: [{\n        duration: getNumberAndArbitrary()\n      }],\n      /**\n       * Transition Timing Function\n       * @see https://tailwindcss.com/docs/transition-timing-function\n       */\n      ease: [{\n        ease: ['linear', 'in', 'out', 'in-out', isArbitraryValue]\n      }],\n      /**\n       * Transition Delay\n       * @see https://tailwindcss.com/docs/transition-delay\n       */\n      delay: [{\n        delay: getNumberAndArbitrary()\n      }],\n      /**\n       * Animation\n       * @see https://tailwindcss.com/docs/animation\n       */\n      animate: [{\n        animate: ['none', 'spin', 'ping', 'pulse', 'bounce', isArbitraryValue]\n      }],\n      // Transforms\n      /**\n       * Transform\n       * @see https://tailwindcss.com/docs/transform\n       */\n      transform: [{\n        transform: ['', 'gpu', 'none']\n      }],\n      /**\n       * Scale\n       * @see https://tailwindcss.com/docs/scale\n       */\n      scale: [{\n        scale: [scale]\n      }],\n      /**\n       * Scale X\n       * @see https://tailwindcss.com/docs/scale\n       */\n      'scale-x': [{\n        'scale-x': [scale]\n      }],\n      /**\n       * Scale Y\n       * @see https://tailwindcss.com/docs/scale\n       */\n      'scale-y': [{\n        'scale-y': [scale]\n      }],\n      /**\n       * Rotate\n       * @see https://tailwindcss.com/docs/rotate\n       */\n      rotate: [{\n        rotate: [isInteger, isArbitraryValue]\n      }],\n      /**\n       * Translate X\n       * @see https://tailwindcss.com/docs/translate\n       */\n      'translate-x': [{\n        'translate-x': [translate]\n      }],\n      /**\n       * Translate Y\n       * @see https://tailwindcss.com/docs/translate\n       */\n      'translate-y': [{\n        'translate-y': [translate]\n      }],\n      /**\n       * Skew X\n       * @see https://tailwindcss.com/docs/skew\n       */\n      'skew-x': [{\n        'skew-x': [skew]\n      }],\n      /**\n       * Skew Y\n       * @see https://tailwindcss.com/docs/skew\n       */\n      'skew-y': [{\n        'skew-y': [skew]\n      }],\n      /**\n       * Transform Origin\n       * @see https://tailwindcss.com/docs/transform-origin\n       */\n      'transform-origin': [{\n        origin: ['center', 'top', 'top-right', 'right', 'bottom-right', 'bottom', 'bottom-left', 'left', 'top-left', isArbitraryValue]\n      }],\n      // Interactivity\n      /**\n       * Accent Color\n       * @see https://tailwindcss.com/docs/accent-color\n       */\n      accent: [{\n        accent: ['auto', colors]\n      }],\n      /**\n       * Appearance\n       * @see https://tailwindcss.com/docs/appearance\n       */\n      appearance: [{\n        appearance: ['none', 'auto']\n      }],\n      /**\n       * Cursor\n       * @see https://tailwindcss.com/docs/cursor\n       */\n      cursor: [{\n        cursor: ['auto', 'default', 'pointer', 'wait', 'text', 'move', 'help', 'not-allowed', 'none', 'context-menu', 'progress', 'cell', 'crosshair', 'vertical-text', 'alias', 'copy', 'no-drop', 'grab', 'grabbing', 'all-scroll', 'col-resize', 'row-resize', 'n-resize', 'e-resize', 's-resize', 'w-resize', 'ne-resize', 'nw-resize', 'se-resize', 'sw-resize', 'ew-resize', 'ns-resize', 'nesw-resize', 'nwse-resize', 'zoom-in', 'zoom-out', isArbitraryValue]\n      }],\n      /**\n       * Caret Color\n       * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities\n       */\n      'caret-color': [{\n        caret: [colors]\n      }],\n      /**\n       * Pointer Events\n       * @see https://tailwindcss.com/docs/pointer-events\n       */\n      'pointer-events': [{\n        'pointer-events': ['none', 'auto']\n      }],\n      /**\n       * Resize\n       * @see https://tailwindcss.com/docs/resize\n       */\n      resize: [{\n        resize: ['none', 'y', 'x', '']\n      }],\n      /**\n       * Scroll Behavior\n       * @see https://tailwindcss.com/docs/scroll-behavior\n       */\n      'scroll-behavior': [{\n        scroll: ['auto', 'smooth']\n      }],\n      /**\n       * Scroll Margin\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-m': [{\n        'scroll-m': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin X\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-mx': [{\n        'scroll-mx': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin Y\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-my': [{\n        'scroll-my': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin Start\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-ms': [{\n        'scroll-ms': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin End\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-me': [{\n        'scroll-me': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin Top\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-mt': [{\n        'scroll-mt': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin Right\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-mr': [{\n        'scroll-mr': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin Bottom\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-mb': [{\n        'scroll-mb': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Margin Left\n       * @see https://tailwindcss.com/docs/scroll-margin\n       */\n      'scroll-ml': [{\n        'scroll-ml': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-p': [{\n        'scroll-p': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding X\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-px': [{\n        'scroll-px': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding Y\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-py': [{\n        'scroll-py': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding Start\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-ps': [{\n        'scroll-ps': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding End\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-pe': [{\n        'scroll-pe': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding Top\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-pt': [{\n        'scroll-pt': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding Right\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-pr': [{\n        'scroll-pr': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding Bottom\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-pb': [{\n        'scroll-pb': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Padding Left\n       * @see https://tailwindcss.com/docs/scroll-padding\n       */\n      'scroll-pl': [{\n        'scroll-pl': getSpacingWithArbitrary()\n      }],\n      /**\n       * Scroll Snap Align\n       * @see https://tailwindcss.com/docs/scroll-snap-align\n       */\n      'snap-align': [{\n        snap: ['start', 'end', 'center', 'align-none']\n      }],\n      /**\n       * Scroll Snap Stop\n       * @see https://tailwindcss.com/docs/scroll-snap-stop\n       */\n      'snap-stop': [{\n        snap: ['normal', 'always']\n      }],\n      /**\n       * Scroll Snap Type\n       * @see https://tailwindcss.com/docs/scroll-snap-type\n       */\n      'snap-type': [{\n        snap: ['none', 'x', 'y', 'both']\n      }],\n      /**\n       * Scroll Snap Type Strictness\n       * @see https://tailwindcss.com/docs/scroll-snap-type\n       */\n      'snap-strictness': [{\n        snap: ['mandatory', 'proximity']\n      }],\n      /**\n       * Touch Action\n       * @see https://tailwindcss.com/docs/touch-action\n       */\n      touch: [{\n        touch: ['auto', 'none', 'manipulation']\n      }],\n      /**\n       * Touch Action X\n       * @see https://tailwindcss.com/docs/touch-action\n       */\n      'touch-x': [{\n        'touch-pan': ['x', 'left', 'right']\n      }],\n      /**\n       * Touch Action Y\n       * @see https://tailwindcss.com/docs/touch-action\n       */\n      'touch-y': [{\n        'touch-pan': ['y', 'up', 'down']\n      }],\n      /**\n       * Touch Action Pinch Zoom\n       * @see https://tailwindcss.com/docs/touch-action\n       */\n      'touch-pz': ['touch-pinch-zoom'],\n      /**\n       * User Select\n       * @see https://tailwindcss.com/docs/user-select\n       */\n      select: [{\n        select: ['none', 'text', 'all', 'auto']\n      }],\n      /**\n       * Will Change\n       * @see https://tailwindcss.com/docs/will-change\n       */\n      'will-change': [{\n        'will-change': ['auto', 'scroll', 'contents', 'transform', isArbitraryValue]\n      }],\n      // SVG\n      /**\n       * Fill\n       * @see https://tailwindcss.com/docs/fill\n       */\n      fill: [{\n        fill: [colors, 'none']\n      }],\n      /**\n       * Stroke Width\n       * @see https://tailwindcss.com/docs/stroke-width\n       */\n      'stroke-w': [{\n        stroke: [isLength, isArbitraryLength, isArbitraryNumber]\n      }],\n      /**\n       * Stroke\n       * @see https://tailwindcss.com/docs/stroke\n       */\n      stroke: [{\n        stroke: [colors, 'none']\n      }],\n      // Accessibility\n      /**\n       * Screen Readers\n       * @see https://tailwindcss.com/docs/screen-readers\n       */\n      sr: ['sr-only', 'not-sr-only'],\n      /**\n       * Forced Color Adjust\n       * @see https://tailwindcss.com/docs/forced-color-adjust\n       */\n      'forced-color-adjust': [{\n        'forced-color-adjust': ['auto', 'none']\n      }]\n    },\n    conflictingClassGroups: {\n      overflow: ['overflow-x', 'overflow-y'],\n      overscroll: ['overscroll-x', 'overscroll-y'],\n      inset: ['inset-x', 'inset-y', 'start', 'end', 'top', 'right', 'bottom', 'left'],\n      'inset-x': ['right', 'left'],\n      'inset-y': ['top', 'bottom'],\n      flex: ['basis', 'grow', 'shrink'],\n      gap: ['gap-x', 'gap-y'],\n      p: ['px', 'py', 'ps', 'pe', 'pt', 'pr', 'pb', 'pl'],\n      px: ['pr', 'pl'],\n      py: ['pt', 'pb'],\n      m: ['mx', 'my', 'ms', 'me', 'mt', 'mr', 'mb', 'ml'],\n      mx: ['mr', 'ml'],\n      my: ['mt', 'mb'],\n      size: ['w', 'h'],\n      'font-size': ['leading'],\n      'fvn-normal': ['fvn-ordinal', 'fvn-slashed-zero', 'fvn-figure', 'fvn-spacing', 'fvn-fraction'],\n      'fvn-ordinal': ['fvn-normal'],\n      'fvn-slashed-zero': ['fvn-normal'],\n      'fvn-figure': ['fvn-normal'],\n      'fvn-spacing': ['fvn-normal'],\n      'fvn-fraction': ['fvn-normal'],\n      'line-clamp': ['display', 'overflow'],\n      rounded: ['rounded-s', 'rounded-e', 'rounded-t', 'rounded-r', 'rounded-b', 'rounded-l', 'rounded-ss', 'rounded-se', 'rounded-ee', 'rounded-es', 'rounded-tl', 'rounded-tr', 'rounded-br', 'rounded-bl'],\n      'rounded-s': ['rounded-ss', 'rounded-es'],\n      'rounded-e': ['rounded-se', 'rounded-ee'],\n      'rounded-t': ['rounded-tl', 'rounded-tr'],\n      'rounded-r': ['rounded-tr', 'rounded-br'],\n      'rounded-b': ['rounded-br', 'rounded-bl'],\n      'rounded-l': ['rounded-tl', 'rounded-bl'],\n      'border-spacing': ['border-spacing-x', 'border-spacing-y'],\n      'border-w': ['border-w-s', 'border-w-e', 'border-w-t', 'border-w-r', 'border-w-b', 'border-w-l'],\n      'border-w-x': ['border-w-r', 'border-w-l'],\n      'border-w-y': ['border-w-t', 'border-w-b'],\n      'border-color': ['border-color-s', 'border-color-e', 'border-color-t', 'border-color-r', 'border-color-b', 'border-color-l'],\n      'border-color-x': ['border-color-r', 'border-color-l'],\n      'border-color-y': ['border-color-t', 'border-color-b'],\n      'scroll-m': ['scroll-mx', 'scroll-my', 'scroll-ms', 'scroll-me', 'scroll-mt', 'scroll-mr', 'scroll-mb', 'scroll-ml'],\n      'scroll-mx': ['scroll-mr', 'scroll-ml'],\n      'scroll-my': ['scroll-mt', 'scroll-mb'],\n      'scroll-p': ['scroll-px', 'scroll-py', 'scroll-ps', 'scroll-pe', 'scroll-pt', 'scroll-pr', 'scroll-pb', 'scroll-pl'],\n      'scroll-px': ['scroll-pr', 'scroll-pl'],\n      'scroll-py': ['scroll-pt', 'scroll-pb'],\n      touch: ['touch-x', 'touch-y', 'touch-pz'],\n      'touch-x': ['touch'],\n      'touch-y': ['touch'],\n      'touch-pz': ['touch']\n    },\n    conflictingClassGroupModifiers: {\n      'font-size': ['leading']\n    }\n  };\n};\n\n/**\n * @param baseConfig Config where other config will be merged into. This object will be mutated.\n * @param configExtension Partial config to merge into the `baseConfig`.\n */\nconst mergeConfigs = (baseConfig, {\n  cacheSize,\n  prefix,\n  separator,\n  experimentalParseClassName,\n  extend = {},\n  override = {}\n}) => {\n  overrideProperty(baseConfig, 'cacheSize', cacheSize);\n  overrideProperty(baseConfig, 'prefix', prefix);\n  overrideProperty(baseConfig, 'separator', separator);\n  overrideProperty(baseConfig, 'experimentalParseClassName', experimentalParseClassName);\n  for (const configKey in override) {\n    overrideConfigProperties(baseConfig[configKey], override[configKey]);\n  }\n  for (const key in extend) {\n    mergeConfigProperties(baseConfig[key], extend[key]);\n  }\n  return baseConfig;\n};\nconst overrideProperty = (baseObject, overrideKey, overrideValue) => {\n  if (overrideValue !== undefined) {\n    baseObject[overrideKey] = overrideValue;\n  }\n};\nconst overrideConfigProperties = (baseObject, overrideObject) => {\n  if (overrideObject) {\n    for (const key in overrideObject) {\n      overrideProperty(baseObject, key, overrideObject[key]);\n    }\n  }\n};\nconst mergeConfigProperties = (baseObject, mergeObject) => {\n  if (mergeObject) {\n    for (const key in mergeObject) {\n      const mergeValue = mergeObject[key];\n      if (mergeValue !== undefined) {\n        baseObject[key] = (baseObject[key] || []).concat(mergeValue);\n      }\n    }\n  }\n};\nconst extendTailwindMerge = (configExtension, ...createConfig) => typeof configExtension === 'function' ? createTailwindMerge(getDefaultConfig, configExtension, ...createConfig) : createTailwindMerge(() => mergeConfigs(getDefaultConfig(), configExtension), ...createConfig);\nconst twMerge = /*#__PURE__*/createTailwindMerge(getDefaultConfig);\nexport { createTailwindMerge, extendTailwindMerge, fromTheme, getDefaultConfig, mergeConfigs, twJoin, twMerge, validators };\n//# sourceMappingURL=bundle-mjs.mjs.map\n","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","import { twMerge as n } from \"tailwind-merge\";\nimport { clsx as l } from \"clsx\";\nconst a = (...r) => n(l(...r)), i = (...r) => (...o) => r.forEach((t) => t?.(...o)), g = (r) => {\n  const o = {\n    0: \"gap-0\",\n    xxs: \"gap-1\",\n    xs: \"gap-2\",\n    sm: \"gap-3\",\n    md: \"gap-4\",\n    lg: \"gap-5\",\n    xl: \"gap-6\",\n    \"2xl\": \"gap-8\"\n  };\n  return o[r] || o.md;\n}, d = {\n  1: \"grid-cols-1\",\n  2: \"grid-cols-2\",\n  3: \"grid-cols-3\",\n  4: \"grid-cols-4\",\n  5: \"grid-cols-5\",\n  6: \"grid-cols-6\",\n  7: \"grid-cols-7\",\n  8: \"grid-cols-8\",\n  9: \"grid-cols-9\",\n  10: \"grid-cols-10\",\n  11: \"grid-cols-11\",\n  12: \"grid-cols-12\"\n}, f = () => {\n  const r = window.navigator?.userAgentData?.platform || window.navigator.platform, o = [\n    \"macOS\",\n    \"Macintosh\",\n    \"MacIntel\",\n    \"MacPPC\",\n    \"Mac68K\"\n  ], t = [\"Win32\", \"Win64\", \"Windows\", \"WinCE\"];\n  let e = \"null\";\n  return o.includes(r) ? e = \"Mac OS\" : t.includes(r) && (e = \"Windows\"), e;\n}, u = (r) => r < 1024 ? `${r} bytes` : r < 1024 * 1024 ? `${(r / 1024).toFixed(2)} KB` : r < 1024 * 1024 * 1024 ? `${(r / (1024 * 1024)).toFixed(2)} MB` : `${(r / (1024 * 1024 * 1024)).toFixed(2)} GB`, m = {\n  set: (r, o) => {\n    if (!(typeof window > \"u\"))\n      try {\n        localStorage.setItem(r, JSON.stringify(o));\n      } catch (t) {\n        console.error(t);\n      }\n  },\n  get: (r) => {\n    if (typeof window > \"u\")\n      return null;\n    try {\n      const o = localStorage.getItem(r);\n      return o ? JSON.parse(o) : null;\n    } catch (o) {\n      return console.error(o), null;\n    }\n  },\n  remove: (r) => {\n    if (!(typeof window > \"u\"))\n      try {\n        localStorage.removeItem(r);\n      } catch (o) {\n        console.error(o);\n      }\n  }\n};\nexport {\n  i as callAll,\n  a as cn,\n  d as columnClasses,\n  u as formatFileSize,\n  g as getGapClass,\n  f as getOperatingSystem,\n  m as safeLocalStorage\n};\n//# sourceMappingURL=functions.es.js.map\n","import { jsx as r } from \"react/jsx-runtime\";\nimport { cn as a, getGapClass as l } from \"../../utilities/functions.es.js\";\nconst i = ({\n  children: e,\n  gap: t = \"lg\",\n  className: s,\n  ...m\n}) => /* @__PURE__ */ r(\n  \"div\",\n  {\n    className: a(\n      \"w-full box-border flex items-center justify-between bg-background-primary p-5 min-h-16\",\n      l(t),\n      s\n    ),\n    ...m,\n    children: e\n  }\n);\ni.displayName = \"Topbar\";\nconst n = ({ gap: e = \"sm\", children: t, className: s }) => /* @__PURE__ */ r(\"div\", { className: a(\"flex items-center\", l(e), s), children: t });\nn.displayName = \"Topbar.Left\";\nconst c = ({\n  gap: e = \"md\",\n  children: t,\n  align: s = \"center\",\n  className: m\n}) => {\n  const f = {\n    left: \"justify-start\",\n    center: \"justify-center\",\n    right: \"justify-end\"\n  }[s];\n  return /* @__PURE__ */ r(\n    \"div\",\n    {\n      className: a(\n        \"flex items-center grow\",\n        l(e),\n        f,\n        m\n      ),\n      children: t\n    }\n  );\n};\nc.displayName = \"Topbar.Middle\";\nconst o = ({ gap: e = \"sm\", children: t, className: s }) => /* @__PURE__ */ r(\"div\", { className: a(\"flex items-center\", l(e), s), children: t });\no.displayName = \"Topbar.Right\";\nconst d = ({ children: e, className: t }) => /* @__PURE__ */ r(\n  \"div\",\n  {\n    className: a(\"flex items-center [&>svg]:block h-full\", t),\n    children: e\n  }\n);\nd.displayName = \"Topbar.Item\";\ni.Left = n;\ni.Middle = c;\ni.Right = o;\ni.Item = d;\nexport {\n  d as Item,\n  n as Left,\n  c as Middle,\n  o as Right,\n  i as Topbar,\n  i as default\n};\n//# sourceMappingURL=topbar.es.js.map\n","function hasWindow() {\n  return typeof window !== 'undefined';\n}\nfunction getNodeName(node) {\n  if (isNode(node)) {\n    return (node.nodeName || '').toLowerCase();\n  }\n  // Mocked nodes in testing environments may not be instances of Node. By\n  // returning `#document` an infinite loop won't occur.\n  // https://github.com/floating-ui/floating-ui/issues/2317\n  return '#document';\n}\nfunction getWindow(node) {\n  var _node$ownerDocument;\n  return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;\n}\nfunction getDocumentElement(node) {\n  var _ref;\n  return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;\n}\nfunction isNode(value) {\n  if (!hasWindow()) {\n    return false;\n  }\n  return value instanceof Node || value instanceof getWindow(value).Node;\n}\nfunction isElement(value) {\n  if (!hasWindow()) {\n    return false;\n  }\n  return value instanceof Element || value instanceof getWindow(value).Element;\n}\nfunction isHTMLElement(value) {\n  if (!hasWindow()) {\n    return false;\n  }\n  return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;\n}\nfunction isShadowRoot(value) {\n  if (!hasWindow() || typeof ShadowRoot === 'undefined') {\n    return false;\n  }\n  return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;\n}\nconst invalidOverflowDisplayValues = /*#__PURE__*/new Set(['inline', 'contents']);\nfunction isOverflowElement(element) {\n  const {\n    overflow,\n    overflowX,\n    overflowY,\n    display\n  } = getComputedStyle(element);\n  return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);\n}\nconst tableElements = /*#__PURE__*/new Set(['table', 'td', 'th']);\nfunction isTableElement(element) {\n  return tableElements.has(getNodeName(element));\n}\nconst topLayerSelectors = [':popover-open', ':modal'];\nfunction isTopLayer(element) {\n  return topLayerSelectors.some(selector => {\n    try {\n      return element.matches(selector);\n    } catch (_e) {\n      return false;\n    }\n  });\n}\nconst transformProperties = ['transform', 'translate', 'scale', 'rotate', 'perspective'];\nconst willChangeValues = ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'];\nconst containValues = ['paint', 'layout', 'strict', 'content'];\nfunction isContainingBlock(elementOrCss) {\n  const webkit = isWebKit();\n  const css = isElement(elementOrCss) ? getComputedStyle(elementOrCss) : elementOrCss;\n\n  // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n  // https://drafts.csswg.org/css-transforms-2/#individual-transforms\n  return transformProperties.some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || willChangeValues.some(value => (css.willChange || '').includes(value)) || containValues.some(value => (css.contain || '').includes(value));\n}\nfunction getContainingBlock(element) {\n  let currentNode = getParentNode(element);\n  while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {\n    if (isContainingBlock(currentNode)) {\n      return currentNode;\n    } else if (isTopLayer(currentNode)) {\n      return null;\n    }\n    currentNode = getParentNode(currentNode);\n  }\n  return null;\n}\nfunction isWebKit() {\n  if (typeof CSS === 'undefined' || !CSS.supports) return false;\n  return CSS.supports('-webkit-backdrop-filter', 'none');\n}\nconst lastTraversableNodeNames = /*#__PURE__*/new Set(['html', 'body', '#document']);\nfunction isLastTraversableNode(node) {\n  return lastTraversableNodeNames.has(getNodeName(node));\n}\nfunction getComputedStyle(element) {\n  return getWindow(element).getComputedStyle(element);\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.scrollX,\n    scrollTop: element.scrollY\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}\nfunction getNearestOverflowAncestor(node) {\n  const parentNode = getParentNode(node);\n  if (isLastTraversableNode(parentNode)) {\n    return node.ownerDocument ? node.ownerDocument.body : node.body;\n  }\n  if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {\n    return parentNode;\n  }\n  return getNearestOverflowAncestor(parentNode);\n}\nfunction getOverflowAncestors(node, list, traverseIframes) {\n  var _node$ownerDocument2;\n  if (list === void 0) {\n    list = [];\n  }\n  if (traverseIframes === void 0) {\n    traverseIframes = true;\n  }\n  const scrollableAncestor = getNearestOverflowAncestor(node);\n  const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);\n  const win = getWindow(scrollableAncestor);\n  if (isBody) {\n    const frameElement = getFrameElement(win);\n    return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);\n  }\n  return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));\n}\nfunction getFrameElement(win) {\n  return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;\n}\n\nexport { getComputedStyle, getContainingBlock, getDocumentElement, getFrameElement, getNearestOverflowAncestor, getNodeName, getNodeScroll, getOverflowAncestors, getParentNode, getWindow, isContainingBlock, isElement, isHTMLElement, isLastTraversableNode, isNode, isOverflowElement, isShadowRoot, isTableElement, isTopLayer, isWebKit };\n","import { isShadowRoot, isHTMLElement } from '@floating-ui/utils/dom';\n\nfunction activeElement(doc) {\n  let activeElement = doc.activeElement;\n  while (((_activeElement = activeElement) == null || (_activeElement = _activeElement.shadowRoot) == null ? void 0 : _activeElement.activeElement) != null) {\n    var _activeElement;\n    activeElement = activeElement.shadowRoot.activeElement;\n  }\n  return activeElement;\n}\nfunction contains(parent, child) {\n  if (!parent || !child) {\n    return false;\n  }\n  const rootNode = child.getRootNode == null ? void 0 : child.getRootNode();\n\n  // First, attempt with faster native method\n  if (parent.contains(child)) {\n    return true;\n  }\n\n  // then fallback to custom implementation with Shadow DOM support\n  if (rootNode && isShadowRoot(rootNode)) {\n    let next = child;\n    while (next) {\n      if (parent === next) {\n        return true;\n      }\n      // @ts-ignore\n      next = next.parentNode || next.host;\n    }\n  }\n\n  // Give up, the result is false\n  return false;\n}\n// Avoid Chrome DevTools blue warning.\nfunction getPlatform() {\n  const uaData = navigator.userAgentData;\n  if (uaData != null && uaData.platform) {\n    return uaData.platform;\n  }\n  return navigator.platform;\n}\nfunction getUserAgent() {\n  const uaData = navigator.userAgentData;\n  if (uaData && Array.isArray(uaData.brands)) {\n    return uaData.brands.map(_ref => {\n      let {\n        brand,\n        version\n      } = _ref;\n      return brand + \"/\" + version;\n    }).join(' ');\n  }\n  return navigator.userAgent;\n}\n\n// License: https://github.com/adobe/react-spectrum/blob/b35d5c02fe900badccd0cf1a8f23bb593419f238/packages/@react-aria/utils/src/isVirtualEvent.ts\nfunction isVirtualClick(event) {\n  // FIXME: Firefox is now emitting a deprecation warning for `mozInputSource`.\n  // Try to find a workaround for this. `react-aria` source still has the check.\n  if (event.mozInputSource === 0 && event.isTrusted) {\n    return true;\n  }\n  if (isAndroid() && event.pointerType) {\n    return event.type === 'click' && event.buttons === 1;\n  }\n  return event.detail === 0 && !event.pointerType;\n}\nfunction isVirtualPointerEvent(event) {\n  if (isJSDOM()) return false;\n  return !isAndroid() && event.width === 0 && event.height === 0 || isAndroid() && event.width === 1 && event.height === 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'mouse' ||\n  // iOS VoiceOver returns 0.333• for width/height.\n  event.width < 1 && event.height < 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'touch';\n}\nfunction isSafari() {\n  // Chrome DevTools does not complain about navigator.vendor\n  return /apple/i.test(navigator.vendor);\n}\nfunction isAndroid() {\n  const re = /android/i;\n  return re.test(getPlatform()) || re.test(getUserAgent());\n}\nfunction isMac() {\n  return getPlatform().toLowerCase().startsWith('mac') && !navigator.maxTouchPoints;\n}\nfunction isJSDOM() {\n  return getUserAgent().includes('jsdom/');\n}\nfunction isMouseLikePointerType(pointerType, strict) {\n  // On some Linux machines with Chromium, mouse inputs return a `pointerType`\n  // of \"pen\": https://github.com/floating-ui/floating-ui/issues/2015\n  const values = ['mouse', 'pen'];\n  if (!strict) {\n    values.push('', undefined);\n  }\n  return values.includes(pointerType);\n}\nfunction isReactEvent(event) {\n  return 'nativeEvent' in event;\n}\nfunction isRootElement(element) {\n  return element.matches('html,body');\n}\nfunction getDocument(node) {\n  return (node == null ? void 0 : node.ownerDocument) || document;\n}\nfunction isEventTargetWithin(event, node) {\n  if (node == null) {\n    return false;\n  }\n  if ('composedPath' in event) {\n    return event.composedPath().includes(node);\n  }\n\n  // TS thinks `event` is of type never as it assumes all browsers support composedPath, but browsers without shadow dom don't\n  const e = event;\n  return e.target != null && node.contains(e.target);\n}\nfunction getTarget(event) {\n  if ('composedPath' in event) {\n    return event.composedPath()[0];\n  }\n\n  // TS thinks `event` is of type never as it assumes all browsers support\n  // `composedPath()`, but browsers without shadow DOM don't.\n  return event.target;\n}\nconst TYPEABLE_SELECTOR = \"input:not([type='hidden']):not([disabled]),\" + \"[contenteditable]:not([contenteditable='false']),textarea:not([disabled])\";\nfunction isTypeableElement(element) {\n  return isHTMLElement(element) && element.matches(TYPEABLE_SELECTOR);\n}\nfunction stopEvent(event) {\n  event.preventDefault();\n  event.stopPropagation();\n}\nfunction isTypeableCombobox(element) {\n  if (!element) return false;\n  return element.getAttribute('role') === 'combobox' && isTypeableElement(element);\n}\n\nexport { TYPEABLE_SELECTOR, activeElement, contains, getDocument, getPlatform, getTarget, getUserAgent, isAndroid, isEventTargetWithin, isJSDOM, isMac, isMouseLikePointerType, isReactEvent, isRootElement, isSafari, isTypeableCombobox, isTypeableElement, isVirtualClick, isVirtualPointerEvent, stopEvent };\n","/*!\n* tabbable 6.4.0\n* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE\n*/\n// NOTE: separate `:not()` selectors has broader browser support than the newer\n//  `:not([inert], [inert] *)` (Feb 2023)\nvar candidateSelectors = ['input:not([inert]):not([inert] *)', 'select:not([inert]):not([inert] *)', 'textarea:not([inert]):not([inert] *)', 'a[href]:not([inert]):not([inert] *)', 'button:not([inert]):not([inert] *)', '[tabindex]:not(slot):not([inert]):not([inert] *)', 'audio[controls]:not([inert]):not([inert] *)', 'video[controls]:not([inert]):not([inert] *)', '[contenteditable]:not([contenteditable=\"false\"]):not([inert]):not([inert] *)', 'details>summary:first-of-type:not([inert]):not([inert] *)', 'details:not([inert]):not([inert] *)'];\nvar candidateSelector = /* #__PURE__ */candidateSelectors.join(',');\nvar NoElement = typeof Element === 'undefined';\nvar matches = NoElement ? function () {} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector;\nvar getRootNode = !NoElement && Element.prototype.getRootNode ? function (element) {\n  var _element$getRootNode;\n  return element === null || element === void 0 ? void 0 : (_element$getRootNode = element.getRootNode) === null || _element$getRootNode === void 0 ? void 0 : _element$getRootNode.call(element);\n} : function (element) {\n  return element === null || element === void 0 ? void 0 : element.ownerDocument;\n};\n\n/**\n * Determines if a node is inert or in an inert ancestor.\n * @param {Node} [node]\n * @param {boolean} [lookUp] If true and `node` is not inert, looks up at ancestors to\n *  see if any of them are inert. If false, only `node` itself is considered.\n * @returns {boolean} True if inert itself or by way of being in an inert ancestor.\n *  False if `node` is falsy.\n */\nvar _isInert = function isInert(node, lookUp) {\n  var _node$getAttribute;\n  if (lookUp === void 0) {\n    lookUp = true;\n  }\n  // CAREFUL: JSDom does not support inert at all, so we can't use the `HTMLElement.inert`\n  //  JS API property; we have to check the attribute, which can either be empty or 'true';\n  //  if it's `null` (not specified) or 'false', it's an active element\n  var inertAtt = node === null || node === void 0 ? void 0 : (_node$getAttribute = node.getAttribute) === null || _node$getAttribute === void 0 ? void 0 : _node$getAttribute.call(node, 'inert');\n  var inert = inertAtt === '' || inertAtt === 'true';\n\n  // NOTE: this could also be handled with `node.matches('[inert], :is([inert] *)')`\n  //  if it weren't for `matches()` not being a function on shadow roots; the following\n  //  code works for any kind of node\n  var result = inert || lookUp && node && (\n  // closest does not exist on shadow roots, so we fall back to a manual\n  // lookup upward, in case it is not defined.\n  typeof node.closest === 'function' ? node.closest('[inert]') : _isInert(node.parentNode));\n  return result;\n};\n\n/**\n * Determines if a node's content is editable.\n * @param {Element} [node]\n * @returns True if it's content-editable; false if it's not or `node` is falsy.\n */\nvar isContentEditable = function isContentEditable(node) {\n  var _node$getAttribute2;\n  // CAREFUL: JSDom does not support the `HTMLElement.isContentEditable` API so we have\n  //  to use the attribute directly to check for this, which can either be empty or 'true';\n  //  if it's `null` (not specified) or 'false', it's a non-editable element\n  var attValue = node === null || node === void 0 ? void 0 : (_node$getAttribute2 = node.getAttribute) === null || _node$getAttribute2 === void 0 ? void 0 : _node$getAttribute2.call(node, 'contenteditable');\n  return attValue === '' || attValue === 'true';\n};\n\n/**\n * @param {Element} el container to check in\n * @param {boolean} includeContainer add container to check\n * @param {(node: Element) => boolean} filter filter candidates\n * @returns {Element[]}\n */\nvar getCandidates = function getCandidates(el, includeContainer, filter) {\n  // even if `includeContainer=false`, we still have to check it for inertness because\n  //  if it's inert (either by itself or via its parent), then all its children are inert\n  if (_isInert(el)) {\n    return [];\n  }\n  var candidates = Array.prototype.slice.apply(el.querySelectorAll(candidateSelector));\n  if (includeContainer && matches.call(el, candidateSelector)) {\n    candidates.unshift(el);\n  }\n  candidates = candidates.filter(filter);\n  return candidates;\n};\n\n/**\n * @callback GetShadowRoot\n * @param {Element} element to check for shadow root\n * @returns {ShadowRoot|boolean} ShadowRoot if available or boolean indicating if a shadowRoot is attached but not available.\n */\n\n/**\n * @callback ShadowRootFilter\n * @param {Element} shadowHostNode the element which contains shadow content\n * @returns {boolean} true if a shadow root could potentially contain valid candidates.\n */\n\n/**\n * @typedef {Object} CandidateScope\n * @property {Element} scopeParent contains inner candidates\n * @property {Element[]} candidates list of candidates found in the scope parent\n */\n\n/**\n * @typedef {Object} IterativeOptions\n * @property {GetShadowRoot|boolean} getShadowRoot true if shadow support is enabled; falsy if not;\n *  if a function, implies shadow support is enabled and either returns the shadow root of an element\n *  or a boolean stating if it has an undisclosed shadow root\n * @property {(node: Element) => boolean} filter filter candidates\n * @property {boolean} flatten if true then result will flatten any CandidateScope into the returned list\n * @property {ShadowRootFilter} shadowRootFilter filter shadow roots;\n */\n\n/**\n * @param {Element[]} elements list of element containers to match candidates from\n * @param {boolean} includeContainer add container list to check\n * @param {IterativeOptions} options\n * @returns {Array.<Element|CandidateScope>}\n */\nvar _getCandidatesIteratively = function getCandidatesIteratively(elements, includeContainer, options) {\n  var candidates = [];\n  var elementsToCheck = Array.from(elements);\n  while (elementsToCheck.length) {\n    var element = elementsToCheck.shift();\n    if (_isInert(element, false)) {\n      // no need to look up since we're drilling down\n      // anything inside this container will also be inert\n      continue;\n    }\n    if (element.tagName === 'SLOT') {\n      // add shadow dom slot scope (slot itself cannot be focusable)\n      var assigned = element.assignedElements();\n      var content = assigned.length ? assigned : element.children;\n      var nestedCandidates = _getCandidatesIteratively(content, true, options);\n      if (options.flatten) {\n        candidates.push.apply(candidates, nestedCandidates);\n      } else {\n        candidates.push({\n          scopeParent: element,\n          candidates: nestedCandidates\n        });\n      }\n    } else {\n      // check candidate element\n      var validCandidate = matches.call(element, candidateSelector);\n      if (validCandidate && options.filter(element) && (includeContainer || !elements.includes(element))) {\n        candidates.push(element);\n      }\n\n      // iterate over shadow content if possible\n      var shadowRoot = element.shadowRoot ||\n      // check for an undisclosed shadow\n      typeof options.getShadowRoot === 'function' && options.getShadowRoot(element);\n\n      // no inert look up because we're already drilling down and checking for inertness\n      //  on the way down, so all containers to this root node should have already been\n      //  vetted as non-inert\n      var validShadowRoot = !_isInert(shadowRoot, false) && (!options.shadowRootFilter || options.shadowRootFilter(element));\n      if (shadowRoot && validShadowRoot) {\n        // add shadow dom scope IIF a shadow root node was given; otherwise, an undisclosed\n        //  shadow exists, so look at light dom children as fallback BUT create a scope for any\n        //  child candidates found because they're likely slotted elements (elements that are\n        //  children of the web component element (which has the shadow), in the light dom, but\n        //  slotted somewhere _inside_ the undisclosed shadow) -- the scope is created below,\n        //  _after_ we return from this recursive call\n        var _nestedCandidates = _getCandidatesIteratively(shadowRoot === true ? element.children : shadowRoot.children, true, options);\n        if (options.flatten) {\n          candidates.push.apply(candidates, _nestedCandidates);\n        } else {\n          candidates.push({\n            scopeParent: element,\n            candidates: _nestedCandidates\n          });\n        }\n      } else {\n        // there's not shadow so just dig into the element's (light dom) children\n        //  __without__ giving the element special scope treatment\n        elementsToCheck.unshift.apply(elementsToCheck, element.children);\n      }\n    }\n  }\n  return candidates;\n};\n\n/**\n * @private\n * Determines if the node has an explicitly specified `tabindex` attribute.\n * @param {HTMLElement} node\n * @returns {boolean} True if so; false if not.\n */\nvar hasTabIndex = function hasTabIndex(node) {\n  return !isNaN(parseInt(node.getAttribute('tabindex'), 10));\n};\n\n/**\n * Determine the tab index of a given node.\n * @param {HTMLElement} node\n * @returns {number} Tab order (negative, 0, or positive number).\n * @throws {Error} If `node` is falsy.\n */\nvar getTabIndex = function getTabIndex(node) {\n  if (!node) {\n    throw new Error('No node provided');\n  }\n  if (node.tabIndex < 0) {\n    // in Chrome, <details/>, <audio controls/> and <video controls/> elements get a default\n    // `tabIndex` of -1 when the 'tabindex' attribute isn't specified in the DOM,\n    // yet they are still part of the regular tab order; in FF, they get a default\n    // `tabIndex` of 0; since Chrome still puts those elements in the regular tab\n    // order, consider their tab index to be 0.\n    // Also browsers do not return `tabIndex` correctly for contentEditable nodes;\n    // so if they don't have a tabindex attribute specifically set, assume it's 0.\n    if ((/^(AUDIO|VIDEO|DETAILS)$/.test(node.tagName) || isContentEditable(node)) && !hasTabIndex(node)) {\n      return 0;\n    }\n  }\n  return node.tabIndex;\n};\n\n/**\n * Determine the tab index of a given node __for sort order purposes__.\n * @param {HTMLElement} node\n * @param {boolean} [isScope] True for a custom element with shadow root or slot that, by default,\n *  has tabIndex -1, but needs to be sorted by document order in order for its content to be\n *  inserted into the correct sort position.\n * @returns {number} Tab order (negative, 0, or positive number).\n */\nvar getSortOrderTabIndex = function getSortOrderTabIndex(node, isScope) {\n  var tabIndex = getTabIndex(node);\n  if (tabIndex < 0 && isScope && !hasTabIndex(node)) {\n    return 0;\n  }\n  return tabIndex;\n};\nvar sortOrderedTabbables = function sortOrderedTabbables(a, b) {\n  return a.tabIndex === b.tabIndex ? a.documentOrder - b.documentOrder : a.tabIndex - b.tabIndex;\n};\nvar isInput = function isInput(node) {\n  return node.tagName === 'INPUT';\n};\nvar isHiddenInput = function isHiddenInput(node) {\n  return isInput(node) && node.type === 'hidden';\n};\nvar isDetailsWithSummary = function isDetailsWithSummary(node) {\n  var r = node.tagName === 'DETAILS' && Array.prototype.slice.apply(node.children).some(function (child) {\n    return child.tagName === 'SUMMARY';\n  });\n  return r;\n};\nvar getCheckedRadio = function getCheckedRadio(nodes, form) {\n  for (var i = 0; i < nodes.length; i++) {\n    if (nodes[i].checked && nodes[i].form === form) {\n      return nodes[i];\n    }\n  }\n};\nvar isTabbableRadio = function isTabbableRadio(node) {\n  if (!node.name) {\n    return true;\n  }\n  var radioScope = node.form || getRootNode(node);\n  var queryRadios = function queryRadios(name) {\n    return radioScope.querySelectorAll('input[type=\"radio\"][name=\"' + name + '\"]');\n  };\n  var radioSet;\n  if (typeof window !== 'undefined' && typeof window.CSS !== 'undefined' && typeof window.CSS.escape === 'function') {\n    radioSet = queryRadios(window.CSS.escape(node.name));\n  } else {\n    try {\n      radioSet = queryRadios(node.name);\n    } catch (err) {\n      // eslint-disable-next-line no-console\n      console.error('Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s', err.message);\n      return false;\n    }\n  }\n  var checked = getCheckedRadio(radioSet, node.form);\n  return !checked || checked === node;\n};\nvar isRadio = function isRadio(node) {\n  return isInput(node) && node.type === 'radio';\n};\nvar isNonTabbableRadio = function isNonTabbableRadio(node) {\n  return isRadio(node) && !isTabbableRadio(node);\n};\n\n// determines if a node is ultimately attached to the window's document\nvar isNodeAttached = function isNodeAttached(node) {\n  var _nodeRoot;\n  // The root node is the shadow root if the node is in a shadow DOM; some document otherwise\n  //  (but NOT _the_ document; see second 'If' comment below for more).\n  // If rootNode is shadow root, it'll have a host, which is the element to which the shadow\n  //  is attached, and the one we need to check if it's in the document or not (because the\n  //  shadow, and all nodes it contains, is never considered in the document since shadows\n  //  behave like self-contained DOMs; but if the shadow's HOST, which is part of the document,\n  //  is hidden, or is not in the document itself but is detached, it will affect the shadow's\n  //  visibility, including all the nodes it contains). The host could be any normal node,\n  //  or a custom element (i.e. web component). Either way, that's the one that is considered\n  //  part of the document, not the shadow root, nor any of its children (i.e. the node being\n  //  tested).\n  // To further complicate things, we have to look all the way up until we find a shadow HOST\n  //  that is attached (or find none) because the node might be in nested shadows...\n  // If rootNode is not a shadow root, it won't have a host, and so rootNode should be the\n  //  document (per the docs) and while it's a Document-type object, that document does not\n  //  appear to be the same as the node's `ownerDocument` for some reason, so it's safer\n  //  to ignore the rootNode at this point, and use `node.ownerDocument`. Otherwise,\n  //  using `rootNode.contains(node)` will _always_ be true we'll get false-positives when\n  //  node is actually detached.\n  // NOTE: If `nodeRootHost` or `node` happens to be the `document` itself (which is possible\n  //  if a tabbable/focusable node was quickly added to the DOM, focused, and then removed\n  //  from the DOM as in https://github.com/focus-trap/focus-trap-react/issues/905), then\n  //  `ownerDocument` will be `null`, hence the optional chaining on it.\n  var nodeRoot = node && getRootNode(node);\n  var nodeRootHost = (_nodeRoot = nodeRoot) === null || _nodeRoot === void 0 ? void 0 : _nodeRoot.host;\n\n  // in some cases, a detached node will return itself as the root instead of a document or\n  //  shadow root object, in which case, we shouldn't try to look further up the host chain\n  var attached = false;\n  if (nodeRoot && nodeRoot !== node) {\n    var _nodeRootHost, _nodeRootHost$ownerDo, _node$ownerDocument;\n    attached = !!((_nodeRootHost = nodeRootHost) !== null && _nodeRootHost !== void 0 && (_nodeRootHost$ownerDo = _nodeRootHost.ownerDocument) !== null && _nodeRootHost$ownerDo !== void 0 && _nodeRootHost$ownerDo.contains(nodeRootHost) || node !== null && node !== void 0 && (_node$ownerDocument = node.ownerDocument) !== null && _node$ownerDocument !== void 0 && _node$ownerDocument.contains(node));\n    while (!attached && nodeRootHost) {\n      var _nodeRoot2, _nodeRootHost2, _nodeRootHost2$ownerD;\n      // since it's not attached and we have a root host, the node MUST be in a nested shadow DOM,\n      //  which means we need to get the host's host and check if that parent host is contained\n      //  in (i.e. attached to) the document\n      nodeRoot = getRootNode(nodeRootHost);\n      nodeRootHost = (_nodeRoot2 = nodeRoot) === null || _nodeRoot2 === void 0 ? void 0 : _nodeRoot2.host;\n      attached = !!((_nodeRootHost2 = nodeRootHost) !== null && _nodeRootHost2 !== void 0 && (_nodeRootHost2$ownerD = _nodeRootHost2.ownerDocument) !== null && _nodeRootHost2$ownerD !== void 0 && _nodeRootHost2$ownerD.contains(nodeRootHost));\n    }\n  }\n  return attached;\n};\nvar isZeroArea = function isZeroArea(node) {\n  var _node$getBoundingClie = node.getBoundingClientRect(),\n    width = _node$getBoundingClie.width,\n    height = _node$getBoundingClie.height;\n  return width === 0 && height === 0;\n};\nvar isHidden = function isHidden(node, _ref) {\n  var displayCheck = _ref.displayCheck,\n    getShadowRoot = _ref.getShadowRoot;\n  if (displayCheck === 'full-native') {\n    if ('checkVisibility' in node) {\n      // Chrome >= 105, Edge >= 105, Firefox >= 106, Safari >= 17.4\n      // @see https://developer.mozilla.org/en-US/docs/Web/API/Element/checkVisibility#browser_compatibility\n      var visible = node.checkVisibility({\n        // Checking opacity might be desirable for some use cases, but natively,\n        // opacity zero elements _are_ focusable and tabbable.\n        checkOpacity: false,\n        opacityProperty: false,\n        contentVisibilityAuto: true,\n        visibilityProperty: true,\n        // This is an alias for `visibilityProperty`. Contemporary browsers\n        // support both. However, this alias has wider browser support (Chrome\n        // >= 105 and Firefox >= 106, vs. Chrome >= 121 and Firefox >= 122), so\n        // we include it anyway.\n        checkVisibilityCSS: true\n      });\n      return !visible;\n    }\n    // Fall through to manual visibility checks\n  }\n\n  // NOTE: visibility will be `undefined` if node is detached from the document\n  //  (see notes about this further down), which means we will consider it visible\n  //  (this is legacy behavior from a very long way back)\n  // NOTE: we check this regardless of `displayCheck=\"none\"` because this is a\n  //  _visibility_ check, not a _display_ check\n  if (getComputedStyle(node).visibility === 'hidden') {\n    return true;\n  }\n  var isDirectSummary = matches.call(node, 'details>summary:first-of-type');\n  var nodeUnderDetails = isDirectSummary ? node.parentElement : node;\n  if (matches.call(nodeUnderDetails, 'details:not([open]) *')) {\n    return true;\n  }\n  if (!displayCheck || displayCheck === 'full' ||\n  // full-native can run this branch when it falls through in case\n  // Element#checkVisibility is unsupported\n  displayCheck === 'full-native' || displayCheck === 'legacy-full') {\n    if (typeof getShadowRoot === 'function') {\n      // figure out if we should consider the node to be in an undisclosed shadow and use the\n      //  'non-zero-area' fallback\n      var originalNode = node;\n      while (node) {\n        var parentElement = node.parentElement;\n        var rootNode = getRootNode(node);\n        if (parentElement && !parentElement.shadowRoot && getShadowRoot(parentElement) === true // check if there's an undisclosed shadow\n        ) {\n          // node has an undisclosed shadow which means we can only treat it as a black box, so we\n          //  fall back to a non-zero-area test\n          return isZeroArea(node);\n        } else if (node.assignedSlot) {\n          // iterate up slot\n          node = node.assignedSlot;\n        } else if (!parentElement && rootNode !== node.ownerDocument) {\n          // cross shadow boundary\n          node = rootNode.host;\n        } else {\n          // iterate up normal dom\n          node = parentElement;\n        }\n      }\n      node = originalNode;\n    }\n    // else, `getShadowRoot` might be true, but all that does is enable shadow DOM support\n    //  (i.e. it does not also presume that all nodes might have undisclosed shadows); or\n    //  it might be a falsy value, which means shadow DOM support is disabled\n\n    // Since we didn't find it sitting in an undisclosed shadow (or shadows are disabled)\n    //  now we can just test to see if it would normally be visible or not, provided it's\n    //  attached to the main document.\n    // NOTE: We must consider case where node is inside a shadow DOM and given directly to\n    //  `isTabbable()` or `isFocusable()` -- regardless of `getShadowRoot` option setting.\n\n    if (isNodeAttached(node)) {\n      // this works wherever the node is: if there's at least one client rect, it's\n      //  somehow displayed; it also covers the CSS 'display: contents' case where the\n      //  node itself is hidden in place of its contents; and there's no need to search\n      //  up the hierarchy either\n      return !node.getClientRects().length;\n    }\n\n    // Else, the node isn't attached to the document, which means the `getClientRects()`\n    //  API will __always__ return zero rects (this can happen, for example, if React\n    //  is used to render nodes onto a detached tree, as confirmed in this thread:\n    //  https://github.com/facebook/react/issues/9117#issuecomment-284228870)\n    //\n    // It also means that even window.getComputedStyle(node).display will return `undefined`\n    //  because styles are only computed for nodes that are in the document.\n    //\n    // NOTE: THIS HAS BEEN THE CASE FOR YEARS. It is not new, nor is it caused by tabbable\n    //  somehow. Though it was never stated officially, anyone who has ever used tabbable\n    //  APIs on nodes in detached containers has actually implicitly used tabbable in what\n    //  was later (as of v5.2.0 on Apr 9, 2021) called `displayCheck=\"none\"` mode -- essentially\n    //  considering __everything__ to be visible because of the innability to determine styles.\n    //\n    // v6.0.0: As of this major release, the default 'full' option __no longer treats detached\n    //  nodes as visible with the 'none' fallback.__\n    if (displayCheck !== 'legacy-full') {\n      return true; // hidden\n    }\n    // else, fallback to 'none' mode and consider the node visible\n  } else if (displayCheck === 'non-zero-area') {\n    // NOTE: Even though this tests that the node's client rect is non-zero to determine\n    //  whether it's displayed, and that a detached node will __always__ have a zero-area\n    //  client rect, we don't special-case for whether the node is attached or not. In\n    //  this mode, we do want to consider nodes that have a zero area to be hidden at all\n    //  times, and that includes attached or not.\n    return isZeroArea(node);\n  }\n\n  // visible, as far as we can tell, or per current `displayCheck=none` mode, we assume\n  //  it's visible\n  return false;\n};\n\n// form fields (nested) inside a disabled fieldset are not focusable/tabbable\n//  unless they are in the _first_ <legend> element of the top-most disabled\n//  fieldset\nvar isDisabledFromFieldset = function isDisabledFromFieldset(node) {\n  if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(node.tagName)) {\n    var parentNode = node.parentElement;\n    // check if `node` is contained in a disabled <fieldset>\n    while (parentNode) {\n      if (parentNode.tagName === 'FIELDSET' && parentNode.disabled) {\n        // look for the first <legend> among the children of the disabled <fieldset>\n        for (var i = 0; i < parentNode.children.length; i++) {\n          var child = parentNode.children.item(i);\n          // when the first <legend> (in document order) is found\n          if (child.tagName === 'LEGEND') {\n            // if its parent <fieldset> is not nested in another disabled <fieldset>,\n            // return whether `node` is a descendant of its first <legend>\n            return matches.call(parentNode, 'fieldset[disabled] *') ? true : !child.contains(node);\n          }\n        }\n        // the disabled <fieldset> containing `node` has no <legend>\n        return true;\n      }\n      parentNode = parentNode.parentElement;\n    }\n  }\n\n  // else, node's tabbable/focusable state should not be affected by a fieldset's\n  //  enabled/disabled state\n  return false;\n};\nvar isNodeMatchingSelectorFocusable = function isNodeMatchingSelectorFocusable(options, node) {\n  if (node.disabled || isHiddenInput(node) || isHidden(node, options) ||\n  // For a details element with a summary, the summary element gets the focus\n  isDetailsWithSummary(node) || isDisabledFromFieldset(node)) {\n    return false;\n  }\n  return true;\n};\nvar isNodeMatchingSelectorTabbable = function isNodeMatchingSelectorTabbable(options, node) {\n  if (isNonTabbableRadio(node) || getTabIndex(node) < 0 || !isNodeMatchingSelectorFocusable(options, node)) {\n    return false;\n  }\n  return true;\n};\nvar isShadowRootTabbable = function isShadowRootTabbable(shadowHostNode) {\n  var tabIndex = parseInt(shadowHostNode.getAttribute('tabindex'), 10);\n  if (isNaN(tabIndex) || tabIndex >= 0) {\n    return true;\n  }\n  // If a custom element has an explicit negative tabindex,\n  // browsers will not allow tab targeting said element's children.\n  return false;\n};\n\n/**\n * @param {Array.<Element|CandidateScope>} candidates\n * @returns Element[]\n */\nvar _sortByOrder = function sortByOrder(candidates) {\n  var regularTabbables = [];\n  var orderedTabbables = [];\n  candidates.forEach(function (item, i) {\n    var isScope = !!item.scopeParent;\n    var element = isScope ? item.scopeParent : item;\n    var candidateTabindex = getSortOrderTabIndex(element, isScope);\n    var elements = isScope ? _sortByOrder(item.candidates) : element;\n    if (candidateTabindex === 0) {\n      isScope ? regularTabbables.push.apply(regularTabbables, elements) : regularTabbables.push(element);\n    } else {\n      orderedTabbables.push({\n        documentOrder: i,\n        tabIndex: candidateTabindex,\n        item: item,\n        isScope: isScope,\n        content: elements\n      });\n    }\n  });\n  return orderedTabbables.sort(sortOrderedTabbables).reduce(function (acc, sortable) {\n    sortable.isScope ? acc.push.apply(acc, sortable.content) : acc.push(sortable.content);\n    return acc;\n  }, []).concat(regularTabbables);\n};\nvar tabbable = function tabbable(container, options) {\n  options = options || {};\n  var candidates;\n  if (options.getShadowRoot) {\n    candidates = _getCandidatesIteratively([container], options.includeContainer, {\n      filter: isNodeMatchingSelectorTabbable.bind(null, options),\n      flatten: false,\n      getShadowRoot: options.getShadowRoot,\n      shadowRootFilter: isShadowRootTabbable\n    });\n  } else {\n    candidates = getCandidates(container, options.includeContainer, isNodeMatchingSelectorTabbable.bind(null, options));\n  }\n  return _sortByOrder(candidates);\n};\nvar focusable = function focusable(container, options) {\n  options = options || {};\n  var candidates;\n  if (options.getShadowRoot) {\n    candidates = _getCandidatesIteratively([container], options.includeContainer, {\n      filter: isNodeMatchingSelectorFocusable.bind(null, options),\n      flatten: true,\n      getShadowRoot: options.getShadowRoot\n    });\n  } else {\n    candidates = getCandidates(container, options.includeContainer, isNodeMatchingSelectorFocusable.bind(null, options));\n  }\n  return candidates;\n};\nvar isTabbable = function isTabbable(node, options) {\n  options = options || {};\n  if (!node) {\n    throw new Error('No node provided');\n  }\n  if (matches.call(node, candidateSelector) === false) {\n    return false;\n  }\n  return isNodeMatchingSelectorTabbable(options, node);\n};\nvar focusableCandidateSelector = /* #__PURE__ */candidateSelectors.concat('iframe:not([inert]):not([inert] *)').join(',');\nvar isFocusable = function isFocusable(node, options) {\n  options = options || {};\n  if (!node) {\n    throw new Error('No node provided');\n  }\n  if (matches.call(node, focusableCandidateSelector) === false) {\n    return false;\n  }\n  return isNodeMatchingSelectorFocusable(options, node);\n};\n\nexport { focusable, getTabIndex, isFocusable, isTabbable, tabbable };\n//# sourceMappingURL=index.esm.js.map\n","/**\n * Custom positioning reference element.\n * @see https://floating-ui.com/docs/virtual-elements\n */\n\nconst sides = ['top', 'right', 'bottom', 'left'];\nconst alignments = ['start', 'end'];\nconst placements = /*#__PURE__*/sides.reduce((acc, side) => acc.concat(side, side + \"-\" + alignments[0], side + \"-\" + alignments[1]), []);\nconst min = Math.min;\nconst max = Math.max;\nconst round = Math.round;\nconst floor = Math.floor;\nconst createCoords = v => ({\n  x: v,\n  y: v\n});\nconst oppositeSideMap = {\n  left: 'right',\n  right: 'left',\n  bottom: 'top',\n  top: 'bottom'\n};\nconst oppositeAlignmentMap = {\n  start: 'end',\n  end: 'start'\n};\nfunction clamp(start, value, end) {\n  return max(start, min(value, end));\n}\nfunction evaluate(value, param) {\n  return typeof value === 'function' ? value(param) : value;\n}\nfunction getSide(placement) {\n  return placement.split('-')[0];\n}\nfunction getAlignment(placement) {\n  return placement.split('-')[1];\n}\nfunction getOppositeAxis(axis) {\n  return axis === 'x' ? 'y' : 'x';\n}\nfunction getAxisLength(axis) {\n  return axis === 'y' ? 'height' : 'width';\n}\nconst yAxisSides = /*#__PURE__*/new Set(['top', 'bottom']);\nfunction getSideAxis(placement) {\n  return yAxisSides.has(getSide(placement)) ? 'y' : 'x';\n}\nfunction getAlignmentAxis(placement) {\n  return getOppositeAxis(getSideAxis(placement));\n}\nfunction getAlignmentSides(placement, rects, rtl) {\n  if (rtl === void 0) {\n    rtl = false;\n  }\n  const alignment = getAlignment(placement);\n  const alignmentAxis = getAlignmentAxis(placement);\n  const length = getAxisLength(alignmentAxis);\n  let mainAlignmentSide = alignmentAxis === '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 [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];\n}\nfunction getExpandedPlacements(placement) {\n  const oppositePlacement = getOppositePlacement(placement);\n  return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];\n}\nfunction getOppositeAlignmentPlacement(placement) {\n  return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);\n}\nconst lrPlacement = ['left', 'right'];\nconst rlPlacement = ['right', 'left'];\nconst tbPlacement = ['top', 'bottom'];\nconst btPlacement = ['bottom', 'top'];\nfunction getSideList(side, isStart, rtl) {\n  switch (side) {\n    case 'top':\n    case 'bottom':\n      if (rtl) return isStart ? rlPlacement : lrPlacement;\n      return isStart ? lrPlacement : rlPlacement;\n    case 'left':\n    case 'right':\n      return isStart ? tbPlacement : btPlacement;\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}\nfunction getOppositePlacement(placement) {\n  return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);\n}\nfunction expandPaddingObject(padding) {\n  return {\n    top: 0,\n    right: 0,\n    bottom: 0,\n    left: 0,\n    ...padding\n  };\n}\nfunction getPaddingObject(padding) {\n  return typeof padding !== 'number' ? expandPaddingObject(padding) : {\n    top: padding,\n    right: padding,\n    bottom: padding,\n    left: padding\n  };\n}\nfunction rectToClientRect(rect) {\n  const {\n    x,\n    y,\n    width,\n    height\n  } = rect;\n  return {\n    width,\n    height,\n    top: y,\n    left: x,\n    right: x + width,\n    bottom: y + height,\n    x,\n    y\n  };\n}\n\nexport { alignments, clamp, createCoords, evaluate, expandPaddingObject, floor, getAlignment, getAlignmentAxis, getAlignmentSides, getAxisLength, getExpandedPlacements, getOppositeAlignmentPlacement, getOppositeAxis, getOppositeAxisPlacements, getOppositePlacement, getPaddingObject, getSide, getSideAxis, max, min, placements, rectToClientRect, round, sides };\n","import { getSideAxis, getAlignmentAxis, getAxisLength, getSide, getAlignment, evaluate, getPaddingObject, rectToClientRect, min, clamp, placements, getAlignmentSides, getOppositeAlignmentPlacement, getOppositePlacement, getExpandedPlacements, getOppositeAxisPlacements, sides, max, getOppositeAxis } from '@floating-ui/utils';\nexport { rectToClientRect } from '@floating-ui/utils';\n\nfunction computeCoordsFromPlacement(_ref, placement, rtl) {\n  let {\n    reference,\n    floating\n  } = _ref;\n  const sideAxis = getSideAxis(placement);\n  const alignmentAxis = getAlignmentAxis(placement);\n  const alignLength = getAxisLength(alignmentAxis);\n  const side = getSide(placement);\n  const isVertical = sideAxis === 'y';\n  const commonX = reference.x + reference.width / 2 - floating.width / 2;\n  const commonY = reference.y + reference.height / 2 - floating.height / 2;\n  const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;\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[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);\n      break;\n    case 'end':\n      coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);\n      break;\n  }\n  return coords;\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  } = evaluate(options, state);\n  const paddingObject = getPaddingObject(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    x,\n    y,\n    width: rects.floating.width,\n    height: rects.floating.height\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    elements,\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\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a given reference element.\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 = 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    var _platform$detectOverf;\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        ...platform,\n        detectOverflow: (_platform$detectOverf = platform.detectOverflow) != null ? _platform$detectOverf : detectOverflow\n      },\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    }\n  }\n  return {\n    x,\n    y,\n    placement: statefulPlacement,\n    strategy,\n    middlewareData\n  };\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    const {\n      x,\n      y,\n      placement,\n      rects,\n      platform,\n      elements,\n      middlewareData\n    } = state;\n    // Since `element` is required, we don't Partial<> the type.\n    const {\n      element,\n      padding = 0\n    } = evaluate(options, state) || {};\n    if (element == null) {\n      return {};\n    }\n    const paddingObject = getPaddingObject(padding);\n    const coords = {\n      x,\n      y\n    };\n    const axis = getAlignmentAxis(placement);\n    const length = getAxisLength(axis);\n    const arrowDimensions = await platform.getDimensions(element);\n    const isYAxis = axis === 'y';\n    const minProp = isYAxis ? 'top' : 'left';\n    const maxProp = isYAxis ? 'bottom' : 'right';\n    const clientProp = isYAxis ? 'clientHeight' : 'clientWidth';\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 ? arrowOffsetParent[clientProp] : 0;\n\n    // DOM platform can return `window` as the `offsetParent`.\n    if (!clientSize || !(await (platform.isElement == null ? void 0 : platform.isElement(arrowOffsetParent)))) {\n      clientSize = elements.floating[clientProp] || rects.floating[length];\n    }\n    const centerToReference = endDiff / 2 - startDiff / 2;\n\n    // If the padding is large enough that it causes the arrow to no longer be\n    // centered, modify the padding so that it is centered.\n    const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;\n    const minPadding = min(paddingObject[minProp], largestPossiblePadding);\n    const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);\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$1 = minPadding;\n    const max = clientSize - arrowDimensions[length] - maxPadding;\n    const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;\n    const offset = clamp(min$1, 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. To ensure `shift()` continues to take action,\n    // a single reset is performed when this is true.\n    const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset && rects.reference[length] / 2 - (center < min$1 ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;\n    const alignmentOffset = shouldAddOffset ? center < min$1 ? center - min$1 : center - max : 0;\n    return {\n      [axis]: coords[axis] + alignmentOffset,\n      data: {\n        [axis]: offset,\n        centerOffset: center - offset - alignmentOffset,\n        ...(shouldAddOffset && {\n          alignmentOffset\n        })\n      },\n      reset: shouldAddOffset\n    };\n  }\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 = placements,\n        autoAlignment = true,\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      const placements$1 = alignment !== undefined || allowedPlacements === placements ? getPlacementList(alignment || null, autoAlignment, allowedPlacements) : allowedPlacements;\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const currentIndex = ((_middlewareData$autoP = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP.index) || 0;\n      const currentPlacement = placements$1[currentIndex];\n      if (currentPlacement == null) {\n        return {};\n      }\n      const alignmentSides = 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$1[0]\n          }\n        };\n      }\n      const currentOverflows = [overflow[getSide(currentPlacement)], overflow[alignmentSides[0]], overflow[alignmentSides[1]]];\n      const allOverflows = [...(((_middlewareData$autoP2 = middlewareData.autoPlacement) == null ? void 0 : _middlewareData$autoP2.overflows) || []), {\n        placement: currentPlacement,\n        overflows: currentOverflows\n      }];\n      const nextPlacement = placements$1[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\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$arrow, _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      } = evaluate(options, state);\n\n      // If a reset by the arrow was caused due to an alignment offset being\n      // added, we should skip any logic now since `flip()` has already done its\n      // work.\n      // https://github.com/floating-ui/floating-ui/issues/2549#issuecomment-1719601643\n      if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {\n        return {};\n      }\n      const side = getSide(placement);\n      const initialSideAxis = getSideAxis(initialPlacement);\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      const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== 'none';\n      if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {\n        fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));\n      }\n      const placements = [initialPlacement, ...fallbackPlacements];\n      const overflow = await platform.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 sides = getAlignmentSides(placement, rects, rtl);\n        overflows.push(overflow[sides[0]], overflow[sides[1]]);\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          const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;\n          if (!ignoreCrossAxisOverflow ||\n          // We leave the current main axis only if every placement on that axis\n          // overflows the main axis.\n          overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {\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\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$filter2;\n                const placement = (_overflowsData$filter2 = overflowsData.filter(d => {\n                  if (hasFallbackAxisSideDirection) {\n                    const currentSideAxis = getSideAxis(d.placement);\n                    return currentSideAxis === initialSideAxis ||\n                    // Create a bias to the `y` side axis due to horizontal\n                    // reading directions favoring greater width.\n                    currentSideAxis === 'y';\n                  }\n                  return true;\n                }).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$filter2[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        rects,\n        platform\n      } = state;\n      const {\n        strategy = 'referenceHidden',\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      switch (strategy) {\n        case 'referenceHidden':\n          {\n            const overflow = await platform.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 platform.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\nfunction getBoundingRect(rects) {\n  const minX = min(...rects.map(rect => rect.left));\n  const minY = min(...rects.map(rect => rect.top));\n  const maxX = max(...rects.map(rect => rect.right));\n  const maxY = max(...rects.map(rect => rect.bottom));\n  return {\n    x: minX,\n    y: minY,\n    width: maxX - minX,\n    height: maxY - minY\n  };\n}\nfunction getRectsByLine(rects) {\n  const sortedRects = rects.slice().sort((a, b) => a.y - b.y);\n  const groups = [];\n  let prevRect = null;\n  for (let i = 0; i < sortedRects.length; i++) {\n    const rect = sortedRects[i];\n    if (!prevRect || rect.y - prevRect.y > prevRect.height / 2) {\n      groups.push([rect]);\n    } else {\n      groups[groups.length - 1].push(rect);\n    }\n    prevRect = rect;\n  }\n  return groups.map(rect => rectToClientRect(getBoundingRect(rect)));\n}\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'inline',\n    options,\n    async fn(state) {\n      const {\n        placement,\n        elements,\n        rects,\n        platform,\n        strategy\n      } = state;\n      // A MouseEvent's client{X,Y} coords can be up to 2 pixels off a\n      // ClientRect's bounds, despite the event listener being triggered. A\n      // padding of 2 seems to handle this issue.\n      const {\n        padding = 2,\n        x,\n        y\n      } = evaluate(options, state);\n      const nativeClientRects = Array.from((await (platform.getClientRects == null ? void 0 : platform.getClientRects(elements.reference))) || []);\n      const clientRects = getRectsByLine(nativeClientRects);\n      const fallback = rectToClientRect(getBoundingRect(nativeClientRects));\n      const paddingObject = getPaddingObject(padding);\n      function getBoundingClientRect() {\n        // There are two rects and they are disjoined.\n        if (clientRects.length === 2 && clientRects[0].left > clientRects[1].right && x != null && y != null) {\n          // Find the first rect in which the point is fully inside.\n          return clientRects.find(rect => x > rect.left - paddingObject.left && x < rect.right + paddingObject.right && y > rect.top - paddingObject.top && y < rect.bottom + paddingObject.bottom) || fallback;\n        }\n\n        // There are 2 or more connected rects.\n        if (clientRects.length >= 2) {\n          if (getSideAxis(placement) === 'y') {\n            const firstRect = clientRects[0];\n            const lastRect = clientRects[clientRects.length - 1];\n            const isTop = getSide(placement) === 'top';\n            const top = firstRect.top;\n            const bottom = lastRect.bottom;\n            const left = isTop ? firstRect.left : lastRect.left;\n            const right = isTop ? firstRect.right : lastRect.right;\n            const width = right - left;\n            const height = bottom - top;\n            return {\n              top,\n              bottom,\n              left,\n              right,\n              width,\n              height,\n              x: left,\n              y: top\n            };\n          }\n          const isLeftSide = getSide(placement) === 'left';\n          const maxRight = max(...clientRects.map(rect => rect.right));\n          const minLeft = min(...clientRects.map(rect => rect.left));\n          const measureRects = clientRects.filter(rect => isLeftSide ? rect.left === minLeft : rect.right === maxRight);\n          const top = measureRects[0].top;\n          const bottom = measureRects[measureRects.length - 1].bottom;\n          const left = minLeft;\n          const right = maxRight;\n          const width = right - left;\n          const height = bottom - top;\n          return {\n            top,\n            bottom,\n            left,\n            right,\n            width,\n            height,\n            x: left,\n            y: top\n          };\n        }\n        return fallback;\n      }\n      const resetRects = await platform.getElementRects({\n        reference: {\n          getBoundingClientRect\n        },\n        floating: elements.floating,\n        strategy\n      });\n      if (rects.reference.x !== resetRects.reference.x || rects.reference.y !== resetRects.reference.y || rects.reference.width !== resetRects.reference.width || rects.reference.height !== resetRects.reference.height) {\n        return {\n          reset: {\n            rects: resetRects\n          }\n        };\n      }\n      return {};\n    }\n  };\n};\n\nconst originSides = /*#__PURE__*/new Set(['left', 'top']);\n\n// For type backwards-compatibility, the `OffsetOptions` type was also\n// Derivable.\n\nasync function convertValueToCoords(state, options) {\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 = getSideAxis(placement) === 'y';\n  const mainAxisMulti = originSides.has(side) ? -1 : 1;\n  const crossAxisMulti = rtl && isVertical ? -1 : 1;\n  const rawValue = evaluate(options, state);\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: rawValue.mainAxis || 0,\n    crossAxis: rawValue.crossAxis || 0,\n    alignmentAxis: rawValue.alignmentAxis\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 (options) {\n  if (options === void 0) {\n    options = 0;\n  }\n  return {\n    name: 'offset',\n    options,\n    async fn(state) {\n      var _middlewareData$offse, _middlewareData$arrow;\n      const {\n        x,\n        y,\n        placement,\n        middlewareData\n      } = state;\n      const diffCoords = await convertValueToCoords(state, options);\n\n      // If the placement is the same and the arrow caused an alignment offset\n      // then we don't need to change the positioning coordinates.\n      if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {\n        return {};\n      }\n      return {\n        x: x + diffCoords.x,\n        y: y + diffCoords.y,\n        data: {\n          ...diffCoords,\n          placement\n        }\n      };\n    }\n  };\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        platform\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      } = evaluate(options, state);\n      const coords = {\n        x,\n        y\n      };\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const crossAxis = getSideAxis(getSide(placement));\n      const mainAxis = getOppositeAxis(crossAxis);\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 = clamp(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 = clamp(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          enabled: {\n            [mainAxis]: checkMainAxis,\n            [crossAxis]: checkCrossAxis\n          }\n        }\n      };\n    }\n  };\n};\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    options,\n    fn(state) {\n      const {\n        x,\n        y,\n        placement,\n        rects,\n        middlewareData\n      } = state;\n      const {\n        offset = 0,\n        mainAxis: checkMainAxis = true,\n        crossAxis: checkCrossAxis = true\n      } = evaluate(options, state);\n      const coords = {\n        x,\n        y\n      };\n      const crossAxis = getSideAxis(placement);\n      const mainAxis = getOppositeAxis(crossAxis);\n      let mainAxisCoord = coords[mainAxis];\n      let crossAxisCoord = coords[crossAxis];\n      const rawOffset = evaluate(offset, state);\n      const computedOffset = typeof rawOffset === 'number' ? {\n        mainAxis: rawOffset,\n        crossAxis: 0\n      } : {\n        mainAxis: 0,\n        crossAxis: 0,\n        ...rawOffset\n      };\n      if (checkMainAxis) {\n        const len = mainAxis === 'y' ? 'height' : 'width';\n        const limitMin = rects.reference[mainAxis] - rects.floating[len] + computedOffset.mainAxis;\n        const limitMax = rects.reference[mainAxis] + rects.reference[len] - computedOffset.mainAxis;\n        if (mainAxisCoord < limitMin) {\n          mainAxisCoord = limitMin;\n        } else if (mainAxisCoord > limitMax) {\n          mainAxisCoord = limitMax;\n        }\n      }\n      if (checkCrossAxis) {\n        var _middlewareData$offse, _middlewareData$offse2;\n        const len = mainAxis === 'y' ? 'width' : 'height';\n        const isOriginSide = originSides.has(getSide(placement));\n        const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);\n        const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);\n        if (crossAxisCoord < limitMin) {\n          crossAxisCoord = limitMin;\n        } else if (crossAxisCoord > limitMax) {\n          crossAxisCoord = limitMax;\n        }\n      }\n      return {\n        [mainAxis]: mainAxisCoord,\n        [crossAxis]: crossAxisCoord\n      };\n    }\n  };\n};\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = function (options) {\n  if (options === void 0) {\n    options = {};\n  }\n  return {\n    name: 'size',\n    options,\n    async fn(state) {\n      var _state$middlewareData, _state$middlewareData2;\n      const {\n        placement,\n        rects,\n        platform,\n        elements\n      } = state;\n      const {\n        apply = () => {},\n        ...detectOverflowOptions\n      } = evaluate(options, state);\n      const overflow = await platform.detectOverflow(state, detectOverflowOptions);\n      const side = getSide(placement);\n      const alignment = getAlignment(placement);\n      const isYAxis = getSideAxis(placement) === 'y';\n      const {\n        width,\n        height\n      } = rects.floating;\n      let heightSide;\n      let widthSide;\n      if (side === 'top' || side === 'bottom') {\n        heightSide = side;\n        widthSide = alignment === ((await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating))) ? 'start' : 'end') ? 'left' : 'right';\n      } else {\n        widthSide = side;\n        heightSide = alignment === 'end' ? 'top' : 'bottom';\n      }\n      const maximumClippingHeight = height - overflow.top - overflow.bottom;\n      const maximumClippingWidth = width - overflow.left - overflow.right;\n      const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);\n      const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);\n      const noShift = !state.middlewareData.shift;\n      let availableHeight = overflowAvailableHeight;\n      let availableWidth = overflowAvailableWidth;\n      if ((_state$middlewareData = state.middlewareData.shift) != null && _state$middlewareData.enabled.x) {\n        availableWidth = maximumClippingWidth;\n      }\n      if ((_state$middlewareData2 = state.middlewareData.shift) != null && _state$middlewareData2.enabled.y) {\n        availableHeight = maximumClippingHeight;\n      }\n      if (noShift && !alignment) {\n        const xMin = max(overflow.left, 0);\n        const xMax = max(overflow.right, 0);\n        const yMin = max(overflow.top, 0);\n        const yMax = max(overflow.bottom, 0);\n        if (isYAxis) {\n          availableWidth = width - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));\n        } else {\n          availableHeight = height - 2 * (yMin !== 0 || yMax !== 0 ? yMin + yMax : max(overflow.top, overflow.bottom));\n        }\n      }\n      await apply({\n        ...state,\n        availableWidth,\n        availableHeight\n      });\n      const nextDimensions = await platform.getDimensions(elements.floating);\n      if (width !== nextDimensions.width || height !== nextDimensions.height) {\n        return {\n          reset: {\n            rects: true\n          }\n        };\n      }\n      return {};\n    }\n  };\n};\n\nexport { arrow, autoPlacement, computePosition, detectOverflow, flip, hide, inline, limitShift, offset, shift, size };\n","import { rectToClientRect, arrow as arrow$1, autoPlacement as autoPlacement$1, detectOverflow as detectOverflow$1, flip as flip$1, hide as hide$1, inline as inline$1, limitShift as limitShift$1, offset as offset$1, shift as shift$1, size as size$1, computePosition as computePosition$1 } from '@floating-ui/core';\nimport { round, createCoords, max, min, floor } from '@floating-ui/utils';\nimport { getComputedStyle as getComputedStyle$1, isHTMLElement, isElement, getWindow, isWebKit, getFrameElement, getNodeScroll, getDocumentElement, isTopLayer, getNodeName, isOverflowElement, getOverflowAncestors, getParentNode, isLastTraversableNode, isContainingBlock, isTableElement, getContainingBlock } from '@floating-ui/utils/dom';\nexport { getOverflowAncestors } from '@floating-ui/utils/dom';\n\nfunction getCssDimensions(element) {\n  const css = getComputedStyle$1(element);\n  // In testing environments, the `width` and `height` properties are empty\n  // strings for SVG elements, returning NaN. Fallback to `0` in this case.\n  let width = parseFloat(css.width) || 0;\n  let height = parseFloat(css.height) || 0;\n  const hasOffset = isHTMLElement(element);\n  const offsetWidth = hasOffset ? element.offsetWidth : width;\n  const offsetHeight = hasOffset ? element.offsetHeight : height;\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    $: shouldFallback\n  };\n}\n\nfunction unwrapElement(element) {\n  return !isElement(element) ? element.contextElement : element;\n}\n\nfunction getScale(element) {\n  const domElement = unwrapElement(element);\n  if (!isHTMLElement(domElement)) {\n    return createCoords(1);\n  }\n  const rect = domElement.getBoundingClientRect();\n  const {\n    width,\n    height,\n    $\n  } = getCssDimensions(domElement);\n  let x = ($ ? round(rect.width) : rect.width) / width;\n  let y = ($ ? 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\nconst noOffsets = /*#__PURE__*/createCoords(0);\nfunction getVisualOffsets(element) {\n  const win = getWindow(element);\n  if (!isWebKit() || !win.visualViewport) {\n    return noOffsets;\n  }\n  return {\n    x: win.visualViewport.offsetLeft,\n    y: win.visualViewport.offsetTop\n  };\n}\nfunction shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {\n  if (isFixed === void 0) {\n    isFixed = false;\n  }\n  if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {\n    return false;\n  }\n  return isFixed;\n}\n\nfunction getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {\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 = createCoords(1);\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 visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);\n  let x = (clientRect.left + visualOffsets.x) / scale.x;\n  let y = (clientRect.top + visualOffsets.y) / 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 currentWin = win;\n    let currentIFrame = getFrameElement(currentWin);\n    while (currentIFrame && offsetParent && offsetWin !== currentWin) {\n      const iframeScale = getScale(currentIFrame);\n      const iframeRect = currentIFrame.getBoundingClientRect();\n      const css = getComputedStyle$1(currentIFrame);\n      const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;\n      const top = iframeRect.top + (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 += left;\n      y += top;\n      currentWin = getWindow(currentIFrame);\n      currentIFrame = getFrameElement(currentWin);\n    }\n  }\n  return rectToClientRect({\n    width,\n    height,\n    x,\n    y\n  });\n}\n\n// If <html> has a CSS width greater than the viewport, then this will be\n// incorrect for RTL.\nfunction getWindowScrollBarX(element, rect) {\n  const leftScroll = getNodeScroll(element).scrollLeft;\n  if (!rect) {\n    return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;\n  }\n  return rect.left + leftScroll;\n}\n\nfunction getHTMLOffset(documentElement, scroll) {\n  const htmlRect = documentElement.getBoundingClientRect();\n  const x = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);\n  const y = htmlRect.top + scroll.scrollTop;\n  return {\n    x,\n    y\n  };\n}\n\nfunction convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {\n  let {\n    elements,\n    rect,\n    offsetParent,\n    strategy\n  } = _ref;\n  const isFixed = strategy === 'fixed';\n  const documentElement = getDocumentElement(offsetParent);\n  const topLayer = elements ? isTopLayer(elements.floating) : false;\n  if (offsetParent === documentElement || topLayer && isFixed) {\n    return rect;\n  }\n  let scroll = {\n    scrollLeft: 0,\n    scrollTop: 0\n  };\n  let scale = createCoords(1);\n  const offsets = createCoords(0);\n  const isOffsetParentAnElement = isHTMLElement(offsetParent);\n  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\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  const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);\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 + htmlOffset.x,\n    y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y\n  };\n}\n\nfunction getClientRects(element) {\n  return Array.from(element.getClientRects());\n}\n\n// Gets the entire size of the scrollable document area, even extending outside\n// of the `<html>` and `<body>` 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\n// Safety check: ensure the scrollbar space is reasonable in case this\n// calculation is affected by unusual styles.\n// Most scrollbars leave 15-18px of space.\nconst SCROLLBAR_MAX = 25;\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 = isWebKit();\n    if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {\n      x = visualViewport.offsetLeft;\n      y = visualViewport.offsetTop;\n    }\n  }\n  const windowScrollbarX = getWindowScrollBarX(html);\n  // <html> `overflow: hidden` + `scrollbar-gutter: stable` reduces the\n  // visual width of the <html> but this is not considered in the size\n  // of `html.clientWidth`.\n  if (windowScrollbarX <= 0) {\n    const doc = html.ownerDocument;\n    const body = doc.body;\n    const bodyStyles = getComputedStyle(body);\n    const bodyMarginInline = doc.compatMode === 'CSS1Compat' ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;\n    const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);\n    if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {\n      width -= clippingStableScrollbarWidth;\n    }\n  } else if (windowScrollbarX <= SCROLLBAR_MAX) {\n    // If the <body> scrollbar is on the left, the width needs to be extended\n    // by the scrollbar amount so there isn't extra space on the right.\n    width += windowScrollbarX;\n  }\n  return {\n    width,\n    height,\n    x,\n    y\n  };\n}\n\nconst absoluteOrFixed = /*#__PURE__*/new Set(['absolute', 'fixed']);\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) : createCoords(1);\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 visualOffsets = getVisualOffsets(element);\n    rect = {\n      x: clippingAncestor.x - visualOffsets.x,\n      y: clippingAncestor.y - visualOffsets.y,\n      width: clippingAncestor.width,\n      height: clippingAncestor.height\n    };\n  }\n  return rectToClientRect(rect);\n}\nfunction hasFixedPositionAncestor(element, stopNode) {\n  const parentNode = getParentNode(element);\n  if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {\n    return false;\n  }\n  return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);\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, [], false).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 currentNodeIsContaining = isContainingBlock(currentNode);\n    if (!currentNodeIsContaining && computedStyle.position === 'fixed') {\n      currentContainingBlockComputedStyle = null;\n    }\n    const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);\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    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' ? isTopLayer(element) ? [] : 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  const {\n    width,\n    height\n  } = getCssDimensions(element);\n  return {\n    width,\n    height\n  };\n}\n\nfunction getRectRelativeToOffsetParent(element, offsetParent, strategy) {\n  const isOffsetParentAnElement = isHTMLElement(offsetParent);\n  const documentElement = getDocumentElement(offsetParent);\n  const isFixed = strategy === 'fixed';\n  const rect = getBoundingClientRect(element, true, isFixed, offsetParent);\n  let scroll = {\n    scrollLeft: 0,\n    scrollTop: 0\n  };\n  const offsets = createCoords(0);\n\n  // If the <body> scrollbar appears on the left (e.g. RTL systems). Use\n  // Firefox with layout.scrollbar.side = 3 in about:config to test this.\n  function setLeftRTLScrollbarOffset() {\n    offsets.x = getWindowScrollBarX(documentElement);\n  }\n  if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {\n    if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {\n      scroll = getNodeScroll(offsetParent);\n    }\n    if (isOffsetParentAnElement) {\n      const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);\n      offsets.x = offsetRect.x + offsetParent.clientLeft;\n      offsets.y = offsetRect.y + offsetParent.clientTop;\n    } else if (documentElement) {\n      setLeftRTLScrollbarOffset();\n    }\n  }\n  if (isFixed && !isOffsetParentAnElement && documentElement) {\n    setLeftRTLScrollbarOffset();\n  }\n  const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);\n  const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;\n  const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;\n  return {\n    x,\n    y,\n    width: rect.width,\n    height: rect.height\n  };\n}\n\nfunction isStaticPositioned(element) {\n  return getComputedStyle$1(element).position === 'static';\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  let rawOffsetParent = element.offsetParent;\n\n  // Firefox returns the <html> element as the offsetParent if it's non-static,\n  // while Chrome and Safari return the <body> element. The <body> element must\n  // be used to perform the correct calculations even if the <html> element is\n  // non-static.\n  if (getDocumentElement(element) === rawOffsetParent) {\n    rawOffsetParent = rawOffsetParent.ownerDocument.body;\n  }\n  return rawOffsetParent;\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 win = getWindow(element);\n  if (isTopLayer(element)) {\n    return win;\n  }\n  if (!isHTMLElement(element)) {\n    let svgOffsetParent = getParentNode(element);\n    while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {\n      if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {\n        return svgOffsetParent;\n      }\n      svgOffsetParent = getParentNode(svgOffsetParent);\n    }\n    return win;\n  }\n  let offsetParent = getTrueOffsetParent(element, polyfill);\n  while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {\n    offsetParent = getTrueOffsetParent(offsetParent, polyfill);\n  }\n  if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {\n    return win;\n  }\n  return offsetParent || getContainingBlock(element) || win;\n}\n\nconst getElementRects = async function (data) {\n  const getOffsetParentFn = this.getOffsetParent || getOffsetParent;\n  const getDimensionsFn = this.getDimensions;\n  const floatingDimensions = await getDimensionsFn(data.floating);\n  return {\n    reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),\n    floating: {\n      x: 0,\n      y: 0,\n      width: floatingDimensions.width,\n      height: floatingDimensions.height\n    }\n  };\n};\n\nfunction isRTL(element) {\n  return getComputedStyle$1(element).direction === 'rtl';\n}\n\nconst platform = {\n  convertOffsetParentRelativeRectToViewportRelativeRect,\n  getDocumentElement,\n  getClippingRect,\n  getOffsetParent,\n  getElementRects,\n  getClientRects,\n  getDimensions,\n  getScale,\n  isElement,\n  isRTL\n};\n\nfunction rectsAreEqual(a, b) {\n  return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;\n}\n\n// https://samthor.au/2021/observing-dom/\nfunction observeMove(element, onMove) {\n  let io = null;\n  let timeoutId;\n  const root = getDocumentElement(element);\n  function cleanup() {\n    var _io;\n    clearTimeout(timeoutId);\n    (_io = io) == null || _io.disconnect();\n    io = null;\n  }\n  function refresh(skip, threshold) {\n    if (skip === void 0) {\n      skip = false;\n    }\n    if (threshold === void 0) {\n      threshold = 1;\n    }\n    cleanup();\n    const elementRectForRootMargin = element.getBoundingClientRect();\n    const {\n      left,\n      top,\n      width,\n      height\n    } = elementRectForRootMargin;\n    if (!skip) {\n      onMove();\n    }\n    if (!width || !height) {\n      return;\n    }\n    const insetTop = floor(top);\n    const insetRight = floor(root.clientWidth - (left + width));\n    const insetBottom = floor(root.clientHeight - (top + height));\n    const insetLeft = floor(left);\n    const rootMargin = -insetTop + \"px \" + -insetRight + \"px \" + -insetBottom + \"px \" + -insetLeft + \"px\";\n    const options = {\n      rootMargin,\n      threshold: max(0, min(1, threshold)) || 1\n    };\n    let isFirstUpdate = true;\n    function handleObserve(entries) {\n      const ratio = entries[0].intersectionRatio;\n      if (ratio !== threshold) {\n        if (!isFirstUpdate) {\n          return refresh();\n        }\n        if (!ratio) {\n          // If the reference is clipped, the ratio is 0. Throttle the refresh\n          // to prevent an infinite loop of updates.\n          timeoutId = setTimeout(() => {\n            refresh(false, 1e-7);\n          }, 1000);\n        } else {\n          refresh(false, ratio);\n        }\n      }\n      if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {\n        // It's possible that even though the ratio is reported as 1, the\n        // element is not actually fully within the IntersectionObserver's root\n        // area anymore. This can happen under performance constraints. This may\n        // be a bug in the browser's IntersectionObserver implementation. To\n        // work around this, we compare the element's bounding rect now with\n        // what it was at the time we created the IntersectionObserver. If they\n        // are not equal then the element moved, so we refresh.\n        refresh();\n      }\n      isFirstUpdate = false;\n    }\n\n    // Older browsers don't support a `document` as the root and will throw an\n    // error.\n    try {\n      io = new IntersectionObserver(handleObserve, {\n        ...options,\n        // Handle <iframe>s\n        root: root.ownerDocument\n      });\n    } catch (_e) {\n      io = new IntersectionObserver(handleObserve, options);\n    }\n    io.observe(element);\n  }\n  refresh(true);\n  return cleanup;\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 = true,\n    ancestorResize = true,\n    elementResize = typeof ResizeObserver === 'function',\n    layoutShift = typeof IntersectionObserver === 'function',\n    animationFrame = false\n  } = options;\n  const referenceEl = unwrapElement(reference);\n  const ancestors = ancestorScroll || ancestorResize ? [...(referenceEl ? getOverflowAncestors(referenceEl) : []), ...getOverflowAncestors(floating)] : [];\n  ancestors.forEach(ancestor => {\n    ancestorScroll && ancestor.addEventListener('scroll', update, {\n      passive: true\n    });\n    ancestorResize && ancestor.addEventListener('resize', update);\n  });\n  const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update) : null;\n  let reobserveFrame = -1;\n  let resizeObserver = null;\n  if (elementResize) {\n    resizeObserver = new ResizeObserver(_ref => {\n      let [firstEntry] = _ref;\n      if (firstEntry && firstEntry.target === referenceEl && resizeObserver) {\n        // Prevent update loops when using the `size` middleware.\n        // https://github.com/floating-ui/floating-ui/issues/1740\n        resizeObserver.unobserve(floating);\n        cancelAnimationFrame(reobserveFrame);\n        reobserveFrame = requestAnimationFrame(() => {\n          var _resizeObserver;\n          (_resizeObserver = resizeObserver) == null || _resizeObserver.observe(floating);\n        });\n      }\n      update();\n    });\n    if (referenceEl && !animationFrame) {\n      resizeObserver.observe(referenceEl);\n    }\n    resizeObserver.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 && !rectsAreEqual(prevRefRect, nextRefRect)) {\n      update();\n    }\n    prevRefRect = nextRefRect;\n    frameId = requestAnimationFrame(frameLoop);\n  }\n  update();\n  return () => {\n    var _resizeObserver2;\n    ancestors.forEach(ancestor => {\n      ancestorScroll && ancestor.removeEventListener('scroll', update);\n      ancestorResize && ancestor.removeEventListener('resize', update);\n    });\n    cleanupIo == null || cleanupIo();\n    (_resizeObserver2 = resizeObserver) == null || _resizeObserver2.disconnect();\n    resizeObserver = null;\n    if (animationFrame) {\n      cancelAnimationFrame(frameId);\n    }\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 */\nconst detectOverflow = detectOverflow$1;\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 = offset$1;\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 = autoPlacement$1;\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 = shift$1;\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 = flip$1;\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = size$1;\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 = hide$1;\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 = arrow$1;\n\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = inline$1;\n\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = limitShift$1;\n\n/**\n * Computes the `x` and `y` coordinates that will place the floating element\n * next to a given reference element.\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\nexport { arrow, autoPlacement, autoUpdate, computePosition, detectOverflow, flip, hide, inline, limitShift, offset, platform, shift, size };\n","import { computePosition, arrow as arrow$2, autoPlacement as autoPlacement$1, flip as flip$1, hide as hide$1, inline as inline$1, limitShift as limitShift$1, offset as offset$1, shift as shift$1, size as size$1 } from '@floating-ui/dom';\nexport { autoUpdate, computePosition, detectOverflow, getOverflowAncestors, platform } from '@floating-ui/dom';\nimport * as React from 'react';\nimport { useLayoutEffect } from 'react';\nimport * as ReactDOM from 'react-dom';\n\nvar isClient = typeof document !== 'undefined';\n\nvar noop = function noop() {};\nvar index = isClient ? useLayoutEffect : noop;\n\n// Fork of `fast-deep-equal` that only does the comparisons we need and compares\n// functions\nfunction deepEqual(a, b) {\n  if (a === b) {\n    return true;\n  }\n  if (typeof a !== typeof b) {\n    return false;\n  }\n  if (typeof a === 'function' && a.toString() === b.toString()) {\n    return true;\n  }\n  let length;\n  let i;\n  let keys;\n  if (a && b && typeof a === 'object') {\n    if (Array.isArray(a)) {\n      length = a.length;\n      if (length !== b.length) return false;\n      for (i = length; i-- !== 0;) {\n        if (!deepEqual(a[i], b[i])) {\n          return false;\n        }\n      }\n      return true;\n    }\n    keys = Object.keys(a);\n    length = keys.length;\n    if (length !== Object.keys(b).length) {\n      return false;\n    }\n    for (i = length; i-- !== 0;) {\n      if (!{}.hasOwnProperty.call(b, keys[i])) {\n        return false;\n      }\n    }\n    for (i = length; i-- !== 0;) {\n      const key = keys[i];\n      if (key === '_owner' && a.$$typeof) {\n        continue;\n      }\n      if (!deepEqual(a[key], b[key])) {\n        return false;\n      }\n    }\n    return true;\n  }\n  return a !== a && b !== b;\n}\n\nfunction getDPR(element) {\n  if (typeof window === 'undefined') {\n    return 1;\n  }\n  const win = element.ownerDocument.defaultView || window;\n  return win.devicePixelRatio || 1;\n}\n\nfunction roundByDPR(element, value) {\n  const dpr = getDPR(element);\n  return Math.round(value * dpr) / dpr;\n}\n\nfunction useLatestRef(value) {\n  const ref = React.useRef(value);\n  index(() => {\n    ref.current = value;\n  });\n  return ref;\n}\n\n/**\n * Provides data to position a floating element.\n * @see https://floating-ui.com/docs/useFloating\n */\nfunction useFloating(options) {\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    placement = 'bottom',\n    strategy = 'absolute',\n    middleware = [],\n    platform,\n    elements: {\n      reference: externalReference,\n      floating: externalFloating\n    } = {},\n    transform = true,\n    whileElementsMounted,\n    open\n  } = options;\n  const [data, setData] = React.useState({\n    x: 0,\n    y: 0,\n    strategy,\n    placement,\n    middlewareData: {},\n    isPositioned: false\n  });\n  const [latestMiddleware, setLatestMiddleware] = React.useState(middleware);\n  if (!deepEqual(latestMiddleware, middleware)) {\n    setLatestMiddleware(middleware);\n  }\n  const [_reference, _setReference] = React.useState(null);\n  const [_floating, _setFloating] = React.useState(null);\n  const setReference = React.useCallback(node => {\n    if (node !== referenceRef.current) {\n      referenceRef.current = node;\n      _setReference(node);\n    }\n  }, []);\n  const setFloating = React.useCallback(node => {\n    if (node !== floatingRef.current) {\n      floatingRef.current = node;\n      _setFloating(node);\n    }\n  }, []);\n  const referenceEl = externalReference || _reference;\n  const floatingEl = externalFloating || _floating;\n  const referenceRef = React.useRef(null);\n  const floatingRef = React.useRef(null);\n  const dataRef = React.useRef(data);\n  const hasWhileElementsMounted = whileElementsMounted != null;\n  const whileElementsMountedRef = useLatestRef(whileElementsMounted);\n  const platformRef = useLatestRef(platform);\n  const openRef = useLatestRef(open);\n  const update = React.useCallback(() => {\n    if (!referenceRef.current || !floatingRef.current) {\n      return;\n    }\n    const config = {\n      placement,\n      strategy,\n      middleware: latestMiddleware\n    };\n    if (platformRef.current) {\n      config.platform = platformRef.current;\n    }\n    computePosition(referenceRef.current, floatingRef.current, config).then(data => {\n      const fullData = {\n        ...data,\n        // The floating element's position may be recomputed while it's closed\n        // but still mounted (such as when transitioning out). To ensure\n        // `isPositioned` will be `false` initially on the next open, avoid\n        // setting it to `true` when `open === false` (must be specified).\n        isPositioned: openRef.current !== false\n      };\n      if (isMountedRef.current && !deepEqual(dataRef.current, fullData)) {\n        dataRef.current = fullData;\n        ReactDOM.flushSync(() => {\n          setData(fullData);\n        });\n      }\n    });\n  }, [latestMiddleware, placement, strategy, platformRef, openRef]);\n  index(() => {\n    if (open === false && dataRef.current.isPositioned) {\n      dataRef.current.isPositioned = false;\n      setData(data => ({\n        ...data,\n        isPositioned: false\n      }));\n    }\n  }, [open]);\n  const isMountedRef = React.useRef(false);\n  index(() => {\n    isMountedRef.current = true;\n    return () => {\n      isMountedRef.current = false;\n    };\n  }, []);\n  index(() => {\n    if (referenceEl) referenceRef.current = referenceEl;\n    if (floatingEl) floatingRef.current = floatingEl;\n    if (referenceEl && floatingEl) {\n      if (whileElementsMountedRef.current) {\n        return whileElementsMountedRef.current(referenceEl, floatingEl, update);\n      }\n      update();\n    }\n  }, [referenceEl, floatingEl, update, whileElementsMountedRef, hasWhileElementsMounted]);\n  const refs = React.useMemo(() => ({\n    reference: referenceRef,\n    floating: floatingRef,\n    setReference,\n    setFloating\n  }), [setReference, setFloating]);\n  const elements = React.useMemo(() => ({\n    reference: referenceEl,\n    floating: floatingEl\n  }), [referenceEl, floatingEl]);\n  const floatingStyles = React.useMemo(() => {\n    const initialStyles = {\n      position: strategy,\n      left: 0,\n      top: 0\n    };\n    if (!elements.floating) {\n      return initialStyles;\n    }\n    const x = roundByDPR(elements.floating, data.x);\n    const y = roundByDPR(elements.floating, data.y);\n    if (transform) {\n      return {\n        ...initialStyles,\n        transform: \"translate(\" + x + \"px, \" + y + \"px)\",\n        ...(getDPR(elements.floating) >= 1.5 && {\n          willChange: 'transform'\n        })\n      };\n    }\n    return {\n      position: strategy,\n      left: x,\n      top: y\n    };\n  }, [strategy, transform, elements.floating, data.x, data.y]);\n  return React.useMemo(() => ({\n    ...data,\n    update,\n    refs,\n    elements,\n    floatingStyles\n  }), [data, update, refs, elements, floatingStyles]);\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 * This wraps the core `arrow` middleware to allow React refs as the element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow$1 = options => {\n  function isRef(value) {\n    return {}.hasOwnProperty.call(value, 'current');\n  }\n  return {\n    name: 'arrow',\n    options,\n    fn(state) {\n      const {\n        element,\n        padding\n      } = typeof options === 'function' ? options(state) : options;\n      if (element && isRef(element)) {\n        if (element.current != null) {\n          return arrow$2({\n            element: element.current,\n            padding\n          }).fn(state);\n        }\n        return {};\n      }\n      if (element) {\n        return arrow$2({\n          element,\n          padding\n        }).fn(state);\n      }\n      return {};\n    }\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 = (options, deps) => ({\n  ...offset$1(options),\n  options: [options, deps]\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 = (options, deps) => ({\n  ...shift$1(options),\n  options: [options, deps]\n});\n\n/**\n * Built-in `limiter` that will stop `shift()` at a certain point.\n */\nconst limitShift = (options, deps) => ({\n  ...limitShift$1(options),\n  options: [options, deps]\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 = (options, deps) => ({\n  ...flip$1(options),\n  options: [options, deps]\n});\n\n/**\n * Provides data that allows you to change the size of the floating element —\n * for instance, prevent it from overflowing the clipping boundary or match the\n * width of the reference element.\n * @see https://floating-ui.com/docs/size\n */\nconst size = (options, deps) => ({\n  ...size$1(options),\n  options: [options, deps]\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 = (options, deps) => ({\n  ...autoPlacement$1(options),\n  options: [options, deps]\n});\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 = (options, deps) => ({\n  ...hide$1(options),\n  options: [options, deps]\n});\n\n/**\n * Provides improved positioning for inline reference elements that can span\n * over multiple lines, such as hyperlinks or range selections.\n * @see https://floating-ui.com/docs/inline\n */\nconst inline = (options, deps) => ({\n  ...inline$1(options),\n  options: [options, deps]\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 * This wraps the core `arrow` middleware to allow React refs as the element.\n * @see https://floating-ui.com/docs/arrow\n */\nconst arrow = (options, deps) => ({\n  ...arrow$1(options),\n  options: [options, deps]\n});\n\nexport { arrow, autoPlacement, flip, hide, inline, limitShift, offset, shift, size, useFloating };\n","import * as React from 'react';\nimport { useLayoutEffect, useEffect, useRef } from 'react';\nimport { stopEvent, getDocument, isMouseLikePointerType, contains, activeElement, isSafari, isTypeableCombobox, isVirtualClick, isVirtualPointerEvent, getTarget, getPlatform, isTypeableElement, isReactEvent, isRootElement, isEventTargetWithin, isMac, getUserAgent } from '@floating-ui/react/utils';\nimport { floor, evaluate, max, min, round } from '@floating-ui/utils';\nimport { getComputedStyle, isElement, getNodeName, isHTMLElement, getWindow, isLastTraversableNode, getParentNode, isWebKit } from '@floating-ui/utils/dom';\nimport { tabbable, isTabbable } from 'tabbable';\nimport * as ReactDOM from 'react-dom';\nimport { getOverflowAncestors, useFloating as useFloating$1, offset, detectOverflow } from '@floating-ui/react-dom';\nexport { arrow, autoPlacement, autoUpdate, computePosition, detectOverflow, flip, getOverflowAncestors, hide, inline, limitShift, offset, platform, shift, size } from '@floating-ui/react-dom';\n\n/**\n * Merges an array of refs into a single memoized callback ref or `null`.\n * @see https://floating-ui.com/docs/react-utils#usemergerefs\n */\nfunction useMergeRefs(refs) {\n  return React.useMemo(() => {\n    if (refs.every(ref => ref == null)) {\n      return null;\n    }\n    return value => {\n      refs.forEach(ref => {\n        if (typeof ref === 'function') {\n          ref(value);\n        } else if (ref != null) {\n          ref.current = value;\n        }\n      });\n    };\n    // eslint-disable-next-line react-hooks/exhaustive-deps\n  }, refs);\n}\n\n// https://github.com/mui/material-ui/issues/41190#issuecomment-2040873379\nconst SafeReact = {\n  ...React\n};\n\nconst useInsertionEffect = SafeReact.useInsertionEffect;\nconst useSafeInsertionEffect = useInsertionEffect || (fn => fn());\nfunction useEffectEvent(callback) {\n  const ref = React.useRef(() => {\n    if (process.env.NODE_ENV !== \"production\") {\n      throw new Error('Cannot call an event handler while rendering.');\n    }\n  });\n  useSafeInsertionEffect(() => {\n    ref.current = callback;\n  });\n  return React.useCallback(function () {\n    for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n      args[_key] = arguments[_key];\n    }\n    return ref.current == null ? void 0 : ref.current(...args);\n  }, []);\n}\n\nconst ARROW_UP = 'ArrowUp';\nconst ARROW_DOWN = 'ArrowDown';\nconst ARROW_LEFT = 'ArrowLeft';\nconst ARROW_RIGHT = 'ArrowRight';\nfunction isDifferentRow(index, cols, prevRow) {\n  return Math.floor(index / cols) !== prevRow;\n}\nfunction isIndexOutOfBounds(listRef, index) {\n  return index < 0 || index >= listRef.current.length;\n}\nfunction getMinIndex(listRef, disabledIndices) {\n  return findNonDisabledIndex(listRef, {\n    disabledIndices\n  });\n}\nfunction getMaxIndex(listRef, disabledIndices) {\n  return findNonDisabledIndex(listRef, {\n    decrement: true,\n    startingIndex: listRef.current.length,\n    disabledIndices\n  });\n}\nfunction findNonDisabledIndex(listRef, _temp) {\n  let {\n    startingIndex = -1,\n    decrement = false,\n    disabledIndices,\n    amount = 1\n  } = _temp === void 0 ? {} : _temp;\n  const list = listRef.current;\n  let index = startingIndex;\n  do {\n    index += decrement ? -amount : amount;\n  } while (index >= 0 && index <= list.length - 1 && isDisabled(list, index, disabledIndices));\n  return index;\n}\nfunction getGridNavigatedIndex(elementsRef, _ref) {\n  let {\n    event,\n    orientation,\n    loop,\n    rtl,\n    cols,\n    disabledIndices,\n    minIndex,\n    maxIndex,\n    prevIndex,\n    stopEvent: stop = false\n  } = _ref;\n  let nextIndex = prevIndex;\n  if (event.key === ARROW_UP) {\n    stop && stopEvent(event);\n    if (prevIndex === -1) {\n      nextIndex = maxIndex;\n    } else {\n      nextIndex = findNonDisabledIndex(elementsRef, {\n        startingIndex: nextIndex,\n        amount: cols,\n        decrement: true,\n        disabledIndices\n      });\n      if (loop && (prevIndex - cols < minIndex || nextIndex < 0)) {\n        const col = prevIndex % cols;\n        const maxCol = maxIndex % cols;\n        const offset = maxIndex - (maxCol - col);\n        if (maxCol === col) {\n          nextIndex = maxIndex;\n        } else {\n          nextIndex = maxCol > col ? offset : offset - cols;\n        }\n      }\n    }\n    if (isIndexOutOfBounds(elementsRef, nextIndex)) {\n      nextIndex = prevIndex;\n    }\n  }\n  if (event.key === ARROW_DOWN) {\n    stop && stopEvent(event);\n    if (prevIndex === -1) {\n      nextIndex = minIndex;\n    } else {\n      nextIndex = findNonDisabledIndex(elementsRef, {\n        startingIndex: prevIndex,\n        amount: cols,\n        disabledIndices\n      });\n      if (loop && prevIndex + cols > maxIndex) {\n        nextIndex = findNonDisabledIndex(elementsRef, {\n          startingIndex: prevIndex % cols - cols,\n          amount: cols,\n          disabledIndices\n        });\n      }\n    }\n    if (isIndexOutOfBounds(elementsRef, nextIndex)) {\n      nextIndex = prevIndex;\n    }\n  }\n\n  // Remains on the same row/column.\n  if (orientation === 'both') {\n    const prevRow = floor(prevIndex / cols);\n    if (event.key === (rtl ? ARROW_LEFT : ARROW_RIGHT)) {\n      stop && stopEvent(event);\n      if (prevIndex % cols !== cols - 1) {\n        nextIndex = findNonDisabledIndex(elementsRef, {\n          startingIndex: prevIndex,\n          disabledIndices\n        });\n        if (loop && isDifferentRow(nextIndex, cols, prevRow)) {\n          nextIndex = findNonDisabledIndex(elementsRef, {\n            startingIndex: prevIndex - prevIndex % cols - 1,\n            disabledIndices\n          });\n        }\n      } else if (loop) {\n        nextIndex = findNonDisabledIndex(elementsRef, {\n          startingIndex: prevIndex - prevIndex % cols - 1,\n          disabledIndices\n        });\n      }\n      if (isDifferentRow(nextIndex, cols, prevRow)) {\n        nextIndex = prevIndex;\n      }\n    }\n    if (event.key === (rtl ? ARROW_RIGHT : ARROW_LEFT)) {\n      stop && stopEvent(event);\n      if (prevIndex % cols !== 0) {\n        nextIndex = findNonDisabledIndex(elementsRef, {\n          startingIndex: prevIndex,\n          decrement: true,\n          disabledIndices\n        });\n        if (loop && isDifferentRow(nextIndex, cols, prevRow)) {\n          nextIndex = findNonDisabledIndex(elementsRef, {\n            startingIndex: prevIndex + (cols - prevIndex % cols),\n            decrement: true,\n            disabledIndices\n          });\n        }\n      } else if (loop) {\n        nextIndex = findNonDisabledIndex(elementsRef, {\n          startingIndex: prevIndex + (cols - prevIndex % cols),\n          decrement: true,\n          disabledIndices\n        });\n      }\n      if (isDifferentRow(nextIndex, cols, prevRow)) {\n        nextIndex = prevIndex;\n      }\n    }\n    const lastRow = floor(maxIndex / cols) === prevRow;\n    if (isIndexOutOfBounds(elementsRef, nextIndex)) {\n      if (loop && lastRow) {\n        nextIndex = event.key === (rtl ? ARROW_RIGHT : ARROW_LEFT) ? maxIndex : findNonDisabledIndex(elementsRef, {\n          startingIndex: prevIndex - prevIndex % cols - 1,\n          disabledIndices\n        });\n      } else {\n        nextIndex = prevIndex;\n      }\n    }\n  }\n  return nextIndex;\n}\n\n/** For each cell index, gets the item index that occupies that cell */\nfunction buildCellMap(sizes, cols, dense) {\n  const cellMap = [];\n  let startIndex = 0;\n  sizes.forEach((_ref2, index) => {\n    let {\n      width,\n      height\n    } = _ref2;\n    if (width > cols) {\n      if (process.env.NODE_ENV !== \"production\") {\n        throw new Error(\"[Floating UI]: Invalid grid - item width at index \" + index + \" is greater than grid columns\");\n      }\n    }\n    let itemPlaced = false;\n    if (dense) {\n      startIndex = 0;\n    }\n    while (!itemPlaced) {\n      const targetCells = [];\n      for (let i = 0; i < width; i++) {\n        for (let j = 0; j < height; j++) {\n          targetCells.push(startIndex + i + j * cols);\n        }\n      }\n      if (startIndex % cols + width <= cols && targetCells.every(cell => cellMap[cell] == null)) {\n        targetCells.forEach(cell => {\n          cellMap[cell] = index;\n        });\n        itemPlaced = true;\n      } else {\n        startIndex++;\n      }\n    }\n  });\n\n  // convert into a non-sparse array\n  return [...cellMap];\n}\n\n/** Gets cell index of an item's corner or -1 when index is -1. */\nfunction getCellIndexOfCorner(index, sizes, cellMap, cols, corner) {\n  if (index === -1) return -1;\n  const firstCellIndex = cellMap.indexOf(index);\n  const sizeItem = sizes[index];\n  switch (corner) {\n    case 'tl':\n      return firstCellIndex;\n    case 'tr':\n      if (!sizeItem) {\n        return firstCellIndex;\n      }\n      return firstCellIndex + sizeItem.width - 1;\n    case 'bl':\n      if (!sizeItem) {\n        return firstCellIndex;\n      }\n      return firstCellIndex + (sizeItem.height - 1) * cols;\n    case 'br':\n      return cellMap.lastIndexOf(index);\n  }\n}\n\n/** Gets all cell indices that correspond to the specified indices */\nfunction getCellIndices(indices, cellMap) {\n  return cellMap.flatMap((index, cellIndex) => indices.includes(index) ? [cellIndex] : []);\n}\nfunction isDisabled(list, index, disabledIndices) {\n  if (disabledIndices) {\n    return disabledIndices.includes(index);\n  }\n  const element = list[index];\n  return element == null || element.hasAttribute('disabled') || element.getAttribute('aria-disabled') === 'true';\n}\n\nvar index = typeof document !== 'undefined' ? useLayoutEffect : useEffect;\n\nfunction sortByDocumentPosition(a, b) {\n  const position = a.compareDocumentPosition(b);\n  if (position & Node.DOCUMENT_POSITION_FOLLOWING || position & Node.DOCUMENT_POSITION_CONTAINED_BY) {\n    return -1;\n  }\n  if (position & Node.DOCUMENT_POSITION_PRECEDING || position & Node.DOCUMENT_POSITION_CONTAINS) {\n    return 1;\n  }\n  return 0;\n}\nfunction areMapsEqual(map1, map2) {\n  if (map1.size !== map2.size) {\n    return false;\n  }\n  for (const [key, value] of map1.entries()) {\n    if (value !== map2.get(key)) {\n      return false;\n    }\n  }\n  return true;\n}\nconst FloatingListContext = /*#__PURE__*/React.createContext({\n  register: () => {},\n  unregister: () => {},\n  map: /*#__PURE__*/new Map(),\n  elementsRef: {\n    current: []\n  }\n});\n/**\n * Provides context for a list of items within the floating element.\n * @see https://floating-ui.com/docs/FloatingList\n */\nfunction FloatingList(props) {\n  const {\n    children,\n    elementsRef,\n    labelsRef\n  } = props;\n  const [map, setMap] = React.useState(() => new Map());\n  const register = React.useCallback(node => {\n    setMap(prevMap => new Map(prevMap).set(node, null));\n  }, []);\n  const unregister = React.useCallback(node => {\n    setMap(prevMap => {\n      const map = new Map(prevMap);\n      map.delete(node);\n      return map;\n    });\n  }, []);\n  index(() => {\n    const newMap = new Map(map);\n    const nodes = Array.from(newMap.keys()).sort(sortByDocumentPosition);\n    nodes.forEach((node, index) => {\n      newMap.set(node, index);\n    });\n    if (!areMapsEqual(map, newMap)) {\n      setMap(newMap);\n    }\n  }, [map]);\n  return /*#__PURE__*/React.createElement(FloatingListContext.Provider, {\n    value: React.useMemo(() => ({\n      register,\n      unregister,\n      map,\n      elementsRef,\n      labelsRef\n    }), [register, unregister, map, elementsRef, labelsRef])\n  }, children);\n}\n/**\n * Used to register a list item and its index (DOM position) in the\n * `FloatingList`.\n * @see https://floating-ui.com/docs/FloatingList#uselistitem\n */\nfunction useListItem(props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    label\n  } = props;\n  const {\n    register,\n    unregister,\n    map,\n    elementsRef,\n    labelsRef\n  } = React.useContext(FloatingListContext);\n  const [index$1, setIndex] = React.useState(null);\n  const componentRef = React.useRef(null);\n  const ref = React.useCallback(node => {\n    componentRef.current = node;\n    if (index$1 !== null) {\n      elementsRef.current[index$1] = node;\n      if (labelsRef) {\n        var _node$textContent;\n        const isLabelDefined = label !== undefined;\n        labelsRef.current[index$1] = isLabelDefined ? label : (_node$textContent = node == null ? void 0 : node.textContent) != null ? _node$textContent : null;\n      }\n    }\n  }, [index$1, elementsRef, labelsRef, label]);\n  index(() => {\n    const node = componentRef.current;\n    if (node) {\n      register(node);\n      return () => {\n        unregister(node);\n      };\n    }\n  }, [register, unregister]);\n  index(() => {\n    const index = componentRef.current ? map.get(componentRef.current) : null;\n    if (index != null) {\n      setIndex(index);\n    }\n  }, [map]);\n  return React.useMemo(() => ({\n    ref,\n    index: index$1 == null ? -1 : index$1\n  }), [index$1, ref]);\n}\n\nfunction renderJsx(render, computedProps) {\n  if (typeof render === 'function') {\n    return render(computedProps);\n  }\n  if (render) {\n    return /*#__PURE__*/React.cloneElement(render, computedProps);\n  }\n  return /*#__PURE__*/React.createElement(\"div\", computedProps);\n}\nconst CompositeContext = /*#__PURE__*/React.createContext({\n  activeIndex: 0,\n  onNavigate: () => {}\n});\nconst horizontalKeys = [ARROW_LEFT, ARROW_RIGHT];\nconst verticalKeys = [ARROW_UP, ARROW_DOWN];\nconst allKeys = [...horizontalKeys, ...verticalKeys];\n\n/**\n * Creates a single tab stop whose items are navigated by arrow keys, which\n * provides list navigation outside of floating element contexts.\n *\n * This is useful to enable navigation of a list of items that aren’t part of a\n * floating element. A menubar is an example of a composite, with each reference\n * element being an item.\n * @see https://floating-ui.com/docs/Composite\n */\nconst Composite = /*#__PURE__*/React.forwardRef(function Composite(props, forwardedRef) {\n  const {\n    render,\n    orientation = 'both',\n    loop = true,\n    rtl = false,\n    cols = 1,\n    disabledIndices,\n    activeIndex: externalActiveIndex,\n    onNavigate: externalSetActiveIndex,\n    itemSizes,\n    dense = false,\n    ...domProps\n  } = props;\n  const [internalActiveIndex, internalSetActiveIndex] = React.useState(0);\n  const activeIndex = externalActiveIndex != null ? externalActiveIndex : internalActiveIndex;\n  const onNavigate = useEffectEvent(externalSetActiveIndex != null ? externalSetActiveIndex : internalSetActiveIndex);\n  const elementsRef = React.useRef([]);\n  const renderElementProps = render && typeof render !== 'function' ? render.props : {};\n  const contextValue = React.useMemo(() => ({\n    activeIndex,\n    onNavigate\n  }), [activeIndex, onNavigate]);\n  const isGrid = cols > 1;\n  function handleKeyDown(event) {\n    if (!allKeys.includes(event.key)) return;\n    let nextIndex = activeIndex;\n    const minIndex = getMinIndex(elementsRef, disabledIndices);\n    const maxIndex = getMaxIndex(elementsRef, disabledIndices);\n    const horizontalEndKey = rtl ? ARROW_LEFT : ARROW_RIGHT;\n    const horizontalStartKey = rtl ? ARROW_RIGHT : ARROW_LEFT;\n    if (isGrid) {\n      const sizes = itemSizes || Array.from({\n        length: elementsRef.current.length\n      }, () => ({\n        width: 1,\n        height: 1\n      }));\n      // To calculate movements on the grid, we use hypothetical cell indices\n      // as if every item was 1x1, then convert back to real indices.\n      const cellMap = buildCellMap(sizes, cols, dense);\n      const minGridIndex = cellMap.findIndex(index => index != null && !isDisabled(elementsRef.current, index, disabledIndices));\n      // last enabled index\n      const maxGridIndex = cellMap.reduce((foundIndex, index, cellIndex) => index != null && !isDisabled(elementsRef.current, index, disabledIndices) ? cellIndex : foundIndex, -1);\n      const maybeNextIndex = cellMap[getGridNavigatedIndex({\n        current: cellMap.map(itemIndex => itemIndex ? elementsRef.current[itemIndex] : null)\n      }, {\n        event,\n        orientation,\n        loop,\n        rtl,\n        cols,\n        // treat undefined (empty grid spaces) as disabled indices so we\n        // don't end up in them\n        disabledIndices: getCellIndices([...(disabledIndices || elementsRef.current.map((_, index) => isDisabled(elementsRef.current, index) ? index : undefined)), undefined], cellMap),\n        minIndex: minGridIndex,\n        maxIndex: maxGridIndex,\n        prevIndex: getCellIndexOfCorner(activeIndex > maxIndex ? minIndex : activeIndex, sizes, cellMap, cols,\n        // use a corner matching the edge closest to the direction we're\n        // moving in so we don't end up in the same item. Prefer\n        // top/left over bottom/right.\n        event.key === ARROW_DOWN ? 'bl' : event.key === horizontalEndKey ? 'tr' : 'tl')\n      })];\n      if (maybeNextIndex != null) {\n        nextIndex = maybeNextIndex;\n      }\n    }\n    const toEndKeys = {\n      horizontal: [horizontalEndKey],\n      vertical: [ARROW_DOWN],\n      both: [horizontalEndKey, ARROW_DOWN]\n    }[orientation];\n    const toStartKeys = {\n      horizontal: [horizontalStartKey],\n      vertical: [ARROW_UP],\n      both: [horizontalStartKey, ARROW_UP]\n    }[orientation];\n    const preventedKeys = isGrid ? allKeys : {\n      horizontal: horizontalKeys,\n      vertical: verticalKeys,\n      both: allKeys\n    }[orientation];\n    if (nextIndex === activeIndex && [...toEndKeys, ...toStartKeys].includes(event.key)) {\n      if (loop && nextIndex === maxIndex && toEndKeys.includes(event.key)) {\n        nextIndex = minIndex;\n      } else if (loop && nextIndex === minIndex && toStartKeys.includes(event.key)) {\n        nextIndex = maxIndex;\n      } else {\n        nextIndex = findNonDisabledIndex(elementsRef, {\n          startingIndex: nextIndex,\n          decrement: toStartKeys.includes(event.key),\n          disabledIndices\n        });\n      }\n    }\n    if (nextIndex !== activeIndex && !isIndexOutOfBounds(elementsRef, nextIndex)) {\n      var _elementsRef$current$;\n      event.stopPropagation();\n      if (preventedKeys.includes(event.key)) {\n        event.preventDefault();\n      }\n      onNavigate(nextIndex);\n      (_elementsRef$current$ = elementsRef.current[nextIndex]) == null || _elementsRef$current$.focus();\n    }\n  }\n  const computedProps = {\n    ...domProps,\n    ...renderElementProps,\n    ref: forwardedRef,\n    'aria-orientation': orientation === 'both' ? undefined : orientation,\n    onKeyDown(e) {\n      domProps.onKeyDown == null || domProps.onKeyDown(e);\n      renderElementProps.onKeyDown == null || renderElementProps.onKeyDown(e);\n      handleKeyDown(e);\n    }\n  };\n  return /*#__PURE__*/React.createElement(CompositeContext.Provider, {\n    value: contextValue\n  }, /*#__PURE__*/React.createElement(FloatingList, {\n    elementsRef: elementsRef\n  }, renderJsx(render, computedProps)));\n});\n/**\n * @see https://floating-ui.com/docs/Composite\n */\nconst CompositeItem = /*#__PURE__*/React.forwardRef(function CompositeItem(props, forwardedRef) {\n  const {\n    render,\n    ...domProps\n  } = props;\n  const renderElementProps = render && typeof render !== 'function' ? render.props : {};\n  const {\n    activeIndex,\n    onNavigate\n  } = React.useContext(CompositeContext);\n  const {\n    ref,\n    index\n  } = useListItem();\n  const mergedRef = useMergeRefs([ref, forwardedRef, renderElementProps.ref]);\n  const isActive = activeIndex === index;\n  const computedProps = {\n    ...domProps,\n    ...renderElementProps,\n    ref: mergedRef,\n    tabIndex: isActive ? 0 : -1,\n    'data-active': isActive ? '' : undefined,\n    onFocus(e) {\n      domProps.onFocus == null || domProps.onFocus(e);\n      renderElementProps.onFocus == null || renderElementProps.onFocus(e);\n      onNavigate(index);\n    }\n  };\n  return renderJsx(render, computedProps);\n});\n\nfunction _extends() {\n  _extends = Object.assign ? Object.assign.bind() : function (target) {\n    for (var i = 1; i < arguments.length; i++) {\n      var source = arguments[i];\n      for (var key in source) {\n        if (Object.prototype.hasOwnProperty.call(source, key)) {\n          target[key] = source[key];\n        }\n      }\n    }\n    return target;\n  };\n  return _extends.apply(this, arguments);\n}\n\nlet serverHandoffComplete = false;\nlet count = 0;\nconst genId = () => // Ensure the id is unique with multiple independent versions of Floating UI\n// on <React 18\n\"floating-ui-\" + Math.random().toString(36).slice(2, 6) + count++;\nfunction useFloatingId() {\n  const [id, setId] = React.useState(() => serverHandoffComplete ? genId() : undefined);\n  index(() => {\n    if (id == null) {\n      setId(genId());\n    }\n    // eslint-disable-next-line react-hooks/exhaustive-deps\n  }, []);\n  React.useEffect(() => {\n    serverHandoffComplete = true;\n  }, []);\n  return id;\n}\nconst useReactId = SafeReact.useId;\n\n/**\n * Uses React 18's built-in `useId()` when available, or falls back to a\n * slightly less performant (requiring a double render) implementation for\n * earlier React versions.\n * @see https://floating-ui.com/docs/react-utils#useid\n */\nconst useId = useReactId || useFloatingId;\n\nlet devMessageSet;\nif (process.env.NODE_ENV !== \"production\") {\n  devMessageSet = /*#__PURE__*/new Set();\n}\nfunction warn() {\n  var _devMessageSet;\n  for (var _len = arguments.length, messages = new Array(_len), _key = 0; _key < _len; _key++) {\n    messages[_key] = arguments[_key];\n  }\n  const message = \"Floating UI: \" + messages.join(' ');\n  if (!((_devMessageSet = devMessageSet) != null && _devMessageSet.has(message))) {\n    var _devMessageSet2;\n    (_devMessageSet2 = devMessageSet) == null || _devMessageSet2.add(message);\n    console.warn(message);\n  }\n}\nfunction error() {\n  var _devMessageSet3;\n  for (var _len2 = arguments.length, messages = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n    messages[_key2] = arguments[_key2];\n  }\n  const message = \"Floating UI: \" + messages.join(' ');\n  if (!((_devMessageSet3 = devMessageSet) != null && _devMessageSet3.has(message))) {\n    var _devMessageSet4;\n    (_devMessageSet4 = devMessageSet) == null || _devMessageSet4.add(message);\n    console.error(message);\n  }\n}\n\n/**\n * Renders a pointing arrow triangle.\n * @see https://floating-ui.com/docs/FloatingArrow\n */\nconst FloatingArrow = /*#__PURE__*/React.forwardRef(function FloatingArrow(props, ref) {\n  const {\n    context: {\n      placement,\n      elements: {\n        floating\n      },\n      middlewareData: {\n        arrow,\n        shift\n      }\n    },\n    width = 14,\n    height = 7,\n    tipRadius = 0,\n    strokeWidth = 0,\n    staticOffset,\n    stroke,\n    d,\n    style: {\n      transform,\n      ...restStyle\n    } = {},\n    ...rest\n  } = props;\n  if (process.env.NODE_ENV !== \"production\") {\n    if (!ref) {\n      warn('The `ref` prop is required for `FloatingArrow`.');\n    }\n  }\n  const clipPathId = useId();\n  const [isRTL, setIsRTL] = React.useState(false);\n\n  // https://github.com/floating-ui/floating-ui/issues/2932\n  index(() => {\n    if (!floating) return;\n    const isRTL = getComputedStyle(floating).direction === 'rtl';\n    if (isRTL) {\n      setIsRTL(true);\n    }\n  }, [floating]);\n  if (!floating) {\n    return null;\n  }\n  const [side, alignment] = placement.split('-');\n  const isVerticalSide = side === 'top' || side === 'bottom';\n  let computedStaticOffset = staticOffset;\n  if (isVerticalSide && shift != null && shift.x || !isVerticalSide && shift != null && shift.y) {\n    computedStaticOffset = null;\n  }\n\n  // Strokes must be double the border width, this ensures the stroke's width\n  // works as you'd expect.\n  const computedStrokeWidth = strokeWidth * 2;\n  const halfStrokeWidth = computedStrokeWidth / 2;\n  const svgX = width / 2 * (tipRadius / -8 + 1);\n  const svgY = height / 2 * tipRadius / 4;\n  const isCustomShape = !!d;\n  const yOffsetProp = computedStaticOffset && alignment === 'end' ? 'bottom' : 'top';\n  let xOffsetProp = computedStaticOffset && alignment === 'end' ? 'right' : 'left';\n  if (computedStaticOffset && isRTL) {\n    xOffsetProp = alignment === 'end' ? 'left' : 'right';\n  }\n  const arrowX = (arrow == null ? void 0 : arrow.x) != null ? computedStaticOffset || arrow.x : '';\n  const arrowY = (arrow == null ? void 0 : arrow.y) != null ? computedStaticOffset || arrow.y : '';\n  const dValue = d || 'M0,0' + (\" H\" + width) + (\" L\" + (width - svgX) + \",\" + (height - svgY)) + (\" Q\" + width / 2 + \",\" + height + \" \" + svgX + \",\" + (height - svgY)) + ' Z';\n  const rotation = {\n    top: isCustomShape ? 'rotate(180deg)' : '',\n    left: isCustomShape ? 'rotate(90deg)' : 'rotate(-90deg)',\n    bottom: isCustomShape ? '' : 'rotate(180deg)',\n    right: isCustomShape ? 'rotate(-90deg)' : 'rotate(90deg)'\n  }[side];\n  return /*#__PURE__*/React.createElement(\"svg\", _extends({}, rest, {\n    \"aria-hidden\": true,\n    ref: ref,\n    width: isCustomShape ? width : width + computedStrokeWidth,\n    height: width,\n    viewBox: \"0 0 \" + width + \" \" + (height > width ? height : width),\n    style: {\n      position: 'absolute',\n      pointerEvents: 'none',\n      [xOffsetProp]: arrowX,\n      [yOffsetProp]: arrowY,\n      [side]: isVerticalSide || isCustomShape ? '100%' : \"calc(100% - \" + computedStrokeWidth / 2 + \"px)\",\n      transform: [rotation, transform].filter(t => !!t).join(' '),\n      ...restStyle\n    }\n  }), computedStrokeWidth > 0 && /*#__PURE__*/React.createElement(\"path\", {\n    clipPath: \"url(#\" + clipPathId + \")\",\n    fill: \"none\",\n    stroke: stroke\n    // Account for the stroke on the fill path rendered below.\n    ,\n    strokeWidth: computedStrokeWidth + (d ? 0 : 1),\n    d: dValue\n  }), /*#__PURE__*/React.createElement(\"path\", {\n    stroke: computedStrokeWidth && !d ? rest.fill : 'none',\n    d: dValue\n  }), /*#__PURE__*/React.createElement(\"clipPath\", {\n    id: clipPathId\n  }, /*#__PURE__*/React.createElement(\"rect\", {\n    x: -halfStrokeWidth,\n    y: halfStrokeWidth * (isCustomShape ? -1 : 1),\n    width: width + computedStrokeWidth,\n    height: width\n  })));\n});\n\nfunction createPubSub() {\n  const map = new Map();\n  return {\n    emit(event, data) {\n      var _map$get;\n      (_map$get = map.get(event)) == null || _map$get.forEach(handler => handler(data));\n    },\n    on(event, listener) {\n      map.set(event, [...(map.get(event) || []), listener]);\n    },\n    off(event, listener) {\n      var _map$get2;\n      map.set(event, ((_map$get2 = map.get(event)) == null ? void 0 : _map$get2.filter(l => l !== listener)) || []);\n    }\n  };\n}\n\nconst FloatingNodeContext = /*#__PURE__*/React.createContext(null);\nconst FloatingTreeContext = /*#__PURE__*/React.createContext(null);\n\n/**\n * Returns the parent node id for nested floating elements, if available.\n * Returns `null` for top-level floating elements.\n */\nconst useFloatingParentNodeId = () => {\n  var _React$useContext;\n  return ((_React$useContext = React.useContext(FloatingNodeContext)) == null ? void 0 : _React$useContext.id) || null;\n};\n\n/**\n * Returns the nearest floating tree context, if available.\n */\nconst useFloatingTree = () => React.useContext(FloatingTreeContext);\n\n/**\n * Registers a node into the `FloatingTree`, returning its id.\n * @see https://floating-ui.com/docs/FloatingTree\n */\nfunction useFloatingNodeId(customParentId) {\n  const id = useId();\n  const tree = useFloatingTree();\n  const reactParentId = useFloatingParentNodeId();\n  const parentId = customParentId || reactParentId;\n  index(() => {\n    const node = {\n      id,\n      parentId\n    };\n    tree == null || tree.addNode(node);\n    return () => {\n      tree == null || tree.removeNode(node);\n    };\n  }, [tree, id, parentId]);\n  return id;\n}\n/**\n * Provides parent node context for nested floating elements.\n * @see https://floating-ui.com/docs/FloatingTree\n */\nfunction FloatingNode(props) {\n  const {\n    children,\n    id\n  } = props;\n  const parentId = useFloatingParentNodeId();\n  return /*#__PURE__*/React.createElement(FloatingNodeContext.Provider, {\n    value: React.useMemo(() => ({\n      id,\n      parentId\n    }), [id, parentId])\n  }, children);\n}\n/**\n * Provides context for nested floating elements when they are not children of\n * each other on the DOM.\n * This is not necessary in all cases, except when there must be explicit communication between parent and child floating elements. It is necessary for:\n * - The `bubbles` option in the `useDismiss()` Hook\n * - Nested virtual list navigation\n * - Nested floating elements that each open on hover\n * - Custom communication between parent and child floating elements\n * @see https://floating-ui.com/docs/FloatingTree\n */\nfunction FloatingTree(props) {\n  const {\n    children\n  } = props;\n  const nodesRef = React.useRef([]);\n  const addNode = React.useCallback(node => {\n    nodesRef.current = [...nodesRef.current, node];\n  }, []);\n  const removeNode = React.useCallback(node => {\n    nodesRef.current = nodesRef.current.filter(n => n !== node);\n  }, []);\n  const events = React.useState(() => createPubSub())[0];\n  return /*#__PURE__*/React.createElement(FloatingTreeContext.Provider, {\n    value: React.useMemo(() => ({\n      nodesRef,\n      addNode,\n      removeNode,\n      events\n    }), [addNode, removeNode, events])\n  }, children);\n}\n\nfunction createAttribute(name) {\n  return \"data-floating-ui-\" + name;\n}\n\nfunction useLatestRef(value) {\n  const ref = useRef(value);\n  index(() => {\n    ref.current = value;\n  });\n  return ref;\n}\n\nconst safePolygonIdentifier = /*#__PURE__*/createAttribute('safe-polygon');\nfunction getDelay(value, prop, pointerType) {\n  if (pointerType && !isMouseLikePointerType(pointerType)) {\n    return 0;\n  }\n  if (typeof value === 'number') {\n    return value;\n  }\n  return value == null ? void 0 : value[prop];\n}\n/**\n * Opens the floating element while hovering over the reference element, like\n * CSS `:hover`.\n * @see https://floating-ui.com/docs/useHover\n */\nfunction useHover(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    onOpenChange,\n    dataRef,\n    events,\n    elements\n  } = context;\n  const {\n    enabled = true,\n    delay = 0,\n    handleClose = null,\n    mouseOnly = false,\n    restMs = 0,\n    move = true\n  } = props;\n  const tree = useFloatingTree();\n  const parentId = useFloatingParentNodeId();\n  const handleCloseRef = useLatestRef(handleClose);\n  const delayRef = useLatestRef(delay);\n  const openRef = useLatestRef(open);\n  const pointerTypeRef = React.useRef();\n  const timeoutRef = React.useRef(-1);\n  const handlerRef = React.useRef();\n  const restTimeoutRef = React.useRef(-1);\n  const blockMouseMoveRef = React.useRef(true);\n  const performedPointerEventsMutationRef = React.useRef(false);\n  const unbindMouseMoveRef = React.useRef(() => {});\n  const restTimeoutPendingRef = React.useRef(false);\n  const isHoverOpen = React.useCallback(() => {\n    var _dataRef$current$open;\n    const type = (_dataRef$current$open = dataRef.current.openEvent) == null ? void 0 : _dataRef$current$open.type;\n    return (type == null ? void 0 : type.includes('mouse')) && type !== 'mousedown';\n  }, [dataRef]);\n\n  // When closing before opening, clear the delay timeouts to cancel it\n  // from showing.\n  React.useEffect(() => {\n    if (!enabled) return;\n    function onOpenChange(_ref) {\n      let {\n        open\n      } = _ref;\n      if (!open) {\n        clearTimeout(timeoutRef.current);\n        clearTimeout(restTimeoutRef.current);\n        blockMouseMoveRef.current = true;\n        restTimeoutPendingRef.current = false;\n      }\n    }\n    events.on('openchange', onOpenChange);\n    return () => {\n      events.off('openchange', onOpenChange);\n    };\n  }, [enabled, events]);\n  React.useEffect(() => {\n    if (!enabled) return;\n    if (!handleCloseRef.current) return;\n    if (!open) return;\n    function onLeave(event) {\n      if (isHoverOpen()) {\n        onOpenChange(false, event, 'hover');\n      }\n    }\n    const html = getDocument(elements.floating).documentElement;\n    html.addEventListener('mouseleave', onLeave);\n    return () => {\n      html.removeEventListener('mouseleave', onLeave);\n    };\n  }, [elements.floating, open, onOpenChange, enabled, handleCloseRef, isHoverOpen]);\n  const closeWithDelay = React.useCallback(function (event, runElseBranch, reason) {\n    if (runElseBranch === void 0) {\n      runElseBranch = true;\n    }\n    if (reason === void 0) {\n      reason = 'hover';\n    }\n    const closeDelay = getDelay(delayRef.current, 'close', pointerTypeRef.current);\n    if (closeDelay && !handlerRef.current) {\n      clearTimeout(timeoutRef.current);\n      timeoutRef.current = window.setTimeout(() => onOpenChange(false, event, reason), closeDelay);\n    } else if (runElseBranch) {\n      clearTimeout(timeoutRef.current);\n      onOpenChange(false, event, reason);\n    }\n  }, [delayRef, onOpenChange]);\n  const cleanupMouseMoveHandler = useEffectEvent(() => {\n    unbindMouseMoveRef.current();\n    handlerRef.current = undefined;\n  });\n  const clearPointerEvents = useEffectEvent(() => {\n    if (performedPointerEventsMutationRef.current) {\n      const body = getDocument(elements.floating).body;\n      body.style.pointerEvents = '';\n      body.removeAttribute(safePolygonIdentifier);\n      performedPointerEventsMutationRef.current = false;\n    }\n  });\n  const isClickLikeOpenEvent = useEffectEvent(() => {\n    return dataRef.current.openEvent ? ['click', 'mousedown'].includes(dataRef.current.openEvent.type) : false;\n  });\n\n  // Registering the mouse events on the reference directly to bypass React's\n  // delegation system. If the cursor was on a disabled element and then entered\n  // the reference (no gap), `mouseenter` doesn't fire in the delegation system.\n  React.useEffect(() => {\n    if (!enabled) return;\n    function onMouseEnter(event) {\n      clearTimeout(timeoutRef.current);\n      blockMouseMoveRef.current = false;\n      if (mouseOnly && !isMouseLikePointerType(pointerTypeRef.current) || restMs > 0 && !getDelay(delayRef.current, 'open')) {\n        return;\n      }\n      const openDelay = getDelay(delayRef.current, 'open', pointerTypeRef.current);\n      if (openDelay) {\n        timeoutRef.current = window.setTimeout(() => {\n          if (!openRef.current) {\n            onOpenChange(true, event, 'hover');\n          }\n        }, openDelay);\n      } else if (!open) {\n        onOpenChange(true, event, 'hover');\n      }\n    }\n    function onMouseLeave(event) {\n      if (isClickLikeOpenEvent()) return;\n      unbindMouseMoveRef.current();\n      const doc = getDocument(elements.floating);\n      clearTimeout(restTimeoutRef.current);\n      restTimeoutPendingRef.current = false;\n      if (handleCloseRef.current && dataRef.current.floatingContext) {\n        // Prevent clearing `onScrollMouseLeave` timeout.\n        if (!open) {\n          clearTimeout(timeoutRef.current);\n        }\n        handlerRef.current = handleCloseRef.current({\n          ...dataRef.current.floatingContext,\n          tree,\n          x: event.clientX,\n          y: event.clientY,\n          onClose() {\n            clearPointerEvents();\n            cleanupMouseMoveHandler();\n            if (!isClickLikeOpenEvent()) {\n              closeWithDelay(event, true, 'safe-polygon');\n            }\n          }\n        });\n        const handler = handlerRef.current;\n        doc.addEventListener('mousemove', handler);\n        unbindMouseMoveRef.current = () => {\n          doc.removeEventListener('mousemove', handler);\n        };\n        return;\n      }\n\n      // Allow interactivity without `safePolygon` on touch devices. With a\n      // pointer, a short close delay is an alternative, so it should work\n      // consistently.\n      const shouldClose = pointerTypeRef.current === 'touch' ? !contains(elements.floating, event.relatedTarget) : true;\n      if (shouldClose) {\n        closeWithDelay(event);\n      }\n    }\n\n    // Ensure the floating element closes after scrolling even if the pointer\n    // did not move.\n    // https://github.com/floating-ui/floating-ui/discussions/1692\n    function onScrollMouseLeave(event) {\n      if (isClickLikeOpenEvent()) return;\n      if (!dataRef.current.floatingContext) return;\n      handleCloseRef.current == null || handleCloseRef.current({\n        ...dataRef.current.floatingContext,\n        tree,\n        x: event.clientX,\n        y: event.clientY,\n        onClose() {\n          clearPointerEvents();\n          cleanupMouseMoveHandler();\n          if (!isClickLikeOpenEvent()) {\n            closeWithDelay(event);\n          }\n        }\n      })(event);\n    }\n    if (isElement(elements.domReference)) {\n      var _elements$floating;\n      const ref = elements.domReference;\n      open && ref.addEventListener('mouseleave', onScrollMouseLeave);\n      (_elements$floating = elements.floating) == null || _elements$floating.addEventListener('mouseleave', onScrollMouseLeave);\n      move && ref.addEventListener('mousemove', onMouseEnter, {\n        once: true\n      });\n      ref.addEventListener('mouseenter', onMouseEnter);\n      ref.addEventListener('mouseleave', onMouseLeave);\n      return () => {\n        var _elements$floating2;\n        open && ref.removeEventListener('mouseleave', onScrollMouseLeave);\n        (_elements$floating2 = elements.floating) == null || _elements$floating2.removeEventListener('mouseleave', onScrollMouseLeave);\n        move && ref.removeEventListener('mousemove', onMouseEnter);\n        ref.removeEventListener('mouseenter', onMouseEnter);\n        ref.removeEventListener('mouseleave', onMouseLeave);\n      };\n    }\n  }, [elements, enabled, context, mouseOnly, restMs, move, closeWithDelay, cleanupMouseMoveHandler, clearPointerEvents, onOpenChange, open, openRef, tree, delayRef, handleCloseRef, dataRef, isClickLikeOpenEvent]);\n\n  // Block pointer-events of every element other than the reference and floating\n  // while the floating element is open and has a `handleClose` handler. Also\n  // handles nested floating elements.\n  // https://github.com/floating-ui/floating-ui/issues/1722\n  index(() => {\n    var _handleCloseRef$curre;\n    if (!enabled) return;\n    if (open && (_handleCloseRef$curre = handleCloseRef.current) != null && _handleCloseRef$curre.__options.blockPointerEvents && isHoverOpen()) {\n      performedPointerEventsMutationRef.current = true;\n      const floatingEl = elements.floating;\n      if (isElement(elements.domReference) && floatingEl) {\n        var _tree$nodesRef$curren;\n        const body = getDocument(elements.floating).body;\n        body.setAttribute(safePolygonIdentifier, '');\n        const ref = elements.domReference;\n        const parentFloating = tree == null || (_tree$nodesRef$curren = tree.nodesRef.current.find(node => node.id === parentId)) == null || (_tree$nodesRef$curren = _tree$nodesRef$curren.context) == null ? void 0 : _tree$nodesRef$curren.elements.floating;\n        if (parentFloating) {\n          parentFloating.style.pointerEvents = '';\n        }\n        body.style.pointerEvents = 'none';\n        ref.style.pointerEvents = 'auto';\n        floatingEl.style.pointerEvents = 'auto';\n        return () => {\n          body.style.pointerEvents = '';\n          ref.style.pointerEvents = '';\n          floatingEl.style.pointerEvents = '';\n        };\n      }\n    }\n  }, [enabled, open, parentId, elements, tree, handleCloseRef, isHoverOpen]);\n  index(() => {\n    if (!open) {\n      pointerTypeRef.current = undefined;\n      restTimeoutPendingRef.current = false;\n      cleanupMouseMoveHandler();\n      clearPointerEvents();\n    }\n  }, [open, cleanupMouseMoveHandler, clearPointerEvents]);\n  React.useEffect(() => {\n    return () => {\n      cleanupMouseMoveHandler();\n      clearTimeout(timeoutRef.current);\n      clearTimeout(restTimeoutRef.current);\n      clearPointerEvents();\n    };\n  }, [enabled, elements.domReference, cleanupMouseMoveHandler, clearPointerEvents]);\n  const reference = React.useMemo(() => {\n    function setPointerRef(event) {\n      pointerTypeRef.current = event.pointerType;\n    }\n    return {\n      onPointerDown: setPointerRef,\n      onPointerEnter: setPointerRef,\n      onMouseMove(event) {\n        const {\n          nativeEvent\n        } = event;\n        function handleMouseMove() {\n          if (!blockMouseMoveRef.current && !openRef.current) {\n            onOpenChange(true, nativeEvent, 'hover');\n          }\n        }\n        if (mouseOnly && !isMouseLikePointerType(pointerTypeRef.current)) {\n          return;\n        }\n        if (open || restMs === 0) {\n          return;\n        }\n\n        // Ignore insignificant movements to account for tremors.\n        if (restTimeoutPendingRef.current && event.movementX ** 2 + event.movementY ** 2 < 2) {\n          return;\n        }\n        clearTimeout(restTimeoutRef.current);\n        if (pointerTypeRef.current === 'touch') {\n          handleMouseMove();\n        } else {\n          restTimeoutPendingRef.current = true;\n          restTimeoutRef.current = window.setTimeout(handleMouseMove, restMs);\n        }\n      }\n    };\n  }, [mouseOnly, onOpenChange, open, openRef, restMs]);\n  const floating = React.useMemo(() => ({\n    onMouseEnter() {\n      clearTimeout(timeoutRef.current);\n    },\n    onMouseLeave(event) {\n      if (!isClickLikeOpenEvent()) {\n        closeWithDelay(event.nativeEvent, false);\n      }\n    }\n  }), [closeWithDelay, isClickLikeOpenEvent]);\n  return React.useMemo(() => enabled ? {\n    reference,\n    floating\n  } : {}, [enabled, reference, floating]);\n}\n\nconst NOOP = () => {};\nconst FloatingDelayGroupContext = /*#__PURE__*/React.createContext({\n  delay: 0,\n  initialDelay: 0,\n  timeoutMs: 0,\n  currentId: null,\n  setCurrentId: NOOP,\n  setState: NOOP,\n  isInstantPhase: false\n});\n\n/**\n * @deprecated\n * Use the return value of `useDelayGroup()` instead.\n */\nconst useDelayGroupContext = () => React.useContext(FloatingDelayGroupContext);\n/**\n * Provides context for a group of floating elements that should share a\n * `delay`.\n * @see https://floating-ui.com/docs/FloatingDelayGroup\n */\nfunction FloatingDelayGroup(props) {\n  const {\n    children,\n    delay,\n    timeoutMs = 0\n  } = props;\n  const [state, setState] = React.useReducer((prev, next) => ({\n    ...prev,\n    ...next\n  }), {\n    delay,\n    timeoutMs,\n    initialDelay: delay,\n    currentId: null,\n    isInstantPhase: false\n  });\n  const initialCurrentIdRef = React.useRef(null);\n  const setCurrentId = React.useCallback(currentId => {\n    setState({\n      currentId\n    });\n  }, []);\n  index(() => {\n    if (state.currentId) {\n      if (initialCurrentIdRef.current === null) {\n        initialCurrentIdRef.current = state.currentId;\n      } else if (!state.isInstantPhase) {\n        setState({\n          isInstantPhase: true\n        });\n      }\n    } else {\n      if (state.isInstantPhase) {\n        setState({\n          isInstantPhase: false\n        });\n      }\n      initialCurrentIdRef.current = null;\n    }\n  }, [state.currentId, state.isInstantPhase]);\n  return /*#__PURE__*/React.createElement(FloatingDelayGroupContext.Provider, {\n    value: React.useMemo(() => ({\n      ...state,\n      setState,\n      setCurrentId\n    }), [state, setCurrentId])\n  }, children);\n}\n/**\n * Enables grouping when called inside a component that's a child of a\n * `FloatingDelayGroup`.\n * @see https://floating-ui.com/docs/FloatingDelayGroup\n */\nfunction useDelayGroup(context, options) {\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    open,\n    onOpenChange,\n    floatingId\n  } = context;\n  const {\n    id: optionId,\n    enabled = true\n  } = options;\n  const id = optionId != null ? optionId : floatingId;\n  const groupContext = useDelayGroupContext();\n  const {\n    currentId,\n    setCurrentId,\n    initialDelay,\n    setState,\n    timeoutMs\n  } = groupContext;\n  index(() => {\n    if (!enabled) return;\n    if (!currentId) return;\n    setState({\n      delay: {\n        open: 1,\n        close: getDelay(initialDelay, 'close')\n      }\n    });\n    if (currentId !== id) {\n      onOpenChange(false);\n    }\n  }, [enabled, id, onOpenChange, setState, currentId, initialDelay]);\n  index(() => {\n    function unset() {\n      onOpenChange(false);\n      setState({\n        delay: initialDelay,\n        currentId: null\n      });\n    }\n    if (!enabled) return;\n    if (!currentId) return;\n    if (!open && currentId === id) {\n      if (timeoutMs) {\n        const timeout = window.setTimeout(unset, timeoutMs);\n        return () => {\n          clearTimeout(timeout);\n        };\n      }\n      unset();\n    }\n  }, [enabled, open, setState, currentId, id, onOpenChange, initialDelay, timeoutMs]);\n  index(() => {\n    if (!enabled) return;\n    if (setCurrentId === NOOP || !open) return;\n    setCurrentId(id);\n  }, [enabled, open, setCurrentId, id]);\n  return groupContext;\n}\n\nlet rafId = 0;\nfunction enqueueFocus(el, options) {\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    preventScroll = false,\n    cancelPrevious = true,\n    sync = false\n  } = options;\n  cancelPrevious && cancelAnimationFrame(rafId);\n  const exec = () => el == null ? void 0 : el.focus({\n    preventScroll\n  });\n  if (sync) {\n    exec();\n  } else {\n    rafId = requestAnimationFrame(exec);\n  }\n}\n\nfunction getAncestors(nodes, id) {\n  var _nodes$find;\n  let allAncestors = [];\n  let currentParentId = (_nodes$find = nodes.find(node => node.id === id)) == null ? void 0 : _nodes$find.parentId;\n  while (currentParentId) {\n    const currentNode = nodes.find(node => node.id === currentParentId);\n    currentParentId = currentNode == null ? void 0 : currentNode.parentId;\n    if (currentNode) {\n      allAncestors = allAncestors.concat(currentNode);\n    }\n  }\n  return allAncestors;\n}\n\nfunction getChildren(nodes, id) {\n  let allChildren = nodes.filter(node => {\n    var _node$context;\n    return node.parentId === id && ((_node$context = node.context) == null ? void 0 : _node$context.open);\n  });\n  let currentChildren = allChildren;\n  while (currentChildren.length) {\n    currentChildren = nodes.filter(node => {\n      var _currentChildren;\n      return (_currentChildren = currentChildren) == null ? void 0 : _currentChildren.some(n => {\n        var _node$context2;\n        return node.parentId === n.id && ((_node$context2 = node.context) == null ? void 0 : _node$context2.open);\n      });\n    });\n    allChildren = allChildren.concat(currentChildren);\n  }\n  return allChildren;\n}\nfunction getDeepestNode(nodes, id) {\n  let deepestNodeId;\n  let maxDepth = -1;\n  function findDeepest(nodeId, depth) {\n    if (depth > maxDepth) {\n      deepestNodeId = nodeId;\n      maxDepth = depth;\n    }\n    const children = getChildren(nodes, nodeId);\n    children.forEach(child => {\n      findDeepest(child.id, depth + 1);\n    });\n  }\n  findDeepest(id, 0);\n  return nodes.find(node => node.id === deepestNodeId);\n}\n\n// Modified to add conditional `aria-hidden` support:\n// https://github.com/theKashey/aria-hidden/blob/9220c8f4a4fd35f63bee5510a9f41a37264382d4/src/index.ts\nlet counterMap = /*#__PURE__*/new WeakMap();\nlet uncontrolledElementsSet = /*#__PURE__*/new WeakSet();\nlet markerMap = {};\nlet lockCount$1 = 0;\nconst supportsInert = () => typeof HTMLElement !== 'undefined' && 'inert' in HTMLElement.prototype;\nconst unwrapHost = node => node && (node.host || unwrapHost(node.parentNode));\nconst correctElements = (parent, targets) => targets.map(target => {\n  if (parent.contains(target)) {\n    return target;\n  }\n  const correctedTarget = unwrapHost(target);\n  if (parent.contains(correctedTarget)) {\n    return correctedTarget;\n  }\n  return null;\n}).filter(x => x != null);\nfunction applyAttributeToOthers(uncorrectedAvoidElements, body, ariaHidden, inert) {\n  const markerName = 'data-floating-ui-inert';\n  const controlAttribute = inert ? 'inert' : ariaHidden ? 'aria-hidden' : null;\n  const avoidElements = correctElements(body, uncorrectedAvoidElements);\n  const elementsToKeep = new Set();\n  const elementsToStop = new Set(avoidElements);\n  const hiddenElements = [];\n  if (!markerMap[markerName]) {\n    markerMap[markerName] = new WeakMap();\n  }\n  const markerCounter = markerMap[markerName];\n  avoidElements.forEach(keep);\n  deep(body);\n  elementsToKeep.clear();\n  function keep(el) {\n    if (!el || elementsToKeep.has(el)) {\n      return;\n    }\n    elementsToKeep.add(el);\n    el.parentNode && keep(el.parentNode);\n  }\n  function deep(parent) {\n    if (!parent || elementsToStop.has(parent)) {\n      return;\n    }\n    [].forEach.call(parent.children, node => {\n      if (getNodeName(node) === 'script') return;\n      if (elementsToKeep.has(node)) {\n        deep(node);\n      } else {\n        const attr = controlAttribute ? node.getAttribute(controlAttribute) : null;\n        const alreadyHidden = attr !== null && attr !== 'false';\n        const counterValue = (counterMap.get(node) || 0) + 1;\n        const markerValue = (markerCounter.get(node) || 0) + 1;\n        counterMap.set(node, counterValue);\n        markerCounter.set(node, markerValue);\n        hiddenElements.push(node);\n        if (counterValue === 1 && alreadyHidden) {\n          uncontrolledElementsSet.add(node);\n        }\n        if (markerValue === 1) {\n          node.setAttribute(markerName, '');\n        }\n        if (!alreadyHidden && controlAttribute) {\n          node.setAttribute(controlAttribute, 'true');\n        }\n      }\n    });\n  }\n  lockCount$1++;\n  return () => {\n    hiddenElements.forEach(element => {\n      const counterValue = (counterMap.get(element) || 0) - 1;\n      const markerValue = (markerCounter.get(element) || 0) - 1;\n      counterMap.set(element, counterValue);\n      markerCounter.set(element, markerValue);\n      if (!counterValue) {\n        if (!uncontrolledElementsSet.has(element) && controlAttribute) {\n          element.removeAttribute(controlAttribute);\n        }\n        uncontrolledElementsSet.delete(element);\n      }\n      if (!markerValue) {\n        element.removeAttribute(markerName);\n      }\n    });\n    lockCount$1--;\n    if (!lockCount$1) {\n      counterMap = new WeakMap();\n      counterMap = new WeakMap();\n      uncontrolledElementsSet = new WeakSet();\n      markerMap = {};\n    }\n  };\n}\nfunction markOthers(avoidElements, ariaHidden, inert) {\n  if (ariaHidden === void 0) {\n    ariaHidden = false;\n  }\n  if (inert === void 0) {\n    inert = false;\n  }\n  const body = getDocument(avoidElements[0]).body;\n  return applyAttributeToOthers(avoidElements.concat(Array.from(body.querySelectorAll('[aria-live]'))), body, ariaHidden, inert);\n}\n\nconst getTabbableOptions = () => ({\n  getShadowRoot: true,\n  displayCheck:\n  // JSDOM does not support the `tabbable` library. To solve this we can\n  // check if `ResizeObserver` is a real function (not polyfilled), which\n  // determines if the current environment is JSDOM-like.\n  typeof ResizeObserver === 'function' && ResizeObserver.toString().includes('[native code]') ? 'full' : 'none'\n});\nfunction getTabbableIn(container, direction) {\n  const allTabbable = tabbable(container, getTabbableOptions());\n  if (direction === 'prev') {\n    allTabbable.reverse();\n  }\n  const activeIndex = allTabbable.indexOf(activeElement(getDocument(container)));\n  const nextTabbableElements = allTabbable.slice(activeIndex + 1);\n  return nextTabbableElements[0];\n}\nfunction getNextTabbable() {\n  return getTabbableIn(document.body, 'next');\n}\nfunction getPreviousTabbable() {\n  return getTabbableIn(document.body, 'prev');\n}\nfunction isOutsideEvent(event, container) {\n  const containerElement = container || event.currentTarget;\n  const relatedTarget = event.relatedTarget;\n  return !relatedTarget || !contains(containerElement, relatedTarget);\n}\nfunction disableFocusInside(container) {\n  const tabbableElements = tabbable(container, getTabbableOptions());\n  tabbableElements.forEach(element => {\n    element.dataset.tabindex = element.getAttribute('tabindex') || '';\n    element.setAttribute('tabindex', '-1');\n  });\n}\nfunction enableFocusInside(container) {\n  const elements = container.querySelectorAll('[data-tabindex]');\n  elements.forEach(element => {\n    const tabindex = element.dataset.tabindex;\n    delete element.dataset.tabindex;\n    if (tabindex) {\n      element.setAttribute('tabindex', tabindex);\n    } else {\n      element.removeAttribute('tabindex');\n    }\n  });\n}\n\n// See Diego Haz's Sandbox for making this logic work well on Safari/iOS:\n// https://codesandbox.io/s/tabbable-portal-f4tng?file=/src/FocusTrap.tsx\n\nconst HIDDEN_STYLES = {\n  border: 0,\n  clip: 'rect(0 0 0 0)',\n  height: '1px',\n  margin: '-1px',\n  overflow: 'hidden',\n  padding: 0,\n  position: 'fixed',\n  whiteSpace: 'nowrap',\n  width: '1px',\n  top: 0,\n  left: 0\n};\nlet timeoutId;\nfunction setActiveElementOnTab(event) {\n  if (event.key === 'Tab') {\n    event.target;\n    clearTimeout(timeoutId);\n  }\n}\nconst FocusGuard = /*#__PURE__*/React.forwardRef(function FocusGuard(props, ref) {\n  const [role, setRole] = React.useState();\n  index(() => {\n    if (isSafari()) {\n      // Unlike other screen readers such as NVDA and JAWS, the virtual cursor\n      // on VoiceOver does trigger the onFocus event, so we can use the focus\n      // trap element. On Safari, only buttons trigger the onFocus event.\n      // NB: \"group\" role in the Sandbox no longer appears to work, must be a\n      // button role.\n      setRole('button');\n    }\n    document.addEventListener('keydown', setActiveElementOnTab);\n    return () => {\n      document.removeEventListener('keydown', setActiveElementOnTab);\n    };\n  }, []);\n  const restProps = {\n    ref,\n    tabIndex: 0,\n    // Role is only for VoiceOver\n    role,\n    'aria-hidden': role ? undefined : true,\n    [createAttribute('focus-guard')]: '',\n    style: HIDDEN_STYLES\n  };\n  return /*#__PURE__*/React.createElement(\"span\", _extends({}, props, restProps));\n});\n\nconst PortalContext = /*#__PURE__*/React.createContext(null);\nconst attr = /*#__PURE__*/createAttribute('portal');\n/**\n * @see https://floating-ui.com/docs/FloatingPortal#usefloatingportalnode\n */\nfunction useFloatingPortalNode(props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    id,\n    root\n  } = props;\n  const uniqueId = useId();\n  const portalContext = usePortalContext();\n  const [portalNode, setPortalNode] = React.useState(null);\n  const portalNodeRef = React.useRef(null);\n  index(() => {\n    return () => {\n      portalNode == null || portalNode.remove();\n      // Allow the subsequent layout effects to create a new node on updates.\n      // The portal node will still be cleaned up on unmount.\n      // https://github.com/floating-ui/floating-ui/issues/2454\n      queueMicrotask(() => {\n        portalNodeRef.current = null;\n      });\n    };\n  }, [portalNode]);\n  index(() => {\n    // Wait for the uniqueId to be generated before creating the portal node in\n    // React <18 (using `useFloatingId` instead of the native `useId`).\n    // https://github.com/floating-ui/floating-ui/issues/2778\n    if (!uniqueId) return;\n    if (portalNodeRef.current) return;\n    const existingIdRoot = id ? document.getElementById(id) : null;\n    if (!existingIdRoot) return;\n    const subRoot = document.createElement('div');\n    subRoot.id = uniqueId;\n    subRoot.setAttribute(attr, '');\n    existingIdRoot.appendChild(subRoot);\n    portalNodeRef.current = subRoot;\n    setPortalNode(subRoot);\n  }, [id, uniqueId]);\n  index(() => {\n    // Wait for the root to exist before creating the portal node. The root must\n    // be stored in state, not a ref, for this to work reactively.\n    if (root === null) return;\n    if (!uniqueId) return;\n    if (portalNodeRef.current) return;\n    let container = root || (portalContext == null ? void 0 : portalContext.portalNode);\n    if (container && !isElement(container)) container = container.current;\n    container = container || document.body;\n    let idWrapper = null;\n    if (id) {\n      idWrapper = document.createElement('div');\n      idWrapper.id = id;\n      container.appendChild(idWrapper);\n    }\n    const subRoot = document.createElement('div');\n    subRoot.id = uniqueId;\n    subRoot.setAttribute(attr, '');\n    container = idWrapper || container;\n    container.appendChild(subRoot);\n    portalNodeRef.current = subRoot;\n    setPortalNode(subRoot);\n  }, [id, root, uniqueId, portalContext]);\n  return portalNode;\n}\n/**\n * Portals the floating element into a given container element — by default,\n * outside of the app root and into the body.\n * This is necessary to ensure the floating element can appear outside any\n * potential parent containers that cause clipping (such as `overflow: hidden`),\n * while retaining its location in the React tree.\n * @see https://floating-ui.com/docs/FloatingPortal\n */\nfunction FloatingPortal(props) {\n  const {\n    children,\n    id,\n    root,\n    preserveTabOrder = true\n  } = props;\n  const portalNode = useFloatingPortalNode({\n    id,\n    root\n  });\n  const [focusManagerState, setFocusManagerState] = React.useState(null);\n  const beforeOutsideRef = React.useRef(null);\n  const afterOutsideRef = React.useRef(null);\n  const beforeInsideRef = React.useRef(null);\n  const afterInsideRef = React.useRef(null);\n  const modal = focusManagerState == null ? void 0 : focusManagerState.modal;\n  const open = focusManagerState == null ? void 0 : focusManagerState.open;\n  const shouldRenderGuards =\n  // The FocusManager and therefore floating element are currently open/\n  // rendered.\n  !!focusManagerState &&\n  // Guards are only for non-modal focus management.\n  !focusManagerState.modal &&\n  // Don't render if unmount is transitioning.\n  focusManagerState.open && preserveTabOrder && !!(root || portalNode);\n\n  // https://codesandbox.io/s/tabbable-portal-f4tng?file=/src/TabbablePortal.tsx\n  React.useEffect(() => {\n    if (!portalNode || !preserveTabOrder || modal) {\n      return;\n    }\n\n    // Make sure elements inside the portal element are tabbable only when the\n    // portal has already been focused, either by tabbing into a focus trap\n    // element outside or using the mouse.\n    function onFocus(event) {\n      if (portalNode && isOutsideEvent(event)) {\n        const focusing = event.type === 'focusin';\n        const manageFocus = focusing ? enableFocusInside : disableFocusInside;\n        manageFocus(portalNode);\n      }\n    }\n    // Listen to the event on the capture phase so they run before the focus\n    // trap elements onFocus prop is called.\n    portalNode.addEventListener('focusin', onFocus, true);\n    portalNode.addEventListener('focusout', onFocus, true);\n    return () => {\n      portalNode.removeEventListener('focusin', onFocus, true);\n      portalNode.removeEventListener('focusout', onFocus, true);\n    };\n  }, [portalNode, preserveTabOrder, modal]);\n  React.useEffect(() => {\n    if (!portalNode) return;\n    if (open) return;\n    enableFocusInside(portalNode);\n  }, [open, portalNode]);\n  return /*#__PURE__*/React.createElement(PortalContext.Provider, {\n    value: React.useMemo(() => ({\n      preserveTabOrder,\n      beforeOutsideRef,\n      afterOutsideRef,\n      beforeInsideRef,\n      afterInsideRef,\n      portalNode,\n      setFocusManagerState\n    }), [preserveTabOrder, portalNode])\n  }, shouldRenderGuards && portalNode && /*#__PURE__*/React.createElement(FocusGuard, {\n    \"data-type\": \"outside\",\n    ref: beforeOutsideRef,\n    onFocus: event => {\n      if (isOutsideEvent(event, portalNode)) {\n        var _beforeInsideRef$curr;\n        (_beforeInsideRef$curr = beforeInsideRef.current) == null || _beforeInsideRef$curr.focus();\n      } else {\n        const prevTabbable = getPreviousTabbable() || (focusManagerState == null ? void 0 : focusManagerState.refs.domReference.current);\n        prevTabbable == null || prevTabbable.focus();\n      }\n    }\n  }), shouldRenderGuards && portalNode && /*#__PURE__*/React.createElement(\"span\", {\n    \"aria-owns\": portalNode.id,\n    style: HIDDEN_STYLES\n  }), portalNode && /*#__PURE__*/ReactDOM.createPortal(children, portalNode), shouldRenderGuards && portalNode && /*#__PURE__*/React.createElement(FocusGuard, {\n    \"data-type\": \"outside\",\n    ref: afterOutsideRef,\n    onFocus: event => {\n      if (isOutsideEvent(event, portalNode)) {\n        var _afterInsideRef$curre;\n        (_afterInsideRef$curre = afterInsideRef.current) == null || _afterInsideRef$curre.focus();\n      } else {\n        const nextTabbable = getNextTabbable() || (focusManagerState == null ? void 0 : focusManagerState.refs.domReference.current);\n        nextTabbable == null || nextTabbable.focus();\n        (focusManagerState == null ? void 0 : focusManagerState.closeOnFocusOut) && (focusManagerState == null ? void 0 : focusManagerState.onOpenChange(false, event.nativeEvent, 'focus-out'));\n      }\n    }\n  }));\n}\nconst usePortalContext = () => React.useContext(PortalContext);\n\nconst FOCUSABLE_ATTRIBUTE = 'data-floating-ui-focusable';\nfunction getFloatingFocusElement(floatingElement) {\n  if (!floatingElement) {\n    return null;\n  }\n  // Try to find the element that has `{...getFloatingProps()}` spread on it.\n  // This indicates the floating element is acting as a positioning wrapper, and\n  // so focus should be managed on the child element with the event handlers and\n  // aria props.\n  return floatingElement.hasAttribute(FOCUSABLE_ATTRIBUTE) ? floatingElement : floatingElement.querySelector(\"[\" + FOCUSABLE_ATTRIBUTE + \"]\") || floatingElement;\n}\n\nconst LIST_LIMIT = 20;\nlet previouslyFocusedElements = [];\nfunction addPreviouslyFocusedElement(element) {\n  previouslyFocusedElements = previouslyFocusedElements.filter(el => el.isConnected);\n  let tabbableEl = element;\n  if (!tabbableEl || getNodeName(tabbableEl) === 'body') return;\n  if (!isTabbable(tabbableEl, getTabbableOptions())) {\n    const tabbableChild = tabbable(tabbableEl, getTabbableOptions())[0];\n    if (tabbableChild) {\n      tabbableEl = tabbableChild;\n    }\n  }\n  previouslyFocusedElements.push(tabbableEl);\n  if (previouslyFocusedElements.length > LIST_LIMIT) {\n    previouslyFocusedElements = previouslyFocusedElements.slice(-LIST_LIMIT);\n  }\n}\nfunction getPreviouslyFocusedElement() {\n  return previouslyFocusedElements.slice().reverse().find(el => el.isConnected);\n}\nconst VisuallyHiddenDismiss = /*#__PURE__*/React.forwardRef(function VisuallyHiddenDismiss(props, ref) {\n  return /*#__PURE__*/React.createElement(\"button\", _extends({}, props, {\n    type: \"button\",\n    ref: ref,\n    tabIndex: -1,\n    style: HIDDEN_STYLES\n  }));\n});\n/**\n * Provides focus management for the floating element.\n * @see https://floating-ui.com/docs/FloatingFocusManager\n */\nfunction FloatingFocusManager(props) {\n  const {\n    context,\n    children,\n    disabled = false,\n    order = ['content'],\n    guards: _guards = true,\n    initialFocus = 0,\n    returnFocus = true,\n    restoreFocus = false,\n    modal = true,\n    visuallyHiddenDismiss = false,\n    closeOnFocusOut = true\n  } = props;\n  const {\n    open,\n    refs,\n    nodeId,\n    onOpenChange,\n    events,\n    dataRef,\n    floatingId,\n    elements: {\n      domReference,\n      floating\n    }\n  } = context;\n  const ignoreInitialFocus = typeof initialFocus === 'number' && initialFocus < 0;\n  // If the reference is a combobox and is typeable (e.g. input/textarea),\n  // there are different focus semantics. The guards should not be rendered, but\n  // aria-hidden should be applied to all nodes still. Further, the visually\n  // hidden dismiss button should only appear at the end of the list, not the\n  // start.\n  const isUntrappedTypeableCombobox = isTypeableCombobox(domReference) && ignoreInitialFocus;\n\n  // Force the guards to be rendered if the `inert` attribute is not supported.\n  const guards = supportsInert() ? _guards : true;\n  const orderRef = useLatestRef(order);\n  const initialFocusRef = useLatestRef(initialFocus);\n  const returnFocusRef = useLatestRef(returnFocus);\n  const tree = useFloatingTree();\n  const portalContext = usePortalContext();\n  const startDismissButtonRef = React.useRef(null);\n  const endDismissButtonRef = React.useRef(null);\n  const preventReturnFocusRef = React.useRef(false);\n  const isPointerDownRef = React.useRef(false);\n  const tabbableIndexRef = React.useRef(-1);\n  const isInsidePortal = portalContext != null;\n  const floatingFocusElement = getFloatingFocusElement(floating);\n  const getTabbableContent = useEffectEvent(function (container) {\n    if (container === void 0) {\n      container = floatingFocusElement;\n    }\n    return container ? tabbable(container, getTabbableOptions()) : [];\n  });\n  const getTabbableElements = useEffectEvent(container => {\n    const content = getTabbableContent(container);\n    return orderRef.current.map(type => {\n      if (domReference && type === 'reference') {\n        return domReference;\n      }\n      if (floatingFocusElement && type === 'floating') {\n        return floatingFocusElement;\n      }\n      return content;\n    }).filter(Boolean).flat();\n  });\n  React.useEffect(() => {\n    if (disabled) return;\n    if (!modal) return;\n    function onKeyDown(event) {\n      if (event.key === 'Tab') {\n        // The focus guards have nothing to focus, so we need to stop the event.\n        if (contains(floatingFocusElement, activeElement(getDocument(floatingFocusElement))) && getTabbableContent().length === 0 && !isUntrappedTypeableCombobox) {\n          stopEvent(event);\n        }\n        const els = getTabbableElements();\n        const target = getTarget(event);\n        if (orderRef.current[0] === 'reference' && target === domReference) {\n          stopEvent(event);\n          if (event.shiftKey) {\n            enqueueFocus(els[els.length - 1]);\n          } else {\n            enqueueFocus(els[1]);\n          }\n        }\n        if (orderRef.current[1] === 'floating' && target === floatingFocusElement && event.shiftKey) {\n          stopEvent(event);\n          enqueueFocus(els[0]);\n        }\n      }\n    }\n    const doc = getDocument(floatingFocusElement);\n    doc.addEventListener('keydown', onKeyDown);\n    return () => {\n      doc.removeEventListener('keydown', onKeyDown);\n    };\n  }, [disabled, domReference, floatingFocusElement, modal, orderRef, isUntrappedTypeableCombobox, getTabbableContent, getTabbableElements]);\n  React.useEffect(() => {\n    if (disabled) return;\n    if (!floating) return;\n    function handleFocusIn(event) {\n      const target = getTarget(event);\n      const tabbableContent = getTabbableContent();\n      const tabbableIndex = tabbableContent.indexOf(target);\n      if (tabbableIndex !== -1) {\n        tabbableIndexRef.current = tabbableIndex;\n      }\n    }\n    floating.addEventListener('focusin', handleFocusIn);\n    return () => {\n      floating.removeEventListener('focusin', handleFocusIn);\n    };\n  }, [disabled, floating, getTabbableContent]);\n  React.useEffect(() => {\n    if (disabled) return;\n    if (!closeOnFocusOut) return;\n\n    // In Safari, buttons lose focus when pressing them.\n    function handlePointerDown() {\n      isPointerDownRef.current = true;\n      setTimeout(() => {\n        isPointerDownRef.current = false;\n      });\n    }\n    function handleFocusOutside(event) {\n      const relatedTarget = event.relatedTarget;\n      queueMicrotask(() => {\n        const movedToUnrelatedNode = !(contains(domReference, relatedTarget) || contains(floating, relatedTarget) || contains(relatedTarget, floating) || contains(portalContext == null ? void 0 : portalContext.portalNode, relatedTarget) || relatedTarget != null && relatedTarget.hasAttribute(createAttribute('focus-guard')) || tree && (getChildren(tree.nodesRef.current, nodeId).find(node => {\n          var _node$context, _node$context2;\n          return contains((_node$context = node.context) == null ? void 0 : _node$context.elements.floating, relatedTarget) || contains((_node$context2 = node.context) == null ? void 0 : _node$context2.elements.domReference, relatedTarget);\n        }) || getAncestors(tree.nodesRef.current, nodeId).find(node => {\n          var _node$context3, _node$context4;\n          return ((_node$context3 = node.context) == null ? void 0 : _node$context3.elements.floating) === relatedTarget || ((_node$context4 = node.context) == null ? void 0 : _node$context4.elements.domReference) === relatedTarget;\n        })));\n\n        // Restore focus to the previous tabbable element index to prevent\n        // focus from being lost outside the floating tree.\n        if (restoreFocus && movedToUnrelatedNode && activeElement(getDocument(floatingFocusElement)) === getDocument(floatingFocusElement).body) {\n          // Let `FloatingPortal` effect knows that focus is still inside the\n          // floating tree.\n          if (isHTMLElement(floatingFocusElement)) {\n            floatingFocusElement.focus();\n          }\n          const prevTabbableIndex = tabbableIndexRef.current;\n          const tabbableContent = getTabbableContent();\n          const nodeToFocus = tabbableContent[prevTabbableIndex] || tabbableContent[tabbableContent.length - 1] || floatingFocusElement;\n          if (isHTMLElement(nodeToFocus)) {\n            nodeToFocus.focus();\n          }\n        }\n\n        // Focus did not move inside the floating tree, and there are no tabbable\n        // portal guards to handle closing.\n        if ((isUntrappedTypeableCombobox ? true : !modal) && relatedTarget && movedToUnrelatedNode && !isPointerDownRef.current &&\n        // Fix React 18 Strict Mode returnFocus due to double rendering.\n        relatedTarget !== getPreviouslyFocusedElement()) {\n          preventReturnFocusRef.current = true;\n          onOpenChange(false, event, 'focus-out');\n        }\n      });\n    }\n    if (floating && isHTMLElement(domReference)) {\n      domReference.addEventListener('focusout', handleFocusOutside);\n      domReference.addEventListener('pointerdown', handlePointerDown);\n      floating.addEventListener('focusout', handleFocusOutside);\n      return () => {\n        domReference.removeEventListener('focusout', handleFocusOutside);\n        domReference.removeEventListener('pointerdown', handlePointerDown);\n        floating.removeEventListener('focusout', handleFocusOutside);\n      };\n    }\n  }, [disabled, domReference, floating, floatingFocusElement, modal, nodeId, tree, portalContext, onOpenChange, closeOnFocusOut, restoreFocus, getTabbableContent, isUntrappedTypeableCombobox]);\n  React.useEffect(() => {\n    var _portalContext$portal;\n    if (disabled) return;\n\n    // Don't hide portals nested within the parent portal.\n    const portalNodes = Array.from((portalContext == null || (_portalContext$portal = portalContext.portalNode) == null ? void 0 : _portalContext$portal.querySelectorAll(\"[\" + createAttribute('portal') + \"]\")) || []);\n    if (floating) {\n      const insideElements = [floating, ...portalNodes, startDismissButtonRef.current, endDismissButtonRef.current, orderRef.current.includes('reference') || isUntrappedTypeableCombobox ? domReference : null].filter(x => x != null);\n      const cleanup = modal || isUntrappedTypeableCombobox ? markOthers(insideElements, guards, !guards) : markOthers(insideElements);\n      return () => {\n        cleanup();\n      };\n    }\n  }, [disabled, domReference, floating, modal, orderRef, portalContext, isUntrappedTypeableCombobox, guards]);\n  index(() => {\n    if (disabled || !isHTMLElement(floatingFocusElement)) return;\n    const doc = getDocument(floatingFocusElement);\n    const previouslyFocusedElement = activeElement(doc);\n\n    // Wait for any layout effect state setters to execute to set `tabIndex`.\n    queueMicrotask(() => {\n      const focusableElements = getTabbableElements(floatingFocusElement);\n      const initialFocusValue = initialFocusRef.current;\n      const elToFocus = (typeof initialFocusValue === 'number' ? focusableElements[initialFocusValue] : initialFocusValue.current) || floatingFocusElement;\n      const focusAlreadyInsideFloatingEl = contains(floatingFocusElement, previouslyFocusedElement);\n      if (!ignoreInitialFocus && !focusAlreadyInsideFloatingEl && open) {\n        enqueueFocus(elToFocus, {\n          preventScroll: elToFocus === floatingFocusElement\n        });\n      }\n    });\n  }, [disabled, open, floatingFocusElement, ignoreInitialFocus, getTabbableElements, initialFocusRef]);\n  index(() => {\n    if (disabled || !floatingFocusElement) return;\n    let preventReturnFocusScroll = false;\n    const doc = getDocument(floatingFocusElement);\n    const previouslyFocusedElement = activeElement(doc);\n    const contextData = dataRef.current;\n    let openEvent = contextData.openEvent;\n    addPreviouslyFocusedElement(previouslyFocusedElement);\n\n    // Dismissing via outside press should always ignore `returnFocus` to\n    // prevent unwanted scrolling.\n    function onOpenChange(_ref) {\n      let {\n        open,\n        reason,\n        event,\n        nested\n      } = _ref;\n      if (open) {\n        openEvent = event;\n      }\n      if (reason === 'escape-key' && refs.domReference.current) {\n        addPreviouslyFocusedElement(refs.domReference.current);\n      }\n      if (reason === 'hover' && event.type === 'mouseleave') {\n        preventReturnFocusRef.current = true;\n      }\n      if (reason !== 'outside-press') return;\n      if (nested) {\n        preventReturnFocusRef.current = false;\n        preventReturnFocusScroll = true;\n      } else {\n        preventReturnFocusRef.current = !(isVirtualClick(event) || isVirtualPointerEvent(event));\n      }\n    }\n    events.on('openchange', onOpenChange);\n    const fallbackEl = doc.createElement('span');\n    fallbackEl.setAttribute('tabindex', '-1');\n    fallbackEl.setAttribute('aria-hidden', 'true');\n    Object.assign(fallbackEl.style, HIDDEN_STYLES);\n    if (isInsidePortal && domReference) {\n      domReference.insertAdjacentElement('afterend', fallbackEl);\n    }\n    function getReturnElement() {\n      if (typeof returnFocusRef.current === 'boolean') {\n        return getPreviouslyFocusedElement() || fallbackEl;\n      }\n      return returnFocusRef.current.current || fallbackEl;\n    }\n    return () => {\n      events.off('openchange', onOpenChange);\n      const activeEl = activeElement(doc);\n      const isFocusInsideFloatingTree = contains(floating, activeEl) || tree && getChildren(tree.nodesRef.current, nodeId).some(node => {\n        var _node$context5;\n        return contains((_node$context5 = node.context) == null ? void 0 : _node$context5.elements.floating, activeEl);\n      });\n      const shouldFocusReference = isFocusInsideFloatingTree || openEvent && ['click', 'mousedown'].includes(openEvent.type);\n      if (shouldFocusReference && refs.domReference.current) {\n        addPreviouslyFocusedElement(refs.domReference.current);\n      }\n      const returnElement = getReturnElement();\n      queueMicrotask(() => {\n        if (\n        // eslint-disable-next-line react-hooks/exhaustive-deps\n        returnFocusRef.current && !preventReturnFocusRef.current && isHTMLElement(returnElement) && (\n        // If the focus moved somewhere else after mount, avoid returning focus\n        // since it likely entered a different element which should be\n        // respected: https://github.com/floating-ui/floating-ui/issues/2607\n        returnElement !== activeEl && activeEl !== doc.body ? isFocusInsideFloatingTree : true)) {\n          returnElement.focus({\n            preventScroll: preventReturnFocusScroll\n          });\n        }\n        fallbackEl.remove();\n      });\n    };\n  }, [disabled, floating, floatingFocusElement, returnFocusRef, dataRef, refs, events, tree, nodeId, isInsidePortal, domReference]);\n  React.useEffect(() => {\n    // The `returnFocus` cleanup behavior is inside a microtask; ensure we\n    // wait for it to complete before resetting the flag.\n    queueMicrotask(() => {\n      preventReturnFocusRef.current = false;\n    });\n  }, [disabled]);\n\n  // Synchronize the `context` & `modal` value to the FloatingPortal context.\n  // It will decide whether or not it needs to render its own guards.\n  index(() => {\n    if (disabled) return;\n    if (!portalContext) return;\n    portalContext.setFocusManagerState({\n      modal,\n      closeOnFocusOut,\n      open,\n      onOpenChange,\n      refs\n    });\n    return () => {\n      portalContext.setFocusManagerState(null);\n    };\n  }, [disabled, portalContext, modal, open, onOpenChange, refs, closeOnFocusOut]);\n  index(() => {\n    if (disabled) return;\n    if (!floatingFocusElement) return;\n    if (typeof MutationObserver !== 'function') return;\n    if (ignoreInitialFocus) return;\n    const handleMutation = () => {\n      const tabIndex = floatingFocusElement.getAttribute('tabindex');\n      const tabbableContent = getTabbableContent();\n      const activeEl = activeElement(getDocument(floating));\n      const tabbableIndex = tabbableContent.indexOf(activeEl);\n      if (tabbableIndex !== -1) {\n        tabbableIndexRef.current = tabbableIndex;\n      }\n      if (orderRef.current.includes('floating') || activeEl !== refs.domReference.current && tabbableContent.length === 0) {\n        if (tabIndex !== '0') {\n          floatingFocusElement.setAttribute('tabindex', '0');\n        }\n      } else if (tabIndex !== '-1') {\n        floatingFocusElement.setAttribute('tabindex', '-1');\n      }\n    };\n    handleMutation();\n    const observer = new MutationObserver(handleMutation);\n    observer.observe(floatingFocusElement, {\n      childList: true,\n      subtree: true,\n      attributes: true\n    });\n    return () => {\n      observer.disconnect();\n    };\n  }, [disabled, floating, floatingFocusElement, refs, orderRef, getTabbableContent, ignoreInitialFocus]);\n  function renderDismissButton(location) {\n    if (disabled || !visuallyHiddenDismiss || !modal) {\n      return null;\n    }\n    return /*#__PURE__*/React.createElement(VisuallyHiddenDismiss, {\n      ref: location === 'start' ? startDismissButtonRef : endDismissButtonRef,\n      onClick: event => onOpenChange(false, event.nativeEvent)\n    }, typeof visuallyHiddenDismiss === 'string' ? visuallyHiddenDismiss : 'Dismiss');\n  }\n  const shouldRenderGuards = !disabled && guards && (modal ? !isUntrappedTypeableCombobox : true) && (isInsidePortal || modal);\n  return /*#__PURE__*/React.createElement(React.Fragment, null, shouldRenderGuards && /*#__PURE__*/React.createElement(FocusGuard, {\n    \"data-type\": \"inside\",\n    ref: portalContext == null ? void 0 : portalContext.beforeInsideRef,\n    onFocus: event => {\n      if (modal) {\n        const els = getTabbableElements();\n        enqueueFocus(order[0] === 'reference' ? els[0] : els[els.length - 1]);\n      } else if (portalContext != null && portalContext.preserveTabOrder && portalContext.portalNode) {\n        preventReturnFocusRef.current = false;\n        if (isOutsideEvent(event, portalContext.portalNode)) {\n          const nextTabbable = getNextTabbable() || domReference;\n          nextTabbable == null || nextTabbable.focus();\n        } else {\n          var _portalContext$before;\n          (_portalContext$before = portalContext.beforeOutsideRef.current) == null || _portalContext$before.focus();\n        }\n      }\n    }\n  }), !isUntrappedTypeableCombobox && renderDismissButton('start'), children, renderDismissButton('end'), shouldRenderGuards && /*#__PURE__*/React.createElement(FocusGuard, {\n    \"data-type\": \"inside\",\n    ref: portalContext == null ? void 0 : portalContext.afterInsideRef,\n    onFocus: event => {\n      if (modal) {\n        enqueueFocus(getTabbableElements()[0]);\n      } else if (portalContext != null && portalContext.preserveTabOrder && portalContext.portalNode) {\n        if (closeOnFocusOut) {\n          preventReturnFocusRef.current = true;\n        }\n        if (isOutsideEvent(event, portalContext.portalNode)) {\n          const prevTabbable = getPreviousTabbable() || domReference;\n          prevTabbable == null || prevTabbable.focus();\n        } else {\n          var _portalContext$afterO;\n          (_portalContext$afterO = portalContext.afterOutsideRef.current) == null || _portalContext$afterO.focus();\n        }\n      }\n    }\n  }));\n}\n\nlet lockCount = 0;\nfunction enableScrollLock() {\n  const isIOS = /iP(hone|ad|od)|iOS/.test(getPlatform());\n  const bodyStyle = document.body.style;\n  // RTL <body> scrollbar\n  const scrollbarX = Math.round(document.documentElement.getBoundingClientRect().left) + document.documentElement.scrollLeft;\n  const paddingProp = scrollbarX ? 'paddingLeft' : 'paddingRight';\n  const scrollbarWidth = window.innerWidth - document.documentElement.clientWidth;\n  const scrollX = bodyStyle.left ? parseFloat(bodyStyle.left) : window.scrollX;\n  const scrollY = bodyStyle.top ? parseFloat(bodyStyle.top) : window.scrollY;\n  bodyStyle.overflow = 'hidden';\n  if (scrollbarWidth) {\n    bodyStyle[paddingProp] = scrollbarWidth + \"px\";\n  }\n\n  // Only iOS doesn't respect `overflow: hidden` on document.body, and this\n  // technique has fewer side effects.\n  if (isIOS) {\n    var _window$visualViewpor, _window$visualViewpor2;\n    // iOS 12 does not support `visualViewport`.\n    const offsetLeft = ((_window$visualViewpor = window.visualViewport) == null ? void 0 : _window$visualViewpor.offsetLeft) || 0;\n    const offsetTop = ((_window$visualViewpor2 = window.visualViewport) == null ? void 0 : _window$visualViewpor2.offsetTop) || 0;\n    Object.assign(bodyStyle, {\n      position: 'fixed',\n      top: -(scrollY - Math.floor(offsetTop)) + \"px\",\n      left: -(scrollX - Math.floor(offsetLeft)) + \"px\",\n      right: '0'\n    });\n  }\n  return () => {\n    Object.assign(bodyStyle, {\n      overflow: '',\n      [paddingProp]: ''\n    });\n    if (isIOS) {\n      Object.assign(bodyStyle, {\n        position: '',\n        top: '',\n        left: '',\n        right: ''\n      });\n      window.scrollTo(scrollX, scrollY);\n    }\n  };\n}\nlet cleanup = () => {};\n\n/**\n * Provides base styling for a fixed overlay element to dim content or block\n * pointer events behind a floating element.\n * It's a regular `<div>`, so it can be styled via any CSS solution you prefer.\n * @see https://floating-ui.com/docs/FloatingOverlay\n */\nconst FloatingOverlay = /*#__PURE__*/React.forwardRef(function FloatingOverlay(props, ref) {\n  const {\n    lockScroll = false,\n    ...rest\n  } = props;\n  index(() => {\n    if (!lockScroll) return;\n    lockCount++;\n    if (lockCount === 1) {\n      cleanup = enableScrollLock();\n    }\n    return () => {\n      lockCount--;\n      if (lockCount === 0) {\n        cleanup();\n      }\n    };\n  }, [lockScroll]);\n  return /*#__PURE__*/React.createElement(\"div\", _extends({\n    ref: ref\n  }, rest, {\n    style: {\n      position: 'fixed',\n      overflow: 'auto',\n      top: 0,\n      right: 0,\n      bottom: 0,\n      left: 0,\n      ...rest.style\n    }\n  }));\n});\n\nfunction isButtonTarget(event) {\n  return isHTMLElement(event.target) && event.target.tagName === 'BUTTON';\n}\nfunction isSpaceIgnored(element) {\n  return isTypeableElement(element);\n}\n/**\n * Opens or closes the floating element when clicking the reference element.\n * @see https://floating-ui.com/docs/useClick\n */\nfunction useClick(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    onOpenChange,\n    dataRef,\n    elements: {\n      domReference\n    }\n  } = context;\n  const {\n    enabled = true,\n    event: eventOption = 'click',\n    toggle = true,\n    ignoreMouse = false,\n    keyboardHandlers = true,\n    stickIfOpen = true\n  } = props;\n  const pointerTypeRef = React.useRef();\n  const didKeyDownRef = React.useRef(false);\n  const reference = React.useMemo(() => ({\n    onPointerDown(event) {\n      pointerTypeRef.current = event.pointerType;\n    },\n    onMouseDown(event) {\n      const pointerType = pointerTypeRef.current;\n\n      // Ignore all buttons except for the \"main\" button.\n      // https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent/button\n      if (event.button !== 0) return;\n      if (eventOption === 'click') return;\n      if (isMouseLikePointerType(pointerType, true) && ignoreMouse) return;\n      if (open && toggle && (dataRef.current.openEvent && stickIfOpen ? dataRef.current.openEvent.type === 'mousedown' : true)) {\n        onOpenChange(false, event.nativeEvent, 'click');\n      } else {\n        // Prevent stealing focus from the floating element\n        event.preventDefault();\n        onOpenChange(true, event.nativeEvent, 'click');\n      }\n    },\n    onClick(event) {\n      const pointerType = pointerTypeRef.current;\n      if (eventOption === 'mousedown' && pointerTypeRef.current) {\n        pointerTypeRef.current = undefined;\n        return;\n      }\n      if (isMouseLikePointerType(pointerType, true) && ignoreMouse) return;\n      if (open && toggle && (dataRef.current.openEvent && stickIfOpen ? dataRef.current.openEvent.type === 'click' : true)) {\n        onOpenChange(false, event.nativeEvent, 'click');\n      } else {\n        onOpenChange(true, event.nativeEvent, 'click');\n      }\n    },\n    onKeyDown(event) {\n      pointerTypeRef.current = undefined;\n      if (event.defaultPrevented || !keyboardHandlers || isButtonTarget(event)) {\n        return;\n      }\n      if (event.key === ' ' && !isSpaceIgnored(domReference)) {\n        // Prevent scrolling\n        event.preventDefault();\n        didKeyDownRef.current = true;\n      }\n      if (event.key === 'Enter') {\n        if (open && toggle) {\n          onOpenChange(false, event.nativeEvent, 'click');\n        } else {\n          onOpenChange(true, event.nativeEvent, 'click');\n        }\n      }\n    },\n    onKeyUp(event) {\n      if (event.defaultPrevented || !keyboardHandlers || isButtonTarget(event) || isSpaceIgnored(domReference)) {\n        return;\n      }\n      if (event.key === ' ' && didKeyDownRef.current) {\n        didKeyDownRef.current = false;\n        if (open && toggle) {\n          onOpenChange(false, event.nativeEvent, 'click');\n        } else {\n          onOpenChange(true, event.nativeEvent, 'click');\n        }\n      }\n    }\n  }), [dataRef, domReference, eventOption, ignoreMouse, keyboardHandlers, onOpenChange, open, stickIfOpen, toggle]);\n  return React.useMemo(() => enabled ? {\n    reference\n  } : {}, [enabled, reference]);\n}\n\nfunction createVirtualElement(domElement, data) {\n  let offsetX = null;\n  let offsetY = null;\n  let isAutoUpdateEvent = false;\n  return {\n    contextElement: domElement || undefined,\n    getBoundingClientRect() {\n      var _data$dataRef$current;\n      const domRect = (domElement == null ? void 0 : domElement.getBoundingClientRect()) || {\n        width: 0,\n        height: 0,\n        x: 0,\n        y: 0\n      };\n      const isXAxis = data.axis === 'x' || data.axis === 'both';\n      const isYAxis = data.axis === 'y' || data.axis === 'both';\n      const canTrackCursorOnAutoUpdate = ['mouseenter', 'mousemove'].includes(((_data$dataRef$current = data.dataRef.current.openEvent) == null ? void 0 : _data$dataRef$current.type) || '') && data.pointerType !== 'touch';\n      let width = domRect.width;\n      let height = domRect.height;\n      let x = domRect.x;\n      let y = domRect.y;\n      if (offsetX == null && data.x && isXAxis) {\n        offsetX = domRect.x - data.x;\n      }\n      if (offsetY == null && data.y && isYAxis) {\n        offsetY = domRect.y - data.y;\n      }\n      x -= offsetX || 0;\n      y -= offsetY || 0;\n      width = 0;\n      height = 0;\n      if (!isAutoUpdateEvent || canTrackCursorOnAutoUpdate) {\n        width = data.axis === 'y' ? domRect.width : 0;\n        height = data.axis === 'x' ? domRect.height : 0;\n        x = isXAxis && data.x != null ? data.x : x;\n        y = isYAxis && data.y != null ? data.y : y;\n      } else if (isAutoUpdateEvent && !canTrackCursorOnAutoUpdate) {\n        height = data.axis === 'x' ? domRect.height : height;\n        width = data.axis === 'y' ? domRect.width : width;\n      }\n      isAutoUpdateEvent = true;\n      return {\n        width,\n        height,\n        x,\n        y,\n        top: y,\n        right: x + width,\n        bottom: y + height,\n        left: x\n      };\n    }\n  };\n}\nfunction isMouseBasedEvent(event) {\n  return event != null && event.clientX != null;\n}\n/**\n * Positions the floating element relative to a client point (in the viewport),\n * such as the mouse position. By default, it follows the mouse cursor.\n * @see https://floating-ui.com/docs/useClientPoint\n */\nfunction useClientPoint(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    dataRef,\n    elements: {\n      floating,\n      domReference\n    },\n    refs\n  } = context;\n  const {\n    enabled = true,\n    axis = 'both',\n    x = null,\n    y = null\n  } = props;\n  const initialRef = React.useRef(false);\n  const cleanupListenerRef = React.useRef(null);\n  const [pointerType, setPointerType] = React.useState();\n  const [reactive, setReactive] = React.useState([]);\n  const setReference = useEffectEvent((x, y) => {\n    if (initialRef.current) return;\n\n    // Prevent setting if the open event was not a mouse-like one\n    // (e.g. focus to open, then hover over the reference element).\n    // Only apply if the event exists.\n    if (dataRef.current.openEvent && !isMouseBasedEvent(dataRef.current.openEvent)) {\n      return;\n    }\n    refs.setPositionReference(createVirtualElement(domReference, {\n      x,\n      y,\n      axis,\n      dataRef,\n      pointerType\n    }));\n  });\n  const handleReferenceEnterOrMove = useEffectEvent(event => {\n    if (x != null || y != null) return;\n    if (!open) {\n      setReference(event.clientX, event.clientY);\n    } else if (!cleanupListenerRef.current) {\n      // If there's no cleanup, there's no listener, but we want to ensure\n      // we add the listener if the cursor landed on the floating element and\n      // then back on the reference (i.e. it's interactive).\n      setReactive([]);\n    }\n  });\n\n  // If the pointer is a mouse-like pointer, we want to continue following the\n  // mouse even if the floating element is transitioning out. On touch\n  // devices, this is undesirable because the floating element will move to\n  // the dismissal touch point.\n  const openCheck = isMouseLikePointerType(pointerType) ? floating : open;\n  const addListener = React.useCallback(() => {\n    // Explicitly specified `x`/`y` coordinates shouldn't add a listener.\n    if (!openCheck || !enabled || x != null || y != null) return;\n    const win = getWindow(floating);\n    function handleMouseMove(event) {\n      const target = getTarget(event);\n      if (!contains(floating, target)) {\n        setReference(event.clientX, event.clientY);\n      } else {\n        win.removeEventListener('mousemove', handleMouseMove);\n        cleanupListenerRef.current = null;\n      }\n    }\n    if (!dataRef.current.openEvent || isMouseBasedEvent(dataRef.current.openEvent)) {\n      win.addEventListener('mousemove', handleMouseMove);\n      const cleanup = () => {\n        win.removeEventListener('mousemove', handleMouseMove);\n        cleanupListenerRef.current = null;\n      };\n      cleanupListenerRef.current = cleanup;\n      return cleanup;\n    }\n    refs.setPositionReference(domReference);\n  }, [openCheck, enabled, x, y, floating, dataRef, refs, domReference, setReference]);\n  React.useEffect(() => {\n    return addListener();\n  }, [addListener, reactive]);\n  React.useEffect(() => {\n    if (enabled && !floating) {\n      initialRef.current = false;\n    }\n  }, [enabled, floating]);\n  React.useEffect(() => {\n    if (!enabled && open) {\n      initialRef.current = true;\n    }\n  }, [enabled, open]);\n  index(() => {\n    if (enabled && (x != null || y != null)) {\n      initialRef.current = false;\n      setReference(x, y);\n    }\n  }, [enabled, x, y, setReference]);\n  const reference = React.useMemo(() => {\n    function setPointerTypeRef(_ref) {\n      let {\n        pointerType\n      } = _ref;\n      setPointerType(pointerType);\n    }\n    return {\n      onPointerDown: setPointerTypeRef,\n      onPointerEnter: setPointerTypeRef,\n      onMouseMove: handleReferenceEnterOrMove,\n      onMouseEnter: handleReferenceEnterOrMove\n    };\n  }, [handleReferenceEnterOrMove]);\n  return React.useMemo(() => enabled ? {\n    reference\n  } : {}, [enabled, reference]);\n}\n\nconst bubbleHandlerKeys = {\n  pointerdown: 'onPointerDown',\n  mousedown: 'onMouseDown',\n  click: 'onClick'\n};\nconst captureHandlerKeys = {\n  pointerdown: 'onPointerDownCapture',\n  mousedown: 'onMouseDownCapture',\n  click: 'onClickCapture'\n};\nconst normalizeProp = normalizable => {\n  var _normalizable$escapeK, _normalizable$outside;\n  return {\n    escapeKey: typeof normalizable === 'boolean' ? normalizable : (_normalizable$escapeK = normalizable == null ? void 0 : normalizable.escapeKey) != null ? _normalizable$escapeK : false,\n    outsidePress: typeof normalizable === 'boolean' ? normalizable : (_normalizable$outside = normalizable == null ? void 0 : normalizable.outsidePress) != null ? _normalizable$outside : true\n  };\n};\n/**\n * Closes the floating element when a dismissal is requested — by default, when\n * the user presses the `escape` key or outside of the floating element.\n * @see https://floating-ui.com/docs/useDismiss\n */\nfunction useDismiss(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    onOpenChange,\n    elements,\n    dataRef\n  } = context;\n  const {\n    enabled = true,\n    escapeKey = true,\n    outsidePress: unstable_outsidePress = true,\n    outsidePressEvent = 'pointerdown',\n    referencePress = false,\n    referencePressEvent = 'pointerdown',\n    ancestorScroll = false,\n    bubbles,\n    capture\n  } = props;\n  const tree = useFloatingTree();\n  const outsidePressFn = useEffectEvent(typeof unstable_outsidePress === 'function' ? unstable_outsidePress : () => false);\n  const outsidePress = typeof unstable_outsidePress === 'function' ? outsidePressFn : unstable_outsidePress;\n  const insideReactTreeRef = React.useRef(false);\n  const endedOrStartedInsideRef = React.useRef(false);\n  const {\n    escapeKey: escapeKeyBubbles,\n    outsidePress: outsidePressBubbles\n  } = normalizeProp(bubbles);\n  const {\n    escapeKey: escapeKeyCapture,\n    outsidePress: outsidePressCapture\n  } = normalizeProp(capture);\n  const isComposingRef = React.useRef(false);\n  const closeOnEscapeKeyDown = useEffectEvent(event => {\n    var _dataRef$current$floa;\n    if (!open || !enabled || !escapeKey || event.key !== 'Escape') {\n      return;\n    }\n\n    // Wait until IME is settled. Pressing `Escape` while composing should\n    // close the compose menu, but not the floating element.\n    if (isComposingRef.current) {\n      return;\n    }\n    const nodeId = (_dataRef$current$floa = dataRef.current.floatingContext) == null ? void 0 : _dataRef$current$floa.nodeId;\n    const children = tree ? getChildren(tree.nodesRef.current, nodeId) : [];\n    if (!escapeKeyBubbles) {\n      event.stopPropagation();\n      if (children.length > 0) {\n        let shouldDismiss = true;\n        children.forEach(child => {\n          var _child$context;\n          if ((_child$context = child.context) != null && _child$context.open && !child.context.dataRef.current.__escapeKeyBubbles) {\n            shouldDismiss = false;\n            return;\n          }\n        });\n        if (!shouldDismiss) {\n          return;\n        }\n      }\n    }\n    onOpenChange(false, isReactEvent(event) ? event.nativeEvent : event, 'escape-key');\n  });\n  const closeOnEscapeKeyDownCapture = useEffectEvent(event => {\n    var _getTarget2;\n    const callback = () => {\n      var _getTarget;\n      closeOnEscapeKeyDown(event);\n      (_getTarget = getTarget(event)) == null || _getTarget.removeEventListener('keydown', callback);\n    };\n    (_getTarget2 = getTarget(event)) == null || _getTarget2.addEventListener('keydown', callback);\n  });\n  const closeOnPressOutside = useEffectEvent(event => {\n    var _dataRef$current$floa2;\n    // Given developers can stop the propagation of the synthetic event,\n    // we can only be confident with a positive value.\n    const insideReactTree = insideReactTreeRef.current;\n    insideReactTreeRef.current = false;\n\n    // When click outside is lazy (`click` event), handle dragging.\n    // Don't close if:\n    // - The click started inside the floating element.\n    // - The click ended inside the floating element.\n    const endedOrStartedInside = endedOrStartedInsideRef.current;\n    endedOrStartedInsideRef.current = false;\n    if (outsidePressEvent === 'click' && endedOrStartedInside) {\n      return;\n    }\n    if (insideReactTree) {\n      return;\n    }\n    if (typeof outsidePress === 'function' && !outsidePress(event)) {\n      return;\n    }\n    const target = getTarget(event);\n    const inertSelector = \"[\" + createAttribute('inert') + \"]\";\n    const markers = getDocument(elements.floating).querySelectorAll(inertSelector);\n    let targetRootAncestor = isElement(target) ? target : null;\n    while (targetRootAncestor && !isLastTraversableNode(targetRootAncestor)) {\n      const nextParent = getParentNode(targetRootAncestor);\n      if (isLastTraversableNode(nextParent) || !isElement(nextParent)) {\n        break;\n      }\n      targetRootAncestor = nextParent;\n    }\n\n    // Check if the click occurred on a third-party element injected after the\n    // floating element rendered.\n    if (markers.length && isElement(target) && !isRootElement(target) &&\n    // Clicked on a direct ancestor (e.g. FloatingOverlay).\n    !contains(target, elements.floating) &&\n    // If the target root element contains none of the markers, then the\n    // element was injected after the floating element rendered.\n    Array.from(markers).every(marker => !contains(targetRootAncestor, marker))) {\n      return;\n    }\n\n    // Check if the click occurred on the scrollbar\n    if (isHTMLElement(target) && floating) {\n      // In Firefox, `target.scrollWidth > target.clientWidth` for inline\n      // elements.\n      const canScrollX = target.clientWidth > 0 && target.scrollWidth > target.clientWidth;\n      const canScrollY = target.clientHeight > 0 && target.scrollHeight > target.clientHeight;\n      let xCond = canScrollY && event.offsetX > target.clientWidth;\n\n      // In some browsers it is possible to change the <body> (or window)\n      // scrollbar to the left side, but is very rare and is difficult to\n      // check for. Plus, for modal dialogs with backdrops, it is more\n      // important that the backdrop is checked but not so much the window.\n      if (canScrollY) {\n        const isRTL = getComputedStyle(target).direction === 'rtl';\n        if (isRTL) {\n          xCond = event.offsetX <= target.offsetWidth - target.clientWidth;\n        }\n      }\n      if (xCond || canScrollX && event.offsetY > target.clientHeight) {\n        return;\n      }\n    }\n    const nodeId = (_dataRef$current$floa2 = dataRef.current.floatingContext) == null ? void 0 : _dataRef$current$floa2.nodeId;\n    const targetIsInsideChildren = tree && getChildren(tree.nodesRef.current, nodeId).some(node => {\n      var _node$context;\n      return isEventTargetWithin(event, (_node$context = node.context) == null ? void 0 : _node$context.elements.floating);\n    });\n    if (isEventTargetWithin(event, elements.floating) || isEventTargetWithin(event, elements.domReference) || targetIsInsideChildren) {\n      return;\n    }\n    const children = tree ? getChildren(tree.nodesRef.current, nodeId) : [];\n    if (children.length > 0) {\n      let shouldDismiss = true;\n      children.forEach(child => {\n        var _child$context2;\n        if ((_child$context2 = child.context) != null && _child$context2.open && !child.context.dataRef.current.__outsidePressBubbles) {\n          shouldDismiss = false;\n          return;\n        }\n      });\n      if (!shouldDismiss) {\n        return;\n      }\n    }\n    onOpenChange(false, event, 'outside-press');\n  });\n  const closeOnPressOutsideCapture = useEffectEvent(event => {\n    var _getTarget4;\n    const callback = () => {\n      var _getTarget3;\n      closeOnPressOutside(event);\n      (_getTarget3 = getTarget(event)) == null || _getTarget3.removeEventListener(outsidePressEvent, callback);\n    };\n    (_getTarget4 = getTarget(event)) == null || _getTarget4.addEventListener(outsidePressEvent, callback);\n  });\n  React.useEffect(() => {\n    if (!open || !enabled) {\n      return;\n    }\n    dataRef.current.__escapeKeyBubbles = escapeKeyBubbles;\n    dataRef.current.__outsidePressBubbles = outsidePressBubbles;\n    let compositionTimeout = -1;\n    function onScroll(event) {\n      onOpenChange(false, event, 'ancestor-scroll');\n    }\n    function handleCompositionStart() {\n      window.clearTimeout(compositionTimeout);\n      isComposingRef.current = true;\n    }\n    function handleCompositionEnd() {\n      // Safari fires `compositionend` before `keydown`, so we need to wait\n      // until the next tick to set `isComposing` to `false`.\n      // https://bugs.webkit.org/show_bug.cgi?id=165004\n      compositionTimeout = window.setTimeout(() => {\n        isComposingRef.current = false;\n      },\n      // 0ms or 1ms don't work in Safari. 5ms appears to consistently work.\n      // Only apply to WebKit for the test to remain 0ms.\n      isWebKit() ? 5 : 0);\n    }\n    const doc = getDocument(elements.floating);\n    if (escapeKey) {\n      doc.addEventListener('keydown', escapeKeyCapture ? closeOnEscapeKeyDownCapture : closeOnEscapeKeyDown, escapeKeyCapture);\n      doc.addEventListener('compositionstart', handleCompositionStart);\n      doc.addEventListener('compositionend', handleCompositionEnd);\n    }\n    outsidePress && doc.addEventListener(outsidePressEvent, outsidePressCapture ? closeOnPressOutsideCapture : closeOnPressOutside, outsidePressCapture);\n    let ancestors = [];\n    if (ancestorScroll) {\n      if (isElement(elements.domReference)) {\n        ancestors = getOverflowAncestors(elements.domReference);\n      }\n      if (isElement(elements.floating)) {\n        ancestors = ancestors.concat(getOverflowAncestors(elements.floating));\n      }\n      if (!isElement(elements.reference) && elements.reference && elements.reference.contextElement) {\n        ancestors = ancestors.concat(getOverflowAncestors(elements.reference.contextElement));\n      }\n    }\n\n    // Ignore the visual viewport for scrolling dismissal (allow pinch-zoom)\n    ancestors = ancestors.filter(ancestor => {\n      var _doc$defaultView;\n      return ancestor !== ((_doc$defaultView = doc.defaultView) == null ? void 0 : _doc$defaultView.visualViewport);\n    });\n    ancestors.forEach(ancestor => {\n      ancestor.addEventListener('scroll', onScroll, {\n        passive: true\n      });\n    });\n    return () => {\n      if (escapeKey) {\n        doc.removeEventListener('keydown', escapeKeyCapture ? closeOnEscapeKeyDownCapture : closeOnEscapeKeyDown, escapeKeyCapture);\n        doc.removeEventListener('compositionstart', handleCompositionStart);\n        doc.removeEventListener('compositionend', handleCompositionEnd);\n      }\n      outsidePress && doc.removeEventListener(outsidePressEvent, outsidePressCapture ? closeOnPressOutsideCapture : closeOnPressOutside, outsidePressCapture);\n      ancestors.forEach(ancestor => {\n        ancestor.removeEventListener('scroll', onScroll);\n      });\n      window.clearTimeout(compositionTimeout);\n    };\n  }, [dataRef, elements, escapeKey, outsidePress, outsidePressEvent, open, onOpenChange, ancestorScroll, enabled, escapeKeyBubbles, outsidePressBubbles, closeOnEscapeKeyDown, escapeKeyCapture, closeOnEscapeKeyDownCapture, closeOnPressOutside, outsidePressCapture, closeOnPressOutsideCapture]);\n  React.useEffect(() => {\n    insideReactTreeRef.current = false;\n  }, [outsidePress, outsidePressEvent]);\n  const reference = React.useMemo(() => ({\n    onKeyDown: closeOnEscapeKeyDown,\n    [bubbleHandlerKeys[referencePressEvent]]: event => {\n      if (referencePress) {\n        onOpenChange(false, event.nativeEvent, 'reference-press');\n      }\n    }\n  }), [closeOnEscapeKeyDown, onOpenChange, referencePress, referencePressEvent]);\n  const floating = React.useMemo(() => ({\n    onKeyDown: closeOnEscapeKeyDown,\n    onMouseDown() {\n      endedOrStartedInsideRef.current = true;\n    },\n    onMouseUp() {\n      endedOrStartedInsideRef.current = true;\n    },\n    [captureHandlerKeys[outsidePressEvent]]: () => {\n      insideReactTreeRef.current = true;\n    }\n  }), [closeOnEscapeKeyDown, outsidePressEvent]);\n  return React.useMemo(() => enabled ? {\n    reference,\n    floating\n  } : {}, [enabled, reference, floating]);\n}\n\nfunction useFloatingRootContext(options) {\n  const {\n    open = false,\n    onOpenChange: onOpenChangeProp,\n    elements: elementsProp\n  } = options;\n  const floatingId = useId();\n  const dataRef = React.useRef({});\n  const [events] = React.useState(() => createPubSub());\n  const nested = useFloatingParentNodeId() != null;\n  if (process.env.NODE_ENV !== \"production\") {\n    const optionDomReference = elementsProp.reference;\n    if (optionDomReference && !isElement(optionDomReference)) {\n      error('Cannot pass a virtual element to the `elements.reference` option,', 'as it must be a real DOM element. Use `refs.setPositionReference()`', 'instead.');\n    }\n  }\n  const [positionReference, setPositionReference] = React.useState(elementsProp.reference);\n  const onOpenChange = useEffectEvent((open, event, reason) => {\n    dataRef.current.openEvent = open ? event : undefined;\n    events.emit('openchange', {\n      open,\n      event,\n      reason,\n      nested\n    });\n    onOpenChangeProp == null || onOpenChangeProp(open, event, reason);\n  });\n  const refs = React.useMemo(() => ({\n    setPositionReference\n  }), []);\n  const elements = React.useMemo(() => ({\n    reference: positionReference || elementsProp.reference || null,\n    floating: elementsProp.floating || null,\n    domReference: elementsProp.reference\n  }), [positionReference, elementsProp.reference, elementsProp.floating]);\n  return React.useMemo(() => ({\n    dataRef,\n    open,\n    onOpenChange,\n    elements,\n    events,\n    floatingId,\n    refs\n  }), [open, onOpenChange, elements, events, floatingId, refs]);\n}\n\n/**\n * Provides data to position a floating element and context to add interactions.\n * @see https://floating-ui.com/docs/useFloating\n */\nfunction useFloating(options) {\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    nodeId\n  } = options;\n  const internalRootContext = useFloatingRootContext({\n    ...options,\n    elements: {\n      reference: null,\n      floating: null,\n      ...options.elements\n    }\n  });\n  const rootContext = options.rootContext || internalRootContext;\n  const computedElements = rootContext.elements;\n  const [_domReference, setDomReference] = React.useState(null);\n  const [positionReference, _setPositionReference] = React.useState(null);\n  const optionDomReference = computedElements == null ? void 0 : computedElements.domReference;\n  const domReference = optionDomReference || _domReference;\n  const domReferenceRef = React.useRef(null);\n  const tree = useFloatingTree();\n  index(() => {\n    if (domReference) {\n      domReferenceRef.current = domReference;\n    }\n  }, [domReference]);\n  const position = useFloating$1({\n    ...options,\n    elements: {\n      ...computedElements,\n      ...(positionReference && {\n        reference: positionReference\n      })\n    }\n  });\n  const setPositionReference = React.useCallback(node => {\n    const computedPositionReference = isElement(node) ? {\n      getBoundingClientRect: () => node.getBoundingClientRect(),\n      contextElement: node\n    } : node;\n    // Store the positionReference in state if the DOM reference is specified externally via the\n    // `elements.reference` option. This ensures that it won't be overridden on future renders.\n    _setPositionReference(computedPositionReference);\n    position.refs.setReference(computedPositionReference);\n  }, [position.refs]);\n  const setReference = React.useCallback(node => {\n    if (isElement(node) || node === null) {\n      domReferenceRef.current = node;\n      setDomReference(node);\n    }\n\n    // Backwards-compatibility for passing a virtual element to `reference`\n    // after it has set the DOM reference.\n    if (isElement(position.refs.reference.current) || position.refs.reference.current === null ||\n    // Don't allow setting virtual elements using the old technique back to\n    // `null` to support `positionReference` + an unstable `reference`\n    // callback ref.\n    node !== null && !isElement(node)) {\n      position.refs.setReference(node);\n    }\n  }, [position.refs]);\n  const refs = React.useMemo(() => ({\n    ...position.refs,\n    setReference,\n    setPositionReference,\n    domReference: domReferenceRef\n  }), [position.refs, setReference, setPositionReference]);\n  const elements = React.useMemo(() => ({\n    ...position.elements,\n    domReference: domReference\n  }), [position.elements, domReference]);\n  const context = React.useMemo(() => ({\n    ...position,\n    ...rootContext,\n    refs,\n    elements,\n    nodeId\n  }), [position, refs, elements, nodeId, rootContext]);\n  index(() => {\n    rootContext.dataRef.current.floatingContext = context;\n    const node = tree == null ? void 0 : tree.nodesRef.current.find(node => node.id === nodeId);\n    if (node) {\n      node.context = context;\n    }\n  });\n  return React.useMemo(() => ({\n    ...position,\n    context,\n    refs,\n    elements\n  }), [position, refs, elements, context]);\n}\n\n/**\n * Opens the floating element while the reference element has focus, like CSS\n * `:focus`.\n * @see https://floating-ui.com/docs/useFocus\n */\nfunction useFocus(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    onOpenChange,\n    events,\n    dataRef,\n    elements\n  } = context;\n  const {\n    enabled = true,\n    visibleOnly = true\n  } = props;\n  const blockFocusRef = React.useRef(false);\n  const timeoutRef = React.useRef();\n  const keyboardModalityRef = React.useRef(true);\n  React.useEffect(() => {\n    if (!enabled) return;\n    const win = getWindow(elements.domReference);\n\n    // If the reference was focused and the user left the tab/window, and the\n    // floating element was not open, the focus should be blocked when they\n    // return to the tab/window.\n    function onBlur() {\n      if (!open && isHTMLElement(elements.domReference) && elements.domReference === activeElement(getDocument(elements.domReference))) {\n        blockFocusRef.current = true;\n      }\n    }\n    function onKeyDown() {\n      keyboardModalityRef.current = true;\n    }\n    win.addEventListener('blur', onBlur);\n    win.addEventListener('keydown', onKeyDown, true);\n    return () => {\n      win.removeEventListener('blur', onBlur);\n      win.removeEventListener('keydown', onKeyDown, true);\n    };\n  }, [elements.domReference, open, enabled]);\n  React.useEffect(() => {\n    if (!enabled) return;\n    function onOpenChange(_ref) {\n      let {\n        reason\n      } = _ref;\n      if (reason === 'reference-press' || reason === 'escape-key') {\n        blockFocusRef.current = true;\n      }\n    }\n    events.on('openchange', onOpenChange);\n    return () => {\n      events.off('openchange', onOpenChange);\n    };\n  }, [events, enabled]);\n  React.useEffect(() => {\n    return () => {\n      clearTimeout(timeoutRef.current);\n    };\n  }, []);\n  const reference = React.useMemo(() => ({\n    onPointerDown(event) {\n      if (isVirtualPointerEvent(event.nativeEvent)) return;\n      keyboardModalityRef.current = false;\n    },\n    onMouseLeave() {\n      blockFocusRef.current = false;\n    },\n    onFocus(event) {\n      if (blockFocusRef.current) return;\n      const target = getTarget(event.nativeEvent);\n      if (visibleOnly && isElement(target)) {\n        try {\n          // Mac Safari unreliably matches `:focus-visible` on the reference\n          // if focus was outside the page initially - use the fallback\n          // instead.\n          if (isSafari() && isMac()) throw Error();\n          if (!target.matches(':focus-visible')) return;\n        } catch (e) {\n          // Old browsers will throw an error when using `:focus-visible`.\n          if (!keyboardModalityRef.current && !isTypeableElement(target)) {\n            return;\n          }\n        }\n      }\n      onOpenChange(true, event.nativeEvent, 'focus');\n    },\n    onBlur(event) {\n      blockFocusRef.current = false;\n      const relatedTarget = event.relatedTarget;\n      const nativeEvent = event.nativeEvent;\n\n      // Hit the non-modal focus management portal guard. Focus will be\n      // moved into the floating element immediately after.\n      const movedToFocusGuard = isElement(relatedTarget) && relatedTarget.hasAttribute(createAttribute('focus-guard')) && relatedTarget.getAttribute('data-type') === 'outside';\n\n      // Wait for the window blur listener to fire.\n      timeoutRef.current = window.setTimeout(() => {\n        var _dataRef$current$floa;\n        const activeEl = activeElement(elements.domReference ? elements.domReference.ownerDocument : document);\n\n        // Focus left the page, keep it open.\n        if (!relatedTarget && activeEl === elements.domReference) return;\n\n        // When focusing the reference element (e.g. regular click), then\n        // clicking into the floating element, prevent it from hiding.\n        // Note: it must be focusable, e.g. `tabindex=\"-1\"`.\n        // We can not rely on relatedTarget to point to the correct element\n        // as it will only point to the shadow host of the newly focused element\n        // and not the element that actually has received focus if it is located\n        // inside a shadow root.\n        if (contains((_dataRef$current$floa = dataRef.current.floatingContext) == null ? void 0 : _dataRef$current$floa.refs.floating.current, activeEl) || contains(elements.domReference, activeEl) || movedToFocusGuard) {\n          return;\n        }\n        onOpenChange(false, nativeEvent, 'focus');\n      });\n    }\n  }), [dataRef, elements.domReference, onOpenChange, visibleOnly]);\n  return React.useMemo(() => enabled ? {\n    reference\n  } : {}, [enabled, reference]);\n}\n\nconst ACTIVE_KEY = 'active';\nconst SELECTED_KEY = 'selected';\nfunction mergeProps(userProps, propsList, elementKey) {\n  const map = new Map();\n  const isItem = elementKey === 'item';\n  let domUserProps = userProps;\n  if (isItem && userProps) {\n    const {\n      [ACTIVE_KEY]: _,\n      [SELECTED_KEY]: __,\n      ...validProps\n    } = userProps;\n    domUserProps = validProps;\n  }\n  return {\n    ...(elementKey === 'floating' && {\n      tabIndex: -1,\n      [FOCUSABLE_ATTRIBUTE]: ''\n    }),\n    ...domUserProps,\n    ...propsList.map(value => {\n      const propsOrGetProps = value ? value[elementKey] : null;\n      if (typeof propsOrGetProps === 'function') {\n        return userProps ? propsOrGetProps(userProps) : null;\n      }\n      return propsOrGetProps;\n    }).concat(userProps).reduce((acc, props) => {\n      if (!props) {\n        return acc;\n      }\n      Object.entries(props).forEach(_ref => {\n        let [key, value] = _ref;\n        if (isItem && [ACTIVE_KEY, SELECTED_KEY].includes(key)) {\n          return;\n        }\n        if (key.indexOf('on') === 0) {\n          if (!map.has(key)) {\n            map.set(key, []);\n          }\n          if (typeof value === 'function') {\n            var _map$get;\n            (_map$get = map.get(key)) == null || _map$get.push(value);\n            acc[key] = function () {\n              var _map$get2;\n              for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {\n                args[_key] = arguments[_key];\n              }\n              return (_map$get2 = map.get(key)) == null ? void 0 : _map$get2.map(fn => fn(...args)).find(val => val !== undefined);\n            };\n          }\n        } else {\n          acc[key] = value;\n        }\n      });\n      return acc;\n    }, {})\n  };\n}\n/**\n * Merges an array of interaction hooks' props into prop getters, allowing\n * event handler functions to be composed together without overwriting one\n * another.\n * @see https://floating-ui.com/docs/useInteractions\n */\nfunction useInteractions(propsList) {\n  if (propsList === void 0) {\n    propsList = [];\n  }\n  const referenceDeps = propsList.map(key => key == null ? void 0 : key.reference);\n  const floatingDeps = propsList.map(key => key == null ? void 0 : key.floating);\n  const itemDeps = propsList.map(key => key == null ? void 0 : key.item);\n  const getReferenceProps = React.useCallback(userProps => mergeProps(userProps, propsList, 'reference'),\n  // eslint-disable-next-line react-hooks/exhaustive-deps\n  referenceDeps);\n  const getFloatingProps = React.useCallback(userProps => mergeProps(userProps, propsList, 'floating'),\n  // eslint-disable-next-line react-hooks/exhaustive-deps\n  floatingDeps);\n  const getItemProps = React.useCallback(userProps => mergeProps(userProps, propsList, 'item'),\n  // eslint-disable-next-line react-hooks/exhaustive-deps\n  itemDeps);\n  return React.useMemo(() => ({\n    getReferenceProps,\n    getFloatingProps,\n    getItemProps\n  }), [getReferenceProps, getFloatingProps, getItemProps]);\n}\n\nlet isPreventScrollSupported = false;\nfunction doSwitch(orientation, vertical, horizontal) {\n  switch (orientation) {\n    case 'vertical':\n      return vertical;\n    case 'horizontal':\n      return horizontal;\n    default:\n      return vertical || horizontal;\n  }\n}\nfunction isMainOrientationKey(key, orientation) {\n  const vertical = key === ARROW_UP || key === ARROW_DOWN;\n  const horizontal = key === ARROW_LEFT || key === ARROW_RIGHT;\n  return doSwitch(orientation, vertical, horizontal);\n}\nfunction isMainOrientationToEndKey(key, orientation, rtl) {\n  const vertical = key === ARROW_DOWN;\n  const horizontal = rtl ? key === ARROW_LEFT : key === ARROW_RIGHT;\n  return doSwitch(orientation, vertical, horizontal) || key === 'Enter' || key === ' ' || key === '';\n}\nfunction isCrossOrientationOpenKey(key, orientation, rtl) {\n  const vertical = rtl ? key === ARROW_LEFT : key === ARROW_RIGHT;\n  const horizontal = key === ARROW_DOWN;\n  return doSwitch(orientation, vertical, horizontal);\n}\nfunction isCrossOrientationCloseKey(key, orientation, rtl) {\n  const vertical = rtl ? key === ARROW_RIGHT : key === ARROW_LEFT;\n  const horizontal = key === ARROW_UP;\n  return doSwitch(orientation, vertical, horizontal);\n}\n/**\n * Adds arrow key-based navigation of a list of items, either using real DOM\n * focus or virtual focus.\n * @see https://floating-ui.com/docs/useListNavigation\n */\nfunction useListNavigation(context, props) {\n  const {\n    open,\n    onOpenChange,\n    elements\n  } = context;\n  const {\n    listRef,\n    activeIndex,\n    onNavigate: unstable_onNavigate = () => {},\n    enabled = true,\n    selectedIndex = null,\n    allowEscape = false,\n    loop = false,\n    nested = false,\n    rtl = false,\n    virtual = false,\n    focusItemOnOpen = 'auto',\n    focusItemOnHover = true,\n    openOnArrowKeyDown = true,\n    disabledIndices = undefined,\n    orientation = 'vertical',\n    cols = 1,\n    scrollItemIntoView = true,\n    virtualItemRef,\n    itemSizes,\n    dense = false\n  } = props;\n  if (process.env.NODE_ENV !== \"production\") {\n    if (allowEscape) {\n      if (!loop) {\n        warn('`useListNavigation` looping must be enabled to allow escaping.');\n      }\n      if (!virtual) {\n        warn('`useListNavigation` must be virtual to allow escaping.');\n      }\n    }\n    if (orientation === 'vertical' && cols > 1) {\n      warn('In grid list navigation mode (`cols` > 1), the `orientation` should', 'be either \"horizontal\" or \"both\".');\n    }\n  }\n  const floatingFocusElement = getFloatingFocusElement(elements.floating);\n  const floatingFocusElementRef = useLatestRef(floatingFocusElement);\n  const parentId = useFloatingParentNodeId();\n  const tree = useFloatingTree();\n  const onNavigate = useEffectEvent(unstable_onNavigate);\n  const typeableComboboxReference = isTypeableCombobox(elements.domReference);\n  const focusItemOnOpenRef = React.useRef(focusItemOnOpen);\n  const indexRef = React.useRef(selectedIndex != null ? selectedIndex : -1);\n  const keyRef = React.useRef(null);\n  const isPointerModalityRef = React.useRef(true);\n  const previousOnNavigateRef = React.useRef(onNavigate);\n  const previousMountedRef = React.useRef(!!elements.floating);\n  const previousOpenRef = React.useRef(open);\n  const forceSyncFocus = React.useRef(false);\n  const forceScrollIntoViewRef = React.useRef(false);\n  const disabledIndicesRef = useLatestRef(disabledIndices);\n  const latestOpenRef = useLatestRef(open);\n  const scrollItemIntoViewRef = useLatestRef(scrollItemIntoView);\n  const selectedIndexRef = useLatestRef(selectedIndex);\n  const [activeId, setActiveId] = React.useState();\n  const [virtualId, setVirtualId] = React.useState();\n  const focusItem = useEffectEvent(function (listRef, indexRef, forceScrollIntoView) {\n    if (forceScrollIntoView === void 0) {\n      forceScrollIntoView = false;\n    }\n    function runFocus(item) {\n      if (virtual) {\n        setActiveId(item.id);\n        tree == null || tree.events.emit('virtualfocus', item);\n        if (virtualItemRef) {\n          virtualItemRef.current = item;\n        }\n      } else {\n        enqueueFocus(item, {\n          preventScroll: true,\n          // Mac Safari does not move the virtual cursor unless the focus call\n          // is sync. However, for the very first focus call, we need to wait\n          // for the position to be ready in order to prevent unwanted\n          // scrolling. This means the virtual cursor will not move to the first\n          // item when first opening the floating element, but will on\n          // subsequent calls. `preventScroll` is supported in modern Safari,\n          // so we can use that instead.\n          // iOS Safari must be async or the first item will not be focused.\n          sync: isMac() && isSafari() ? isPreventScrollSupported || forceSyncFocus.current : false\n        });\n      }\n    }\n    const initialItem = listRef.current[indexRef.current];\n    if (initialItem) {\n      runFocus(initialItem);\n    }\n    requestAnimationFrame(() => {\n      const waitedItem = listRef.current[indexRef.current] || initialItem;\n      if (!waitedItem) return;\n      if (!initialItem) {\n        runFocus(waitedItem);\n      }\n      const scrollIntoViewOptions = scrollItemIntoViewRef.current;\n      const shouldScrollIntoView = scrollIntoViewOptions && item && (forceScrollIntoView || !isPointerModalityRef.current);\n      if (shouldScrollIntoView) {\n        // JSDOM doesn't support `.scrollIntoView()` but it's widely supported\n        // by all browsers.\n        waitedItem.scrollIntoView == null || waitedItem.scrollIntoView(typeof scrollIntoViewOptions === 'boolean' ? {\n          block: 'nearest',\n          inline: 'nearest'\n        } : scrollIntoViewOptions);\n      }\n    });\n  });\n  index(() => {\n    document.createElement('div').focus({\n      get preventScroll() {\n        isPreventScrollSupported = true;\n        return false;\n      }\n    });\n  }, []);\n\n  // Sync `selectedIndex` to be the `activeIndex` upon opening the floating\n  // element. Also, reset `activeIndex` upon closing the floating element.\n  index(() => {\n    if (!enabled) return;\n    if (open && elements.floating) {\n      if (focusItemOnOpenRef.current && selectedIndex != null) {\n        // Regardless of the pointer modality, we want to ensure the selected\n        // item comes into view when the floating element is opened.\n        forceScrollIntoViewRef.current = true;\n        indexRef.current = selectedIndex;\n        onNavigate(selectedIndex);\n      }\n    } else if (previousMountedRef.current) {\n      // Since the user can specify `onNavigate` conditionally\n      // (onNavigate: open ? setActiveIndex : setSelectedIndex),\n      // we store and call the previous function.\n      indexRef.current = -1;\n      previousOnNavigateRef.current(null);\n    }\n  }, [enabled, open, elements.floating, selectedIndex, onNavigate]);\n\n  // Sync `activeIndex` to be the focused item while the floating element is\n  // open.\n  index(() => {\n    if (!enabled) return;\n    if (open && elements.floating) {\n      if (activeIndex == null) {\n        forceSyncFocus.current = false;\n        if (selectedIndexRef.current != null) {\n          return;\n        }\n\n        // Reset while the floating element was open (e.g. the list changed).\n        if (previousMountedRef.current) {\n          indexRef.current = -1;\n          focusItem(listRef, indexRef);\n        }\n\n        // Initial sync.\n        if ((!previousOpenRef.current || !previousMountedRef.current) && focusItemOnOpenRef.current && (keyRef.current != null || focusItemOnOpenRef.current === true && keyRef.current == null)) {\n          let runs = 0;\n          const waitForListPopulated = () => {\n            if (listRef.current[0] == null) {\n              // Avoid letting the browser paint if possible on the first try,\n              // otherwise use rAF. Don't try more than twice, since something\n              // is wrong otherwise.\n              if (runs < 2) {\n                const scheduler = runs ? requestAnimationFrame : queueMicrotask;\n                scheduler(waitForListPopulated);\n              }\n              runs++;\n            } else {\n              indexRef.current = keyRef.current == null || isMainOrientationToEndKey(keyRef.current, orientation, rtl) || nested ? getMinIndex(listRef, disabledIndicesRef.current) : getMaxIndex(listRef, disabledIndicesRef.current);\n              keyRef.current = null;\n              onNavigate(indexRef.current);\n            }\n          };\n          waitForListPopulated();\n        }\n      } else if (!isIndexOutOfBounds(listRef, activeIndex)) {\n        indexRef.current = activeIndex;\n        focusItem(listRef, indexRef, forceScrollIntoViewRef.current);\n        forceScrollIntoViewRef.current = false;\n      }\n    }\n  }, [enabled, open, elements.floating, activeIndex, selectedIndexRef, nested, listRef, orientation, rtl, onNavigate, focusItem, disabledIndicesRef]);\n\n  // Ensure the parent floating element has focus when a nested child closes\n  // to allow arrow key navigation to work after the pointer leaves the child.\n  index(() => {\n    var _nodes$find;\n    if (!enabled || elements.floating || !tree || virtual || !previousMountedRef.current) {\n      return;\n    }\n    const nodes = tree.nodesRef.current;\n    const parent = (_nodes$find = nodes.find(node => node.id === parentId)) == null || (_nodes$find = _nodes$find.context) == null ? void 0 : _nodes$find.elements.floating;\n    const activeEl = activeElement(getDocument(elements.floating));\n    const treeContainsActiveEl = nodes.some(node => node.context && contains(node.context.elements.floating, activeEl));\n    if (parent && !treeContainsActiveEl && isPointerModalityRef.current) {\n      parent.focus({\n        preventScroll: true\n      });\n    }\n  }, [enabled, elements.floating, tree, parentId, virtual]);\n  index(() => {\n    if (!enabled) return;\n    if (!tree) return;\n    if (!virtual) return;\n    if (parentId) return;\n    function handleVirtualFocus(item) {\n      setVirtualId(item.id);\n      if (virtualItemRef) {\n        virtualItemRef.current = item;\n      }\n    }\n    tree.events.on('virtualfocus', handleVirtualFocus);\n    return () => {\n      tree.events.off('virtualfocus', handleVirtualFocus);\n    };\n  }, [enabled, tree, virtual, parentId, virtualItemRef]);\n  index(() => {\n    previousOnNavigateRef.current = onNavigate;\n    previousMountedRef.current = !!elements.floating;\n  });\n  index(() => {\n    if (!open) {\n      keyRef.current = null;\n    }\n  }, [open]);\n  index(() => {\n    previousOpenRef.current = open;\n  }, [open]);\n  const hasActiveIndex = activeIndex != null;\n  const item = React.useMemo(() => {\n    function syncCurrentTarget(currentTarget) {\n      if (!open) return;\n      const index = listRef.current.indexOf(currentTarget);\n      if (index !== -1) {\n        onNavigate(index);\n      }\n    }\n    const props = {\n      onFocus(_ref) {\n        let {\n          currentTarget\n        } = _ref;\n        syncCurrentTarget(currentTarget);\n      },\n      onClick: _ref2 => {\n        let {\n          currentTarget\n        } = _ref2;\n        return currentTarget.focus({\n          preventScroll: true\n        });\n      },\n      // Safari\n      ...(focusItemOnHover && {\n        onMouseMove(_ref3) {\n          let {\n            currentTarget\n          } = _ref3;\n          syncCurrentTarget(currentTarget);\n        },\n        onPointerLeave(_ref4) {\n          let {\n            pointerType\n          } = _ref4;\n          if (!isPointerModalityRef.current || pointerType === 'touch') {\n            return;\n          }\n          indexRef.current = -1;\n          focusItem(listRef, indexRef);\n          onNavigate(null);\n          if (!virtual) {\n            enqueueFocus(floatingFocusElementRef.current, {\n              preventScroll: true\n            });\n          }\n        }\n      })\n    };\n    return props;\n  }, [open, floatingFocusElementRef, focusItem, focusItemOnHover, listRef, onNavigate, virtual]);\n  const commonOnKeyDown = useEffectEvent(event => {\n    isPointerModalityRef.current = false;\n    forceSyncFocus.current = true;\n\n    // When composing a character, Chrome fires ArrowDown twice. Firefox/Safari\n    // don't appear to suffer from this. `event.isComposing` is avoided due to\n    // Safari not supporting it properly (although it's not needed in the first\n    // place for Safari, just avoiding any possible issues).\n    if (event.which === 229) {\n      return;\n    }\n\n    // If the floating element is animating out, ignore navigation. Otherwise,\n    // the `activeIndex` gets set to 0 despite not being open so the next time\n    // the user ArrowDowns, the first item won't be focused.\n    if (!latestOpenRef.current && event.currentTarget === floatingFocusElementRef.current) {\n      return;\n    }\n    if (nested && isCrossOrientationCloseKey(event.key, orientation, rtl)) {\n      stopEvent(event);\n      onOpenChange(false, event.nativeEvent, 'list-navigation');\n      if (isHTMLElement(elements.domReference)) {\n        if (virtual) {\n          tree == null || tree.events.emit('virtualfocus', elements.domReference);\n        } else {\n          elements.domReference.focus();\n        }\n      }\n      return;\n    }\n    const currentIndex = indexRef.current;\n    const minIndex = getMinIndex(listRef, disabledIndices);\n    const maxIndex = getMaxIndex(listRef, disabledIndices);\n    if (!typeableComboboxReference) {\n      if (event.key === 'Home') {\n        stopEvent(event);\n        indexRef.current = minIndex;\n        onNavigate(indexRef.current);\n      }\n      if (event.key === 'End') {\n        stopEvent(event);\n        indexRef.current = maxIndex;\n        onNavigate(indexRef.current);\n      }\n    }\n\n    // Grid navigation.\n    if (cols > 1) {\n      const sizes = itemSizes || Array.from({\n        length: listRef.current.length\n      }, () => ({\n        width: 1,\n        height: 1\n      }));\n      // To calculate movements on the grid, we use hypothetical cell indices\n      // as if every item was 1x1, then convert back to real indices.\n      const cellMap = buildCellMap(sizes, cols, dense);\n      const minGridIndex = cellMap.findIndex(index => index != null && !isDisabled(listRef.current, index, disabledIndices));\n      // last enabled index\n      const maxGridIndex = cellMap.reduce((foundIndex, index, cellIndex) => index != null && !isDisabled(listRef.current, index, disabledIndices) ? cellIndex : foundIndex, -1);\n      const index = cellMap[getGridNavigatedIndex({\n        current: cellMap.map(itemIndex => itemIndex != null ? listRef.current[itemIndex] : null)\n      }, {\n        event,\n        orientation,\n        loop,\n        rtl,\n        cols,\n        // treat undefined (empty grid spaces) as disabled indices so we\n        // don't end up in them\n        disabledIndices: getCellIndices([...(disabledIndices || listRef.current.map((_, index) => isDisabled(listRef.current, index) ? index : undefined)), undefined], cellMap),\n        minIndex: minGridIndex,\n        maxIndex: maxGridIndex,\n        prevIndex: getCellIndexOfCorner(indexRef.current > maxIndex ? minIndex : indexRef.current, sizes, cellMap, cols,\n        // use a corner matching the edge closest to the direction\n        // we're moving in so we don't end up in the same item. Prefer\n        // top/left over bottom/right.\n        event.key === ARROW_DOWN ? 'bl' : event.key === (rtl ? ARROW_LEFT : ARROW_RIGHT) ? 'tr' : 'tl'),\n        stopEvent: true\n      })];\n      if (index != null) {\n        indexRef.current = index;\n        onNavigate(indexRef.current);\n      }\n      if (orientation === 'both') {\n        return;\n      }\n    }\n    if (isMainOrientationKey(event.key, orientation)) {\n      stopEvent(event);\n\n      // Reset the index if no item is focused.\n      if (open && !virtual && activeElement(event.currentTarget.ownerDocument) === event.currentTarget) {\n        indexRef.current = isMainOrientationToEndKey(event.key, orientation, rtl) ? minIndex : maxIndex;\n        onNavigate(indexRef.current);\n        return;\n      }\n      if (isMainOrientationToEndKey(event.key, orientation, rtl)) {\n        if (loop) {\n          indexRef.current = currentIndex >= maxIndex ? allowEscape && currentIndex !== listRef.current.length ? -1 : minIndex : findNonDisabledIndex(listRef, {\n            startingIndex: currentIndex,\n            disabledIndices\n          });\n        } else {\n          indexRef.current = Math.min(maxIndex, findNonDisabledIndex(listRef, {\n            startingIndex: currentIndex,\n            disabledIndices\n          }));\n        }\n      } else {\n        if (loop) {\n          indexRef.current = currentIndex <= minIndex ? allowEscape && currentIndex !== -1 ? listRef.current.length : maxIndex : findNonDisabledIndex(listRef, {\n            startingIndex: currentIndex,\n            decrement: true,\n            disabledIndices\n          });\n        } else {\n          indexRef.current = Math.max(minIndex, findNonDisabledIndex(listRef, {\n            startingIndex: currentIndex,\n            decrement: true,\n            disabledIndices\n          }));\n        }\n      }\n      if (isIndexOutOfBounds(listRef, indexRef.current)) {\n        onNavigate(null);\n      } else {\n        onNavigate(indexRef.current);\n      }\n    }\n  });\n  const ariaActiveDescendantProp = React.useMemo(() => {\n    return virtual && open && hasActiveIndex && {\n      'aria-activedescendant': virtualId || activeId\n    };\n  }, [virtual, open, hasActiveIndex, virtualId, activeId]);\n  const floating = React.useMemo(() => {\n    return {\n      'aria-orientation': orientation === 'both' ? undefined : orientation,\n      ...(!isTypeableCombobox(elements.domReference) && ariaActiveDescendantProp),\n      onKeyDown: commonOnKeyDown,\n      onPointerMove() {\n        isPointerModalityRef.current = true;\n      }\n    };\n  }, [ariaActiveDescendantProp, commonOnKeyDown, elements.domReference, orientation]);\n  const reference = React.useMemo(() => {\n    function checkVirtualMouse(event) {\n      if (focusItemOnOpen === 'auto' && isVirtualClick(event.nativeEvent)) {\n        focusItemOnOpenRef.current = true;\n      }\n    }\n    function checkVirtualPointer(event) {\n      // `pointerdown` fires first, reset the state then perform the checks.\n      focusItemOnOpenRef.current = focusItemOnOpen;\n      if (focusItemOnOpen === 'auto' && isVirtualPointerEvent(event.nativeEvent)) {\n        focusItemOnOpenRef.current = true;\n      }\n    }\n    return {\n      ...ariaActiveDescendantProp,\n      onKeyDown(event) {\n        isPointerModalityRef.current = false;\n        const isArrowKey = event.key.startsWith('Arrow');\n        const isHomeOrEndKey = ['Home', 'End'].includes(event.key);\n        const isMoveKey = isArrowKey || isHomeOrEndKey;\n        const isCrossOpenKey = isCrossOrientationOpenKey(event.key, orientation, rtl);\n        const isCrossCloseKey = isCrossOrientationCloseKey(event.key, orientation, rtl);\n        const isMainKey = isMainOrientationKey(event.key, orientation);\n        const isNavigationKey = (nested ? isCrossOpenKey : isMainKey) || event.key === 'Enter' || event.key.trim() === '';\n        if (virtual && open) {\n          const rootNode = tree == null ? void 0 : tree.nodesRef.current.find(node => node.parentId == null);\n          const deepestNode = tree && rootNode ? getDeepestNode(tree.nodesRef.current, rootNode.id) : null;\n          if (isMoveKey && deepestNode && virtualItemRef) {\n            const eventObject = new KeyboardEvent('keydown', {\n              key: event.key,\n              bubbles: true\n            });\n            if (isCrossOpenKey || isCrossCloseKey) {\n              var _deepestNode$context, _deepestNode$context2;\n              const isCurrentTarget = ((_deepestNode$context = deepestNode.context) == null ? void 0 : _deepestNode$context.elements.domReference) === event.currentTarget;\n              const dispatchItem = isCrossCloseKey && !isCurrentTarget ? (_deepestNode$context2 = deepestNode.context) == null ? void 0 : _deepestNode$context2.elements.domReference : isCrossOpenKey ? listRef.current.find(item => (item == null ? void 0 : item.id) === activeId) : null;\n              if (dispatchItem) {\n                stopEvent(event);\n                dispatchItem.dispatchEvent(eventObject);\n                setVirtualId(undefined);\n              }\n            }\n            if ((isMainKey || isHomeOrEndKey) && deepestNode.context) {\n              if (deepestNode.context.open && deepestNode.parentId && event.currentTarget !== deepestNode.context.elements.domReference) {\n                var _deepestNode$context$;\n                stopEvent(event);\n                (_deepestNode$context$ = deepestNode.context.elements.domReference) == null || _deepestNode$context$.dispatchEvent(eventObject);\n                return;\n              }\n            }\n          }\n          return commonOnKeyDown(event);\n        }\n\n        // If a floating element should not open on arrow key down, avoid\n        // setting `activeIndex` while it's closed.\n        if (!open && !openOnArrowKeyDown && isArrowKey) {\n          return;\n        }\n        if (isNavigationKey) {\n          keyRef.current = nested && isMainKey ? null : event.key;\n        }\n        if (nested) {\n          if (isCrossOpenKey) {\n            stopEvent(event);\n            if (open) {\n              indexRef.current = getMinIndex(listRef, disabledIndicesRef.current);\n              onNavigate(indexRef.current);\n            } else {\n              onOpenChange(true, event.nativeEvent, 'list-navigation');\n            }\n          }\n          return;\n        }\n        if (isMainKey) {\n          if (selectedIndex != null) {\n            indexRef.current = selectedIndex;\n          }\n          stopEvent(event);\n          if (!open && openOnArrowKeyDown) {\n            onOpenChange(true, event.nativeEvent, 'list-navigation');\n          } else {\n            commonOnKeyDown(event);\n          }\n          if (open) {\n            onNavigate(indexRef.current);\n          }\n        }\n      },\n      onFocus() {\n        if (open && !virtual) {\n          onNavigate(null);\n        }\n      },\n      onPointerDown: checkVirtualPointer,\n      onMouseDown: checkVirtualMouse,\n      onClick: checkVirtualMouse\n    };\n  }, [activeId, ariaActiveDescendantProp, commonOnKeyDown, disabledIndicesRef, focusItemOnOpen, listRef, nested, onNavigate, onOpenChange, open, openOnArrowKeyDown, orientation, rtl, selectedIndex, tree, virtual, virtualItemRef]);\n  return React.useMemo(() => enabled ? {\n    reference,\n    floating,\n    item\n  } : {}, [enabled, reference, floating, item]);\n}\n\nconst componentRoleToAriaRoleMap = /*#__PURE__*/new Map([['select', 'listbox'], ['combobox', 'listbox'], ['label', false]]);\n\n/**\n * Adds base screen reader props to the reference and floating elements for a\n * given floating element `role`.\n * @see https://floating-ui.com/docs/useRole\n */\nfunction useRole(context, props) {\n  var _componentRoleToAriaR;\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    floatingId\n  } = context;\n  const {\n    enabled = true,\n    role = 'dialog'\n  } = props;\n  const ariaRole = (_componentRoleToAriaR = componentRoleToAriaRoleMap.get(role)) != null ? _componentRoleToAriaR : role;\n  const referenceId = useId();\n  const parentId = useFloatingParentNodeId();\n  const isNested = parentId != null;\n  const reference = React.useMemo(() => {\n    if (ariaRole === 'tooltip' || role === 'label') {\n      return {\n        [\"aria-\" + (role === 'label' ? 'labelledby' : 'describedby')]: open ? floatingId : undefined\n      };\n    }\n    return {\n      'aria-expanded': open ? 'true' : 'false',\n      'aria-haspopup': ariaRole === 'alertdialog' ? 'dialog' : ariaRole,\n      'aria-controls': open ? floatingId : undefined,\n      ...(ariaRole === 'listbox' && {\n        role: 'combobox'\n      }),\n      ...(ariaRole === 'menu' && {\n        id: referenceId\n      }),\n      ...(ariaRole === 'menu' && isNested && {\n        role: 'menuitem'\n      }),\n      ...(role === 'select' && {\n        'aria-autocomplete': 'none'\n      }),\n      ...(role === 'combobox' && {\n        'aria-autocomplete': 'list'\n      })\n    };\n  }, [ariaRole, floatingId, isNested, open, referenceId, role]);\n  const floating = React.useMemo(() => {\n    const floatingProps = {\n      id: floatingId,\n      ...(ariaRole && {\n        role: ariaRole\n      })\n    };\n    if (ariaRole === 'tooltip' || role === 'label') {\n      return floatingProps;\n    }\n    return {\n      ...floatingProps,\n      ...(ariaRole === 'menu' && {\n        'aria-labelledby': referenceId\n      })\n    };\n  }, [ariaRole, floatingId, referenceId, role]);\n  const item = React.useCallback(_ref => {\n    let {\n      active,\n      selected\n    } = _ref;\n    const commonProps = {\n      role: 'option',\n      ...(active && {\n        id: floatingId + \"-option\"\n      })\n    };\n\n    // For `menu`, we are unable to tell if the item is a `menuitemradio`\n    // or `menuitemcheckbox`. For backwards-compatibility reasons, also\n    // avoid defaulting to `menuitem` as it may overwrite custom role props.\n    switch (role) {\n      case 'select':\n        return {\n          ...commonProps,\n          'aria-selected': active && selected\n        };\n      case 'combobox':\n        {\n          return {\n            ...commonProps,\n            ...(active && {\n              'aria-selected': true\n            })\n          };\n        }\n    }\n    return {};\n  }, [floatingId, role]);\n  return React.useMemo(() => enabled ? {\n    reference,\n    floating,\n    item\n  } : {}, [enabled, reference, floating, item]);\n}\n\n// Converts a JS style key like `backgroundColor` to a CSS transition-property\n// like `background-color`.\nconst camelCaseToKebabCase = str => str.replace(/[A-Z]+(?![a-z])|[A-Z]/g, ($, ofs) => (ofs ? '-' : '') + $.toLowerCase());\nfunction execWithArgsOrReturn(valueOrFn, args) {\n  return typeof valueOrFn === 'function' ? valueOrFn(args) : valueOrFn;\n}\nfunction useDelayUnmount(open, durationMs) {\n  const [isMounted, setIsMounted] = React.useState(open);\n  if (open && !isMounted) {\n    setIsMounted(true);\n  }\n  React.useEffect(() => {\n    if (!open && isMounted) {\n      const timeout = setTimeout(() => setIsMounted(false), durationMs);\n      return () => clearTimeout(timeout);\n    }\n  }, [open, isMounted, durationMs]);\n  return isMounted;\n}\n/**\n * Provides a status string to apply CSS transitions to a floating element,\n * correctly handling placement-aware transitions.\n * @see https://floating-ui.com/docs/useTransition#usetransitionstatus\n */\nfunction useTransitionStatus(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    open,\n    elements: {\n      floating\n    }\n  } = context;\n  const {\n    duration = 250\n  } = props;\n  const isNumberDuration = typeof duration === 'number';\n  const closeDuration = (isNumberDuration ? duration : duration.close) || 0;\n  const [status, setStatus] = React.useState('unmounted');\n  const isMounted = useDelayUnmount(open, closeDuration);\n  if (!isMounted && status === 'close') {\n    setStatus('unmounted');\n  }\n  index(() => {\n    if (!floating) return;\n    if (open) {\n      setStatus('initial');\n      const frame = requestAnimationFrame(() => {\n        setStatus('open');\n      });\n      return () => {\n        cancelAnimationFrame(frame);\n      };\n    }\n    setStatus('close');\n  }, [open, floating]);\n  return {\n    isMounted,\n    status\n  };\n}\n/**\n * Provides styles to apply CSS transitions to a floating element, correctly\n * handling placement-aware transitions. Wrapper around `useTransitionStatus`.\n * @see https://floating-ui.com/docs/useTransition#usetransitionstyles\n */\nfunction useTransitionStyles(context, props) {\n  if (props === void 0) {\n    props = {};\n  }\n  const {\n    initial: unstable_initial = {\n      opacity: 0\n    },\n    open: unstable_open,\n    close: unstable_close,\n    common: unstable_common,\n    duration = 250\n  } = props;\n  const placement = context.placement;\n  const side = placement.split('-')[0];\n  const fnArgs = React.useMemo(() => ({\n    side,\n    placement\n  }), [side, placement]);\n  const isNumberDuration = typeof duration === 'number';\n  const openDuration = (isNumberDuration ? duration : duration.open) || 0;\n  const closeDuration = (isNumberDuration ? duration : duration.close) || 0;\n  const [styles, setStyles] = React.useState(() => ({\n    ...execWithArgsOrReturn(unstable_common, fnArgs),\n    ...execWithArgsOrReturn(unstable_initial, fnArgs)\n  }));\n  const {\n    isMounted,\n    status\n  } = useTransitionStatus(context, {\n    duration\n  });\n  const initialRef = useLatestRef(unstable_initial);\n  const openRef = useLatestRef(unstable_open);\n  const closeRef = useLatestRef(unstable_close);\n  const commonRef = useLatestRef(unstable_common);\n  index(() => {\n    const initialStyles = execWithArgsOrReturn(initialRef.current, fnArgs);\n    const closeStyles = execWithArgsOrReturn(closeRef.current, fnArgs);\n    const commonStyles = execWithArgsOrReturn(commonRef.current, fnArgs);\n    const openStyles = execWithArgsOrReturn(openRef.current, fnArgs) || Object.keys(initialStyles).reduce((acc, key) => {\n      acc[key] = '';\n      return acc;\n    }, {});\n    if (status === 'initial') {\n      setStyles(styles => ({\n        transitionProperty: styles.transitionProperty,\n        ...commonStyles,\n        ...initialStyles\n      }));\n    }\n    if (status === 'open') {\n      setStyles({\n        transitionProperty: Object.keys(openStyles).map(camelCaseToKebabCase).join(','),\n        transitionDuration: openDuration + \"ms\",\n        ...commonStyles,\n        ...openStyles\n      });\n    }\n    if (status === 'close') {\n      const styles = closeStyles || initialStyles;\n      setStyles({\n        transitionProperty: Object.keys(styles).map(camelCaseToKebabCase).join(','),\n        transitionDuration: closeDuration + \"ms\",\n        ...commonStyles,\n        ...styles\n      });\n    }\n  }, [closeDuration, closeRef, initialRef, openRef, commonRef, openDuration, status, fnArgs]);\n  return {\n    isMounted,\n    styles\n  };\n}\n\n/**\n * Provides a matching callback that can be used to focus an item as the user\n * types, often used in tandem with `useListNavigation()`.\n * @see https://floating-ui.com/docs/useTypeahead\n */\nfunction useTypeahead(context, props) {\n  var _ref;\n  const {\n    open,\n    dataRef\n  } = context;\n  const {\n    listRef,\n    activeIndex,\n    onMatch: unstable_onMatch,\n    onTypingChange: unstable_onTypingChange,\n    enabled = true,\n    findMatch = null,\n    resetMs = 750,\n    ignoreKeys = [],\n    selectedIndex = null\n  } = props;\n  const timeoutIdRef = React.useRef();\n  const stringRef = React.useRef('');\n  const prevIndexRef = React.useRef((_ref = selectedIndex != null ? selectedIndex : activeIndex) != null ? _ref : -1);\n  const matchIndexRef = React.useRef(null);\n  const onMatch = useEffectEvent(unstable_onMatch);\n  const onTypingChange = useEffectEvent(unstable_onTypingChange);\n  const findMatchRef = useLatestRef(findMatch);\n  const ignoreKeysRef = useLatestRef(ignoreKeys);\n  index(() => {\n    if (open) {\n      clearTimeout(timeoutIdRef.current);\n      matchIndexRef.current = null;\n      stringRef.current = '';\n    }\n  }, [open]);\n  index(() => {\n    // Sync arrow key navigation but not typeahead navigation.\n    if (open && stringRef.current === '') {\n      var _ref2;\n      prevIndexRef.current = (_ref2 = selectedIndex != null ? selectedIndex : activeIndex) != null ? _ref2 : -1;\n    }\n  }, [open, selectedIndex, activeIndex]);\n  const setTypingChange = useEffectEvent(value => {\n    if (value) {\n      if (!dataRef.current.typing) {\n        dataRef.current.typing = value;\n        onTypingChange(value);\n      }\n    } else {\n      if (dataRef.current.typing) {\n        dataRef.current.typing = value;\n        onTypingChange(value);\n      }\n    }\n  });\n  const onKeyDown = useEffectEvent(event => {\n    function getMatchingIndex(list, orderedList, string) {\n      const str = findMatchRef.current ? findMatchRef.current(orderedList, string) : orderedList.find(text => (text == null ? void 0 : text.toLocaleLowerCase().indexOf(string.toLocaleLowerCase())) === 0);\n      return str ? list.indexOf(str) : -1;\n    }\n    const listContent = listRef.current;\n    if (stringRef.current.length > 0 && stringRef.current[0] !== ' ') {\n      if (getMatchingIndex(listContent, listContent, stringRef.current) === -1) {\n        setTypingChange(false);\n      } else if (event.key === ' ') {\n        stopEvent(event);\n      }\n    }\n    if (listContent == null || ignoreKeysRef.current.includes(event.key) ||\n    // Character key.\n    event.key.length !== 1 ||\n    // Modifier key.\n    event.ctrlKey || event.metaKey || event.altKey) {\n      return;\n    }\n    if (open && event.key !== ' ') {\n      stopEvent(event);\n      setTypingChange(true);\n    }\n\n    // Bail out if the list contains a word like \"llama\" or \"aaron\". TODO:\n    // allow it in this case, too.\n    const allowRapidSuccessionOfFirstLetter = listContent.every(text => {\n      var _text$, _text$2;\n      return text ? ((_text$ = text[0]) == null ? void 0 : _text$.toLocaleLowerCase()) !== ((_text$2 = text[1]) == null ? void 0 : _text$2.toLocaleLowerCase()) : true;\n    });\n\n    // Allows the user to cycle through items that start with the same letter\n    // in rapid succession.\n    if (allowRapidSuccessionOfFirstLetter && stringRef.current === event.key) {\n      stringRef.current = '';\n      prevIndexRef.current = matchIndexRef.current;\n    }\n    stringRef.current += event.key;\n    clearTimeout(timeoutIdRef.current);\n    timeoutIdRef.current = setTimeout(() => {\n      stringRef.current = '';\n      prevIndexRef.current = matchIndexRef.current;\n      setTypingChange(false);\n    }, resetMs);\n    const prevIndex = prevIndexRef.current;\n    const index = getMatchingIndex(listContent, [...listContent.slice((prevIndex || 0) + 1), ...listContent.slice(0, (prevIndex || 0) + 1)], stringRef.current);\n    if (index !== -1) {\n      onMatch(index);\n      matchIndexRef.current = index;\n    } else if (event.key !== ' ') {\n      stringRef.current = '';\n      setTypingChange(false);\n    }\n  });\n  const reference = React.useMemo(() => ({\n    onKeyDown\n  }), [onKeyDown]);\n  const floating = React.useMemo(() => {\n    return {\n      onKeyDown,\n      onKeyUp(event) {\n        if (event.key === ' ') {\n          setTypingChange(false);\n        }\n      }\n    };\n  }, [onKeyDown, setTypingChange]);\n  return React.useMemo(() => enabled ? {\n    reference,\n    floating\n  } : {}, [enabled, reference, floating]);\n}\n\nfunction getArgsWithCustomFloatingHeight(state, height) {\n  return {\n    ...state,\n    rects: {\n      ...state.rects,\n      floating: {\n        ...state.rects.floating,\n        height\n      }\n    }\n  };\n}\n/**\n * Positions the floating element such that an inner element inside of it is\n * anchored to the reference element.\n * @see https://floating-ui.com/docs/inner\n */\nconst inner = props => ({\n  name: 'inner',\n  options: props,\n  async fn(state) {\n    const {\n      listRef,\n      overflowRef,\n      onFallbackChange,\n      offset: innerOffset = 0,\n      index = 0,\n      minItemsVisible = 4,\n      referenceOverflowThreshold = 0,\n      scrollRef,\n      ...detectOverflowOptions\n    } = evaluate(props, state);\n    const {\n      rects,\n      elements: {\n        floating\n      }\n    } = state;\n    const item = listRef.current[index];\n    const scrollEl = (scrollRef == null ? void 0 : scrollRef.current) || floating;\n\n    // Valid combinations:\n    // 1. Floating element is the scrollRef and has a border (default)\n    // 2. Floating element is not the scrollRef, floating element has a border\n    // 3. Floating element is not the scrollRef, scrollRef has a border\n    // Floating > {...getFloatingProps()} wrapper > scrollRef > items is not\n    // allowed as VoiceOver doesn't work.\n    const clientTop = floating.clientTop || scrollEl.clientTop;\n    const floatingIsBordered = floating.clientTop !== 0;\n    const scrollElIsBordered = scrollEl.clientTop !== 0;\n    const floatingIsScrollEl = floating === scrollEl;\n    if (process.env.NODE_ENV !== \"production\") {\n      if (!state.placement.startsWith('bottom')) {\n        warn('`placement` side must be \"bottom\" when using the `inner`', 'middleware.');\n      }\n    }\n    if (!item) {\n      return {};\n    }\n    const nextArgs = {\n      ...state,\n      ...(await offset(-item.offsetTop - floating.clientTop - rects.reference.height / 2 - item.offsetHeight / 2 - innerOffset).fn(state))\n    };\n    const overflow = await detectOverflow(getArgsWithCustomFloatingHeight(nextArgs, scrollEl.scrollHeight + clientTop + floating.clientTop), detectOverflowOptions);\n    const refOverflow = await detectOverflow(nextArgs, {\n      ...detectOverflowOptions,\n      elementContext: 'reference'\n    });\n    const diffY = max(0, overflow.top);\n    const nextY = nextArgs.y + diffY;\n    const isScrollable = scrollEl.scrollHeight > scrollEl.clientHeight;\n    const rounder = isScrollable ? v => v : round;\n    const maxHeight = rounder(max(0, scrollEl.scrollHeight + (floatingIsBordered && floatingIsScrollEl || scrollElIsBordered ? clientTop * 2 : 0) - diffY - max(0, overflow.bottom)));\n    scrollEl.style.maxHeight = maxHeight + \"px\";\n    scrollEl.scrollTop = diffY;\n\n    // There is not enough space, fallback to standard anchored positioning\n    if (onFallbackChange) {\n      const shouldFallback = scrollEl.offsetHeight < item.offsetHeight * min(minItemsVisible, listRef.current.length) - 1 || refOverflow.top >= -referenceOverflowThreshold || refOverflow.bottom >= -referenceOverflowThreshold;\n      ReactDOM.flushSync(() => onFallbackChange(shouldFallback));\n    }\n    if (overflowRef) {\n      overflowRef.current = await detectOverflow(getArgsWithCustomFloatingHeight({\n        ...nextArgs,\n        y: nextY\n      }, scrollEl.offsetHeight + clientTop + floating.clientTop), detectOverflowOptions);\n    }\n    return {\n      y: nextY\n    };\n  }\n});\n/**\n * Changes the `inner` middleware's `offset` upon a `wheel` event to\n * expand the floating element's height, revealing more list items.\n * @see https://floating-ui.com/docs/inner\n */\nfunction useInnerOffset(context, props) {\n  const {\n    open,\n    elements\n  } = context;\n  const {\n    enabled = true,\n    overflowRef,\n    scrollRef,\n    onChange: unstable_onChange\n  } = props;\n  const onChange = useEffectEvent(unstable_onChange);\n  const controlledScrollingRef = React.useRef(false);\n  const prevScrollTopRef = React.useRef(null);\n  const initialOverflowRef = React.useRef(null);\n  React.useEffect(() => {\n    if (!enabled) return;\n    function onWheel(e) {\n      if (e.ctrlKey || !el || overflowRef.current == null) {\n        return;\n      }\n      const dY = e.deltaY;\n      const isAtTop = overflowRef.current.top >= -0.5;\n      const isAtBottom = overflowRef.current.bottom >= -0.5;\n      const remainingScroll = el.scrollHeight - el.clientHeight;\n      const sign = dY < 0 ? -1 : 1;\n      const method = dY < 0 ? 'max' : 'min';\n      if (el.scrollHeight <= el.clientHeight) {\n        return;\n      }\n      if (!isAtTop && dY > 0 || !isAtBottom && dY < 0) {\n        e.preventDefault();\n        ReactDOM.flushSync(() => {\n          onChange(d => d + Math[method](dY, remainingScroll * sign));\n        });\n      } else if (/firefox/i.test(getUserAgent())) {\n        // Needed to propagate scrolling during momentum scrolling phase once\n        // it gets limited by the boundary. UX improvement, not critical.\n        el.scrollTop += dY;\n      }\n    }\n    const el = (scrollRef == null ? void 0 : scrollRef.current) || elements.floating;\n    if (open && el) {\n      el.addEventListener('wheel', onWheel);\n\n      // Wait for the position to be ready.\n      requestAnimationFrame(() => {\n        prevScrollTopRef.current = el.scrollTop;\n        if (overflowRef.current != null) {\n          initialOverflowRef.current = {\n            ...overflowRef.current\n          };\n        }\n      });\n      return () => {\n        prevScrollTopRef.current = null;\n        initialOverflowRef.current = null;\n        el.removeEventListener('wheel', onWheel);\n      };\n    }\n  }, [enabled, open, elements.floating, overflowRef, scrollRef, onChange]);\n  const floating = React.useMemo(() => ({\n    onKeyDown() {\n      controlledScrollingRef.current = true;\n    },\n    onWheel() {\n      controlledScrollingRef.current = false;\n    },\n    onPointerMove() {\n      controlledScrollingRef.current = false;\n    },\n    onScroll() {\n      const el = (scrollRef == null ? void 0 : scrollRef.current) || elements.floating;\n      if (!overflowRef.current || !el || !controlledScrollingRef.current) {\n        return;\n      }\n      if (prevScrollTopRef.current !== null) {\n        const scrollDiff = el.scrollTop - prevScrollTopRef.current;\n        if (overflowRef.current.bottom < -0.5 && scrollDiff < -1 || overflowRef.current.top < -0.5 && scrollDiff > 1) {\n          ReactDOM.flushSync(() => onChange(d => d + scrollDiff));\n        }\n      }\n\n      // [Firefox] Wait for the height change to have been applied.\n      requestAnimationFrame(() => {\n        prevScrollTopRef.current = el.scrollTop;\n      });\n    }\n  }), [elements.floating, onChange, overflowRef, scrollRef]);\n  return React.useMemo(() => enabled ? {\n    floating\n  } : {}, [enabled, floating]);\n}\n\nfunction isPointInPolygon(point, polygon) {\n  const [x, y] = point;\n  let isInside = false;\n  const length = polygon.length;\n  for (let i = 0, j = length - 1; i < length; j = i++) {\n    const [xi, yi] = polygon[i] || [0, 0];\n    const [xj, yj] = polygon[j] || [0, 0];\n    const intersect = yi >= y !== yj >= y && x <= (xj - xi) * (y - yi) / (yj - yi) + xi;\n    if (intersect) {\n      isInside = !isInside;\n    }\n  }\n  return isInside;\n}\nfunction isInside(point, rect) {\n  return point[0] >= rect.x && point[0] <= rect.x + rect.width && point[1] >= rect.y && point[1] <= rect.y + rect.height;\n}\n/**\n * Generates a safe polygon area that the user can traverse without closing the\n * floating element once leaving the reference element.\n * @see https://floating-ui.com/docs/useHover#safepolygon\n */\nfunction safePolygon(options) {\n  if (options === void 0) {\n    options = {};\n  }\n  const {\n    buffer = 0.5,\n    blockPointerEvents = false,\n    requireIntent = true\n  } = options;\n  let timeoutId;\n  let hasLanded = false;\n  let lastX = null;\n  let lastY = null;\n  let lastCursorTime = performance.now();\n  function getCursorSpeed(x, y) {\n    const currentTime = performance.now();\n    const elapsedTime = currentTime - lastCursorTime;\n    if (lastX === null || lastY === null || elapsedTime === 0) {\n      lastX = x;\n      lastY = y;\n      lastCursorTime = currentTime;\n      return null;\n    }\n    const deltaX = x - lastX;\n    const deltaY = y - lastY;\n    const distance = Math.sqrt(deltaX * deltaX + deltaY * deltaY);\n    const speed = distance / elapsedTime; // px / ms\n\n    lastX = x;\n    lastY = y;\n    lastCursorTime = currentTime;\n    return speed;\n  }\n  const fn = _ref => {\n    let {\n      x,\n      y,\n      placement,\n      elements,\n      onClose,\n      nodeId,\n      tree\n    } = _ref;\n    return function onMouseMove(event) {\n      function close() {\n        clearTimeout(timeoutId);\n        onClose();\n      }\n      clearTimeout(timeoutId);\n      if (!elements.domReference || !elements.floating || placement == null || x == null || y == null) {\n        return;\n      }\n      const {\n        clientX,\n        clientY\n      } = event;\n      const clientPoint = [clientX, clientY];\n      const target = getTarget(event);\n      const isLeave = event.type === 'mouseleave';\n      const isOverFloatingEl = contains(elements.floating, target);\n      const isOverReferenceEl = contains(elements.domReference, target);\n      const refRect = elements.domReference.getBoundingClientRect();\n      const rect = elements.floating.getBoundingClientRect();\n      const side = placement.split('-')[0];\n      const cursorLeaveFromRight = x > rect.right - rect.width / 2;\n      const cursorLeaveFromBottom = y > rect.bottom - rect.height / 2;\n      const isOverReferenceRect = isInside(clientPoint, refRect);\n      const isFloatingWider = rect.width > refRect.width;\n      const isFloatingTaller = rect.height > refRect.height;\n      const left = (isFloatingWider ? refRect : rect).left;\n      const right = (isFloatingWider ? refRect : rect).right;\n      const top = (isFloatingTaller ? refRect : rect).top;\n      const bottom = (isFloatingTaller ? refRect : rect).bottom;\n      if (isOverFloatingEl) {\n        hasLanded = true;\n        if (!isLeave) {\n          return;\n        }\n      }\n      if (isOverReferenceEl) {\n        hasLanded = false;\n      }\n      if (isOverReferenceEl && !isLeave) {\n        hasLanded = true;\n        return;\n      }\n\n      // Prevent overlapping floating element from being stuck in an open-close\n      // loop: https://github.com/floating-ui/floating-ui/issues/1910\n      if (isLeave && isElement(event.relatedTarget) && contains(elements.floating, event.relatedTarget)) {\n        return;\n      }\n\n      // If any nested child is open, abort.\n      if (tree && getChildren(tree.nodesRef.current, nodeId).some(_ref2 => {\n        let {\n          context\n        } = _ref2;\n        return context == null ? void 0 : context.open;\n      })) {\n        return;\n      }\n\n      // If the pointer is leaving from the opposite side, the \"buffer\" logic\n      // creates a point where the floating element remains open, but should be\n      // ignored.\n      // A constant of 1 handles floating point rounding errors.\n      if (side === 'top' && y >= refRect.bottom - 1 || side === 'bottom' && y <= refRect.top + 1 || side === 'left' && x >= refRect.right - 1 || side === 'right' && x <= refRect.left + 1) {\n        return close();\n      }\n\n      // Ignore when the cursor is within the rectangular trough between the\n      // two elements. Since the triangle is created from the cursor point,\n      // which can start beyond the ref element's edge, traversing back and\n      // forth from the ref to the floating element can cause it to close. This\n      // ensures it always remains open in that case.\n      let rectPoly = [];\n      switch (side) {\n        case 'top':\n          rectPoly = [[left, refRect.top + 1], [left, rect.bottom - 1], [right, rect.bottom - 1], [right, refRect.top + 1]];\n          break;\n        case 'bottom':\n          rectPoly = [[left, rect.top + 1], [left, refRect.bottom - 1], [right, refRect.bottom - 1], [right, rect.top + 1]];\n          break;\n        case 'left':\n          rectPoly = [[rect.right - 1, bottom], [rect.right - 1, top], [refRect.left + 1, top], [refRect.left + 1, bottom]];\n          break;\n        case 'right':\n          rectPoly = [[refRect.right - 1, bottom], [refRect.right - 1, top], [rect.left + 1, top], [rect.left + 1, bottom]];\n          break;\n      }\n      function getPolygon(_ref3) {\n        let [x, y] = _ref3;\n        switch (side) {\n          case 'top':\n            {\n              const cursorPointOne = [isFloatingWider ? x + buffer / 2 : cursorLeaveFromRight ? x + buffer * 4 : x - buffer * 4, y + buffer + 1];\n              const cursorPointTwo = [isFloatingWider ? x - buffer / 2 : cursorLeaveFromRight ? x + buffer * 4 : x - buffer * 4, y + buffer + 1];\n              const commonPoints = [[rect.left, cursorLeaveFromRight ? rect.bottom - buffer : isFloatingWider ? rect.bottom - buffer : rect.top], [rect.right, cursorLeaveFromRight ? isFloatingWider ? rect.bottom - buffer : rect.top : rect.bottom - buffer]];\n              return [cursorPointOne, cursorPointTwo, ...commonPoints];\n            }\n          case 'bottom':\n            {\n              const cursorPointOne = [isFloatingWider ? x + buffer / 2 : cursorLeaveFromRight ? x + buffer * 4 : x - buffer * 4, y - buffer];\n              const cursorPointTwo = [isFloatingWider ? x - buffer / 2 : cursorLeaveFromRight ? x + buffer * 4 : x - buffer * 4, y - buffer];\n              const commonPoints = [[rect.left, cursorLeaveFromRight ? rect.top + buffer : isFloatingWider ? rect.top + buffer : rect.bottom], [rect.right, cursorLeaveFromRight ? isFloatingWider ? rect.top + buffer : rect.bottom : rect.top + buffer]];\n              return [cursorPointOne, cursorPointTwo, ...commonPoints];\n            }\n          case 'left':\n            {\n              const cursorPointOne = [x + buffer + 1, isFloatingTaller ? y + buffer / 2 : cursorLeaveFromBottom ? y + buffer * 4 : y - buffer * 4];\n              const cursorPointTwo = [x + buffer + 1, isFloatingTaller ? y - buffer / 2 : cursorLeaveFromBottom ? y + buffer * 4 : y - buffer * 4];\n              const commonPoints = [[cursorLeaveFromBottom ? rect.right - buffer : isFloatingTaller ? rect.right - buffer : rect.left, rect.top], [cursorLeaveFromBottom ? isFloatingTaller ? rect.right - buffer : rect.left : rect.right - buffer, rect.bottom]];\n              return [...commonPoints, cursorPointOne, cursorPointTwo];\n            }\n          case 'right':\n            {\n              const cursorPointOne = [x - buffer, isFloatingTaller ? y + buffer / 2 : cursorLeaveFromBottom ? y + buffer * 4 : y - buffer * 4];\n              const cursorPointTwo = [x - buffer, isFloatingTaller ? y - buffer / 2 : cursorLeaveFromBottom ? y + buffer * 4 : y - buffer * 4];\n              const commonPoints = [[cursorLeaveFromBottom ? rect.left + buffer : isFloatingTaller ? rect.left + buffer : rect.right, rect.top], [cursorLeaveFromBottom ? isFloatingTaller ? rect.left + buffer : rect.right : rect.left + buffer, rect.bottom]];\n              return [cursorPointOne, cursorPointTwo, ...commonPoints];\n            }\n        }\n      }\n      if (isPointInPolygon([clientX, clientY], rectPoly)) {\n        return;\n      }\n      if (hasLanded && !isOverReferenceRect) {\n        return close();\n      }\n      if (!isLeave && requireIntent) {\n        const cursorSpeed = getCursorSpeed(event.clientX, event.clientY);\n        const cursorSpeedThreshold = 0.1;\n        if (cursorSpeed !== null && cursorSpeed < cursorSpeedThreshold) {\n          return close();\n        }\n      }\n      if (!isPointInPolygon([clientX, clientY], getPolygon([x, y]))) {\n        close();\n      } else if (!hasLanded && requireIntent) {\n        timeoutId = window.setTimeout(close, 40);\n      }\n    };\n  };\n  fn.__options = {\n    blockPointerEvents\n  };\n  return fn;\n}\n\nexport { Composite, CompositeItem, FloatingArrow, FloatingDelayGroup, FloatingFocusManager, FloatingList, FloatingNode, FloatingOverlay, FloatingPortal, FloatingTree, inner, safePolygon, useClick, useClientPoint, useDelayGroup, useDelayGroupContext, useDismiss, useFloating, useFloatingNodeId, useFloatingParentNodeId, useFloatingPortalNode, useFloatingRootContext, useFloatingTree, useFocus, useHover, useId, useInnerOffset, useInteractions, useListItem, useListNavigation, useMergeRefs, useRole, useTransitionStatus, useTransitionStyles, useTypeahead };\n","import { warnOnce } from '../../utils/warn-once.mjs';\n\nfunction createDOMMotionComponentProxy(componentFactory) {\n    if (typeof Proxy === \"undefined\") {\n        return componentFactory;\n    }\n    /**\n     * A cache of generated `motion` components, e.g `motion.div`, `motion.input` etc.\n     * Rather than generating them anew every render.\n     */\n    const componentCache = new Map();\n    const deprecatedFactoryFunction = (...args) => {\n        if (process.env.NODE_ENV !== \"production\") {\n            warnOnce(false, \"motion() is deprecated. Use motion.create() instead.\");\n        }\n        return componentFactory(...args);\n    };\n    return new Proxy(deprecatedFactoryFunction, {\n        /**\n         * Called when `motion` is referenced with a prop: `motion.div`, `motion.input` etc.\n         * The prop name is passed through as `key` and we can use that to generate a `motion`\n         * DOM component with that name.\n         */\n        get: (_target, key) => {\n            if (key === \"create\")\n                return componentFactory;\n            /**\n             * If this element doesn't exist in the component cache, create it and cache.\n             */\n            if (!componentCache.has(key)) {\n                componentCache.set(key, componentFactory(key));\n            }\n            return componentCache.get(key);\n        },\n    });\n}\n\nexport { createDOMMotionComponentProxy };\n","function isAnimationControls(v) {\n    return (v !== null &&\n        typeof v === \"object\" &&\n        typeof v.start === \"function\");\n}\n\nexport { isAnimationControls };\n","const isKeyframesTarget = (v) => {\n    return Array.isArray(v);\n};\n\nexport { isKeyframesTarget };\n","function shallowCompare(next, prev) {\n    if (!Array.isArray(prev))\n        return false;\n    const prevLength = prev.length;\n    if (prevLength !== next.length)\n        return false;\n    for (let i = 0; i < prevLength; i++) {\n        if (prev[i] !== next[i])\n            return false;\n    }\n    return true;\n}\n\nexport { shallowCompare };\n","/**\n * Decides if the supplied variable is variant label\n */\nfunction isVariantLabel(v) {\n    return typeof v === \"string\" || Array.isArray(v);\n}\n\nexport { isVariantLabel };\n","function getValueState(visualElement) {\n    const state = [{}, {}];\n    visualElement === null || visualElement === void 0 ? void 0 : visualElement.values.forEach((value, key) => {\n        state[0][key] = value.get();\n        state[1][key] = value.getVelocity();\n    });\n    return state;\n}\nfunction resolveVariantFromProps(props, definition, custom, visualElement) {\n    /**\n     * If the variant definition is a function, resolve.\n     */\n    if (typeof definition === \"function\") {\n        const [current, velocity] = getValueState(visualElement);\n        definition = definition(custom !== undefined ? custom : props.custom, current, velocity);\n    }\n    /**\n     * If the variant definition is a variant label, or\n     * the function returned a variant label, resolve.\n     */\n    if (typeof definition === \"string\") {\n        definition = props.variants && props.variants[definition];\n    }\n    /**\n     * At this point we've resolved both functions and variant labels,\n     * but the resolved variant label might itself have been a function.\n     * If so, resolve. This can only have returned a valid target object.\n     */\n    if (typeof definition === \"function\") {\n        const [current, velocity] = getValueState(visualElement);\n        definition = definition(custom !== undefined ? custom : props.custom, current, velocity);\n    }\n    return definition;\n}\n\nexport { resolveVariantFromProps };\n","import { resolveVariantFromProps } from './resolve-variants.mjs';\n\nfunction resolveVariant(visualElement, definition, custom) {\n    const props = visualElement.getProps();\n    return resolveVariantFromProps(props, definition, custom !== undefined ? custom : props.custom, visualElement);\n}\n\nexport { resolveVariant };\n","const variantPriorityOrder = [\n    \"animate\",\n    \"whileInView\",\n    \"whileFocus\",\n    \"whileHover\",\n    \"whileTap\",\n    \"whileDrag\",\n    \"exit\",\n];\nconst variantProps = [\"initial\", ...variantPriorityOrder];\n\nexport { variantPriorityOrder, variantProps };\n","/*#__NO_SIDE_EFFECTS__*/\nfunction memo(callback) {\n    let result;\n    return () => {\n        if (result === undefined)\n            result = callback();\n        return result;\n    };\n}\n\nexport { memo };\n","import { memo } from 'motion-utils';\n\nconst supportsScrollTimeline = memo(() => window.ScrollTimeline !== undefined);\n\nexport { supportsScrollTimeline };\n","import { supportsScrollTimeline } from '../../utils/supports/scroll-timeline.mjs';\n\nclass BaseGroupPlaybackControls {\n    constructor(animations) {\n        // Bound to accomodate common `return animation.stop` pattern\n        this.stop = () => this.runAll(\"stop\");\n        this.animations = animations.filter(Boolean);\n    }\n    get finished() {\n        // Support for new finished Promise and legacy thennable API\n        return Promise.all(this.animations.map((animation) => \"finished\" in animation ? animation.finished : animation));\n    }\n    /**\n     * TODO: Filter out cancelled or stopped animations before returning\n     */\n    getAll(propName) {\n        return this.animations[0][propName];\n    }\n    setAll(propName, newValue) {\n        for (let i = 0; i < this.animations.length; i++) {\n            this.animations[i][propName] = newValue;\n        }\n    }\n    attachTimeline(timeline, fallback) {\n        const subscriptions = this.animations.map((animation) => {\n            if (supportsScrollTimeline() && animation.attachTimeline) {\n                return animation.attachTimeline(timeline);\n            }\n            else if (typeof fallback === \"function\") {\n                return fallback(animation);\n            }\n        });\n        return () => {\n            subscriptions.forEach((cancel, i) => {\n                cancel && cancel();\n                this.animations[i].stop();\n            });\n        };\n    }\n    get time() {\n        return this.getAll(\"time\");\n    }\n    set time(time) {\n        this.setAll(\"time\", time);\n    }\n    get speed() {\n        return this.getAll(\"speed\");\n    }\n    set speed(speed) {\n        this.setAll(\"speed\", speed);\n    }\n    get startTime() {\n        return this.getAll(\"startTime\");\n    }\n    get duration() {\n        let max = 0;\n        for (let i = 0; i < this.animations.length; i++) {\n            max = Math.max(max, this.animations[i].duration);\n        }\n        return max;\n    }\n    runAll(methodName) {\n        this.animations.forEach((controls) => controls[methodName]());\n    }\n    flatten() {\n        this.runAll(\"flatten\");\n    }\n    play() {\n        this.runAll(\"play\");\n    }\n    pause() {\n        this.runAll(\"pause\");\n    }\n    cancel() {\n        this.runAll(\"cancel\");\n    }\n    complete() {\n        this.runAll(\"complete\");\n    }\n}\n\nexport { BaseGroupPlaybackControls };\n","import { BaseGroupPlaybackControls } from './BaseGroup.mjs';\n\n/**\n * TODO: This is a temporary class to support the legacy\n * thennable API\n */\nclass GroupPlaybackControls extends BaseGroupPlaybackControls {\n    then(onResolve, onReject) {\n        return Promise.all(this.animations).then(onResolve).catch(onReject);\n    }\n}\n\nexport { GroupPlaybackControls };\n","function getValueTransition(transition, key) {\n    return transition\n        ? transition[key] ||\n            transition[\"default\"] ||\n            transition\n        : undefined;\n}\n\nexport { getValueTransition };\n","/**\n * Implement a practical max duration for keyframe generation\n * to prevent infinite loops\n */\nconst maxGeneratorDuration = 20000;\nfunction calcGeneratorDuration(generator) {\n    let duration = 0;\n    const timeStep = 50;\n    let state = generator.next(duration);\n    while (!state.done && duration < maxGeneratorDuration) {\n        duration += timeStep;\n        state = generator.next(duration);\n    }\n    return duration >= maxGeneratorDuration ? Infinity : duration;\n}\n\nexport { calcGeneratorDuration, maxGeneratorDuration };\n","function isGenerator(type) {\n    return typeof type === \"function\";\n}\n\nexport { isGenerator };\n","function attachTimeline(animation, timeline) {\n    animation.timeline = timeline;\n    animation.onfinish = null;\n}\n\nexport { attachTimeline };\n","const isBezierDefinition = (easing) => Array.isArray(easing) && typeof easing[0] === \"number\";\n\nexport { isBezierDefinition };\n","/**\n * Add the ability for test suites to manually set support flags\n * to better test more environments.\n */\nconst supportsFlags = {\n    linearEasing: undefined,\n};\n\nexport { supportsFlags };\n","import { memo } from 'motion-utils';\nimport { supportsFlags } from './flags.mjs';\n\nfunction memoSupports(callback, supportsFlag) {\n    const memoized = memo(callback);\n    return () => { var _a; return (_a = supportsFlags[supportsFlag]) !== null && _a !== void 0 ? _a : memoized(); };\n}\n\nexport { memoSupports };\n","import { memoSupports } from './memo.mjs';\n\nconst supportsLinearEasing = /*@__PURE__*/ memoSupports(() => {\n    try {\n        document\n            .createElement(\"div\")\n            .animate({ opacity: 0 }, { easing: \"linear(0, 1)\" });\n    }\n    catch (e) {\n        return false;\n    }\n    return true;\n}, \"linearEasing\");\n\nexport { supportsLinearEasing };\n","/*\n  Progress within given range\n\n  Given a lower limit and an upper limit, we return the progress\n  (expressed as a number 0-1) represented by the given value, and\n  limit that progress to within 0-1.\n\n  @param [number]: Lower limit\n  @param [number]: Upper limit\n  @param [number]: Value to find progress within given range\n  @return [number]: Progress of value within range as expressed 0-1\n*/\n/*#__NO_SIDE_EFFECTS__*/\nconst progress = (from, to, value) => {\n    const toFromDifference = to - from;\n    return toFromDifference === 0 ? 1 : (value - from) / toFromDifference;\n};\n\nexport { progress };\n","import { progress } from 'motion-utils';\n\nconst generateLinearEasing = (easing, duration, // as milliseconds\nresolution = 10 // as milliseconds\n) => {\n    let points = \"\";\n    const numPoints = Math.max(Math.round(duration / resolution), 2);\n    for (let i = 0; i < numPoints; i++) {\n        points += easing(progress(0, numPoints - 1, i)) + \", \";\n    }\n    return `linear(${points.substring(0, points.length - 2)})`;\n};\n\nexport { generateLinearEasing };\n","import { isBezierDefinition } from '../../../utils/is-bezier-definition.mjs';\nimport { supportsLinearEasing } from '../../../utils/supports/linear-easing.mjs';\nimport { generateLinearEasing } from './linear.mjs';\n\nfunction isWaapiSupportedEasing(easing) {\n    return Boolean((typeof easing === \"function\" && supportsLinearEasing()) ||\n        !easing ||\n        (typeof easing === \"string\" &&\n            (easing in supportedWaapiEasing || supportsLinearEasing())) ||\n        isBezierDefinition(easing) ||\n        (Array.isArray(easing) && easing.every(isWaapiSupportedEasing)));\n}\nconst cubicBezierAsString = ([a, b, c, d]) => `cubic-bezier(${a}, ${b}, ${c}, ${d})`;\nconst supportedWaapiEasing = {\n    linear: \"linear\",\n    ease: \"ease\",\n    easeIn: \"ease-in\",\n    easeOut: \"ease-out\",\n    easeInOut: \"ease-in-out\",\n    circIn: /*@__PURE__*/ cubicBezierAsString([0, 0.65, 0.55, 1]),\n    circOut: /*@__PURE__*/ cubicBezierAsString([0.55, 0, 1, 0.45]),\n    backIn: /*@__PURE__*/ cubicBezierAsString([0.31, 0.01, 0.66, -0.59]),\n    backOut: /*@__PURE__*/ cubicBezierAsString([0.33, 1.53, 0.69, 0.99]),\n};\nfunction mapEasingToNativeEasing(easing, duration) {\n    if (!easing) {\n        return undefined;\n    }\n    else if (typeof easing === \"function\" && supportsLinearEasing()) {\n        return generateLinearEasing(easing, duration);\n    }\n    else if (isBezierDefinition(easing)) {\n        return cubicBezierAsString(easing);\n    }\n    else if (Array.isArray(easing)) {\n        return easing.map((segmentEasing) => mapEasingToNativeEasing(segmentEasing, duration) ||\n            supportedWaapiEasing.easeOut);\n    }\n    else {\n        return supportedWaapiEasing[easing];\n    }\n}\n\nexport { cubicBezierAsString, isWaapiSupportedEasing, mapEasingToNativeEasing, supportedWaapiEasing };\n","const isDragging = {\n    x: false,\n    y: false,\n};\nfunction isDragActive() {\n    return isDragging.x || isDragging.y;\n}\n\nexport { isDragActive, isDragging };\n","import { resolveElements } from '../../utils/resolve-elements.mjs';\n\nfunction setupGesture(elementOrSelector, options) {\n    const elements = resolveElements(elementOrSelector);\n    const gestureAbortController = new AbortController();\n    const eventOptions = {\n        passive: true,\n        ...options,\n        signal: gestureAbortController.signal,\n    };\n    const cancel = () => gestureAbortController.abort();\n    return [elements, eventOptions, cancel];\n}\n\nexport { setupGesture };\n","function resolveElements(elementOrSelector, scope, selectorCache) {\n    var _a;\n    if (elementOrSelector instanceof Element) {\n        return [elementOrSelector];\n    }\n    else if (typeof elementOrSelector === \"string\") {\n        let root = document;\n        if (scope) {\n            // TODO: Refactor to utils package\n            // invariant(\n            //     Boolean(scope.current),\n            //     \"Scope provided, but no element detected.\"\n            // )\n            root = scope.current;\n        }\n        const elements = (_a = selectorCache === null || selectorCache === void 0 ? void 0 : selectorCache[elementOrSelector]) !== null && _a !== void 0 ? _a : root.querySelectorAll(elementOrSelector);\n        return elements ? Array.from(elements) : [];\n    }\n    return Array.from(elementOrSelector);\n}\n\nexport { resolveElements };\n","import { isDragActive } from './drag/state/is-active.mjs';\nimport { setupGesture } from './utils/setup.mjs';\n\n/**\n * Filter out events that are not pointer events, or are triggering\n * while a Motion gesture is active.\n */\nfunction filterEvents(callback) {\n    return (event) => {\n        if (event.pointerType === \"touch\" || isDragActive())\n            return;\n        callback(event);\n    };\n}\n/**\n * Create a hover gesture. hover() is different to .addEventListener(\"pointerenter\")\n * in that it has an easier syntax, filters out polyfilled touch events, interoperates\n * with drag gestures, and automatically removes the \"pointerennd\" event listener when the hover ends.\n *\n * @public\n */\nfunction hover(elementOrSelector, onHoverStart, options = {}) {\n    const [elements, eventOptions, cancel] = setupGesture(elementOrSelector, options);\n    const onPointerEnter = filterEvents((enterEvent) => {\n        const { target } = enterEvent;\n        const onHoverEnd = onHoverStart(enterEvent);\n        if (typeof onHoverEnd !== \"function\" || !target)\n            return;\n        const onPointerLeave = filterEvents((leaveEvent) => {\n            onHoverEnd(leaveEvent);\n            target.removeEventListener(\"pointerleave\", onPointerLeave);\n        });\n        target.addEventListener(\"pointerleave\", onPointerLeave, eventOptions);\n    });\n    elements.forEach((element) => {\n        element.addEventListener(\"pointerenter\", onPointerEnter, eventOptions);\n    });\n    return cancel;\n}\n\nexport { hover };\n","/**\n * Recursively traverse up the tree to check whether the provided child node\n * is the parent or a descendant of it.\n *\n * @param parent - Element to find\n * @param child - Element to test against parent\n */\nconst isNodeOrChild = (parent, child) => {\n    if (!child) {\n        return false;\n    }\n    else if (parent === child) {\n        return true;\n    }\n    else {\n        return isNodeOrChild(parent, child.parentElement);\n    }\n};\n\nexport { isNodeOrChild };\n","const isPrimaryPointer = (event) => {\n    if (event.pointerType === \"mouse\") {\n        return typeof event.button !== \"number\" || event.button <= 0;\n    }\n    else {\n        /**\n         * isPrimary is true for all mice buttons, whereas every touch point\n         * is regarded as its own input. So subsequent concurrent touch points\n         * will be false.\n         *\n         * Specifically match against false here as incomplete versions of\n         * PointerEvents in very old browser might have it set as undefined.\n         */\n        return event.isPrimary !== false;\n    }\n};\n\nexport { isPrimaryPointer };\n","const focusableElements = new Set([\n    \"BUTTON\",\n    \"INPUT\",\n    \"SELECT\",\n    \"TEXTAREA\",\n    \"A\",\n]);\nfunction isElementKeyboardAccessible(element) {\n    return (focusableElements.has(element.tagName) ||\n        element.tabIndex !== -1);\n}\n\nexport { isElementKeyboardAccessible };\n","const isPressing = new WeakSet();\n\nexport { isPressing };\n","import { isPressing } from './state.mjs';\n\n/**\n * Filter out events that are not \"Enter\" keys.\n */\nfunction filterEvents(callback) {\n    return (event) => {\n        if (event.key !== \"Enter\")\n            return;\n        callback(event);\n    };\n}\nfunction firePointerEvent(target, type) {\n    target.dispatchEvent(new PointerEvent(\"pointer\" + type, { isPrimary: true, bubbles: true }));\n}\nconst enableKeyboardPress = (focusEvent, eventOptions) => {\n    const element = focusEvent.currentTarget;\n    if (!element)\n        return;\n    const handleKeydown = filterEvents(() => {\n        if (isPressing.has(element))\n            return;\n        firePointerEvent(element, \"down\");\n        const handleKeyup = filterEvents(() => {\n            firePointerEvent(element, \"up\");\n        });\n        const handleBlur = () => firePointerEvent(element, \"cancel\");\n        element.addEventListener(\"keyup\", handleKeyup, eventOptions);\n        element.addEventListener(\"blur\", handleBlur, eventOptions);\n    });\n    element.addEventListener(\"keydown\", handleKeydown, eventOptions);\n    /**\n     * Add an event listener that fires on blur to remove the keydown events.\n     */\n    element.addEventListener(\"blur\", () => element.removeEventListener(\"keydown\", handleKeydown), eventOptions);\n};\n\nexport { enableKeyboardPress };\n","import { isDragActive } from '../drag/state/is-active.mjs';\nimport { isNodeOrChild } from '../utils/is-node-or-child.mjs';\nimport { isPrimaryPointer } from '../utils/is-primary-pointer.mjs';\nimport { setupGesture } from '../utils/setup.mjs';\nimport { isElementKeyboardAccessible } from './utils/is-keyboard-accessible.mjs';\nimport { enableKeyboardPress } from './utils/keyboard.mjs';\nimport { isPressing } from './utils/state.mjs';\n\n/**\n * Filter out events that are not primary pointer events, or are triggering\n * while a Motion gesture is active.\n */\nfunction isValidPressEvent(event) {\n    return isPrimaryPointer(event) && !isDragActive();\n}\n/**\n * Create a press gesture.\n *\n * Press is different to `\"pointerdown\"`, `\"pointerup\"` in that it\n * automatically filters out secondary pointer events like right\n * click and multitouch.\n *\n * It also adds accessibility support for keyboards, where\n * an element with a press gesture will receive focus and\n *  trigger on Enter `\"keydown\"` and `\"keyup\"` events.\n *\n * This is different to a browser's `\"click\"` event, which does\n * respond to keyboards but only for the `\"click\"` itself, rather\n * than the press start and end/cancel. The element also needs\n * to be focusable for this to work, whereas a press gesture will\n * make an element focusable by default.\n *\n * @public\n */\nfunction press(elementOrSelector, onPressStart, options = {}) {\n    const [elements, eventOptions, cancelEvents] = setupGesture(elementOrSelector, options);\n    const startPress = (startEvent) => {\n        const element = startEvent.currentTarget;\n        if (!isValidPressEvent(startEvent) || isPressing.has(element))\n            return;\n        isPressing.add(element);\n        const onPressEnd = onPressStart(startEvent);\n        const onPointerEnd = (endEvent, success) => {\n            window.removeEventListener(\"pointerup\", onPointerUp);\n            window.removeEventListener(\"pointercancel\", onPointerCancel);\n            if (!isValidPressEvent(endEvent) || !isPressing.has(element)) {\n                return;\n            }\n            isPressing.delete(element);\n            if (typeof onPressEnd === \"function\") {\n                onPressEnd(endEvent, { success });\n            }\n        };\n        const onPointerUp = (upEvent) => {\n            onPointerEnd(upEvent, options.useGlobalTarget ||\n                isNodeOrChild(element, upEvent.target));\n        };\n        const onPointerCancel = (cancelEvent) => {\n            onPointerEnd(cancelEvent, false);\n        };\n        window.addEventListener(\"pointerup\", onPointerUp, eventOptions);\n        window.addEventListener(\"pointercancel\", onPointerCancel, eventOptions);\n    };\n    elements.forEach((element) => {\n        if (!isElementKeyboardAccessible(element) &&\n            element.getAttribute(\"tabindex\") === null) {\n            element.tabIndex = 0;\n        }\n        const target = options.useGlobalTarget ? window : element;\n        target.addEventListener(\"pointerdown\", startPress, eventOptions);\n        element.addEventListener(\"focus\", (event) => enableKeyboardPress(event, eventOptions), eventOptions);\n    });\n    return cancelEvents;\n}\n\nexport { press };\n","/**\n * Converts seconds to milliseconds\n *\n * @param seconds - Time in seconds.\n * @return milliseconds - Converted time in milliseconds.\n */\n/*#__NO_SIDE_EFFECTS__*/\nconst secondsToMilliseconds = (seconds) => seconds * 1000;\n/*#__NO_SIDE_EFFECTS__*/\nconst millisecondsToSeconds = (milliseconds) => milliseconds / 1000;\n\nexport { millisecondsToSeconds, secondsToMilliseconds };\n","/*#__NO_SIDE_EFFECTS__*/\nconst noop = (any) => any;\n\nexport { noop };\n","/**\n * Generate a list of every possible transform key.\n */\nconst transformPropOrder = [\n    \"transformPerspective\",\n    \"x\",\n    \"y\",\n    \"z\",\n    \"translateX\",\n    \"translateY\",\n    \"translateZ\",\n    \"scale\",\n    \"scaleX\",\n    \"scaleY\",\n    \"rotate\",\n    \"rotateX\",\n    \"rotateY\",\n    \"rotateZ\",\n    \"skew\",\n    \"skewX\",\n    \"skewY\",\n];\n/**\n * A quick lookup for transform props.\n */\nconst transformProps = new Set(transformPropOrder);\n\nexport { transformPropOrder, transformProps };\n","import { transformPropOrder } from './keys-transform.mjs';\n\nconst positionalKeys = new Set([\n    \"width\",\n    \"height\",\n    \"top\",\n    \"left\",\n    \"right\",\n    \"bottom\",\n    ...transformPropOrder,\n]);\n\nexport { positionalKeys };\n","import { isKeyframesTarget } from '../animation/utils/is-keyframes-target.mjs';\n\nconst isCustomValue = (v) => {\n    return Boolean(v && typeof v === \"object\" && v.mix && v.toValue);\n};\nconst resolveFinalValueInKeyframes = (v) => {\n    // TODO maybe throw if v.length - 1 is placeholder token?\n    return isKeyframesTarget(v) ? v[v.length - 1] || 0 : v;\n};\n\nexport { isCustomValue, resolveFinalValueInKeyframes };\n","import { MotionGlobalConfig } from '../utils/GlobalConfig.mjs';\nimport { createRenderStep } from './render-step.mjs';\n\nconst stepsOrder = [\n    \"read\", // Read\n    \"resolveKeyframes\", // Write/Read/Write/Read\n    \"update\", // Compute\n    \"preRender\", // Compute\n    \"render\", // Write\n    \"postRender\", // Compute\n];\nconst maxElapsed = 40;\nfunction createRenderBatcher(scheduleNextBatch, allowKeepAlive) {\n    let runNextFrame = false;\n    let useDefaultElapsed = true;\n    const state = {\n        delta: 0.0,\n        timestamp: 0.0,\n        isProcessing: false,\n    };\n    const flagRunNextFrame = () => (runNextFrame = true);\n    const steps = stepsOrder.reduce((acc, key) => {\n        acc[key] = createRenderStep(flagRunNextFrame);\n        return acc;\n    }, {});\n    const { read, resolveKeyframes, update, preRender, render, postRender } = steps;\n    const processBatch = () => {\n        const timestamp = MotionGlobalConfig.useManualTiming\n            ? state.timestamp\n            : performance.now();\n        runNextFrame = false;\n        state.delta = useDefaultElapsed\n            ? 1000 / 60\n            : Math.max(Math.min(timestamp - state.timestamp, maxElapsed), 1);\n        state.timestamp = timestamp;\n        state.isProcessing = true;\n        // Unrolled render loop for better per-frame performance\n        read.process(state);\n        resolveKeyframes.process(state);\n        update.process(state);\n        preRender.process(state);\n        render.process(state);\n        postRender.process(state);\n        state.isProcessing = false;\n        if (runNextFrame && allowKeepAlive) {\n            useDefaultElapsed = false;\n            scheduleNextBatch(processBatch);\n        }\n    };\n    const wake = () => {\n        runNextFrame = true;\n        useDefaultElapsed = true;\n        if (!state.isProcessing) {\n            scheduleNextBatch(processBatch);\n        }\n    };\n    const schedule = stepsOrder.reduce((acc, key) => {\n        const step = steps[key];\n        acc[key] = (process, keepAlive = false, immediate = false) => {\n            if (!runNextFrame)\n                wake();\n            return step.schedule(process, keepAlive, immediate);\n        };\n        return acc;\n    }, {});\n    const cancel = (process) => {\n        for (let i = 0; i < stepsOrder.length; i++) {\n            steps[stepsOrder[i]].cancel(process);\n        }\n    };\n    return { schedule, cancel, state, steps };\n}\n\nexport { createRenderBatcher, stepsOrder };\n","function createRenderStep(runNextFrame) {\n    /**\n     * We create and reuse two queues, one to queue jobs for the current frame\n     * and one for the next. We reuse to avoid triggering GC after x frames.\n     */\n    let thisFrame = new Set();\n    let nextFrame = new Set();\n    /**\n     * Track whether we're currently processing jobs in this step. This way\n     * we can decide whether to schedule new jobs for this frame or next.\n     */\n    let isProcessing = false;\n    let flushNextFrame = false;\n    /**\n     * A set of processes which were marked keepAlive when scheduled.\n     */\n    const toKeepAlive = new WeakSet();\n    let latestFrameData = {\n        delta: 0.0,\n        timestamp: 0.0,\n        isProcessing: false,\n    };\n    function triggerCallback(callback) {\n        if (toKeepAlive.has(callback)) {\n            step.schedule(callback);\n            runNextFrame();\n        }\n        callback(latestFrameData);\n    }\n    const step = {\n        /**\n         * Schedule a process to run on the next frame.\n         */\n        schedule: (callback, keepAlive = false, immediate = false) => {\n            const addToCurrentFrame = immediate && isProcessing;\n            const queue = addToCurrentFrame ? thisFrame : nextFrame;\n            if (keepAlive)\n                toKeepAlive.add(callback);\n            if (!queue.has(callback))\n                queue.add(callback);\n            return callback;\n        },\n        /**\n         * Cancel the provided callback from running on the next frame.\n         */\n        cancel: (callback) => {\n            nextFrame.delete(callback);\n            toKeepAlive.delete(callback);\n        },\n        /**\n         * Execute all schedule callbacks.\n         */\n        process: (frameData) => {\n            latestFrameData = frameData;\n            /**\n             * If we're already processing we've probably been triggered by a flushSync\n             * inside an existing process. Instead of executing, mark flushNextFrame\n             * as true and ensure we flush the following frame at the end of this one.\n             */\n            if (isProcessing) {\n                flushNextFrame = true;\n                return;\n            }\n            isProcessing = true;\n            [thisFrame, nextFrame] = [nextFrame, thisFrame];\n            // Execute this frame\n            thisFrame.forEach(triggerCallback);\n            // Clear the frame so no callbacks remain. This is to avoid\n            // memory leaks should this render step not run for a while.\n            thisFrame.clear();\n            isProcessing = false;\n            if (flushNextFrame) {\n                flushNextFrame = false;\n                step.process(frameData);\n            }\n        },\n    };\n    return step;\n}\n\nexport { createRenderStep };\n","import { noop } from 'motion-utils';\nimport { createRenderBatcher } from './batcher.mjs';\n\nconst { schedule: frame, cancel: cancelFrame, state: frameData, steps: frameSteps, } = createRenderBatcher(typeof requestAnimationFrame !== \"undefined\" ? requestAnimationFrame : noop, true);\n\nexport { cancelFrame, frame, frameData, frameSteps };\n","import { MotionGlobalConfig } from '../utils/GlobalConfig.mjs';\nimport { frameData } from './frame.mjs';\n\nlet now;\nfunction clearTime() {\n    now = undefined;\n}\n/**\n * An eventloop-synchronous alternative to performance.now().\n *\n * Ensures that time measurements remain consistent within a synchronous context.\n * Usually calling performance.now() twice within the same synchronous context\n * will return different values which isn't useful for animations when we're usually\n * trying to sync animations to the same frame.\n */\nconst time = {\n    now: () => {\n        if (now === undefined) {\n            time.set(frameData.isProcessing || MotionGlobalConfig.useManualTiming\n                ? frameData.timestamp\n                : performance.now());\n        }\n        return now;\n    },\n    set: (newTime) => {\n        now = newTime;\n        queueMicrotask(clearTime);\n    },\n};\n\nexport { time };\n","function addUniqueItem(arr, item) {\n    if (arr.indexOf(item) === -1)\n        arr.push(item);\n}\nfunction removeItem(arr, item) {\n    const index = arr.indexOf(item);\n    if (index > -1)\n        arr.splice(index, 1);\n}\n// Adapted from array-move\nfunction moveItem([...arr], fromIndex, toIndex) {\n    const startIndex = fromIndex < 0 ? arr.length + fromIndex : fromIndex;\n    if (startIndex >= 0 && startIndex < arr.length) {\n        const endIndex = toIndex < 0 ? arr.length + toIndex : toIndex;\n        const [item] = arr.splice(fromIndex, 1);\n        arr.splice(endIndex, 0, item);\n    }\n    return arr;\n}\n\nexport { addUniqueItem, moveItem, removeItem };\n","import { addUniqueItem, removeItem } from './array.mjs';\n\nclass SubscriptionManager {\n    constructor() {\n        this.subscriptions = [];\n    }\n    add(handler) {\n        addUniqueItem(this.subscriptions, handler);\n        return () => removeItem(this.subscriptions, handler);\n    }\n    notify(a, b, c) {\n        const numSubscriptions = this.subscriptions.length;\n        if (!numSubscriptions)\n            return;\n        if (numSubscriptions === 1) {\n            /**\n             * If there's only a single handler we can just call it without invoking a loop.\n             */\n            this.subscriptions[0](a, b, c);\n        }\n        else {\n            for (let i = 0; i < numSubscriptions; i++) {\n                /**\n                 * Check whether the handler exists before firing as it's possible\n                 * the subscriptions were modified during this loop running.\n                 */\n                const handler = this.subscriptions[i];\n                handler && handler(a, b, c);\n            }\n        }\n    }\n    getSize() {\n        return this.subscriptions.length;\n    }\n    clear() {\n        this.subscriptions.length = 0;\n    }\n}\n\nexport { SubscriptionManager };\n","/*\n  Convert velocity into velocity per second\n\n  @param [number]: Unit per frame\n  @param [number]: Frame duration in ms\n*/\nfunction velocityPerSecond(velocity, frameDuration) {\n    return frameDuration ? velocity * (1000 / frameDuration) : 0;\n}\n\nexport { velocityPerSecond };\n","import { time } from '../frameloop/sync-time.mjs';\nimport { SubscriptionManager } from '../utils/subscription-manager.mjs';\nimport { velocityPerSecond } from '../utils/velocity-per-second.mjs';\nimport { warnOnce } from '../utils/warn-once.mjs';\nimport { frame } from '../frameloop/frame.mjs';\n\n/**\n * Maximum time between the value of two frames, beyond which we\n * assume the velocity has since been 0.\n */\nconst MAX_VELOCITY_DELTA = 30;\nconst isFloat = (value) => {\n    return !isNaN(parseFloat(value));\n};\nconst collectMotionValues = {\n    current: undefined,\n};\n/**\n * `MotionValue` is used to track the state and velocity of motion values.\n *\n * @public\n */\nclass MotionValue {\n    /**\n     * @param init - The initiating value\n     * @param config - Optional configuration options\n     *\n     * -  `transformer`: A function to transform incoming values with.\n     *\n     * @internal\n     */\n    constructor(init, options = {}) {\n        /**\n         * This will be replaced by the build step with the latest version number.\n         * When MotionValues are provided to motion components, warn if versions are mixed.\n         */\n        this.version = \"11.18.2\";\n        /**\n         * Tracks whether this value can output a velocity. Currently this is only true\n         * if the value is numerical, but we might be able to widen the scope here and support\n         * other value types.\n         *\n         * @internal\n         */\n        this.canTrackVelocity = null;\n        /**\n         * An object containing a SubscriptionManager for each active event.\n         */\n        this.events = {};\n        this.updateAndNotify = (v, render = true) => {\n            const currentTime = time.now();\n            /**\n             * If we're updating the value during another frame or eventloop\n             * than the previous frame, then the we set the previous frame value\n             * to current.\n             */\n            if (this.updatedAt !== currentTime) {\n                this.setPrevFrameValue();\n            }\n            this.prev = this.current;\n            this.setCurrent(v);\n            // Update update subscribers\n            if (this.current !== this.prev && this.events.change) {\n                this.events.change.notify(this.current);\n            }\n            // Update render subscribers\n            if (render && this.events.renderRequest) {\n                this.events.renderRequest.notify(this.current);\n            }\n        };\n        this.hasAnimated = false;\n        this.setCurrent(init);\n        this.owner = options.owner;\n    }\n    setCurrent(current) {\n        this.current = current;\n        this.updatedAt = time.now();\n        if (this.canTrackVelocity === null && current !== undefined) {\n            this.canTrackVelocity = isFloat(this.current);\n        }\n    }\n    setPrevFrameValue(prevFrameValue = this.current) {\n        this.prevFrameValue = prevFrameValue;\n        this.prevUpdatedAt = this.updatedAt;\n    }\n    /**\n     * Adds a function that will be notified when the `MotionValue` is updated.\n     *\n     * It returns a function that, when called, will cancel the subscription.\n     *\n     * When calling `onChange` inside a React component, it should be wrapped with the\n     * `useEffect` hook. As it returns an unsubscribe function, this should be returned\n     * from the `useEffect` function to ensure you don't add duplicate subscribers..\n     *\n     * ```jsx\n     * export const MyComponent = () => {\n     *   const x = useMotionValue(0)\n     *   const y = useMotionValue(0)\n     *   const opacity = useMotionValue(1)\n     *\n     *   useEffect(() => {\n     *     function updateOpacity() {\n     *       const maxXY = Math.max(x.get(), y.get())\n     *       const newOpacity = transform(maxXY, [0, 100], [1, 0])\n     *       opacity.set(newOpacity)\n     *     }\n     *\n     *     const unsubscribeX = x.on(\"change\", updateOpacity)\n     *     const unsubscribeY = y.on(\"change\", updateOpacity)\n     *\n     *     return () => {\n     *       unsubscribeX()\n     *       unsubscribeY()\n     *     }\n     *   }, [])\n     *\n     *   return <motion.div style={{ x }} />\n     * }\n     * ```\n     *\n     * @param subscriber - A function that receives the latest value.\n     * @returns A function that, when called, will cancel this subscription.\n     *\n     * @deprecated\n     */\n    onChange(subscription) {\n        if (process.env.NODE_ENV !== \"production\") {\n            warnOnce(false, `value.onChange(callback) is deprecated. Switch to value.on(\"change\", callback).`);\n        }\n        return this.on(\"change\", subscription);\n    }\n    on(eventName, callback) {\n        if (!this.events[eventName]) {\n            this.events[eventName] = new SubscriptionManager();\n        }\n        const unsubscribe = this.events[eventName].add(callback);\n        if (eventName === \"change\") {\n            return () => {\n                unsubscribe();\n                /**\n                 * If we have no more change listeners by the start\n                 * of the next frame, stop active animations.\n                 */\n                frame.read(() => {\n                    if (!this.events.change.getSize()) {\n                        this.stop();\n                    }\n                });\n            };\n        }\n        return unsubscribe;\n    }\n    clearListeners() {\n        for (const eventManagers in this.events) {\n            this.events[eventManagers].clear();\n        }\n    }\n    /**\n     * Attaches a passive effect to the `MotionValue`.\n     *\n     * @internal\n     */\n    attach(passiveEffect, stopPassiveEffect) {\n        this.passiveEffect = passiveEffect;\n        this.stopPassiveEffect = stopPassiveEffect;\n    }\n    /**\n     * Sets the state of the `MotionValue`.\n     *\n     * @remarks\n     *\n     * ```jsx\n     * const x = useMotionValue(0)\n     * x.set(10)\n     * ```\n     *\n     * @param latest - Latest value to set.\n     * @param render - Whether to notify render subscribers. Defaults to `true`\n     *\n     * @public\n     */\n    set(v, render = true) {\n        if (!render || !this.passiveEffect) {\n            this.updateAndNotify(v, render);\n        }\n        else {\n            this.passiveEffect(v, this.updateAndNotify);\n        }\n    }\n    setWithVelocity(prev, current, delta) {\n        this.set(current);\n        this.prev = undefined;\n        this.prevFrameValue = prev;\n        this.prevUpdatedAt = this.updatedAt - delta;\n    }\n    /**\n     * Set the state of the `MotionValue`, stopping any active animations,\n     * effects, and resets velocity to `0`.\n     */\n    jump(v, endAnimation = true) {\n        this.updateAndNotify(v);\n        this.prev = v;\n        this.prevUpdatedAt = this.prevFrameValue = undefined;\n        endAnimation && this.stop();\n        if (this.stopPassiveEffect)\n            this.stopPassiveEffect();\n    }\n    /**\n     * Returns the latest state of `MotionValue`\n     *\n     * @returns - The latest state of `MotionValue`\n     *\n     * @public\n     */\n    get() {\n        if (collectMotionValues.current) {\n            collectMotionValues.current.push(this);\n        }\n        return this.current;\n    }\n    /**\n     * @public\n     */\n    getPrevious() {\n        return this.prev;\n    }\n    /**\n     * Returns the latest velocity of `MotionValue`\n     *\n     * @returns - The latest velocity of `MotionValue`. Returns `0` if the state is non-numerical.\n     *\n     * @public\n     */\n    getVelocity() {\n        const currentTime = time.now();\n        if (!this.canTrackVelocity ||\n            this.prevFrameValue === undefined ||\n            currentTime - this.updatedAt > MAX_VELOCITY_DELTA) {\n            return 0;\n        }\n        const delta = Math.min(this.updatedAt - this.prevUpdatedAt, MAX_VELOCITY_DELTA);\n        // Casts because of parseFloat's poor typing\n        return velocityPerSecond(parseFloat(this.current) -\n            parseFloat(this.prevFrameValue), delta);\n    }\n    /**\n     * Registers a new animation to control this `MotionValue`. Only one\n     * animation can drive a `MotionValue` at one time.\n     *\n     * ```jsx\n     * value.start()\n     * ```\n     *\n     * @param animation - A function that starts the provided animation\n     *\n     * @internal\n     */\n    start(startAnimation) {\n        this.stop();\n        return new Promise((resolve) => {\n            this.hasAnimated = true;\n            this.animation = startAnimation(resolve);\n            if (this.events.animationStart) {\n                this.events.animationStart.notify();\n            }\n        }).then(() => {\n            if (this.events.animationComplete) {\n                this.events.animationComplete.notify();\n            }\n            this.clearAnimation();\n        });\n    }\n    /**\n     * Stop the currently active animation.\n     *\n     * @public\n     */\n    stop() {\n        if (this.animation) {\n            this.animation.stop();\n            if (this.events.animationCancel) {\n                this.events.animationCancel.notify();\n            }\n        }\n        this.clearAnimation();\n    }\n    /**\n     * Returns `true` if this value is currently animating.\n     *\n     * @public\n     */\n    isAnimating() {\n        return !!this.animation;\n    }\n    clearAnimation() {\n        delete this.animation;\n    }\n    /**\n     * Destroy and clean up subscribers to this `MotionValue`.\n     *\n     * The `MotionValue` hooks like `useMotionValue` and `useTransform` automatically\n     * handle the lifecycle of the returned `MotionValue`, so this method is only necessary if you've manually\n     * created a `MotionValue` via the `motionValue` function.\n     *\n     * @public\n     */\n    destroy() {\n        this.clearListeners();\n        this.stop();\n        if (this.stopPassiveEffect) {\n            this.stopPassiveEffect();\n        }\n    }\n}\nfunction motionValue(init, options) {\n    return new MotionValue(init, options);\n}\n\nexport { MotionValue, collectMotionValues, motionValue };\n","import { resolveFinalValueInKeyframes } from '../../utils/resolve-value.mjs';\nimport { motionValue } from '../../value/index.mjs';\nimport { resolveVariant } from './resolve-dynamic-variants.mjs';\n\n/**\n * Set VisualElement's MotionValue, creating a new MotionValue for it if\n * it doesn't exist.\n */\nfunction setMotionValue(visualElement, key, value) {\n    if (visualElement.hasValue(key)) {\n        visualElement.getValue(key).set(value);\n    }\n    else {\n        visualElement.addValue(key, motionValue(value));\n    }\n}\nfunction setTarget(visualElement, definition) {\n    const resolved = resolveVariant(visualElement, definition);\n    let { transitionEnd = {}, transition = {}, ...target } = resolved || {};\n    target = { ...target, ...transitionEnd };\n    for (const key in target) {\n        const value = resolveFinalValueInKeyframes(target[key]);\n        setMotionValue(visualElement, key, value);\n    }\n}\n\nexport { setTarget };\n","const isMotionValue = (value) => Boolean(value && value.getVelocity);\n\nexport { isMotionValue };\n","import { isWillChangeMotionValue } from './is.mjs';\n\nfunction addValueToWillChange(visualElement, key) {\n    const willChange = visualElement.getValue(\"willChange\");\n    /**\n     * It could be that a user has set willChange to a regular MotionValue,\n     * in which case we can't add the value to it.\n     */\n    if (isWillChangeMotionValue(willChange)) {\n        return willChange.add(key);\n    }\n}\n\nexport { addValueToWillChange };\n","import { isMotionValue } from '../utils/is-motion-value.mjs';\n\nfunction isWillChangeMotionValue(value) {\n    return Boolean(isMotionValue(value) && value.add);\n}\n\nexport { isWillChangeMotionValue };\n","/**\n * Convert camelCase to dash-case properties.\n */\nconst camelToDash = (str) => str.replace(/([a-z])([A-Z])/gu, \"$1-$2\").toLowerCase();\n\nexport { camelToDash };\n","import { camelToDash } from '../../render/dom/utils/camel-to-dash.mjs';\n\nconst optimizedAppearDataId = \"framerAppearId\";\nconst optimizedAppearDataAttribute = \"data-\" + camelToDash(optimizedAppearDataId);\n\nexport { optimizedAppearDataAttribute, optimizedAppearDataId };\n","import { optimizedAppearDataAttribute } from './data-id.mjs';\n\nfunction getOptimisedAppearId(visualElement) {\n    return visualElement.props[optimizedAppearDataAttribute];\n}\n\nexport { getOptimisedAppearId };\n","const instantAnimationState = {\n    current: false,\n};\n\nexport { instantAnimationState };\n","import { noop } from 'motion-utils';\n\n/*\n  Bezier function generator\n  This has been modified from Gaëtan Renaudeau's BezierEasing\n  https://github.com/gre/bezier-easing/blob/master/src/index.js\n  https://github.com/gre/bezier-easing/blob/master/LICENSE\n  \n  I've removed the newtonRaphsonIterate algo because in benchmarking it\n  wasn't noticiably faster than binarySubdivision, indeed removing it\n  usually improved times, depending on the curve.\n  I also removed the lookup table, as for the added bundle size and loop we're\n  only cutting ~4 or so subdivision iterations. I bumped the max iterations up\n  to 12 to compensate and this still tended to be faster for no perceivable\n  loss in accuracy.\n  Usage\n    const easeOut = cubicBezier(.17,.67,.83,.67);\n    const x = easeOut(0.5); // returns 0.627...\n*/\n// Returns x(t) given t, x1, and x2, or y(t) given t, y1, and y2.\nconst calcBezier = (t, a1, a2) => (((1.0 - 3.0 * a2 + 3.0 * a1) * t + (3.0 * a2 - 6.0 * a1)) * t + 3.0 * a1) *\n    t;\nconst subdivisionPrecision = 0.0000001;\nconst subdivisionMaxIterations = 12;\nfunction binarySubdivide(x, lowerBound, upperBound, mX1, mX2) {\n    let currentX;\n    let currentT;\n    let i = 0;\n    do {\n        currentT = lowerBound + (upperBound - lowerBound) / 2.0;\n        currentX = calcBezier(currentT, mX1, mX2) - x;\n        if (currentX > 0.0) {\n            upperBound = currentT;\n        }\n        else {\n            lowerBound = currentT;\n        }\n    } while (Math.abs(currentX) > subdivisionPrecision &&\n        ++i < subdivisionMaxIterations);\n    return currentT;\n}\nfunction cubicBezier(mX1, mY1, mX2, mY2) {\n    // If this is a linear gradient, return linear easing\n    if (mX1 === mY1 && mX2 === mY2)\n        return noop;\n    const getTForX = (aX) => binarySubdivide(aX, 0, 1, mX1, mX2);\n    // If animation is at start/end, return t without easing\n    return (t) => t === 0 || t === 1 ? t : calcBezier(getTForX(t), mY1, mY2);\n}\n\nexport { cubicBezier };\n","// Accepts an easing function and returns a new one that outputs mirrored values for\n// the second half of the animation. Turns easeIn into easeInOut.\nconst mirrorEasing = (easing) => (p) => p <= 0.5 ? easing(2 * p) / 2 : (2 - easing(2 * (1 - p))) / 2;\n\nexport { mirrorEasing };\n","// Accepts an easing function and returns a new one that outputs reversed values.\n// Turns easeIn into easeOut.\nconst reverseEasing = (easing) => (p) => 1 - easing(1 - p);\n\nexport { reverseEasing };\n","import { cubicBezier } from './cubic-bezier.mjs';\nimport { mirrorEasing } from './modifiers/mirror.mjs';\nimport { reverseEasing } from './modifiers/reverse.mjs';\n\nconst backOut = /*@__PURE__*/ cubicBezier(0.33, 1.53, 0.69, 0.99);\nconst backIn = /*@__PURE__*/ reverseEasing(backOut);\nconst backInOut = /*@__PURE__*/ mirrorEasing(backIn);\n\nexport { backIn, backInOut, backOut };\n","import { backIn } from './back.mjs';\n\nconst anticipate = (p) => (p *= 2) < 1 ? 0.5 * backIn(p) : 0.5 * (2 - Math.pow(2, -10 * (p - 1)));\n\nexport { anticipate };\n","import { mirrorEasing } from './modifiers/mirror.mjs';\nimport { reverseEasing } from './modifiers/reverse.mjs';\n\nconst circIn = (p) => 1 - Math.sin(Math.acos(p));\nconst circOut = reverseEasing(circIn);\nconst circInOut = mirrorEasing(circIn);\n\nexport { circIn, circInOut, circOut };\n","/**\n * Check if the value is a zero value string like \"0px\" or \"0%\"\n */\nconst isZeroValueString = (v) => /^0[^.\\s]+$/u.test(v);\n\nexport { isZeroValueString };\n","import { isZeroValueString } from '../../utils/is-zero-value-string.mjs';\n\nfunction isNone(value) {\n    if (typeof value === \"number\") {\n        return value === 0;\n    }\n    else if (value !== null) {\n        return value === \"none\" || value === \"0\" || isZeroValueString(value);\n    }\n    else {\n        return true;\n    }\n}\n\nexport { isNone };\n","const clamp = (min, max, v) => {\n    if (v > max)\n        return max;\n    if (v < min)\n        return min;\n    return v;\n};\n\nexport { clamp };\n","import { clamp } from '../../../utils/clamp.mjs';\n\nconst number = {\n    test: (v) => typeof v === \"number\",\n    parse: parseFloat,\n    transform: (v) => v,\n};\nconst alpha = {\n    ...number,\n    transform: (v) => clamp(0, 1, v),\n};\nconst scale = {\n    ...number,\n    default: 1,\n};\n\nexport { alpha, number, scale };\n","// If this number is a decimal, make it just five decimal places\n// to avoid exponents\nconst sanitize = (v) => Math.round(v * 100000) / 100000;\n\nexport { sanitize };\n","const floatRegex = /-?(?:\\d+(?:\\.\\d+)?|\\.\\d+)/gu;\n\nexport { floatRegex };\n","const singleColorRegex = /^(?:#[\\da-f]{3,8}|(?:rgb|hsl)a?\\((?:-?[\\d.]+%?[,\\s]+){2}-?[\\d.]+%?\\s*(?:[,/]\\s*)?(?:\\b\\d+(?:\\.\\d+)?|\\.\\d+)?%?\\))$/iu;\n\nexport { singleColorRegex };\n","import { floatRegex } from '../utils/float-regex.mjs';\nimport { isNullish } from '../utils/is-nullish.mjs';\nimport { singleColorRegex } from '../utils/single-color-regex.mjs';\n\n/**\n * Returns true if the provided string is a color, ie rgba(0,0,0,0) or #000,\n * but false if a number or multiple colors\n */\nconst isColorString = (type, testProp) => (v) => {\n    return Boolean((typeof v === \"string\" &&\n        singleColorRegex.test(v) &&\n        v.startsWith(type)) ||\n        (testProp &&\n            !isNullish(v) &&\n            Object.prototype.hasOwnProperty.call(v, testProp)));\n};\nconst splitColor = (aName, bName, cName) => (v) => {\n    if (typeof v !== \"string\")\n        return v;\n    const [a, b, c, alpha] = v.match(floatRegex);\n    return {\n        [aName]: parseFloat(a),\n        [bName]: parseFloat(b),\n        [cName]: parseFloat(c),\n        alpha: alpha !== undefined ? parseFloat(alpha) : 1,\n    };\n};\n\nexport { isColorString, splitColor };\n","function isNullish(v) {\n    return v == null;\n}\n\nexport { isNullish };\n","import { clamp } from '../../../utils/clamp.mjs';\nimport { alpha, number } from '../numbers/index.mjs';\nimport { sanitize } from '../utils/sanitize.mjs';\nimport { isColorString, splitColor } from './utils.mjs';\n\nconst clampRgbUnit = (v) => clamp(0, 255, v);\nconst rgbUnit = {\n    ...number,\n    transform: (v) => Math.round(clampRgbUnit(v)),\n};\nconst rgba = {\n    test: /*@__PURE__*/ isColorString(\"rgb\", \"red\"),\n    parse: /*@__PURE__*/ splitColor(\"red\", \"green\", \"blue\"),\n    transform: ({ red, green, blue, alpha: alpha$1 = 1 }) => \"rgba(\" +\n        rgbUnit.transform(red) +\n        \", \" +\n        rgbUnit.transform(green) +\n        \", \" +\n        rgbUnit.transform(blue) +\n        \", \" +\n        sanitize(alpha.transform(alpha$1)) +\n        \")\",\n};\n\nexport { rgbUnit, rgba };\n","import { rgba } from './rgba.mjs';\nimport { isColorString } from './utils.mjs';\n\nfunction parseHex(v) {\n    let r = \"\";\n    let g = \"\";\n    let b = \"\";\n    let a = \"\";\n    // If we have 6 characters, ie #FF0000\n    if (v.length > 5) {\n        r = v.substring(1, 3);\n        g = v.substring(3, 5);\n        b = v.substring(5, 7);\n        a = v.substring(7, 9);\n        // Or we have 3 characters, ie #F00\n    }\n    else {\n        r = v.substring(1, 2);\n        g = v.substring(2, 3);\n        b = v.substring(3, 4);\n        a = v.substring(4, 5);\n        r += r;\n        g += g;\n        b += b;\n        a += a;\n    }\n    return {\n        red: parseInt(r, 16),\n        green: parseInt(g, 16),\n        blue: parseInt(b, 16),\n        alpha: a ? parseInt(a, 16) / 255 : 1,\n    };\n}\nconst hex = {\n    test: /*@__PURE__*/ isColorString(\"#\"),\n    parse: parseHex,\n    transform: rgba.transform,\n};\n\nexport { hex };\n","const createUnitType = (unit) => ({\n    test: (v) => typeof v === \"string\" && v.endsWith(unit) && v.split(\" \").length === 1,\n    parse: parseFloat,\n    transform: (v) => `${v}${unit}`,\n});\nconst degrees = /*@__PURE__*/ createUnitType(\"deg\");\nconst percent = /*@__PURE__*/ createUnitType(\"%\");\nconst px = /*@__PURE__*/ createUnitType(\"px\");\nconst vh = /*@__PURE__*/ createUnitType(\"vh\");\nconst vw = /*@__PURE__*/ createUnitType(\"vw\");\nconst progressPercentage = {\n    ...percent,\n    parse: (v) => percent.parse(v) / 100,\n    transform: (v) => percent.transform(v * 100),\n};\n\nexport { degrees, percent, progressPercentage, px, vh, vw };\n","import { alpha } from '../numbers/index.mjs';\nimport { percent } from '../numbers/units.mjs';\nimport { sanitize } from '../utils/sanitize.mjs';\nimport { isColorString, splitColor } from './utils.mjs';\n\nconst hsla = {\n    test: /*@__PURE__*/ isColorString(\"hsl\", \"hue\"),\n    parse: /*@__PURE__*/ splitColor(\"hue\", \"saturation\", \"lightness\"),\n    transform: ({ hue, saturation, lightness, alpha: alpha$1 = 1 }) => {\n        return (\"hsla(\" +\n            Math.round(hue) +\n            \", \" +\n            percent.transform(sanitize(saturation)) +\n            \", \" +\n            percent.transform(sanitize(lightness)) +\n            \", \" +\n            sanitize(alpha.transform(alpha$1)) +\n            \")\");\n    },\n};\n\nexport { hsla };\n","import { hex } from './hex.mjs';\nimport { hsla } from './hsla.mjs';\nimport { rgba } from './rgba.mjs';\n\nconst color = {\n    test: (v) => rgba.test(v) || hex.test(v) || hsla.test(v),\n    parse: (v) => {\n        if (rgba.test(v)) {\n            return rgba.parse(v);\n        }\n        else if (hsla.test(v)) {\n            return hsla.parse(v);\n        }\n        else {\n            return hex.parse(v);\n        }\n    },\n    transform: (v) => {\n        return typeof v === \"string\"\n            ? v\n            : v.hasOwnProperty(\"red\")\n                ? rgba.transform(v)\n                : hsla.transform(v);\n    },\n};\n\nexport { color };\n","const colorRegex = /(?:#[\\da-f]{3,8}|(?:rgb|hsl)a?\\((?:-?[\\d.]+%?[,\\s]+){2}-?[\\d.]+%?\\s*(?:[,/]\\s*)?(?:\\b\\d+(?:\\.\\d+)?|\\.\\d+)?%?\\))/giu;\n\nexport { colorRegex };\n","import { color } from '../color/index.mjs';\nimport { colorRegex } from '../utils/color-regex.mjs';\nimport { floatRegex } from '../utils/float-regex.mjs';\nimport { sanitize } from '../utils/sanitize.mjs';\n\nfunction test(v) {\n    var _a, _b;\n    return (isNaN(v) &&\n        typeof v === \"string\" &&\n        (((_a = v.match(floatRegex)) === null || _a === void 0 ? void 0 : _a.length) || 0) +\n            (((_b = v.match(colorRegex)) === null || _b === void 0 ? void 0 : _b.length) || 0) >\n            0);\n}\nconst NUMBER_TOKEN = \"number\";\nconst COLOR_TOKEN = \"color\";\nconst VAR_TOKEN = \"var\";\nconst VAR_FUNCTION_TOKEN = \"var(\";\nconst SPLIT_TOKEN = \"${}\";\n// this regex consists of the `singleCssVariableRegex|rgbHSLValueRegex|digitRegex`\nconst complexRegex = /var\\s*\\(\\s*--(?:[\\w-]+\\s*|[\\w-]+\\s*,(?:\\s*[^)(\\s]|\\s*\\((?:[^)(]|\\([^)(]*\\))*\\))+\\s*)\\)|#[\\da-f]{3,8}|(?:rgb|hsl)a?\\((?:-?[\\d.]+%?[,\\s]+){2}-?[\\d.]+%?\\s*(?:[,/]\\s*)?(?:\\b\\d+(?:\\.\\d+)?|\\.\\d+)?%?\\)|-?(?:\\d+(?:\\.\\d+)?|\\.\\d+)/giu;\nfunction analyseComplexValue(value) {\n    const originalValue = value.toString();\n    const values = [];\n    const indexes = {\n        color: [],\n        number: [],\n        var: [],\n    };\n    const types = [];\n    let i = 0;\n    const tokenised = originalValue.replace(complexRegex, (parsedValue) => {\n        if (color.test(parsedValue)) {\n            indexes.color.push(i);\n            types.push(COLOR_TOKEN);\n            values.push(color.parse(parsedValue));\n        }\n        else if (parsedValue.startsWith(VAR_FUNCTION_TOKEN)) {\n            indexes.var.push(i);\n            types.push(VAR_TOKEN);\n            values.push(parsedValue);\n        }\n        else {\n            indexes.number.push(i);\n            types.push(NUMBER_TOKEN);\n            values.push(parseFloat(parsedValue));\n        }\n        ++i;\n        return SPLIT_TOKEN;\n    });\n    const split = tokenised.split(SPLIT_TOKEN);\n    return { values, split, indexes, types };\n}\nfunction parseComplexValue(v) {\n    return analyseComplexValue(v).values;\n}\nfunction createTransformer(source) {\n    const { split, types } = analyseComplexValue(source);\n    const numSections = split.length;\n    return (v) => {\n        let output = \"\";\n        for (let i = 0; i < numSections; i++) {\n            output += split[i];\n            if (v[i] !== undefined) {\n                const type = types[i];\n                if (type === NUMBER_TOKEN) {\n                    output += sanitize(v[i]);\n                }\n                else if (type === COLOR_TOKEN) {\n                    output += color.transform(v[i]);\n                }\n                else {\n                    output += v[i];\n                }\n            }\n        }\n        return output;\n    };\n}\nconst convertNumbersToZero = (v) => typeof v === \"number\" ? 0 : v;\nfunction getAnimatableNone(v) {\n    const parsed = parseComplexValue(v);\n    const transformer = createTransformer(v);\n    return transformer(parsed.map(convertNumbersToZero));\n}\nconst complex = {\n    test,\n    parse: parseComplexValue,\n    createTransformer,\n    getAnimatableNone,\n};\n\nexport { analyseComplexValue, complex };\n","import { complex } from './index.mjs';\nimport { floatRegex } from '../utils/float-regex.mjs';\n\n/**\n * Properties that should default to 1 or 100%\n */\nconst maxDefaults = new Set([\"brightness\", \"contrast\", \"saturate\", \"opacity\"]);\nfunction applyDefaultFilter(v) {\n    const [name, value] = v.slice(0, -1).split(\"(\");\n    if (name === \"drop-shadow\")\n        return v;\n    const [number] = value.match(floatRegex) || [];\n    if (!number)\n        return v;\n    const unit = value.replace(number, \"\");\n    let defaultValue = maxDefaults.has(name) ? 1 : 0;\n    if (number !== value)\n        defaultValue *= 100;\n    return name + \"(\" + defaultValue + unit + \")\";\n}\nconst functionRegex = /\\b([a-z-]*)\\(.*?\\)/gu;\nconst filter = {\n    ...complex,\n    getAnimatableNone: (v) => {\n        const functions = v.match(functionRegex);\n        return functions ? functions.map(applyDefaultFilter).join(\" \") : v;\n    },\n};\n\nexport { filter };\n","import { px } from '../../../value/types/numbers/units.mjs';\n\nconst browserNumberValueTypes = {\n    // Border props\n    borderWidth: px,\n    borderTopWidth: px,\n    borderRightWidth: px,\n    borderBottomWidth: px,\n    borderLeftWidth: px,\n    borderRadius: px,\n    radius: px,\n    borderTopLeftRadius: px,\n    borderTopRightRadius: px,\n    borderBottomRightRadius: px,\n    borderBottomLeftRadius: px,\n    // Positioning props\n    width: px,\n    maxWidth: px,\n    height: px,\n    maxHeight: px,\n    top: px,\n    right: px,\n    bottom: px,\n    left: px,\n    // Spacing props\n    padding: px,\n    paddingTop: px,\n    paddingRight: px,\n    paddingBottom: px,\n    paddingLeft: px,\n    margin: px,\n    marginTop: px,\n    marginRight: px,\n    marginBottom: px,\n    marginLeft: px,\n    // Misc\n    backgroundPositionX: px,\n    backgroundPositionY: px,\n};\n\nexport { browserNumberValueTypes };\n","import { scale, alpha } from '../../../value/types/numbers/index.mjs';\nimport { degrees, px, progressPercentage } from '../../../value/types/numbers/units.mjs';\n\nconst transformValueTypes = {\n    rotate: degrees,\n    rotateX: degrees,\n    rotateY: degrees,\n    rotateZ: degrees,\n    scale,\n    scaleX: scale,\n    scaleY: scale,\n    scaleZ: scale,\n    skew: degrees,\n    skewX: degrees,\n    skewY: degrees,\n    distance: px,\n    translateX: px,\n    translateY: px,\n    translateZ: px,\n    x: px,\n    y: px,\n    z: px,\n    perspective: px,\n    transformPerspective: px,\n    opacity: alpha,\n    originX: progressPercentage,\n    originY: progressPercentage,\n    originZ: px,\n};\n\nexport { transformValueTypes };\n","import { number } from '../../../value/types/numbers/index.mjs';\n\nconst int = {\n    ...number,\n    transform: Math.round,\n};\n\nexport { int };\n","import { alpha } from '../../../value/types/numbers/index.mjs';\nimport { px } from '../../../value/types/numbers/units.mjs';\nimport { browserNumberValueTypes } from './number-browser.mjs';\nimport { transformValueTypes } from './transform.mjs';\nimport { int } from './type-int.mjs';\n\nconst numberValueTypes = {\n    ...browserNumberValueTypes,\n    ...transformValueTypes,\n    zIndex: int,\n    size: px,\n    // SVG\n    fillOpacity: alpha,\n    strokeOpacity: alpha,\n    numOctaves: int,\n};\n\nexport { numberValueTypes };\n","import { color } from '../../../value/types/color/index.mjs';\nimport { filter } from '../../../value/types/complex/filter.mjs';\nimport { numberValueTypes } from './number.mjs';\n\n/**\n * A map of default value types for common values\n */\nconst defaultValueTypes = {\n    ...numberValueTypes,\n    // Color props\n    color,\n    backgroundColor: color,\n    outlineColor: color,\n    fill: color,\n    stroke: color,\n    // Border props\n    borderColor: color,\n    borderTopColor: color,\n    borderRightColor: color,\n    borderBottomColor: color,\n    borderLeftColor: color,\n    filter,\n    WebkitFilter: filter,\n};\n/**\n * Gets the default ValueType for the provided value key\n */\nconst getDefaultValueType = (key) => defaultValueTypes[key];\n\nexport { defaultValueTypes, getDefaultValueType };\n","import { complex } from '../../../value/types/complex/index.mjs';\nimport { filter } from '../../../value/types/complex/filter.mjs';\nimport { getDefaultValueType } from './defaults.mjs';\n\nfunction getAnimatableNone(key, value) {\n    let defaultValueType = getDefaultValueType(key);\n    if (defaultValueType !== filter)\n        defaultValueType = complex;\n    // If value is not recognised as animatable, ie \"none\", create an animatable version origin based on the target\n    return defaultValueType.getAnimatableNone\n        ? defaultValueType.getAnimatableNone(value)\n        : undefined;\n}\n\nexport { getAnimatableNone };\n","import { analyseComplexValue } from '../../../value/types/complex/index.mjs';\nimport { getAnimatableNone } from '../../dom/value-types/animatable-none.mjs';\n\n/**\n * If we encounter keyframes like \"none\" or \"0\" and we also have keyframes like\n * \"#fff\" or \"200px 200px\" we want to find a keyframe to serve as a template for\n * the \"none\" keyframes. In this case \"#fff\" or \"200px 200px\" - then these get turned into\n * zero equivalents, i.e. \"#fff0\" or \"0px 0px\".\n */\nconst invalidTemplates = new Set([\"auto\", \"none\", \"0\"]);\nfunction makeNoneKeyframesAnimatable(unresolvedKeyframes, noneKeyframeIndexes, name) {\n    let i = 0;\n    let animatableTemplate = undefined;\n    while (i < unresolvedKeyframes.length && !animatableTemplate) {\n        const keyframe = unresolvedKeyframes[i];\n        if (typeof keyframe === \"string\" &&\n            !invalidTemplates.has(keyframe) &&\n            analyseComplexValue(keyframe).values.length) {\n            animatableTemplate = unresolvedKeyframes[i];\n        }\n        i++;\n    }\n    if (animatableTemplate && name) {\n        for (const noneIndex of noneKeyframeIndexes) {\n            unresolvedKeyframes[noneIndex] = getAnimatableNone(name, animatableTemplate);\n        }\n    }\n}\n\nexport { makeNoneKeyframesAnimatable };\n","import { number } from '../../../value/types/numbers/index.mjs';\nimport { px } from '../../../value/types/numbers/units.mjs';\nimport { transformPropOrder } from '../../html/utils/keys-transform.mjs';\n\nconst isNumOrPxType = (v) => v === number || v === px;\nconst getPosFromMatrix = (matrix, pos) => parseFloat(matrix.split(\", \")[pos]);\nconst getTranslateFromMatrix = (pos2, pos3) => (_bbox, { transform }) => {\n    if (transform === \"none\" || !transform)\n        return 0;\n    const matrix3d = transform.match(/^matrix3d\\((.+)\\)$/u);\n    if (matrix3d) {\n        return getPosFromMatrix(matrix3d[1], pos3);\n    }\n    else {\n        const matrix = transform.match(/^matrix\\((.+)\\)$/u);\n        if (matrix) {\n            return getPosFromMatrix(matrix[1], pos2);\n        }\n        else {\n            return 0;\n        }\n    }\n};\nconst transformKeys = new Set([\"x\", \"y\", \"z\"]);\nconst nonTranslationalTransformKeys = transformPropOrder.filter((key) => !transformKeys.has(key));\nfunction removeNonTranslationalTransform(visualElement) {\n    const removedTransforms = [];\n    nonTranslationalTransformKeys.forEach((key) => {\n        const value = visualElement.getValue(key);\n        if (value !== undefined) {\n            removedTransforms.push([key, value.get()]);\n            value.set(key.startsWith(\"scale\") ? 1 : 0);\n        }\n    });\n    return removedTransforms;\n}\nconst positionalValues = {\n    // Dimensions\n    width: ({ x }, { paddingLeft = \"0\", paddingRight = \"0\" }) => x.max - x.min - parseFloat(paddingLeft) - parseFloat(paddingRight),\n    height: ({ y }, { paddingTop = \"0\", paddingBottom = \"0\" }) => y.max - y.min - parseFloat(paddingTop) - parseFloat(paddingBottom),\n    top: (_bbox, { top }) => parseFloat(top),\n    left: (_bbox, { left }) => parseFloat(left),\n    bottom: ({ y }, { top }) => parseFloat(top) + (y.max - y.min),\n    right: ({ x }, { left }) => parseFloat(left) + (x.max - x.min),\n    // Transform\n    x: getTranslateFromMatrix(4, 13),\n    y: getTranslateFromMatrix(5, 14),\n};\n// Alias translate longform names\npositionalValues.translateX = positionalValues.x;\npositionalValues.translateY = positionalValues.y;\n\nexport { isNumOrPxType, positionalValues, removeNonTranslationalTransform };\n","import { removeNonTranslationalTransform } from '../dom/utils/unit-conversion.mjs';\nimport { frame } from '../../frameloop/frame.mjs';\n\nconst toResolve = new Set();\nlet isScheduled = false;\nlet anyNeedsMeasurement = false;\nfunction measureAllKeyframes() {\n    if (anyNeedsMeasurement) {\n        const resolversToMeasure = Array.from(toResolve).filter((resolver) => resolver.needsMeasurement);\n        const elementsToMeasure = new Set(resolversToMeasure.map((resolver) => resolver.element));\n        const transformsToRestore = new Map();\n        /**\n         * Write pass\n         * If we're measuring elements we want to remove bounding box-changing transforms.\n         */\n        elementsToMeasure.forEach((element) => {\n            const removedTransforms = removeNonTranslationalTransform(element);\n            if (!removedTransforms.length)\n                return;\n            transformsToRestore.set(element, removedTransforms);\n            element.render();\n        });\n        // Read\n        resolversToMeasure.forEach((resolver) => resolver.measureInitialState());\n        // Write\n        elementsToMeasure.forEach((element) => {\n            element.render();\n            const restore = transformsToRestore.get(element);\n            if (restore) {\n                restore.forEach(([key, value]) => {\n                    var _a;\n                    (_a = element.getValue(key)) === null || _a === void 0 ? void 0 : _a.set(value);\n                });\n            }\n        });\n        // Read\n        resolversToMeasure.forEach((resolver) => resolver.measureEndState());\n        // Write\n        resolversToMeasure.forEach((resolver) => {\n            if (resolver.suspendedScrollY !== undefined) {\n                window.scrollTo(0, resolver.suspendedScrollY);\n            }\n        });\n    }\n    anyNeedsMeasurement = false;\n    isScheduled = false;\n    toResolve.forEach((resolver) => resolver.complete());\n    toResolve.clear();\n}\nfunction readAllKeyframes() {\n    toResolve.forEach((resolver) => {\n        resolver.readKeyframes();\n        if (resolver.needsMeasurement) {\n            anyNeedsMeasurement = true;\n        }\n    });\n}\nfunction flushKeyframeResolvers() {\n    readAllKeyframes();\n    measureAllKeyframes();\n}\nclass KeyframeResolver {\n    constructor(unresolvedKeyframes, onComplete, name, motionValue, element, isAsync = false) {\n        /**\n         * Track whether this resolver has completed. Once complete, it never\n         * needs to attempt keyframe resolution again.\n         */\n        this.isComplete = false;\n        /**\n         * Track whether this resolver is async. If it is, it'll be added to the\n         * resolver queue and flushed in the next frame. Resolvers that aren't going\n         * to trigger read/write thrashing don't need to be async.\n         */\n        this.isAsync = false;\n        /**\n         * Track whether this resolver needs to perform a measurement\n         * to resolve its keyframes.\n         */\n        this.needsMeasurement = false;\n        /**\n         * Track whether this resolver is currently scheduled to resolve\n         * to allow it to be cancelled and resumed externally.\n         */\n        this.isScheduled = false;\n        this.unresolvedKeyframes = [...unresolvedKeyframes];\n        this.onComplete = onComplete;\n        this.name = name;\n        this.motionValue = motionValue;\n        this.element = element;\n        this.isAsync = isAsync;\n    }\n    scheduleResolve() {\n        this.isScheduled = true;\n        if (this.isAsync) {\n            toResolve.add(this);\n            if (!isScheduled) {\n                isScheduled = true;\n                frame.read(readAllKeyframes);\n                frame.resolveKeyframes(measureAllKeyframes);\n            }\n        }\n        else {\n            this.readKeyframes();\n            this.complete();\n        }\n    }\n    readKeyframes() {\n        const { unresolvedKeyframes, name, element, motionValue } = this;\n        /**\n         * If a keyframe is null, we hydrate it either by reading it from\n         * the instance, or propagating from previous keyframes.\n         */\n        for (let i = 0; i < unresolvedKeyframes.length; i++) {\n            if (unresolvedKeyframes[i] === null) {\n                /**\n                 * If the first keyframe is null, we need to find its value by sampling the element\n                 */\n                if (i === 0) {\n                    const currentValue = motionValue === null || motionValue === void 0 ? void 0 : motionValue.get();\n                    const finalKeyframe = unresolvedKeyframes[unresolvedKeyframes.length - 1];\n                    if (currentValue !== undefined) {\n                        unresolvedKeyframes[0] = currentValue;\n                    }\n                    else if (element && name) {\n                        const valueAsRead = element.readValue(name, finalKeyframe);\n                        if (valueAsRead !== undefined && valueAsRead !== null) {\n                            unresolvedKeyframes[0] = valueAsRead;\n                        }\n                    }\n                    if (unresolvedKeyframes[0] === undefined) {\n                        unresolvedKeyframes[0] = finalKeyframe;\n                    }\n                    if (motionValue && currentValue === undefined) {\n                        motionValue.set(unresolvedKeyframes[0]);\n                    }\n                }\n                else {\n                    unresolvedKeyframes[i] = unresolvedKeyframes[i - 1];\n                }\n            }\n        }\n    }\n    setFinalKeyframe() { }\n    measureInitialState() { }\n    renderEndStyles() { }\n    measureEndState() { }\n    complete() {\n        this.isComplete = true;\n        this.onComplete(this.unresolvedKeyframes, this.finalKeyframe);\n        toResolve.delete(this);\n    }\n    cancel() {\n        if (!this.isComplete) {\n            this.isScheduled = false;\n            toResolve.delete(this);\n        }\n    }\n    resume() {\n        if (!this.isComplete)\n            this.scheduleResolve();\n    }\n}\n\nexport { KeyframeResolver, flushKeyframeResolvers };\n","import { noop } from './noop.mjs';\n\nlet warning = noop;\nlet invariant = noop;\nif (process.env.NODE_ENV !== \"production\") {\n    warning = (check, message) => {\n        if (!check && typeof console !== \"undefined\") {\n            console.warn(message);\n        }\n    };\n    invariant = (check, message) => {\n        if (!check) {\n            throw new Error(message);\n        }\n    };\n}\n\nexport { invariant, warning };\n","/**\n * Check if value is a numerical string, ie a string that is purely a number eg \"100\" or \"-100.1\"\n */\nconst isNumericalString = (v) => /^-?(?:\\d+(?:\\.\\d+)?|\\.\\d+)$/u.test(v);\n\nexport { isNumericalString };\n","const checkStringStartsWith = (token) => (key) => typeof key === \"string\" && key.startsWith(token);\nconst isCSSVariableName = \n/*@__PURE__*/ checkStringStartsWith(\"--\");\nconst startsAsVariableToken = \n/*@__PURE__*/ checkStringStartsWith(\"var(--\");\nconst isCSSVariableToken = (value) => {\n    const startsWithToken = startsAsVariableToken(value);\n    if (!startsWithToken)\n        return false;\n    // Ensure any comments are stripped from the value as this can harm performance of the regex.\n    return singleCssVariableRegex.test(value.split(\"/*\")[0].trim());\n};\nconst singleCssVariableRegex = /var\\(--(?:[\\w-]+\\s*|[\\w-]+\\s*,(?:\\s*[^)(\\s]|\\s*\\((?:[^)(]|\\([^)(]*\\))*\\))+\\s*)\\)$/iu;\n\nexport { isCSSVariableName, isCSSVariableToken };\n","import { invariant } from 'motion-utils';\nimport { isNumericalString } from '../../../utils/is-numerical-string.mjs';\nimport { isCSSVariableToken } from './is-css-variable.mjs';\n\n/**\n * Parse Framer's special CSS variable format into a CSS token and a fallback.\n *\n * ```\n * `var(--foo, #fff)` => [`--foo`, '#fff']\n * ```\n *\n * @param current\n */\nconst splitCSSVariableRegex = \n// eslint-disable-next-line redos-detector/no-unsafe-regex -- false positive, as it can match a lot of words\n/^var\\(--(?:([\\w-]+)|([\\w-]+), ?([a-zA-Z\\d ()%#.,-]+))\\)/u;\nfunction parseCSSVariable(current) {\n    const match = splitCSSVariableRegex.exec(current);\n    if (!match)\n        return [,];\n    const [, token1, token2, fallback] = match;\n    return [`--${token1 !== null && token1 !== void 0 ? token1 : token2}`, fallback];\n}\nconst maxDepth = 4;\nfunction getVariableValue(current, element, depth = 1) {\n    invariant(depth <= maxDepth, `Max CSS variable fallback depth detected in property \"${current}\". This may indicate a circular fallback dependency.`);\n    const [token, fallback] = parseCSSVariable(current);\n    // No CSS variable detected\n    if (!token)\n        return;\n    // Attempt to read this CSS variable off the element\n    const resolved = window.getComputedStyle(element).getPropertyValue(token);\n    if (resolved) {\n        const trimmed = resolved.trim();\n        return isNumericalString(trimmed) ? parseFloat(trimmed) : trimmed;\n    }\n    return isCSSVariableToken(fallback)\n        ? getVariableValue(fallback, element, depth + 1)\n        : fallback;\n}\n\nexport { getVariableValue, parseCSSVariable };\n","/**\n * Tests a provided value against a ValueType\n */\nconst testValueType = (v) => (type) => type.test(v);\n\nexport { testValueType };\n","import { number } from '../../../value/types/numbers/index.mjs';\nimport { px, percent, degrees, vw, vh } from '../../../value/types/numbers/units.mjs';\nimport { testValueType } from './test.mjs';\nimport { auto } from './type-auto.mjs';\n\n/**\n * A list of value types commonly used for dimensions\n */\nconst dimensionValueTypes = [number, px, percent, degrees, vw, vh, auto];\n/**\n * Tests a dimensional value against the list of dimension ValueTypes\n */\nconst findDimensionValueType = (v) => dimensionValueTypes.find(testValueType(v));\n\nexport { dimensionValueTypes, findDimensionValueType };\n","/**\n * ValueType for \"auto\"\n */\nconst auto = {\n    test: (v) => v === \"auto\",\n    parse: (v) => v,\n};\n\nexport { auto };\n","import { isNone } from '../../animation/utils/is-none.mjs';\nimport { positionalKeys } from '../html/utils/keys-position.mjs';\nimport { makeNoneKeyframesAnimatable } from '../html/utils/make-none-animatable.mjs';\nimport { KeyframeResolver } from '../utils/KeyframesResolver.mjs';\nimport { getVariableValue } from './utils/css-variables-conversion.mjs';\nimport { isCSSVariableToken } from './utils/is-css-variable.mjs';\nimport { isNumOrPxType, positionalValues } from './utils/unit-conversion.mjs';\nimport { findDimensionValueType } from './value-types/dimensions.mjs';\n\nclass DOMKeyframesResolver extends KeyframeResolver {\n    constructor(unresolvedKeyframes, onComplete, name, motionValue, element) {\n        super(unresolvedKeyframes, onComplete, name, motionValue, element, true);\n    }\n    readKeyframes() {\n        const { unresolvedKeyframes, element, name } = this;\n        if (!element || !element.current)\n            return;\n        super.readKeyframes();\n        /**\n         * If any keyframe is a CSS variable, we need to find its value by sampling the element\n         */\n        for (let i = 0; i < unresolvedKeyframes.length; i++) {\n            let keyframe = unresolvedKeyframes[i];\n            if (typeof keyframe === \"string\") {\n                keyframe = keyframe.trim();\n                if (isCSSVariableToken(keyframe)) {\n                    const resolved = getVariableValue(keyframe, element.current);\n                    if (resolved !== undefined) {\n                        unresolvedKeyframes[i] = resolved;\n                    }\n                    if (i === unresolvedKeyframes.length - 1) {\n                        this.finalKeyframe = keyframe;\n                    }\n                }\n            }\n        }\n        /**\n         * Resolve \"none\" values. We do this potentially twice - once before and once after measuring keyframes.\n         * This could be seen as inefficient but it's a trade-off to avoid measurements in more situations, which\n         * have a far bigger performance impact.\n         */\n        this.resolveNoneKeyframes();\n        /**\n         * Check to see if unit type has changed. If so schedule jobs that will\n         * temporarily set styles to the destination keyframes.\n         * Skip if we have more than two keyframes or this isn't a positional value.\n         * TODO: We can throw if there are multiple keyframes and the value type changes.\n         */\n        if (!positionalKeys.has(name) || unresolvedKeyframes.length !== 2) {\n            return;\n        }\n        const [origin, target] = unresolvedKeyframes;\n        const originType = findDimensionValueType(origin);\n        const targetType = findDimensionValueType(target);\n        /**\n         * Either we don't recognise these value types or we can animate between them.\n         */\n        if (originType === targetType)\n            return;\n        /**\n         * If both values are numbers or pixels, we can animate between them by\n         * converting them to numbers.\n         */\n        if (isNumOrPxType(originType) && isNumOrPxType(targetType)) {\n            for (let i = 0; i < unresolvedKeyframes.length; i++) {\n                const value = unresolvedKeyframes[i];\n                if (typeof value === \"string\") {\n                    unresolvedKeyframes[i] = parseFloat(value);\n                }\n            }\n        }\n        else {\n            /**\n             * Else, the only way to resolve this is by measuring the element.\n             */\n            this.needsMeasurement = true;\n        }\n    }\n    resolveNoneKeyframes() {\n        const { unresolvedKeyframes, name } = this;\n        const noneKeyframeIndexes = [];\n        for (let i = 0; i < unresolvedKeyframes.length; i++) {\n            if (isNone(unresolvedKeyframes[i])) {\n                noneKeyframeIndexes.push(i);\n            }\n        }\n        if (noneKeyframeIndexes.length) {\n            makeNoneKeyframesAnimatable(unresolvedKeyframes, noneKeyframeIndexes, name);\n        }\n    }\n    measureInitialState() {\n        const { element, unresolvedKeyframes, name } = this;\n        if (!element || !element.current)\n            return;\n        if (name === \"height\") {\n            this.suspendedScrollY = window.pageYOffset;\n        }\n        this.measuredOrigin = positionalValues[name](element.measureViewportBox(), window.getComputedStyle(element.current));\n        unresolvedKeyframes[0] = this.measuredOrigin;\n        // Set final key frame to measure after next render\n        const measureKeyframe = unresolvedKeyframes[unresolvedKeyframes.length - 1];\n        if (measureKeyframe !== undefined) {\n            element.getValue(name, measureKeyframe).jump(measureKeyframe, false);\n        }\n    }\n    measureEndState() {\n        var _a;\n        const { element, name, unresolvedKeyframes } = this;\n        if (!element || !element.current)\n            return;\n        const value = element.getValue(name);\n        value && value.jump(this.measuredOrigin, false);\n        const finalKeyframeIndex = unresolvedKeyframes.length - 1;\n        const finalKeyframe = unresolvedKeyframes[finalKeyframeIndex];\n        unresolvedKeyframes[finalKeyframeIndex] = positionalValues[name](element.measureViewportBox(), window.getComputedStyle(element.current));\n        if (finalKeyframe !== null && this.finalKeyframe === undefined) {\n            this.finalKeyframe = finalKeyframe;\n        }\n        // If we removed transform values, reapply them before the next render\n        if ((_a = this.removedTransforms) === null || _a === void 0 ? void 0 : _a.length) {\n            this.removedTransforms.forEach(([unsetTransformName, unsetTransformValue]) => {\n                element\n                    .getValue(unsetTransformName)\n                    .set(unsetTransformValue);\n            });\n        }\n        this.resolveNoneKeyframes();\n    }\n}\n\nexport { DOMKeyframesResolver };\n","import { complex } from '../../value/types/complex/index.mjs';\n\n/**\n * Check if a value is animatable. Examples:\n *\n * ✅: 100, \"100px\", \"#fff\"\n * ❌: \"block\", \"url(2.jpg)\"\n * @param value\n *\n * @internal\n */\nconst isAnimatable = (value, name) => {\n    // If the list of keys tat might be non-animatable grows, replace with Set\n    if (name === \"zIndex\")\n        return false;\n    // If it's a number or a keyframes array, we can animate it. We might at some point\n    // need to do a deep isAnimatable check of keyframes, or let Popmotion handle this,\n    // but for now lets leave it like this for performance reasons\n    if (typeof value === \"number\" || Array.isArray(value))\n        return true;\n    if (typeof value === \"string\" && // It's animatable if we have a string\n        (complex.test(value) || value === \"0\") && // And it contains numbers and/or colors\n        !value.startsWith(\"url(\") // Unless it starts with \"url(\"\n    ) {\n        return true;\n    }\n    return false;\n};\n\nexport { isAnimatable };\n","import { isGenerator } from 'motion-dom';\nimport { warning } from 'motion-utils';\nimport { isAnimatable } from '../../utils/is-animatable.mjs';\n\nfunction hasKeyframesChanged(keyframes) {\n    const current = keyframes[0];\n    if (keyframes.length === 1)\n        return true;\n    for (let i = 0; i < keyframes.length; i++) {\n        if (keyframes[i] !== current)\n            return true;\n    }\n}\nfunction canAnimate(keyframes, name, type, velocity) {\n    /**\n     * Check if we're able to animate between the start and end keyframes,\n     * and throw a warning if we're attempting to animate between one that's\n     * animatable and another that isn't.\n     */\n    const originKeyframe = keyframes[0];\n    if (originKeyframe === null)\n        return false;\n    /**\n     * These aren't traditionally animatable but we do support them.\n     * In future we could look into making this more generic or replacing\n     * this function with mix() === mixImmediate\n     */\n    if (name === \"display\" || name === \"visibility\")\n        return true;\n    const targetKeyframe = keyframes[keyframes.length - 1];\n    const isOriginAnimatable = isAnimatable(originKeyframe, name);\n    const isTargetAnimatable = isAnimatable(targetKeyframe, name);\n    warning(isOriginAnimatable === isTargetAnimatable, `You are trying to animate ${name} from \"${originKeyframe}\" to \"${targetKeyframe}\". ${originKeyframe} is not an animatable value - to enable this animation set ${originKeyframe} to a value animatable to ${targetKeyframe} via the \\`style\\` property.`);\n    // Always skip if any of these are true\n    if (!isOriginAnimatable || !isTargetAnimatable) {\n        return false;\n    }\n    return (hasKeyframesChanged(keyframes) ||\n        ((type === \"spring\" || isGenerator(type)) && velocity));\n}\n\nexport { canAnimate };\n","const isNotNull = (value) => value !== null;\nfunction getFinalKeyframe(keyframes, { repeat, repeatType = \"loop\" }, finalKeyframe) {\n    const resolvedKeyframes = keyframes.filter(isNotNull);\n    const index = repeat && repeatType !== \"loop\" && repeat % 2 === 1\n        ? 0\n        : resolvedKeyframes.length - 1;\n    return !index || finalKeyframe === undefined\n        ? resolvedKeyframes[index]\n        : finalKeyframe;\n}\n\nexport { getFinalKeyframe };\n","import { time } from '../../frameloop/sync-time.mjs';\nimport { flushKeyframeResolvers } from '../../render/utils/KeyframesResolver.mjs';\nimport { instantAnimationState } from '../../utils/use-instant-transition-state.mjs';\nimport { canAnimate } from './utils/can-animate.mjs';\nimport { getFinalKeyframe } from './waapi/utils/get-final-keyframe.mjs';\n\n/**\n * Maximum time allowed between an animation being created and it being\n * resolved for us to use the latter as the start time.\n *\n * This is to ensure that while we prefer to \"start\" an animation as soon\n * as it's triggered, we also want to avoid a visual jump if there's a big delay\n * between these two moments.\n */\nconst MAX_RESOLVE_DELAY = 40;\nclass BaseAnimation {\n    constructor({ autoplay = true, delay = 0, type = \"keyframes\", repeat = 0, repeatDelay = 0, repeatType = \"loop\", ...options }) {\n        // Track whether the animation has been stopped. Stopped animations won't restart.\n        this.isStopped = false;\n        this.hasAttemptedResolve = false;\n        this.createdAt = time.now();\n        this.options = {\n            autoplay,\n            delay,\n            type,\n            repeat,\n            repeatDelay,\n            repeatType,\n            ...options,\n        };\n        this.updateFinishedPromise();\n    }\n    /**\n     * This method uses the createdAt and resolvedAt to calculate the\n     * animation startTime. *Ideally*, we would use the createdAt time as t=0\n     * as the following frame would then be the first frame of the animation in\n     * progress, which would feel snappier.\n     *\n     * However, if there's a delay (main thread work) between the creation of\n     * the animation and the first commited frame, we prefer to use resolvedAt\n     * to avoid a sudden jump into the animation.\n     */\n    calcStartTime() {\n        if (!this.resolvedAt)\n            return this.createdAt;\n        return this.resolvedAt - this.createdAt > MAX_RESOLVE_DELAY\n            ? this.resolvedAt\n            : this.createdAt;\n    }\n    /**\n     * A getter for resolved data. If keyframes are not yet resolved, accessing\n     * this.resolved will synchronously flush all pending keyframe resolvers.\n     * This is a deoptimisation, but at its worst still batches read/writes.\n     */\n    get resolved() {\n        if (!this._resolved && !this.hasAttemptedResolve) {\n            flushKeyframeResolvers();\n        }\n        return this._resolved;\n    }\n    /**\n     * A method to be called when the keyframes resolver completes. This method\n     * will check if its possible to run the animation and, if not, skip it.\n     * Otherwise, it will call initPlayback on the implementing class.\n     */\n    onKeyframesResolved(keyframes, finalKeyframe) {\n        this.resolvedAt = time.now();\n        this.hasAttemptedResolve = true;\n        const { name, type, velocity, delay, onComplete, onUpdate, isGenerator, } = this.options;\n        /**\n         * If we can't animate this value with the resolved keyframes\n         * then we should complete it immediately.\n         */\n        if (!isGenerator && !canAnimate(keyframes, name, type, velocity)) {\n            // Finish immediately\n            if (instantAnimationState.current || !delay) {\n                onUpdate &&\n                    onUpdate(getFinalKeyframe(keyframes, this.options, finalKeyframe));\n                onComplete && onComplete();\n                this.resolveFinishedPromise();\n                return;\n            }\n            // Finish after a delay\n            else {\n                this.options.duration = 0;\n            }\n        }\n        const resolvedAnimation = this.initPlayback(keyframes, finalKeyframe);\n        if (resolvedAnimation === false)\n            return;\n        this._resolved = {\n            keyframes,\n            finalKeyframe,\n            ...resolvedAnimation,\n        };\n        this.onPostResolved();\n    }\n    onPostResolved() { }\n    /**\n     * Allows the returned animation to be awaited or promise-chained. Currently\n     * resolves when the animation finishes at all but in a future update could/should\n     * reject if its cancels.\n     */\n    then(resolve, reject) {\n        return this.currentFinishedPromise.then(resolve, reject);\n    }\n    flatten() {\n        this.options.type = \"keyframes\";\n        this.options.ease = \"linear\";\n    }\n    updateFinishedPromise() {\n        this.currentFinishedPromise = new Promise((resolve) => {\n            this.resolveFinishedPromise = resolve;\n        });\n    }\n}\n\nexport { BaseAnimation };\n","/*\n  Value in range from progress\n\n  Given a lower limit and an upper limit, we return the value within\n  that range as expressed by progress (usually a number from 0 to 1)\n\n  So progress = 0.5 would change\n\n  from -------- to\n\n  to\n\n  from ---- to\n\n  E.g. from = 10, to = 20, progress = 0.5 => 15\n\n  @param [number]: Lower limit of range\n  @param [number]: Upper limit of range\n  @param [number]: The progress between lower and upper limits expressed 0-1\n  @return [number]: Value as calculated from progress within range (not limited within range)\n*/\nconst mixNumber = (from, to, progress) => {\n    return from + (to - from) * progress;\n};\n\nexport { mixNumber };\n","// Adapted from https://gist.github.com/mjackson/5311256\nfunction hueToRgb(p, q, t) {\n    if (t < 0)\n        t += 1;\n    if (t > 1)\n        t -= 1;\n    if (t < 1 / 6)\n        return p + (q - p) * 6 * t;\n    if (t < 1 / 2)\n        return q;\n    if (t < 2 / 3)\n        return p + (q - p) * (2 / 3 - t) * 6;\n    return p;\n}\nfunction hslaToRgba({ hue, saturation, lightness, alpha }) {\n    hue /= 360;\n    saturation /= 100;\n    lightness /= 100;\n    let red = 0;\n    let green = 0;\n    let blue = 0;\n    if (!saturation) {\n        red = green = blue = lightness;\n    }\n    else {\n        const q = lightness < 0.5\n            ? lightness * (1 + saturation)\n            : lightness + saturation - lightness * saturation;\n        const p = 2 * lightness - q;\n        red = hueToRgb(p, q, hue + 1 / 3);\n        green = hueToRgb(p, q, hue);\n        blue = hueToRgb(p, q, hue - 1 / 3);\n    }\n    return {\n        red: Math.round(red * 255),\n        green: Math.round(green * 255),\n        blue: Math.round(blue * 255),\n        alpha,\n    };\n}\n\nexport { hslaToRgba };\n","function mixImmediate(a, b) {\n    return (p) => (p > 0 ? b : a);\n}\n\nexport { mixImmediate };\n","import { mixNumber } from './number.mjs';\nimport { warning } from 'motion-utils';\nimport { hslaToRgba } from '../hsla-to-rgba.mjs';\nimport { hex } from '../../value/types/color/hex.mjs';\nimport { rgba } from '../../value/types/color/rgba.mjs';\nimport { hsla } from '../../value/types/color/hsla.mjs';\nimport { mixImmediate } from './immediate.mjs';\n\n// Linear color space blending\n// Explained https://www.youtube.com/watch?v=LKnqECcg6Gw\n// Demonstrated http://codepen.io/osublake/pen/xGVVaN\nconst mixLinearColor = (from, to, v) => {\n    const fromExpo = from * from;\n    const expo = v * (to * to - fromExpo) + fromExpo;\n    return expo < 0 ? 0 : Math.sqrt(expo);\n};\nconst colorTypes = [hex, rgba, hsla];\nconst getColorType = (v) => colorTypes.find((type) => type.test(v));\nfunction asRGBA(color) {\n    const type = getColorType(color);\n    warning(Boolean(type), `'${color}' is not an animatable color. Use the equivalent color code instead.`);\n    if (!Boolean(type))\n        return false;\n    let model = type.parse(color);\n    if (type === hsla) {\n        // TODO Remove this cast - needed since Motion's stricter typing\n        model = hslaToRgba(model);\n    }\n    return model;\n}\nconst mixColor = (from, to) => {\n    const fromRGBA = asRGBA(from);\n    const toRGBA = asRGBA(to);\n    if (!fromRGBA || !toRGBA) {\n        return mixImmediate(from, to);\n    }\n    const blended = { ...fromRGBA };\n    return (v) => {\n        blended.red = mixLinearColor(fromRGBA.red, toRGBA.red, v);\n        blended.green = mixLinearColor(fromRGBA.green, toRGBA.green, v);\n        blended.blue = mixLinearColor(fromRGBA.blue, toRGBA.blue, v);\n        blended.alpha = mixNumber(fromRGBA.alpha, toRGBA.alpha, v);\n        return rgba.transform(blended);\n    };\n};\n\nexport { mixColor, mixLinearColor };\n","/**\n * Pipe\n * Compose other transformers to run linearily\n * pipe(min(20), max(40))\n * @param  {...functions} transformers\n * @return {function}\n */\nconst combineFunctions = (a, b) => (v) => b(a(v));\nconst pipe = (...transformers) => transformers.reduce(combineFunctions);\n\nexport { pipe };\n","const invisibleValues = new Set([\"none\", \"hidden\"]);\n/**\n * Returns a function that, when provided a progress value between 0 and 1,\n * will return the \"none\" or \"hidden\" string only when the progress is that of\n * the origin or target.\n */\nfunction mixVisibility(origin, target) {\n    if (invisibleValues.has(origin)) {\n        return (p) => (p <= 0 ? origin : target);\n    }\n    else {\n        return (p) => (p >= 1 ? target : origin);\n    }\n}\n\nexport { invisibleValues, mixVisibility };\n","import { mixNumber as mixNumber$1 } from './number.mjs';\nimport { mixColor } from './color.mjs';\nimport { pipe } from '../pipe.mjs';\nimport { warning } from 'motion-utils';\nimport { color } from '../../value/types/color/index.mjs';\nimport { complex, analyseComplexValue } from '../../value/types/complex/index.mjs';\nimport { isCSSVariableToken } from '../../render/dom/utils/is-css-variable.mjs';\nimport { invisibleValues, mixVisibility } from './visibility.mjs';\nimport { mixImmediate } from './immediate.mjs';\n\nfunction mixNumber(a, b) {\n    return (p) => mixNumber$1(a, b, p);\n}\nfunction getMixer(a) {\n    if (typeof a === \"number\") {\n        return mixNumber;\n    }\n    else if (typeof a === \"string\") {\n        return isCSSVariableToken(a)\n            ? mixImmediate\n            : color.test(a)\n                ? mixColor\n                : mixComplex;\n    }\n    else if (Array.isArray(a)) {\n        return mixArray;\n    }\n    else if (typeof a === \"object\") {\n        return color.test(a) ? mixColor : mixObject;\n    }\n    return mixImmediate;\n}\nfunction mixArray(a, b) {\n    const output = [...a];\n    const numValues = output.length;\n    const blendValue = a.map((v, i) => getMixer(v)(v, b[i]));\n    return (p) => {\n        for (let i = 0; i < numValues; i++) {\n            output[i] = blendValue[i](p);\n        }\n        return output;\n    };\n}\nfunction mixObject(a, b) {\n    const output = { ...a, ...b };\n    const blendValue = {};\n    for (const key in output) {\n        if (a[key] !== undefined && b[key] !== undefined) {\n            blendValue[key] = getMixer(a[key])(a[key], b[key]);\n        }\n    }\n    return (v) => {\n        for (const key in blendValue) {\n            output[key] = blendValue[key](v);\n        }\n        return output;\n    };\n}\nfunction matchOrder(origin, target) {\n    var _a;\n    const orderedOrigin = [];\n    const pointers = { color: 0, var: 0, number: 0 };\n    for (let i = 0; i < target.values.length; i++) {\n        const type = target.types[i];\n        const originIndex = origin.indexes[type][pointers[type]];\n        const originValue = (_a = origin.values[originIndex]) !== null && _a !== void 0 ? _a : 0;\n        orderedOrigin[i] = originValue;\n        pointers[type]++;\n    }\n    return orderedOrigin;\n}\nconst mixComplex = (origin, target) => {\n    const template = complex.createTransformer(target);\n    const originStats = analyseComplexValue(origin);\n    const targetStats = analyseComplexValue(target);\n    const canInterpolate = originStats.indexes.var.length === targetStats.indexes.var.length &&\n        originStats.indexes.color.length === targetStats.indexes.color.length &&\n        originStats.indexes.number.length >= targetStats.indexes.number.length;\n    if (canInterpolate) {\n        if ((invisibleValues.has(origin) &&\n            !targetStats.values.length) ||\n            (invisibleValues.has(target) &&\n                !originStats.values.length)) {\n            return mixVisibility(origin, target);\n        }\n        return pipe(mixArray(matchOrder(originStats, targetStats), targetStats.values), template);\n    }\n    else {\n        warning(true, `Complex values '${origin}' and '${target}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`);\n        return mixImmediate(origin, target);\n    }\n};\n\nexport { getMixer, mixArray, mixComplex, mixObject };\n","import { getMixer } from './complex.mjs';\nimport { mixNumber } from './number.mjs';\n\nfunction mix(from, to, p) {\n    if (typeof from === \"number\" &&\n        typeof to === \"number\" &&\n        typeof p === \"number\") {\n        return mixNumber(from, to, p);\n    }\n    const mixer = getMixer(from);\n    return mixer(from, to);\n}\n\nexport { mix };\n","import { velocityPerSecond } from '../../../utils/velocity-per-second.mjs';\n\nconst velocitySampleDuration = 5; // ms\nfunction calcGeneratorVelocity(resolveValue, t, current) {\n    const prevT = Math.max(t - velocitySampleDuration, 0);\n    return velocityPerSecond(current - resolveValue(prevT), t - prevT);\n}\n\nexport { calcGeneratorVelocity };\n","const springDefaults = {\n    // Default spring physics\n    stiffness: 100,\n    damping: 10,\n    mass: 1.0,\n    velocity: 0.0,\n    // Default duration/bounce-based options\n    duration: 800, // in ms\n    bounce: 0.3,\n    visualDuration: 0.3, // in seconds\n    // Rest thresholds\n    restSpeed: {\n        granular: 0.01,\n        default: 2,\n    },\n    restDelta: {\n        granular: 0.005,\n        default: 0.5,\n    },\n    // Limits\n    minDuration: 0.01, // in seconds\n    maxDuration: 10.0, // in seconds\n    minDamping: 0.05,\n    maxDamping: 1,\n};\n\nexport { springDefaults };\n","import { warning, secondsToMilliseconds, millisecondsToSeconds } from 'motion-utils';\nimport { clamp } from '../../../utils/clamp.mjs';\nimport { springDefaults } from './defaults.mjs';\n\nconst safeMin = 0.001;\nfunction findSpring({ duration = springDefaults.duration, bounce = springDefaults.bounce, velocity = springDefaults.velocity, mass = springDefaults.mass, }) {\n    let envelope;\n    let derivative;\n    warning(duration <= secondsToMilliseconds(springDefaults.maxDuration), \"Spring duration must be 10 seconds or less\");\n    let dampingRatio = 1 - bounce;\n    /**\n     * Restrict dampingRatio and duration to within acceptable ranges.\n     */\n    dampingRatio = clamp(springDefaults.minDamping, springDefaults.maxDamping, dampingRatio);\n    duration = clamp(springDefaults.minDuration, springDefaults.maxDuration, millisecondsToSeconds(duration));\n    if (dampingRatio < 1) {\n        /**\n         * Underdamped spring\n         */\n        envelope = (undampedFreq) => {\n            const exponentialDecay = undampedFreq * dampingRatio;\n            const delta = exponentialDecay * duration;\n            const a = exponentialDecay - velocity;\n            const b = calcAngularFreq(undampedFreq, dampingRatio);\n            const c = Math.exp(-delta);\n            return safeMin - (a / b) * c;\n        };\n        derivative = (undampedFreq) => {\n            const exponentialDecay = undampedFreq * dampingRatio;\n            const delta = exponentialDecay * duration;\n            const d = delta * velocity + velocity;\n            const e = Math.pow(dampingRatio, 2) * Math.pow(undampedFreq, 2) * duration;\n            const f = Math.exp(-delta);\n            const g = calcAngularFreq(Math.pow(undampedFreq, 2), dampingRatio);\n            const factor = -envelope(undampedFreq) + safeMin > 0 ? -1 : 1;\n            return (factor * ((d - e) * f)) / g;\n        };\n    }\n    else {\n        /**\n         * Critically-damped spring\n         */\n        envelope = (undampedFreq) => {\n            const a = Math.exp(-undampedFreq * duration);\n            const b = (undampedFreq - velocity) * duration + 1;\n            return -safeMin + a * b;\n        };\n        derivative = (undampedFreq) => {\n            const a = Math.exp(-undampedFreq * duration);\n            const b = (velocity - undampedFreq) * (duration * duration);\n            return a * b;\n        };\n    }\n    const initialGuess = 5 / duration;\n    const undampedFreq = approximateRoot(envelope, derivative, initialGuess);\n    duration = secondsToMilliseconds(duration);\n    if (isNaN(undampedFreq)) {\n        return {\n            stiffness: springDefaults.stiffness,\n            damping: springDefaults.damping,\n            duration,\n        };\n    }\n    else {\n        const stiffness = Math.pow(undampedFreq, 2) * mass;\n        return {\n            stiffness,\n            damping: dampingRatio * 2 * Math.sqrt(mass * stiffness),\n            duration,\n        };\n    }\n}\nconst rootIterations = 12;\nfunction approximateRoot(envelope, derivative, initialGuess) {\n    let result = initialGuess;\n    for (let i = 1; i < rootIterations; i++) {\n        result = result - envelope(result) / derivative(result);\n    }\n    return result;\n}\nfunction calcAngularFreq(undampedFreq, dampingRatio) {\n    return undampedFreq * Math.sqrt(1 - dampingRatio * dampingRatio);\n}\n\nexport { calcAngularFreq, findSpring };\n","import { calcGeneratorDuration, maxGeneratorDuration, generateLinearEasing } from 'motion-dom';\nimport { millisecondsToSeconds, secondsToMilliseconds } from 'motion-utils';\nimport { clamp } from '../../../utils/clamp.mjs';\nimport { calcGeneratorVelocity } from '../utils/velocity.mjs';\nimport { springDefaults } from './defaults.mjs';\nimport { findSpring, calcAngularFreq } from './find.mjs';\n\nconst durationKeys = [\"duration\", \"bounce\"];\nconst physicsKeys = [\"stiffness\", \"damping\", \"mass\"];\nfunction isSpringType(options, keys) {\n    return keys.some((key) => options[key] !== undefined);\n}\nfunction getSpringOptions(options) {\n    let springOptions = {\n        velocity: springDefaults.velocity,\n        stiffness: springDefaults.stiffness,\n        damping: springDefaults.damping,\n        mass: springDefaults.mass,\n        isResolvedFromDuration: false,\n        ...options,\n    };\n    // stiffness/damping/mass overrides duration/bounce\n    if (!isSpringType(options, physicsKeys) &&\n        isSpringType(options, durationKeys)) {\n        if (options.visualDuration) {\n            const visualDuration = options.visualDuration;\n            const root = (2 * Math.PI) / (visualDuration * 1.2);\n            const stiffness = root * root;\n            const damping = 2 *\n                clamp(0.05, 1, 1 - (options.bounce || 0)) *\n                Math.sqrt(stiffness);\n            springOptions = {\n                ...springOptions,\n                mass: springDefaults.mass,\n                stiffness,\n                damping,\n            };\n        }\n        else {\n            const derived = findSpring(options);\n            springOptions = {\n                ...springOptions,\n                ...derived,\n                mass: springDefaults.mass,\n            };\n            springOptions.isResolvedFromDuration = true;\n        }\n    }\n    return springOptions;\n}\nfunction spring(optionsOrVisualDuration = springDefaults.visualDuration, bounce = springDefaults.bounce) {\n    const options = typeof optionsOrVisualDuration !== \"object\"\n        ? {\n            visualDuration: optionsOrVisualDuration,\n            keyframes: [0, 1],\n            bounce,\n        }\n        : optionsOrVisualDuration;\n    let { restSpeed, restDelta } = options;\n    const origin = options.keyframes[0];\n    const target = options.keyframes[options.keyframes.length - 1];\n    /**\n     * This is the Iterator-spec return value. We ensure it's mutable rather than using a generator\n     * to reduce GC during animation.\n     */\n    const state = { done: false, value: origin };\n    const { stiffness, damping, mass, duration, velocity, isResolvedFromDuration, } = getSpringOptions({\n        ...options,\n        velocity: -millisecondsToSeconds(options.velocity || 0),\n    });\n    const initialVelocity = velocity || 0.0;\n    const dampingRatio = damping / (2 * Math.sqrt(stiffness * mass));\n    const initialDelta = target - origin;\n    const undampedAngularFreq = millisecondsToSeconds(Math.sqrt(stiffness / mass));\n    /**\n     * If we're working on a granular scale, use smaller defaults for determining\n     * when the spring is finished.\n     *\n     * These defaults have been selected emprically based on what strikes a good\n     * ratio between feeling good and finishing as soon as changes are imperceptible.\n     */\n    const isGranularScale = Math.abs(initialDelta) < 5;\n    restSpeed || (restSpeed = isGranularScale\n        ? springDefaults.restSpeed.granular\n        : springDefaults.restSpeed.default);\n    restDelta || (restDelta = isGranularScale\n        ? springDefaults.restDelta.granular\n        : springDefaults.restDelta.default);\n    let resolveSpring;\n    if (dampingRatio < 1) {\n        const angularFreq = calcAngularFreq(undampedAngularFreq, dampingRatio);\n        // Underdamped spring\n        resolveSpring = (t) => {\n            const envelope = Math.exp(-dampingRatio * undampedAngularFreq * t);\n            return (target -\n                envelope *\n                    (((initialVelocity +\n                        dampingRatio * undampedAngularFreq * initialDelta) /\n                        angularFreq) *\n                        Math.sin(angularFreq * t) +\n                        initialDelta * Math.cos(angularFreq * t)));\n        };\n    }\n    else if (dampingRatio === 1) {\n        // Critically damped spring\n        resolveSpring = (t) => target -\n            Math.exp(-undampedAngularFreq * t) *\n                (initialDelta +\n                    (initialVelocity + undampedAngularFreq * initialDelta) * t);\n    }\n    else {\n        // Overdamped spring\n        const dampedAngularFreq = undampedAngularFreq * Math.sqrt(dampingRatio * dampingRatio - 1);\n        resolveSpring = (t) => {\n            const envelope = Math.exp(-dampingRatio * undampedAngularFreq * t);\n            // When performing sinh or cosh values can hit Infinity so we cap them here\n            const freqForT = Math.min(dampedAngularFreq * t, 300);\n            return (target -\n                (envelope *\n                    ((initialVelocity +\n                        dampingRatio * undampedAngularFreq * initialDelta) *\n                        Math.sinh(freqForT) +\n                        dampedAngularFreq *\n                            initialDelta *\n                            Math.cosh(freqForT))) /\n                    dampedAngularFreq);\n        };\n    }\n    const generator = {\n        calculatedDuration: isResolvedFromDuration ? duration || null : null,\n        next: (t) => {\n            const current = resolveSpring(t);\n            if (!isResolvedFromDuration) {\n                let currentVelocity = 0.0;\n                /**\n                 * We only need to calculate velocity for under-damped springs\n                 * as over- and critically-damped springs can't overshoot, so\n                 * checking only for displacement is enough.\n                 */\n                if (dampingRatio < 1) {\n                    currentVelocity =\n                        t === 0\n                            ? secondsToMilliseconds(initialVelocity)\n                            : calcGeneratorVelocity(resolveSpring, t, current);\n                }\n                const isBelowVelocityThreshold = Math.abs(currentVelocity) <= restSpeed;\n                const isBelowDisplacementThreshold = Math.abs(target - current) <= restDelta;\n                state.done =\n                    isBelowVelocityThreshold && isBelowDisplacementThreshold;\n            }\n            else {\n                state.done = t >= duration;\n            }\n            state.value = state.done ? target : current;\n            return state;\n        },\n        toString: () => {\n            const calculatedDuration = Math.min(calcGeneratorDuration(generator), maxGeneratorDuration);\n            const easing = generateLinearEasing((progress) => generator.next(calculatedDuration * progress).value, calculatedDuration, 30);\n            return calculatedDuration + \"ms \" + easing;\n        },\n    };\n    return generator;\n}\n\nexport { spring };\n","import { spring } from './spring/index.mjs';\nimport { calcGeneratorVelocity } from './utils/velocity.mjs';\n\nfunction inertia({ keyframes, velocity = 0.0, power = 0.8, timeConstant = 325, bounceDamping = 10, bounceStiffness = 500, modifyTarget, min, max, restDelta = 0.5, restSpeed, }) {\n    const origin = keyframes[0];\n    const state = {\n        done: false,\n        value: origin,\n    };\n    const isOutOfBounds = (v) => (min !== undefined && v < min) || (max !== undefined && v > max);\n    const nearestBoundary = (v) => {\n        if (min === undefined)\n            return max;\n        if (max === undefined)\n            return min;\n        return Math.abs(min - v) < Math.abs(max - v) ? min : max;\n    };\n    let amplitude = power * velocity;\n    const ideal = origin + amplitude;\n    const target = modifyTarget === undefined ? ideal : modifyTarget(ideal);\n    /**\n     * If the target has changed we need to re-calculate the amplitude, otherwise\n     * the animation will start from the wrong position.\n     */\n    if (target !== ideal)\n        amplitude = target - origin;\n    const calcDelta = (t) => -amplitude * Math.exp(-t / timeConstant);\n    const calcLatest = (t) => target + calcDelta(t);\n    const applyFriction = (t) => {\n        const delta = calcDelta(t);\n        const latest = calcLatest(t);\n        state.done = Math.abs(delta) <= restDelta;\n        state.value = state.done ? target : latest;\n    };\n    /**\n     * Ideally this would resolve for t in a stateless way, we could\n     * do that by always precalculating the animation but as we know\n     * this will be done anyway we can assume that spring will\n     * be discovered during that.\n     */\n    let timeReachedBoundary;\n    let spring$1;\n    const checkCatchBoundary = (t) => {\n        if (!isOutOfBounds(state.value))\n            return;\n        timeReachedBoundary = t;\n        spring$1 = spring({\n            keyframes: [state.value, nearestBoundary(state.value)],\n            velocity: calcGeneratorVelocity(calcLatest, t, state.value), // TODO: This should be passing * 1000\n            damping: bounceDamping,\n            stiffness: bounceStiffness,\n            restDelta,\n            restSpeed,\n        });\n    };\n    checkCatchBoundary(0);\n    return {\n        calculatedDuration: null,\n        next: (t) => {\n            /**\n             * We need to resolve the friction to figure out if we need a\n             * spring but we don't want to do this twice per frame. So here\n             * we flag if we updated for this frame and later if we did\n             * we can skip doing it again.\n             */\n            let hasUpdatedFrame = false;\n            if (!spring$1 && timeReachedBoundary === undefined) {\n                hasUpdatedFrame = true;\n                applyFriction(t);\n                checkCatchBoundary(t);\n            }\n            /**\n             * If we have a spring and the provided t is beyond the moment the friction\n             * animation crossed the min/max boundary, use the spring.\n             */\n            if (timeReachedBoundary !== undefined && t >= timeReachedBoundary) {\n                return spring$1.next(t - timeReachedBoundary);\n            }\n            else {\n                !hasUpdatedFrame && applyFriction(t);\n                return state;\n            }\n        },\n    };\n}\n\nexport { inertia };\n","import { cubicBezier } from './cubic-bezier.mjs';\n\nconst easeIn = /*@__PURE__*/ cubicBezier(0.42, 0, 1, 1);\nconst easeOut = /*@__PURE__*/ cubicBezier(0, 0, 0.58, 1);\nconst easeInOut = /*@__PURE__*/ cubicBezier(0.42, 0, 0.58, 1);\n\nexport { easeIn, easeInOut, easeOut };\n","import { isBezierDefinition } from 'motion-dom';\nimport { invariant, noop } from 'motion-utils';\nimport { anticipate } from '../anticipate.mjs';\nimport { backIn, backInOut, backOut } from '../back.mjs';\nimport { circIn, circInOut, circOut } from '../circ.mjs';\nimport { cubicBezier } from '../cubic-bezier.mjs';\nimport { easeIn, easeInOut, easeOut } from '../ease.mjs';\n\nconst easingLookup = {\n    linear: noop,\n    easeIn,\n    easeInOut,\n    easeOut,\n    circIn,\n    circInOut,\n    circOut,\n    backIn,\n    backInOut,\n    backOut,\n    anticipate,\n};\nconst easingDefinitionToFunction = (definition) => {\n    if (isBezierDefinition(definition)) {\n        // If cubic bezier definition, create bezier curve\n        invariant(definition.length === 4, `Cubic bezier arrays must contain four numerical values.`);\n        const [x1, y1, x2, y2] = definition;\n        return cubicBezier(x1, y1, x2, y2);\n    }\n    else if (typeof definition === \"string\") {\n        // Else lookup from table\n        invariant(easingLookup[definition] !== undefined, `Invalid easing type '${definition}'`);\n        return easingLookup[definition];\n    }\n    return definition;\n};\n\nexport { easingDefinitionToFunction };\n","import { easeInOut } from '../../easing/ease.mjs';\nimport { isEasingArray } from '../../easing/utils/is-easing-array.mjs';\nimport { easingDefinitionToFunction } from '../../easing/utils/map.mjs';\nimport { interpolate } from '../../utils/interpolate.mjs';\nimport { defaultOffset } from '../../utils/offsets/default.mjs';\nimport { convertOffsetToTimes } from '../../utils/offsets/time.mjs';\n\nfunction defaultEasing(values, easing) {\n    return values.map(() => easing || easeInOut).splice(0, values.length - 1);\n}\nfunction keyframes({ duration = 300, keyframes: keyframeValues, times, ease = \"easeInOut\", }) {\n    /**\n     * Easing functions can be externally defined as strings. Here we convert them\n     * into actual functions.\n     */\n    const easingFunctions = isEasingArray(ease)\n        ? ease.map(easingDefinitionToFunction)\n        : easingDefinitionToFunction(ease);\n    /**\n     * This is the Iterator-spec return value. We ensure it's mutable rather than using a generator\n     * to reduce GC during animation.\n     */\n    const state = {\n        done: false,\n        value: keyframeValues[0],\n    };\n    /**\n     * Create a times array based on the provided 0-1 offsets\n     */\n    const absoluteTimes = convertOffsetToTimes(\n    // Only use the provided offsets if they're the correct length\n    // TODO Maybe we should warn here if there's a length mismatch\n    times && times.length === keyframeValues.length\n        ? times\n        : defaultOffset(keyframeValues), duration);\n    const mapTimeToKeyframe = interpolate(absoluteTimes, keyframeValues, {\n        ease: Array.isArray(easingFunctions)\n            ? easingFunctions\n            : defaultEasing(keyframeValues, easingFunctions),\n    });\n    return {\n        calculatedDuration: duration,\n        next: (t) => {\n            state.value = mapTimeToKeyframe(t);\n            state.done = t >= duration;\n            return state;\n        },\n    };\n}\n\nexport { defaultEasing, keyframes };\n","const isEasingArray = (ease) => {\n    return Array.isArray(ease) && typeof ease[0] !== \"number\";\n};\n\nexport { isEasingArray };\n","function convertOffsetToTimes(offset, duration) {\n    return offset.map((o) => o * duration);\n}\n\nexport { convertOffsetToTimes };\n","import { fillOffset } from './fill.mjs';\n\nfunction defaultOffset(arr) {\n    const offset = [0];\n    fillOffset(offset, arr.length - 1);\n    return offset;\n}\n\nexport { defaultOffset };\n","import { progress } from 'motion-utils';\nimport { mixNumber } from '../mix/number.mjs';\n\nfunction fillOffset(offset, remaining) {\n    const min = offset[offset.length - 1];\n    for (let i = 1; i <= remaining; i++) {\n        const offsetProgress = progress(0, remaining, i);\n        offset.push(mixNumber(min, 1, offsetProgress));\n    }\n}\n\nexport { fillOffset };\n","import { invariant, noop, progress } from 'motion-utils';\nimport { clamp } from './clamp.mjs';\nimport { mix } from './mix/index.mjs';\nimport { pipe } from './pipe.mjs';\n\nfunction createMixers(output, ease, customMixer) {\n    const mixers = [];\n    const mixerFactory = customMixer || mix;\n    const numMixers = output.length - 1;\n    for (let i = 0; i < numMixers; i++) {\n        let mixer = mixerFactory(output[i], output[i + 1]);\n        if (ease) {\n            const easingFunction = Array.isArray(ease) ? ease[i] || noop : ease;\n            mixer = pipe(easingFunction, mixer);\n        }\n        mixers.push(mixer);\n    }\n    return mixers;\n}\n/**\n * Create a function that maps from a numerical input array to a generic output array.\n *\n * Accepts:\n *   - Numbers\n *   - Colors (hex, hsl, hsla, rgb, rgba)\n *   - Complex (combinations of one or more numbers or strings)\n *\n * ```jsx\n * const mixColor = interpolate([0, 1], ['#fff', '#000'])\n *\n * mixColor(0.5) // 'rgba(128, 128, 128, 1)'\n * ```\n *\n * TODO Revist this approach once we've moved to data models for values,\n * probably not needed to pregenerate mixer functions.\n *\n * @public\n */\nfunction interpolate(input, output, { clamp: isClamp = true, ease, mixer } = {}) {\n    const inputLength = input.length;\n    invariant(inputLength === output.length, \"Both input and output ranges must be the same length\");\n    /**\n     * If we're only provided a single input, we can just make a function\n     * that returns the output.\n     */\n    if (inputLength === 1)\n        return () => output[0];\n    if (inputLength === 2 && output[0] === output[1])\n        return () => output[1];\n    const isZeroDeltaRange = input[0] === input[1];\n    // If input runs highest -> lowest, reverse both arrays\n    if (input[0] > input[inputLength - 1]) {\n        input = [...input].reverse();\n        output = [...output].reverse();\n    }\n    const mixers = createMixers(output, ease, mixer);\n    const numMixers = mixers.length;\n    const interpolator = (v) => {\n        if (isZeroDeltaRange && v < input[0])\n            return output[0];\n        let i = 0;\n        if (numMixers > 1) {\n            for (; i < input.length - 2; i++) {\n                if (v < input[i + 1])\n                    break;\n            }\n        }\n        const progressInRange = progress(input[i], input[i + 1], v);\n        return mixers[i](progressInRange);\n    };\n    return isClamp\n        ? (v) => interpolator(clamp(input[0], input[inputLength - 1], v))\n        : interpolator;\n}\n\nexport { interpolate };\n","import { time } from '../../../frameloop/sync-time.mjs';\nimport { frame, cancelFrame, frameData } from '../../../frameloop/frame.mjs';\n\nconst frameloopDriver = (update) => {\n    const passTimestamp = ({ timestamp }) => update(timestamp);\n    return {\n        start: () => frame.update(passTimestamp, true),\n        stop: () => cancelFrame(passTimestamp),\n        /**\n         * If we're processing this frame we can use the\n         * framelocked timestamp to keep things in sync.\n         */\n        now: () => (frameData.isProcessing ? frameData.timestamp : time.now()),\n    };\n};\n\nexport { frameloopDriver };\n","import { isGenerator, calcGeneratorDuration } from 'motion-dom';\nimport { invariant, millisecondsToSeconds, secondsToMilliseconds } from 'motion-utils';\nimport { KeyframeResolver } from '../../render/utils/KeyframesResolver.mjs';\nimport { clamp } from '../../utils/clamp.mjs';\nimport { mix } from '../../utils/mix/index.mjs';\nimport { pipe } from '../../utils/pipe.mjs';\nimport { inertia } from '../generators/inertia.mjs';\nimport { keyframes } from '../generators/keyframes.mjs';\nimport { spring } from '../generators/spring/index.mjs';\nimport { BaseAnimation } from './BaseAnimation.mjs';\nimport { frameloopDriver } from './drivers/driver-frameloop.mjs';\nimport { getFinalKeyframe } from './waapi/utils/get-final-keyframe.mjs';\n\nconst generators = {\n    decay: inertia,\n    inertia,\n    tween: keyframes,\n    keyframes: keyframes,\n    spring,\n};\nconst percentToProgress = (percent) => percent / 100;\n/**\n * Animation that runs on the main thread. Designed to be WAAPI-spec in the subset of\n * features we expose publically. Mostly the compatibility is to ensure visual identity\n * between both WAAPI and main thread animations.\n */\nclass MainThreadAnimation extends BaseAnimation {\n    constructor(options) {\n        super(options);\n        /**\n         * The time at which the animation was paused.\n         */\n        this.holdTime = null;\n        /**\n         * The time at which the animation was cancelled.\n         */\n        this.cancelTime = null;\n        /**\n         * The current time of the animation.\n         */\n        this.currentTime = 0;\n        /**\n         * Playback speed as a factor. 0 would be stopped, -1 reverse and 2 double speed.\n         */\n        this.playbackSpeed = 1;\n        /**\n         * The state of the animation to apply when the animation is resolved. This\n         * allows calls to the public API to control the animation before it is resolved,\n         * without us having to resolve it first.\n         */\n        this.pendingPlayState = \"running\";\n        /**\n         * The time at which the animation was started.\n         */\n        this.startTime = null;\n        this.state = \"idle\";\n        /**\n         * This method is bound to the instance to fix a pattern where\n         * animation.stop is returned as a reference from a useEffect.\n         */\n        this.stop = () => {\n            this.resolver.cancel();\n            this.isStopped = true;\n            if (this.state === \"idle\")\n                return;\n            this.teardown();\n            const { onStop } = this.options;\n            onStop && onStop();\n        };\n        const { name, motionValue, element, keyframes } = this.options;\n        const KeyframeResolver$1 = (element === null || element === void 0 ? void 0 : element.KeyframeResolver) || KeyframeResolver;\n        const onResolved = (resolvedKeyframes, finalKeyframe) => this.onKeyframesResolved(resolvedKeyframes, finalKeyframe);\n        this.resolver = new KeyframeResolver$1(keyframes, onResolved, name, motionValue, element);\n        this.resolver.scheduleResolve();\n    }\n    flatten() {\n        super.flatten();\n        // If we've already resolved the animation, re-initialise it\n        if (this._resolved) {\n            Object.assign(this._resolved, this.initPlayback(this._resolved.keyframes));\n        }\n    }\n    initPlayback(keyframes$1) {\n        const { type = \"keyframes\", repeat = 0, repeatDelay = 0, repeatType, velocity = 0, } = this.options;\n        const generatorFactory = isGenerator(type)\n            ? type\n            : generators[type] || keyframes;\n        /**\n         * If our generator doesn't support mixing numbers, we need to replace keyframes with\n         * [0, 100] and then make a function that maps that to the actual keyframes.\n         *\n         * 100 is chosen instead of 1 as it works nicer with spring animations.\n         */\n        let mapPercentToKeyframes;\n        let mirroredGenerator;\n        if (generatorFactory !== keyframes &&\n            typeof keyframes$1[0] !== \"number\") {\n            if (process.env.NODE_ENV !== \"production\") {\n                invariant(keyframes$1.length === 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${keyframes$1}`);\n            }\n            mapPercentToKeyframes = pipe(percentToProgress, mix(keyframes$1[0], keyframes$1[1]));\n            keyframes$1 = [0, 100];\n        }\n        const generator = generatorFactory({ ...this.options, keyframes: keyframes$1 });\n        /**\n         * If we have a mirror repeat type we need to create a second generator that outputs the\n         * mirrored (not reversed) animation and later ping pong between the two generators.\n         */\n        if (repeatType === \"mirror\") {\n            mirroredGenerator = generatorFactory({\n                ...this.options,\n                keyframes: [...keyframes$1].reverse(),\n                velocity: -velocity,\n            });\n        }\n        /**\n         * If duration is undefined and we have repeat options,\n         * we need to calculate a duration from the generator.\n         *\n         * We set it to the generator itself to cache the duration.\n         * Any timeline resolver will need to have already precalculated\n         * the duration by this step.\n         */\n        if (generator.calculatedDuration === null) {\n            generator.calculatedDuration = calcGeneratorDuration(generator);\n        }\n        const { calculatedDuration } = generator;\n        const resolvedDuration = calculatedDuration + repeatDelay;\n        const totalDuration = resolvedDuration * (repeat + 1) - repeatDelay;\n        return {\n            generator,\n            mirroredGenerator,\n            mapPercentToKeyframes,\n            calculatedDuration,\n            resolvedDuration,\n            totalDuration,\n        };\n    }\n    onPostResolved() {\n        const { autoplay = true } = this.options;\n        this.play();\n        if (this.pendingPlayState === \"paused\" || !autoplay) {\n            this.pause();\n        }\n        else {\n            this.state = this.pendingPlayState;\n        }\n    }\n    tick(timestamp, sample = false) {\n        const { resolved } = this;\n        // If the animations has failed to resolve, return the final keyframe.\n        if (!resolved) {\n            const { keyframes } = this.options;\n            return { done: true, value: keyframes[keyframes.length - 1] };\n        }\n        const { finalKeyframe, generator, mirroredGenerator, mapPercentToKeyframes, keyframes, calculatedDuration, totalDuration, resolvedDuration, } = resolved;\n        if (this.startTime === null)\n            return generator.next(0);\n        const { delay, repeat, repeatType, repeatDelay, onUpdate } = this.options;\n        /**\n         * requestAnimationFrame timestamps can come through as lower than\n         * the startTime as set by performance.now(). Here we prevent this,\n         * though in the future it could be possible to make setting startTime\n         * a pending operation that gets resolved here.\n         */\n        if (this.speed > 0) {\n            this.startTime = Math.min(this.startTime, timestamp);\n        }\n        else if (this.speed < 0) {\n            this.startTime = Math.min(timestamp - totalDuration / this.speed, this.startTime);\n        }\n        // Update currentTime\n        if (sample) {\n            this.currentTime = timestamp;\n        }\n        else if (this.holdTime !== null) {\n            this.currentTime = this.holdTime;\n        }\n        else {\n            // Rounding the time because floating point arithmetic is not always accurate, e.g. 3000.367 - 1000.367 =\n            // 2000.0000000000002. This is a problem when we are comparing the currentTime with the duration, for\n            // example.\n            this.currentTime =\n                Math.round(timestamp - this.startTime) * this.speed;\n        }\n        // Rebase on delay\n        const timeWithoutDelay = this.currentTime - delay * (this.speed >= 0 ? 1 : -1);\n        const isInDelayPhase = this.speed >= 0\n            ? timeWithoutDelay < 0\n            : timeWithoutDelay > totalDuration;\n        this.currentTime = Math.max(timeWithoutDelay, 0);\n        // If this animation has finished, set the current time  to the total duration.\n        if (this.state === \"finished\" && this.holdTime === null) {\n            this.currentTime = totalDuration;\n        }\n        let elapsed = this.currentTime;\n        let frameGenerator = generator;\n        if (repeat) {\n            /**\n             * Get the current progress (0-1) of the animation. If t is >\n             * than duration we'll get values like 2.5 (midway through the\n             * third iteration)\n             */\n            const progress = Math.min(this.currentTime, totalDuration) / resolvedDuration;\n            /**\n             * Get the current iteration (0 indexed). For instance the floor of\n             * 2.5 is 2.\n             */\n            let currentIteration = Math.floor(progress);\n            /**\n             * Get the current progress of the iteration by taking the remainder\n             * so 2.5 is 0.5 through iteration 2\n             */\n            let iterationProgress = progress % 1.0;\n            /**\n             * If iteration progress is 1 we count that as the end\n             * of the previous iteration.\n             */\n            if (!iterationProgress && progress >= 1) {\n                iterationProgress = 1;\n            }\n            iterationProgress === 1 && currentIteration--;\n            currentIteration = Math.min(currentIteration, repeat + 1);\n            /**\n             * Reverse progress if we're not running in \"normal\" direction\n             */\n            const isOddIteration = Boolean(currentIteration % 2);\n            if (isOddIteration) {\n                if (repeatType === \"reverse\") {\n                    iterationProgress = 1 - iterationProgress;\n                    if (repeatDelay) {\n                        iterationProgress -= repeatDelay / resolvedDuration;\n                    }\n                }\n                else if (repeatType === \"mirror\") {\n                    frameGenerator = mirroredGenerator;\n                }\n            }\n            elapsed = clamp(0, 1, iterationProgress) * resolvedDuration;\n        }\n        /**\n         * If we're in negative time, set state as the initial keyframe.\n         * This prevents delay: x, duration: 0 animations from finishing\n         * instantly.\n         */\n        const state = isInDelayPhase\n            ? { done: false, value: keyframes[0] }\n            : frameGenerator.next(elapsed);\n        if (mapPercentToKeyframes) {\n            state.value = mapPercentToKeyframes(state.value);\n        }\n        let { done } = state;\n        if (!isInDelayPhase && calculatedDuration !== null) {\n            done =\n                this.speed >= 0\n                    ? this.currentTime >= totalDuration\n                    : this.currentTime <= 0;\n        }\n        const isAnimationFinished = this.holdTime === null &&\n            (this.state === \"finished\" || (this.state === \"running\" && done));\n        if (isAnimationFinished && finalKeyframe !== undefined) {\n            state.value = getFinalKeyframe(keyframes, this.options, finalKeyframe);\n        }\n        if (onUpdate) {\n            onUpdate(state.value);\n        }\n        if (isAnimationFinished) {\n            this.finish();\n        }\n        return state;\n    }\n    get duration() {\n        const { resolved } = this;\n        return resolved ? millisecondsToSeconds(resolved.calculatedDuration) : 0;\n    }\n    get time() {\n        return millisecondsToSeconds(this.currentTime);\n    }\n    set time(newTime) {\n        newTime = secondsToMilliseconds(newTime);\n        this.currentTime = newTime;\n        if (this.holdTime !== null || this.speed === 0) {\n            this.holdTime = newTime;\n        }\n        else if (this.driver) {\n            this.startTime = this.driver.now() - newTime / this.speed;\n        }\n    }\n    get speed() {\n        return this.playbackSpeed;\n    }\n    set speed(newSpeed) {\n        const hasChanged = this.playbackSpeed !== newSpeed;\n        this.playbackSpeed = newSpeed;\n        if (hasChanged) {\n            this.time = millisecondsToSeconds(this.currentTime);\n        }\n    }\n    play() {\n        if (!this.resolver.isScheduled) {\n            this.resolver.resume();\n        }\n        if (!this._resolved) {\n            this.pendingPlayState = \"running\";\n            return;\n        }\n        if (this.isStopped)\n            return;\n        const { driver = frameloopDriver, onPlay, startTime } = this.options;\n        if (!this.driver) {\n            this.driver = driver((timestamp) => this.tick(timestamp));\n        }\n        onPlay && onPlay();\n        const now = this.driver.now();\n        if (this.holdTime !== null) {\n            this.startTime = now - this.holdTime;\n        }\n        else if (!this.startTime) {\n            this.startTime = startTime !== null && startTime !== void 0 ? startTime : this.calcStartTime();\n        }\n        else if (this.state === \"finished\") {\n            this.startTime = now;\n        }\n        if (this.state === \"finished\") {\n            this.updateFinishedPromise();\n        }\n        this.cancelTime = this.startTime;\n        this.holdTime = null;\n        /**\n         * Set playState to running only after we've used it in\n         * the previous logic.\n         */\n        this.state = \"running\";\n        this.driver.start();\n    }\n    pause() {\n        var _a;\n        if (!this._resolved) {\n            this.pendingPlayState = \"paused\";\n            return;\n        }\n        this.state = \"paused\";\n        this.holdTime = (_a = this.currentTime) !== null && _a !== void 0 ? _a : 0;\n    }\n    complete() {\n        if (this.state !== \"running\") {\n            this.play();\n        }\n        this.pendingPlayState = this.state = \"finished\";\n        this.holdTime = null;\n    }\n    finish() {\n        this.teardown();\n        this.state = \"finished\";\n        const { onComplete } = this.options;\n        onComplete && onComplete();\n    }\n    cancel() {\n        if (this.cancelTime !== null) {\n            this.tick(this.cancelTime);\n        }\n        this.teardown();\n        this.updateFinishedPromise();\n    }\n    teardown() {\n        this.state = \"idle\";\n        this.stopDriver();\n        this.resolveFinishedPromise();\n        this.updateFinishedPromise();\n        this.startTime = this.cancelTime = null;\n        this.resolver.cancel();\n    }\n    stopDriver() {\n        if (!this.driver)\n            return;\n        this.driver.stop();\n        this.driver = undefined;\n    }\n    sample(time) {\n        this.startTime = 0;\n        return this.tick(time, true);\n    }\n}\n// Legacy interface\nfunction animateValue(options) {\n    return new MainThreadAnimation(options);\n}\n\nexport { MainThreadAnimation, animateValue };\n","/**\n * A list of values that can be hardware-accelerated.\n */\nconst acceleratedValues = new Set([\n    \"opacity\",\n    \"clipPath\",\n    \"filter\",\n    \"transform\",\n    // TODO: Can be accelerated but currently disabled until https://issues.chromium.org/issues/41491098 is resolved\n    // or until we implement support for linear() easing.\n    // \"background-color\"\n]);\n\nexport { acceleratedValues };\n","import { memo } from 'motion-utils';\n\nconst supportsWaapi = /*@__PURE__*/ memo(() => Object.hasOwnProperty.call(Element.prototype, \"animate\"));\n\nexport { supportsWaapi };\n","import { supportsLinearEasing, attachTimeline, isGenerator, isWaapiSupportedEasing } from 'motion-dom';\nimport { millisecondsToSeconds, secondsToMilliseconds, noop } from 'motion-utils';\nimport { anticipate } from '../../easing/anticipate.mjs';\nimport { backInOut } from '../../easing/back.mjs';\nimport { circInOut } from '../../easing/circ.mjs';\nimport { DOMKeyframesResolver } from '../../render/dom/DOMKeyframesResolver.mjs';\nimport { BaseAnimation } from './BaseAnimation.mjs';\nimport { MainThreadAnimation } from './MainThreadAnimation.mjs';\nimport { acceleratedValues } from './utils/accelerated-values.mjs';\nimport { startWaapiAnimation } from './waapi/index.mjs';\nimport { getFinalKeyframe } from './waapi/utils/get-final-keyframe.mjs';\nimport { supportsWaapi } from './waapi/utils/supports-waapi.mjs';\n\n/**\n * 10ms is chosen here as it strikes a balance between smooth\n * results (more than one keyframe per frame at 60fps) and\n * keyframe quantity.\n */\nconst sampleDelta = 10; //ms\n/**\n * Implement a practical max duration for keyframe generation\n * to prevent infinite loops\n */\nconst maxDuration = 20000;\n/**\n * Check if an animation can run natively via WAAPI or requires pregenerated keyframes.\n * WAAPI doesn't support spring or function easings so we run these as JS animation before\n * handing off.\n */\nfunction requiresPregeneratedKeyframes(options) {\n    return (isGenerator(options.type) ||\n        options.type === \"spring\" ||\n        !isWaapiSupportedEasing(options.ease));\n}\nfunction pregenerateKeyframes(keyframes, options) {\n    /**\n     * Create a main-thread animation to pregenerate keyframes.\n     * We sample this at regular intervals to generate keyframes that we then\n     * linearly interpolate between.\n     */\n    const sampleAnimation = new MainThreadAnimation({\n        ...options,\n        keyframes,\n        repeat: 0,\n        delay: 0,\n        isGenerator: true,\n    });\n    let state = { done: false, value: keyframes[0] };\n    const pregeneratedKeyframes = [];\n    /**\n     * Bail after 20 seconds of pre-generated keyframes as it's likely\n     * we're heading for an infinite loop.\n     */\n    let t = 0;\n    while (!state.done && t < maxDuration) {\n        state = sampleAnimation.sample(t);\n        pregeneratedKeyframes.push(state.value);\n        t += sampleDelta;\n    }\n    return {\n        times: undefined,\n        keyframes: pregeneratedKeyframes,\n        duration: t - sampleDelta,\n        ease: \"linear\",\n    };\n}\nconst unsupportedEasingFunctions = {\n    anticipate,\n    backInOut,\n    circInOut,\n};\nfunction isUnsupportedEase(key) {\n    return key in unsupportedEasingFunctions;\n}\nclass AcceleratedAnimation extends BaseAnimation {\n    constructor(options) {\n        super(options);\n        const { name, motionValue, element, keyframes } = this.options;\n        this.resolver = new DOMKeyframesResolver(keyframes, (resolvedKeyframes, finalKeyframe) => this.onKeyframesResolved(resolvedKeyframes, finalKeyframe), name, motionValue, element);\n        this.resolver.scheduleResolve();\n    }\n    initPlayback(keyframes, finalKeyframe) {\n        let { duration = 300, times, ease, type, motionValue, name, startTime, } = this.options;\n        /**\n         * If element has since been unmounted, return false to indicate\n         * the animation failed to initialised.\n         */\n        if (!motionValue.owner || !motionValue.owner.current) {\n            return false;\n        }\n        /**\n         * If the user has provided an easing function name that isn't supported\n         * by WAAPI (like \"anticipate\"), we need to provide the corressponding\n         * function. This will later get converted to a linear() easing function.\n         */\n        if (typeof ease === \"string\" &&\n            supportsLinearEasing() &&\n            isUnsupportedEase(ease)) {\n            ease = unsupportedEasingFunctions[ease];\n        }\n        /**\n         * If this animation needs pre-generated keyframes then generate.\n         */\n        if (requiresPregeneratedKeyframes(this.options)) {\n            const { onComplete, onUpdate, motionValue, element, ...options } = this.options;\n            const pregeneratedAnimation = pregenerateKeyframes(keyframes, options);\n            keyframes = pregeneratedAnimation.keyframes;\n            // If this is a very short animation, ensure we have\n            // at least two keyframes to animate between as older browsers\n            // can't animate between a single keyframe.\n            if (keyframes.length === 1) {\n                keyframes[1] = keyframes[0];\n            }\n            duration = pregeneratedAnimation.duration;\n            times = pregeneratedAnimation.times;\n            ease = pregeneratedAnimation.ease;\n            type = \"keyframes\";\n        }\n        const animation = startWaapiAnimation(motionValue.owner.current, name, keyframes, { ...this.options, duration, times, ease });\n        // Override the browser calculated startTime with one synchronised to other JS\n        // and WAAPI animations starting this event loop.\n        animation.startTime = startTime !== null && startTime !== void 0 ? startTime : this.calcStartTime();\n        if (this.pendingTimeline) {\n            attachTimeline(animation, this.pendingTimeline);\n            this.pendingTimeline = undefined;\n        }\n        else {\n            /**\n             * Prefer the `onfinish` prop as it's more widely supported than\n             * the `finished` promise.\n             *\n             * Here, we synchronously set the provided MotionValue to the end\n             * keyframe. If we didn't, when the WAAPI animation is finished it would\n             * be removed from the element which would then revert to its old styles.\n             */\n            animation.onfinish = () => {\n                const { onComplete } = this.options;\n                motionValue.set(getFinalKeyframe(keyframes, this.options, finalKeyframe));\n                onComplete && onComplete();\n                this.cancel();\n                this.resolveFinishedPromise();\n            };\n        }\n        return {\n            animation,\n            duration,\n            times,\n            type,\n            ease,\n            keyframes: keyframes,\n        };\n    }\n    get duration() {\n        const { resolved } = this;\n        if (!resolved)\n            return 0;\n        const { duration } = resolved;\n        return millisecondsToSeconds(duration);\n    }\n    get time() {\n        const { resolved } = this;\n        if (!resolved)\n            return 0;\n        const { animation } = resolved;\n        return millisecondsToSeconds(animation.currentTime || 0);\n    }\n    set time(newTime) {\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        const { animation } = resolved;\n        animation.currentTime = secondsToMilliseconds(newTime);\n    }\n    get speed() {\n        const { resolved } = this;\n        if (!resolved)\n            return 1;\n        const { animation } = resolved;\n        return animation.playbackRate;\n    }\n    set speed(newSpeed) {\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        const { animation } = resolved;\n        animation.playbackRate = newSpeed;\n    }\n    get state() {\n        const { resolved } = this;\n        if (!resolved)\n            return \"idle\";\n        const { animation } = resolved;\n        return animation.playState;\n    }\n    get startTime() {\n        const { resolved } = this;\n        if (!resolved)\n            return null;\n        const { animation } = resolved;\n        // Coerce to number as TypeScript incorrectly types this\n        // as CSSNumberish\n        return animation.startTime;\n    }\n    /**\n     * Replace the default DocumentTimeline with another AnimationTimeline.\n     * Currently used for scroll animations.\n     */\n    attachTimeline(timeline) {\n        if (!this._resolved) {\n            this.pendingTimeline = timeline;\n        }\n        else {\n            const { resolved } = this;\n            if (!resolved)\n                return noop;\n            const { animation } = resolved;\n            attachTimeline(animation, timeline);\n        }\n        return noop;\n    }\n    play() {\n        if (this.isStopped)\n            return;\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        const { animation } = resolved;\n        if (animation.playState === \"finished\") {\n            this.updateFinishedPromise();\n        }\n        animation.play();\n    }\n    pause() {\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        const { animation } = resolved;\n        animation.pause();\n    }\n    stop() {\n        this.resolver.cancel();\n        this.isStopped = true;\n        if (this.state === \"idle\")\n            return;\n        this.resolveFinishedPromise();\n        this.updateFinishedPromise();\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        const { animation, keyframes, duration, type, ease, times } = resolved;\n        if (animation.playState === \"idle\" ||\n            animation.playState === \"finished\") {\n            return;\n        }\n        /**\n         * WAAPI doesn't natively have any interruption capabilities.\n         *\n         * Rather than read commited styles back out of the DOM, we can\n         * create a renderless JS animation and sample it twice to calculate\n         * its current value, \"previous\" value, and therefore allow\n         * Motion to calculate velocity for any subsequent animation.\n         */\n        if (this.time) {\n            const { motionValue, onUpdate, onComplete, element, ...options } = this.options;\n            const sampleAnimation = new MainThreadAnimation({\n                ...options,\n                keyframes,\n                duration,\n                type,\n                ease,\n                times,\n                isGenerator: true,\n            });\n            const sampleTime = secondsToMilliseconds(this.time);\n            motionValue.setWithVelocity(sampleAnimation.sample(sampleTime - sampleDelta).value, sampleAnimation.sample(sampleTime).value, sampleDelta);\n        }\n        const { onStop } = this.options;\n        onStop && onStop();\n        this.cancel();\n    }\n    complete() {\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        resolved.animation.finish();\n    }\n    cancel() {\n        const { resolved } = this;\n        if (!resolved)\n            return;\n        resolved.animation.cancel();\n    }\n    static supports(options) {\n        const { motionValue, name, repeatDelay, repeatType, damping, type } = options;\n        if (!motionValue ||\n            !motionValue.owner ||\n            !(motionValue.owner.current instanceof HTMLElement)) {\n            return false;\n        }\n        const { onUpdate, transformTemplate } = motionValue.owner.getProps();\n        return (supportsWaapi() &&\n            name &&\n            acceleratedValues.has(name) &&\n            /**\n             * If we're outputting values to onUpdate then we can't use WAAPI as there's\n             * no way to read the value from WAAPI every frame.\n             */\n            !onUpdate &&\n            !transformTemplate &&\n            !repeatDelay &&\n            repeatType !== \"mirror\" &&\n            damping !== 0 &&\n            type !== \"inertia\");\n    }\n}\n\nexport { AcceleratedAnimation };\n","import { mapEasingToNativeEasing } from 'motion-dom';\n\nfunction startWaapiAnimation(element, valueName, keyframes, { delay = 0, duration = 300, repeat = 0, repeatType = \"loop\", ease = \"easeInOut\", times, } = {}) {\n    const keyframeOptions = { [valueName]: keyframes };\n    if (times)\n        keyframeOptions.offset = times;\n    const easing = mapEasingToNativeEasing(ease, duration);\n    /**\n     * If this is an easing array, apply to keyframes, not animation as a whole\n     */\n    if (Array.isArray(easing))\n        keyframeOptions.easing = easing;\n    return element.animate(keyframeOptions, {\n        delay,\n        duration,\n        easing: !Array.isArray(easing) ? easing : \"linear\",\n        fill: \"both\",\n        iterations: repeat + 1,\n        direction: repeatType === \"reverse\" ? \"alternate\" : \"normal\",\n    });\n}\n\nexport { startWaapiAnimation };\n","import { transformProps } from '../../render/html/utils/keys-transform.mjs';\n\nconst underDampedSpring = {\n    type: \"spring\",\n    stiffness: 500,\n    damping: 25,\n    restSpeed: 10,\n};\nconst criticallyDampedSpring = (target) => ({\n    type: \"spring\",\n    stiffness: 550,\n    damping: target === 0 ? 2 * Math.sqrt(550) : 30,\n    restSpeed: 10,\n});\nconst keyframesTransition = {\n    type: \"keyframes\",\n    duration: 0.8,\n};\n/**\n * Default easing curve is a slightly shallower version of\n * the default browser easing curve.\n */\nconst ease = {\n    type: \"keyframes\",\n    ease: [0.25, 0.1, 0.35, 1],\n    duration: 0.3,\n};\nconst getDefaultTransition = (valueKey, { keyframes }) => {\n    if (keyframes.length > 2) {\n        return keyframesTransition;\n    }\n    else if (transformProps.has(valueKey)) {\n        return valueKey.startsWith(\"scale\")\n            ? criticallyDampedSpring(keyframes[1])\n            : underDampedSpring;\n    }\n    return ease;\n};\n\nexport { getDefaultTransition };\n","import { getValueTransition, GroupPlaybackControls } from 'motion-dom';\nimport { secondsToMilliseconds } from 'motion-utils';\nimport { frame } from '../../frameloop/frame.mjs';\nimport { MotionGlobalConfig } from '../../utils/GlobalConfig.mjs';\nimport { instantAnimationState } from '../../utils/use-instant-transition-state.mjs';\nimport { AcceleratedAnimation } from '../animators/AcceleratedAnimation.mjs';\nimport { MainThreadAnimation } from '../animators/MainThreadAnimation.mjs';\nimport { getFinalKeyframe } from '../animators/waapi/utils/get-final-keyframe.mjs';\nimport { getDefaultTransition } from '../utils/default-transitions.mjs';\nimport { isTransitionDefined } from '../utils/is-transition-defined.mjs';\n\nconst animateMotionValue = (name, value, target, transition = {}, element, isHandoff) => (onComplete) => {\n    const valueTransition = getValueTransition(transition, name) || {};\n    /**\n     * Most transition values are currently completely overwritten by value-specific\n     * transitions. In the future it'd be nicer to blend these transitions. But for now\n     * delay actually does inherit from the root transition if not value-specific.\n     */\n    const delay = valueTransition.delay || transition.delay || 0;\n    /**\n     * Elapsed isn't a public transition option but can be passed through from\n     * optimized appear effects in milliseconds.\n     */\n    let { elapsed = 0 } = transition;\n    elapsed = elapsed - secondsToMilliseconds(delay);\n    let options = {\n        keyframes: Array.isArray(target) ? target : [null, target],\n        ease: \"easeOut\",\n        velocity: value.getVelocity(),\n        ...valueTransition,\n        delay: -elapsed,\n        onUpdate: (v) => {\n            value.set(v);\n            valueTransition.onUpdate && valueTransition.onUpdate(v);\n        },\n        onComplete: () => {\n            onComplete();\n            valueTransition.onComplete && valueTransition.onComplete();\n        },\n        name,\n        motionValue: value,\n        element: isHandoff ? undefined : element,\n    };\n    /**\n     * If there's no transition defined for this value, we can generate\n     * unqiue transition settings for this value.\n     */\n    if (!isTransitionDefined(valueTransition)) {\n        options = {\n            ...options,\n            ...getDefaultTransition(name, options),\n        };\n    }\n    /**\n     * Both WAAPI and our internal animation functions use durations\n     * as defined by milliseconds, while our external API defines them\n     * as seconds.\n     */\n    if (options.duration) {\n        options.duration = secondsToMilliseconds(options.duration);\n    }\n    if (options.repeatDelay) {\n        options.repeatDelay = secondsToMilliseconds(options.repeatDelay);\n    }\n    if (options.from !== undefined) {\n        options.keyframes[0] = options.from;\n    }\n    let shouldSkip = false;\n    if (options.type === false ||\n        (options.duration === 0 && !options.repeatDelay)) {\n        options.duration = 0;\n        if (options.delay === 0) {\n            shouldSkip = true;\n        }\n    }\n    if (instantAnimationState.current ||\n        MotionGlobalConfig.skipAnimations) {\n        shouldSkip = true;\n        options.duration = 0;\n        options.delay = 0;\n    }\n    /**\n     * If we can or must skip creating the animation, and apply only\n     * the final keyframe, do so. We also check once keyframes are resolved but\n     * this early check prevents the need to create an animation at all.\n     */\n    if (shouldSkip && !isHandoff && value.get() !== undefined) {\n        const finalKeyframe = getFinalKeyframe(options.keyframes, valueTransition);\n        if (finalKeyframe !== undefined) {\n            frame.update(() => {\n                options.onUpdate(finalKeyframe);\n                options.onComplete();\n            });\n            // We still want to return some animation controls here rather\n            // than returning undefined\n            return new GroupPlaybackControls([]);\n        }\n    }\n    /**\n     * Animate via WAAPI if possible. If this is a handoff animation, the optimised animation will be running via\n     * WAAPI. Therefore, this animation must be JS to ensure it runs \"under\" the\n     * optimised animation.\n     */\n    if (!isHandoff && AcceleratedAnimation.supports(options)) {\n        return new AcceleratedAnimation(options);\n    }\n    else {\n        return new MainThreadAnimation(options);\n    }\n};\n\nexport { animateMotionValue };\n","/**\n * Decide whether a transition is defined on a given Transition.\n * This filters out orchestration options and returns true\n * if any options are left.\n */\nfunction isTransitionDefined({ when, delay: _delay, delayChildren, staggerChildren, staggerDirection, repeat, repeatType, repeatDelay, from, elapsed, ...transition }) {\n    return !!Object.keys(transition).length;\n}\n\nexport { isTransitionDefined };\n","import { getValueTransition } from 'motion-dom';\nimport { positionalKeys } from '../../render/html/utils/keys-position.mjs';\nimport { setTarget } from '../../render/utils/setters.mjs';\nimport { addValueToWillChange } from '../../value/use-will-change/add-will-change.mjs';\nimport { getOptimisedAppearId } from '../optimized-appear/get-appear-id.mjs';\nimport { animateMotionValue } from './motion-value.mjs';\nimport { frame } from '../../frameloop/frame.mjs';\n\n/**\n * Decide whether we should block this animation. Previously, we achieved this\n * just by checking whether the key was listed in protectedKeys, but this\n * posed problems if an animation was triggered by afterChildren and protectedKeys\n * had been set to true in the meantime.\n */\nfunction shouldBlockAnimation({ protectedKeys, needsAnimating }, key) {\n    const shouldBlock = protectedKeys.hasOwnProperty(key) && needsAnimating[key] !== true;\n    needsAnimating[key] = false;\n    return shouldBlock;\n}\nfunction animateTarget(visualElement, targetAndTransition, { delay = 0, transitionOverride, type } = {}) {\n    var _a;\n    let { transition = visualElement.getDefaultTransition(), transitionEnd, ...target } = targetAndTransition;\n    if (transitionOverride)\n        transition = transitionOverride;\n    const animations = [];\n    const animationTypeState = type &&\n        visualElement.animationState &&\n        visualElement.animationState.getState()[type];\n    for (const key in target) {\n        const value = visualElement.getValue(key, (_a = visualElement.latestValues[key]) !== null && _a !== void 0 ? _a : null);\n        const valueTarget = target[key];\n        if (valueTarget === undefined ||\n            (animationTypeState &&\n                shouldBlockAnimation(animationTypeState, key))) {\n            continue;\n        }\n        const valueTransition = {\n            delay,\n            ...getValueTransition(transition || {}, key),\n        };\n        /**\n         * If this is the first time a value is being animated, check\n         * to see if we're handling off from an existing animation.\n         */\n        let isHandoff = false;\n        if (window.MotionHandoffAnimation) {\n            const appearId = getOptimisedAppearId(visualElement);\n            if (appearId) {\n                const startTime = window.MotionHandoffAnimation(appearId, key, frame);\n                if (startTime !== null) {\n                    valueTransition.startTime = startTime;\n                    isHandoff = true;\n                }\n            }\n        }\n        addValueToWillChange(visualElement, key);\n        value.start(animateMotionValue(key, value, valueTarget, visualElement.shouldReduceMotion && positionalKeys.has(key)\n            ? { type: false }\n            : valueTransition, visualElement, isHandoff));\n        const animation = value.animation;\n        if (animation) {\n            animations.push(animation);\n        }\n    }\n    if (transitionEnd) {\n        Promise.all(animations).then(() => {\n            frame.update(() => {\n                transitionEnd && setTarget(visualElement, transitionEnd);\n            });\n        });\n    }\n    return animations;\n}\n\nexport { animateTarget };\n","import { resolveVariant } from '../../render/utils/resolve-dynamic-variants.mjs';\nimport { animateTarget } from './visual-element-target.mjs';\n\nfunction animateVariant(visualElement, variant, options = {}) {\n    var _a;\n    const resolved = resolveVariant(visualElement, variant, options.type === \"exit\"\n        ? (_a = visualElement.presenceContext) === null || _a === void 0 ? void 0 : _a.custom\n        : undefined);\n    let { transition = visualElement.getDefaultTransition() || {} } = resolved || {};\n    if (options.transitionOverride) {\n        transition = options.transitionOverride;\n    }\n    /**\n     * If we have a variant, create a callback that runs it as an animation.\n     * Otherwise, we resolve a Promise immediately for a composable no-op.\n     */\n    const getAnimation = resolved\n        ? () => Promise.all(animateTarget(visualElement, resolved, options))\n        : () => Promise.resolve();\n    /**\n     * If we have children, create a callback that runs all their animations.\n     * Otherwise, we resolve a Promise immediately for a composable no-op.\n     */\n    const getChildAnimations = visualElement.variantChildren && visualElement.variantChildren.size\n        ? (forwardDelay = 0) => {\n            const { delayChildren = 0, staggerChildren, staggerDirection, } = transition;\n            return animateChildren(visualElement, variant, delayChildren + forwardDelay, staggerChildren, staggerDirection, options);\n        }\n        : () => Promise.resolve();\n    /**\n     * If the transition explicitly defines a \"when\" option, we need to resolve either\n     * this animation or all children animations before playing the other.\n     */\n    const { when } = transition;\n    if (when) {\n        const [first, last] = when === \"beforeChildren\"\n            ? [getAnimation, getChildAnimations]\n            : [getChildAnimations, getAnimation];\n        return first().then(() => last());\n    }\n    else {\n        return Promise.all([getAnimation(), getChildAnimations(options.delay)]);\n    }\n}\nfunction animateChildren(visualElement, variant, delayChildren = 0, staggerChildren = 0, staggerDirection = 1, options) {\n    const animations = [];\n    const maxStaggerDuration = (visualElement.variantChildren.size - 1) * staggerChildren;\n    const generateStaggerDuration = staggerDirection === 1\n        ? (i = 0) => i * staggerChildren\n        : (i = 0) => maxStaggerDuration - i * staggerChildren;\n    Array.from(visualElement.variantChildren)\n        .sort(sortByTreeOrder)\n        .forEach((child, i) => {\n        child.notify(\"AnimationStart\", variant);\n        animations.push(animateVariant(child, variant, {\n            ...options,\n            delay: delayChildren + generateStaggerDuration(i),\n        }).then(() => child.notify(\"AnimationComplete\", variant)));\n    });\n    return Promise.all(animations);\n}\nfunction sortByTreeOrder(a, b) {\n    return a.sortNodePosition(b);\n}\n\nexport { animateVariant, sortByTreeOrder };\n","import { isVariantLabel } from './is-variant-label.mjs';\nimport { variantProps } from './variant-props.mjs';\n\nconst numVariantProps = variantProps.length;\nfunction getVariantContext(visualElement) {\n    if (!visualElement)\n        return undefined;\n    if (!visualElement.isControllingVariants) {\n        const context = visualElement.parent\n            ? getVariantContext(visualElement.parent) || {}\n            : {};\n        if (visualElement.props.initial !== undefined) {\n            context.initial = visualElement.props.initial;\n        }\n        return context;\n    }\n    const context = {};\n    for (let i = 0; i < numVariantProps; i++) {\n        const name = variantProps[i];\n        const prop = visualElement.props[name];\n        if (isVariantLabel(prop) || prop === false) {\n            context[name] = prop;\n        }\n    }\n    return context;\n}\n\nexport { getVariantContext };\n","import { isAnimationControls } from '../../animation/utils/is-animation-controls.mjs';\nimport { isKeyframesTarget } from '../../animation/utils/is-keyframes-target.mjs';\nimport { shallowCompare } from '../../utils/shallow-compare.mjs';\nimport { isVariantLabel } from './is-variant-label.mjs';\nimport { resolveVariant } from './resolve-dynamic-variants.mjs';\nimport { variantPriorityOrder } from './variant-props.mjs';\nimport { animateVisualElement } from '../../animation/interfaces/visual-element.mjs';\nimport { getVariantContext } from './get-variant-context.mjs';\n\nconst reversePriorityOrder = [...variantPriorityOrder].reverse();\nconst numAnimationTypes = variantPriorityOrder.length;\nfunction animateList(visualElement) {\n    return (animations) => Promise.all(animations.map(({ animation, options }) => animateVisualElement(visualElement, animation, options)));\n}\nfunction createAnimationState(visualElement) {\n    let animate = animateList(visualElement);\n    let state = createState();\n    let isInitialRender = true;\n    /**\n     * This function will be used to reduce the animation definitions for\n     * each active animation type into an object of resolved values for it.\n     */\n    const buildResolvedTypeValues = (type) => (acc, definition) => {\n        var _a;\n        const resolved = resolveVariant(visualElement, definition, type === \"exit\"\n            ? (_a = visualElement.presenceContext) === null || _a === void 0 ? void 0 : _a.custom\n            : undefined);\n        if (resolved) {\n            const { transition, transitionEnd, ...target } = resolved;\n            acc = { ...acc, ...target, ...transitionEnd };\n        }\n        return acc;\n    };\n    /**\n     * This just allows us to inject mocked animation functions\n     * @internal\n     */\n    function setAnimateFunction(makeAnimator) {\n        animate = makeAnimator(visualElement);\n    }\n    /**\n     * When we receive new props, we need to:\n     * 1. Create a list of protected keys for each type. This is a directory of\n     *    value keys that are currently being \"handled\" by types of a higher priority\n     *    so that whenever an animation is played of a given type, these values are\n     *    protected from being animated.\n     * 2. Determine if an animation type needs animating.\n     * 3. Determine if any values have been removed from a type and figure out\n     *    what to animate those to.\n     */\n    function animateChanges(changedActiveType) {\n        const { props } = visualElement;\n        const context = getVariantContext(visualElement.parent) || {};\n        /**\n         * A list of animations that we'll build into as we iterate through the animation\n         * types. This will get executed at the end of the function.\n         */\n        const animations = [];\n        /**\n         * Keep track of which values have been removed. Then, as we hit lower priority\n         * animation types, we can check if they contain removed values and animate to that.\n         */\n        const removedKeys = new Set();\n        /**\n         * A dictionary of all encountered keys. This is an object to let us build into and\n         * copy it without iteration. Each time we hit an animation type we set its protected\n         * keys - the keys its not allowed to animate - to the latest version of this object.\n         */\n        let encounteredKeys = {};\n        /**\n         * If a variant has been removed at a given index, and this component is controlling\n         * variant animations, we want to ensure lower-priority variants are forced to animate.\n         */\n        let removedVariantIndex = Infinity;\n        /**\n         * Iterate through all animation types in reverse priority order. For each, we want to\n         * detect which values it's handling and whether or not they've changed (and therefore\n         * need to be animated). If any values have been removed, we want to detect those in\n         * lower priority props and flag for animation.\n         */\n        for (let i = 0; i < numAnimationTypes; i++) {\n            const type = reversePriorityOrder[i];\n            const typeState = state[type];\n            const prop = props[type] !== undefined\n                ? props[type]\n                : context[type];\n            const propIsVariant = isVariantLabel(prop);\n            /**\n             * If this type has *just* changed isActive status, set activeDelta\n             * to that status. Otherwise set to null.\n             */\n            const activeDelta = type === changedActiveType ? typeState.isActive : null;\n            if (activeDelta === false)\n                removedVariantIndex = i;\n            /**\n             * If this prop is an inherited variant, rather than been set directly on the\n             * component itself, we want to make sure we allow the parent to trigger animations.\n             *\n             * TODO: Can probably change this to a !isControllingVariants check\n             */\n            let isInherited = prop === context[type] &&\n                prop !== props[type] &&\n                propIsVariant;\n            /**\n             *\n             */\n            if (isInherited &&\n                isInitialRender &&\n                visualElement.manuallyAnimateOnMount) {\n                isInherited = false;\n            }\n            /**\n             * Set all encountered keys so far as the protected keys for this type. This will\n             * be any key that has been animated or otherwise handled by active, higher-priortiy types.\n             */\n            typeState.protectedKeys = { ...encounteredKeys };\n            // Check if we can skip analysing this prop early\n            if (\n            // If it isn't active and hasn't *just* been set as inactive\n            (!typeState.isActive && activeDelta === null) ||\n                // If we didn't and don't have any defined prop for this animation type\n                (!prop && !typeState.prevProp) ||\n                // Or if the prop doesn't define an animation\n                isAnimationControls(prop) ||\n                typeof prop === \"boolean\") {\n                continue;\n            }\n            /**\n             * As we go look through the values defined on this type, if we detect\n             * a changed value or a value that was removed in a higher priority, we set\n             * this to true and add this prop to the animation list.\n             */\n            const variantDidChange = checkVariantsDidChange(typeState.prevProp, prop);\n            let shouldAnimateType = variantDidChange ||\n                // If we're making this variant active, we want to always make it active\n                (type === changedActiveType &&\n                    typeState.isActive &&\n                    !isInherited &&\n                    propIsVariant) ||\n                // If we removed a higher-priority variant (i is in reverse order)\n                (i > removedVariantIndex && propIsVariant);\n            let handledRemovedValues = false;\n            /**\n             * As animations can be set as variant lists, variants or target objects, we\n             * coerce everything to an array if it isn't one already\n             */\n            const definitionList = Array.isArray(prop) ? prop : [prop];\n            /**\n             * Build an object of all the resolved values. We'll use this in the subsequent\n             * animateChanges calls to determine whether a value has changed.\n             */\n            let resolvedValues = definitionList.reduce(buildResolvedTypeValues(type), {});\n            if (activeDelta === false)\n                resolvedValues = {};\n            /**\n             * Now we need to loop through all the keys in the prev prop and this prop,\n             * and decide:\n             * 1. If the value has changed, and needs animating\n             * 2. If it has been removed, and needs adding to the removedKeys set\n             * 3. If it has been removed in a higher priority type and needs animating\n             * 4. If it hasn't been removed in a higher priority but hasn't changed, and\n             *    needs adding to the type's protectedKeys list.\n             */\n            const { prevResolvedValues = {} } = typeState;\n            const allKeys = {\n                ...prevResolvedValues,\n                ...resolvedValues,\n            };\n            const markToAnimate = (key) => {\n                shouldAnimateType = true;\n                if (removedKeys.has(key)) {\n                    handledRemovedValues = true;\n                    removedKeys.delete(key);\n                }\n                typeState.needsAnimating[key] = true;\n                const motionValue = visualElement.getValue(key);\n                if (motionValue)\n                    motionValue.liveStyle = false;\n            };\n            for (const key in allKeys) {\n                const next = resolvedValues[key];\n                const prev = prevResolvedValues[key];\n                // If we've already handled this we can just skip ahead\n                if (encounteredKeys.hasOwnProperty(key))\n                    continue;\n                /**\n                 * If the value has changed, we probably want to animate it.\n                 */\n                let valueHasChanged = false;\n                if (isKeyframesTarget(next) && isKeyframesTarget(prev)) {\n                    valueHasChanged = !shallowCompare(next, prev);\n                }\n                else {\n                    valueHasChanged = next !== prev;\n                }\n                if (valueHasChanged) {\n                    if (next !== undefined && next !== null) {\n                        // If next is defined and doesn't equal prev, it needs animating\n                        markToAnimate(key);\n                    }\n                    else {\n                        // If it's undefined, it's been removed.\n                        removedKeys.add(key);\n                    }\n                }\n                else if (next !== undefined && removedKeys.has(key)) {\n                    /**\n                     * If next hasn't changed and it isn't undefined, we want to check if it's\n                     * been removed by a higher priority\n                     */\n                    markToAnimate(key);\n                }\n                else {\n                    /**\n                     * If it hasn't changed, we add it to the list of protected values\n                     * to ensure it doesn't get animated.\n                     */\n                    typeState.protectedKeys[key] = true;\n                }\n            }\n            /**\n             * Update the typeState so next time animateChanges is called we can compare the\n             * latest prop and resolvedValues to these.\n             */\n            typeState.prevProp = prop;\n            typeState.prevResolvedValues = resolvedValues;\n            /**\n             *\n             */\n            if (typeState.isActive) {\n                encounteredKeys = { ...encounteredKeys, ...resolvedValues };\n            }\n            if (isInitialRender && visualElement.blockInitialAnimation) {\n                shouldAnimateType = false;\n            }\n            /**\n             * If this is an inherited prop we want to skip this animation\n             * unless the inherited variants haven't changed on this render.\n             */\n            const willAnimateViaParent = isInherited && variantDidChange;\n            const needsAnimating = !willAnimateViaParent || handledRemovedValues;\n            if (shouldAnimateType && needsAnimating) {\n                animations.push(...definitionList.map((animation) => ({\n                    animation: animation,\n                    options: { type },\n                })));\n            }\n        }\n        /**\n         * If there are some removed value that haven't been dealt with,\n         * we need to create a new animation that falls back either to the value\n         * defined in the style prop, or the last read value.\n         */\n        if (removedKeys.size) {\n            const fallbackAnimation = {};\n            removedKeys.forEach((key) => {\n                const fallbackTarget = visualElement.getBaseTarget(key);\n                const motionValue = visualElement.getValue(key);\n                if (motionValue)\n                    motionValue.liveStyle = true;\n                // @ts-expect-error - @mattgperry to figure if we should do something here\n                fallbackAnimation[key] = fallbackTarget !== null && fallbackTarget !== void 0 ? fallbackTarget : null;\n            });\n            animations.push({ animation: fallbackAnimation });\n        }\n        let shouldAnimate = Boolean(animations.length);\n        if (isInitialRender &&\n            (props.initial === false || props.initial === props.animate) &&\n            !visualElement.manuallyAnimateOnMount) {\n            shouldAnimate = false;\n        }\n        isInitialRender = false;\n        return shouldAnimate ? animate(animations) : Promise.resolve();\n    }\n    /**\n     * Change whether a certain animation type is active.\n     */\n    function setActive(type, isActive) {\n        var _a;\n        // If the active state hasn't changed, we can safely do nothing here\n        if (state[type].isActive === isActive)\n            return Promise.resolve();\n        // Propagate active change to children\n        (_a = visualElement.variantChildren) === null || _a === void 0 ? void 0 : _a.forEach((child) => { var _a; return (_a = child.animationState) === null || _a === void 0 ? void 0 : _a.setActive(type, isActive); });\n        state[type].isActive = isActive;\n        const animations = animateChanges(type);\n        for (const key in state) {\n            state[key].protectedKeys = {};\n        }\n        return animations;\n    }\n    return {\n        animateChanges,\n        setActive,\n        setAnimateFunction,\n        getState: () => state,\n        reset: () => {\n            state = createState();\n            isInitialRender = true;\n        },\n    };\n}\nfunction checkVariantsDidChange(prev, next) {\n    if (typeof next === \"string\") {\n        return next !== prev;\n    }\n    else if (Array.isArray(next)) {\n        return !shallowCompare(next, prev);\n    }\n    return false;\n}\nfunction createTypeState(isActive = false) {\n    return {\n        isActive,\n        protectedKeys: {},\n        needsAnimating: {},\n        prevResolvedValues: {},\n    };\n}\nfunction createState() {\n    return {\n        animate: createTypeState(true),\n        whileInView: createTypeState(),\n        whileHover: createTypeState(),\n        whileTap: createTypeState(),\n        whileDrag: createTypeState(),\n        whileFocus: createTypeState(),\n        exit: createTypeState(),\n    };\n}\n\nexport { checkVariantsDidChange, createAnimationState };\n","import { resolveVariant } from '../../render/utils/resolve-dynamic-variants.mjs';\nimport { animateTarget } from './visual-element-target.mjs';\nimport { animateVariant } from './visual-element-variant.mjs';\n\nfunction animateVisualElement(visualElement, definition, options = {}) {\n    visualElement.notify(\"AnimationStart\", definition);\n    let animation;\n    if (Array.isArray(definition)) {\n        const animations = definition.map((variant) => animateVariant(visualElement, variant, options));\n        animation = Promise.all(animations);\n    }\n    else if (typeof definition === \"string\") {\n        animation = animateVariant(visualElement, definition, options);\n    }\n    else {\n        const resolvedDefinition = typeof definition === \"function\"\n            ? resolveVariant(visualElement, definition, options.custom)\n            : definition;\n        animation = Promise.all(animateTarget(visualElement, resolvedDefinition, options));\n    }\n    return animation.then(() => {\n        visualElement.notify(\"AnimationComplete\", definition);\n    });\n}\n\nexport { animateVisualElement };\n","class Feature {\n    constructor(node) {\n        this.isMounted = false;\n        this.node = node;\n    }\n    update() { }\n}\n\nexport { Feature };\n","import { Feature } from '../Feature.mjs';\n\nlet id = 0;\nclass ExitAnimationFeature extends Feature {\n    constructor() {\n        super(...arguments);\n        this.id = id++;\n    }\n    update() {\n        if (!this.node.presenceContext)\n            return;\n        const { isPresent, onExitComplete } = this.node.presenceContext;\n        const { isPresent: prevIsPresent } = this.node.prevPresenceContext || {};\n        if (!this.node.animationState || isPresent === prevIsPresent) {\n            return;\n        }\n        const exitAnimation = this.node.animationState.setActive(\"exit\", !isPresent);\n        if (onExitComplete && !isPresent) {\n            exitAnimation.then(() => onExitComplete(this.id));\n        }\n    }\n    mount() {\n        const { register } = this.node.presenceContext || {};\n        if (register) {\n            this.unmount = register(this.id);\n        }\n    }\n    unmount() { }\n}\n\nexport { ExitAnimationFeature };\n","import { AnimationFeature } from './animation/index.mjs';\nimport { ExitAnimationFeature } from './animation/exit.mjs';\n\nconst animations = {\n    animation: {\n        Feature: AnimationFeature,\n    },\n    exit: {\n        Feature: ExitAnimationFeature,\n    },\n};\n\nexport { animations };\n","import { isAnimationControls } from '../../../animation/utils/is-animation-controls.mjs';\nimport { createAnimationState } from '../../../render/utils/animation-state.mjs';\nimport { Feature } from '../Feature.mjs';\n\nclass AnimationFeature extends Feature {\n    /**\n     * We dynamically generate the AnimationState manager as it contains a reference\n     * to the underlying animation library. We only want to load that if we load this,\n     * so people can optionally code split it out using the `m` component.\n     */\n    constructor(node) {\n        super(node);\n        node.animationState || (node.animationState = createAnimationState(node));\n    }\n    updateAnimationControlsSubscription() {\n        const { animate } = this.node.getProps();\n        if (isAnimationControls(animate)) {\n            this.unmountControls = animate.subscribe(this.node);\n        }\n    }\n    /**\n     * Subscribe any provided AnimationControls to the component's VisualElement\n     */\n    mount() {\n        this.updateAnimationControlsSubscription();\n    }\n    update() {\n        const { animate } = this.node.getProps();\n        const { animate: prevAnimate } = this.node.prevProps || {};\n        if (animate !== prevAnimate) {\n            this.updateAnimationControlsSubscription();\n        }\n    }\n    unmount() {\n        var _a;\n        this.node.animationState.reset();\n        (_a = this.unmountControls) === null || _a === void 0 ? void 0 : _a.call(this);\n    }\n}\n\nexport { AnimationFeature };\n","function addDomEvent(target, eventName, handler, options = { passive: true }) {\n    target.addEventListener(eventName, handler, options);\n    return () => target.removeEventListener(eventName, handler);\n}\n\nexport { addDomEvent };\n","import { isPrimaryPointer } from 'motion-dom';\n\nfunction extractEventInfo(event) {\n    return {\n        point: {\n            x: event.pageX,\n            y: event.pageY,\n        },\n    };\n}\nconst addPointerInfo = (handler) => {\n    return (event) => isPrimaryPointer(event) && handler(event, extractEventInfo(event));\n};\n\nexport { addPointerInfo, extractEventInfo };\n","import { addDomEvent } from './add-dom-event.mjs';\nimport { addPointerInfo } from './event-info.mjs';\n\nfunction addPointerEvent(target, eventName, handler, options) {\n    return addDomEvent(target, eventName, addPointerInfo(handler), options);\n}\n\nexport { addPointerEvent };\n","const distance = (a, b) => Math.abs(a - b);\nfunction distance2D(a, b) {\n    // Multi-dimensional\n    const xDelta = distance(a.x, b.x);\n    const yDelta = distance(a.y, b.y);\n    return Math.sqrt(xDelta ** 2 + yDelta ** 2);\n}\n\nexport { distance, distance2D };\n","import { isPrimaryPointer } from 'motion-dom';\nimport { secondsToMilliseconds, millisecondsToSeconds } from 'motion-utils';\nimport { addPointerEvent } from '../../events/add-pointer-event.mjs';\nimport { extractEventInfo } from '../../events/event-info.mjs';\nimport { distance2D } from '../../utils/distance.mjs';\nimport { pipe } from '../../utils/pipe.mjs';\nimport { frame, cancelFrame, frameData } from '../../frameloop/frame.mjs';\n\n/**\n * @internal\n */\nclass PanSession {\n    constructor(event, handlers, { transformPagePoint, contextWindow, dragSnapToOrigin = false, } = {}) {\n        /**\n         * @internal\n         */\n        this.startEvent = null;\n        /**\n         * @internal\n         */\n        this.lastMoveEvent = null;\n        /**\n         * @internal\n         */\n        this.lastMoveEventInfo = null;\n        /**\n         * @internal\n         */\n        this.handlers = {};\n        /**\n         * @internal\n         */\n        this.contextWindow = window;\n        this.updatePoint = () => {\n            if (!(this.lastMoveEvent && this.lastMoveEventInfo))\n                return;\n            const info = getPanInfo(this.lastMoveEventInfo, this.history);\n            const isPanStarted = this.startEvent !== null;\n            // Only start panning if the offset is larger than 3 pixels. If we make it\n            // any larger than this we'll want to reset the pointer history\n            // on the first update to avoid visual snapping to the cursoe.\n            const isDistancePastThreshold = distance2D(info.offset, { x: 0, y: 0 }) >= 3;\n            if (!isPanStarted && !isDistancePastThreshold)\n                return;\n            const { point } = info;\n            const { timestamp } = frameData;\n            this.history.push({ ...point, timestamp });\n            const { onStart, onMove } = this.handlers;\n            if (!isPanStarted) {\n                onStart && onStart(this.lastMoveEvent, info);\n                this.startEvent = this.lastMoveEvent;\n            }\n            onMove && onMove(this.lastMoveEvent, info);\n        };\n        this.handlePointerMove = (event, info) => {\n            this.lastMoveEvent = event;\n            this.lastMoveEventInfo = transformPoint(info, this.transformPagePoint);\n            // Throttle mouse move event to once per frame\n            frame.update(this.updatePoint, true);\n        };\n        this.handlePointerUp = (event, info) => {\n            this.end();\n            const { onEnd, onSessionEnd, resumeAnimation } = this.handlers;\n            if (this.dragSnapToOrigin)\n                resumeAnimation && resumeAnimation();\n            if (!(this.lastMoveEvent && this.lastMoveEventInfo))\n                return;\n            const panInfo = getPanInfo(event.type === \"pointercancel\"\n                ? this.lastMoveEventInfo\n                : transformPoint(info, this.transformPagePoint), this.history);\n            if (this.startEvent && onEnd) {\n                onEnd(event, panInfo);\n            }\n            onSessionEnd && onSessionEnd(event, panInfo);\n        };\n        // If we have more than one touch, don't start detecting this gesture\n        if (!isPrimaryPointer(event))\n            return;\n        this.dragSnapToOrigin = dragSnapToOrigin;\n        this.handlers = handlers;\n        this.transformPagePoint = transformPagePoint;\n        this.contextWindow = contextWindow || window;\n        const info = extractEventInfo(event);\n        const initialInfo = transformPoint(info, this.transformPagePoint);\n        const { point } = initialInfo;\n        const { timestamp } = frameData;\n        this.history = [{ ...point, timestamp }];\n        const { onSessionStart } = handlers;\n        onSessionStart &&\n            onSessionStart(event, getPanInfo(initialInfo, this.history));\n        this.removeListeners = pipe(addPointerEvent(this.contextWindow, \"pointermove\", this.handlePointerMove), addPointerEvent(this.contextWindow, \"pointerup\", this.handlePointerUp), addPointerEvent(this.contextWindow, \"pointercancel\", this.handlePointerUp));\n    }\n    updateHandlers(handlers) {\n        this.handlers = handlers;\n    }\n    end() {\n        this.removeListeners && this.removeListeners();\n        cancelFrame(this.updatePoint);\n    }\n}\nfunction transformPoint(info, transformPagePoint) {\n    return transformPagePoint ? { point: transformPagePoint(info.point) } : info;\n}\nfunction subtractPoint(a, b) {\n    return { x: a.x - b.x, y: a.y - b.y };\n}\nfunction getPanInfo({ point }, history) {\n    return {\n        point,\n        delta: subtractPoint(point, lastDevicePoint(history)),\n        offset: subtractPoint(point, startDevicePoint(history)),\n        velocity: getVelocity(history, 0.1),\n    };\n}\nfunction startDevicePoint(history) {\n    return history[0];\n}\nfunction lastDevicePoint(history) {\n    return history[history.length - 1];\n}\nfunction getVelocity(history, timeDelta) {\n    if (history.length < 2) {\n        return { x: 0, y: 0 };\n    }\n    let i = history.length - 1;\n    let timestampedPoint = null;\n    const lastPoint = lastDevicePoint(history);\n    while (i >= 0) {\n        timestampedPoint = history[i];\n        if (lastPoint.timestamp - timestampedPoint.timestamp >\n            secondsToMilliseconds(timeDelta)) {\n            break;\n        }\n        i--;\n    }\n    if (!timestampedPoint) {\n        return { x: 0, y: 0 };\n    }\n    const time = millisecondsToSeconds(lastPoint.timestamp - timestampedPoint.timestamp);\n    if (time === 0) {\n        return { x: 0, y: 0 };\n    }\n    const currentVelocity = {\n        x: (lastPoint.x - timestampedPoint.x) / time,\n        y: (lastPoint.y - timestampedPoint.y) / time,\n    };\n    if (currentVelocity.x === Infinity) {\n        currentVelocity.x = 0;\n    }\n    if (currentVelocity.y === Infinity) {\n        currentVelocity.y = 0;\n    }\n    return currentVelocity;\n}\n\nexport { PanSession };\n","function isRefObject(ref) {\n    return (ref &&\n        typeof ref === \"object\" &&\n        Object.prototype.hasOwnProperty.call(ref, \"current\"));\n}\n\nexport { isRefObject };\n","import { mixNumber } from '../../utils/mix/number.mjs';\n\nconst SCALE_PRECISION = 0.0001;\nconst SCALE_MIN = 1 - SCALE_PRECISION;\nconst SCALE_MAX = 1 + SCALE_PRECISION;\nconst TRANSLATE_PRECISION = 0.01;\nconst TRANSLATE_MIN = 0 - TRANSLATE_PRECISION;\nconst TRANSLATE_MAX = 0 + TRANSLATE_PRECISION;\nfunction calcLength(axis) {\n    return axis.max - axis.min;\n}\nfunction isNear(value, target, maxDistance) {\n    return Math.abs(value - target) <= maxDistance;\n}\nfunction calcAxisDelta(delta, source, target, origin = 0.5) {\n    delta.origin = origin;\n    delta.originPoint = mixNumber(source.min, source.max, delta.origin);\n    delta.scale = calcLength(target) / calcLength(source);\n    delta.translate =\n        mixNumber(target.min, target.max, delta.origin) - delta.originPoint;\n    if ((delta.scale >= SCALE_MIN && delta.scale <= SCALE_MAX) ||\n        isNaN(delta.scale)) {\n        delta.scale = 1.0;\n    }\n    if ((delta.translate >= TRANSLATE_MIN &&\n        delta.translate <= TRANSLATE_MAX) ||\n        isNaN(delta.translate)) {\n        delta.translate = 0.0;\n    }\n}\nfunction calcBoxDelta(delta, source, target, origin) {\n    calcAxisDelta(delta.x, source.x, target.x, origin ? origin.originX : undefined);\n    calcAxisDelta(delta.y, source.y, target.y, origin ? origin.originY : undefined);\n}\nfunction calcRelativeAxis(target, relative, parent) {\n    target.min = parent.min + relative.min;\n    target.max = target.min + calcLength(relative);\n}\nfunction calcRelativeBox(target, relative, parent) {\n    calcRelativeAxis(target.x, relative.x, parent.x);\n    calcRelativeAxis(target.y, relative.y, parent.y);\n}\nfunction calcRelativeAxisPosition(target, layout, parent) {\n    target.min = layout.min - parent.min;\n    target.max = target.min + calcLength(layout);\n}\nfunction calcRelativePosition(target, layout, parent) {\n    calcRelativeAxisPosition(target.x, layout.x, parent.x);\n    calcRelativeAxisPosition(target.y, layout.y, parent.y);\n}\n\nexport { calcAxisDelta, calcBoxDelta, calcLength, calcRelativeAxis, calcRelativeAxisPosition, calcRelativeBox, calcRelativePosition, isNear };\n","import { progress } from 'motion-utils';\nimport { calcLength } from '../../../projection/geometry/delta-calc.mjs';\nimport { clamp } from '../../../utils/clamp.mjs';\nimport { mixNumber } from '../../../utils/mix/number.mjs';\n\n/**\n * Apply constraints to a point. These constraints are both physical along an\n * axis, and an elastic factor that determines how much to constrain the point\n * by if it does lie outside the defined parameters.\n */\nfunction applyConstraints(point, { min, max }, elastic) {\n    if (min !== undefined && point < min) {\n        // If we have a min point defined, and this is outside of that, constrain\n        point = elastic\n            ? mixNumber(min, point, elastic.min)\n            : Math.max(point, min);\n    }\n    else if (max !== undefined && point > max) {\n        // If we have a max point defined, and this is outside of that, constrain\n        point = elastic\n            ? mixNumber(max, point, elastic.max)\n            : Math.min(point, max);\n    }\n    return point;\n}\n/**\n * Calculate constraints in terms of the viewport when defined relatively to the\n * measured axis. This is measured from the nearest edge, so a max constraint of 200\n * on an axis with a max value of 300 would return a constraint of 500 - axis length\n */\nfunction calcRelativeAxisConstraints(axis, min, max) {\n    return {\n        min: min !== undefined ? axis.min + min : undefined,\n        max: max !== undefined\n            ? axis.max + max - (axis.max - axis.min)\n            : undefined,\n    };\n}\n/**\n * Calculate constraints in terms of the viewport when\n * defined relatively to the measured bounding box.\n */\nfunction calcRelativeConstraints(layoutBox, { top, left, bottom, right }) {\n    return {\n        x: calcRelativeAxisConstraints(layoutBox.x, left, right),\n        y: calcRelativeAxisConstraints(layoutBox.y, top, bottom),\n    };\n}\n/**\n * Calculate viewport constraints when defined as another viewport-relative axis\n */\nfunction calcViewportAxisConstraints(layoutAxis, constraintsAxis) {\n    let min = constraintsAxis.min - layoutAxis.min;\n    let max = constraintsAxis.max - layoutAxis.max;\n    // If the constraints axis is actually smaller than the layout axis then we can\n    // flip the constraints\n    if (constraintsAxis.max - constraintsAxis.min <\n        layoutAxis.max - layoutAxis.min) {\n        [min, max] = [max, min];\n    }\n    return { min, max };\n}\n/**\n * Calculate viewport constraints when defined as another viewport-relative box\n */\nfunction calcViewportConstraints(layoutBox, constraintsBox) {\n    return {\n        x: calcViewportAxisConstraints(layoutBox.x, constraintsBox.x),\n        y: calcViewportAxisConstraints(layoutBox.y, constraintsBox.y),\n    };\n}\n/**\n * Calculate a transform origin relative to the source axis, between 0-1, that results\n * in an asthetically pleasing scale/transform needed to project from source to target.\n */\nfunction calcOrigin(source, target) {\n    let origin = 0.5;\n    const sourceLength = calcLength(source);\n    const targetLength = calcLength(target);\n    if (targetLength > sourceLength) {\n        origin = progress(target.min, target.max - sourceLength, source.min);\n    }\n    else if (sourceLength > targetLength) {\n        origin = progress(source.min, source.max - targetLength, target.min);\n    }\n    return clamp(0, 1, origin);\n}\n/**\n * Rebase the calculated viewport constraints relative to the layout.min point.\n */\nfunction rebaseAxisConstraints(layout, constraints) {\n    const relativeConstraints = {};\n    if (constraints.min !== undefined) {\n        relativeConstraints.min = constraints.min - layout.min;\n    }\n    if (constraints.max !== undefined) {\n        relativeConstraints.max = constraints.max - layout.min;\n    }\n    return relativeConstraints;\n}\nconst defaultElastic = 0.35;\n/**\n * Accepts a dragElastic prop and returns resolved elastic values for each axis.\n */\nfunction resolveDragElastic(dragElastic = defaultElastic) {\n    if (dragElastic === false) {\n        dragElastic = 0;\n    }\n    else if (dragElastic === true) {\n        dragElastic = defaultElastic;\n    }\n    return {\n        x: resolveAxisElastic(dragElastic, \"left\", \"right\"),\n        y: resolveAxisElastic(dragElastic, \"top\", \"bottom\"),\n    };\n}\nfunction resolveAxisElastic(dragElastic, minLabel, maxLabel) {\n    return {\n        min: resolvePointElastic(dragElastic, minLabel),\n        max: resolvePointElastic(dragElastic, maxLabel),\n    };\n}\nfunction resolvePointElastic(dragElastic, label) {\n    return typeof dragElastic === \"number\"\n        ? dragElastic\n        : dragElastic[label] || 0;\n}\n\nexport { applyConstraints, calcOrigin, calcRelativeAxisConstraints, calcRelativeConstraints, calcViewportAxisConstraints, calcViewportConstraints, defaultElastic, rebaseAxisConstraints, resolveAxisElastic, resolveDragElastic, resolvePointElastic };\n","const createAxisDelta = () => ({\n    translate: 0,\n    scale: 1,\n    origin: 0,\n    originPoint: 0,\n});\nconst createDelta = () => ({\n    x: createAxisDelta(),\n    y: createAxisDelta(),\n});\nconst createAxis = () => ({ min: 0, max: 0 });\nconst createBox = () => ({\n    x: createAxis(),\n    y: createAxis(),\n});\n\nexport { createAxis, createAxisDelta, createBox, createDelta };\n","function eachAxis(callback) {\n    return [callback(\"x\"), callback(\"y\")];\n}\n\nexport { eachAxis };\n","/**\n * Bounding boxes tend to be defined as top, left, right, bottom. For various operations\n * it's easier to consider each axis individually. This function returns a bounding box\n * as a map of single-axis min/max values.\n */\nfunction convertBoundingBoxToBox({ top, left, right, bottom, }) {\n    return {\n        x: { min: left, max: right },\n        y: { min: top, max: bottom },\n    };\n}\nfunction convertBoxToBoundingBox({ x, y }) {\n    return { top: y.min, right: x.max, bottom: y.max, left: x.min };\n}\n/**\n * Applies a TransformPoint function to a bounding box. TransformPoint is usually a function\n * provided by Framer to allow measured points to be corrected for device scaling. This is used\n * when measuring DOM elements and DOM event points.\n */\nfunction transformBoxPoints(point, transformPoint) {\n    if (!transformPoint)\n        return point;\n    const topLeft = transformPoint({ x: point.left, y: point.top });\n    const bottomRight = transformPoint({ x: point.right, y: point.bottom });\n    return {\n        top: topLeft.y,\n        left: topLeft.x,\n        bottom: bottomRight.y,\n        right: bottomRight.x,\n    };\n}\n\nexport { convertBoundingBoxToBox, convertBoxToBoundingBox, transformBoxPoints };\n","function isIdentityScale(scale) {\n    return scale === undefined || scale === 1;\n}\nfunction hasScale({ scale, scaleX, scaleY }) {\n    return (!isIdentityScale(scale) ||\n        !isIdentityScale(scaleX) ||\n        !isIdentityScale(scaleY));\n}\nfunction hasTransform(values) {\n    return (hasScale(values) ||\n        has2DTranslate(values) ||\n        values.z ||\n        values.rotate ||\n        values.rotateX ||\n        values.rotateY ||\n        values.skewX ||\n        values.skewY);\n}\nfunction has2DTranslate(values) {\n    return is2DTranslate(values.x) || is2DTranslate(values.y);\n}\nfunction is2DTranslate(value) {\n    return value && value !== \"0%\";\n}\n\nexport { has2DTranslate, hasScale, hasTransform };\n","import { mixNumber } from '../../utils/mix/number.mjs';\nimport { hasTransform } from '../utils/has-transform.mjs';\n\n/**\n * Scales a point based on a factor and an originPoint\n */\nfunction scalePoint(point, scale, originPoint) {\n    const distanceFromOrigin = point - originPoint;\n    const scaled = scale * distanceFromOrigin;\n    return originPoint + scaled;\n}\n/**\n * Applies a translate/scale delta to a point\n */\nfunction applyPointDelta(point, translate, scale, originPoint, boxScale) {\n    if (boxScale !== undefined) {\n        point = scalePoint(point, boxScale, originPoint);\n    }\n    return scalePoint(point, scale, originPoint) + translate;\n}\n/**\n * Applies a translate/scale delta to an axis\n */\nfunction applyAxisDelta(axis, translate = 0, scale = 1, originPoint, boxScale) {\n    axis.min = applyPointDelta(axis.min, translate, scale, originPoint, boxScale);\n    axis.max = applyPointDelta(axis.max, translate, scale, originPoint, boxScale);\n}\n/**\n * Applies a translate/scale delta to a box\n */\nfunction applyBoxDelta(box, { x, y }) {\n    applyAxisDelta(box.x, x.translate, x.scale, x.originPoint);\n    applyAxisDelta(box.y, y.translate, y.scale, y.originPoint);\n}\nconst TREE_SCALE_SNAP_MIN = 0.999999999999;\nconst TREE_SCALE_SNAP_MAX = 1.0000000000001;\n/**\n * Apply a tree of deltas to a box. We do this to calculate the effect of all the transforms\n * in a tree upon our box before then calculating how to project it into our desired viewport-relative box\n *\n * This is the final nested loop within updateLayoutDelta for future refactoring\n */\nfunction applyTreeDeltas(box, treeScale, treePath, isSharedTransition = false) {\n    const treeLength = treePath.length;\n    if (!treeLength)\n        return;\n    // Reset the treeScale\n    treeScale.x = treeScale.y = 1;\n    let node;\n    let delta;\n    for (let i = 0; i < treeLength; i++) {\n        node = treePath[i];\n        delta = node.projectionDelta;\n        /**\n         * TODO: Prefer to remove this, but currently we have motion components with\n         * display: contents in Framer.\n         */\n        const { visualElement } = node.options;\n        if (visualElement &&\n            visualElement.props.style &&\n            visualElement.props.style.display === \"contents\") {\n            continue;\n        }\n        if (isSharedTransition &&\n            node.options.layoutScroll &&\n            node.scroll &&\n            node !== node.root) {\n            transformBox(box, {\n                x: -node.scroll.offset.x,\n                y: -node.scroll.offset.y,\n            });\n        }\n        if (delta) {\n            // Incoporate each ancestor's scale into a culmulative treeScale for this component\n            treeScale.x *= delta.x.scale;\n            treeScale.y *= delta.y.scale;\n            // Apply each ancestor's calculated delta into this component's recorded layout box\n            applyBoxDelta(box, delta);\n        }\n        if (isSharedTransition && hasTransform(node.latestValues)) {\n            transformBox(box, node.latestValues);\n        }\n    }\n    /**\n     * Snap tree scale back to 1 if it's within a non-perceivable threshold.\n     * This will help reduce useless scales getting rendered.\n     */\n    if (treeScale.x < TREE_SCALE_SNAP_MAX &&\n        treeScale.x > TREE_SCALE_SNAP_MIN) {\n        treeScale.x = 1.0;\n    }\n    if (treeScale.y < TREE_SCALE_SNAP_MAX &&\n        treeScale.y > TREE_SCALE_SNAP_MIN) {\n        treeScale.y = 1.0;\n    }\n}\nfunction translateAxis(axis, distance) {\n    axis.min = axis.min + distance;\n    axis.max = axis.max + distance;\n}\n/**\n * Apply a transform to an axis from the latest resolved motion values.\n * This function basically acts as a bridge between a flat motion value map\n * and applyAxisDelta\n */\nfunction transformAxis(axis, axisTranslate, axisScale, boxScale, axisOrigin = 0.5) {\n    const originPoint = mixNumber(axis.min, axis.max, axisOrigin);\n    // Apply the axis delta to the final axis\n    applyAxisDelta(axis, axisTranslate, axisScale, originPoint, boxScale);\n}\n/**\n * Apply a transform to a box from the latest resolved motion values.\n */\nfunction transformBox(box, transform) {\n    transformAxis(box.x, transform.x, transform.scaleX, transform.scale, transform.originX);\n    transformAxis(box.y, transform.y, transform.scaleY, transform.scale, transform.originY);\n}\n\nexport { applyAxisDelta, applyBoxDelta, applyPointDelta, applyTreeDeltas, scalePoint, transformAxis, transformBox, translateAxis };\n","import { convertBoundingBoxToBox, transformBoxPoints } from '../geometry/conversion.mjs';\nimport { translateAxis } from '../geometry/delta-apply.mjs';\n\nfunction measureViewportBox(instance, transformPoint) {\n    return convertBoundingBoxToBox(transformBoxPoints(instance.getBoundingClientRect(), transformPoint));\n}\nfunction measurePageBox(element, rootProjectionNode, transformPagePoint) {\n    const viewportBox = measureViewportBox(element, transformPagePoint);\n    const { scroll } = rootProjectionNode;\n    if (scroll) {\n        translateAxis(viewportBox.x, scroll.offset.x);\n        translateAxis(viewportBox.y, scroll.offset.y);\n    }\n    return viewportBox;\n}\n\nexport { measurePageBox, measureViewportBox };\n","// Fixes https://github.com/motiondivision/motion/issues/2270\nconst getContextWindow = ({ current }) => {\n    return current ? current.ownerDocument.defaultView : null;\n};\n\nexport { getContextWindow };\n","import { invariant } from 'motion-utils';\nimport { setDragLock } from 'motion-dom';\nimport { PanSession } from '../pan/PanSession.mjs';\nimport { isRefObject } from '../../utils/is-ref-object.mjs';\nimport { addPointerEvent } from '../../events/add-pointer-event.mjs';\nimport { applyConstraints, calcRelativeConstraints, resolveDragElastic, rebaseAxisConstraints, calcViewportConstraints, calcOrigin, defaultElastic } from './utils/constraints.mjs';\nimport { createBox } from '../../projection/geometry/models.mjs';\nimport { eachAxis } from '../../projection/utils/each-axis.mjs';\nimport { measurePageBox } from '../../projection/utils/measure.mjs';\nimport { extractEventInfo } from '../../events/event-info.mjs';\nimport { convertBoxToBoundingBox, convertBoundingBoxToBox } from '../../projection/geometry/conversion.mjs';\nimport { addDomEvent } from '../../events/add-dom-event.mjs';\nimport { calcLength } from '../../projection/geometry/delta-calc.mjs';\nimport { mixNumber } from '../../utils/mix/number.mjs';\nimport { percent } from '../../value/types/numbers/units.mjs';\nimport { animateMotionValue } from '../../animation/interfaces/motion-value.mjs';\nimport { getContextWindow } from '../../utils/get-context-window.mjs';\nimport { addValueToWillChange } from '../../value/use-will-change/add-will-change.mjs';\nimport { frame } from '../../frameloop/frame.mjs';\n\nconst elementDragControls = new WeakMap();\n/**\n *\n */\n// let latestPointerEvent: PointerEvent\nclass VisualElementDragControls {\n    constructor(visualElement) {\n        this.openDragLock = null;\n        this.isDragging = false;\n        this.currentDirection = null;\n        this.originPoint = { x: 0, y: 0 };\n        /**\n         * The permitted boundaries of travel, in pixels.\n         */\n        this.constraints = false;\n        this.hasMutatedConstraints = false;\n        /**\n         * The per-axis resolved elastic values.\n         */\n        this.elastic = createBox();\n        this.visualElement = visualElement;\n    }\n    start(originEvent, { snapToCursor = false } = {}) {\n        /**\n         * Don't start dragging if this component is exiting\n         */\n        const { presenceContext } = this.visualElement;\n        if (presenceContext && presenceContext.isPresent === false)\n            return;\n        const onSessionStart = (event) => {\n            const { dragSnapToOrigin } = this.getProps();\n            // Stop or pause any animations on both axis values immediately. This allows the user to throw and catch\n            // the component.\n            dragSnapToOrigin ? this.pauseAnimation() : this.stopAnimation();\n            if (snapToCursor) {\n                this.snapToCursor(extractEventInfo(event).point);\n            }\n        };\n        const onStart = (event, info) => {\n            // Attempt to grab the global drag gesture lock - maybe make this part of PanSession\n            const { drag, dragPropagation, onDragStart } = this.getProps();\n            if (drag && !dragPropagation) {\n                if (this.openDragLock)\n                    this.openDragLock();\n                this.openDragLock = setDragLock(drag);\n                // If we don 't have the lock, don't start dragging\n                if (!this.openDragLock)\n                    return;\n            }\n            this.isDragging = true;\n            this.currentDirection = null;\n            this.resolveConstraints();\n            if (this.visualElement.projection) {\n                this.visualElement.projection.isAnimationBlocked = true;\n                this.visualElement.projection.target = undefined;\n            }\n            /**\n             * Record gesture origin\n             */\n            eachAxis((axis) => {\n                let current = this.getAxisMotionValue(axis).get() || 0;\n                /**\n                 * If the MotionValue is a percentage value convert to px\n                 */\n                if (percent.test(current)) {\n                    const { projection } = this.visualElement;\n                    if (projection && projection.layout) {\n                        const measuredAxis = projection.layout.layoutBox[axis];\n                        if (measuredAxis) {\n                            const length = calcLength(measuredAxis);\n                            current = length * (parseFloat(current) / 100);\n                        }\n                    }\n                }\n                this.originPoint[axis] = current;\n            });\n            // Fire onDragStart event\n            if (onDragStart) {\n                frame.postRender(() => onDragStart(event, info));\n            }\n            addValueToWillChange(this.visualElement, \"transform\");\n            const { animationState } = this.visualElement;\n            animationState && animationState.setActive(\"whileDrag\", true);\n        };\n        const onMove = (event, info) => {\n            // latestPointerEvent = event\n            const { dragPropagation, dragDirectionLock, onDirectionLock, onDrag, } = this.getProps();\n            // If we didn't successfully receive the gesture lock, early return.\n            if (!dragPropagation && !this.openDragLock)\n                return;\n            const { offset } = info;\n            // Attempt to detect drag direction if directionLock is true\n            if (dragDirectionLock && this.currentDirection === null) {\n                this.currentDirection = getCurrentDirection(offset);\n                // If we've successfully set a direction, notify listener\n                if (this.currentDirection !== null) {\n                    onDirectionLock && onDirectionLock(this.currentDirection);\n                }\n                return;\n            }\n            // Update each point with the latest position\n            this.updateAxis(\"x\", info.point, offset);\n            this.updateAxis(\"y\", info.point, offset);\n            /**\n             * Ideally we would leave the renderer to fire naturally at the end of\n             * this frame but if the element is about to change layout as the result\n             * of a re-render we want to ensure the browser can read the latest\n             * bounding box to ensure the pointer and element don't fall out of sync.\n             */\n            this.visualElement.render();\n            /**\n             * This must fire after the render call as it might trigger a state\n             * change which itself might trigger a layout update.\n             */\n            onDrag && onDrag(event, info);\n        };\n        const onSessionEnd = (event, info) => this.stop(event, info);\n        const resumeAnimation = () => eachAxis((axis) => {\n            var _a;\n            return this.getAnimationState(axis) === \"paused\" &&\n                ((_a = this.getAxisMotionValue(axis).animation) === null || _a === void 0 ? void 0 : _a.play());\n        });\n        const { dragSnapToOrigin } = this.getProps();\n        this.panSession = new PanSession(originEvent, {\n            onSessionStart,\n            onStart,\n            onMove,\n            onSessionEnd,\n            resumeAnimation,\n        }, {\n            transformPagePoint: this.visualElement.getTransformPagePoint(),\n            dragSnapToOrigin,\n            contextWindow: getContextWindow(this.visualElement),\n        });\n    }\n    stop(event, info) {\n        const isDragging = this.isDragging;\n        this.cancel();\n        if (!isDragging)\n            return;\n        const { velocity } = info;\n        this.startAnimation(velocity);\n        const { onDragEnd } = this.getProps();\n        if (onDragEnd) {\n            frame.postRender(() => onDragEnd(event, info));\n        }\n    }\n    cancel() {\n        this.isDragging = false;\n        const { projection, animationState } = this.visualElement;\n        if (projection) {\n            projection.isAnimationBlocked = false;\n        }\n        this.panSession && this.panSession.end();\n        this.panSession = undefined;\n        const { dragPropagation } = this.getProps();\n        if (!dragPropagation && this.openDragLock) {\n            this.openDragLock();\n            this.openDragLock = null;\n        }\n        animationState && animationState.setActive(\"whileDrag\", false);\n    }\n    updateAxis(axis, _point, offset) {\n        const { drag } = this.getProps();\n        // If we're not dragging this axis, do an early return.\n        if (!offset || !shouldDrag(axis, drag, this.currentDirection))\n            return;\n        const axisValue = this.getAxisMotionValue(axis);\n        let next = this.originPoint[axis] + offset[axis];\n        // Apply constraints\n        if (this.constraints && this.constraints[axis]) {\n            next = applyConstraints(next, this.constraints[axis], this.elastic[axis]);\n        }\n        axisValue.set(next);\n    }\n    resolveConstraints() {\n        var _a;\n        const { dragConstraints, dragElastic } = this.getProps();\n        const layout = this.visualElement.projection &&\n            !this.visualElement.projection.layout\n            ? this.visualElement.projection.measure(false)\n            : (_a = this.visualElement.projection) === null || _a === void 0 ? void 0 : _a.layout;\n        const prevConstraints = this.constraints;\n        if (dragConstraints && isRefObject(dragConstraints)) {\n            if (!this.constraints) {\n                this.constraints = this.resolveRefConstraints();\n            }\n        }\n        else {\n            if (dragConstraints && layout) {\n                this.constraints = calcRelativeConstraints(layout.layoutBox, dragConstraints);\n            }\n            else {\n                this.constraints = false;\n            }\n        }\n        this.elastic = resolveDragElastic(dragElastic);\n        /**\n         * If we're outputting to external MotionValues, we want to rebase the measured constraints\n         * from viewport-relative to component-relative.\n         */\n        if (prevConstraints !== this.constraints &&\n            layout &&\n            this.constraints &&\n            !this.hasMutatedConstraints) {\n            eachAxis((axis) => {\n                if (this.constraints !== false &&\n                    this.getAxisMotionValue(axis)) {\n                    this.constraints[axis] = rebaseAxisConstraints(layout.layoutBox[axis], this.constraints[axis]);\n                }\n            });\n        }\n    }\n    resolveRefConstraints() {\n        const { dragConstraints: constraints, onMeasureDragConstraints } = this.getProps();\n        if (!constraints || !isRefObject(constraints))\n            return false;\n        const constraintsElement = constraints.current;\n        invariant(constraintsElement !== null, \"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.\");\n        const { projection } = this.visualElement;\n        // TODO\n        if (!projection || !projection.layout)\n            return false;\n        const constraintsBox = measurePageBox(constraintsElement, projection.root, this.visualElement.getTransformPagePoint());\n        let measuredConstraints = calcViewportConstraints(projection.layout.layoutBox, constraintsBox);\n        /**\n         * If there's an onMeasureDragConstraints listener we call it and\n         * if different constraints are returned, set constraints to that\n         */\n        if (onMeasureDragConstraints) {\n            const userConstraints = onMeasureDragConstraints(convertBoxToBoundingBox(measuredConstraints));\n            this.hasMutatedConstraints = !!userConstraints;\n            if (userConstraints) {\n                measuredConstraints = convertBoundingBoxToBox(userConstraints);\n            }\n        }\n        return measuredConstraints;\n    }\n    startAnimation(velocity) {\n        const { drag, dragMomentum, dragElastic, dragTransition, dragSnapToOrigin, onDragTransitionEnd, } = this.getProps();\n        const constraints = this.constraints || {};\n        const momentumAnimations = eachAxis((axis) => {\n            if (!shouldDrag(axis, drag, this.currentDirection)) {\n                return;\n            }\n            let transition = (constraints && constraints[axis]) || {};\n            if (dragSnapToOrigin)\n                transition = { min: 0, max: 0 };\n            /**\n             * Overdamp the boundary spring if `dragElastic` is disabled. There's still a frame\n             * of spring animations so we should look into adding a disable spring option to `inertia`.\n             * We could do something here where we affect the `bounceStiffness` and `bounceDamping`\n             * using the value of `dragElastic`.\n             */\n            const bounceStiffness = dragElastic ? 200 : 1000000;\n            const bounceDamping = dragElastic ? 40 : 10000000;\n            const inertia = {\n                type: \"inertia\",\n                velocity: dragMomentum ? velocity[axis] : 0,\n                bounceStiffness,\n                bounceDamping,\n                timeConstant: 750,\n                restDelta: 1,\n                restSpeed: 10,\n                ...dragTransition,\n                ...transition,\n            };\n            // If we're not animating on an externally-provided `MotionValue` we can use the\n            // component's animation controls which will handle interactions with whileHover (etc),\n            // otherwise we just have to animate the `MotionValue` itself.\n            return this.startAxisValueAnimation(axis, inertia);\n        });\n        // Run all animations and then resolve the new drag constraints.\n        return Promise.all(momentumAnimations).then(onDragTransitionEnd);\n    }\n    startAxisValueAnimation(axis, transition) {\n        const axisValue = this.getAxisMotionValue(axis);\n        addValueToWillChange(this.visualElement, axis);\n        return axisValue.start(animateMotionValue(axis, axisValue, 0, transition, this.visualElement, false));\n    }\n    stopAnimation() {\n        eachAxis((axis) => this.getAxisMotionValue(axis).stop());\n    }\n    pauseAnimation() {\n        eachAxis((axis) => { var _a; return (_a = this.getAxisMotionValue(axis).animation) === null || _a === void 0 ? void 0 : _a.pause(); });\n    }\n    getAnimationState(axis) {\n        var _a;\n        return (_a = this.getAxisMotionValue(axis).animation) === null || _a === void 0 ? void 0 : _a.state;\n    }\n    /**\n     * Drag works differently depending on which props are provided.\n     *\n     * - If _dragX and _dragY are provided, we output the gesture delta directly to those motion values.\n     * - Otherwise, we apply the delta to the x/y motion values.\n     */\n    getAxisMotionValue(axis) {\n        const dragKey = `_drag${axis.toUpperCase()}`;\n        const props = this.visualElement.getProps();\n        const externalMotionValue = props[dragKey];\n        return externalMotionValue\n            ? externalMotionValue\n            : this.visualElement.getValue(axis, (props.initial\n                ? props.initial[axis]\n                : undefined) || 0);\n    }\n    snapToCursor(point) {\n        eachAxis((axis) => {\n            const { drag } = this.getProps();\n            // If we're not dragging this axis, do an early return.\n            if (!shouldDrag(axis, drag, this.currentDirection))\n                return;\n            const { projection } = this.visualElement;\n            const axisValue = this.getAxisMotionValue(axis);\n            if (projection && projection.layout) {\n                const { min, max } = projection.layout.layoutBox[axis];\n                axisValue.set(point[axis] - mixNumber(min, max, 0.5));\n            }\n        });\n    }\n    /**\n     * When the viewport resizes we want to check if the measured constraints\n     * have changed and, if so, reposition the element within those new constraints\n     * relative to where it was before the resize.\n     */\n    scalePositionWithinConstraints() {\n        if (!this.visualElement.current)\n            return;\n        const { drag, dragConstraints } = this.getProps();\n        const { projection } = this.visualElement;\n        if (!isRefObject(dragConstraints) || !projection || !this.constraints)\n            return;\n        /**\n         * Stop current animations as there can be visual glitching if we try to do\n         * this mid-animation\n         */\n        this.stopAnimation();\n        /**\n         * Record the relative position of the dragged element relative to the\n         * constraints box and save as a progress value.\n         */\n        const boxProgress = { x: 0, y: 0 };\n        eachAxis((axis) => {\n            const axisValue = this.getAxisMotionValue(axis);\n            if (axisValue && this.constraints !== false) {\n                const latest = axisValue.get();\n                boxProgress[axis] = calcOrigin({ min: latest, max: latest }, this.constraints[axis]);\n            }\n        });\n        /**\n         * Update the layout of this element and resolve the latest drag constraints\n         */\n        const { transformTemplate } = this.visualElement.getProps();\n        this.visualElement.current.style.transform = transformTemplate\n            ? transformTemplate({}, \"\")\n            : \"none\";\n        projection.root && projection.root.updateScroll();\n        projection.updateLayout();\n        this.resolveConstraints();\n        /**\n         * For each axis, calculate the current progress of the layout axis\n         * within the new constraints.\n         */\n        eachAxis((axis) => {\n            if (!shouldDrag(axis, drag, null))\n                return;\n            /**\n             * Calculate a new transform based on the previous box progress\n             */\n            const axisValue = this.getAxisMotionValue(axis);\n            const { min, max } = this.constraints[axis];\n            axisValue.set(mixNumber(min, max, boxProgress[axis]));\n        });\n    }\n    addListeners() {\n        if (!this.visualElement.current)\n            return;\n        elementDragControls.set(this.visualElement, this);\n        const element = this.visualElement.current;\n        /**\n         * Attach a pointerdown event listener on this DOM element to initiate drag tracking.\n         */\n        const stopPointerListener = addPointerEvent(element, \"pointerdown\", (event) => {\n            const { drag, dragListener = true } = this.getProps();\n            drag && dragListener && this.start(event);\n        });\n        const measureDragConstraints = () => {\n            const { dragConstraints } = this.getProps();\n            if (isRefObject(dragConstraints) && dragConstraints.current) {\n                this.constraints = this.resolveRefConstraints();\n            }\n        };\n        const { projection } = this.visualElement;\n        const stopMeasureLayoutListener = projection.addEventListener(\"measure\", measureDragConstraints);\n        if (projection && !projection.layout) {\n            projection.root && projection.root.updateScroll();\n            projection.updateLayout();\n        }\n        frame.read(measureDragConstraints);\n        /**\n         * Attach a window resize listener to scale the draggable target within its defined\n         * constraints as the window resizes.\n         */\n        const stopResizeListener = addDomEvent(window, \"resize\", () => this.scalePositionWithinConstraints());\n        /**\n         * If the element's layout changes, calculate the delta and apply that to\n         * the drag gesture's origin point.\n         */\n        const stopLayoutUpdateListener = projection.addEventListener(\"didUpdate\", (({ delta, hasLayoutChanged }) => {\n            if (this.isDragging && hasLayoutChanged) {\n                eachAxis((axis) => {\n                    const motionValue = this.getAxisMotionValue(axis);\n                    if (!motionValue)\n                        return;\n                    this.originPoint[axis] += delta[axis].translate;\n                    motionValue.set(motionValue.get() + delta[axis].translate);\n                });\n                this.visualElement.render();\n            }\n        }));\n        return () => {\n            stopResizeListener();\n            stopPointerListener();\n            stopMeasureLayoutListener();\n            stopLayoutUpdateListener && stopLayoutUpdateListener();\n        };\n    }\n    getProps() {\n        const props = this.visualElement.getProps();\n        const { drag = false, dragDirectionLock = false, dragPropagation = false, dragConstraints = false, dragElastic = defaultElastic, dragMomentum = true, } = props;\n        return {\n            ...props,\n            drag,\n            dragDirectionLock,\n            dragPropagation,\n            dragConstraints,\n            dragElastic,\n            dragMomentum,\n        };\n    }\n}\nfunction shouldDrag(direction, drag, currentDirection) {\n    return ((drag === true || drag === direction) &&\n        (currentDirection === null || currentDirection === direction));\n}\n/**\n * Based on an x/y offset determine the current drag direction. If both axis' offsets are lower\n * than the provided threshold, return `null`.\n *\n * @param offset - The x/y offset from origin.\n * @param lockThreshold - (Optional) - the minimum absolute offset before we can determine a drag direction.\n */\nfunction getCurrentDirection(offset, lockThreshold = 10) {\n    let direction = null;\n    if (Math.abs(offset.y) > lockThreshold) {\n        direction = \"y\";\n    }\n    else if (Math.abs(offset.x) > lockThreshold) {\n        direction = \"x\";\n    }\n    return direction;\n}\n\nexport { VisualElementDragControls, elementDragControls };\n","import { isDragging } from './is-active.mjs';\n\nfunction setDragLock(axis) {\n    if (axis === \"x\" || axis === \"y\") {\n        if (isDragging[axis]) {\n            return null;\n        }\n        else {\n            isDragging[axis] = true;\n            return () => {\n                isDragging[axis] = false;\n            };\n        }\n    }\n    else {\n        if (isDragging.x || isDragging.y) {\n            return null;\n        }\n        else {\n            isDragging.x = isDragging.y = true;\n            return () => {\n                isDragging.x = isDragging.y = false;\n            };\n        }\n    }\n}\n\nexport { setDragLock };\n","import { PanSession } from './PanSession.mjs';\nimport { addPointerEvent } from '../../events/add-pointer-event.mjs';\nimport { Feature } from '../../motion/features/Feature.mjs';\nimport { noop } from 'motion-utils';\nimport { getContextWindow } from '../../utils/get-context-window.mjs';\nimport { frame } from '../../frameloop/frame.mjs';\n\nconst asyncHandler = (handler) => (event, info) => {\n    if (handler) {\n        frame.postRender(() => handler(event, info));\n    }\n};\nclass PanGesture extends Feature {\n    constructor() {\n        super(...arguments);\n        this.removePointerDownListener = noop;\n    }\n    onPointerDown(pointerDownEvent) {\n        this.session = new PanSession(pointerDownEvent, this.createPanHandlers(), {\n            transformPagePoint: this.node.getTransformPagePoint(),\n            contextWindow: getContextWindow(this.node),\n        });\n    }\n    createPanHandlers() {\n        const { onPanSessionStart, onPanStart, onPan, onPanEnd } = this.node.getProps();\n        return {\n            onSessionStart: asyncHandler(onPanSessionStart),\n            onStart: asyncHandler(onPanStart),\n            onMove: onPan,\n            onEnd: (event, info) => {\n                delete this.session;\n                if (onPanEnd) {\n                    frame.postRender(() => onPanEnd(event, info));\n                }\n            },\n        };\n    }\n    mount() {\n        this.removePointerDownListener = addPointerEvent(this.node.current, \"pointerdown\", (event) => this.onPointerDown(event));\n    }\n    update() {\n        this.session && this.session.updateHandlers(this.createPanHandlers());\n    }\n    unmount() {\n        this.removePointerDownListener();\n        this.session && this.session.end();\n    }\n}\n\nexport { PanGesture };\n","\"use client\";\nimport { createContext } from 'react';\n\n/**\n * @public\n */\nconst PresenceContext = createContext(null);\n\nexport { PresenceContext };\n","import { useContext, useId, useEffect, useCallback } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\n\n/**\n * When a component is the child of `AnimatePresence`, it can use `usePresence`\n * to access information about whether it's still present in the React tree.\n *\n * ```jsx\n * import { usePresence } from \"framer-motion\"\n *\n * export const Component = () => {\n *   const [isPresent, safeToRemove] = usePresence()\n *\n *   useEffect(() => {\n *     !isPresent && setTimeout(safeToRemove, 1000)\n *   }, [isPresent])\n *\n *   return <div />\n * }\n * ```\n *\n * If `isPresent` is `false`, it means that a component has been removed the tree, but\n * `AnimatePresence` won't really remove it until `safeToRemove` has been called.\n *\n * @public\n */\nfunction usePresence(subscribe = true) {\n    const context = useContext(PresenceContext);\n    if (context === null)\n        return [true, null];\n    const { isPresent, onExitComplete, register } = context;\n    // It's safe to call the following hooks conditionally (after an early return) because the context will always\n    // either be null or non-null for the lifespan of the component.\n    const id = useId();\n    useEffect(() => {\n        if (subscribe)\n            register(id);\n    }, [subscribe]);\n    const safeToRemove = useCallback(() => subscribe && onExitComplete && onExitComplete(id), [id, onExitComplete, subscribe]);\n    return !isPresent && onExitComplete ? [false, safeToRemove] : [true];\n}\n/**\n * Similar to `usePresence`, except `useIsPresent` simply returns whether or not the component is present.\n * There is no `safeToRemove` function.\n *\n * ```jsx\n * import { useIsPresent } from \"framer-motion\"\n *\n * export const Component = () => {\n *   const isPresent = useIsPresent()\n *\n *   useEffect(() => {\n *     !isPresent && console.log(\"I've been removed!\")\n *   }, [isPresent])\n *\n *   return <div />\n * }\n * ```\n *\n * @public\n */\nfunction useIsPresent() {\n    return isPresent(useContext(PresenceContext));\n}\nfunction isPresent(context) {\n    return context === null ? true : context.isPresent;\n}\n\nexport { isPresent, useIsPresent, usePresence };\n","\"use client\";\nimport { createContext } from 'react';\n\nconst LayoutGroupContext = createContext({});\n\nexport { LayoutGroupContext };\n","\"use client\";\nimport { createContext } from 'react';\n\n/**\n * Internal, exported only for usage in Framer\n */\nconst SwitchLayoutGroupContext = createContext({});\n\nexport { SwitchLayoutGroupContext };\n","/**\n * This should only ever be modified on the client otherwise it'll\n * persist through server requests. If we need instanced states we\n * could lazy-init via root.\n */\nconst globalProjectionState = {\n    /**\n     * Global flag as to whether the tree has animated since the last time\n     * we resized the window\n     */\n    hasAnimatedSinceResize: true,\n    /**\n     * We set this to true once, on the first update. Any nodes added to the tree beyond that\n     * update will be given a `data-projection-id` attribute.\n     */\n    hasEverUpdated: false,\n};\n\nexport { globalProjectionState };\n","import { px } from '../../value/types/numbers/units.mjs';\n\nfunction pixelsToPercent(pixels, axis) {\n    if (axis.max === axis.min)\n        return 0;\n    return (pixels / (axis.max - axis.min)) * 100;\n}\n/**\n * We always correct borderRadius as a percentage rather than pixels to reduce paints.\n * For example, if you are projecting a box that is 100px wide with a 10px borderRadius\n * into a box that is 200px wide with a 20px borderRadius, that is actually a 10%\n * borderRadius in both states. If we animate between the two in pixels that will trigger\n * a paint each time. If we animate between the two in percentage we'll avoid a paint.\n */\nconst correctBorderRadius = {\n    correct: (latest, node) => {\n        if (!node.target)\n            return latest;\n        /**\n         * If latest is a string, if it's a percentage we can return immediately as it's\n         * going to be stretched appropriately. Otherwise, if it's a pixel, convert it to a number.\n         */\n        if (typeof latest === \"string\") {\n            if (px.test(latest)) {\n                latest = parseFloat(latest);\n            }\n            else {\n                return latest;\n            }\n        }\n        /**\n         * If latest is a number, it's a pixel value. We use the current viewportBox to calculate that\n         * pixel value as a percentage of each axis\n         */\n        const x = pixelsToPercent(latest, node.target.x);\n        const y = pixelsToPercent(latest, node.target.y);\n        return `${x}% ${y}%`;\n    },\n};\n\nexport { correctBorderRadius, pixelsToPercent };\n","import { mixNumber } from '../../utils/mix/number.mjs';\nimport { complex } from '../../value/types/complex/index.mjs';\n\nconst correctBoxShadow = {\n    correct: (latest, { treeScale, projectionDelta }) => {\n        const original = latest;\n        const shadow = complex.parse(latest);\n        // TODO: Doesn't support multiple shadows\n        if (shadow.length > 5)\n            return original;\n        const template = complex.createTransformer(latest);\n        const offset = typeof shadow[0] !== \"number\" ? 1 : 0;\n        // Calculate the overall context scale\n        const xScale = projectionDelta.x.scale * treeScale.x;\n        const yScale = projectionDelta.y.scale * treeScale.y;\n        shadow[0 + offset] /= xScale;\n        shadow[1 + offset] /= yScale;\n        /**\n         * Ideally we'd correct x and y scales individually, but because blur and\n         * spread apply to both we have to take a scale average and apply that instead.\n         * We could potentially improve the outcome of this by incorporating the ratio between\n         * the two scales.\n         */\n        const averageScale = mixNumber(xScale, yScale, 0.5);\n        // Blur\n        if (typeof shadow[2 + offset] === \"number\")\n            shadow[2 + offset] /= averageScale;\n        // Spread\n        if (typeof shadow[3 + offset] === \"number\")\n            shadow[3 + offset] /= averageScale;\n        return template(shadow);\n    },\n};\n\nexport { correctBoxShadow };\n","const scaleCorrectors = {};\nfunction addScaleCorrector(correctors) {\n    Object.assign(scaleCorrectors, correctors);\n}\n\nexport { addScaleCorrector, scaleCorrectors };\n","import { createRenderBatcher } from './batcher.mjs';\n\nconst { schedule: microtask, cancel: cancelMicrotask } = createRenderBatcher(queueMicrotask, false);\n\nexport { cancelMicrotask, microtask };\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { useContext, Component } from 'react';\nimport { usePresence } from '../../../components/AnimatePresence/use-presence.mjs';\nimport { LayoutGroupContext } from '../../../context/LayoutGroupContext.mjs';\nimport { SwitchLayoutGroupContext } from '../../../context/SwitchLayoutGroupContext.mjs';\nimport { globalProjectionState } from '../../../projection/node/state.mjs';\nimport { correctBorderRadius } from '../../../projection/styles/scale-border-radius.mjs';\nimport { correctBoxShadow } from '../../../projection/styles/scale-box-shadow.mjs';\nimport { addScaleCorrector } from '../../../projection/styles/scale-correction.mjs';\nimport { microtask } from '../../../frameloop/microtask.mjs';\nimport { frame } from '../../../frameloop/frame.mjs';\n\nclass MeasureLayoutWithContext extends Component {\n    /**\n     * This only mounts projection nodes for components that\n     * need measuring, we might want to do it for all components\n     * in order to incorporate transforms\n     */\n    componentDidMount() {\n        const { visualElement, layoutGroup, switchLayoutGroup, layoutId } = this.props;\n        const { projection } = visualElement;\n        addScaleCorrector(defaultScaleCorrectors);\n        if (projection) {\n            if (layoutGroup.group)\n                layoutGroup.group.add(projection);\n            if (switchLayoutGroup && switchLayoutGroup.register && layoutId) {\n                switchLayoutGroup.register(projection);\n            }\n            projection.root.didUpdate();\n            projection.addEventListener(\"animationComplete\", () => {\n                this.safeToRemove();\n            });\n            projection.setOptions({\n                ...projection.options,\n                onExitComplete: () => this.safeToRemove(),\n            });\n        }\n        globalProjectionState.hasEverUpdated = true;\n    }\n    getSnapshotBeforeUpdate(prevProps) {\n        const { layoutDependency, visualElement, drag, isPresent } = this.props;\n        const projection = visualElement.projection;\n        if (!projection)\n            return null;\n        /**\n         * TODO: We use this data in relegate to determine whether to\n         * promote a previous element. There's no guarantee its presence data\n         * will have updated by this point - if a bug like this arises it will\n         * have to be that we markForRelegation and then find a new lead some other way,\n         * perhaps in didUpdate\n         */\n        projection.isPresent = isPresent;\n        if (drag ||\n            prevProps.layoutDependency !== layoutDependency ||\n            layoutDependency === undefined) {\n            projection.willUpdate();\n        }\n        else {\n            this.safeToRemove();\n        }\n        if (prevProps.isPresent !== isPresent) {\n            if (isPresent) {\n                projection.promote();\n            }\n            else if (!projection.relegate()) {\n                /**\n                 * If there's another stack member taking over from this one,\n                 * it's in charge of the exit animation and therefore should\n                 * be in charge of the safe to remove. Otherwise we call it here.\n                 */\n                frame.postRender(() => {\n                    const stack = projection.getStack();\n                    if (!stack || !stack.members.length) {\n                        this.safeToRemove();\n                    }\n                });\n            }\n        }\n        return null;\n    }\n    componentDidUpdate() {\n        const { projection } = this.props.visualElement;\n        if (projection) {\n            projection.root.didUpdate();\n            microtask.postRender(() => {\n                if (!projection.currentAnimation && projection.isLead()) {\n                    this.safeToRemove();\n                }\n            });\n        }\n    }\n    componentWillUnmount() {\n        const { visualElement, layoutGroup, switchLayoutGroup: promoteContext, } = this.props;\n        const { projection } = visualElement;\n        if (projection) {\n            projection.scheduleCheckAfterUnmount();\n            if (layoutGroup && layoutGroup.group)\n                layoutGroup.group.remove(projection);\n            if (promoteContext && promoteContext.deregister)\n                promoteContext.deregister(projection);\n        }\n    }\n    safeToRemove() {\n        const { safeToRemove } = this.props;\n        safeToRemove && safeToRemove();\n    }\n    render() {\n        return null;\n    }\n}\nfunction MeasureLayout(props) {\n    const [isPresent, safeToRemove] = usePresence();\n    const layoutGroup = useContext(LayoutGroupContext);\n    return (jsx(MeasureLayoutWithContext, { ...props, layoutGroup: layoutGroup, switchLayoutGroup: useContext(SwitchLayoutGroupContext), isPresent: isPresent, safeToRemove: safeToRemove }));\n}\nconst defaultScaleCorrectors = {\n    borderRadius: {\n        ...correctBorderRadius,\n        applyTo: [\n            \"borderTopLeftRadius\",\n            \"borderTopRightRadius\",\n            \"borderBottomLeftRadius\",\n            \"borderBottomRightRadius\",\n        ],\n    },\n    borderTopLeftRadius: correctBorderRadius,\n    borderTopRightRadius: correctBorderRadius,\n    borderBottomLeftRadius: correctBorderRadius,\n    borderBottomRightRadius: correctBorderRadius,\n    boxShadow: correctBoxShadow,\n};\n\nexport { MeasureLayout };\n","const compareByDepth = (a, b) => a.depth - b.depth;\n\nexport { compareByDepth };\n","import { addUniqueItem, removeItem } from '../../utils/array.mjs';\nimport { compareByDepth } from './compare-by-depth.mjs';\n\nclass FlatTree {\n    constructor() {\n        this.children = [];\n        this.isDirty = false;\n    }\n    add(child) {\n        addUniqueItem(this.children, child);\n        this.isDirty = true;\n    }\n    remove(child) {\n        removeItem(this.children, child);\n        this.isDirty = true;\n    }\n    forEach(callback) {\n        this.isDirty && this.children.sort(compareByDepth);\n        this.isDirty = false;\n        this.children.forEach(callback);\n    }\n}\n\nexport { FlatTree };\n","import { isCustomValue } from '../../utils/resolve-value.mjs';\nimport { isMotionValue } from './is-motion-value.mjs';\n\n/**\n * If the provided value is a MotionValue, this returns the actual value, otherwise just the value itself\n *\n * TODO: Remove and move to library\n */\nfunction resolveMotionValue(value) {\n    const unwrappedValue = isMotionValue(value) ? value.get() : value;\n    return isCustomValue(unwrappedValue)\n        ? unwrappedValue.toValue()\n        : unwrappedValue;\n}\n\nexport { resolveMotionValue };\n","import { progress, noop } from 'motion-utils';\nimport { circOut } from '../../easing/circ.mjs';\nimport { mixNumber } from '../../utils/mix/number.mjs';\nimport { percent, px } from '../../value/types/numbers/units.mjs';\n\nconst borders = [\"TopLeft\", \"TopRight\", \"BottomLeft\", \"BottomRight\"];\nconst numBorders = borders.length;\nconst asNumber = (value) => typeof value === \"string\" ? parseFloat(value) : value;\nconst isPx = (value) => typeof value === \"number\" || px.test(value);\nfunction mixValues(target, follow, lead, progress, shouldCrossfadeOpacity, isOnlyMember) {\n    if (shouldCrossfadeOpacity) {\n        target.opacity = mixNumber(0, \n        // TODO Reinstate this if only child\n        lead.opacity !== undefined ? lead.opacity : 1, easeCrossfadeIn(progress));\n        target.opacityExit = mixNumber(follow.opacity !== undefined ? follow.opacity : 1, 0, easeCrossfadeOut(progress));\n    }\n    else if (isOnlyMember) {\n        target.opacity = mixNumber(follow.opacity !== undefined ? follow.opacity : 1, lead.opacity !== undefined ? lead.opacity : 1, progress);\n    }\n    /**\n     * Mix border radius\n     */\n    for (let i = 0; i < numBorders; i++) {\n        const borderLabel = `border${borders[i]}Radius`;\n        let followRadius = getRadius(follow, borderLabel);\n        let leadRadius = getRadius(lead, borderLabel);\n        if (followRadius === undefined && leadRadius === undefined)\n            continue;\n        followRadius || (followRadius = 0);\n        leadRadius || (leadRadius = 0);\n        const canMix = followRadius === 0 ||\n            leadRadius === 0 ||\n            isPx(followRadius) === isPx(leadRadius);\n        if (canMix) {\n            target[borderLabel] = Math.max(mixNumber(asNumber(followRadius), asNumber(leadRadius), progress), 0);\n            if (percent.test(leadRadius) || percent.test(followRadius)) {\n                target[borderLabel] += \"%\";\n            }\n        }\n        else {\n            target[borderLabel] = leadRadius;\n        }\n    }\n    /**\n     * Mix rotation\n     */\n    if (follow.rotate || lead.rotate) {\n        target.rotate = mixNumber(follow.rotate || 0, lead.rotate || 0, progress);\n    }\n}\nfunction getRadius(values, radiusName) {\n    return values[radiusName] !== undefined\n        ? values[radiusName]\n        : values.borderRadius;\n}\n// /**\n//  * We only want to mix the background color if there's a follow element\n//  * that we're not crossfading opacity between. For instance with switch\n//  * AnimateSharedLayout animations, this helps the illusion of a continuous\n//  * element being animated but also cuts down on the number of paints triggered\n//  * for elements where opacity is doing that work for us.\n//  */\n// if (\n//     !hasFollowElement &&\n//     latestLeadValues.backgroundColor &&\n//     latestFollowValues.backgroundColor\n// ) {\n//     /**\n//      * This isn't ideal performance-wise as mixColor is creating a new function every frame.\n//      * We could probably create a mixer that runs at the start of the animation but\n//      * the idea behind the crossfader is that it runs dynamically between two potentially\n//      * changing targets (ie opacity or borderRadius may be animating independently via variants)\n//      */\n//     leadState.backgroundColor = followState.backgroundColor = mixColor(\n//         latestFollowValues.backgroundColor as string,\n//         latestLeadValues.backgroundColor as string\n//     )(p)\n// }\nconst easeCrossfadeIn = /*@__PURE__*/ compress(0, 0.5, circOut);\nconst easeCrossfadeOut = /*@__PURE__*/ compress(0.5, 0.95, noop);\nfunction compress(min, max, easing) {\n    return (p) => {\n        // Could replace ifs with clamp\n        if (p < min)\n            return 0;\n        if (p > max)\n            return 1;\n        return easing(progress(min, max, p));\n    };\n}\n\nexport { mixValues };\n","/**\n * Reset an axis to the provided origin box.\n *\n * This is a mutative operation.\n */\nfunction copyAxisInto(axis, originAxis) {\n    axis.min = originAxis.min;\n    axis.max = originAxis.max;\n}\n/**\n * Reset a box to the provided origin box.\n *\n * This is a mutative operation.\n */\nfunction copyBoxInto(box, originBox) {\n    copyAxisInto(box.x, originBox.x);\n    copyAxisInto(box.y, originBox.y);\n}\n/**\n * Reset a delta to the provided origin box.\n *\n * This is a mutative operation.\n */\nfunction copyAxisDeltaInto(delta, originDelta) {\n    delta.translate = originDelta.translate;\n    delta.scale = originDelta.scale;\n    delta.originPoint = originDelta.originPoint;\n    delta.origin = originDelta.origin;\n}\n\nexport { copyAxisDeltaInto, copyAxisInto, copyBoxInto };\n","import { mixNumber } from '../../utils/mix/number.mjs';\nimport { percent } from '../../value/types/numbers/units.mjs';\nimport { scalePoint } from './delta-apply.mjs';\n\n/**\n * Remove a delta from a point. This is essentially the steps of applyPointDelta in reverse\n */\nfunction removePointDelta(point, translate, scale, originPoint, boxScale) {\n    point -= translate;\n    point = scalePoint(point, 1 / scale, originPoint);\n    if (boxScale !== undefined) {\n        point = scalePoint(point, 1 / boxScale, originPoint);\n    }\n    return point;\n}\n/**\n * Remove a delta from an axis. This is essentially the steps of applyAxisDelta in reverse\n */\nfunction removeAxisDelta(axis, translate = 0, scale = 1, origin = 0.5, boxScale, originAxis = axis, sourceAxis = axis) {\n    if (percent.test(translate)) {\n        translate = parseFloat(translate);\n        const relativeProgress = mixNumber(sourceAxis.min, sourceAxis.max, translate / 100);\n        translate = relativeProgress - sourceAxis.min;\n    }\n    if (typeof translate !== \"number\")\n        return;\n    let originPoint = mixNumber(originAxis.min, originAxis.max, origin);\n    if (axis === originAxis)\n        originPoint -= translate;\n    axis.min = removePointDelta(axis.min, translate, scale, originPoint, boxScale);\n    axis.max = removePointDelta(axis.max, translate, scale, originPoint, boxScale);\n}\n/**\n * Remove a transforms from an axis. This is essentially the steps of applyAxisTransforms in reverse\n * and acts as a bridge between motion values and removeAxisDelta\n */\nfunction removeAxisTransforms(axis, transforms, [key, scaleKey, originKey], origin, sourceAxis) {\n    removeAxisDelta(axis, transforms[key], transforms[scaleKey], transforms[originKey], transforms.scale, origin, sourceAxis);\n}\n/**\n * The names of the motion values we want to apply as translation, scale and origin.\n */\nconst xKeys = [\"x\", \"scaleX\", \"originX\"];\nconst yKeys = [\"y\", \"scaleY\", \"originY\"];\n/**\n * Remove a transforms from an box. This is essentially the steps of applyAxisBox in reverse\n * and acts as a bridge between motion values and removeAxisDelta\n */\nfunction removeBoxTransforms(box, transforms, originBox, sourceBox) {\n    removeAxisTransforms(box.x, transforms, xKeys, originBox ? originBox.x : undefined, sourceBox ? sourceBox.x : undefined);\n    removeAxisTransforms(box.y, transforms, yKeys, originBox ? originBox.y : undefined, sourceBox ? sourceBox.y : undefined);\n}\n\nexport { removeAxisDelta, removeAxisTransforms, removeBoxTransforms, removePointDelta };\n","import { calcLength } from './delta-calc.mjs';\n\nfunction isAxisDeltaZero(delta) {\n    return delta.translate === 0 && delta.scale === 1;\n}\nfunction isDeltaZero(delta) {\n    return isAxisDeltaZero(delta.x) && isAxisDeltaZero(delta.y);\n}\nfunction axisEquals(a, b) {\n    return a.min === b.min && a.max === b.max;\n}\nfunction boxEquals(a, b) {\n    return axisEquals(a.x, b.x) && axisEquals(a.y, b.y);\n}\nfunction axisEqualsRounded(a, b) {\n    return (Math.round(a.min) === Math.round(b.min) &&\n        Math.round(a.max) === Math.round(b.max));\n}\nfunction boxEqualsRounded(a, b) {\n    return axisEqualsRounded(a.x, b.x) && axisEqualsRounded(a.y, b.y);\n}\nfunction aspectRatio(box) {\n    return calcLength(box.x) / calcLength(box.y);\n}\nfunction axisDeltaEquals(a, b) {\n    return (a.translate === b.translate &&\n        a.scale === b.scale &&\n        a.originPoint === b.originPoint);\n}\n\nexport { aspectRatio, axisDeltaEquals, axisEquals, axisEqualsRounded, boxEquals, boxEqualsRounded, isDeltaZero };\n","import { addUniqueItem, removeItem } from '../../utils/array.mjs';\n\nclass NodeStack {\n    constructor() {\n        this.members = [];\n    }\n    add(node) {\n        addUniqueItem(this.members, node);\n        node.scheduleRender();\n    }\n    remove(node) {\n        removeItem(this.members, node);\n        if (node === this.prevLead) {\n            this.prevLead = undefined;\n        }\n        if (node === this.lead) {\n            const prevLead = this.members[this.members.length - 1];\n            if (prevLead) {\n                this.promote(prevLead);\n            }\n        }\n    }\n    relegate(node) {\n        const indexOfNode = this.members.findIndex((member) => node === member);\n        if (indexOfNode === 0)\n            return false;\n        /**\n         * Find the next projection node that is present\n         */\n        let prevLead;\n        for (let i = indexOfNode; i >= 0; i--) {\n            const member = this.members[i];\n            if (member.isPresent !== false) {\n                prevLead = member;\n                break;\n            }\n        }\n        if (prevLead) {\n            this.promote(prevLead);\n            return true;\n        }\n        else {\n            return false;\n        }\n    }\n    promote(node, preserveFollowOpacity) {\n        const prevLead = this.lead;\n        if (node === prevLead)\n            return;\n        this.prevLead = prevLead;\n        this.lead = node;\n        node.show();\n        if (prevLead) {\n            prevLead.instance && prevLead.scheduleRender();\n            node.scheduleRender();\n            node.resumeFrom = prevLead;\n            if (preserveFollowOpacity) {\n                node.resumeFrom.preserveOpacity = true;\n            }\n            if (prevLead.snapshot) {\n                node.snapshot = prevLead.snapshot;\n                node.snapshot.latestValues =\n                    prevLead.animationValues || prevLead.latestValues;\n            }\n            if (node.root && node.root.isUpdating) {\n                node.isLayoutDirty = true;\n            }\n            const { crossfade } = node.options;\n            if (crossfade === false) {\n                prevLead.hide();\n            }\n            /**\n             * TODO:\n             *   - Test border radius when previous node was deleted\n             *   - boxShadow mixing\n             *   - Shared between element A in scrolled container and element B (scroll stays the same or changes)\n             *   - Shared between element A in transformed container and element B (transform stays the same or changes)\n             *   - Shared between element A in scrolled page and element B (scroll stays the same or changes)\n             * ---\n             *   - Crossfade opacity of root nodes\n             *   - layoutId changes after animation\n             *   - layoutId changes mid animation\n             */\n        }\n    }\n    exitAnimationComplete() {\n        this.members.forEach((node) => {\n            const { options, resumingFrom } = node;\n            options.onExitComplete && options.onExitComplete();\n            if (resumingFrom) {\n                resumingFrom.options.onExitComplete &&\n                    resumingFrom.options.onExitComplete();\n            }\n        });\n    }\n    scheduleRender() {\n        this.members.forEach((node) => {\n            node.instance && node.scheduleRender(false);\n        });\n    }\n    /**\n     * Clear any leads that have been removed this render to prevent them from being\n     * used in future animations and to prevent memory leaks\n     */\n    removeLeadSnapshot() {\n        if (this.lead && this.lead.snapshot) {\n            this.lead.snapshot = undefined;\n        }\n    }\n}\n\nexport { NodeStack };\n","import { getValueTransition } from 'motion-dom';\nimport { noop } from 'motion-utils';\nimport { animateSingleValue } from '../../animation/animate/single-value.mjs';\nimport { getOptimisedAppearId } from '../../animation/optimized-appear/get-appear-id.mjs';\nimport { cancelFrame, frameData, frameSteps, frame } from '../../frameloop/frame.mjs';\nimport { microtask } from '../../frameloop/microtask.mjs';\nimport { time } from '../../frameloop/sync-time.mjs';\nimport { isSVGElement } from '../../render/dom/utils/is-svg-element.mjs';\nimport { FlatTree } from '../../render/utils/flat-tree.mjs';\nimport { clamp } from '../../utils/clamp.mjs';\nimport { delay } from '../../utils/delay.mjs';\nimport { mixNumber } from '../../utils/mix/number.mjs';\nimport { SubscriptionManager } from '../../utils/subscription-manager.mjs';\nimport { resolveMotionValue } from '../../value/utils/resolve-motion-value.mjs';\nimport { mixValues } from '../animation/mix-values.mjs';\nimport { copyBoxInto, copyAxisDeltaInto } from '../geometry/copy.mjs';\nimport { translateAxis, transformBox, applyBoxDelta, applyTreeDeltas } from '../geometry/delta-apply.mjs';\nimport { calcRelativePosition, calcRelativeBox, calcBoxDelta, calcLength, isNear } from '../geometry/delta-calc.mjs';\nimport { removeBoxTransforms } from '../geometry/delta-remove.mjs';\nimport { createBox, createDelta } from '../geometry/models.mjs';\nimport { boxEqualsRounded, isDeltaZero, axisDeltaEquals, aspectRatio, boxEquals } from '../geometry/utils.mjs';\nimport { NodeStack } from '../shared/stack.mjs';\nimport { scaleCorrectors } from '../styles/scale-correction.mjs';\nimport { buildProjectionTransform } from '../styles/transform.mjs';\nimport { eachAxis } from '../utils/each-axis.mjs';\nimport { hasTransform, hasScale, has2DTranslate } from '../utils/has-transform.mjs';\nimport { globalProjectionState } from './state.mjs';\n\nconst metrics = {\n    type: \"projectionFrame\",\n    totalNodes: 0,\n    resolvedTargetDeltas: 0,\n    recalculatedProjection: 0,\n};\nconst isDebug = typeof window !== \"undefined\" && window.MotionDebug !== undefined;\nconst transformAxes = [\"\", \"X\", \"Y\", \"Z\"];\nconst hiddenVisibility = { visibility: \"hidden\" };\n/**\n * We use 1000 as the animation target as 0-1000 maps better to pixels than 0-1\n * which has a noticeable difference in spring animations\n */\nconst animationTarget = 1000;\nlet id = 0;\nfunction resetDistortingTransform(key, visualElement, values, sharedAnimationValues) {\n    const { latestValues } = visualElement;\n    // Record the distorting transform and then temporarily set it to 0\n    if (latestValues[key]) {\n        values[key] = latestValues[key];\n        visualElement.setStaticValue(key, 0);\n        if (sharedAnimationValues) {\n            sharedAnimationValues[key] = 0;\n        }\n    }\n}\nfunction cancelTreeOptimisedTransformAnimations(projectionNode) {\n    projectionNode.hasCheckedOptimisedAppear = true;\n    if (projectionNode.root === projectionNode)\n        return;\n    const { visualElement } = projectionNode.options;\n    if (!visualElement)\n        return;\n    const appearId = getOptimisedAppearId(visualElement);\n    if (window.MotionHasOptimisedAnimation(appearId, \"transform\")) {\n        const { layout, layoutId } = projectionNode.options;\n        window.MotionCancelOptimisedAnimation(appearId, \"transform\", frame, !(layout || layoutId));\n    }\n    const { parent } = projectionNode;\n    if (parent && !parent.hasCheckedOptimisedAppear) {\n        cancelTreeOptimisedTransformAnimations(parent);\n    }\n}\nfunction createProjectionNode({ attachResizeListener, defaultParent, measureScroll, checkIsScrollRoot, resetTransform, }) {\n    return class ProjectionNode {\n        constructor(latestValues = {}, parent = defaultParent === null || defaultParent === void 0 ? void 0 : defaultParent()) {\n            /**\n             * A unique ID generated for every projection node.\n             */\n            this.id = id++;\n            /**\n             * An id that represents a unique session instigated by startUpdate.\n             */\n            this.animationId = 0;\n            /**\n             * A Set containing all this component's children. This is used to iterate\n             * through the children.\n             *\n             * TODO: This could be faster to iterate as a flat array stored on the root node.\n             */\n            this.children = new Set();\n            /**\n             * Options for the node. We use this to configure what kind of layout animations\n             * we should perform (if any).\n             */\n            this.options = {};\n            /**\n             * We use this to detect when its safe to shut down part of a projection tree.\n             * We have to keep projecting children for scale correction and relative projection\n             * until all their parents stop performing layout animations.\n             */\n            this.isTreeAnimating = false;\n            this.isAnimationBlocked = false;\n            /**\n             * Flag to true if we think this layout has been changed. We can't always know this,\n             * currently we set it to true every time a component renders, or if it has a layoutDependency\n             * if that has changed between renders. Additionally, components can be grouped by LayoutGroup\n             * and if one node is dirtied, they all are.\n             */\n            this.isLayoutDirty = false;\n            /**\n             * Flag to true if we think the projection calculations for this node needs\n             * recalculating as a result of an updated transform or layout animation.\n             */\n            this.isProjectionDirty = false;\n            /**\n             * Flag to true if the layout *or* transform has changed. This then gets propagated\n             * throughout the projection tree, forcing any element below to recalculate on the next frame.\n             */\n            this.isSharedProjectionDirty = false;\n            /**\n             * Flag transform dirty. This gets propagated throughout the whole tree but is only\n             * respected by shared nodes.\n             */\n            this.isTransformDirty = false;\n            /**\n             * Block layout updates for instant layout transitions throughout the tree.\n             */\n            this.updateManuallyBlocked = false;\n            this.updateBlockedByResize = false;\n            /**\n             * Set to true between the start of the first `willUpdate` call and the end of the `didUpdate`\n             * call.\n             */\n            this.isUpdating = false;\n            /**\n             * If this is an SVG element we currently disable projection transforms\n             */\n            this.isSVG = false;\n            /**\n             * Flag to true (during promotion) if a node doing an instant layout transition needs to reset\n             * its projection styles.\n             */\n            this.needsReset = false;\n            /**\n             * Flags whether this node should have its transform reset prior to measuring.\n             */\n            this.shouldResetTransform = false;\n            /**\n             * Store whether this node has been checked for optimised appear animations. As\n             * effects fire bottom-up, and we want to look up the tree for appear animations,\n             * this makes sure we only check each path once, stopping at nodes that\n             * have already been checked.\n             */\n            this.hasCheckedOptimisedAppear = false;\n            /**\n             * An object representing the calculated contextual/accumulated/tree scale.\n             * This will be used to scale calculcated projection transforms, as these are\n             * calculated in screen-space but need to be scaled for elements to layoutly\n             * make it to their calculated destinations.\n             *\n             * TODO: Lazy-init\n             */\n            this.treeScale = { x: 1, y: 1 };\n            /**\n             *\n             */\n            this.eventHandlers = new Map();\n            this.hasTreeAnimated = false;\n            // Note: Currently only running on root node\n            this.updateScheduled = false;\n            this.scheduleUpdate = () => this.update();\n            this.projectionUpdateScheduled = false;\n            this.checkUpdateFailed = () => {\n                if (this.isUpdating) {\n                    this.isUpdating = false;\n                    this.clearAllSnapshots();\n                }\n            };\n            /**\n             * This is a multi-step process as shared nodes might be of different depths. Nodes\n             * are sorted by depth order, so we need to resolve the entire tree before moving to\n             * the next step.\n             */\n            this.updateProjection = () => {\n                this.projectionUpdateScheduled = false;\n                /**\n                 * Reset debug counts. Manually resetting rather than creating a new\n                 * object each frame.\n                 */\n                if (isDebug) {\n                    metrics.totalNodes =\n                        metrics.resolvedTargetDeltas =\n                            metrics.recalculatedProjection =\n                                0;\n                }\n                this.nodes.forEach(propagateDirtyNodes);\n                this.nodes.forEach(resolveTargetDelta);\n                this.nodes.forEach(calcProjection);\n                this.nodes.forEach(cleanDirtyNodes);\n                if (isDebug) {\n                    window.MotionDebug.record(metrics);\n                }\n            };\n            /**\n             * Frame calculations\n             */\n            this.resolvedRelativeTargetAt = 0.0;\n            this.hasProjected = false;\n            this.isVisible = true;\n            this.animationProgress = 0;\n            /**\n             * Shared layout\n             */\n            // TODO Only running on root node\n            this.sharedNodes = new Map();\n            this.latestValues = latestValues;\n            this.root = parent ? parent.root || parent : this;\n            this.path = parent ? [...parent.path, parent] : [];\n            this.parent = parent;\n            this.depth = parent ? parent.depth + 1 : 0;\n            for (let i = 0; i < this.path.length; i++) {\n                this.path[i].shouldResetTransform = true;\n            }\n            if (this.root === this)\n                this.nodes = new FlatTree();\n        }\n        addEventListener(name, handler) {\n            if (!this.eventHandlers.has(name)) {\n                this.eventHandlers.set(name, new SubscriptionManager());\n            }\n            return this.eventHandlers.get(name).add(handler);\n        }\n        notifyListeners(name, ...args) {\n            const subscriptionManager = this.eventHandlers.get(name);\n            subscriptionManager && subscriptionManager.notify(...args);\n        }\n        hasListeners(name) {\n            return this.eventHandlers.has(name);\n        }\n        /**\n         * Lifecycles\n         */\n        mount(instance, isLayoutDirty = this.root.hasTreeAnimated) {\n            if (this.instance)\n                return;\n            this.isSVG = isSVGElement(instance);\n            this.instance = instance;\n            const { layoutId, layout, visualElement } = this.options;\n            if (visualElement && !visualElement.current) {\n                visualElement.mount(instance);\n            }\n            this.root.nodes.add(this);\n            this.parent && this.parent.children.add(this);\n            if (isLayoutDirty && (layout || layoutId)) {\n                this.isLayoutDirty = true;\n            }\n            if (attachResizeListener) {\n                let cancelDelay;\n                const resizeUnblockUpdate = () => (this.root.updateBlockedByResize = false);\n                attachResizeListener(instance, () => {\n                    this.root.updateBlockedByResize = true;\n                    cancelDelay && cancelDelay();\n                    cancelDelay = delay(resizeUnblockUpdate, 250);\n                    if (globalProjectionState.hasAnimatedSinceResize) {\n                        globalProjectionState.hasAnimatedSinceResize = false;\n                        this.nodes.forEach(finishAnimation);\n                    }\n                });\n            }\n            if (layoutId) {\n                this.root.registerSharedNode(layoutId, this);\n            }\n            // Only register the handler if it requires layout animation\n            if (this.options.animate !== false &&\n                visualElement &&\n                (layoutId || layout)) {\n                this.addEventListener(\"didUpdate\", ({ delta, hasLayoutChanged, hasRelativeTargetChanged, layout: newLayout, }) => {\n                    if (this.isTreeAnimationBlocked()) {\n                        this.target = undefined;\n                        this.relativeTarget = undefined;\n                        return;\n                    }\n                    // TODO: Check here if an animation exists\n                    const layoutTransition = this.options.transition ||\n                        visualElement.getDefaultTransition() ||\n                        defaultLayoutTransition;\n                    const { onLayoutAnimationStart, onLayoutAnimationComplete, } = visualElement.getProps();\n                    /**\n                     * The target layout of the element might stay the same,\n                     * but its position relative to its parent has changed.\n                     */\n                    const targetChanged = !this.targetLayout ||\n                        !boxEqualsRounded(this.targetLayout, newLayout) ||\n                        hasRelativeTargetChanged;\n                    /**\n                     * If the layout hasn't seemed to have changed, it might be that the\n                     * element is visually in the same place in the document but its position\n                     * relative to its parent has indeed changed. So here we check for that.\n                     */\n                    const hasOnlyRelativeTargetChanged = !hasLayoutChanged && hasRelativeTargetChanged;\n                    if (this.options.layoutRoot ||\n                        (this.resumeFrom && this.resumeFrom.instance) ||\n                        hasOnlyRelativeTargetChanged ||\n                        (hasLayoutChanged &&\n                            (targetChanged || !this.currentAnimation))) {\n                        if (this.resumeFrom) {\n                            this.resumingFrom = this.resumeFrom;\n                            this.resumingFrom.resumingFrom = undefined;\n                        }\n                        this.setAnimationOrigin(delta, hasOnlyRelativeTargetChanged);\n                        const animationOptions = {\n                            ...getValueTransition(layoutTransition, \"layout\"),\n                            onPlay: onLayoutAnimationStart,\n                            onComplete: onLayoutAnimationComplete,\n                        };\n                        if (visualElement.shouldReduceMotion ||\n                            this.options.layoutRoot) {\n                            animationOptions.delay = 0;\n                            animationOptions.type = false;\n                        }\n                        this.startAnimation(animationOptions);\n                    }\n                    else {\n                        /**\n                         * If the layout hasn't changed and we have an animation that hasn't started yet,\n                         * finish it immediately. Otherwise it will be animating from a location\n                         * that was probably never commited to screen and look like a jumpy box.\n                         */\n                        if (!hasLayoutChanged) {\n                            finishAnimation(this);\n                        }\n                        if (this.isLead() && this.options.onExitComplete) {\n                            this.options.onExitComplete();\n                        }\n                    }\n                    this.targetLayout = newLayout;\n                });\n            }\n        }\n        unmount() {\n            this.options.layoutId && this.willUpdate();\n            this.root.nodes.remove(this);\n            const stack = this.getStack();\n            stack && stack.remove(this);\n            this.parent && this.parent.children.delete(this);\n            this.instance = undefined;\n            cancelFrame(this.updateProjection);\n        }\n        // only on the root\n        blockUpdate() {\n            this.updateManuallyBlocked = true;\n        }\n        unblockUpdate() {\n            this.updateManuallyBlocked = false;\n        }\n        isUpdateBlocked() {\n            return this.updateManuallyBlocked || this.updateBlockedByResize;\n        }\n        isTreeAnimationBlocked() {\n            return (this.isAnimationBlocked ||\n                (this.parent && this.parent.isTreeAnimationBlocked()) ||\n                false);\n        }\n        // Note: currently only running on root node\n        startUpdate() {\n            if (this.isUpdateBlocked())\n                return;\n            this.isUpdating = true;\n            this.nodes && this.nodes.forEach(resetSkewAndRotation);\n            this.animationId++;\n        }\n        getTransformTemplate() {\n            const { visualElement } = this.options;\n            return visualElement && visualElement.getProps().transformTemplate;\n        }\n        willUpdate(shouldNotifyListeners = true) {\n            this.root.hasTreeAnimated = true;\n            if (this.root.isUpdateBlocked()) {\n                this.options.onExitComplete && this.options.onExitComplete();\n                return;\n            }\n            /**\n             * If we're running optimised appear animations then these must be\n             * cancelled before measuring the DOM. This is so we can measure\n             * the true layout of the element rather than the WAAPI animation\n             * which will be unaffected by the resetSkewAndRotate step.\n             *\n             * Note: This is a DOM write. Worst case scenario is this is sandwiched\n             * between other snapshot reads which will cause unnecessary style recalculations.\n             * This has to happen here though, as we don't yet know which nodes will need\n             * snapshots in startUpdate(), but we only want to cancel optimised animations\n             * if a layout animation measurement is actually going to be affected by them.\n             */\n            if (window.MotionCancelOptimisedAnimation &&\n                !this.hasCheckedOptimisedAppear) {\n                cancelTreeOptimisedTransformAnimations(this);\n            }\n            !this.root.isUpdating && this.root.startUpdate();\n            if (this.isLayoutDirty)\n                return;\n            this.isLayoutDirty = true;\n            for (let i = 0; i < this.path.length; i++) {\n                const node = this.path[i];\n                node.shouldResetTransform = true;\n                node.updateScroll(\"snapshot\");\n                if (node.options.layoutRoot) {\n                    node.willUpdate(false);\n                }\n            }\n            const { layoutId, layout } = this.options;\n            if (layoutId === undefined && !layout)\n                return;\n            const transformTemplate = this.getTransformTemplate();\n            this.prevTransformTemplateValue = transformTemplate\n                ? transformTemplate(this.latestValues, \"\")\n                : undefined;\n            this.updateSnapshot();\n            shouldNotifyListeners && this.notifyListeners(\"willUpdate\");\n        }\n        update() {\n            this.updateScheduled = false;\n            const updateWasBlocked = this.isUpdateBlocked();\n            // When doing an instant transition, we skip the layout update,\n            // but should still clean up the measurements so that the next\n            // snapshot could be taken correctly.\n            if (updateWasBlocked) {\n                this.unblockUpdate();\n                this.clearAllSnapshots();\n                this.nodes.forEach(clearMeasurements);\n                return;\n            }\n            if (!this.isUpdating) {\n                this.nodes.forEach(clearIsLayoutDirty);\n            }\n            this.isUpdating = false;\n            /**\n             * Write\n             */\n            this.nodes.forEach(resetTransformStyle);\n            /**\n             * Read ==================\n             */\n            // Update layout measurements of updated children\n            this.nodes.forEach(updateLayout);\n            /**\n             * Write\n             */\n            // Notify listeners that the layout is updated\n            this.nodes.forEach(notifyLayoutUpdate);\n            this.clearAllSnapshots();\n            /**\n             * Manually flush any pending updates. Ideally\n             * we could leave this to the following requestAnimationFrame but this seems\n             * to leave a flash of incorrectly styled content.\n             */\n            const now = time.now();\n            frameData.delta = clamp(0, 1000 / 60, now - frameData.timestamp);\n            frameData.timestamp = now;\n            frameData.isProcessing = true;\n            frameSteps.update.process(frameData);\n            frameSteps.preRender.process(frameData);\n            frameSteps.render.process(frameData);\n            frameData.isProcessing = false;\n        }\n        didUpdate() {\n            if (!this.updateScheduled) {\n                this.updateScheduled = true;\n                microtask.read(this.scheduleUpdate);\n            }\n        }\n        clearAllSnapshots() {\n            this.nodes.forEach(clearSnapshot);\n            this.sharedNodes.forEach(removeLeadSnapshots);\n        }\n        scheduleUpdateProjection() {\n            if (!this.projectionUpdateScheduled) {\n                this.projectionUpdateScheduled = true;\n                frame.preRender(this.updateProjection, false, true);\n            }\n        }\n        scheduleCheckAfterUnmount() {\n            /**\n             * If the unmounting node is in a layoutGroup and did trigger a willUpdate,\n             * we manually call didUpdate to give a chance to the siblings to animate.\n             * Otherwise, cleanup all snapshots to prevents future nodes from reusing them.\n             */\n            frame.postRender(() => {\n                if (this.isLayoutDirty) {\n                    this.root.didUpdate();\n                }\n                else {\n                    this.root.checkUpdateFailed();\n                }\n            });\n        }\n        /**\n         * Update measurements\n         */\n        updateSnapshot() {\n            if (this.snapshot || !this.instance)\n                return;\n            this.snapshot = this.measure();\n        }\n        updateLayout() {\n            if (!this.instance)\n                return;\n            // TODO: Incorporate into a forwarded scroll offset\n            this.updateScroll();\n            if (!(this.options.alwaysMeasureLayout && this.isLead()) &&\n                !this.isLayoutDirty) {\n                return;\n            }\n            /**\n             * When a node is mounted, it simply resumes from the prevLead's\n             * snapshot instead of taking a new one, but the ancestors scroll\n             * might have updated while the prevLead is unmounted. We need to\n             * update the scroll again to make sure the layout we measure is\n             * up to date.\n             */\n            if (this.resumeFrom && !this.resumeFrom.instance) {\n                for (let i = 0; i < this.path.length; i++) {\n                    const node = this.path[i];\n                    node.updateScroll();\n                }\n            }\n            const prevLayout = this.layout;\n            this.layout = this.measure(false);\n            this.layoutCorrected = createBox();\n            this.isLayoutDirty = false;\n            this.projectionDelta = undefined;\n            this.notifyListeners(\"measure\", this.layout.layoutBox);\n            const { visualElement } = this.options;\n            visualElement &&\n                visualElement.notify(\"LayoutMeasure\", this.layout.layoutBox, prevLayout ? prevLayout.layoutBox : undefined);\n        }\n        updateScroll(phase = \"measure\") {\n            let needsMeasurement = Boolean(this.options.layoutScroll && this.instance);\n            if (this.scroll &&\n                this.scroll.animationId === this.root.animationId &&\n                this.scroll.phase === phase) {\n                needsMeasurement = false;\n            }\n            if (needsMeasurement) {\n                const isRoot = checkIsScrollRoot(this.instance);\n                this.scroll = {\n                    animationId: this.root.animationId,\n                    phase,\n                    isRoot,\n                    offset: measureScroll(this.instance),\n                    wasRoot: this.scroll ? this.scroll.isRoot : isRoot,\n                };\n            }\n        }\n        resetTransform() {\n            if (!resetTransform)\n                return;\n            const isResetRequested = this.isLayoutDirty ||\n                this.shouldResetTransform ||\n                this.options.alwaysMeasureLayout;\n            const hasProjection = this.projectionDelta && !isDeltaZero(this.projectionDelta);\n            const transformTemplate = this.getTransformTemplate();\n            const transformTemplateValue = transformTemplate\n                ? transformTemplate(this.latestValues, \"\")\n                : undefined;\n            const transformTemplateHasChanged = transformTemplateValue !== this.prevTransformTemplateValue;\n            if (isResetRequested &&\n                (hasProjection ||\n                    hasTransform(this.latestValues) ||\n                    transformTemplateHasChanged)) {\n                resetTransform(this.instance, transformTemplateValue);\n                this.shouldResetTransform = false;\n                this.scheduleRender();\n            }\n        }\n        measure(removeTransform = true) {\n            const pageBox = this.measurePageBox();\n            let layoutBox = this.removeElementScroll(pageBox);\n            /**\n             * Measurements taken during the pre-render stage\n             * still have transforms applied so we remove them\n             * via calculation.\n             */\n            if (removeTransform) {\n                layoutBox = this.removeTransform(layoutBox);\n            }\n            roundBox(layoutBox);\n            return {\n                animationId: this.root.animationId,\n                measuredBox: pageBox,\n                layoutBox,\n                latestValues: {},\n                source: this.id,\n            };\n        }\n        measurePageBox() {\n            var _a;\n            const { visualElement } = this.options;\n            if (!visualElement)\n                return createBox();\n            const box = visualElement.measureViewportBox();\n            const wasInScrollRoot = ((_a = this.scroll) === null || _a === void 0 ? void 0 : _a.wasRoot) || this.path.some(checkNodeWasScrollRoot);\n            if (!wasInScrollRoot) {\n                // Remove viewport scroll to give page-relative coordinates\n                const { scroll } = this.root;\n                if (scroll) {\n                    translateAxis(box.x, scroll.offset.x);\n                    translateAxis(box.y, scroll.offset.y);\n                }\n            }\n            return box;\n        }\n        removeElementScroll(box) {\n            var _a;\n            const boxWithoutScroll = createBox();\n            copyBoxInto(boxWithoutScroll, box);\n            if ((_a = this.scroll) === null || _a === void 0 ? void 0 : _a.wasRoot) {\n                return boxWithoutScroll;\n            }\n            /**\n             * Performance TODO: Keep a cumulative scroll offset down the tree\n             * rather than loop back up the path.\n             */\n            for (let i = 0; i < this.path.length; i++) {\n                const node = this.path[i];\n                const { scroll, options } = node;\n                if (node !== this.root && scroll && options.layoutScroll) {\n                    /**\n                     * If this is a new scroll root, we want to remove all previous scrolls\n                     * from the viewport box.\n                     */\n                    if (scroll.wasRoot) {\n                        copyBoxInto(boxWithoutScroll, box);\n                    }\n                    translateAxis(boxWithoutScroll.x, scroll.offset.x);\n                    translateAxis(boxWithoutScroll.y, scroll.offset.y);\n                }\n            }\n            return boxWithoutScroll;\n        }\n        applyTransform(box, transformOnly = false) {\n            const withTransforms = createBox();\n            copyBoxInto(withTransforms, box);\n            for (let i = 0; i < this.path.length; i++) {\n                const node = this.path[i];\n                if (!transformOnly &&\n                    node.options.layoutScroll &&\n                    node.scroll &&\n                    node !== node.root) {\n                    transformBox(withTransforms, {\n                        x: -node.scroll.offset.x,\n                        y: -node.scroll.offset.y,\n                    });\n                }\n                if (!hasTransform(node.latestValues))\n                    continue;\n                transformBox(withTransforms, node.latestValues);\n            }\n            if (hasTransform(this.latestValues)) {\n                transformBox(withTransforms, this.latestValues);\n            }\n            return withTransforms;\n        }\n        removeTransform(box) {\n            const boxWithoutTransform = createBox();\n            copyBoxInto(boxWithoutTransform, box);\n            for (let i = 0; i < this.path.length; i++) {\n                const node = this.path[i];\n                if (!node.instance)\n                    continue;\n                if (!hasTransform(node.latestValues))\n                    continue;\n                hasScale(node.latestValues) && node.updateSnapshot();\n                const sourceBox = createBox();\n                const nodeBox = node.measurePageBox();\n                copyBoxInto(sourceBox, nodeBox);\n                removeBoxTransforms(boxWithoutTransform, node.latestValues, node.snapshot ? node.snapshot.layoutBox : undefined, sourceBox);\n            }\n            if (hasTransform(this.latestValues)) {\n                removeBoxTransforms(boxWithoutTransform, this.latestValues);\n            }\n            return boxWithoutTransform;\n        }\n        setTargetDelta(delta) {\n            this.targetDelta = delta;\n            this.root.scheduleUpdateProjection();\n            this.isProjectionDirty = true;\n        }\n        setOptions(options) {\n            this.options = {\n                ...this.options,\n                ...options,\n                crossfade: options.crossfade !== undefined ? options.crossfade : true,\n            };\n        }\n        clearMeasurements() {\n            this.scroll = undefined;\n            this.layout = undefined;\n            this.snapshot = undefined;\n            this.prevTransformTemplateValue = undefined;\n            this.targetDelta = undefined;\n            this.target = undefined;\n            this.isLayoutDirty = false;\n        }\n        forceRelativeParentToResolveTarget() {\n            if (!this.relativeParent)\n                return;\n            /**\n             * If the parent target isn't up-to-date, force it to update.\n             * This is an unfortunate de-optimisation as it means any updating relative\n             * projection will cause all the relative parents to recalculate back\n             * up the tree.\n             */\n            if (this.relativeParent.resolvedRelativeTargetAt !==\n                frameData.timestamp) {\n                this.relativeParent.resolveTargetDelta(true);\n            }\n        }\n        resolveTargetDelta(forceRecalculation = false) {\n            var _a;\n            /**\n             * Once the dirty status of nodes has been spread through the tree, we also\n             * need to check if we have a shared node of a different depth that has itself\n             * been dirtied.\n             */\n            const lead = this.getLead();\n            this.isProjectionDirty || (this.isProjectionDirty = lead.isProjectionDirty);\n            this.isTransformDirty || (this.isTransformDirty = lead.isTransformDirty);\n            this.isSharedProjectionDirty || (this.isSharedProjectionDirty = lead.isSharedProjectionDirty);\n            const isShared = Boolean(this.resumingFrom) || this !== lead;\n            /**\n             * We don't use transform for this step of processing so we don't\n             * need to check whether any nodes have changed transform.\n             */\n            const canSkip = !(forceRecalculation ||\n                (isShared && this.isSharedProjectionDirty) ||\n                this.isProjectionDirty ||\n                ((_a = this.parent) === null || _a === void 0 ? void 0 : _a.isProjectionDirty) ||\n                this.attemptToResolveRelativeTarget ||\n                this.root.updateBlockedByResize);\n            if (canSkip)\n                return;\n            const { layout, layoutId } = this.options;\n            /**\n             * If we have no layout, we can't perform projection, so early return\n             */\n            if (!this.layout || !(layout || layoutId))\n                return;\n            this.resolvedRelativeTargetAt = frameData.timestamp;\n            /**\n             * If we don't have a targetDelta but do have a layout, we can attempt to resolve\n             * a relativeParent. This will allow a component to perform scale correction\n             * even if no animation has started.\n             */\n            if (!this.targetDelta && !this.relativeTarget) {\n                const relativeParent = this.getClosestProjectingParent();\n                if (relativeParent &&\n                    relativeParent.layout &&\n                    this.animationProgress !== 1) {\n                    this.relativeParent = relativeParent;\n                    this.forceRelativeParentToResolveTarget();\n                    this.relativeTarget = createBox();\n                    this.relativeTargetOrigin = createBox();\n                    calcRelativePosition(this.relativeTargetOrigin, this.layout.layoutBox, relativeParent.layout.layoutBox);\n                    copyBoxInto(this.relativeTarget, this.relativeTargetOrigin);\n                }\n                else {\n                    this.relativeParent = this.relativeTarget = undefined;\n                }\n            }\n            /**\n             * If we have no relative target or no target delta our target isn't valid\n             * for this frame.\n             */\n            if (!this.relativeTarget && !this.targetDelta)\n                return;\n            /**\n             * Lazy-init target data structure\n             */\n            if (!this.target) {\n                this.target = createBox();\n                this.targetWithTransforms = createBox();\n            }\n            /**\n             * If we've got a relative box for this component, resolve it into a target relative to the parent.\n             */\n            if (this.relativeTarget &&\n                this.relativeTargetOrigin &&\n                this.relativeParent &&\n                this.relativeParent.target) {\n                this.forceRelativeParentToResolveTarget();\n                calcRelativeBox(this.target, this.relativeTarget, this.relativeParent.target);\n                /**\n                 * If we've only got a targetDelta, resolve it into a target\n                 */\n            }\n            else if (this.targetDelta) {\n                if (Boolean(this.resumingFrom)) {\n                    // TODO: This is creating a new object every frame\n                    this.target = this.applyTransform(this.layout.layoutBox);\n                }\n                else {\n                    copyBoxInto(this.target, this.layout.layoutBox);\n                }\n                applyBoxDelta(this.target, this.targetDelta);\n            }\n            else {\n                /**\n                 * If no target, use own layout as target\n                 */\n                copyBoxInto(this.target, this.layout.layoutBox);\n            }\n            /**\n             * If we've been told to attempt to resolve a relative target, do so.\n             */\n            if (this.attemptToResolveRelativeTarget) {\n                this.attemptToResolveRelativeTarget = false;\n                const relativeParent = this.getClosestProjectingParent();\n                if (relativeParent &&\n                    Boolean(relativeParent.resumingFrom) ===\n                        Boolean(this.resumingFrom) &&\n                    !relativeParent.options.layoutScroll &&\n                    relativeParent.target &&\n                    this.animationProgress !== 1) {\n                    this.relativeParent = relativeParent;\n                    this.forceRelativeParentToResolveTarget();\n                    this.relativeTarget = createBox();\n                    this.relativeTargetOrigin = createBox();\n                    calcRelativePosition(this.relativeTargetOrigin, this.target, relativeParent.target);\n                    copyBoxInto(this.relativeTarget, this.relativeTargetOrigin);\n                }\n                else {\n                    this.relativeParent = this.relativeTarget = undefined;\n                }\n            }\n            /**\n             * Increase debug counter for resolved target deltas\n             */\n            if (isDebug) {\n                metrics.resolvedTargetDeltas++;\n            }\n        }\n        getClosestProjectingParent() {\n            if (!this.parent ||\n                hasScale(this.parent.latestValues) ||\n                has2DTranslate(this.parent.latestValues)) {\n                return undefined;\n            }\n            if (this.parent.isProjecting()) {\n                return this.parent;\n            }\n            else {\n                return this.parent.getClosestProjectingParent();\n            }\n        }\n        isProjecting() {\n            return Boolean((this.relativeTarget ||\n                this.targetDelta ||\n                this.options.layoutRoot) &&\n                this.layout);\n        }\n        calcProjection() {\n            var _a;\n            const lead = this.getLead();\n            const isShared = Boolean(this.resumingFrom) || this !== lead;\n            let canSkip = true;\n            /**\n             * If this is a normal layout animation and neither this node nor its nearest projecting\n             * is dirty then we can't skip.\n             */\n            if (this.isProjectionDirty || ((_a = this.parent) === null || _a === void 0 ? void 0 : _a.isProjectionDirty)) {\n                canSkip = false;\n            }\n            /**\n             * If this is a shared layout animation and this node's shared projection is dirty then\n             * we can't skip.\n             */\n            if (isShared &&\n                (this.isSharedProjectionDirty || this.isTransformDirty)) {\n                canSkip = false;\n            }\n            /**\n             * If we have resolved the target this frame we must recalculate the\n             * projection to ensure it visually represents the internal calculations.\n             */\n            if (this.resolvedRelativeTargetAt === frameData.timestamp) {\n                canSkip = false;\n            }\n            if (canSkip)\n                return;\n            const { layout, layoutId } = this.options;\n            /**\n             * If this section of the tree isn't animating we can\n             * delete our target sources for the following frame.\n             */\n            this.isTreeAnimating = Boolean((this.parent && this.parent.isTreeAnimating) ||\n                this.currentAnimation ||\n                this.pendingAnimation);\n            if (!this.isTreeAnimating) {\n                this.targetDelta = this.relativeTarget = undefined;\n            }\n            if (!this.layout || !(layout || layoutId))\n                return;\n            /**\n             * Reset the corrected box with the latest values from box, as we're then going\n             * to perform mutative operations on it.\n             */\n            copyBoxInto(this.layoutCorrected, this.layout.layoutBox);\n            /**\n             * Record previous tree scales before updating.\n             */\n            const prevTreeScaleX = this.treeScale.x;\n            const prevTreeScaleY = this.treeScale.y;\n            /**\n             * Apply all the parent deltas to this box to produce the corrected box. This\n             * is the layout box, as it will appear on screen as a result of the transforms of its parents.\n             */\n            applyTreeDeltas(this.layoutCorrected, this.treeScale, this.path, isShared);\n            /**\n             * If this layer needs to perform scale correction but doesn't have a target,\n             * use the layout as the target.\n             */\n            if (lead.layout &&\n                !lead.target &&\n                (this.treeScale.x !== 1 || this.treeScale.y !== 1)) {\n                lead.target = lead.layout.layoutBox;\n                lead.targetWithTransforms = createBox();\n            }\n            const { target } = lead;\n            if (!target) {\n                /**\n                 * If we don't have a target to project into, but we were previously\n                 * projecting, we want to remove the stored transform and schedule\n                 * a render to ensure the elements reflect the removed transform.\n                 */\n                if (this.prevProjectionDelta) {\n                    this.createProjectionDeltas();\n                    this.scheduleRender();\n                }\n                return;\n            }\n            if (!this.projectionDelta || !this.prevProjectionDelta) {\n                this.createProjectionDeltas();\n            }\n            else {\n                copyAxisDeltaInto(this.prevProjectionDelta.x, this.projectionDelta.x);\n                copyAxisDeltaInto(this.prevProjectionDelta.y, this.projectionDelta.y);\n            }\n            /**\n             * Update the delta between the corrected box and the target box before user-set transforms were applied.\n             * This will allow us to calculate the corrected borderRadius and boxShadow to compensate\n             * for our layout reprojection, but still allow them to be scaled correctly by the user.\n             * It might be that to simplify this we may want to accept that user-set scale is also corrected\n             * and we wouldn't have to keep and calc both deltas, OR we could support a user setting\n             * to allow people to choose whether these styles are corrected based on just the\n             * layout reprojection or the final bounding box.\n             */\n            calcBoxDelta(this.projectionDelta, this.layoutCorrected, target, this.latestValues);\n            if (this.treeScale.x !== prevTreeScaleX ||\n                this.treeScale.y !== prevTreeScaleY ||\n                !axisDeltaEquals(this.projectionDelta.x, this.prevProjectionDelta.x) ||\n                !axisDeltaEquals(this.projectionDelta.y, this.prevProjectionDelta.y)) {\n                this.hasProjected = true;\n                this.scheduleRender();\n                this.notifyListeners(\"projectionUpdate\", target);\n            }\n            /**\n             * Increase debug counter for recalculated projections\n             */\n            if (isDebug) {\n                metrics.recalculatedProjection++;\n            }\n        }\n        hide() {\n            this.isVisible = false;\n            // TODO: Schedule render\n        }\n        show() {\n            this.isVisible = true;\n            // TODO: Schedule render\n        }\n        scheduleRender(notifyAll = true) {\n            var _a;\n            (_a = this.options.visualElement) === null || _a === void 0 ? void 0 : _a.scheduleRender();\n            if (notifyAll) {\n                const stack = this.getStack();\n                stack && stack.scheduleRender();\n            }\n            if (this.resumingFrom && !this.resumingFrom.instance) {\n                this.resumingFrom = undefined;\n            }\n        }\n        createProjectionDeltas() {\n            this.prevProjectionDelta = createDelta();\n            this.projectionDelta = createDelta();\n            this.projectionDeltaWithTransform = createDelta();\n        }\n        setAnimationOrigin(delta, hasOnlyRelativeTargetChanged = false) {\n            const snapshot = this.snapshot;\n            const snapshotLatestValues = snapshot\n                ? snapshot.latestValues\n                : {};\n            const mixedValues = { ...this.latestValues };\n            const targetDelta = createDelta();\n            if (!this.relativeParent ||\n                !this.relativeParent.options.layoutRoot) {\n                this.relativeTarget = this.relativeTargetOrigin = undefined;\n            }\n            this.attemptToResolveRelativeTarget = !hasOnlyRelativeTargetChanged;\n            const relativeLayout = createBox();\n            const snapshotSource = snapshot ? snapshot.source : undefined;\n            const layoutSource = this.layout ? this.layout.source : undefined;\n            const isSharedLayoutAnimation = snapshotSource !== layoutSource;\n            const stack = this.getStack();\n            const isOnlyMember = !stack || stack.members.length <= 1;\n            const shouldCrossfadeOpacity = Boolean(isSharedLayoutAnimation &&\n                !isOnlyMember &&\n                this.options.crossfade === true &&\n                !this.path.some(hasOpacityCrossfade));\n            this.animationProgress = 0;\n            let prevRelativeTarget;\n            this.mixTargetDelta = (latest) => {\n                const progress = latest / 1000;\n                mixAxisDelta(targetDelta.x, delta.x, progress);\n                mixAxisDelta(targetDelta.y, delta.y, progress);\n                this.setTargetDelta(targetDelta);\n                if (this.relativeTarget &&\n                    this.relativeTargetOrigin &&\n                    this.layout &&\n                    this.relativeParent &&\n                    this.relativeParent.layout) {\n                    calcRelativePosition(relativeLayout, this.layout.layoutBox, this.relativeParent.layout.layoutBox);\n                    mixBox(this.relativeTarget, this.relativeTargetOrigin, relativeLayout, progress);\n                    /**\n                     * If this is an unchanged relative target we can consider the\n                     * projection not dirty.\n                     */\n                    if (prevRelativeTarget &&\n                        boxEquals(this.relativeTarget, prevRelativeTarget)) {\n                        this.isProjectionDirty = false;\n                    }\n                    if (!prevRelativeTarget)\n                        prevRelativeTarget = createBox();\n                    copyBoxInto(prevRelativeTarget, this.relativeTarget);\n                }\n                if (isSharedLayoutAnimation) {\n                    this.animationValues = mixedValues;\n                    mixValues(mixedValues, snapshotLatestValues, this.latestValues, progress, shouldCrossfadeOpacity, isOnlyMember);\n                }\n                this.root.scheduleUpdateProjection();\n                this.scheduleRender();\n                this.animationProgress = progress;\n            };\n            this.mixTargetDelta(this.options.layoutRoot ? 1000 : 0);\n        }\n        startAnimation(options) {\n            this.notifyListeners(\"animationStart\");\n            this.currentAnimation && this.currentAnimation.stop();\n            if (this.resumingFrom && this.resumingFrom.currentAnimation) {\n                this.resumingFrom.currentAnimation.stop();\n            }\n            if (this.pendingAnimation) {\n                cancelFrame(this.pendingAnimation);\n                this.pendingAnimation = undefined;\n            }\n            /**\n             * Start the animation in the next frame to have a frame with progress 0,\n             * where the target is the same as when the animation started, so we can\n             * calculate the relative positions correctly for instant transitions.\n             */\n            this.pendingAnimation = frame.update(() => {\n                globalProjectionState.hasAnimatedSinceResize = true;\n                this.currentAnimation = animateSingleValue(0, animationTarget, {\n                    ...options,\n                    onUpdate: (latest) => {\n                        this.mixTargetDelta(latest);\n                        options.onUpdate && options.onUpdate(latest);\n                    },\n                    onComplete: () => {\n                        options.onComplete && options.onComplete();\n                        this.completeAnimation();\n                    },\n                });\n                if (this.resumingFrom) {\n                    this.resumingFrom.currentAnimation = this.currentAnimation;\n                }\n                this.pendingAnimation = undefined;\n            });\n        }\n        completeAnimation() {\n            if (this.resumingFrom) {\n                this.resumingFrom.currentAnimation = undefined;\n                this.resumingFrom.preserveOpacity = undefined;\n            }\n            const stack = this.getStack();\n            stack && stack.exitAnimationComplete();\n            this.resumingFrom =\n                this.currentAnimation =\n                    this.animationValues =\n                        undefined;\n            this.notifyListeners(\"animationComplete\");\n        }\n        finishAnimation() {\n            if (this.currentAnimation) {\n                this.mixTargetDelta && this.mixTargetDelta(animationTarget);\n                this.currentAnimation.stop();\n            }\n            this.completeAnimation();\n        }\n        applyTransformsToTarget() {\n            const lead = this.getLead();\n            let { targetWithTransforms, target, layout, latestValues } = lead;\n            if (!targetWithTransforms || !target || !layout)\n                return;\n            /**\n             * If we're only animating position, and this element isn't the lead element,\n             * then instead of projecting into the lead box we instead want to calculate\n             * a new target that aligns the two boxes but maintains the layout shape.\n             */\n            if (this !== lead &&\n                this.layout &&\n                layout &&\n                shouldAnimatePositionOnly(this.options.animationType, this.layout.layoutBox, layout.layoutBox)) {\n                target = this.target || createBox();\n                const xLength = calcLength(this.layout.layoutBox.x);\n                target.x.min = lead.target.x.min;\n                target.x.max = target.x.min + xLength;\n                const yLength = calcLength(this.layout.layoutBox.y);\n                target.y.min = lead.target.y.min;\n                target.y.max = target.y.min + yLength;\n            }\n            copyBoxInto(targetWithTransforms, target);\n            /**\n             * Apply the latest user-set transforms to the targetBox to produce the targetBoxFinal.\n             * This is the final box that we will then project into by calculating a transform delta and\n             * applying it to the corrected box.\n             */\n            transformBox(targetWithTransforms, latestValues);\n            /**\n             * Update the delta between the corrected box and the final target box, after\n             * user-set transforms are applied to it. This will be used by the renderer to\n             * create a transform style that will reproject the element from its layout layout\n             * into the desired bounding box.\n             */\n            calcBoxDelta(this.projectionDeltaWithTransform, this.layoutCorrected, targetWithTransforms, latestValues);\n        }\n        registerSharedNode(layoutId, node) {\n            if (!this.sharedNodes.has(layoutId)) {\n                this.sharedNodes.set(layoutId, new NodeStack());\n            }\n            const stack = this.sharedNodes.get(layoutId);\n            stack.add(node);\n            const config = node.options.initialPromotionConfig;\n            node.promote({\n                transition: config ? config.transition : undefined,\n                preserveFollowOpacity: config && config.shouldPreserveFollowOpacity\n                    ? config.shouldPreserveFollowOpacity(node)\n                    : undefined,\n            });\n        }\n        isLead() {\n            const stack = this.getStack();\n            return stack ? stack.lead === this : true;\n        }\n        getLead() {\n            var _a;\n            const { layoutId } = this.options;\n            return layoutId ? ((_a = this.getStack()) === null || _a === void 0 ? void 0 : _a.lead) || this : this;\n        }\n        getPrevLead() {\n            var _a;\n            const { layoutId } = this.options;\n            return layoutId ? (_a = this.getStack()) === null || _a === void 0 ? void 0 : _a.prevLead : undefined;\n        }\n        getStack() {\n            const { layoutId } = this.options;\n            if (layoutId)\n                return this.root.sharedNodes.get(layoutId);\n        }\n        promote({ needsReset, transition, preserveFollowOpacity, } = {}) {\n            const stack = this.getStack();\n            if (stack)\n                stack.promote(this, preserveFollowOpacity);\n            if (needsReset) {\n                this.projectionDelta = undefined;\n                this.needsReset = true;\n            }\n            if (transition)\n                this.setOptions({ transition });\n        }\n        relegate() {\n            const stack = this.getStack();\n            if (stack) {\n                return stack.relegate(this);\n            }\n            else {\n                return false;\n            }\n        }\n        resetSkewAndRotation() {\n            const { visualElement } = this.options;\n            if (!visualElement)\n                return;\n            // If there's no detected skew or rotation values, we can early return without a forced render.\n            let hasDistortingTransform = false;\n            /**\n             * An unrolled check for rotation values. Most elements don't have any rotation and\n             * skipping the nested loop and new object creation is 50% faster.\n             */\n            const { latestValues } = visualElement;\n            if (latestValues.z ||\n                latestValues.rotate ||\n                latestValues.rotateX ||\n                latestValues.rotateY ||\n                latestValues.rotateZ ||\n                latestValues.skewX ||\n                latestValues.skewY) {\n                hasDistortingTransform = true;\n            }\n            // If there's no distorting values, we don't need to do any more.\n            if (!hasDistortingTransform)\n                return;\n            const resetValues = {};\n            if (latestValues.z) {\n                resetDistortingTransform(\"z\", visualElement, resetValues, this.animationValues);\n            }\n            // Check the skew and rotate value of all axes and reset to 0\n            for (let i = 0; i < transformAxes.length; i++) {\n                resetDistortingTransform(`rotate${transformAxes[i]}`, visualElement, resetValues, this.animationValues);\n                resetDistortingTransform(`skew${transformAxes[i]}`, visualElement, resetValues, this.animationValues);\n            }\n            // Force a render of this element to apply the transform with all skews and rotations\n            // set to 0.\n            visualElement.render();\n            // Put back all the values we reset\n            for (const key in resetValues) {\n                visualElement.setStaticValue(key, resetValues[key]);\n                if (this.animationValues) {\n                    this.animationValues[key] = resetValues[key];\n                }\n            }\n            // Schedule a render for the next frame. This ensures we won't visually\n            // see the element with the reset rotate value applied.\n            visualElement.scheduleRender();\n        }\n        getProjectionStyles(styleProp) {\n            var _a, _b;\n            if (!this.instance || this.isSVG)\n                return undefined;\n            if (!this.isVisible) {\n                return hiddenVisibility;\n            }\n            const styles = {\n                visibility: \"\",\n            };\n            const transformTemplate = this.getTransformTemplate();\n            if (this.needsReset) {\n                this.needsReset = false;\n                styles.opacity = \"\";\n                styles.pointerEvents =\n                    resolveMotionValue(styleProp === null || styleProp === void 0 ? void 0 : styleProp.pointerEvents) || \"\";\n                styles.transform = transformTemplate\n                    ? transformTemplate(this.latestValues, \"\")\n                    : \"none\";\n                return styles;\n            }\n            const lead = this.getLead();\n            if (!this.projectionDelta || !this.layout || !lead.target) {\n                const emptyStyles = {};\n                if (this.options.layoutId) {\n                    emptyStyles.opacity =\n                        this.latestValues.opacity !== undefined\n                            ? this.latestValues.opacity\n                            : 1;\n                    emptyStyles.pointerEvents =\n                        resolveMotionValue(styleProp === null || styleProp === void 0 ? void 0 : styleProp.pointerEvents) || \"\";\n                }\n                if (this.hasProjected && !hasTransform(this.latestValues)) {\n                    emptyStyles.transform = transformTemplate\n                        ? transformTemplate({}, \"\")\n                        : \"none\";\n                    this.hasProjected = false;\n                }\n                return emptyStyles;\n            }\n            const valuesToRender = lead.animationValues || lead.latestValues;\n            this.applyTransformsToTarget();\n            styles.transform = buildProjectionTransform(this.projectionDeltaWithTransform, this.treeScale, valuesToRender);\n            if (transformTemplate) {\n                styles.transform = transformTemplate(valuesToRender, styles.transform);\n            }\n            const { x, y } = this.projectionDelta;\n            styles.transformOrigin = `${x.origin * 100}% ${y.origin * 100}% 0`;\n            if (lead.animationValues) {\n                /**\n                 * If the lead component is animating, assign this either the entering/leaving\n                 * opacity\n                 */\n                styles.opacity =\n                    lead === this\n                        ? (_b = (_a = valuesToRender.opacity) !== null && _a !== void 0 ? _a : this.latestValues.opacity) !== null && _b !== void 0 ? _b : 1\n                        : this.preserveOpacity\n                            ? this.latestValues.opacity\n                            : valuesToRender.opacityExit;\n            }\n            else {\n                /**\n                 * Or we're not animating at all, set the lead component to its layout\n                 * opacity and other components to hidden.\n                 */\n                styles.opacity =\n                    lead === this\n                        ? valuesToRender.opacity !== undefined\n                            ? valuesToRender.opacity\n                            : \"\"\n                        : valuesToRender.opacityExit !== undefined\n                            ? valuesToRender.opacityExit\n                            : 0;\n            }\n            /**\n             * Apply scale correction\n             */\n            for (const key in scaleCorrectors) {\n                if (valuesToRender[key] === undefined)\n                    continue;\n                const { correct, applyTo } = scaleCorrectors[key];\n                /**\n                 * Only apply scale correction to the value if we have an\n                 * active projection transform. Otherwise these values become\n                 * vulnerable to distortion if the element changes size without\n                 * a corresponding layout animation.\n                 */\n                const corrected = styles.transform === \"none\"\n                    ? valuesToRender[key]\n                    : correct(valuesToRender[key], lead);\n                if (applyTo) {\n                    const num = applyTo.length;\n                    for (let i = 0; i < num; i++) {\n                        styles[applyTo[i]] = corrected;\n                    }\n                }\n                else {\n                    styles[key] = corrected;\n                }\n            }\n            /**\n             * Disable pointer events on follow components. This is to ensure\n             * that if a follow component covers a lead component it doesn't block\n             * pointer events on the lead.\n             */\n            if (this.options.layoutId) {\n                styles.pointerEvents =\n                    lead === this\n                        ? resolveMotionValue(styleProp === null || styleProp === void 0 ? void 0 : styleProp.pointerEvents) || \"\"\n                        : \"none\";\n            }\n            return styles;\n        }\n        clearSnapshot() {\n            this.resumeFrom = this.snapshot = undefined;\n        }\n        // Only run on root\n        resetTree() {\n            this.root.nodes.forEach((node) => { var _a; return (_a = node.currentAnimation) === null || _a === void 0 ? void 0 : _a.stop(); });\n            this.root.nodes.forEach(clearMeasurements);\n            this.root.sharedNodes.clear();\n        }\n    };\n}\nfunction updateLayout(node) {\n    node.updateLayout();\n}\nfunction notifyLayoutUpdate(node) {\n    var _a;\n    const snapshot = ((_a = node.resumeFrom) === null || _a === void 0 ? void 0 : _a.snapshot) || node.snapshot;\n    if (node.isLead() &&\n        node.layout &&\n        snapshot &&\n        node.hasListeners(\"didUpdate\")) {\n        const { layoutBox: layout, measuredBox: measuredLayout } = node.layout;\n        const { animationType } = node.options;\n        const isShared = snapshot.source !== node.layout.source;\n        // TODO Maybe we want to also resize the layout snapshot so we don't trigger\n        // animations for instance if layout=\"size\" and an element has only changed position\n        if (animationType === \"size\") {\n            eachAxis((axis) => {\n                const axisSnapshot = isShared\n                    ? snapshot.measuredBox[axis]\n                    : snapshot.layoutBox[axis];\n                const length = calcLength(axisSnapshot);\n                axisSnapshot.min = layout[axis].min;\n                axisSnapshot.max = axisSnapshot.min + length;\n            });\n        }\n        else if (shouldAnimatePositionOnly(animationType, snapshot.layoutBox, layout)) {\n            eachAxis((axis) => {\n                const axisSnapshot = isShared\n                    ? snapshot.measuredBox[axis]\n                    : snapshot.layoutBox[axis];\n                const length = calcLength(layout[axis]);\n                axisSnapshot.max = axisSnapshot.min + length;\n                /**\n                 * Ensure relative target gets resized and rerendererd\n                 */\n                if (node.relativeTarget && !node.currentAnimation) {\n                    node.isProjectionDirty = true;\n                    node.relativeTarget[axis].max =\n                        node.relativeTarget[axis].min + length;\n                }\n            });\n        }\n        const layoutDelta = createDelta();\n        calcBoxDelta(layoutDelta, layout, snapshot.layoutBox);\n        const visualDelta = createDelta();\n        if (isShared) {\n            calcBoxDelta(visualDelta, node.applyTransform(measuredLayout, true), snapshot.measuredBox);\n        }\n        else {\n            calcBoxDelta(visualDelta, layout, snapshot.layoutBox);\n        }\n        const hasLayoutChanged = !isDeltaZero(layoutDelta);\n        let hasRelativeTargetChanged = false;\n        if (!node.resumeFrom) {\n            const relativeParent = node.getClosestProjectingParent();\n            /**\n             * If the relativeParent is itself resuming from a different element then\n             * the relative snapshot is not relavent\n             */\n            if (relativeParent && !relativeParent.resumeFrom) {\n                const { snapshot: parentSnapshot, layout: parentLayout } = relativeParent;\n                if (parentSnapshot && parentLayout) {\n                    const relativeSnapshot = createBox();\n                    calcRelativePosition(relativeSnapshot, snapshot.layoutBox, parentSnapshot.layoutBox);\n                    const relativeLayout = createBox();\n                    calcRelativePosition(relativeLayout, layout, parentLayout.layoutBox);\n                    if (!boxEqualsRounded(relativeSnapshot, relativeLayout)) {\n                        hasRelativeTargetChanged = true;\n                    }\n                    if (relativeParent.options.layoutRoot) {\n                        node.relativeTarget = relativeLayout;\n                        node.relativeTargetOrigin = relativeSnapshot;\n                        node.relativeParent = relativeParent;\n                    }\n                }\n            }\n        }\n        node.notifyListeners(\"didUpdate\", {\n            layout,\n            snapshot,\n            delta: visualDelta,\n            layoutDelta,\n            hasLayoutChanged,\n            hasRelativeTargetChanged,\n        });\n    }\n    else if (node.isLead()) {\n        const { onExitComplete } = node.options;\n        onExitComplete && onExitComplete();\n    }\n    /**\n     * Clearing transition\n     * TODO: Investigate why this transition is being passed in as {type: false } from Framer\n     * and why we need it at all\n     */\n    node.options.transition = undefined;\n}\nfunction propagateDirtyNodes(node) {\n    /**\n     * Increase debug counter for nodes encountered this frame\n     */\n    if (isDebug) {\n        metrics.totalNodes++;\n    }\n    if (!node.parent)\n        return;\n    /**\n     * If this node isn't projecting, propagate isProjectionDirty. It will have\n     * no performance impact but it will allow the next child that *is* projecting\n     * but *isn't* dirty to just check its parent to see if *any* ancestor needs\n     * correcting.\n     */\n    if (!node.isProjecting()) {\n        node.isProjectionDirty = node.parent.isProjectionDirty;\n    }\n    /**\n     * Propagate isSharedProjectionDirty and isTransformDirty\n     * throughout the whole tree. A future revision can take another look at\n     * this but for safety we still recalcualte shared nodes.\n     */\n    node.isSharedProjectionDirty || (node.isSharedProjectionDirty = Boolean(node.isProjectionDirty ||\n        node.parent.isProjectionDirty ||\n        node.parent.isSharedProjectionDirty));\n    node.isTransformDirty || (node.isTransformDirty = node.parent.isTransformDirty);\n}\nfunction cleanDirtyNodes(node) {\n    node.isProjectionDirty =\n        node.isSharedProjectionDirty =\n            node.isTransformDirty =\n                false;\n}\nfunction clearSnapshot(node) {\n    node.clearSnapshot();\n}\nfunction clearMeasurements(node) {\n    node.clearMeasurements();\n}\nfunction clearIsLayoutDirty(node) {\n    node.isLayoutDirty = false;\n}\nfunction resetTransformStyle(node) {\n    const { visualElement } = node.options;\n    if (visualElement && visualElement.getProps().onBeforeLayoutMeasure) {\n        visualElement.notify(\"BeforeLayoutMeasure\");\n    }\n    node.resetTransform();\n}\nfunction finishAnimation(node) {\n    node.finishAnimation();\n    node.targetDelta = node.relativeTarget = node.target = undefined;\n    node.isProjectionDirty = true;\n}\nfunction resolveTargetDelta(node) {\n    node.resolveTargetDelta();\n}\nfunction calcProjection(node) {\n    node.calcProjection();\n}\nfunction resetSkewAndRotation(node) {\n    node.resetSkewAndRotation();\n}\nfunction removeLeadSnapshots(stack) {\n    stack.removeLeadSnapshot();\n}\nfunction mixAxisDelta(output, delta, p) {\n    output.translate = mixNumber(delta.translate, 0, p);\n    output.scale = mixNumber(delta.scale, 1, p);\n    output.origin = delta.origin;\n    output.originPoint = delta.originPoint;\n}\nfunction mixAxis(output, from, to, p) {\n    output.min = mixNumber(from.min, to.min, p);\n    output.max = mixNumber(from.max, to.max, p);\n}\nfunction mixBox(output, from, to, p) {\n    mixAxis(output.x, from.x, to.x, p);\n    mixAxis(output.y, from.y, to.y, p);\n}\nfunction hasOpacityCrossfade(node) {\n    return (node.animationValues && node.animationValues.opacityExit !== undefined);\n}\nconst defaultLayoutTransition = {\n    duration: 0.45,\n    ease: [0.4, 0, 0.1, 1],\n};\nconst userAgentContains = (string) => typeof navigator !== \"undefined\" &&\n    navigator.userAgent &&\n    navigator.userAgent.toLowerCase().includes(string);\n/**\n * Measured bounding boxes must be rounded in Safari and\n * left untouched in Chrome, otherwise non-integer layouts within scaled-up elements\n * can appear to jump.\n */\nconst roundPoint = userAgentContains(\"applewebkit/\") && !userAgentContains(\"chrome/\")\n    ? Math.round\n    : noop;\nfunction roundAxis(axis) {\n    // Round to the nearest .5 pixels to support subpixel layouts\n    axis.min = roundPoint(axis.min);\n    axis.max = roundPoint(axis.max);\n}\nfunction roundBox(box) {\n    roundAxis(box.x);\n    roundAxis(box.y);\n}\nfunction shouldAnimatePositionOnly(animationType, snapshot, layout) {\n    return (animationType === \"position\" ||\n        (animationType === \"preserve-aspect\" &&\n            !isNear(aspectRatio(snapshot), aspectRatio(layout), 0.2)));\n}\nfunction checkNodeWasScrollRoot(node) {\n    var _a;\n    return node !== node.root && ((_a = node.scroll) === null || _a === void 0 ? void 0 : _a.wasRoot);\n}\n\nexport { cleanDirtyNodes, createProjectionNode, mixAxis, mixAxisDelta, mixBox, propagateDirtyNodes };\n","function isSVGElement(element) {\n    return element instanceof SVGElement && element.tagName !== \"svg\";\n}\n\nexport { isSVGElement };\n","import { secondsToMilliseconds } from 'motion-utils';\nimport { time } from '../frameloop/sync-time.mjs';\nimport { frame, cancelFrame } from '../frameloop/frame.mjs';\n\n/**\n * Timeout defined in ms\n */\nfunction delay(callback, timeout) {\n    const start = time.now();\n    const checkElapsed = ({ timestamp }) => {\n        const elapsed = timestamp - start;\n        if (elapsed >= timeout) {\n            cancelFrame(checkElapsed);\n            callback(elapsed - timeout);\n        }\n    };\n    frame.read(checkElapsed, true);\n    return () => cancelFrame(checkElapsed);\n}\nfunction delayInSeconds(callback, timeout) {\n    return delay(callback, secondsToMilliseconds(timeout));\n}\n\nexport { delay, delayInSeconds };\n","import { motionValue } from '../../value/index.mjs';\nimport { isMotionValue } from '../../value/utils/is-motion-value.mjs';\nimport { animateMotionValue } from '../interfaces/motion-value.mjs';\n\nfunction animateSingleValue(value, keyframes, options) {\n    const motionValue$1 = isMotionValue(value) ? value : motionValue(value);\n    motionValue$1.start(animateMotionValue(\"\", motionValue$1, keyframes, options));\n    return motionValue$1.animation;\n}\n\nexport { animateSingleValue };\n","function buildProjectionTransform(delta, treeScale, latestTransform) {\n    let transform = \"\";\n    /**\n     * The translations we use to calculate are always relative to the viewport coordinate space.\n     * But when we apply scales, we also scale the coordinate space of an element and its children.\n     * For instance if we have a treeScale (the culmination of all parent scales) of 0.5 and we need\n     * to move an element 100 pixels, we actually need to move it 200 in within that scaled space.\n     */\n    const xTranslate = delta.x.translate / treeScale.x;\n    const yTranslate = delta.y.translate / treeScale.y;\n    const zTranslate = (latestTransform === null || latestTransform === void 0 ? void 0 : latestTransform.z) || 0;\n    if (xTranslate || yTranslate || zTranslate) {\n        transform = `translate3d(${xTranslate}px, ${yTranslate}px, ${zTranslate}px) `;\n    }\n    /**\n     * Apply scale correction for the tree transform.\n     * This will apply scale to the screen-orientated axes.\n     */\n    if (treeScale.x !== 1 || treeScale.y !== 1) {\n        transform += `scale(${1 / treeScale.x}, ${1 / treeScale.y}) `;\n    }\n    if (latestTransform) {\n        const { transformPerspective, rotate, rotateX, rotateY, skewX, skewY } = latestTransform;\n        if (transformPerspective)\n            transform = `perspective(${transformPerspective}px) ${transform}`;\n        if (rotate)\n            transform += `rotate(${rotate}deg) `;\n        if (rotateX)\n            transform += `rotateX(${rotateX}deg) `;\n        if (rotateY)\n            transform += `rotateY(${rotateY}deg) `;\n        if (skewX)\n            transform += `skewX(${skewX}deg) `;\n        if (skewY)\n            transform += `skewY(${skewY}deg) `;\n    }\n    /**\n     * Apply scale to match the size of the element to the size we want it.\n     * This will apply scale to the element-orientated axes.\n     */\n    const elementScaleX = delta.x.scale * treeScale.x;\n    const elementScaleY = delta.y.scale * treeScale.y;\n    if (elementScaleX !== 1 || elementScaleY !== 1) {\n        transform += `scale(${elementScaleX}, ${elementScaleY})`;\n    }\n    return transform || \"none\";\n}\n\nexport { buildProjectionTransform };\n","import { createProjectionNode } from './create-projection-node.mjs';\nimport { addDomEvent } from '../../events/add-dom-event.mjs';\n\nconst DocumentProjectionNode = createProjectionNode({\n    attachResizeListener: (ref, notify) => addDomEvent(ref, \"resize\", notify),\n    measureScroll: () => ({\n        x: document.documentElement.scrollLeft || document.body.scrollLeft,\n        y: document.documentElement.scrollTop || document.body.scrollTop,\n    }),\n    checkIsScrollRoot: () => true,\n});\n\nexport { DocumentProjectionNode };\n","import { createProjectionNode } from './create-projection-node.mjs';\nimport { DocumentProjectionNode } from './DocumentProjectionNode.mjs';\n\nconst rootProjectionNode = {\n    current: undefined,\n};\nconst HTMLProjectionNode = createProjectionNode({\n    measureScroll: (instance) => ({\n        x: instance.scrollLeft,\n        y: instance.scrollTop,\n    }),\n    defaultParent: () => {\n        if (!rootProjectionNode.current) {\n            const documentNode = new DocumentProjectionNode({});\n            documentNode.mount(window);\n            documentNode.setOptions({ layoutScroll: true });\n            rootProjectionNode.current = documentNode;\n        }\n        return rootProjectionNode.current;\n    },\n    resetTransform: (instance, value) => {\n        instance.style.transform = value !== undefined ? value : \"none\";\n    },\n    checkIsScrollRoot: (instance) => Boolean(window.getComputedStyle(instance).position === \"fixed\"),\n});\n\nexport { HTMLProjectionNode, rootProjectionNode };\n","import { DragGesture } from '../../gestures/drag/index.mjs';\nimport { PanGesture } from '../../gestures/pan/index.mjs';\nimport { MeasureLayout } from './layout/MeasureLayout.mjs';\nimport { HTMLProjectionNode } from '../../projection/node/HTMLProjectionNode.mjs';\n\nconst drag = {\n    pan: {\n        Feature: PanGesture,\n    },\n    drag: {\n        Feature: DragGesture,\n        ProjectionNode: HTMLProjectionNode,\n        MeasureLayout,\n    },\n};\n\nexport { drag };\n","import { Feature } from '../../motion/features/Feature.mjs';\nimport { noop } from 'motion-utils';\nimport { VisualElementDragControls } from './VisualElementDragControls.mjs';\n\nclass DragGesture extends Feature {\n    constructor(node) {\n        super(node);\n        this.removeGroupControls = noop;\n        this.removeListeners = noop;\n        this.controls = new VisualElementDragControls(node);\n    }\n    mount() {\n        // If we've been provided a DragControls for manual control over the drag gesture,\n        // subscribe this component to it on mount.\n        const { dragControls } = this.node.getProps();\n        if (dragControls) {\n            this.removeGroupControls = dragControls.subscribe(this.controls);\n        }\n        this.removeListeners = this.controls.addListeners() || noop;\n    }\n    unmount() {\n        this.removeGroupControls();\n        this.removeListeners();\n    }\n}\n\nexport { DragGesture };\n","import { Feature } from '../motion/features/Feature.mjs';\nimport { hover } from 'motion-dom';\nimport { extractEventInfo } from '../events/event-info.mjs';\nimport { frame } from '../frameloop/frame.mjs';\n\nfunction handleHoverEvent(node, event, lifecycle) {\n    const { props } = node;\n    if (node.animationState && props.whileHover) {\n        node.animationState.setActive(\"whileHover\", lifecycle === \"Start\");\n    }\n    const eventName = (\"onHover\" + lifecycle);\n    const callback = props[eventName];\n    if (callback) {\n        frame.postRender(() => callback(event, extractEventInfo(event)));\n    }\n}\nclass HoverGesture extends Feature {\n    mount() {\n        const { current } = this.node;\n        if (!current)\n            return;\n        this.unmount = hover(current, (startEvent) => {\n            handleHoverEvent(this.node, startEvent, \"Start\");\n            return (endEvent) => handleHoverEvent(this.node, endEvent, \"End\");\n        });\n    }\n    unmount() { }\n}\n\nexport { HoverGesture };\n","import { Feature } from '../motion/features/Feature.mjs';\nimport { press } from 'motion-dom';\nimport { extractEventInfo } from '../events/event-info.mjs';\nimport { frame } from '../frameloop/frame.mjs';\n\nfunction handlePressEvent(node, event, lifecycle) {\n    const { props } = node;\n    if (node.animationState && props.whileTap) {\n        node.animationState.setActive(\"whileTap\", lifecycle === \"Start\");\n    }\n    const eventName = (\"onTap\" + (lifecycle === \"End\" ? \"\" : lifecycle));\n    const callback = props[eventName];\n    if (callback) {\n        frame.postRender(() => callback(event, extractEventInfo(event)));\n    }\n}\nclass PressGesture extends Feature {\n    mount() {\n        const { current } = this.node;\n        if (!current)\n            return;\n        this.unmount = press(current, (startEvent) => {\n            handlePressEvent(this.node, startEvent, \"Start\");\n            return (endEvent, { success }) => handlePressEvent(this.node, endEvent, success ? \"End\" : \"Cancel\");\n        }, { useGlobalTarget: this.node.props.globalTapTarget });\n    }\n    unmount() { }\n}\n\nexport { PressGesture };\n","/**\n * Map an IntersectionHandler callback to an element. We only ever make one handler for one\n * element, so even though these handlers might all be triggered by different\n * observers, we can keep them in the same map.\n */\nconst observerCallbacks = new WeakMap();\n/**\n * Multiple observers can be created for multiple element/document roots. Each with\n * different settings. So here we store dictionaries of observers to each root,\n * using serialised settings (threshold/margin) as lookup keys.\n */\nconst observers = new WeakMap();\nconst fireObserverCallback = (entry) => {\n    const callback = observerCallbacks.get(entry.target);\n    callback && callback(entry);\n};\nconst fireAllObserverCallbacks = (entries) => {\n    entries.forEach(fireObserverCallback);\n};\nfunction initIntersectionObserver({ root, ...options }) {\n    const lookupRoot = root || document;\n    /**\n     * If we don't have an observer lookup map for this root, create one.\n     */\n    if (!observers.has(lookupRoot)) {\n        observers.set(lookupRoot, {});\n    }\n    const rootObservers = observers.get(lookupRoot);\n    const key = JSON.stringify(options);\n    /**\n     * If we don't have an observer for this combination of root and settings,\n     * create one.\n     */\n    if (!rootObservers[key]) {\n        rootObservers[key] = new IntersectionObserver(fireAllObserverCallbacks, { root, ...options });\n    }\n    return rootObservers[key];\n}\nfunction observeIntersection(element, options, callback) {\n    const rootInteresectionObserver = initIntersectionObserver(options);\n    observerCallbacks.set(element, callback);\n    rootInteresectionObserver.observe(element);\n    return () => {\n        observerCallbacks.delete(element);\n        rootInteresectionObserver.unobserve(element);\n    };\n}\n\nexport { observeIntersection };\n","import { Feature } from '../Feature.mjs';\nimport { observeIntersection } from './observers.mjs';\n\nconst thresholdNames = {\n    some: 0,\n    all: 1,\n};\nclass InViewFeature extends Feature {\n    constructor() {\n        super(...arguments);\n        this.hasEnteredView = false;\n        this.isInView = false;\n    }\n    startObserver() {\n        this.unmount();\n        const { viewport = {} } = this.node.getProps();\n        const { root, margin: rootMargin, amount = \"some\", once } = viewport;\n        const options = {\n            root: root ? root.current : undefined,\n            rootMargin,\n            threshold: typeof amount === \"number\" ? amount : thresholdNames[amount],\n        };\n        const onIntersectionUpdate = (entry) => {\n            const { isIntersecting } = entry;\n            /**\n             * If there's been no change in the viewport state, early return.\n             */\n            if (this.isInView === isIntersecting)\n                return;\n            this.isInView = isIntersecting;\n            /**\n             * Handle hasEnteredView. If this is only meant to run once, and\n             * element isn't visible, early return. Otherwise set hasEnteredView to true.\n             */\n            if (once && !isIntersecting && this.hasEnteredView) {\n                return;\n            }\n            else if (isIntersecting) {\n                this.hasEnteredView = true;\n            }\n            if (this.node.animationState) {\n                this.node.animationState.setActive(\"whileInView\", isIntersecting);\n            }\n            /**\n             * Use the latest committed props rather than the ones in scope\n             * when this observer is created\n             */\n            const { onViewportEnter, onViewportLeave } = this.node.getProps();\n            const callback = isIntersecting ? onViewportEnter : onViewportLeave;\n            callback && callback(entry);\n        };\n        return observeIntersection(this.node.current, options, onIntersectionUpdate);\n    }\n    mount() {\n        this.startObserver();\n    }\n    update() {\n        if (typeof IntersectionObserver === \"undefined\")\n            return;\n        const { props, prevProps } = this.node;\n        const hasOptionsChanged = [\"amount\", \"margin\", \"root\"].some(hasViewportOptionChanged(props, prevProps));\n        if (hasOptionsChanged) {\n            this.startObserver();\n        }\n    }\n    unmount() { }\n}\nfunction hasViewportOptionChanged({ viewport = {} }, { viewport: prevViewport = {} } = {}) {\n    return (name) => viewport[name] !== prevViewport[name];\n}\n\nexport { InViewFeature };\n","import { HoverGesture } from '../../gestures/hover.mjs';\nimport { FocusGesture } from '../../gestures/focus.mjs';\nimport { PressGesture } from '../../gestures/press.mjs';\nimport { InViewFeature } from './viewport/index.mjs';\n\nconst gestureAnimations = {\n    inView: {\n        Feature: InViewFeature,\n    },\n    tap: {\n        Feature: PressGesture,\n    },\n    focus: {\n        Feature: FocusGesture,\n    },\n    hover: {\n        Feature: HoverGesture,\n    },\n};\n\nexport { gestureAnimations };\n","import { addDomEvent } from '../events/add-dom-event.mjs';\nimport { Feature } from '../motion/features/Feature.mjs';\nimport { pipe } from '../utils/pipe.mjs';\n\nclass FocusGesture extends Feature {\n    constructor() {\n        super(...arguments);\n        this.isActive = false;\n    }\n    onFocus() {\n        let isFocusVisible = false;\n        /**\n         * If this element doesn't match focus-visible then don't\n         * apply whileHover. But, if matches throws that focus-visible\n         * is not a valid selector then in that browser outline styles will be applied\n         * to the element by default and we want to match that behaviour with whileFocus.\n         */\n        try {\n            isFocusVisible = this.node.current.matches(\":focus-visible\");\n        }\n        catch (e) {\n            isFocusVisible = true;\n        }\n        if (!isFocusVisible || !this.node.animationState)\n            return;\n        this.node.animationState.setActive(\"whileFocus\", true);\n        this.isActive = true;\n    }\n    onBlur() {\n        if (!this.isActive || !this.node.animationState)\n            return;\n        this.node.animationState.setActive(\"whileFocus\", false);\n        this.isActive = false;\n    }\n    mount() {\n        this.unmount = pipe(addDomEvent(this.node.current, \"focus\", () => this.onFocus()), addDomEvent(this.node.current, \"blur\", () => this.onBlur()));\n    }\n    unmount() { }\n}\n\nexport { FocusGesture };\n","import { HTMLProjectionNode } from '../../projection/node/HTMLProjectionNode.mjs';\nimport { MeasureLayout } from './layout/MeasureLayout.mjs';\n\nconst layout = {\n    layout: {\n        ProjectionNode: HTMLProjectionNode,\n        MeasureLayout,\n    },\n};\n\nexport { layout };\n","\"use client\";\nimport { createContext } from 'react';\n\nconst LazyContext = createContext({ strict: false });\n\nexport { LazyContext };\n","\"use client\";\nimport { createContext } from 'react';\n\n/**\n * @public\n */\nconst MotionConfigContext = createContext({\n    transformPagePoint: (p) => p,\n    isStatic: false,\n    reducedMotion: \"never\",\n});\n\nexport { MotionConfigContext };\n","\"use client\";\nimport { createContext } from 'react';\n\nconst MotionContext = createContext({});\n\nexport { MotionContext };\n","import { isAnimationControls } from '../../animation/utils/is-animation-controls.mjs';\nimport { isVariantLabel } from './is-variant-label.mjs';\nimport { variantProps } from './variant-props.mjs';\n\nfunction isControllingVariants(props) {\n    return (isAnimationControls(props.animate) ||\n        variantProps.some((name) => isVariantLabel(props[name])));\n}\nfunction isVariantNode(props) {\n    return Boolean(isControllingVariants(props) || props.variants);\n}\n\nexport { isControllingVariants, isVariantNode };\n","import { useContext, useMemo } from 'react';\nimport { MotionContext } from './index.mjs';\nimport { getCurrentTreeVariants } from './utils.mjs';\n\nfunction useCreateMotionContext(props) {\n    const { initial, animate } = getCurrentTreeVariants(props, useContext(MotionContext));\n    return useMemo(() => ({ initial, animate }), [variantLabelsAsDependency(initial), variantLabelsAsDependency(animate)]);\n}\nfunction variantLabelsAsDependency(prop) {\n    return Array.isArray(prop) ? prop.join(\" \") : prop;\n}\n\nexport { useCreateMotionContext };\n","const isBrowser = typeof window !== \"undefined\";\n\nexport { isBrowser };\n","const featureProps = {\n    animation: [\n        \"animate\",\n        \"variants\",\n        \"whileHover\",\n        \"whileTap\",\n        \"exit\",\n        \"whileInView\",\n        \"whileFocus\",\n        \"whileDrag\",\n    ],\n    exit: [\"exit\"],\n    drag: [\"drag\", \"dragControls\"],\n    focus: [\"whileFocus\"],\n    hover: [\"whileHover\", \"onHoverStart\", \"onHoverEnd\"],\n    tap: [\"whileTap\", \"onTap\", \"onTapStart\", \"onTapCancel\"],\n    pan: [\"onPan\", \"onPanStart\", \"onPanSessionStart\", \"onPanEnd\"],\n    inView: [\"whileInView\", \"onViewportEnter\", \"onViewportLeave\"],\n    layout: [\"layout\", \"layoutId\"],\n};\nconst featureDefinitions = {};\nfor (const key in featureProps) {\n    featureDefinitions[key] = {\n        isEnabled: (props) => featureProps[key].some((name) => !!props[name]),\n    };\n}\n\nexport { featureDefinitions };\n","const motionComponentSymbol = Symbol.for(\"motionComponentSymbol\");\n\nexport { motionComponentSymbol };\n","import { useCallback } from 'react';\nimport { isRefObject } from '../../utils/is-ref-object.mjs';\n\n/**\n * Creates a ref function that, when called, hydrates the provided\n * external ref and VisualElement.\n */\nfunction useMotionRef(visualState, visualElement, externalRef) {\n    return useCallback((instance) => {\n        if (instance) {\n            visualState.onMount && visualState.onMount(instance);\n        }\n        if (visualElement) {\n            if (instance) {\n                visualElement.mount(instance);\n            }\n            else {\n                visualElement.unmount();\n            }\n        }\n        if (externalRef) {\n            if (typeof externalRef === \"function\") {\n                externalRef(instance);\n            }\n            else if (isRefObject(externalRef)) {\n                externalRef.current = instance;\n            }\n        }\n    }, \n    /**\n     * Only pass a new ref callback to React if we've received a visual element\n     * factory. Otherwise we'll be mounting/remounting every time externalRef\n     * or other dependencies change.\n     */\n    [visualElement]);\n}\n\nexport { useMotionRef };\n","import { useLayoutEffect, useEffect } from 'react';\nimport { isBrowser } from './is-browser.mjs';\n\nconst useIsomorphicLayoutEffect = isBrowser ? useLayoutEffect : useEffect;\n\nexport { useIsomorphicLayoutEffect };\n","import { useContext, useRef, useInsertionEffect, useEffect } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { MotionContext } from '../../context/MotionContext/index.mjs';\nimport { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';\nimport { LazyContext } from '../../context/LazyContext.mjs';\nimport { MotionConfigContext } from '../../context/MotionConfigContext.mjs';\nimport { optimizedAppearDataAttribute } from '../../animation/optimized-appear/data-id.mjs';\nimport { microtask } from '../../frameloop/microtask.mjs';\nimport { isRefObject } from '../../utils/is-ref-object.mjs';\nimport { SwitchLayoutGroupContext } from '../../context/SwitchLayoutGroupContext.mjs';\n\nfunction useVisualElement(Component, visualState, props, createVisualElement, ProjectionNodeConstructor) {\n    var _a, _b;\n    const { visualElement: parent } = useContext(MotionContext);\n    const lazyContext = useContext(LazyContext);\n    const presenceContext = useContext(PresenceContext);\n    const reducedMotionConfig = useContext(MotionConfigContext).reducedMotion;\n    const visualElementRef = useRef(null);\n    /**\n     * If we haven't preloaded a renderer, check to see if we have one lazy-loaded\n     */\n    createVisualElement = createVisualElement || lazyContext.renderer;\n    if (!visualElementRef.current && createVisualElement) {\n        visualElementRef.current = createVisualElement(Component, {\n            visualState,\n            parent,\n            props,\n            presenceContext,\n            blockInitialAnimation: presenceContext\n                ? presenceContext.initial === false\n                : false,\n            reducedMotionConfig,\n        });\n    }\n    const visualElement = visualElementRef.current;\n    /**\n     * Load Motion gesture and animation features. These are rendered as renderless\n     * components so each feature can optionally make use of React lifecycle methods.\n     */\n    const initialLayoutGroupConfig = useContext(SwitchLayoutGroupContext);\n    if (visualElement &&\n        !visualElement.projection &&\n        ProjectionNodeConstructor &&\n        (visualElement.type === \"html\" || visualElement.type === \"svg\")) {\n        createProjectionNode(visualElementRef.current, props, ProjectionNodeConstructor, initialLayoutGroupConfig);\n    }\n    const isMounted = useRef(false);\n    useInsertionEffect(() => {\n        /**\n         * Check the component has already mounted before calling\n         * `update` unnecessarily. This ensures we skip the initial update.\n         */\n        if (visualElement && isMounted.current) {\n            visualElement.update(props, presenceContext);\n        }\n    });\n    /**\n     * Cache this value as we want to know whether HandoffAppearAnimations\n     * was present on initial render - it will be deleted after this.\n     */\n    const optimisedAppearId = props[optimizedAppearDataAttribute];\n    const wantsHandoff = useRef(Boolean(optimisedAppearId) &&\n        !((_a = window.MotionHandoffIsComplete) === null || _a === void 0 ? void 0 : _a.call(window, optimisedAppearId)) &&\n        ((_b = window.MotionHasOptimisedAnimation) === null || _b === void 0 ? void 0 : _b.call(window, optimisedAppearId)));\n    useIsomorphicLayoutEffect(() => {\n        if (!visualElement)\n            return;\n        isMounted.current = true;\n        window.MotionIsMounted = true;\n        visualElement.updateFeatures();\n        microtask.render(visualElement.render);\n        /**\n         * Ideally this function would always run in a useEffect.\n         *\n         * However, if we have optimised appear animations to handoff from,\n         * it needs to happen synchronously to ensure there's no flash of\n         * incorrect styles in the event of a hydration error.\n         *\n         * So if we detect a situtation where optimised appear animations\n         * are running, we use useLayoutEffect to trigger animations.\n         */\n        if (wantsHandoff.current && visualElement.animationState) {\n            visualElement.animationState.animateChanges();\n        }\n    });\n    useEffect(() => {\n        if (!visualElement)\n            return;\n        if (!wantsHandoff.current && visualElement.animationState) {\n            visualElement.animationState.animateChanges();\n        }\n        if (wantsHandoff.current) {\n            // This ensures all future calls to animateChanges() in this component will run in useEffect\n            queueMicrotask(() => {\n                var _a;\n                (_a = window.MotionHandoffMarkAsComplete) === null || _a === void 0 ? void 0 : _a.call(window, optimisedAppearId);\n            });\n            wantsHandoff.current = false;\n        }\n    });\n    return visualElement;\n}\nfunction createProjectionNode(visualElement, props, ProjectionNodeConstructor, initialPromotionConfig) {\n    const { layoutId, layout, drag, dragConstraints, layoutScroll, layoutRoot, } = props;\n    visualElement.projection = new ProjectionNodeConstructor(visualElement.latestValues, props[\"data-framer-portal-id\"]\n        ? undefined\n        : getClosestProjectingNode(visualElement.parent));\n    visualElement.projection.setOptions({\n        layoutId,\n        layout,\n        alwaysMeasureLayout: Boolean(drag) || (dragConstraints && isRefObject(dragConstraints)),\n        visualElement,\n        /**\n         * TODO: Update options in an effect. This could be tricky as it'll be too late\n         * to update by the time layout animations run.\n         * We also need to fix this safeToRemove by linking it up to the one returned by usePresence,\n         * ensuring it gets called if there's no potential layout animations.\n         *\n         */\n        animationType: typeof layout === \"string\" ? layout : \"both\",\n        initialPromotionConfig,\n        layoutScroll,\n        layoutRoot,\n    });\n}\nfunction getClosestProjectingNode(visualElement) {\n    if (!visualElement)\n        return undefined;\n    return visualElement.options.allowProjection !== false\n        ? visualElement.projection\n        : getClosestProjectingNode(visualElement.parent);\n}\n\nexport { useVisualElement };\n","\"use client\";\nimport { jsxs, jsx } from 'react/jsx-runtime';\nimport { warning, invariant } from 'motion-utils';\nimport { forwardRef, useContext } from 'react';\nimport { LayoutGroupContext } from '../context/LayoutGroupContext.mjs';\nimport { LazyContext } from '../context/LazyContext.mjs';\nimport { MotionConfigContext } from '../context/MotionConfigContext.mjs';\nimport { MotionContext } from '../context/MotionContext/index.mjs';\nimport { useCreateMotionContext } from '../context/MotionContext/create.mjs';\nimport { isBrowser } from '../utils/is-browser.mjs';\nimport { featureDefinitions } from './features/definitions.mjs';\nimport { loadFeatures } from './features/load-features.mjs';\nimport { motionComponentSymbol } from './utils/symbol.mjs';\nimport { useMotionRef } from './utils/use-motion-ref.mjs';\nimport { useVisualElement } from './utils/use-visual-element.mjs';\n\n/**\n * Create a `motion` component.\n *\n * This function accepts a Component argument, which can be either a string (ie \"div\"\n * for `motion.div`), or an actual React component.\n *\n * Alongside this is a config option which provides a way of rendering the provided\n * component \"offline\", or outside the React render cycle.\n */\nfunction createRendererMotionComponent({ preloadedFeatures, createVisualElement, useRender, useVisualState, Component, }) {\n    var _a, _b;\n    preloadedFeatures && loadFeatures(preloadedFeatures);\n    function MotionComponent(props, externalRef) {\n        /**\n         * If we need to measure the element we load this functionality in a\n         * separate class component in order to gain access to getSnapshotBeforeUpdate.\n         */\n        let MeasureLayout;\n        const configAndProps = {\n            ...useContext(MotionConfigContext),\n            ...props,\n            layoutId: useLayoutId(props),\n        };\n        const { isStatic } = configAndProps;\n        const context = useCreateMotionContext(props);\n        const visualState = useVisualState(props, isStatic);\n        if (!isStatic && isBrowser) {\n            useStrictMode(configAndProps, preloadedFeatures);\n            const layoutProjection = getProjectionFunctionality(configAndProps);\n            MeasureLayout = layoutProjection.MeasureLayout;\n            /**\n             * Create a VisualElement for this component. A VisualElement provides a common\n             * interface to renderer-specific APIs (ie DOM/Three.js etc) as well as\n             * providing a way of rendering to these APIs outside of the React render loop\n             * for more performant animations and interactions\n             */\n            context.visualElement = useVisualElement(Component, visualState, configAndProps, createVisualElement, layoutProjection.ProjectionNode);\n        }\n        /**\n         * The mount order and hierarchy is specific to ensure our element ref\n         * is hydrated by the time features fire their effects.\n         */\n        return (jsxs(MotionContext.Provider, { value: context, children: [MeasureLayout && context.visualElement ? (jsx(MeasureLayout, { visualElement: context.visualElement, ...configAndProps })) : null, useRender(Component, props, useMotionRef(visualState, context.visualElement, externalRef), visualState, isStatic, context.visualElement)] }));\n    }\n    MotionComponent.displayName = `motion.${typeof Component === \"string\"\n        ? Component\n        : `create(${(_b = (_a = Component.displayName) !== null && _a !== void 0 ? _a : Component.name) !== null && _b !== void 0 ? _b : \"\"})`}`;\n    const ForwardRefMotionComponent = forwardRef(MotionComponent);\n    ForwardRefMotionComponent[motionComponentSymbol] = Component;\n    return ForwardRefMotionComponent;\n}\nfunction useLayoutId({ layoutId }) {\n    const layoutGroupId = useContext(LayoutGroupContext).id;\n    return layoutGroupId && layoutId !== undefined\n        ? layoutGroupId + \"-\" + layoutId\n        : layoutId;\n}\nfunction useStrictMode(configAndProps, preloadedFeatures) {\n    const isStrict = useContext(LazyContext).strict;\n    /**\n     * If we're in development mode, check to make sure we're not rendering a motion component\n     * as a child of LazyMotion, as this will break the file-size benefits of using it.\n     */\n    if (process.env.NODE_ENV !== \"production\" &&\n        preloadedFeatures &&\n        isStrict) {\n        const strictMessage = \"You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.\";\n        configAndProps.ignoreStrict\n            ? warning(false, strictMessage)\n            : invariant(false, strictMessage);\n    }\n}\nfunction getProjectionFunctionality(props) {\n    const { drag, layout } = featureDefinitions;\n    if (!drag && !layout)\n        return {};\n    const combined = { ...drag, ...layout };\n    return {\n        MeasureLayout: (drag === null || drag === void 0 ? void 0 : drag.isEnabled(props)) || (layout === null || layout === void 0 ? void 0 : layout.isEnabled(props))\n            ? combined.MeasureLayout\n            : undefined,\n        ProjectionNode: combined.ProjectionNode,\n    };\n}\n\nexport { createRendererMotionComponent };\n","import { isVariantLabel } from '../../render/utils/is-variant-label.mjs';\nimport { isControllingVariants } from '../../render/utils/is-controlling-variants.mjs';\n\nfunction getCurrentTreeVariants(props, context) {\n    if (isControllingVariants(props)) {\n        const { initial, animate } = props;\n        return {\n            initial: initial === false || isVariantLabel(initial)\n                ? initial\n                : undefined,\n            animate: isVariantLabel(animate) ? animate : undefined,\n        };\n    }\n    return props.inherit !== false ? context : {};\n}\n\nexport { getCurrentTreeVariants };\n","import { featureDefinitions } from './definitions.mjs';\n\nfunction loadFeatures(features) {\n    for (const key in features) {\n        featureDefinitions[key] = {\n            ...featureDefinitions[key],\n            ...features[key],\n        };\n    }\n}\n\nexport { loadFeatures };\n","/**\n * We keep these listed separately as we use the lowercase tag names as part\n * of the runtime bundle to detect SVG components\n */\nconst lowercaseSVGElements = [\n    \"animate\",\n    \"circle\",\n    \"defs\",\n    \"desc\",\n    \"ellipse\",\n    \"g\",\n    \"image\",\n    \"line\",\n    \"filter\",\n    \"marker\",\n    \"mask\",\n    \"metadata\",\n    \"path\",\n    \"pattern\",\n    \"polygon\",\n    \"polyline\",\n    \"rect\",\n    \"stop\",\n    \"switch\",\n    \"symbol\",\n    \"svg\",\n    \"text\",\n    \"tspan\",\n    \"use\",\n    \"view\",\n];\n\nexport { lowercaseSVGElements };\n","import { lowercaseSVGElements } from '../../svg/lowercase-elements.mjs';\n\nfunction isSVGComponent(Component) {\n    if (\n    /**\n     * If it's not a string, it's a custom React component. Currently we only support\n     * HTML custom React components.\n     */\n    typeof Component !== \"string\" ||\n        /**\n         * If it contains a dash, the element is a custom HTML webcomponent.\n         */\n        Component.includes(\"-\")) {\n        return false;\n    }\n    else if (\n    /**\n     * If it's in our list of lowercase SVG tags, it's an SVG component\n     */\n    lowercaseSVGElements.indexOf(Component) > -1 ||\n        /**\n         * If it contains a capital letter, it's an SVG component\n         */\n        /[A-Z]/u.test(Component)) {\n        return true;\n    }\n    return false;\n}\n\nexport { isSVGComponent };\n","import { useRef } from 'react';\n\n/**\n * Creates a constant value over the lifecycle of a component.\n *\n * Even if `useMemo` is provided an empty array as its final argument, it doesn't offer\n * a guarantee that it won't re-run for performance reasons later on. By using `useConstant`\n * you can ensure that initialisers don't execute twice or more.\n */\nfunction useConstant(init) {\n    const ref = useRef(null);\n    if (ref.current === null) {\n        ref.current = init();\n    }\n    return ref.current;\n}\n\nexport { useConstant };\n","import { useContext } from 'react';\nimport { isAnimationControls } from '../../animation/utils/is-animation-controls.mjs';\nimport { MotionContext } from '../../context/MotionContext/index.mjs';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { isControllingVariants, isVariantNode } from '../../render/utils/is-controlling-variants.mjs';\nimport { resolveVariantFromProps } from '../../render/utils/resolve-variants.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { resolveMotionValue } from '../../value/utils/resolve-motion-value.mjs';\n\nfunction makeState({ scrapeMotionValuesFromProps, createRenderState, onUpdate, }, props, context, presenceContext) {\n    const state = {\n        latestValues: makeLatestValues(props, context, presenceContext, scrapeMotionValuesFromProps),\n        renderState: createRenderState(),\n    };\n    if (onUpdate) {\n        /**\n         * onMount works without the VisualElement because it could be\n         * called before the VisualElement payload has been hydrated.\n         * (e.g. if someone is using m components <m.circle />)\n         */\n        state.onMount = (instance) => onUpdate({ props, current: instance, ...state });\n        state.onUpdate = (visualElement) => onUpdate(visualElement);\n    }\n    return state;\n}\nconst makeUseVisualState = (config) => (props, isStatic) => {\n    const context = useContext(MotionContext);\n    const presenceContext = useContext(PresenceContext);\n    const make = () => makeState(config, props, context, presenceContext);\n    return isStatic ? make() : useConstant(make);\n};\nfunction makeLatestValues(props, context, presenceContext, scrapeMotionValues) {\n    const values = {};\n    const motionValues = scrapeMotionValues(props, {});\n    for (const key in motionValues) {\n        values[key] = resolveMotionValue(motionValues[key]);\n    }\n    let { initial, animate } = props;\n    const isControllingVariants$1 = isControllingVariants(props);\n    const isVariantNode$1 = isVariantNode(props);\n    if (context &&\n        isVariantNode$1 &&\n        !isControllingVariants$1 &&\n        props.inherit !== false) {\n        if (initial === undefined)\n            initial = context.initial;\n        if (animate === undefined)\n            animate = context.animate;\n    }\n    let isInitialAnimationBlocked = presenceContext\n        ? presenceContext.initial === false\n        : false;\n    isInitialAnimationBlocked = isInitialAnimationBlocked || initial === false;\n    const variantToSet = isInitialAnimationBlocked ? animate : initial;\n    if (variantToSet &&\n        typeof variantToSet !== \"boolean\" &&\n        !isAnimationControls(variantToSet)) {\n        const list = Array.isArray(variantToSet) ? variantToSet : [variantToSet];\n        for (let i = 0; i < list.length; i++) {\n            const resolved = resolveVariantFromProps(props, list[i]);\n            if (resolved) {\n                const { transitionEnd, transition, ...target } = resolved;\n                for (const key in target) {\n                    let valueTarget = target[key];\n                    if (Array.isArray(valueTarget)) {\n                        /**\n                         * Take final keyframe if the initial animation is blocked because\n                         * we want to initialise at the end of that blocked animation.\n                         */\n                        const index = isInitialAnimationBlocked\n                            ? valueTarget.length - 1\n                            : 0;\n                        valueTarget = valueTarget[index];\n                    }\n                    if (valueTarget !== null) {\n                        values[key] = valueTarget;\n                    }\n                }\n                for (const key in transitionEnd) {\n                    values[key] = transitionEnd[key];\n                }\n            }\n        }\n    }\n    return values;\n}\n\nexport { makeUseVisualState };\n","/**\n * Provided a value and a ValueType, returns the value as that value type.\n */\nconst getValueAsType = (value, type) => {\n    return type && typeof value === \"number\"\n        ? type.transform(value)\n        : value;\n};\n\nexport { getValueAsType };\n","import { getValueAsType } from '../../dom/value-types/get-as-type.mjs';\nimport { numberValueTypes } from '../../dom/value-types/number.mjs';\nimport { transformPropOrder } from './keys-transform.mjs';\n\nconst translateAlias = {\n    x: \"translateX\",\n    y: \"translateY\",\n    z: \"translateZ\",\n    transformPerspective: \"perspective\",\n};\nconst numTransforms = transformPropOrder.length;\n/**\n * Build a CSS transform style from individual x/y/scale etc properties.\n *\n * This outputs with a default order of transforms/scales/rotations, this can be customised by\n * providing a transformTemplate function.\n */\nfunction buildTransform(latestValues, transform, transformTemplate) {\n    // The transform string we're going to build into.\n    let transformString = \"\";\n    let transformIsDefault = true;\n    /**\n     * Loop over all possible transforms in order, adding the ones that\n     * are present to the transform string.\n     */\n    for (let i = 0; i < numTransforms; i++) {\n        const key = transformPropOrder[i];\n        const value = latestValues[key];\n        if (value === undefined)\n            continue;\n        let valueIsDefault = true;\n        if (typeof value === \"number\") {\n            valueIsDefault = value === (key.startsWith(\"scale\") ? 1 : 0);\n        }\n        else {\n            valueIsDefault = parseFloat(value) === 0;\n        }\n        if (!valueIsDefault || transformTemplate) {\n            const valueAsType = getValueAsType(value, numberValueTypes[key]);\n            if (!valueIsDefault) {\n                transformIsDefault = false;\n                const transformName = translateAlias[key] || key;\n                transformString += `${transformName}(${valueAsType}) `;\n            }\n            if (transformTemplate) {\n                transform[key] = valueAsType;\n            }\n        }\n    }\n    transformString = transformString.trim();\n    // If we have a custom `transform` template, pass our transform values and\n    // generated transformString to that before returning\n    if (transformTemplate) {\n        transformString = transformTemplate(transform, transformIsDefault ? \"\" : transformString);\n    }\n    else if (transformIsDefault) {\n        transformString = \"none\";\n    }\n    return transformString;\n}\n\nexport { buildTransform };\n","import { isCSSVariableName } from '../../dom/utils/is-css-variable.mjs';\nimport { getValueAsType } from '../../dom/value-types/get-as-type.mjs';\nimport { numberValueTypes } from '../../dom/value-types/number.mjs';\nimport { buildTransform } from './build-transform.mjs';\nimport { transformProps } from './keys-transform.mjs';\n\nfunction buildHTMLStyles(state, latestValues, transformTemplate) {\n    const { style, vars, transformOrigin } = state;\n    // Track whether we encounter any transform or transformOrigin values.\n    let hasTransform = false;\n    let hasTransformOrigin = false;\n    /**\n     * Loop over all our latest animated values and decide whether to handle them\n     * as a style or CSS variable.\n     *\n     * Transforms and transform origins are kept separately for further processing.\n     */\n    for (const key in latestValues) {\n        const value = latestValues[key];\n        if (transformProps.has(key)) {\n            // If this is a transform, flag to enable further transform processing\n            hasTransform = true;\n            continue;\n        }\n        else if (isCSSVariableName(key)) {\n            vars[key] = value;\n            continue;\n        }\n        else {\n            // Convert the value to its default value type, ie 0 -> \"0px\"\n            const valueAsType = getValueAsType(value, numberValueTypes[key]);\n            if (key.startsWith(\"origin\")) {\n                // If this is a transform origin, flag and enable further transform-origin processing\n                hasTransformOrigin = true;\n                transformOrigin[key] =\n                    valueAsType;\n            }\n            else {\n                style[key] = valueAsType;\n            }\n        }\n    }\n    if (!latestValues.transform) {\n        if (hasTransform || transformTemplate) {\n            style.transform = buildTransform(latestValues, state.transform, transformTemplate);\n        }\n        else if (style.transform) {\n            /**\n             * If we have previously created a transform but currently don't have any,\n             * reset transform style to none.\n             */\n            style.transform = \"none\";\n        }\n    }\n    /**\n     * Build a transformOrigin style. Uses the same defaults as the browser for\n     * undefined origins.\n     */\n    if (hasTransformOrigin) {\n        const { originX = \"50%\", originY = \"50%\", originZ = 0, } = transformOrigin;\n        style.transformOrigin = `${originX} ${originY} ${originZ}`;\n    }\n}\n\nexport { buildHTMLStyles };\n","import { px } from '../../../value/types/numbers/units.mjs';\n\nconst dashKeys = {\n    offset: \"stroke-dashoffset\",\n    array: \"stroke-dasharray\",\n};\nconst camelKeys = {\n    offset: \"strokeDashoffset\",\n    array: \"strokeDasharray\",\n};\n/**\n * Build SVG path properties. Uses the path's measured length to convert\n * our custom pathLength, pathSpacing and pathOffset into stroke-dashoffset\n * and stroke-dasharray attributes.\n *\n * This function is mutative to reduce per-frame GC.\n */\nfunction buildSVGPath(attrs, length, spacing = 1, offset = 0, useDashCase = true) {\n    // Normalise path length by setting SVG attribute pathLength to 1\n    attrs.pathLength = 1;\n    // We use dash case when setting attributes directly to the DOM node and camel case\n    // when defining props on a React component.\n    const keys = useDashCase ? dashKeys : camelKeys;\n    // Build the dash offset\n    attrs[keys.offset] = px.transform(-offset);\n    // Build the dash array\n    const pathLength = px.transform(length);\n    const pathSpacing = px.transform(spacing);\n    attrs[keys.array] = `${pathLength} ${pathSpacing}`;\n}\n\nexport { buildSVGPath };\n","import { px } from '../../../value/types/numbers/units.mjs';\n\nfunction calcOrigin(origin, offset, size) {\n    return typeof origin === \"string\"\n        ? origin\n        : px.transform(offset + size * origin);\n}\n/**\n * The SVG transform origin defaults are different to CSS and is less intuitive,\n * so we use the measured dimensions of the SVG to reconcile these.\n */\nfunction calcSVGTransformOrigin(dimensions, originX, originY) {\n    const pxOriginX = calcOrigin(originX, dimensions.x, dimensions.width);\n    const pxOriginY = calcOrigin(originY, dimensions.y, dimensions.height);\n    return `${pxOriginX} ${pxOriginY}`;\n}\n\nexport { calcSVGTransformOrigin };\n","import { buildHTMLStyles } from '../../html/utils/build-styles.mjs';\nimport { buildSVGPath } from './path.mjs';\nimport { calcSVGTransformOrigin } from './transform-origin.mjs';\n\n/**\n * Build SVG visual attrbutes, like cx and style.transform\n */\nfunction buildSVGAttrs(state, { attrX, attrY, attrScale, originX, originY, pathLength, pathSpacing = 1, pathOffset = 0, \n// This is object creation, which we try to avoid per-frame.\n...latest }, isSVGTag, transformTemplate) {\n    buildHTMLStyles(state, latest, transformTemplate);\n    /**\n     * For svg tags we just want to make sure viewBox is animatable and treat all the styles\n     * as normal HTML tags.\n     */\n    if (isSVGTag) {\n        if (state.style.viewBox) {\n            state.attrs.viewBox = state.style.viewBox;\n        }\n        return;\n    }\n    state.attrs = state.style;\n    state.style = {};\n    const { attrs, style, dimensions } = state;\n    /**\n     * However, we apply transforms as CSS transforms. So if we detect a transform we take it from attrs\n     * and copy it into style.\n     */\n    if (attrs.transform) {\n        if (dimensions)\n            style.transform = attrs.transform;\n        delete attrs.transform;\n    }\n    // Parse transformOrigin\n    if (dimensions &&\n        (originX !== undefined || originY !== undefined || style.transform)) {\n        style.transformOrigin = calcSVGTransformOrigin(dimensions, originX !== undefined ? originX : 0.5, originY !== undefined ? originY : 0.5);\n    }\n    // Render attrX/attrY/attrScale as attributes\n    if (attrX !== undefined)\n        attrs.x = attrX;\n    if (attrY !== undefined)\n        attrs.y = attrY;\n    if (attrScale !== undefined)\n        attrs.scale = attrScale;\n    // Build SVG path if one has been defined\n    if (pathLength !== undefined) {\n        buildSVGPath(attrs, pathLength, pathSpacing, pathOffset, false);\n    }\n}\n\nexport { buildSVGAttrs };\n","const createHtmlRenderState = () => ({\n    style: {},\n    transform: {},\n    transformOrigin: {},\n    vars: {},\n});\n\nexport { createHtmlRenderState };\n","const isSVGTag = (tag) => typeof tag === \"string\" && tag.toLowerCase() === \"svg\";\n\nexport { isSVGTag };\n","function renderHTML(element, { style, vars }, styleProp, projection) {\n    Object.assign(element.style, style, projection && projection.getProjectionStyles(styleProp));\n    // Loop over any CSS variables and assign those.\n    for (const key in vars) {\n        element.style.setProperty(key, vars[key]);\n    }\n}\n\nexport { renderHTML };\n","/**\n * A set of attribute names that are always read/written as camel case.\n */\nconst camelCaseAttributes = new Set([\n    \"baseFrequency\",\n    \"diffuseConstant\",\n    \"kernelMatrix\",\n    \"kernelUnitLength\",\n    \"keySplines\",\n    \"keyTimes\",\n    \"limitingConeAngle\",\n    \"markerHeight\",\n    \"markerWidth\",\n    \"numOctaves\",\n    \"targetX\",\n    \"targetY\",\n    \"surfaceScale\",\n    \"specularConstant\",\n    \"specularExponent\",\n    \"stdDeviation\",\n    \"tableValues\",\n    \"viewBox\",\n    \"gradientTransform\",\n    \"pathLength\",\n    \"startOffset\",\n    \"textLength\",\n    \"lengthAdjust\",\n]);\n\nexport { camelCaseAttributes };\n","import { camelToDash } from '../../dom/utils/camel-to-dash.mjs';\nimport { renderHTML } from '../../html/utils/render.mjs';\nimport { camelCaseAttributes } from './camel-case-attrs.mjs';\n\nfunction renderSVG(element, renderState, _styleProp, projection) {\n    renderHTML(element, renderState, undefined, projection);\n    for (const key in renderState.attrs) {\n        element.setAttribute(!camelCaseAttributes.has(key) ? camelToDash(key) : key, renderState.attrs[key]);\n    }\n}\n\nexport { renderSVG };\n","import { scaleCorrectors } from '../../projection/styles/scale-correction.mjs';\nimport { transformProps } from '../../render/html/utils/keys-transform.mjs';\n\nfunction isForcedMotionValue(key, { layout, layoutId }) {\n    return (transformProps.has(key) ||\n        key.startsWith(\"origin\") ||\n        ((layout || layoutId !== undefined) &&\n            (!!scaleCorrectors[key] || key === \"opacity\")));\n}\n\nexport { isForcedMotionValue };\n","import { isForcedMotionValue } from '../../../motion/utils/is-forced-motion-value.mjs';\nimport { isMotionValue } from '../../../value/utils/is-motion-value.mjs';\n\nfunction scrapeMotionValuesFromProps(props, prevProps, visualElement) {\n    var _a;\n    const { style } = props;\n    const newValues = {};\n    for (const key in style) {\n        if (isMotionValue(style[key]) ||\n            (prevProps.style &&\n                isMotionValue(prevProps.style[key])) ||\n            isForcedMotionValue(key, props) ||\n            ((_a = visualElement === null || visualElement === void 0 ? void 0 : visualElement.getValue(key)) === null || _a === void 0 ? void 0 : _a.liveStyle) !== undefined) {\n            newValues[key] = style[key];\n        }\n    }\n    return newValues;\n}\n\nexport { scrapeMotionValuesFromProps };\n","import { isMotionValue } from '../../../value/utils/is-motion-value.mjs';\nimport { transformPropOrder } from '../../html/utils/keys-transform.mjs';\nimport { scrapeMotionValuesFromProps as scrapeMotionValuesFromProps$1 } from '../../html/utils/scrape-motion-values.mjs';\n\nfunction scrapeMotionValuesFromProps(props, prevProps, visualElement) {\n    const newValues = scrapeMotionValuesFromProps$1(props, prevProps, visualElement);\n    for (const key in props) {\n        if (isMotionValue(props[key]) ||\n            isMotionValue(prevProps[key])) {\n            const targetKey = transformPropOrder.indexOf(key) !== -1\n                ? \"attr\" + key.charAt(0).toUpperCase() + key.substring(1)\n                : key;\n            newValues[targetKey] = props[key];\n        }\n    }\n    return newValues;\n}\n\nexport { scrapeMotionValuesFromProps };\n","import { frame } from '../../frameloop/frame.mjs';\nimport { makeUseVisualState } from '../../motion/utils/use-visual-state.mjs';\nimport { transformProps } from '../html/utils/keys-transform.mjs';\nimport { buildSVGAttrs } from './utils/build-attrs.mjs';\nimport { createSvgRenderState } from './utils/create-render-state.mjs';\nimport { isSVGTag } from './utils/is-svg-tag.mjs';\nimport { renderSVG } from './utils/render.mjs';\nimport { scrapeMotionValuesFromProps } from './utils/scrape-motion-values.mjs';\n\nfunction updateSVGDimensions(instance, renderState) {\n    try {\n        renderState.dimensions =\n            typeof instance.getBBox === \"function\"\n                ? instance.getBBox()\n                : instance.getBoundingClientRect();\n    }\n    catch (e) {\n        // Most likely trying to measure an unrendered element under Firefox\n        renderState.dimensions = {\n            x: 0,\n            y: 0,\n            width: 0,\n            height: 0,\n        };\n    }\n}\nconst layoutProps = [\"x\", \"y\", \"width\", \"height\", \"cx\", \"cy\", \"r\"];\nconst svgMotionConfig = {\n    useVisualState: makeUseVisualState({\n        scrapeMotionValuesFromProps: scrapeMotionValuesFromProps,\n        createRenderState: createSvgRenderState,\n        onUpdate: ({ props, prevProps, current, renderState, latestValues, }) => {\n            if (!current)\n                return;\n            let hasTransform = !!props.drag;\n            if (!hasTransform) {\n                for (const key in latestValues) {\n                    if (transformProps.has(key)) {\n                        hasTransform = true;\n                        break;\n                    }\n                }\n            }\n            if (!hasTransform)\n                return;\n            let needsMeasure = !prevProps;\n            if (prevProps) {\n                /**\n                 * Check the layout props for changes, if any are found we need to\n                 * measure the element again.\n                 */\n                for (let i = 0; i < layoutProps.length; i++) {\n                    const key = layoutProps[i];\n                    if (props[key] !==\n                        prevProps[key]) {\n                        needsMeasure = true;\n                    }\n                }\n            }\n            if (!needsMeasure)\n                return;\n            frame.read(() => {\n                updateSVGDimensions(current, renderState);\n                frame.render(() => {\n                    buildSVGAttrs(renderState, latestValues, isSVGTag(current.tagName), props.transformTemplate);\n                    renderSVG(current, renderState);\n                });\n            });\n        },\n    }),\n};\n\nexport { svgMotionConfig };\n","import { createHtmlRenderState } from '../../html/utils/create-render-state.mjs';\n\nconst createSvgRenderState = () => ({\n    ...createHtmlRenderState(),\n    attrs: {},\n});\n\nexport { createSvgRenderState };\n","import { makeUseVisualState } from '../../motion/utils/use-visual-state.mjs';\nimport { scrapeMotionValuesFromProps } from './utils/scrape-motion-values.mjs';\nimport { createHtmlRenderState } from './utils/create-render-state.mjs';\n\nconst htmlMotionConfig = {\n    useVisualState: makeUseVisualState({\n        scrapeMotionValuesFromProps,\n        createRenderState: createHtmlRenderState,\n    }),\n};\n\nexport { htmlMotionConfig };\n","import { useMemo } from 'react';\nimport { isForcedMotionValue } from '../../motion/utils/is-forced-motion-value.mjs';\nimport { isMotionValue } from '../../value/utils/is-motion-value.mjs';\nimport { buildHTMLStyles } from './utils/build-styles.mjs';\nimport { createHtmlRenderState } from './utils/create-render-state.mjs';\n\nfunction copyRawValuesOnly(target, source, props) {\n    for (const key in source) {\n        if (!isMotionValue(source[key]) && !isForcedMotionValue(key, props)) {\n            target[key] = source[key];\n        }\n    }\n}\nfunction useInitialMotionValues({ transformTemplate }, visualState) {\n    return useMemo(() => {\n        const state = createHtmlRenderState();\n        buildHTMLStyles(state, visualState, transformTemplate);\n        return Object.assign({}, state.vars, state.style);\n    }, [visualState]);\n}\nfunction useStyle(props, visualState) {\n    const styleProp = props.style || {};\n    const style = {};\n    /**\n     * Copy non-Motion Values straight into style\n     */\n    copyRawValuesOnly(style, styleProp, props);\n    Object.assign(style, useInitialMotionValues(props, visualState));\n    return style;\n}\nfunction useHTMLProps(props, visualState) {\n    // The `any` isn't ideal but it is the type of createElement props argument\n    const htmlProps = {};\n    const style = useStyle(props, visualState);\n    if (props.drag && props.dragListener !== false) {\n        // Disable the ghost element when a user drags\n        htmlProps.draggable = false;\n        // Disable text selection\n        style.userSelect =\n            style.WebkitUserSelect =\n                style.WebkitTouchCallout =\n                    \"none\";\n        // Disable scrolling on the draggable direction\n        style.touchAction =\n            props.drag === true\n                ? \"none\"\n                : `pan-${props.drag === \"x\" ? \"y\" : \"x\"}`;\n    }\n    if (props.tabIndex === undefined &&\n        (props.onTap || props.onTapStart || props.whileTap)) {\n        htmlProps.tabIndex = 0;\n    }\n    htmlProps.style = style;\n    return htmlProps;\n}\n\nexport { copyRawValuesOnly, useHTMLProps };\n","/**\n * A list of all valid MotionProps.\n *\n * @privateRemarks\n * This doesn't throw if a `MotionProp` name is missing - it should.\n */\nconst validMotionProps = new Set([\n    \"animate\",\n    \"exit\",\n    \"variants\",\n    \"initial\",\n    \"style\",\n    \"values\",\n    \"variants\",\n    \"transition\",\n    \"transformTemplate\",\n    \"custom\",\n    \"inherit\",\n    \"onBeforeLayoutMeasure\",\n    \"onAnimationStart\",\n    \"onAnimationComplete\",\n    \"onUpdate\",\n    \"onDragStart\",\n    \"onDrag\",\n    \"onDragEnd\",\n    \"onMeasureDragConstraints\",\n    \"onDirectionLock\",\n    \"onDragTransitionEnd\",\n    \"_dragX\",\n    \"_dragY\",\n    \"onHoverStart\",\n    \"onHoverEnd\",\n    \"onViewportEnter\",\n    \"onViewportLeave\",\n    \"globalTapTarget\",\n    \"ignoreStrict\",\n    \"viewport\",\n]);\n/**\n * Check whether a prop name is a valid `MotionProp` key.\n *\n * @param key - Name of the property to check\n * @returns `true` is key is a valid `MotionProp`.\n *\n * @public\n */\nfunction isValidMotionProp(key) {\n    return (key.startsWith(\"while\") ||\n        (key.startsWith(\"drag\") && key !== \"draggable\") ||\n        key.startsWith(\"layout\") ||\n        key.startsWith(\"onTap\") ||\n        key.startsWith(\"onPan\") ||\n        key.startsWith(\"onLayout\") ||\n        validMotionProps.has(key));\n}\n\nexport { isValidMotionProp };\n","import { isValidMotionProp } from '../../../motion/utils/valid-prop.mjs';\n\nlet shouldForward = (key) => !isValidMotionProp(key);\nfunction loadExternalIsValidProp(isValidProp) {\n    if (!isValidProp)\n        return;\n    // Explicitly filter our events\n    shouldForward = (key) => key.startsWith(\"on\") ? !isValidMotionProp(key) : isValidProp(key);\n}\n/**\n * Emotion and Styled Components both allow users to pass through arbitrary props to their components\n * to dynamically generate CSS. They both use the `@emotion/is-prop-valid` package to determine which\n * of these should be passed to the underlying DOM node.\n *\n * However, when styling a Motion component `styled(motion.div)`, both packages pass through *all* props\n * as it's seen as an arbitrary component rather than a DOM node. Motion only allows arbitrary props\n * passed through the `custom` prop so it doesn't *need* the payload or computational overhead of\n * `@emotion/is-prop-valid`, however to fix this problem we need to use it.\n *\n * By making it an optionalDependency we can offer this functionality only in the situations where it's\n * actually required.\n */\ntry {\n    /**\n     * We attempt to import this package but require won't be defined in esm environments, in that case\n     * isPropValid will have to be provided via `MotionContext`. In a 6.0.0 this should probably be removed\n     * in favour of explicit injection.\n     */\n    loadExternalIsValidProp(require(\"@emotion/is-prop-valid\").default);\n}\ncatch (_a) {\n    // We don't need to actually do anything here - the fallback is the existing `isPropValid`.\n}\nfunction filterProps(props, isDom, forwardMotionProps) {\n    const filteredProps = {};\n    for (const key in props) {\n        /**\n         * values is considered a valid prop by Emotion, so if it's present\n         * this will be rendered out to the DOM unless explicitly filtered.\n         *\n         * We check the type as it could be used with the `feColorMatrix`\n         * element, which we support.\n         */\n        if (key === \"values\" && typeof props.values === \"object\")\n            continue;\n        if (shouldForward(key) ||\n            (forwardMotionProps === true && isValidMotionProp(key)) ||\n            (!isDom && !isValidMotionProp(key)) ||\n            // If trying to use native HTML drag events, forward drag listeners\n            (props[\"draggable\"] &&\n                key.startsWith(\"onDrag\"))) {\n            filteredProps[key] =\n                props[key];\n        }\n    }\n    return filteredProps;\n}\n\nexport { filterProps, loadExternalIsValidProp };\n","import { useMemo } from 'react';\nimport { copyRawValuesOnly } from '../html/use-props.mjs';\nimport { buildSVGAttrs } from './utils/build-attrs.mjs';\nimport { createSvgRenderState } from './utils/create-render-state.mjs';\nimport { isSVGTag } from './utils/is-svg-tag.mjs';\n\nfunction useSVGProps(props, visualState, _isStatic, Component) {\n    const visualProps = useMemo(() => {\n        const state = createSvgRenderState();\n        buildSVGAttrs(state, visualState, isSVGTag(Component), props.transformTemplate);\n        return {\n            ...state.attrs,\n            style: { ...state.style },\n        };\n    }, [visualState]);\n    if (props.style) {\n        const rawStyles = {};\n        copyRawValuesOnly(rawStyles, props.style, props);\n        visualProps.style = { ...rawStyles, ...visualProps.style };\n    }\n    return visualProps;\n}\n\nexport { useSVGProps };\n","import { Fragment, useMemo, createElement } from 'react';\nimport { useHTMLProps } from '../html/use-props.mjs';\nimport { filterProps } from './utils/filter-props.mjs';\nimport { isSVGComponent } from './utils/is-svg-component.mjs';\nimport { useSVGProps } from '../svg/use-props.mjs';\nimport { isMotionValue } from '../../value/utils/is-motion-value.mjs';\n\nfunction createUseRender(forwardMotionProps = false) {\n    const useRender = (Component, props, ref, { latestValues }, isStatic) => {\n        const useVisualProps = isSVGComponent(Component)\n            ? useSVGProps\n            : useHTMLProps;\n        const visualProps = useVisualProps(props, latestValues, isStatic, Component);\n        const filteredProps = filterProps(props, typeof Component === \"string\", forwardMotionProps);\n        const elementProps = Component !== Fragment\n            ? { ...filteredProps, ...visualProps, ref }\n            : {};\n        /**\n         * If component has been handed a motion value as its child,\n         * memoise its initial value and render that. Subsequent updates\n         * will be handled by the onChange handler\n         */\n        const { children } = props;\n        const renderedChildren = useMemo(() => (isMotionValue(children) ? children.get() : children), [children]);\n        return createElement(Component, {\n            ...elementProps,\n            children: renderedChildren,\n        });\n    };\n    return useRender;\n}\n\nexport { createUseRender };\n","import { createRendererMotionComponent } from '../../motion/index.mjs';\nimport { isSVGComponent } from '../dom/utils/is-svg-component.mjs';\nimport { svgMotionConfig } from '../svg/config-motion.mjs';\nimport { htmlMotionConfig } from '../html/config-motion.mjs';\nimport { createUseRender } from '../dom/use-render.mjs';\n\nfunction createMotionComponentFactory(preloadedFeatures, createVisualElement) {\n    return function createMotionComponent(Component, { forwardMotionProps } = { forwardMotionProps: false }) {\n        const baseConfig = isSVGComponent(Component)\n            ? svgMotionConfig\n            : htmlMotionConfig;\n        const config = {\n            ...baseConfig,\n            preloadedFeatures,\n            useRender: createUseRender(forwardMotionProps),\n            createVisualElement,\n            Component,\n        };\n        return createRendererMotionComponent(config);\n    };\n}\n\nexport { createMotionComponentFactory };\n","// Does this device prefer reduced motion? Returns `null` server-side.\nconst prefersReducedMotion = { current: null };\nconst hasReducedMotionListener = { current: false };\n\nexport { hasReducedMotionListener, prefersReducedMotion };\n","import { color } from '../../../value/types/color/index.mjs';\nimport { complex } from '../../../value/types/complex/index.mjs';\nimport { dimensionValueTypes } from './dimensions.mjs';\nimport { testValueType } from './test.mjs';\n\n/**\n * A list of all ValueTypes\n */\nconst valueTypes = [...dimensionValueTypes, color, complex];\n/**\n * Tests a value against the list of ValueTypes\n */\nconst findValueType = (v) => valueTypes.find(testValueType(v));\n\nexport { findValueType };\n","const visualElementStore = new WeakMap();\n\nexport { visualElementStore };\n","import { time } from '../frameloop/sync-time.mjs';\nimport { featureDefinitions } from '../motion/features/definitions.mjs';\nimport { createBox } from '../projection/geometry/models.mjs';\nimport { isNumericalString } from '../utils/is-numerical-string.mjs';\nimport { isZeroValueString } from '../utils/is-zero-value-string.mjs';\nimport { initPrefersReducedMotion } from '../utils/reduced-motion/index.mjs';\nimport { hasReducedMotionListener, prefersReducedMotion } from '../utils/reduced-motion/state.mjs';\nimport { SubscriptionManager } from '../utils/subscription-manager.mjs';\nimport { warnOnce } from '../utils/warn-once.mjs';\nimport { motionValue } from '../value/index.mjs';\nimport { complex } from '../value/types/complex/index.mjs';\nimport { isMotionValue } from '../value/utils/is-motion-value.mjs';\nimport { getAnimatableNone } from './dom/value-types/animatable-none.mjs';\nimport { findValueType } from './dom/value-types/find.mjs';\nimport { transformProps } from './html/utils/keys-transform.mjs';\nimport { visualElementStore } from './store.mjs';\nimport { isControllingVariants, isVariantNode } from './utils/is-controlling-variants.mjs';\nimport { KeyframeResolver } from './utils/KeyframesResolver.mjs';\nimport { updateMotionValuesFromProps } from './utils/motion-values.mjs';\nimport { resolveVariantFromProps } from './utils/resolve-variants.mjs';\nimport { frame, cancelFrame } from '../frameloop/frame.mjs';\n\nconst propEventHandlers = [\n    \"AnimationStart\",\n    \"AnimationComplete\",\n    \"Update\",\n    \"BeforeLayoutMeasure\",\n    \"LayoutMeasure\",\n    \"LayoutAnimationStart\",\n    \"LayoutAnimationComplete\",\n];\n/**\n * A VisualElement is an imperative abstraction around UI elements such as\n * HTMLElement, SVGElement, Three.Object3D etc.\n */\nclass VisualElement {\n    /**\n     * This method takes React props and returns found MotionValues. For example, HTML\n     * MotionValues will be found within the style prop, whereas for Three.js within attribute arrays.\n     *\n     * This isn't an abstract method as it needs calling in the constructor, but it is\n     * intended to be one.\n     */\n    scrapeMotionValuesFromProps(_props, _prevProps, _visualElement) {\n        return {};\n    }\n    constructor({ parent, props, presenceContext, reducedMotionConfig, blockInitialAnimation, visualState, }, options = {}) {\n        /**\n         * A reference to the current underlying Instance, e.g. a HTMLElement\n         * or Three.Mesh etc.\n         */\n        this.current = null;\n        /**\n         * A set containing references to this VisualElement's children.\n         */\n        this.children = new Set();\n        /**\n         * Determine what role this visual element should take in the variant tree.\n         */\n        this.isVariantNode = false;\n        this.isControllingVariants = false;\n        /**\n         * Decides whether this VisualElement should animate in reduced motion\n         * mode.\n         *\n         * TODO: This is currently set on every individual VisualElement but feels\n         * like it could be set globally.\n         */\n        this.shouldReduceMotion = null;\n        /**\n         * A map of all motion values attached to this visual element. Motion\n         * values are source of truth for any given animated value. A motion\n         * value might be provided externally by the component via props.\n         */\n        this.values = new Map();\n        this.KeyframeResolver = KeyframeResolver;\n        /**\n         * Cleanup functions for active features (hover/tap/exit etc)\n         */\n        this.features = {};\n        /**\n         * A map of every subscription that binds the provided or generated\n         * motion values onChange listeners to this visual element.\n         */\n        this.valueSubscriptions = new Map();\n        /**\n         * A reference to the previously-provided motion values as returned\n         * from scrapeMotionValuesFromProps. We use the keys in here to determine\n         * if any motion values need to be removed after props are updated.\n         */\n        this.prevMotionValues = {};\n        /**\n         * An object containing a SubscriptionManager for each active event.\n         */\n        this.events = {};\n        /**\n         * An object containing an unsubscribe function for each prop event subscription.\n         * For example, every \"Update\" event can have multiple subscribers via\n         * VisualElement.on(), but only one of those can be defined via the onUpdate prop.\n         */\n        this.propEventSubscriptions = {};\n        this.notifyUpdate = () => this.notify(\"Update\", this.latestValues);\n        this.render = () => {\n            if (!this.current)\n                return;\n            this.triggerBuild();\n            this.renderInstance(this.current, this.renderState, this.props.style, this.projection);\n        };\n        this.renderScheduledAt = 0.0;\n        this.scheduleRender = () => {\n            const now = time.now();\n            if (this.renderScheduledAt < now) {\n                this.renderScheduledAt = now;\n                frame.render(this.render, false, true);\n            }\n        };\n        const { latestValues, renderState, onUpdate } = visualState;\n        this.onUpdate = onUpdate;\n        this.latestValues = latestValues;\n        this.baseTarget = { ...latestValues };\n        this.initialValues = props.initial ? { ...latestValues } : {};\n        this.renderState = renderState;\n        this.parent = parent;\n        this.props = props;\n        this.presenceContext = presenceContext;\n        this.depth = parent ? parent.depth + 1 : 0;\n        this.reducedMotionConfig = reducedMotionConfig;\n        this.options = options;\n        this.blockInitialAnimation = Boolean(blockInitialAnimation);\n        this.isControllingVariants = isControllingVariants(props);\n        this.isVariantNode = isVariantNode(props);\n        if (this.isVariantNode) {\n            this.variantChildren = new Set();\n        }\n        this.manuallyAnimateOnMount = Boolean(parent && parent.current);\n        /**\n         * Any motion values that are provided to the element when created\n         * aren't yet bound to the element, as this would technically be impure.\n         * However, we iterate through the motion values and set them to the\n         * initial values for this component.\n         *\n         * TODO: This is impure and we should look at changing this to run on mount.\n         * Doing so will break some tests but this isn't necessarily a breaking change,\n         * more a reflection of the test.\n         */\n        const { willChange, ...initialMotionValues } = this.scrapeMotionValuesFromProps(props, {}, this);\n        for (const key in initialMotionValues) {\n            const value = initialMotionValues[key];\n            if (latestValues[key] !== undefined && isMotionValue(value)) {\n                value.set(latestValues[key], false);\n            }\n        }\n    }\n    mount(instance) {\n        this.current = instance;\n        visualElementStore.set(instance, this);\n        if (this.projection && !this.projection.instance) {\n            this.projection.mount(instance);\n        }\n        if (this.parent && this.isVariantNode && !this.isControllingVariants) {\n            this.removeFromVariantTree = this.parent.addVariantChild(this);\n        }\n        this.values.forEach((value, key) => this.bindToMotionValue(key, value));\n        if (!hasReducedMotionListener.current) {\n            initPrefersReducedMotion();\n        }\n        this.shouldReduceMotion =\n            this.reducedMotionConfig === \"never\"\n                ? false\n                : this.reducedMotionConfig === \"always\"\n                    ? true\n                    : prefersReducedMotion.current;\n        if (process.env.NODE_ENV !== \"production\") {\n            warnOnce(this.shouldReduceMotion !== true, \"You have Reduced Motion enabled on your device. Animations may not appear as expected.\");\n        }\n        if (this.parent)\n            this.parent.children.add(this);\n        this.update(this.props, this.presenceContext);\n    }\n    unmount() {\n        visualElementStore.delete(this.current);\n        this.projection && this.projection.unmount();\n        cancelFrame(this.notifyUpdate);\n        cancelFrame(this.render);\n        this.valueSubscriptions.forEach((remove) => remove());\n        this.valueSubscriptions.clear();\n        this.removeFromVariantTree && this.removeFromVariantTree();\n        this.parent && this.parent.children.delete(this);\n        for (const key in this.events) {\n            this.events[key].clear();\n        }\n        for (const key in this.features) {\n            const feature = this.features[key];\n            if (feature) {\n                feature.unmount();\n                feature.isMounted = false;\n            }\n        }\n        this.current = null;\n    }\n    bindToMotionValue(key, value) {\n        if (this.valueSubscriptions.has(key)) {\n            this.valueSubscriptions.get(key)();\n        }\n        const valueIsTransform = transformProps.has(key);\n        const removeOnChange = value.on(\"change\", (latestValue) => {\n            this.latestValues[key] = latestValue;\n            this.props.onUpdate && frame.preRender(this.notifyUpdate);\n            if (valueIsTransform && this.projection) {\n                this.projection.isTransformDirty = true;\n            }\n        });\n        const removeOnRenderRequest = value.on(\"renderRequest\", this.scheduleRender);\n        let removeSyncCheck;\n        if (window.MotionCheckAppearSync) {\n            removeSyncCheck = window.MotionCheckAppearSync(this, key, value);\n        }\n        this.valueSubscriptions.set(key, () => {\n            removeOnChange();\n            removeOnRenderRequest();\n            if (removeSyncCheck)\n                removeSyncCheck();\n            if (value.owner)\n                value.stop();\n        });\n    }\n    sortNodePosition(other) {\n        /**\n         * If these nodes aren't even of the same type we can't compare their depth.\n         */\n        if (!this.current ||\n            !this.sortInstanceNodePosition ||\n            this.type !== other.type) {\n            return 0;\n        }\n        return this.sortInstanceNodePosition(this.current, other.current);\n    }\n    updateFeatures() {\n        let key = \"animation\";\n        for (key in featureDefinitions) {\n            const featureDefinition = featureDefinitions[key];\n            if (!featureDefinition)\n                continue;\n            const { isEnabled, Feature: FeatureConstructor } = featureDefinition;\n            /**\n             * If this feature is enabled but not active, make a new instance.\n             */\n            if (!this.features[key] &&\n                FeatureConstructor &&\n                isEnabled(this.props)) {\n                this.features[key] = new FeatureConstructor(this);\n            }\n            /**\n             * If we have a feature, mount or update it.\n             */\n            if (this.features[key]) {\n                const feature = this.features[key];\n                if (feature.isMounted) {\n                    feature.update();\n                }\n                else {\n                    feature.mount();\n                    feature.isMounted = true;\n                }\n            }\n        }\n    }\n    triggerBuild() {\n        this.build(this.renderState, this.latestValues, this.props);\n    }\n    /**\n     * Measure the current viewport box with or without transforms.\n     * Only measures axis-aligned boxes, rotate and skew must be manually\n     * removed with a re-render to work.\n     */\n    measureViewportBox() {\n        return this.current\n            ? this.measureInstanceViewportBox(this.current, this.props)\n            : createBox();\n    }\n    getStaticValue(key) {\n        return this.latestValues[key];\n    }\n    setStaticValue(key, value) {\n        this.latestValues[key] = value;\n    }\n    /**\n     * Update the provided props. Ensure any newly-added motion values are\n     * added to our map, old ones removed, and listeners updated.\n     */\n    update(props, presenceContext) {\n        if (props.transformTemplate || this.props.transformTemplate) {\n            this.scheduleRender();\n        }\n        this.prevProps = this.props;\n        this.props = props;\n        this.prevPresenceContext = this.presenceContext;\n        this.presenceContext = presenceContext;\n        /**\n         * Update prop event handlers ie onAnimationStart, onAnimationComplete\n         */\n        for (let i = 0; i < propEventHandlers.length; i++) {\n            const key = propEventHandlers[i];\n            if (this.propEventSubscriptions[key]) {\n                this.propEventSubscriptions[key]();\n                delete this.propEventSubscriptions[key];\n            }\n            const listenerName = (\"on\" + key);\n            const listener = props[listenerName];\n            if (listener) {\n                this.propEventSubscriptions[key] = this.on(key, listener);\n            }\n        }\n        this.prevMotionValues = updateMotionValuesFromProps(this, this.scrapeMotionValuesFromProps(props, this.prevProps, this), this.prevMotionValues);\n        if (this.handleChildMotionValue) {\n            this.handleChildMotionValue();\n        }\n        this.onUpdate && this.onUpdate(this);\n    }\n    getProps() {\n        return this.props;\n    }\n    /**\n     * Returns the variant definition with a given name.\n     */\n    getVariant(name) {\n        return this.props.variants ? this.props.variants[name] : undefined;\n    }\n    /**\n     * Returns the defined default transition on this component.\n     */\n    getDefaultTransition() {\n        return this.props.transition;\n    }\n    getTransformPagePoint() {\n        return this.props.transformPagePoint;\n    }\n    getClosestVariantNode() {\n        return this.isVariantNode\n            ? this\n            : this.parent\n                ? this.parent.getClosestVariantNode()\n                : undefined;\n    }\n    /**\n     * Add a child visual element to our set of children.\n     */\n    addVariantChild(child) {\n        const closestVariantNode = this.getClosestVariantNode();\n        if (closestVariantNode) {\n            closestVariantNode.variantChildren &&\n                closestVariantNode.variantChildren.add(child);\n            return () => closestVariantNode.variantChildren.delete(child);\n        }\n    }\n    /**\n     * Add a motion value and bind it to this visual element.\n     */\n    addValue(key, value) {\n        // Remove existing value if it exists\n        const existingValue = this.values.get(key);\n        if (value !== existingValue) {\n            if (existingValue)\n                this.removeValue(key);\n            this.bindToMotionValue(key, value);\n            this.values.set(key, value);\n            this.latestValues[key] = value.get();\n        }\n    }\n    /**\n     * Remove a motion value and unbind any active subscriptions.\n     */\n    removeValue(key) {\n        this.values.delete(key);\n        const unsubscribe = this.valueSubscriptions.get(key);\n        if (unsubscribe) {\n            unsubscribe();\n            this.valueSubscriptions.delete(key);\n        }\n        delete this.latestValues[key];\n        this.removeValueFromRenderState(key, this.renderState);\n    }\n    /**\n     * Check whether we have a motion value for this key\n     */\n    hasValue(key) {\n        return this.values.has(key);\n    }\n    getValue(key, defaultValue) {\n        if (this.props.values && this.props.values[key]) {\n            return this.props.values[key];\n        }\n        let value = this.values.get(key);\n        if (value === undefined && defaultValue !== undefined) {\n            value = motionValue(defaultValue === null ? undefined : defaultValue, { owner: this });\n            this.addValue(key, value);\n        }\n        return value;\n    }\n    /**\n     * If we're trying to animate to a previously unencountered value,\n     * we need to check for it in our state and as a last resort read it\n     * directly from the instance (which might have performance implications).\n     */\n    readValue(key, target) {\n        var _a;\n        let value = this.latestValues[key] !== undefined || !this.current\n            ? this.latestValues[key]\n            : (_a = this.getBaseTargetFromProps(this.props, key)) !== null && _a !== void 0 ? _a : this.readValueFromInstance(this.current, key, this.options);\n        if (value !== undefined && value !== null) {\n            if (typeof value === \"string\" &&\n                (isNumericalString(value) || isZeroValueString(value))) {\n                // If this is a number read as a string, ie \"0\" or \"200\", convert it to a number\n                value = parseFloat(value);\n            }\n            else if (!findValueType(value) && complex.test(target)) {\n                value = getAnimatableNone(key, target);\n            }\n            this.setBaseTarget(key, isMotionValue(value) ? value.get() : value);\n        }\n        return isMotionValue(value) ? value.get() : value;\n    }\n    /**\n     * Set the base target to later animate back to. This is currently\n     * only hydrated on creation and when we first read a value.\n     */\n    setBaseTarget(key, value) {\n        this.baseTarget[key] = value;\n    }\n    /**\n     * Find the base target for a value thats been removed from all animation\n     * props.\n     */\n    getBaseTarget(key) {\n        var _a;\n        const { initial } = this.props;\n        let valueFromInitial;\n        if (typeof initial === \"string\" || typeof initial === \"object\") {\n            const variant = resolveVariantFromProps(this.props, initial, (_a = this.presenceContext) === null || _a === void 0 ? void 0 : _a.custom);\n            if (variant) {\n                valueFromInitial = variant[key];\n            }\n        }\n        /**\n         * If this value still exists in the current initial variant, read that.\n         */\n        if (initial && valueFromInitial !== undefined) {\n            return valueFromInitial;\n        }\n        /**\n         * Alternatively, if this VisualElement config has defined a getBaseTarget\n         * so we can read the value from an alternative source, try that.\n         */\n        const target = this.getBaseTargetFromProps(this.props, key);\n        if (target !== undefined && !isMotionValue(target))\n            return target;\n        /**\n         * If the value was initially defined on initial, but it doesn't any more,\n         * return undefined. Otherwise return the value as initially read from the DOM.\n         */\n        return this.initialValues[key] !== undefined &&\n            valueFromInitial === undefined\n            ? undefined\n            : this.baseTarget[key];\n    }\n    on(eventName, callback) {\n        if (!this.events[eventName]) {\n            this.events[eventName] = new SubscriptionManager();\n        }\n        return this.events[eventName].add(callback);\n    }\n    notify(eventName, ...args) {\n        if (this.events[eventName]) {\n            this.events[eventName].notify(...args);\n        }\n    }\n}\n\nexport { VisualElement };\n","import { isBrowser } from '../is-browser.mjs';\nimport { hasReducedMotionListener, prefersReducedMotion } from './state.mjs';\n\nfunction initPrefersReducedMotion() {\n    hasReducedMotionListener.current = true;\n    if (!isBrowser)\n        return;\n    if (window.matchMedia) {\n        const motionMediaQuery = window.matchMedia(\"(prefers-reduced-motion)\");\n        const setReducedMotionPreferences = () => (prefersReducedMotion.current = motionMediaQuery.matches);\n        motionMediaQuery.addListener(setReducedMotionPreferences);\n        setReducedMotionPreferences();\n    }\n    else {\n        prefersReducedMotion.current = false;\n    }\n}\n\nexport { initPrefersReducedMotion };\n","import { warnOnce } from '../../utils/warn-once.mjs';\nimport { motionValue } from '../../value/index.mjs';\nimport { isMotionValue } from '../../value/utils/is-motion-value.mjs';\n\nfunction updateMotionValuesFromProps(element, next, prev) {\n    for (const key in next) {\n        const nextValue = next[key];\n        const prevValue = prev[key];\n        if (isMotionValue(nextValue)) {\n            /**\n             * If this is a motion value found in props or style, we want to add it\n             * to our visual element's motion value map.\n             */\n            element.addValue(key, nextValue);\n            /**\n             * Check the version of the incoming motion value with this version\n             * and warn against mismatches.\n             */\n            if (process.env.NODE_ENV === \"development\") {\n                warnOnce(nextValue.version === \"11.18.2\", `Attempting to mix Motion versions ${nextValue.version} with 11.18.2 may not work as expected.`);\n            }\n        }\n        else if (isMotionValue(prevValue)) {\n            /**\n             * If we're swapping from a motion value to a static value,\n             * create a new motion value from that\n             */\n            element.addValue(key, motionValue(nextValue, { owner: element }));\n        }\n        else if (prevValue !== nextValue) {\n            /**\n             * If this is a flat value that has changed, update the motion value\n             * or create one if it doesn't exist. We only want to do this if we're\n             * not handling the value with our animation state.\n             */\n            if (element.hasValue(key)) {\n                const existingValue = element.getValue(key);\n                if (existingValue.liveStyle === true) {\n                    existingValue.jump(nextValue);\n                }\n                else if (!existingValue.hasAnimated) {\n                    existingValue.set(nextValue);\n                }\n            }\n            else {\n                const latestValue = element.getStaticValue(key);\n                element.addValue(key, motionValue(latestValue !== undefined ? latestValue : nextValue, { owner: element }));\n            }\n        }\n    }\n    // Handle removed values\n    for (const key in prev) {\n        if (next[key] === undefined)\n            element.removeValue(key);\n    }\n    return next;\n}\n\nexport { updateMotionValuesFromProps };\n","import { VisualElement } from '../VisualElement.mjs';\nimport { DOMKeyframesResolver } from './DOMKeyframesResolver.mjs';\nimport { isMotionValue } from '../../value/utils/is-motion-value.mjs';\n\nclass DOMVisualElement extends VisualElement {\n    constructor() {\n        super(...arguments);\n        this.KeyframeResolver = DOMKeyframesResolver;\n    }\n    sortInstanceNodePosition(a, b) {\n        /**\n         * compareDocumentPosition returns a bitmask, by using the bitwise &\n         * we're returning true if 2 in that bitmask is set to true. 2 is set\n         * to true if b preceeds a.\n         */\n        return a.compareDocumentPosition(b) & 2 ? 1 : -1;\n    }\n    getBaseTargetFromProps(props, key) {\n        return props.style\n            ? props.style[key]\n            : undefined;\n    }\n    removeValueFromRenderState(key, { vars, style }) {\n        delete vars[key];\n        delete style[key];\n    }\n    handleChildMotionValue() {\n        if (this.childSubscription) {\n            this.childSubscription();\n            delete this.childSubscription;\n        }\n        const { children } = this.props;\n        if (isMotionValue(children)) {\n            this.childSubscription = children.on(\"change\", (latest) => {\n                if (this.current) {\n                    this.current.textContent = `${latest}`;\n                }\n            });\n        }\n    }\n}\n\nexport { DOMVisualElement };\n","import { measureViewportBox } from '../../projection/utils/measure.mjs';\nimport { DOMVisualElement } from '../dom/DOMVisualElement.mjs';\nimport { isCSSVariableName } from '../dom/utils/is-css-variable.mjs';\nimport { getDefaultValueType } from '../dom/value-types/defaults.mjs';\nimport { buildHTMLStyles } from './utils/build-styles.mjs';\nimport { transformProps } from './utils/keys-transform.mjs';\nimport { renderHTML } from './utils/render.mjs';\nimport { scrapeMotionValuesFromProps } from './utils/scrape-motion-values.mjs';\n\nfunction getComputedStyle(element) {\n    return window.getComputedStyle(element);\n}\nclass HTMLVisualElement extends DOMVisualElement {\n    constructor() {\n        super(...arguments);\n        this.type = \"html\";\n        this.renderInstance = renderHTML;\n    }\n    readValueFromInstance(instance, key) {\n        if (transformProps.has(key)) {\n            const defaultType = getDefaultValueType(key);\n            return defaultType ? defaultType.default || 0 : 0;\n        }\n        else {\n            const computedStyle = getComputedStyle(instance);\n            const value = (isCSSVariableName(key)\n                ? computedStyle.getPropertyValue(key)\n                : computedStyle[key]) || 0;\n            return typeof value === \"string\" ? value.trim() : value;\n        }\n    }\n    measureInstanceViewportBox(instance, { transformPagePoint }) {\n        return measureViewportBox(instance, transformPagePoint);\n    }\n    build(renderState, latestValues, props) {\n        buildHTMLStyles(renderState, latestValues, props.transformTemplate);\n    }\n    scrapeMotionValuesFromProps(props, prevProps, visualElement) {\n        return scrapeMotionValuesFromProps(props, prevProps, visualElement);\n    }\n}\n\nexport { HTMLVisualElement, getComputedStyle };\n","import { createBox } from '../../projection/geometry/models.mjs';\nimport { DOMVisualElement } from '../dom/DOMVisualElement.mjs';\nimport { camelToDash } from '../dom/utils/camel-to-dash.mjs';\nimport { getDefaultValueType } from '../dom/value-types/defaults.mjs';\nimport { transformProps } from '../html/utils/keys-transform.mjs';\nimport { buildSVGAttrs } from './utils/build-attrs.mjs';\nimport { camelCaseAttributes } from './utils/camel-case-attrs.mjs';\nimport { isSVGTag } from './utils/is-svg-tag.mjs';\nimport { renderSVG } from './utils/render.mjs';\nimport { scrapeMotionValuesFromProps } from './utils/scrape-motion-values.mjs';\n\nclass SVGVisualElement extends DOMVisualElement {\n    constructor() {\n        super(...arguments);\n        this.type = \"svg\";\n        this.isSVGTag = false;\n        this.measureInstanceViewportBox = createBox;\n    }\n    getBaseTargetFromProps(props, key) {\n        return props[key];\n    }\n    readValueFromInstance(instance, key) {\n        if (transformProps.has(key)) {\n            const defaultType = getDefaultValueType(key);\n            return defaultType ? defaultType.default || 0 : 0;\n        }\n        key = !camelCaseAttributes.has(key) ? camelToDash(key) : key;\n        return instance.getAttribute(key);\n    }\n    scrapeMotionValuesFromProps(props, prevProps, visualElement) {\n        return scrapeMotionValuesFromProps(props, prevProps, visualElement);\n    }\n    build(renderState, latestValues, props) {\n        buildSVGAttrs(renderState, latestValues, this.isSVGTag, props.transformTemplate);\n    }\n    renderInstance(instance, renderState, styleProp, projection) {\n        renderSVG(instance, renderState, styleProp, projection);\n    }\n    mount(instance) {\n        this.isSVGTag = isSVGTag(instance.tagName);\n        super.mount(instance);\n    }\n}\n\nexport { SVGVisualElement };\n","import { Fragment } from 'react';\nimport { HTMLVisualElement } from '../html/HTMLVisualElement.mjs';\nimport { SVGVisualElement } from '../svg/SVGVisualElement.mjs';\nimport { isSVGComponent } from './utils/is-svg-component.mjs';\n\nconst createDomVisualElement = (Component, options) => {\n    return isSVGComponent(Component)\n        ? new SVGVisualElement(options)\n        : new HTMLVisualElement(options, {\n            allowProjection: Component !== Fragment,\n        });\n};\n\nexport { createDomVisualElement };\n","import { createDOMMotionComponentProxy } from '../create-proxy.mjs';\nimport { createMotionComponent } from './create.mjs';\n\nconst motion = /*@__PURE__*/ createDOMMotionComponentProxy(createMotionComponent);\n\nexport { motion };\n","import { animations } from '../../../motion/features/animations.mjs';\nimport { drag } from '../../../motion/features/drag.mjs';\nimport { gestureAnimations } from '../../../motion/features/gestures.mjs';\nimport { layout } from '../../../motion/features/layout.mjs';\nimport { createMotionComponentFactory } from '../create-factory.mjs';\nimport { createDomVisualElement } from '../../dom/create-visual-element.mjs';\n\nconst createMotionComponent = /*@__PURE__*/ createMotionComponentFactory({\n    ...animations,\n    ...gestureAnimations,\n    ...drag,\n    ...layout,\n}, createDomVisualElement);\n\nexport { createMotionComponent };\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { useId, useRef, useContext, useInsertionEffect } from 'react';\nimport { MotionConfigContext } from '../../context/MotionConfigContext.mjs';\n\n/**\n * Measurement functionality has to be within a separate component\n * to leverage snapshot lifecycle.\n */\nclass PopChildMeasure extends React.Component {\n    getSnapshotBeforeUpdate(prevProps) {\n        const element = this.props.childRef.current;\n        if (element && prevProps.isPresent && !this.props.isPresent) {\n            const size = this.props.sizeRef.current;\n            size.height = element.offsetHeight || 0;\n            size.width = element.offsetWidth || 0;\n            size.top = element.offsetTop;\n            size.left = element.offsetLeft;\n        }\n        return null;\n    }\n    /**\n     * Required with getSnapshotBeforeUpdate to stop React complaining.\n     */\n    componentDidUpdate() { }\n    render() {\n        return this.props.children;\n    }\n}\nfunction PopChild({ children, isPresent }) {\n    const id = useId();\n    const ref = useRef(null);\n    const size = useRef({\n        width: 0,\n        height: 0,\n        top: 0,\n        left: 0,\n    });\n    const { nonce } = useContext(MotionConfigContext);\n    /**\n     * We create and inject a style block so we can apply this explicit\n     * sizing in a non-destructive manner by just deleting the style block.\n     *\n     * We can't apply size via render as the measurement happens\n     * in getSnapshotBeforeUpdate (post-render), likewise if we apply the\n     * styles directly on the DOM node, we might be overwriting\n     * styles set via the style prop.\n     */\n    useInsertionEffect(() => {\n        const { width, height, top, left } = size.current;\n        if (isPresent || !ref.current || !width || !height)\n            return;\n        ref.current.dataset.motionPopId = id;\n        const style = document.createElement(\"style\");\n        if (nonce)\n            style.nonce = nonce;\n        document.head.appendChild(style);\n        if (style.sheet) {\n            style.sheet.insertRule(`\n          [data-motion-pop-id=\"${id}\"] {\n            position: absolute !important;\n            width: ${width}px !important;\n            height: ${height}px !important;\n            top: ${top}px !important;\n            left: ${left}px !important;\n          }\n        `);\n        }\n        return () => {\n            document.head.removeChild(style);\n        };\n    }, [isPresent]);\n    return (jsx(PopChildMeasure, { isPresent: isPresent, childRef: ref, sizeRef: size, children: React.cloneElement(children, { ref }) }));\n}\n\nexport { PopChild };\n","\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { useId, useCallback, useMemo } from 'react';\nimport { PresenceContext } from '../../context/PresenceContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { PopChild } from './PopChild.mjs';\n\nconst PresenceChild = ({ children, initial, isPresent, onExitComplete, custom, presenceAffectsLayout, mode, }) => {\n    const presenceChildren = useConstant(newChildrenMap);\n    const id = useId();\n    const memoizedOnExitComplete = useCallback((childId) => {\n        presenceChildren.set(childId, true);\n        for (const isComplete of presenceChildren.values()) {\n            if (!isComplete)\n                return; // can stop searching when any is incomplete\n        }\n        onExitComplete && onExitComplete();\n    }, [presenceChildren, onExitComplete]);\n    const context = useMemo(() => ({\n        id,\n        initial,\n        isPresent,\n        custom,\n        onExitComplete: memoizedOnExitComplete,\n        register: (childId) => {\n            presenceChildren.set(childId, false);\n            return () => presenceChildren.delete(childId);\n        },\n    }), \n    /**\n     * If the presence of a child affects the layout of the components around it,\n     * we want to make a new context value to ensure they get re-rendered\n     * so they can detect that layout change.\n     */\n    presenceAffectsLayout\n        ? [Math.random(), memoizedOnExitComplete]\n        : [isPresent, memoizedOnExitComplete]);\n    useMemo(() => {\n        presenceChildren.forEach((_, key) => presenceChildren.set(key, false));\n    }, [isPresent]);\n    /**\n     * If there's no `motion` components to fire exit animations, we want to remove this\n     * component immediately.\n     */\n    React.useEffect(() => {\n        !isPresent &&\n            !presenceChildren.size &&\n            onExitComplete &&\n            onExitComplete();\n    }, [isPresent]);\n    if (mode === \"popLayout\") {\n        children = jsx(PopChild, { isPresent: isPresent, children: children });\n    }\n    return (jsx(PresenceContext.Provider, { value: context, children: children }));\n};\nfunction newChildrenMap() {\n    return new Map();\n}\n\nexport { PresenceChild };\n","import { Children, isValidElement } from 'react';\n\nconst getChildKey = (child) => child.key || \"\";\nfunction onlyElements(children) {\n    const filtered = [];\n    // We use forEach here instead of map as map mutates the component key by preprending `.$`\n    Children.forEach(children, (child) => {\n        if (isValidElement(child))\n            filtered.push(child);\n    });\n    return filtered;\n}\n\nexport { getChildKey, onlyElements };\n","\"use client\";\nimport { jsx, Fragment } from 'react/jsx-runtime';\nimport { useMemo, useRef, useState, useContext } from 'react';\nimport { LayoutGroupContext } from '../../context/LayoutGroupContext.mjs';\nimport { useConstant } from '../../utils/use-constant.mjs';\nimport { PresenceChild } from './PresenceChild.mjs';\nimport { usePresence } from './use-presence.mjs';\nimport { onlyElements, getChildKey } from './utils.mjs';\nimport { useIsomorphicLayoutEffect } from '../../utils/use-isomorphic-effect.mjs';\n\n/**\n * `AnimatePresence` enables the animation of components that have been removed from the tree.\n *\n * When adding/removing more than a single child, every child **must** be given a unique `key` prop.\n *\n * Any `motion` components that have an `exit` property defined will animate out when removed from\n * the tree.\n *\n * ```jsx\n * import { motion, AnimatePresence } from 'framer-motion'\n *\n * export const Items = ({ items }) => (\n *   <AnimatePresence>\n *     {items.map(item => (\n *       <motion.div\n *         key={item.id}\n *         initial={{ opacity: 0 }}\n *         animate={{ opacity: 1 }}\n *         exit={{ opacity: 0 }}\n *       />\n *     ))}\n *   </AnimatePresence>\n * )\n * ```\n *\n * You can sequence exit animations throughout a tree using variants.\n *\n * If a child contains multiple `motion` components with `exit` props, it will only unmount the child\n * once all `motion` components have finished animating out. Likewise, any components using\n * `usePresence` all need to call `safeToRemove`.\n *\n * @public\n */\nconst AnimatePresence = ({ children, custom, initial = true, onExitComplete, presenceAffectsLayout = true, mode = \"sync\", propagate = false, }) => {\n    const [isParentPresent, safeToRemove] = usePresence(propagate);\n    /**\n     * Filter any children that aren't ReactElements. We can only track components\n     * between renders with a props.key.\n     */\n    const presentChildren = useMemo(() => onlyElements(children), [children]);\n    /**\n     * Track the keys of the currently rendered children. This is used to\n     * determine which children are exiting.\n     */\n    const presentKeys = propagate && !isParentPresent ? [] : presentChildren.map(getChildKey);\n    /**\n     * If `initial={false}` we only want to pass this to components in the first render.\n     */\n    const isInitialRender = useRef(true);\n    /**\n     * A ref containing the currently present children. When all exit animations\n     * are complete, we use this to re-render the component with the latest children\n     * *committed* rather than the latest children *rendered*.\n     */\n    const pendingPresentChildren = useRef(presentChildren);\n    /**\n     * Track which exiting children have finished animating out.\n     */\n    const exitComplete = useConstant(() => new Map());\n    /**\n     * Save children to render as React state. To ensure this component is concurrent-safe,\n     * we check for exiting children via an effect.\n     */\n    const [diffedChildren, setDiffedChildren] = useState(presentChildren);\n    const [renderedChildren, setRenderedChildren] = useState(presentChildren);\n    useIsomorphicLayoutEffect(() => {\n        isInitialRender.current = false;\n        pendingPresentChildren.current = presentChildren;\n        /**\n         * Update complete status of exiting children.\n         */\n        for (let i = 0; i < renderedChildren.length; i++) {\n            const key = getChildKey(renderedChildren[i]);\n            if (!presentKeys.includes(key)) {\n                if (exitComplete.get(key) !== true) {\n                    exitComplete.set(key, false);\n                }\n            }\n            else {\n                exitComplete.delete(key);\n            }\n        }\n    }, [renderedChildren, presentKeys.length, presentKeys.join(\"-\")]);\n    const exitingChildren = [];\n    if (presentChildren !== diffedChildren) {\n        let nextChildren = [...presentChildren];\n        /**\n         * Loop through all the currently rendered components and decide which\n         * are exiting.\n         */\n        for (let i = 0; i < renderedChildren.length; i++) {\n            const child = renderedChildren[i];\n            const key = getChildKey(child);\n            if (!presentKeys.includes(key)) {\n                nextChildren.splice(i, 0, child);\n                exitingChildren.push(child);\n            }\n        }\n        /**\n         * If we're in \"wait\" mode, and we have exiting children, we want to\n         * only render these until they've all exited.\n         */\n        if (mode === \"wait\" && exitingChildren.length) {\n            nextChildren = exitingChildren;\n        }\n        setRenderedChildren(onlyElements(nextChildren));\n        setDiffedChildren(presentChildren);\n        /**\n         * Early return to ensure once we've set state with the latest diffed\n         * children, we can immediately re-render.\n         */\n        return;\n    }\n    if (process.env.NODE_ENV !== \"production\" &&\n        mode === \"wait\" &&\n        renderedChildren.length > 1) {\n        console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to \"wait\". This will lead to odd visual behaviour.`);\n    }\n    /**\n     * If we've been provided a forceRender function by the LayoutGroupContext,\n     * we can use it to force a re-render amongst all surrounding components once\n     * all components have finished animating out.\n     */\n    const { forceRender } = useContext(LayoutGroupContext);\n    return (jsx(Fragment, { children: renderedChildren.map((child) => {\n            const key = getChildKey(child);\n            const isPresent = propagate && !isParentPresent\n                ? false\n                : presentChildren === renderedChildren ||\n                    presentKeys.includes(key);\n            const onExit = () => {\n                if (exitComplete.has(key)) {\n                    exitComplete.set(key, true);\n                }\n                else {\n                    return;\n                }\n                let isEveryExitComplete = true;\n                exitComplete.forEach((isExitComplete) => {\n                    if (!isExitComplete)\n                        isEveryExitComplete = false;\n                });\n                if (isEveryExitComplete) {\n                    forceRender === null || forceRender === void 0 ? void 0 : forceRender();\n                    setRenderedChildren(pendingPresentChildren.current);\n                    propagate && (safeToRemove === null || safeToRemove === void 0 ? void 0 : safeToRemove());\n                    onExitComplete && onExitComplete();\n                }\n            };\n            return (jsx(PresenceChild, { isPresent: isPresent, initial: !isInitialRender.current || initial\n                    ? undefined\n                    : false, custom: isPresent ? undefined : custom, presenceAffectsLayout: presenceAffectsLayout, mode: mode, onExitComplete: isPresent ? undefined : onExit, children: child }, key));\n        }) }));\n};\n\nexport { AnimatePresence };\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nconst toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, \"$1-$2\").toLowerCase();\nconst mergeClasses = (...classes) => classes.filter((className, index, array) => {\n  return Boolean(className) && array.indexOf(className) === index;\n}).join(\" \");\n\nexport { mergeClasses, toKebabCase };\n//# sourceMappingURL=utils.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nvar defaultAttributes = {\n  xmlns: \"http://www.w3.org/2000/svg\",\n  width: 24,\n  height: 24,\n  viewBox: \"0 0 24 24\",\n  fill: \"none\",\n  stroke: \"currentColor\",\n  strokeWidth: 2,\n  strokeLinecap: \"round\",\n  strokeLinejoin: \"round\"\n};\n\nexport { defaultAttributes as default };\n//# sourceMappingURL=defaultAttributes.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport defaultAttributes from './defaultAttributes.js';\nimport { mergeClasses } from './shared/src/utils.js';\n\nconst Icon = forwardRef(\n  ({\n    color = \"currentColor\",\n    size = 24,\n    strokeWidth = 2,\n    absoluteStrokeWidth,\n    className = \"\",\n    children,\n    iconNode,\n    ...rest\n  }, ref) => {\n    return createElement(\n      \"svg\",\n      {\n        ref,\n        ...defaultAttributes,\n        width: size,\n        height: size,\n        stroke: color,\n        strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,\n        className: mergeClasses(\"lucide\", className),\n        ...rest\n      },\n      [\n        ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n        ...Array.isArray(children) ? children : [children]\n      ]\n    );\n  }\n);\n\nexport { Icon as default };\n//# sourceMappingURL=Icon.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport { mergeClasses, toKebabCase } from './shared/src/utils.js';\nimport Icon from './Icon.js';\n\nconst createLucideIcon = (iconName, iconNode) => {\n  const Component = forwardRef(\n    ({ className, ...props }, ref) => createElement(Icon, {\n      ref,\n      iconNode,\n      className: mergeClasses(`lucide-${toKebabCase(iconName)}`, className),\n      ...props\n    })\n  );\n  Component.displayName = `${iconName}`;\n  return Component;\n};\n\nexport { createLucideIcon as default };\n//# sourceMappingURL=createLucideIcon.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst ChevronDown = createLucideIcon(\"ChevronDown\", [\n  [\"path\", { d: \"m6 9 6 6 6-6\", key: \"qrunsl\" }]\n]);\n\nexport { ChevronDown as default };\n//# sourceMappingURL=chevron-down.js.map\n","import { jsx as e, jsxs as g } from \"react/jsx-runtime\";\nimport { createContext as A, useState as y, useContext as D } from \"react\";\nimport { motion as b, AnimatePresence as E } from \"framer-motion\";\nimport { ChevronDown as K } from \"lucide-react\";\nimport { cn as o } from \"../../utilities/functions.es.js\";\nconst C = A({}), N = () => D(C), l = ({ size: t = \"md\", children: a, className: s }) => /* @__PURE__ */ e(C.Provider, { value: { size: t }, children: /* @__PURE__ */ e(\"div\", { className: o(\"flex flex-col bg-background-primary p-2\", s), children: a }) });\nl.displayName = \"Menu\";\nconst M = ({\n  heading: t,\n  arrow: a = !1,\n  showArrowOnHover: s = !1,\n  // Prop to toggle hover-based arrow display\n  open: r = !0,\n  onClick: i,\n  children: c,\n  className: m\n}) => {\n  const [n, x] = y(r), [v, u] = y(!1), { size: p } = N(), d = \"text-text-primary bg-transparent cursor-pointer flex justify-between items-center gap-1\", k = {\n    sm: \"text-xs\",\n    md: \"text-sm\"\n  }[p ?? \"md\"], w = {\n    sm: \"size-4\",\n    md: \"size-5\"\n  }[p ?? \"md\"], h = () => {\n    x(!n), i && i(!n);\n  }, S = {\n    open: { rotate: 180 },\n    closed: { rotate: 0 }\n  }, L = {\n    open: { height: \"auto\", opacity: 1 },\n    closed: { height: 0, opacity: 0 }\n  }, V = {\n    visible: { opacity: 1 },\n    hidden: { opacity: 0 }\n  }, j = () => s ? n || v ? \"visible\" : \"hidden\" : \"visible\";\n  return /* @__PURE__ */ g(\"div\", { children: [\n    !!t && /* @__PURE__ */ g(\n      \"div\",\n      {\n        role: \"button\",\n        tabIndex: 0,\n        onClick: h,\n        onKeyDown: (f) => {\n          (f.key === \"Enter\" || f.key === \" \") && h();\n        },\n        onMouseEnter: () => s && u(!0),\n        onMouseLeave: () => s && u(!1),\n        className: o(\n          d,\n          k,\n          t ? \"p-1\" : \"p-0\",\n          m\n        ),\n        \"aria-expanded\": n,\n        children: [\n          /* @__PURE__ */ e(\"span\", { className: \"text-text-tertiary\", children: t }),\n          a && /* @__PURE__ */ e(\n            b.span,\n            {\n              className: \"flex items-center text-border-strong\",\n              initial: \"hidden\",\n              animate: j(),\n              exit: \"hidden\",\n              variants: V,\n              transition: { duration: 0.15 },\n              children: /* @__PURE__ */ e(\n                b.span,\n                {\n                  className: \"inline-flex p-1\",\n                  variants: S,\n                  animate: n ? \"open\" : \"closed\",\n                  transition: { duration: 0.15 },\n                  children: /* @__PURE__ */ e(\n                    K,\n                    {\n                      className: o(\"shrink-0\", w)\n                    }\n                  )\n                }\n              )\n            }\n          )\n        ]\n      }\n    ),\n    /* @__PURE__ */ e(E, { initial: !1, children: n && /* @__PURE__ */ e(\n      b.ul,\n      {\n        role: \"menu\",\n        variants: L,\n        initial: \"closed\",\n        animate: \"open\",\n        exit: \"closed\",\n        transition: { duration: 0.3, ease: \"easeInOut\" },\n        className: \"overflow flex gap-0.5 flex-col m-0 bg-white rounded p-0\",\n        children: c\n      }\n    ) })\n  ] });\n};\nM.displayName = \"Menu.List\";\nconst z = ({\n  disabled: t = !1,\n  active: a,\n  onClick: s,\n  children: r,\n  className: i\n}) => {\n  const { size: c } = N(), m = \"flex p-1 gap-1 items-center bg-transparent border-none rounded text-text-secondary cursor-pointer m-0\", n = {\n    sm: \"[&>svg]:size-4 [&>svg]:m-1 [&>*:not(svg)]:mx-1 [&>*:not(svg)]:my-0.5 text-sm\",\n    md: \"[&>svg]:size-5 [&>svg]:m-1.5 [&>*:not(svg)]:m-1 text-base\"\n  }[c ?? \"md\"];\n  return /* @__PURE__ */ e(\n    \"li\",\n    {\n      role: \"menuitem\",\n      tabIndex: 0,\n      onClick: s,\n      onKeyDown: (d) => {\n        (d.key === \"Enter\" || d.key === \" \") && s?.();\n      },\n      className: o(\n        m,\n        n,\n        \"hover:bg-background-secondary hover:text-text-primary\",\n        t ? \"text-text-disabled hover:text-text-disabled cursor-not-allowed hover:bg-transparent\" : \"\",\n        a ? \"text-icon-primary [&>svg]:text-icon-interactive bg-background-secondary\" : \"\",\n        \"transition-colors duration-300 ease-in-out\",\n        i\n      ),\n      children: r\n    }\n  );\n};\nz.displayName = \"Menu.Item\";\nconst I = ({\n  variant: t = \"solid\",\n  className: a\n}) => {\n  const s = {\n    solid: \"border-solid\",\n    dashed: \"border-dashed\",\n    dotted: \"border-dotted\",\n    double: \"border-double\",\n    hidden: \"border-hidden\",\n    none: \"border-none\"\n  }[t];\n  return /* @__PURE__ */ e(\"li\", { className: \"m-0 p-0 list-none\", role: \"separator\", \"aria-hidden\": \"true\", children: /* @__PURE__ */ e(\n    \"hr\",\n    {\n      className: o(\n        \"w-full border-0 border-t border-border-subtle\",\n        s,\n        a\n      )\n    }\n  ) });\n};\nI.displayName = \"Menu.Separator\";\nl.List = M;\nl.Item = z;\nl.Separator = I;\nexport {\n  l as Menu,\n  z as MenuItem,\n  M as MenuList,\n  I as MenuSeparator,\n  l as default\n};\n//# sourceMappingURL=menu-item.es.js.map\n","import { jsx as s, jsxs as V } from \"react/jsx-runtime\";\nimport l, { createContext as h, useState as j, cloneElement as M, isValidElement as g, Fragment as U, useContext as q } from \"react\";\nimport { useFloating as z, offset as B, flip as G, shift as H, autoUpdate as J, useClick as K, useDismiss as Q, useRole as X, useInteractions as Y, useTransitionStyles as Z, FloatingPortal as _ } from \"@floating-ui/react\";\nimport { cn as u, callAll as w } from \"../../utilities/functions.es.js\";\nimport { Menu as c } from \"../menu-item/menu-item.es.js\";\nconst y = h({}), C = () => q(y), a = ({\n  placement: e = \"bottom\",\n  offset: o = 10,\n  boundary: n = \"clippingAncestors\",\n  children: t,\n  className: m\n}) => {\n  const [f, i] = j(!1), { refs: p, floatingStyles: S, context: d } = z({\n    open: f,\n    onOpenChange: i,\n    placement: e,\n    strategy: \"fixed\",\n    middleware: [\n      B(o),\n      G({ boundary: n }),\n      H({ boundary: n })\n    ],\n    whileElementsMounted: J\n  }), I = K(d), E = Q(d), F = X(d, { role: \"menu\" }), { getReferenceProps: R, getFloatingProps: L } = Y([\n    I,\n    E,\n    F\n  ]), { isMounted: T, styles: W } = Z(d, {\n    duration: 150,\n    initial: { opacity: 0, scale: 0.95 },\n    open: { opacity: 1, scale: 1 },\n    close: { opacity: 0, scale: 0.95 }\n  }), A = () => i((r) => !r), O = () => i(!1);\n  return /* @__PURE__ */ s(\n    y.Provider,\n    {\n      value: {\n        refs: p,\n        handleClose: O,\n        isMounted: T,\n        styles: W,\n        floatingStyles: S,\n        getFloatingProps: L\n      },\n      children: /* @__PURE__ */ V(\"div\", { className: u(\"relative inline-block\", m), children: [\n        l.Children.map(t, (r) => l.isValidElement(r) && r?.type?.displayName === \"DropdownMenu.Trigger\" ? M(r, {\n          ref: p.setReference,\n          onClick: A,\n          ...R()\n        }) : null),\n        l.Children.toArray(t).filter(\n          (r) => l.isValidElement(r) && [\n            \"DropdownMenu.Portal\",\n            \"DropdownMenu.ContentWrapper\"\n          ].includes(\n            r.type.displayName || \"\"\n          )\n        ).map((r) => r)\n      ] })\n    }\n  );\n};\na.displayName = \"DropdownMenu\";\nconst D = ({\n  children: e,\n  className: o\n}) => {\n  const { refs: n, floatingStyles: t, getFloatingProps: m, isMounted: f, styles: i } = C();\n  return f && /* @__PURE__ */ s(\n    \"div\",\n    {\n      ref: n.setFloating,\n      className: o,\n      style: {\n        ...t,\n        ...i\n      },\n      ...m(),\n      children: l.Children.map(e, (p) => p?.type?.displayName === \"DropdownMenu.Content\" ? p : null)\n    }\n  );\n};\nD.displayName = \"DropdownMenu.ContentWrapper\";\nconst N = ({\n  children: e,\n  root: o,\n  id: n\n}) => /* @__PURE__ */ s(_, { id: n, root: o, children: e });\nN.displayName = \"DropdownMenu.Portal\";\nconst x = l.forwardRef(({ children: e, className: o, ...n }, t) => g(e) ? l.cloneElement(e, {\n  className: u(o, e.props.className),\n  ref: t,\n  ...n\n}) : /* @__PURE__ */ s(\n  \"div\",\n  {\n    ref: t,\n    className: u(\"cursor-pointer\", o),\n    role: \"button\",\n    tabIndex: 0,\n    ...n,\n    children: e\n  }\n));\nx.displayName = \"DropdownMenu.Trigger\";\nconst P = ({\n  children: e,\n  className: o,\n  ...n\n}) => /* @__PURE__ */ s(\n  \"div\",\n  {\n    className: u(\n      \"border border-solid border-border-subtle rounded-md shadow-lg overflow-hidden\",\n      o\n    ),\n    children: /* @__PURE__ */ s(c, { ...n, children: e })\n  }\n);\nP.displayName = \"DropdownMenu.Content\";\nconst b = (e) => /* @__PURE__ */ s(c.List, { ...e });\nb.displayName = \"DropdownMenu.List\";\nconst k = ({\n  children: e,\n  as: o = c.Item,\n  ...n\n}) => {\n  const { handleClose: t } = C();\n  return e ? o === U && g(e) ? M(e, {\n    onClick: w(\n      e.props?.onClick,\n      t\n    )\n  }) : /* @__PURE__ */ s(\n    o,\n    {\n      ...n,\n      className: u(\"px-2\", n.className),\n      onClick: w(n.onClick, t),\n      children: e\n    }\n  ) : null;\n};\nk.displayName = \"DropdownMenu.Item\";\nconst v = (e) => /* @__PURE__ */ s(c.Separator, { ...e });\nv.displayName = \"DropdownMenu.Separator\";\na.Trigger = x;\na.Content = P;\na.List = b;\na.Item = k;\na.Separator = v;\na.Portal = N;\na.ContentWrapper = D;\nexport {\n  a as DropdownMenu,\n  P as DropdownMenuContent,\n  D as DropdownMenuContentWrapper,\n  k as DropdownMenuItem,\n  b as DropdownMenuList,\n  N as DropdownMenuPortal,\n  v as DropdownMenuSeparator,\n  x as DropdownMenuTrigger,\n  a as default\n};\n//# sourceMappingURL=dropdown-menu.es.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst X = createLucideIcon(\"X\", [\n  [\"path\", { d: \"M18 6 6 18\", key: \"1bl5f8\" }],\n  [\"path\", { d: \"m6 6 12 12\", key: \"d8bk6v\" }]\n]);\n\nexport { X as default };\n//# sourceMappingURL=x.js.map\n","import { jsxs as i, jsx as e } from \"react/jsx-runtime\";\nimport { forwardRef as C } from \"react\";\nimport { cn as d } from \"../../utilities/functions.es.js\";\nimport { X as N } from \"lucide-react\";\nconst j = C(\n  ({\n    label: r = \"\",\n    size: s = \"sm\",\n    // xxs, xs, sm, md, lg\n    className: c = \"\",\n    type: u = \"pill\",\n    // pill, rounded\n    variant: a = \"neutral\",\n    // neutral, red, yellow, green, blue, inverse\n    icon: l = null,\n    disabled: b = !1,\n    onClose: x = () => {\n    },\n    closable: p = !1,\n    onMouseDown: m = () => {\n    },\n    disableHover: v = !1\n  }, y) => {\n    const h = \"font-medium border-badge-border-gray flex items-center justify-center border border-solid box-border max-w-full transition-colors duration-150 ease-in-out\", f = {\n      xxs: \"py-0.5 px-0.5 text-xs h-4\",\n      xs: \"py-0.5 px-1 text-xs h-5\",\n      sm: \"py-1 px-1.5 text-xs h-6\",\n      md: \"py-1 px-1.5 text-sm h-7\",\n      lg: \"py-1 px-1.5 text-base h-8\"\n    }, k = {\n      pill: \"rounded-full\",\n      rounded: \"rounded\"\n    }, w = {\n      neutral: \"hover:bg-badge-hover-gray\",\n      red: \"hover:bg-badge-hover-red\",\n      yellow: \"hover:bg-badge-hover-yellow\",\n      green: \"hover:bg-badge-hover-green\",\n      blue: \"hover:bg-badge-hover-sky\",\n      inverse: \"hover:bg-badge-hover-inverse\",\n      disabled: \"hover:bg-badge-hover-disabled\"\n    }, t = {\n      neutral: \"bg-badge-background-gray text-badge-color-gray border-badge-border-gray\",\n      red: \"bg-badge-background-red text-badge-color-red border-badge-border-red\",\n      yellow: \"bg-badge-background-yellow text-badge-color-yellow border-badge-border-yellow\",\n      green: \"bg-badge-background-green text-badge-color-green border-badge-border-green\",\n      blue: \"bg-badge-background-sky text-badge-color-sky border-badge-border-sky\",\n      inverse: \"bg-background-inverse text-text-inverse border-background-inverse\",\n      disabled: \"bg-badge-background-disabled text-badge-color-disabled border-badge-border-disabled disabled cursor-not-allowed\"\n    };\n    let o = \"\", n = \"group relative justify-center flex items-center cursor-pointer\";\n    const g = {\n      xxs: \"[&>svg]:size-3\",\n      xs: \"[&>svg]:size-3\",\n      sm: \"[&>svg]:size-3\",\n      md: \"[&>svg]:size-4\",\n      lg: \"[&>svg]:size-5\"\n    };\n    return b ? (o = t.disabled, n += \" cursor-not-allowed disabled\") : o = t[a], r ? /* @__PURE__ */ i(\n      \"span\",\n      {\n        className: d(\n          h,\n          f[s],\n          k[u],\n          \"gap-0.5\",\n          o,\n          !v && w[a],\n          c\n        ),\n        ref: y,\n        children: [\n          l ? /* @__PURE__ */ e(\n            \"span\",\n            {\n              className: d(\n                \"justify-center flex items-center\",\n                g[s]\n              ),\n              children: l\n            }\n          ) : null,\n          /* @__PURE__ */ e(\"span\", { className: \"px-1 truncate inline-block\", children: r }),\n          p && /* @__PURE__ */ i(\n            \"span\",\n            {\n              className: d(n, g[s]),\n              onMouseDown: m,\n              role: \"button\",\n              tabIndex: 0,\n              ...!b && {\n                onClick: x\n              },\n              children: [\n                /* @__PURE__ */ e(\"span\", { className: \"sr-only\", children: `Remove ${r}` }),\n                /* @__PURE__ */ e(N, {}),\n                /* @__PURE__ */ e(\"span\", { className: \"absolute -inset-1\" })\n              ]\n            }\n          )\n        ]\n      }\n    ) : null;\n  }\n);\nj.displayName = \"Badge\";\nexport {\n  j as default\n};\n//# sourceMappingURL=badge.es.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nconst toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, \"$1-$2\").toLowerCase();\nconst mergeClasses = (...classes) => classes.filter((className, index, array) => {\n  return Boolean(className) && array.indexOf(className) === index;\n}).join(\" \");\n\nexport { mergeClasses, toKebabCase };\n//# sourceMappingURL=utils.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nvar defaultAttributes = {\n  xmlns: \"http://www.w3.org/2000/svg\",\n  width: 24,\n  height: 24,\n  viewBox: \"0 0 24 24\",\n  fill: \"none\",\n  stroke: \"currentColor\",\n  strokeWidth: 2,\n  strokeLinecap: \"round\",\n  strokeLinejoin: \"round\"\n};\n\nexport { defaultAttributes as default };\n//# sourceMappingURL=defaultAttributes.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport defaultAttributes from './defaultAttributes.js';\nimport { mergeClasses } from './shared/src/utils.js';\n\nconst Icon = forwardRef(\n  ({\n    color = \"currentColor\",\n    size = 24,\n    strokeWidth = 2,\n    absoluteStrokeWidth,\n    className = \"\",\n    children,\n    iconNode,\n    ...rest\n  }, ref) => {\n    return createElement(\n      \"svg\",\n      {\n        ref,\n        ...defaultAttributes,\n        width: size,\n        height: size,\n        stroke: color,\n        strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,\n        className: mergeClasses(\"lucide\", className),\n        ...rest\n      },\n      [\n        ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n        ...Array.isArray(children) ? children : [children]\n      ]\n    );\n  }\n);\n\nexport { Icon as default };\n//# sourceMappingURL=Icon.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport { mergeClasses, toKebabCase } from './shared/src/utils.js';\nimport Icon from './Icon.js';\n\nconst createLucideIcon = (iconName, iconNode) => {\n  const Component = forwardRef(\n    ({ className, ...props }, ref) => createElement(Icon, {\n      ref,\n      iconNode,\n      className: mergeClasses(`lucide-${toKebabCase(iconName)}`, className),\n      ...props\n    })\n  );\n  Component.displayName = `${iconName}`;\n  return Component;\n};\n\nexport { createLucideIcon as default };\n//# sourceMappingURL=createLucideIcon.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst CircleHelp = createLucideIcon(\"CircleHelp\", [\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n  [\"path\", { d: \"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3\", key: \"1u773s\" }],\n  [\"path\", { d: \"M12 17h.01\", key: \"p32p05\" }]\n]);\n\nexport { CircleHelp as default };\n//# sourceMappingURL=circle-help.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst FileText = createLucideIcon(\"FileText\", [\n  [\"path\", { d: \"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z\", key: \"1rqfz7\" }],\n  [\"path\", { d: \"M14 2v4a2 2 0 0 0 2 2h4\", key: \"tnqrlb\" }],\n  [\"path\", { d: \"M10 9H8\", key: \"b1mrlr\" }],\n  [\"path\", { d: \"M16 13H8\", key: \"t4e002\" }],\n  [\"path\", { d: \"M16 17H8\", key: \"z1uh3a\" }]\n]);\n\nexport { FileText as default };\n//# sourceMappingURL=file-text.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Headset = createLucideIcon(\"Headset\", [\n  [\n    \"path\",\n    {\n      d: \"M3 11h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-5Zm0 0a9 9 0 1 1 18 0m0 0v5a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3Z\",\n      key: \"12oyoe\"\n    }\n  ],\n  [\"path\", { d: \"M21 16v2a4 4 0 0 1-4 4h-5\", key: \"1x7m43\" }]\n]);\n\nexport { Headset as default };\n//# sourceMappingURL=headset.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst User = createLucideIcon(\"User\", [\n  [\"path\", { d: \"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2\", key: \"975kel\" }],\n  [\"circle\", { cx: \"12\", cy: \"7\", r: \"4\", key: \"17ys0d\" }]\n]);\n\nexport { User as default };\n//# sourceMappingURL=user.js.map\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"i18n\"];","export const routes = {\n    dashboard: {\n        path: \"dashboard\",\n    },\n    widgets: {\n        path: \"widgets\",\n    },\n    settings: {\n        path: \"settings\",\n    },\n    headerFooterBuilder: { \n        path: \"elementor-hf\" \n    },\n    onboarding: { \n        path: \"onboarding\" \n    }\n}","function _typeof(o) {\n  \"@babel/helpers - typeof\";\n\n  return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) {\n    return typeof o;\n  } : function (o) {\n    return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o;\n  }, _typeof(o);\n}\nexport { _typeof as default };","import _typeof from \"./typeof.js\";\nimport toPrimitive from \"./toPrimitive.js\";\nfunction toPropertyKey(t) {\n  var i = toPrimitive(t, \"string\");\n  return \"symbol\" == _typeof(i) ? i : i + \"\";\n}\nexport { toPropertyKey as default };","import _typeof from \"./typeof.js\";\nfunction toPrimitive(t, r) {\n  if (\"object\" != _typeof(t) || !t) return t;\n  var e = t[Symbol.toPrimitive];\n  if (void 0 !== e) {\n    var i = e.call(t, r || \"default\");\n    if (\"object\" != _typeof(i)) return i;\n    throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n  }\n  return (\"string\" === r ? String : Number)(t);\n}\nexport { toPrimitive as default };","import toPropertyKey from \"./toPropertyKey.js\";\nfunction _defineProperties(e, r) {\n  for (var t = 0; t < r.length; t++) {\n    var o = r[t];\n    o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, toPropertyKey(o.key), o);\n  }\n}\nfunction _createClass(e, r, t) {\n  return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", {\n    writable: !1\n  }), e;\n}\nexport { _createClass as default };","function _getPrototypeOf(t) {\n  return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) {\n    return t.__proto__ || Object.getPrototypeOf(t);\n  }, _getPrototypeOf(t);\n}\nexport { _getPrototypeOf as default };","function _setPrototypeOf(t, e) {\n  return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {\n    return t.__proto__ = e, t;\n  }, _setPrototypeOf(t, e);\n}\nexport { _setPrototypeOf as default };","import toPropertyKey from \"./toPropertyKey.js\";\nfunction _defineProperty(e, r, t) {\n  return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {\n    value: t,\n    enumerable: !0,\n    configurable: !0,\n    writable: !0\n  }) : e[r] = t, e;\n}\nexport { _defineProperty as default };","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"element\"];","import _extends from '@babel/runtime/helpers/esm/extends';\n\n/**\r\n * Actions represent the type of change to a location value.\r\n *\r\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#action\r\n */\nvar Action;\n\n(function (Action) {\n  /**\r\n   * A POP indicates a change to an arbitrary index in the history stack, such\r\n   * as a back or forward navigation. It does not describe the direction of the\r\n   * navigation, only that the current index changed.\r\n   *\r\n   * Note: This is the default action for newly created history objects.\r\n   */\n  Action[\"Pop\"] = \"POP\";\n  /**\r\n   * A PUSH indicates a new entry being added to the history stack, such as when\r\n   * a link is clicked and a new page loads. When this happens, all subsequent\r\n   * entries in the stack are lost.\r\n   */\n\n  Action[\"Push\"] = \"PUSH\";\n  /**\r\n   * A REPLACE indicates the entry at the current index in the history stack\r\n   * being replaced by a new one.\r\n   */\n\n  Action[\"Replace\"] = \"REPLACE\";\n})(Action || (Action = {}));\n\nvar readOnly = process.env.NODE_ENV !== \"production\" ? function (obj) {\n  return Object.freeze(obj);\n} : function (obj) {\n  return obj;\n};\n\nfunction warning(cond, message) {\n  if (!cond) {\n    // eslint-disable-next-line no-console\n    if (typeof console !== 'undefined') console.warn(message);\n\n    try {\n      // Welcome to debugging history!\n      //\n      // This error is thrown as a convenience so you can more easily\n      // find the source for a warning that appears in the console by\n      // enabling \"pause on exceptions\" in your JavaScript debugger.\n      throw new Error(message); // eslint-disable-next-line no-empty\n    } catch (e) {}\n  }\n}\n\nvar BeforeUnloadEventType = 'beforeunload';\nvar HashChangeEventType = 'hashchange';\nvar PopStateEventType = 'popstate';\n/**\r\n * Browser history stores the location in regular URLs. This is the standard for\r\n * most web apps, but it requires some configuration on the server to ensure you\r\n * serve the same app at multiple URLs.\r\n *\r\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createbrowserhistory\r\n */\n\nfunction createBrowserHistory(options) {\n  if (options === void 0) {\n    options = {};\n  }\n\n  var _options = options,\n      _options$window = _options.window,\n      window = _options$window === void 0 ? document.defaultView : _options$window;\n  var globalHistory = window.history;\n\n  function getIndexAndLocation() {\n    var _window$location = window.location,\n        pathname = _window$location.pathname,\n        search = _window$location.search,\n        hash = _window$location.hash;\n    var state = globalHistory.state || {};\n    return [state.idx, readOnly({\n      pathname: pathname,\n      search: search,\n      hash: hash,\n      state: state.usr || null,\n      key: state.key || 'default'\n    })];\n  }\n\n  var blockedPopTx = null;\n\n  function handlePop() {\n    if (blockedPopTx) {\n      blockers.call(blockedPopTx);\n      blockedPopTx = null;\n    } else {\n      var nextAction = Action.Pop;\n\n      var _getIndexAndLocation = getIndexAndLocation(),\n          nextIndex = _getIndexAndLocation[0],\n          nextLocation = _getIndexAndLocation[1];\n\n      if (blockers.length) {\n        if (nextIndex != null) {\n          var delta = index - nextIndex;\n\n          if (delta) {\n            // Revert the POP\n            blockedPopTx = {\n              action: nextAction,\n              location: nextLocation,\n              retry: function retry() {\n                go(delta * -1);\n              }\n            };\n            go(delta);\n          }\n        } else {\n          // Trying to POP to a location with no index. We did not create\n          // this location, so we can't effectively block the navigation.\n          process.env.NODE_ENV !== \"production\" ? warning(false, // TODO: Write up a doc that explains our blocking strategy in\n          // detail and link to it here so people can understand better what\n          // is going on and how to avoid it.\n          \"You are trying to block a POP navigation to a location that was not \" + \"created by the history library. The block will fail silently in \" + \"production, but in general you should do all navigation with the \" + \"history library (instead of using window.history.pushState directly) \" + \"to avoid this situation.\") : void 0;\n        }\n      } else {\n        applyTx(nextAction);\n      }\n    }\n  }\n\n  window.addEventListener(PopStateEventType, handlePop);\n  var action = Action.Pop;\n\n  var _getIndexAndLocation2 = getIndexAndLocation(),\n      index = _getIndexAndLocation2[0],\n      location = _getIndexAndLocation2[1];\n\n  var listeners = createEvents();\n  var blockers = createEvents();\n\n  if (index == null) {\n    index = 0;\n    globalHistory.replaceState(_extends({}, globalHistory.state, {\n      idx: index\n    }), '');\n  }\n\n  function createHref(to) {\n    return typeof to === 'string' ? to : createPath(to);\n  } // state defaults to `null` because `window.history.state` does\n\n\n  function getNextLocation(to, state) {\n    if (state === void 0) {\n      state = null;\n    }\n\n    return readOnly(_extends({\n      pathname: location.pathname,\n      hash: '',\n      search: ''\n    }, typeof to === 'string' ? parsePath(to) : to, {\n      state: state,\n      key: createKey()\n    }));\n  }\n\n  function getHistoryStateAndUrl(nextLocation, index) {\n    return [{\n      usr: nextLocation.state,\n      key: nextLocation.key,\n      idx: index\n    }, createHref(nextLocation)];\n  }\n\n  function allowTx(action, location, retry) {\n    return !blockers.length || (blockers.call({\n      action: action,\n      location: location,\n      retry: retry\n    }), false);\n  }\n\n  function applyTx(nextAction) {\n    action = nextAction;\n\n    var _getIndexAndLocation3 = getIndexAndLocation();\n\n    index = _getIndexAndLocation3[0];\n    location = _getIndexAndLocation3[1];\n    listeners.call({\n      action: action,\n      location: location\n    });\n  }\n\n  function push(to, state) {\n    var nextAction = Action.Push;\n    var nextLocation = getNextLocation(to, state);\n\n    function retry() {\n      push(to, state);\n    }\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      var _getHistoryStateAndUr = getHistoryStateAndUrl(nextLocation, index + 1),\n          historyState = _getHistoryStateAndUr[0],\n          url = _getHistoryStateAndUr[1]; // TODO: Support forced reloading\n      // try...catch because iOS limits us to 100 pushState calls :/\n\n\n      try {\n        globalHistory.pushState(historyState, '', url);\n      } catch (error) {\n        // They are going to lose state here, but there is no real\n        // way to warn them about it since the page will refresh...\n        window.location.assign(url);\n      }\n\n      applyTx(nextAction);\n    }\n  }\n\n  function replace(to, state) {\n    var nextAction = Action.Replace;\n    var nextLocation = getNextLocation(to, state);\n\n    function retry() {\n      replace(to, state);\n    }\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      var _getHistoryStateAndUr2 = getHistoryStateAndUrl(nextLocation, index),\n          historyState = _getHistoryStateAndUr2[0],\n          url = _getHistoryStateAndUr2[1]; // TODO: Support forced reloading\n\n\n      globalHistory.replaceState(historyState, '', url);\n      applyTx(nextAction);\n    }\n  }\n\n  function go(delta) {\n    globalHistory.go(delta);\n  }\n\n  var history = {\n    get action() {\n      return action;\n    },\n\n    get location() {\n      return location;\n    },\n\n    createHref: createHref,\n    push: push,\n    replace: replace,\n    go: go,\n    back: function back() {\n      go(-1);\n    },\n    forward: function forward() {\n      go(1);\n    },\n    listen: function listen(listener) {\n      return listeners.push(listener);\n    },\n    block: function block(blocker) {\n      var unblock = blockers.push(blocker);\n\n      if (blockers.length === 1) {\n        window.addEventListener(BeforeUnloadEventType, promptBeforeUnload);\n      }\n\n      return function () {\n        unblock(); // Remove the beforeunload listener so the document may\n        // still be salvageable in the pagehide event.\n        // See https://html.spec.whatwg.org/#unloading-documents\n\n        if (!blockers.length) {\n          window.removeEventListener(BeforeUnloadEventType, promptBeforeUnload);\n        }\n      };\n    }\n  };\n  return history;\n}\n/**\r\n * Hash history stores the location in window.location.hash. This makes it ideal\r\n * for situations where you don't want to send the location to the server for\r\n * some reason, either because you do cannot configure it or the URL space is\r\n * reserved for something else.\r\n *\r\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createhashhistory\r\n */\n\nfunction createHashHistory(options) {\n  if (options === void 0) {\n    options = {};\n  }\n\n  var _options2 = options,\n      _options2$window = _options2.window,\n      window = _options2$window === void 0 ? document.defaultView : _options2$window;\n  var globalHistory = window.history;\n\n  function getIndexAndLocation() {\n    var _parsePath = parsePath(window.location.hash.substr(1)),\n        _parsePath$pathname = _parsePath.pathname,\n        pathname = _parsePath$pathname === void 0 ? '/' : _parsePath$pathname,\n        _parsePath$search = _parsePath.search,\n        search = _parsePath$search === void 0 ? '' : _parsePath$search,\n        _parsePath$hash = _parsePath.hash,\n        hash = _parsePath$hash === void 0 ? '' : _parsePath$hash;\n\n    var state = globalHistory.state || {};\n    return [state.idx, readOnly({\n      pathname: pathname,\n      search: search,\n      hash: hash,\n      state: state.usr || null,\n      key: state.key || 'default'\n    })];\n  }\n\n  var blockedPopTx = null;\n\n  function handlePop() {\n    if (blockedPopTx) {\n      blockers.call(blockedPopTx);\n      blockedPopTx = null;\n    } else {\n      var nextAction = Action.Pop;\n\n      var _getIndexAndLocation4 = getIndexAndLocation(),\n          nextIndex = _getIndexAndLocation4[0],\n          nextLocation = _getIndexAndLocation4[1];\n\n      if (blockers.length) {\n        if (nextIndex != null) {\n          var delta = index - nextIndex;\n\n          if (delta) {\n            // Revert the POP\n            blockedPopTx = {\n              action: nextAction,\n              location: nextLocation,\n              retry: function retry() {\n                go(delta * -1);\n              }\n            };\n            go(delta);\n          }\n        } else {\n          // Trying to POP to a location with no index. We did not create\n          // this location, so we can't effectively block the navigation.\n          process.env.NODE_ENV !== \"production\" ? warning(false, // TODO: Write up a doc that explains our blocking strategy in\n          // detail and link to it here so people can understand better\n          // what is going on and how to avoid it.\n          \"You are trying to block a POP navigation to a location that was not \" + \"created by the history library. The block will fail silently in \" + \"production, but in general you should do all navigation with the \" + \"history library (instead of using window.history.pushState directly) \" + \"to avoid this situation.\") : void 0;\n        }\n      } else {\n        applyTx(nextAction);\n      }\n    }\n  }\n\n  window.addEventListener(PopStateEventType, handlePop); // popstate does not fire on hashchange in IE 11 and old (trident) Edge\n  // https://developer.mozilla.org/de/docs/Web/API/Window/popstate_event\n\n  window.addEventListener(HashChangeEventType, function () {\n    var _getIndexAndLocation5 = getIndexAndLocation(),\n        nextLocation = _getIndexAndLocation5[1]; // Ignore extraneous hashchange events.\n\n\n    if (createPath(nextLocation) !== createPath(location)) {\n      handlePop();\n    }\n  });\n  var action = Action.Pop;\n\n  var _getIndexAndLocation6 = getIndexAndLocation(),\n      index = _getIndexAndLocation6[0],\n      location = _getIndexAndLocation6[1];\n\n  var listeners = createEvents();\n  var blockers = createEvents();\n\n  if (index == null) {\n    index = 0;\n    globalHistory.replaceState(_extends({}, globalHistory.state, {\n      idx: index\n    }), '');\n  }\n\n  function getBaseHref() {\n    var base = document.querySelector('base');\n    var href = '';\n\n    if (base && base.getAttribute('href')) {\n      var url = window.location.href;\n      var hashIndex = url.indexOf('#');\n      href = hashIndex === -1 ? url : url.slice(0, hashIndex);\n    }\n\n    return href;\n  }\n\n  function createHref(to) {\n    return getBaseHref() + '#' + (typeof to === 'string' ? to : createPath(to));\n  }\n\n  function getNextLocation(to, state) {\n    if (state === void 0) {\n      state = null;\n    }\n\n    return readOnly(_extends({\n      pathname: location.pathname,\n      hash: '',\n      search: ''\n    }, typeof to === 'string' ? parsePath(to) : to, {\n      state: state,\n      key: createKey()\n    }));\n  }\n\n  function getHistoryStateAndUrl(nextLocation, index) {\n    return [{\n      usr: nextLocation.state,\n      key: nextLocation.key,\n      idx: index\n    }, createHref(nextLocation)];\n  }\n\n  function allowTx(action, location, retry) {\n    return !blockers.length || (blockers.call({\n      action: action,\n      location: location,\n      retry: retry\n    }), false);\n  }\n\n  function applyTx(nextAction) {\n    action = nextAction;\n\n    var _getIndexAndLocation7 = getIndexAndLocation();\n\n    index = _getIndexAndLocation7[0];\n    location = _getIndexAndLocation7[1];\n    listeners.call({\n      action: action,\n      location: location\n    });\n  }\n\n  function push(to, state) {\n    var nextAction = Action.Push;\n    var nextLocation = getNextLocation(to, state);\n\n    function retry() {\n      push(to, state);\n    }\n\n    process.env.NODE_ENV !== \"production\" ? warning(nextLocation.pathname.charAt(0) === '/', \"Relative pathnames are not supported in hash history.push(\" + JSON.stringify(to) + \")\") : void 0;\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      var _getHistoryStateAndUr3 = getHistoryStateAndUrl(nextLocation, index + 1),\n          historyState = _getHistoryStateAndUr3[0],\n          url = _getHistoryStateAndUr3[1]; // TODO: Support forced reloading\n      // try...catch because iOS limits us to 100 pushState calls :/\n\n\n      try {\n        globalHistory.pushState(historyState, '', url);\n      } catch (error) {\n        // They are going to lose state here, but there is no real\n        // way to warn them about it since the page will refresh...\n        window.location.assign(url);\n      }\n\n      applyTx(nextAction);\n    }\n  }\n\n  function replace(to, state) {\n    var nextAction = Action.Replace;\n    var nextLocation = getNextLocation(to, state);\n\n    function retry() {\n      replace(to, state);\n    }\n\n    process.env.NODE_ENV !== \"production\" ? warning(nextLocation.pathname.charAt(0) === '/', \"Relative pathnames are not supported in hash history.replace(\" + JSON.stringify(to) + \")\") : void 0;\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      var _getHistoryStateAndUr4 = getHistoryStateAndUrl(nextLocation, index),\n          historyState = _getHistoryStateAndUr4[0],\n          url = _getHistoryStateAndUr4[1]; // TODO: Support forced reloading\n\n\n      globalHistory.replaceState(historyState, '', url);\n      applyTx(nextAction);\n    }\n  }\n\n  function go(delta) {\n    globalHistory.go(delta);\n  }\n\n  var history = {\n    get action() {\n      return action;\n    },\n\n    get location() {\n      return location;\n    },\n\n    createHref: createHref,\n    push: push,\n    replace: replace,\n    go: go,\n    back: function back() {\n      go(-1);\n    },\n    forward: function forward() {\n      go(1);\n    },\n    listen: function listen(listener) {\n      return listeners.push(listener);\n    },\n    block: function block(blocker) {\n      var unblock = blockers.push(blocker);\n\n      if (blockers.length === 1) {\n        window.addEventListener(BeforeUnloadEventType, promptBeforeUnload);\n      }\n\n      return function () {\n        unblock(); // Remove the beforeunload listener so the document may\n        // still be salvageable in the pagehide event.\n        // See https://html.spec.whatwg.org/#unloading-documents\n\n        if (!blockers.length) {\n          window.removeEventListener(BeforeUnloadEventType, promptBeforeUnload);\n        }\n      };\n    }\n  };\n  return history;\n}\n/**\r\n * Memory history stores the current location in memory. It is designed for use\r\n * in stateful non-browser environments like tests and React Native.\r\n *\r\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#creatememoryhistory\r\n */\n\nfunction createMemoryHistory(options) {\n  if (options === void 0) {\n    options = {};\n  }\n\n  var _options3 = options,\n      _options3$initialEntr = _options3.initialEntries,\n      initialEntries = _options3$initialEntr === void 0 ? ['/'] : _options3$initialEntr,\n      initialIndex = _options3.initialIndex;\n  var entries = initialEntries.map(function (entry) {\n    var location = readOnly(_extends({\n      pathname: '/',\n      search: '',\n      hash: '',\n      state: null,\n      key: createKey()\n    }, typeof entry === 'string' ? parsePath(entry) : entry));\n    process.env.NODE_ENV !== \"production\" ? warning(location.pathname.charAt(0) === '/', \"Relative pathnames are not supported in createMemoryHistory({ initialEntries }) (invalid entry: \" + JSON.stringify(entry) + \")\") : void 0;\n    return location;\n  });\n  var index = clamp(initialIndex == null ? entries.length - 1 : initialIndex, 0, entries.length - 1);\n  var action = Action.Pop;\n  var location = entries[index];\n  var listeners = createEvents();\n  var blockers = createEvents();\n\n  function createHref(to) {\n    return typeof to === 'string' ? to : createPath(to);\n  }\n\n  function getNextLocation(to, state) {\n    if (state === void 0) {\n      state = null;\n    }\n\n    return readOnly(_extends({\n      pathname: location.pathname,\n      search: '',\n      hash: ''\n    }, typeof to === 'string' ? parsePath(to) : to, {\n      state: state,\n      key: createKey()\n    }));\n  }\n\n  function allowTx(action, location, retry) {\n    return !blockers.length || (blockers.call({\n      action: action,\n      location: location,\n      retry: retry\n    }), false);\n  }\n\n  function applyTx(nextAction, nextLocation) {\n    action = nextAction;\n    location = nextLocation;\n    listeners.call({\n      action: action,\n      location: location\n    });\n  }\n\n  function push(to, state) {\n    var nextAction = Action.Push;\n    var nextLocation = getNextLocation(to, state);\n\n    function retry() {\n      push(to, state);\n    }\n\n    process.env.NODE_ENV !== \"production\" ? warning(location.pathname.charAt(0) === '/', \"Relative pathnames are not supported in memory history.push(\" + JSON.stringify(to) + \")\") : void 0;\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      index += 1;\n      entries.splice(index, entries.length, nextLocation);\n      applyTx(nextAction, nextLocation);\n    }\n  }\n\n  function replace(to, state) {\n    var nextAction = Action.Replace;\n    var nextLocation = getNextLocation(to, state);\n\n    function retry() {\n      replace(to, state);\n    }\n\n    process.env.NODE_ENV !== \"production\" ? warning(location.pathname.charAt(0) === '/', \"Relative pathnames are not supported in memory history.replace(\" + JSON.stringify(to) + \")\") : void 0;\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      entries[index] = nextLocation;\n      applyTx(nextAction, nextLocation);\n    }\n  }\n\n  function go(delta) {\n    var nextIndex = clamp(index + delta, 0, entries.length - 1);\n    var nextAction = Action.Pop;\n    var nextLocation = entries[nextIndex];\n\n    function retry() {\n      go(delta);\n    }\n\n    if (allowTx(nextAction, nextLocation, retry)) {\n      index = nextIndex;\n      applyTx(nextAction, nextLocation);\n    }\n  }\n\n  var history = {\n    get index() {\n      return index;\n    },\n\n    get action() {\n      return action;\n    },\n\n    get location() {\n      return location;\n    },\n\n    createHref: createHref,\n    push: push,\n    replace: replace,\n    go: go,\n    back: function back() {\n      go(-1);\n    },\n    forward: function forward() {\n      go(1);\n    },\n    listen: function listen(listener) {\n      return listeners.push(listener);\n    },\n    block: function block(blocker) {\n      return blockers.push(blocker);\n    }\n  };\n  return history;\n} ////////////////////////////////////////////////////////////////////////////////\n// UTILS\n////////////////////////////////////////////////////////////////////////////////\n\nfunction clamp(n, lowerBound, upperBound) {\n  return Math.min(Math.max(n, lowerBound), upperBound);\n}\n\nfunction promptBeforeUnload(event) {\n  // Cancel the event.\n  event.preventDefault(); // Chrome (and legacy IE) requires returnValue to be set.\n\n  event.returnValue = '';\n}\n\nfunction createEvents() {\n  var handlers = [];\n  return {\n    get length() {\n      return handlers.length;\n    },\n\n    push: function push(fn) {\n      handlers.push(fn);\n      return function () {\n        handlers = handlers.filter(function (handler) {\n          return handler !== fn;\n        });\n      };\n    },\n    call: function call(arg) {\n      handlers.forEach(function (fn) {\n        return fn && fn(arg);\n      });\n    }\n  };\n}\n\nfunction createKey() {\n  return Math.random().toString(36).substr(2, 8);\n}\n/**\r\n * Creates a string URL path from the given pathname, search, and hash components.\r\n *\r\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createpath\r\n */\n\n\nfunction createPath(_ref) {\n  var _ref$pathname = _ref.pathname,\n      pathname = _ref$pathname === void 0 ? '/' : _ref$pathname,\n      _ref$search = _ref.search,\n      search = _ref$search === void 0 ? '' : _ref$search,\n      _ref$hash = _ref.hash,\n      hash = _ref$hash === void 0 ? '' : _ref$hash;\n  if (search && search !== '?') pathname += search.charAt(0) === '?' ? search : '?' + search;\n  if (hash && hash !== '#') pathname += hash.charAt(0) === '#' ? hash : '#' + hash;\n  return pathname;\n}\n/**\r\n * Parses a string URL path into its separate pathname, search, and hash components.\r\n *\r\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#parsepath\r\n */\n\nfunction parsePath(path) {\n  var parsedPath = {};\n\n  if (path) {\n    var hashIndex = path.indexOf('#');\n\n    if (hashIndex >= 0) {\n      parsedPath.hash = path.substr(hashIndex);\n      path = path.substr(0, hashIndex);\n    }\n\n    var searchIndex = path.indexOf('?');\n\n    if (searchIndex >= 0) {\n      parsedPath.search = path.substr(searchIndex);\n      path = path.substr(0, searchIndex);\n    }\n\n    if (path) {\n      parsedPath.pathname = path;\n    }\n  }\n\n  return parsedPath;\n}\n\nexport { Action, createBrowserHistory, createHashHistory, createMemoryHistory, createPath, parsePath };\n//# sourceMappingURL=index.js.map\n","import qs from \"querystringify\";\nexport function locationToRoute(location) {\n  // location comes from the history package\n  return {\n    path: location.pathname,\n    hash: location.hash,\n    query: qs.parse(location.search),\n  };\n}\n","function _extends() {\n  return _extends = Object.assign ? Object.assign.bind() : function (n) {\n    for (var e = 1; e < arguments.length; e++) {\n      var t = arguments[e];\n      for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);\n    }\n    return n;\n  }, _extends.apply(null, arguments);\n}\nexport { _extends as default };","import { createBrowserHistory } from \"history\";\nimport { locationToRoute } from \"./utils\";\n\nexport const history = createBrowserHistory();\nexport const RouterContext = wp.element.createContext({\n  route: locationToRoute(history.location),\n});\n","import { RouterContext } from \"./context\";\nconst { useContext } = wp.element;\nimport { match } from \"path-to-regexp\";\nlet prev = \"\";\n\nexport function Route({ path, onRoute, children }) {\n  // Extract route from RouterContext\n  const { route } = useContext(RouterContext);\n\n  const checkMatch = match(`${path}`);\n  const matched = checkMatch(`${route.hash.substr(1)}`);\n\n  if (!matched) {\n    return null;\n  }\n\n  if (onRoute) {\n    if (prev !== matched.path) {\n      onRoute();\n    }\n    prev = matched.path;\n  }\n\n  return <div>{wp.element.cloneElement(children, { route: matched })}</div>;\n}\n","const { useContext } = wp.element;\nimport { RouterContext, history } from \"./context\";\nimport classNames from \"classnames\";\nimport { match } from \"path-to-regexp\";\n\nexport function Link(props) {\n  const { to, onClick, children, activeClassName } = props;\n  const { route } = useContext(RouterContext);\n\n  let state = { ...props };\n  delete state.activeClassName;\n\n  const isActive = () => {\n    const checkMatch = match(`${to}`);\n    return checkMatch(`${route.hash.substr(1)}`);\n  };\n\n  const handleClick = (e) => {\n    e.preventDefault();\n    // Dont' navigate if current path.\n    if (route.path === to && ! e.target.classList.contains('uae-user-icon')) {\n      return;\n    }\n    // Trigger onClick prop manually.\n    if (onClick) {\n      onClick(e);\n    }\n\n    if (to === \"elementor-hf\" && uaelSettingsData.header_footer_builder ) {\n      window.location.href = uaelSettingsData.header_footer_builder;\n      return;\n    }\n\n    const { search } = history.location;\n    const expectedPage = \"admin.php?page=uaepro\";\n    const currentHash = window.location.hash;\n\n    // Verify if the current URL is as expected\n    if (!search.includes(expectedPage) || !currentHash.includes(to)) {\n        // Redirect to the expected URL\n        window.location.href = `${uaelSettingsData.uaepro_settings_url}#${to}`;\n        return;\n    }\n\n    if (!to.includes('settings')) {\n      // Remove &tab from the URL.\n      const newSearch = search.replace(/&tab=[^&]*/, '');\n      // Use history API to navigate page.\n      history.push(`${newSearch}#${to}`);\n    } else {\n      const changeSearch = search + '&tab=1';\n\n      if (e.target.classList.contains('uae-user-icon') && window.location.hash.includes('settings')) {\n        window.location.href = `${changeSearch}#${to}`;\n      } else {\n        // Use history API to navigate page.\n        history.push(`${search}#${to}`);\n      }\n    }\n\n  };\n\n  return (\n    <a\n      {...state}\n      className={classNames({ [activeClassName]: isActive() }, props.className)}\n      onClick={handleClick}\n    >\n      {children}\n    </a>\n  );\n}\n","import { Component } from \"@wordpress/element\";\nimport { locationToRoute } from \"./utils\";\nimport { history, RouterContext } from \"./context\";\nimport { Route } from \"./route\";\nimport { Link } from \"./link\";\nimport { match } from \"path-to-regexp\";\n\nclass Router extends Component {\n  constructor(props) {\n    super(props);\n\n    // Convert our routes into an array for easy 404 checking\n    this.routes = Object.keys(props.routes).map(\n      (key) => props.routes[key].path\n    );\n\n    // Listen for path changes from the history API\n    this.unlisten = history.listen(this.handleRouteChange);\n\n    const route = locationToRoute(history.location);\n    const { search } = history.location;\n\n    // Define the initial RouterContext value\n    this.state = {\n      route,\n      defaultRoute: props?.defaultRoute\n        ? `${search}#${props?.defaultRoute}`\n        : `${search}#/`,\n    };\n  }\n\n  componentWillUnmount() {\n    // Stop listening for changes if the Router component unmounts\n    this.unlisten();\n  }\n\n  handleRouteChange = (location) => {\n    localStorage.setItem('selectedItemId', '1');\n    const route = locationToRoute(location?.location);\n    this.setState({ route: route });\n  };\n\n  render() {\n    // Define our variables\n    const { children, NotFound } = this.props;\n    const { route, defaultRoute } = this.state;\n\n    if (!route.hash) {\n      history.push(defaultRoute);\n      return <div></div>;\n    }\n\n    let matched = false;\n    // match route\n    (this.routes || []).forEach((name) => {\n      const checkMatch = match(route.hash.substr(1));\n      const isMatched = checkMatch(`${route.hash.substr(1)}`);\n      if (!isMatched) {\n        return;\n      }\n      matched = {\n        name,\n        data: isMatched,\n      };\n    });\n\n    const routerContextValue = { route, matched };\n\n    // Check if 404 if no route matched\n    const is404 = !matched;\n\n    return (\n      <RouterContext.Provider value={routerContextValue}>\n        {is404 ? <div>Not found</div> : children}\n      </RouterContext.Provider>\n    );\n  }\n}\nexport { history, RouterContext, Router, Route, Link };\n","function _classCallCheck(a, n) {\n  if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\");\n}\nexport { _classCallCheck as default };","import _typeof from \"./typeof.js\";\nimport assertThisInitialized from \"./assertThisInitialized.js\";\nfunction _possibleConstructorReturn(t, e) {\n  if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e;\n  if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\");\n  return assertThisInitialized(t);\n}\nexport { _possibleConstructorReturn as default };","function _assertThisInitialized(e) {\n  if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n  return e;\n}\nexport { _assertThisInitialized as default };","import setPrototypeOf from \"./setPrototypeOf.js\";\nfunction _inherits(t, e) {\n  if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\");\n  t.prototype = Object.create(e && e.prototype, {\n    constructor: {\n      value: t,\n      writable: !0,\n      configurable: !0\n    }\n  }), Object.defineProperty(t, \"prototype\", {\n    writable: !1\n  }), e && setPrototypeOf(t, e);\n}\nexport { _inherits as default };","/**\n * === Whats New RSS ===\n *\n * Version: 1.1.0\n * Generated on: 17th September, 2025\n * Documentation: https://github.com/brainstormforce/whats-new-rss/blob/master/README.md\n */\n\nimport { useEffect, useRef } from \"react\";\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n    return new (P || (P = Promise))(function (resolve, reject) {\n        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n        function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n        step((generator = generator.apply(thisArg, _arguments || [])).next());\n    });\n};\nconst WhatsNewRSSDefaultArgs = {\n    rssFeedURL: '',\n    selector: '',\n    uniqueKey: '',\n    loaderIcon: `<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" viewBox=\"0 0 100 100\" preserveAspectRatio=\"xMidYMid\">\n\t<circle cx=\"50\" cy=\"50\" fill=\"none\" stroke=\"#9f9f9f\" stroke-width=\"10\" r=\"35\" stroke-dasharray=\"164.93361431346415 56.97787143782138\">\n\t\t<animateTransform attributeName=\"transform\" type=\"rotate\" repeatCount=\"indefinite\" dur=\"1s\" values=\"0 50 50;360 50 50\" keyTimes=\"0;1\"></animateTransform>\n\t</circle>\n\t</svg>`,\n    viewAll: {\n        link: '',\n        label: 'View All',\n    },\n    triggerButton: {\n        label: '',\n        icon: `<svg width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M8.61703 13.1998C8.04294 13.1503 7.46192 13.125 6.875 13.125H6.25C4.17893 13.125 2.5 11.4461 2.5 9.375C2.5 7.30393 4.17893 5.625 6.25 5.625H6.875C7.46192 5.625 8.04294 5.59972 8.61703 5.55018M8.61703 13.1998C8.82774 14.0012 9.1031 14.7764 9.43719 15.5195C9.64341 15.9782 9.48685 16.5273 9.05134 16.7787L8.50441 17.0945C8.04492 17.3598 7.45466 17.1921 7.23201 16.7106C6.70983 15.5811 6.30451 14.3866 6.03155 13.1425M8.61703 13.1998C8.29598 11.9787 8.125 10.6968 8.125 9.375C8.125 8.05316 8.29598 6.77125 8.61703 5.55018M8.61703 13.1998C11.25 13.427 13.737 14.1643 15.9789 15.3124M8.61703 5.55018C11.25 5.323 13.737 4.58569 15.9789 3.43757M15.9789 3.43757C15.8808 3.12162 15.7751 2.80903 15.662 2.5M15.9789 3.43757C16.4247 4.87356 16.7131 6.37885 16.8238 7.93326M15.9789 15.3124C15.8808 15.6284 15.7751 15.941 15.662 16.25M15.9789 15.3124C16.4247 13.8764 16.7131 12.3711 16.8238 10.8167M16.8238 7.93326C17.237 8.2772 17.5 8.79539 17.5 9.375C17.5 9.95461 17.237 10.4728 16.8238 10.8167M16.8238 7.93326C16.8578 8.40942 16.875 8.8902 16.875 9.375C16.875 9.8598 16.8578 10.3406 16.8238 10.8167\" stroke=\"#94A3B8\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n        beforeBtn: '',\n        afterBtn: '',\n        className: '',\n        onClick: () => { },\n    },\n    notification: {\n        setLastPostUnixTime: null,\n        getLastPostUnixTime: null\n    },\n    flyout: {\n        title: \"What's New?\",\n        innerContent: {\n            titleLink: true,\n            additionalClasses: []\n        },\n        excerpt: {\n            wordLimit: 500,\n            moreSymbol: '&hellip;',\n            readMore: {\n                label: 'Read More',\n                className: '',\n            }\n        },\n        className: '',\n        closeOnEsc: true,\n        closeOnOverlayClick: true,\n        closeBtnIcon: `<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M6 18L18 6M6 6L18 18\" stroke=\"#94A3B8\" stroke-width=\"1.5\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n        formatDate: null,\n        onOpen: () => { },\n        onClose: () => { },\n        onReady: () => { },\n    }\n};\nclass WhatsNewRSS {\n    ;\n    /**\n     * Initialize our class.\n     *\n     * @param {ConstructorArgs} args\n     */\n    constructor(args) {\n        this.rssFeedURLs = [];\n        /**\n         * UnixTime stamp of the last seen or read post.\n         */\n        this.lastPostUnixTime = 0;\n        /**\n         * UnixTime stamp of the last seen or read post for multi feeds by feed key.\n         */\n        this.multiLastPostUnixTime = {};\n        /**\n         * Total number of new notification counts.\n         */\n        this.notificationsCount = 0;\n        /**\n         * Notification counts for multi feeds by feed key.\n         */\n        this.multiNotificationCount = {};\n        /**\n         * Check if has new feeds.\n         */\n        this.hasNewFeeds = false;\n        /**\n         * Check if has new feeds in multi feeds mode.\n         */\n        this.multiHasNewFeeds = {};\n        this.validateArgs(args);\n        this.parseDefaults(args);\n        this.setElement();\n        if (!this.getElement()) {\n            console.warn('WNR: Cannot find element with', this.getArgs().selector);\n            return;\n        }\n        this.setID();\n        this.setRSSFeedURLs();\n        WhatsNewRSSCacheUtils.setInstanceID(this.getID());\n        this.RSS_Fetch_Instance = new WhatsNewRSSFetch(this);\n        this.RSS_View_Instance = new WhatsNewRSSView(this);\n        this.setNotificationsCount();\n        this.setTriggers();\n    }\n    /**\n     * Validate the passed arguments in constructor.\n     *\n     * @param {ConstructorArgs} args\n     */\n    validateArgs(args) {\n        [\"rssFeedURL\", \"selector\", \"uniqueKey\"].forEach((requiredArg) => {\n            if (!args[requiredArg]) {\n                throw new Error(`${requiredArg} is a required argument. It cannot be empty or undefined.`);\n            }\n            switch (requiredArg) {\n                case 'rssFeedURL':\n                    const arg = args[requiredArg];\n                    if (Array.isArray(arg)) {\n                        arg.forEach((rssFeedURL) => {\n                            if (!(rssFeedURL === null || rssFeedURL === void 0 ? void 0 : rssFeedURL.key)) {\n                                throw new Error(`The parameter \"key\" is required for \"${requiredArg}\" parameter in multi-feed mode.`);\n                            }\n                            if (rssFeedURL.key.includes(' ')) {\n                                throw new Error(`The parameter \"key\" cannot have spaces for \"${requiredArg}\" parameter in multi-feed mode. Ref Key: \"${rssFeedURL.key}\"`);\n                            }\n                        });\n                    }\n                    break;\n                default:\n                    break;\n            }\n        });\n    }\n    /**\n     * Parse the arguments passed by the user with the defaults.\n     *\n     * @param {ConstructorArgs} args\n     */\n    parseDefaults(args) {\n        var _a, _b;\n        this.args = Object.assign(Object.assign(Object.assign({}, WhatsNewRSSDefaultArgs), args), { viewAll: Object.assign(Object.assign({}, WhatsNewRSSDefaultArgs.viewAll), args === null || args === void 0 ? void 0 : args.viewAll), triggerButton: Object.assign(Object.assign({}, WhatsNewRSSDefaultArgs.triggerButton), args === null || args === void 0 ? void 0 : args.triggerButton), flyout: Object.assign(Object.assign(Object.assign({}, WhatsNewRSSDefaultArgs.flyout), args === null || args === void 0 ? void 0 : args.flyout), { innerContent: Object.assign(Object.assign({}, WhatsNewRSSDefaultArgs.flyout.innerContent), (_a = args === null || args === void 0 ? void 0 : args.flyout) === null || _a === void 0 ? void 0 : _a.innerContent), excerpt: Object.assign(Object.assign({}, WhatsNewRSSDefaultArgs.flyout.excerpt), (_b = args === null || args === void 0 ? void 0 : args.flyout) === null || _b === void 0 ? void 0 : _b.excerpt) }) });\n    }\n    /**\n     * Returns parsed args.\n     *\n     * @returns {ConstructorArgs}\n     */\n    getArgs() {\n        return this.args;\n    }\n    /**\n     * Sets the HTML element queried using passed selector.\n     */\n    setElement() {\n        this.element = document.querySelector(this.args.selector);\n    }\n    /**\n     * Returns the html element according to the selector.\n     *\n     * @returns {HTMLElement}\n     */\n    getElement() {\n        return this.element;\n    }\n    /**\n     * Creates unique ID for current instance, that can be used by the library elements.\n     */\n    setID() {\n        const data = [this.getArgs().selector, this.getArgs().uniqueKey];\n        const rssFeedURL = this.getArgs().rssFeedURL;\n        if (Array.isArray(rssFeedURL)) {\n            rssFeedURL.forEach((_rssFeedURL) => {\n                data.push(_rssFeedURL.key);\n            });\n        }\n        else {\n            data.push(rssFeedURL);\n        }\n        this.ID = btoa(data.join('-')).slice(-12).replace(/=/g, '') + '-' + this.getArgs().uniqueKey;\n    }\n    /**\n     * Whether or not multiple feed urls is provided or not.\n     *\n     * @returns {boolean}\n     */\n    isMultiFeedRSS() {\n        return 'string' !== typeof this.getArgs().rssFeedURL;\n    }\n    setRSSFeedURLs() {\n        const rssFeedURL = this.getArgs().rssFeedURL;\n        if (!this.isMultiFeedRSS()) {\n            this.rssFeedURLs.push({\n                key: null,\n                label: '',\n                url: rssFeedURL.toString(),\n            });\n        }\n        else {\n            if (Array.isArray(rssFeedURL)) {\n                rssFeedURL.forEach(_item => {\n                    this.rssFeedURLs.push(_item);\n                });\n            }\n        }\n    }\n    getRSSFeedURLs() {\n        return this.rssFeedURLs;\n    }\n    /**\n     * Returns the current instance unique ID.\n     *\n     * @returns {string}\n     */\n    getID() {\n        return this.ID;\n    }\n    /**\n     * Checks and counts new notification for the notification badge.\n     */\n    setNotificationsCount() {\n        return __awaiter(this, void 0, void 0, function* () {\n            yield Promise.all(this.getRSSFeedURLs().map((_a) => __awaiter(this, [_a], void 0, function* ({ key }) {\n                let lastPostUnixTime = 0;\n                if (('function' === typeof this.getArgs().notification.getLastPostUnixTime)) {\n                    lastPostUnixTime = yield this.getArgs().notification.getLastPostUnixTime(key, this);\n                }\n                else {\n                    lastPostUnixTime = WhatsNewRSSCacheUtils.getLastPostUnixTime(key);\n                }\n                if (this.isMultiFeedRSS()) {\n                    this.multiLastPostUnixTime[key] = +lastPostUnixTime;\n                }\n                else {\n                    this.lastPostUnixTime = +lastPostUnixTime;\n                }\n            })));\n            yield this.RSS_Fetch_Instance.fetchData()\n                .then((res) => {\n                Object.keys(res).forEach((key) => {\n                    const data = res[key];\n                    if (!data.length) {\n                        return;\n                    }\n                    this.multiNotificationCount[key] = 0;\n                    const currentPostUnixTime = +data[0].date;\n                    const lastPostUnixTime = this.isMultiFeedRSS() ? this.multiLastPostUnixTime[key] : this.lastPostUnixTime;\n                    if (currentPostUnixTime > lastPostUnixTime) {\n                        data.forEach((item) => {\n                            if (item.date > lastPostUnixTime) {\n                                if (this.isMultiFeedRSS()) {\n                                    this.multiNotificationCount[key]++;\n                                    this.multiHasNewFeeds[key] = true;\n                                }\n                                // Keep a record of total notifications even in multi-feed mode.\n                                this.notificationsCount++;\n                                this.hasNewFeeds = true;\n                            }\n                        });\n                        this.RSS_View_Instance.setNotification(this.notificationsCount);\n                    }\n                });\n            })\n                .catch(console.error);\n        });\n    }\n    /**\n     * Returns total number of new notifications.\n     *\n     * @returns {number}\n     */\n    getNotificationsCount() {\n        return this.notificationsCount;\n    }\n    /**\n     * Sets the triggers for the library, eg: close, open, fetch.\n     */\n    setTriggers() {\n        const triggerButton = document.getElementById(this.RSS_View_Instance.getTriggerButtonID());\n        const flyout = document.getElementById(this.RSS_View_Instance.getFlyoutID());\n        const flyoutInner = flyout.querySelector('.whats-new-rss-flyout-inner-content');\n        const flyoutCloseBtn = document.getElementById(this.RSS_View_Instance.getFlyoutCloseBtnID());\n        const multiFeedNav = document.getElementById(this.RSS_View_Instance.getFlyoutMultiFeedNavID());\n        const injectContents = (key) => {\n            /**\n             * Fetch data on flyout open.\n             */\n            this.RSS_Fetch_Instance.fetchData()\n                .then((res) => {\n                flyoutInner.innerHTML = '';\n                const data = res[key];\n                if (!data.length) {\n                    return;\n                }\n                const currentPostUnixTime = +data[0].date;\n                const lastPostUnixTime = this.isMultiFeedRSS() ? this.multiLastPostUnixTime[key] : this.lastPostUnixTime;\n                data.forEach((item) => {\n                    const isNewPost = !!lastPostUnixTime ? item.date > lastPostUnixTime : false;\n                    const contentTitle = this.getArgs().flyout.innerContent.titleLink ?\n                        `<a href=\"${item.postLink}\" target=\"_blank\">\n\t\t\t\t\t\t\t\t<h2>${item.title}</h2>\n\t\t\t\t\t\t\t</a>`\n                        :\n                            `<h2>${item.title}</h2>`;\n                    const innerContent = `\n\t\t\t\t\t\t\t\t<div class=\"rss-content-header\">\n\t\t\t\t\t\t\t\t\t<p>${this.RSS_View_Instance.formatDate(new Date(item.date))}</p>\n\t\t\t\t\t\t\t\t\t${contentTitle}\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t${this.RSS_View_Instance.createExcerpt(item.description, item.postLink, this.getArgs().flyout.excerpt)}\n\t\t\t\t\t\t\t\t${this.RSS_View_Instance.listChildrenPosts(item.children)}\n\t\t\t\t\t\t\t`;\n                    const additionalClasses = this.getArgs().flyout.innerContent.additionalClasses;\n                    if (!!key) {\n                        additionalClasses.push('`inner-content-item-feed-key-${key}`');\n                    }\n                    flyoutInner.innerHTML += this.RSS_View_Instance.innerContentWrapper(innerContent, isNewPost, additionalClasses.join(' '));\n                });\n                if (this.getArgs().viewAll.link) {\n                    // If we have link provided for the view all button then append a view all button at the end of the contents.\n                    flyoutInner.innerHTML += this.RSS_View_Instance.innerContentWrapper(`\n\t\t\t\t\t\t\t<a href=\"${this.getArgs().viewAll.link}\" class=\"button view-all\">${this.getArgs().viewAll.label}</a>\n\t\t\t\t\t\t\t`);\n                }\n                this.RSS_View_Instance.setIsLoading(false);\n                flyout.classList.add('ready');\n                this.getArgs().flyout.onReady(this);\n                /**\n                 * Change focus to flyout on flyout ready.\n                 */\n                flyout.focus();\n                // Set the last latest post date for notification handling.\n                if (!this.isMultiFeedRSS()) {\n                    this.lastPostUnixTime = currentPostUnixTime;\n                    if (this.hasNewFeeds) {\n                        if ('function' === typeof this.getArgs().notification.setLastPostUnixTime) {\n                            this.getArgs().notification.setLastPostUnixTime(currentPostUnixTime, key);\n                        }\n                        else {\n                            WhatsNewRSSCacheUtils.setLastPostUnixTime(currentPostUnixTime, key);\n                        }\n                    }\n                }\n            })\n                .catch(console.error);\n        };\n        /**\n         * Open flyout on trigger button click.\n         * Flyout has three states: `closed | open | ready`\n         */\n        triggerButton.addEventListener(\"click\", (e) => {\n            e.preventDefault();\n            const scrollBarWidth = window.innerWidth - document.documentElement.clientWidth;\n            this.getArgs().triggerButton.onClick(this);\n            this.RSS_View_Instance.setIsLoading(true);\n            flyout.removeAttribute('style');\n            flyout.classList.remove('closed');\n            flyout.classList.add('open');\n            document.body.classList.add('whats-new-rss-is-active');\n            // Fix glitch issue that happens when opening drawers.\n            if (!!scrollBarWidth) {\n                const styleSheet = document.getElementById('whats-new-rss-styles');\n                if (styleSheet === null || styleSheet === void 0 ? void 0 : styleSheet.sheet) {\n                    styleSheet.sheet.insertRule(`.whats-new-rss-is-active { background-color: yellow; padding-right: ${scrollBarWidth}px; }`, styleSheet.sheet.cssRules.length);\n                }\n            }\n            this.getArgs().flyout.onOpen(this);\n            if (!this.isMultiFeedRSS()) {\n                injectContents(null);\n                return;\n            }\n            const navBtns = multiFeedNav.querySelectorAll('button');\n            navBtns.forEach((navBtn) => {\n                this.RSS_View_Instance.setMultiFeedTabNotificationCount(navBtn.dataset.feedKey, this.multiNotificationCount[navBtn.dataset.feedKey]);\n                navBtn.addEventListener('click', (e) => {\n                    e.preventDefault();\n                    const currentFeedKey = navBtn.dataset.feedKey;\n                    this.multiNotificationCount[currentFeedKey] = 0;\n                    this.RSS_Fetch_Instance.fetchData()\n                        .then((res) => {\n                        const currentPostUnixTime = res[currentFeedKey][0].date;\n                        this.multiLastPostUnixTime[currentFeedKey] = currentPostUnixTime;\n                        if (true === this.multiHasNewFeeds[currentFeedKey]) {\n                            if ('function' === typeof this.getArgs().notification.setLastPostUnixTime) {\n                                this.getArgs().notification.setLastPostUnixTime(currentPostUnixTime, currentFeedKey);\n                            }\n                            else {\n                                WhatsNewRSSCacheUtils.setLastPostUnixTime(currentPostUnixTime, currentFeedKey);\n                            }\n                        }\n                        this.multiHasNewFeeds[currentFeedKey] = false;\n                    })\n                        .catch(console.error);\n                    navBtns.forEach(navBtn => {\n                        navBtn.classList.remove('selected');\n                        const feedKey = navBtn.dataset.feedKey;\n                        const innerContentClassName = `.inner-content-item-feed-key-${feedKey}`;\n                        document.querySelectorAll(innerContentClassName).forEach(item => {\n                            if (currentFeedKey !== feedKey) {\n                                item.classList.add('hidden');\n                            }\n                            else {\n                                item.classList.remove('hidden');\n                            }\n                        });\n                    });\n                    navBtn.classList.add('selected');\n                    injectContents(currentFeedKey);\n                });\n            });\n            navBtns[0].click();\n        });\n        /**\n         * Handle events for the closing of the flyout.\n         */\n        const handleFlyoutClose = () => {\n            flyout.classList.add('closed');\n            flyout.classList.remove('open');\n            flyout.classList.remove('ready');\n            document.body.classList.remove('whats-new-rss-is-active');\n            if (this.isMultiFeedRSS()) {\n                this.RSS_View_Instance.setNotification(Object.values(this.multiNotificationCount).filter(Boolean).length);\n            }\n            else {\n                this.hasNewFeeds = false;\n                this.RSS_View_Instance.setNotification(false);\n            }\n            flyoutInner.innerHTML = '';\n            this.getArgs().flyout.onClose(this);\n            /**\n             * Change focus back to trigger button after flyout close.\n             */\n            triggerButton.focus();\n        };\n        if (this.getArgs().flyout.closeOnEsc) {\n            document.addEventListener('keydown', function (e) {\n                if ('Escape' !== e.key)\n                    return;\n                if (!flyout.classList.contains('open'))\n                    return;\n                handleFlyoutClose();\n            });\n        }\n        if (this.getArgs().flyout.closeOnOverlayClick) {\n            flyout.querySelector('.whats-new-rss-flyout-overlay').addEventListener('click', handleFlyoutClose);\n        }\n        flyoutCloseBtn.addEventListener('click', handleFlyoutClose);\n    }\n}\nclass WhatsNewRSSCacheUtils {\n    static setInstanceID(instanceID) {\n        if (!this.instanceID) {\n            this.instanceID = instanceID;\n        }\n    }\n    static prefixer(key, prefixKey = '') {\n        if (!this.instanceID) {\n            throw new Error('Instance ID not set.');\n        }\n        return !!prefixKey ? `${this.keys[key]}-${this.instanceID}-${prefixKey}` : `${this.keys[key]}-${this.instanceID}`;\n    }\n    static _setDataExpiry(prefixKey = '') {\n        const expiryInSeconds = 86400; // Defaults to 24 hours.\n        const now = new Date();\n        const expiry = now.getTime() + (expiryInSeconds * 1000);\n        sessionStorage.setItem(this.prefixer('SESSION_DATA_EXPIRY', prefixKey), JSON.stringify(expiry));\n    }\n    static _isDataExpired(prefixKey = '') {\n        const key = this.prefixer('SESSION_DATA_EXPIRY', prefixKey);\n        const value = window.sessionStorage.getItem(key);\n        if (!value) {\n            return true;\n        }\n        const expiry = JSON.parse(value);\n        const now = new Date();\n        if (now.getTime() > expiry) {\n            window.sessionStorage.removeItem(key);\n            return true;\n        }\n        return false;\n    }\n    static setSessionData(data, prefixKey = '') {\n        this._setDataExpiry(prefixKey);\n        return window.sessionStorage.setItem(this.prefixer('SESSION', prefixKey), data);\n    }\n    static getSessionData(prefixKey = '') {\n        if (!this._isDataExpired(prefixKey)) {\n            return window.sessionStorage.getItem(this.prefixer('SESSION', prefixKey));\n        }\n        return '{}';\n    }\n    static setLastPostUnixTime(unixTime, prefixKey = '') {\n        return window.localStorage.setItem(this.prefixer('LAST_LATEST_POST', prefixKey), unixTime.toString());\n    }\n    static getLastPostUnixTime(prefixKey = '') {\n        return +window.localStorage.getItem(this.prefixer('LAST_LATEST_POST', prefixKey));\n    }\n}\nWhatsNewRSSCacheUtils.keys = {\n    SESSION_DATA_EXPIRY: \"whats-new-cache-expiry\",\n    LAST_LATEST_POST: \"whats-new-last-unixtime\",\n    SESSION: \"whats-new-cache\"\n};\n/**\n * Class for handling the data fetching.\n * It also handles the session caching of the fetched data internally.\n */\nclass WhatsNewRSSFetch {\n    constructor(RSS) {\n        this.data = {};\n        this.RSS = RSS;\n        this.RSS.getRSSFeedURLs().forEach((feed) => {\n            const sessionCache = JSON.parse(WhatsNewRSSCacheUtils.getSessionData(feed.key));\n            if (sessionCache && sessionCache.length) {\n                this.data[feed.key] = sessionCache;\n            }\n        });\n    }\n    fetchData() {\n        return __awaiter(this, void 0, void 0, function* () {\n            if (Object.keys(this.data).length) {\n                return this.data;\n            }\n            const fetchPromises = this.RSS.getRSSFeedURLs().map((feed) => __awaiter(this, void 0, void 0, function* () {\n                this.data[feed.key] = [];\n                const res = yield fetch(feed.url);\n                let data = yield res.text();\n                /**\n                 * There was an issue with the xml content parse\n                 * And during parse we were getting \"<parsererror>\" because of the ‘raquo’ entity.\n                 */\n                data = data.replace(/&raquo;/g, '&amp;raquo;');\n                const parser = new DOMParser();\n                const xmlDoc = parser.parseFromString(data, 'text/xml');\n                const items = xmlDoc.querySelectorAll('item');\n                items.forEach(item => {\n                    var _a;\n                    const title = item.querySelector('title').textContent;\n                    const link = item.querySelector('link').textContent;\n                    const contentEncoded = item.querySelector('content\\\\:encoded, encoded');\n                    const content = contentEncoded ? contentEncoded.textContent : '';\n                    const rssDate = item.querySelector('pubDate').innerHTML;\n                    this.data[feed.key].push({\n                        title: title,\n                        date: !!rssDate ? +new Date(rssDate) : null,\n                        postLink: link,\n                        description: content.replace(/<a\\b((?:(?!target=)[^>])*)>/g, '<a$1 target=\"_blank\">').replace(/<p>\\s*<\\/p>/g, ''),\n                        children: JSON.parse(((_a = item.querySelector('children')) === null || _a === void 0 ? void 0 : _a.innerHTML) || '{}')\n                    });\n                });\n                WhatsNewRSSCacheUtils.setSessionData(JSON.stringify(this.data[feed.key]), feed.key);\n            }));\n            yield Promise.all(fetchPromises);\n            return this.data;\n        });\n    }\n}\n/**\n * The class for handling library trigger button and flyout elements.\n * It also provides some necessary methods that can be used during development.\n */\nclass WhatsNewRSSView {\n    constructor(RSS) {\n        this.RSS = RSS;\n        this.createTriggerButton();\n        this.createFlyOut();\n    }\n    getTriggerButtonID() {\n        return `whats-new-rss-btn-${this.RSS.getID()}`;\n    }\n    getFlyoutID() {\n        return `whats-new-rss-flyout-${this.RSS.getID()}`;\n    }\n    getFlyoutCloseBtnID() {\n        return `whats-new-rss-flyout-close-${this.RSS.getID()}`;\n    }\n    getFlyoutMultiFeedNavID() {\n        return `whats-new-rss-flyout-multi-feed-nav-${this.RSS.getID()}`;\n    }\n    setIsLoading(isLoading = false) {\n        const flyoutWrapper = document.getElementById(this.getFlyoutID());\n        if (isLoading) {\n            flyoutWrapper.classList.add('is-loading');\n        }\n        else {\n            flyoutWrapper.classList.remove('is-loading');\n        }\n    }\n    setNotification(notificationsCount) {\n        const notificationBadge = document.querySelector(`#${this.getTriggerButtonID()} .whats-new-rss-notification-badge`);\n        if (!!notificationsCount) {\n            if (this.RSS.isMultiFeedRSS()) {\n                notificationBadge.innerHTML = '';\n                notificationBadge.classList.add('is-multi-feed');\n            }\n            else {\n                notificationBadge.innerHTML = notificationsCount > 9 ? \"9+\" : notificationsCount.toString();\n            }\n            notificationBadge.classList.remove('hide');\n        }\n        else {\n            notificationBadge.classList.add('hide');\n        }\n    }\n    createTriggerButton() {\n        let button = '';\n        const label = this.RSS.getArgs().triggerButton.label;\n        if (!!label) {\n            button = `\n\t\t\t${this.RSS.getArgs().triggerButton.beforeBtn}\n\t\t\t<a class=\"whats-new-rss-trigger-button has-label\" id=\"${this.getTriggerButtonID()}\">\n\t\t\t\t<div class=\"icon-badge\">\n\t\t\t\t\t${this.RSS.getArgs().triggerButton.icon}\n\t\t\t\t\t<div class=\"whats-new-rss-notification-badge hide\">0</div>\n\t\t\t\t</div>\n\t\t\t\t${label}\n\t\t\t</a>\n\t\t\t${this.RSS.getArgs().triggerButton.afterBtn}\n\t\t\t`;\n        }\n        else {\n            button = `\n\t\t\t${this.RSS.getArgs().triggerButton.beforeBtn}\n\t\t\t<a class=\"whats-new-rss-trigger-button\" id=\"${this.getTriggerButtonID()}\">\n\t\t\t\t${this.RSS.getArgs().triggerButton.icon}\n\t\t\t\t<div class=\"whats-new-rss-notification-badge hide\">0</div>\n\t\t\t</a>\n\t\t\t${this.RSS.getArgs().triggerButton.afterBtn}\n\t\t\t`;\n        }\n        this.RSS.getElement().innerHTML += button;\n    }\n    createFlyOut() {\n        const wrapperClasses = [\n            'whats-new-rss-flyout',\n            'closed',\n        ];\n        if (this.RSS.getArgs().flyout.className) {\n            wrapperClasses.push(this.RSS.getArgs().flyout.className);\n        }\n        let multiFeedNav = [];\n        if (this.RSS.isMultiFeedRSS()) {\n            multiFeedNav.push(`<nav id=\"${this.getFlyoutMultiFeedNavID()}\" class=\"whats-new-rss-multi-feed-nav\">`);\n            this.RSS.getRSSFeedURLs().forEach((feed) => {\n                multiFeedNav.push(`<button type=\"button\" data-feed-key=\"${feed.key}\">\n\t\t\t\t\t\t${feed.label}\n\t\t\t\t\t\t<div class=\"new-notification-count\"></div>\n\t\t\t\t\t</button>\n\t\t\t\t\t`);\n            });\n            multiFeedNav.push('</nav>');\n        }\n        const flyoutWrapper = document.createElement('div');\n        flyoutWrapper.setAttribute('id', this.getFlyoutID());\n        flyoutWrapper.setAttribute('class', wrapperClasses.join(' '));\n        flyoutWrapper.setAttribute('role', 'dialog');\n        flyoutWrapper.setAttribute('style', 'visibility:hidden');\n        flyoutWrapper.innerHTML = `\n\t\t<div class=\"whats-new-rss-flyout-contents\">\n\n\t\t\t<div class=\"whats-new-rss-flyout-inner-header\">\n\n\t\t\t\t<div class=\"whats-new-rss-flyout-inner-header__title-icon-wrapper\">\n\t\t\t\t\t<h3>${this.RSS.getArgs().flyout.title}</h3>\n\n\t\t\t\t\t<span class=\"whats-new-rss-flyout-inner-header__loading-icon\">\n\t\t\t\t\t${this.RSS.getArgs().loaderIcon}\n\t\t\t\t\t</span>\n\t\t\t\t</div>\n\n\t\t\t\t<button type=\"button\" id=\"${this.getFlyoutCloseBtnID()}\">${this.RSS.getArgs().flyout.closeBtnIcon}</button>\n\t\t\t</div>\n\n\t\t\t${multiFeedNav.join('')}\n\n\t\t\t<div class=\"whats-new-rss-flyout-inner-content\">\n\t\t\t\t<div class=\"skeleton-container\">\n\t\t\t\t\t<div class=\"skeleton-row whats-new-rss-flyout-inner-content-item\"></div>\n\t\t\t\t\t<div class=\"skeleton-row whats-new-rss-flyout-inner-content-item\"></div>\n\t\t\t\t\t<div class=\"skeleton-row whats-new-rss-flyout-inner-content-item\"></div>\n\t\t\t\t</div>\n\t\t\t</div>\n\n\t\t</div>\n\n\t\t<div class=\"whats-new-rss-flyout-overlay\"></div>\n\t\t`;\n        document.body.appendChild(flyoutWrapper);\n    }\n    setMultiFeedTabNotificationCount(key, notificationCount = 0) {\n        const tabBtn = document.querySelector(`#${this.getFlyoutMultiFeedNavID()} button[data-feed-key=\"${key}\"]`);\n        if (!tabBtn) {\n            return;\n        }\n        const el = tabBtn.querySelector('.new-notification-count');\n        if (notificationCount) {\n            const _count = notificationCount > 9 ? '9+' : notificationCount;\n            el.innerHTML = _count.toString();\n        }\n        else {\n            el.innerHTML = '';\n        }\n    }\n    innerContentWrapper(content, isNewPost = false, additionalClasses = '') {\n        const classes = ['whats-new-rss-flyout-inner-content-item'];\n        if (isNewPost) {\n            classes.push('rss-new-post');\n        }\n        if (!!additionalClasses) {\n            classes.push(additionalClasses);\n        }\n        return `\n\t\t<div class=\"${classes.join(' ')}\">\n\t\t\t${isNewPost ? '<small class=\"new-post-badge\">New ✨</small>' : ''}\n\t\t\t${content}\n\t\t</div>\n\t\t`;\n    }\n    createExcerpt(content, readMoreLink, options) {\n        const { wordLimit, moreSymbol, readMore } = options;\n        if (!wordLimit) {\n            return content;\n        }\n        const plainText = content.replace(/<[^>]*>/g, '');\n        const words = plainText.split(/\\s+/);\n        let rawExcerpt = words.slice(0, wordLimit).join(' ');\n        if (moreSymbol) {\n            rawExcerpt += moreSymbol;\n        }\n        if (wordLimit > words.length) {\n            return content;\n        }\n        if (!!readMoreLink && !!(readMore === null || readMore === void 0 ? void 0 : readMore.label)) {\n            return `<p>${rawExcerpt} <a href=\"${readMoreLink}\" target=\"_blank\" class=\"${readMore.className}\">${readMore.label}</a></p>`;\n        }\n        return `<p>${rawExcerpt}</p>`;\n    }\n    listChildrenPosts(children) {\n        const _children = Object.values(children);\n        if (!_children.length)\n            return '';\n        const details = document.createElement('details');\n        const summary = document.createElement('summary');\n        const itemsWrapper = document.createElement('div');\n        _children.forEach((child) => {\n            const postContentDoc = new DOMParser().parseFromString(child.post_content, 'text/html');\n            const itemDiv = document.createElement('div');\n            itemDiv.classList.add('sub-version-item');\n            itemDiv.innerHTML = `\n\t\t\t\t<div class=\"sub-version-header\">\n\t\t\t\t\t<h4 class=\"sub-version-title\">${child.post_title}</h4>\n\t\t\t\t\t<span class=\"sub-version-date\">${this.formatDate(new Date(child.post_date))}</span>\n\t\t\t\t</div>\n\t\t\t\t<div class=\"sub-version-content\">${postContentDoc.documentElement.textContent}</div>\n\t\t\t`;\n            itemsWrapper.appendChild(itemDiv);\n        });\n        summary.innerHTML = '<p class=\"text-see-more\">See More</p><p class=\"text-see-less\">See Less</p>';\n        details.appendChild(summary);\n        details.appendChild(itemsWrapper);\n        itemsWrapper.classList.add('sub-version-items-wrapper');\n        details.classList.add('whats-new-rss-sub-version-details');\n        return details.outerHTML;\n    }\n    formatDate(date) {\n        if ('function' === typeof this.RSS.getArgs().flyout.formatDate) {\n            return this.RSS.getArgs().flyout.formatDate(date);\n        }\n        const currentDate = new Date();\n        const timestamp = date.getTime();\n        const currentTimestamp = currentDate.getTime();\n        const difference = currentTimestamp - timestamp;\n        // Define time intervals in milliseconds\n        const minute = 60 * 1000;\n        const hour = minute * 60;\n        const day = hour * 24;\n        const week = day * 7;\n        const month = day * 30; // Rough estimate, assuming 30 days in a month\n        if (difference < minute) {\n            return 'Just now';\n        }\n        else if (difference < hour) {\n            const minutes = Math.floor(difference / minute);\n            return `${minutes} minute${minutes > 1 ? 's' : ''} ago`;\n        }\n        else if (difference < day) {\n            const hours = Math.floor(difference / hour);\n            return `${hours} hour${hours > 1 ? 's' : ''} ago`;\n        }\n        else if (difference < week) {\n            const days = Math.floor(difference / day);\n            return `${days} day${days > 1 ? 's' : ''} ago`;\n        }\n        else if (difference < month) {\n            const weeks = Math.floor(difference / week);\n            return `${weeks} week${weeks > 1 ? 's' : ''} ago`;\n        }\n        else {\n            // Handle months and years accordingly\n            // This is a rough estimate and may not be accurate in all cases\n            const months = Math.floor(difference / month);\n            return `${months} month${months > 1 ? 's' : ''} ago`;\n        }\n    }\n}\n\nasync function getCSS() {\n    return `.whats-new-rss-is-active{overflow:hidden}.whats-new-rss-trigger-button{display:flex;align-items:center;position:relative;width:auto;padding:0!important;cursor:pointer}.whats-new-rss-trigger-button.has-label{align-items:end;gap:10px}.whats-new-rss-trigger-button.has-label .icon-badge{position:relative;line-height:1}.whats-new-rss-trigger-button.has-label .icon-badge .whats-new-rss-notification-badge{top:-12px;right:-10px}.whats-new-rss-trigger-button .whats-new-rss-notification-badge{position:absolute;top:-8px;right:-9px;width:18px;height:18px;font-size:10px;line-height:20px;text-align:center;border-radius:10px;color:#fff;background:#ff580e;display:flex;align-items:center;justify-content:center;transition:transform .2s ease-in-out}.whats-new-rss-trigger-button .whats-new-rss-notification-badge.is-multi-feed{top:-2px;right:-2px;font-size:0;width:10px;height:10px}.whats-new-rss-trigger-button .whats-new-rss-notification-badge.hide{display:none!important}.whats-new-rss-trigger-button:hover .whats-new-rss-notification-badge{transform:unset}.whats-new-rss-flyout{position:fixed;top:0;right:0;bottom:0;width:100%;z-index:99999;transition:visibility .3s ease-in-out;font-family:Arial,Helvetica,sans-serif;height:100vh;font-size:15px;font-weight:400;line-height:20px;color:#475569;margin-bottom:5px}.whats-new-rss-flyout .lightbox-trigger,.whats-new-rss-flyout.hidden{display:none}.whats-new-rss-flyout.is-loading .whats-new-rss-flyout-inner-header__loading-icon{display:block;margin:auto}.whats-new-rss-flyout.is-loading .whats-new-rss-flyout-inner-header__loading-icon svg{display:block;background:0 0;width:25px;height:25px}.whats-new-rss-flyout p{font-size:15px;font-weight:400;line-height:1.5em;color:#475569;margin-bottom:15px}.whats-new-rss-flyout p a{color:#1170ff}.whats-new-rss-flyout .wp-block-uagb-buttons{background:#ff6c0a;padding:10px 18px;width:fit-content;color:#fff;border-radius:6px;box-shadow:0 1px 2px rgba(0,0,0,.05);margin-bottom:15px}.whats-new-rss-flyout .wp-block-uagb-buttons .uagb-button__link{color:#fff;font-size:1rem;font-weight:600;line-height:1.5rem}.whats-new-rss-flyout .ast-oembed-container{position:relative;padding-top:56.25%;height:0;overflow:hidden;max-width:100%;height:auto}.whats-new-rss-flyout .wp-has-aspect-ratio iframe{bottom:0;height:100%;left:0;position:absolute;right:0;top:0;width:100%}.whats-new-rss-flyout .whats-new-rss-flyout-contents{position:fixed;display:flex;right:0;width:30%;height:100%;flex-direction:column;background-color:#fff;transition:transform .3s ease-in-out;z-index:9999}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header{display:flex;justify-content:space-between;align-items:center;padding:18px 24px!important;border-bottom:1px solid #ccc}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header button{border:none;background:0 0;font-size:30px;cursor:pointer;color:#94a3b8;padding:0;margin:0;box-shadow:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header .whats-new-rss-flyout-inner-header__title-icon-wrapper{display:flex;gap:10px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header .whats-new-rss-flyout-inner-header__title-icon-wrapper h3{margin:0;padding:0;color:#0f172a;font-weight:600;font-size:20px;line-height:24px;margin-bottom:0!important}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav{display:flex;padding:0 30px;border-bottom:1px solid #ccc;gap:2em;overflow:auto;white-space:nowrap}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button{position:relative;background:0 0;color:inherit;padding:15px 0;border-bottom:2px solid transparent}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button:focus,.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button:hover{border-color:inherit}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button.selected{border-color:#5d5d5d}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button .new-notification-count{position:absolute;top:0;right:-10px;width:20px;font-size:10px;line-height:20px;text-align:center;border-radius:10px;color:#fff;background:red}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content{flex:1;overflow-y:auto}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .skeleton-container{margin:30px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item{border-bottom:1px solid #d8dfe9;padding:24px 24px;color:#475569;font-weight:400;font-size:14px;line-height:20px;display:flex;flex-direction:column;gap:12px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .wp-smiley{display:inline-block;margin:0;min-height:1em;margin-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item>*{margin:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h2{font-size:22px;font-weight:700;line-height:1.5em;margin-bottom:15px;padding-top:12px;padding-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h3{font-size:20px;font-weight:700;line-height:1.5em;padding-top:12px;padding-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h4{font-size:18px;font-weight:700;line-height:1.5em;padding-top:12px;padding-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h5{font-size:16px;font-weight:700;line-height:1.5em;margin-bottom:15px;padding-top:12px;padding-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h6{font-size:13px;font-weight:700;line-height:1.5em;margin-bottom:15px;padding-top:12px;padding-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item.skeleton-row{height:25vh;margin:40px 0;background:linear-gradient(90deg,#eee 25%,#ddd 50%,#eee 75%);background-size:200% 100%;animation:shimmer 1.5s infinite}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item.rss-new-post{position:relative}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item.rss-new-post .new-post-badge{background:#ff6c0a;border-radius:4px;top:22px;right:24px;padding:0 4px;color:#fff;position:absolute}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .rss-content-header{display:flex;flex-direction:column;gap:4px;padding:0 0 8px 0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .rss-content-header p{color:#94a3b8;margin:0;padding:0;font-weight:600;line-height:16px;font-size:12px;margin-bottom:0!important}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .rss-content-header h2{margin:0;color:#0f172a;font-weight:700;line-height:1.5em;font-size:24px;padding:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item p{padding:0;font-size:15px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item p:last-child{margin-bottom:0;padding-bottom:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item a{color:#1170ff;text-decoration:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item figure{margin:10px 0;margin-bottom:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item figure.wp-block-embed.is-type-video{position:relative;width:100%;height:0;padding-bottom:56.25%}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item figure iframe{position:absolute;top:0;left:0;width:100%;height:100%;border:0;max-width:100%}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item img{box-sizing:border-box;height:auto;max-width:100%;vertical-align:bottom;margin-bottom:15px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item video{vertical-align:middle;width:100%}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item strong{font-weight:600}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ol,.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ul{padding-inline-start:20px;margin-left:10px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ol li,.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ul li{font-size:15px;font-weight:400;line-height:1.5em;color:#475569;margin-bottom:4px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ul{list-style-type:disc}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ol{list-style-type:decimal}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details{line-height:20px;font-size:.9em;margin:10px 0;background:#f9fafb}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary{display:flex;justify-content:space-between;cursor:pointer;padding:20px 15px;height:1em;line-height:20px;font-weight:800}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary::after{content:\"⌃\";font-size:20px;transform:rotateX(180deg);font-weight:800}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary .text-see-more{display:block}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary .text-see-less{display:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary{border-bottom:1px solid #e2e8f0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary::after{transform:rotateX(45deg)}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary .text-see-more{display:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary .text-see-less{display:block}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details .sub-version-item{position:relative;padding:1em;border-bottom:1px solid #e2e8f0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details .sub-version-item .sub-version-header{display:flex;justify-content:space-between}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details .sub-version-item .sub-version-content{margin-top:1em}.whats-new-rss-flyout .whats-new-rss-flyout-overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:rgba(0,0,0,.5);transition:all .3s ease-in-out}.whats-new-rss-flyout.closed{visibility:hidden}.whats-new-rss-flyout.closed .whats-new-rss-flyout-overlay{opacity:0;visibility:hidden}.whats-new-rss-flyout.closed .whats-new-rss-flyout-contents{transform:translateX(100%)}.whats-new-rss-flyout .whats-new-rss-flyout-inner-header__loading-icon{display:none}@keyframes shimmer{0%{background-position:-200% 0}100%{background-position:200% 0}}@media screen and (max-width:1024px){.whats-new-rss-flyout .whats-new-rss-flyout-contents{width:40%}}@media screen and (max-width:768px){.whats-new-rss-flyout .whats-new-rss-flyout-contents{width:85%}}`;\n}\n\nasync function addStyleIfNotExists() {\n    const styleId = 'whats-new-rss-styles';\n    if (!document.getElementById(styleId)) {\n        const style = document.createElement('style');\n        style.id = styleId;\n        style.innerHTML = await getCSS();\n        document.head.appendChild(style);\n    }\n}\n\n\nfunction createWhatsNewRSSInstance(args) {\n    return new WhatsNewRSS(args);\n}\n\nfunction useWhatsNewRSS({ selector, ...rest }) {\n    const instanceRef = useRef(null);\n\n    useEffect(() => {\n        addStyleIfNotExists();\n\n        if (!instanceRef.current) {\n            instanceRef.current = createWhatsNewRSSInstance({ selector, ...rest });\n        }\n\n        // Cleanup function\n        return () => {\n            if (instanceRef.current && typeof instanceRef.current.destroy === 'function') {\n                instanceRef.current.destroy();\n            }\n        };\n    }, [selector, ...Object.values(rest)]); // Adjust dependencies as needed\n\n    return instanceRef.current;\n}\n\nexport default useWhatsNewRSS;\n\n","import React, { useEffect, useState } from \"react\";\nimport { Topbar, Badge, DropdownMenu } from \"@bsf/force-ui\";\nimport { CircleHelp, FileText, Headset, User } from \"lucide-react\";\nimport { __ } from \"@wordpress/i18n\";\nimport { routes } from \"../admin/settings/routes\";\nimport { Link } from \"../router/index\";\nimport useWhatsNewRSS from \"whats-new-rss\";\nfunction updateNavMenuActiveState() {\n\tconst currentPath = window.location.hash;\n\tconst menuItems = document.querySelectorAll(\n\t\t\"#adminmenu #toplevel_page_uaepro a\"\n\t);\n\tmenuItems.forEach((item) => {\n\t\tconst href = item.getAttribute(\"href\");\n\t\tconst parentLi = item.closest(\"li\");\n\t\tconst itemText = item.textContent.trim();\n\t\tif (\n\t\t\thref &&\n\t\t\t(currentPath.includes(href.split(\"#\")[1]) ||\n\t\t\t\t(\"#dashboard\" === currentPath && itemText === \"Dashboard\"))\n\t\t) {\n\t\t\tparentLi.classList.add(\"current\");\n\t\t} else {\n\t\t\tparentLi.classList.remove(\"current\");\n\t\t}\n\t});\n}\nexport default function NavMenu() {\n\tconst [isDropdownOpen, setIsDropdownOpen] = useState(false);\n\tconst [isHelpOpen, setIsHelpOpen] = useState(false);\n\tconst toggleHelpDropdown = () => setIsHelpOpen((prev) => !prev);\n\tconst closeHelpDropdown = () => setIsHelpOpen(false);\n\tuseEffect(() => {\n\t\tupdateNavMenuActiveState();\n\t\twindow.addEventListener(\"hashchange\", updateNavMenuActiveState);\n\t\treturn () => {\n\t\t\twindow.removeEventListener(\"hashchange\", updateNavMenuActiveState);\n\t\t};\n\t}, []);\n\tuseEffect(() => {\n\t\tconst handleClickOutside = (event) => {\n\t\t\tif (!event.target.closest(\".uae-help-dropdown\")) {\n\t\t\t\tsetIsHelpOpen(false);\n\t\t\t}\n\t\t};\n\t\tdocument.addEventListener(\"click\", handleClickOutside);\n\t\treturn () => document.removeEventListener(\"click\", handleClickOutside);\n\t}, []);\n\tconst currentPath = window.location.hash;\n\tconst isActive = (path) => currentPath.includes(path);\n\tconst linkStyle = (path) => ({\n\t\tcolor: isActive(path) ? \"#111827\" : \"#4B5563\",\n\t\tborderBottom: isActive(path) ? \"2px solid #6005FF\" : \"none\",\n\t\tpaddingBottom: \"22px\",\n\t\tmarginBottom: \"-16px\",\n\t});\n\tconst handleRedirect = (url) => {\n\t\twindow.open(url, \"_blank\");\n\t\tsetIsHelpOpen(false);\n\t\tsetIsDropdownOpen(false);\n\t};\n\tuseWhatsNewRSS({\n\t\trssFeedURL: \"https://ultimateelementor.com/whats-new/feed/\",\n\t\tselector: \"#uae-whats-new\",\n\t\tuniqueKey: \"uael-whats-new\",\n\t\ttriggerButton: {\n\t\t\tbeforeBtn:\n\t\t\t\t'<div class=\"w-4 sm:w-8 h-8 sm:h-10 flex items-center whitespace-nowrap justify-center cursor-pointer rounded-full border border-slate-200\">',\n\t\t\ticon: '<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"#434141\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-megaphone\"><path d=\"m3 11 18-5v12L3 14v-3z\"></path><path d=\"M11.6 16.8a3 3 0 1 1-5.8-1.6\"></path></svg>',\n\t\t\tafterBtn: \"</div>\",\n\t\t},\n\t\tflyout: {\n\t\t\ttitle: __(\"What's New?\", \"uael\"),\n\t\t\tformatDate: (date) => {\n\t\t\t\tconst dayOfWeek = date.toLocaleDateString(\"en-US\", {\n\t\t\t\t\tweekday: \"long\",\n\t\t\t\t});\n\t\t\t\tconst month = date.toLocaleDateString(\"en-US\", {\n\t\t\t\t\tmonth: \"long\",\n\t\t\t\t});\n\t\t\t\tconst day = date.getDate();\n\t\t\t\tconst year = date.getFullYear();\n\t\t\t\treturn `${dayOfWeek} ${month} ${day}, ${year}`;\n\t\t\t},\n\t\t},\n\t});\n\treturn (\n\t\t<Topbar\n\t\t\tclassName=\"uae-nav-menu relative\"\n\t\t\tstyle={{ width: \"unset\", padding: \"0.5rem\", zIndex: \"9\" }}\n\t\t>\n\t\t\t<div className=\"flex flex-col lg:flex-row items-start md:items-center w-full\">\n\t\t\t\t<div className=\"flex flex-row md:items-center md:gap-8 w-full\">\n\t\t\t\t\t<Topbar.Left>\n\t\t\t\t\t\t<Topbar.Item>\n\t\t\t\t\t\t\t{uaelSettingsData.icon_url && (\n\t\t\t\t\t\t\t\t<Link to={routes.dashboard.path}>\n\t\t\t\t\t\t\t\t\t<img\n\t\t\t\t\t\t\t\t\t\tsrc={`${uaelSettingsData.icon_url}`}\n\t\t\t\t\t\t\t\t\t\talt=\"Logo\"\n\t\t\t\t\t\t\t\t\t\tclassName=\"ml-4 cursor-pointer\"\n\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\theight: \"35px\",\n\t\t\t\t\t\t\t\t\t\t\twidth: \"35px\",\n\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t</Link>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t</Topbar.Item>\n\t\t\t\t\t</Topbar.Left>\n\t\t\t\t\t<Topbar.Middle className=\"flex-grow\" align=\"left\">\n\t\t\t\t\t\t<nav className=\"flex flex-wrap gap-6 mt-2 md:mt-0 cursor-pointer\">\n\t\t\t\t\t\t\t<Link\n\t\t\t\t\t\t\t\tto={routes.dashboard.path}\n\t\t\t\t\t\t\t\tclassName={`${\n\t\t\t\t\t\t\t\t\tisActive(\"dashboard\") ? \"active-link\" : \"\"\n\t\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t\t\tstyle={linkStyle(\"dashboard\")}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{__(\"Dashboard\", \"uael\")}\n\t\t\t\t\t\t\t</Link>\n\t\t\t\t\t\t\t{uaelSettingsData.is_lite_active && (\n\t\t\t\t\t\t\t\t<Link\n\t\t\t\t\t\t\t\t\tto={routes.headerFooterBuilder.path} // Add this Link component.\n\t\t\t\t\t\t\t\t\tclassName={`${\n\t\t\t\t\t\t\t\t\t\tisActive(\n\t\t\t\t\t\t\t\t\t\t\t\"edit.php?post_type=elementor-hf\"\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t? \"active-link\"\n\t\t\t\t\t\t\t\t\t\t\t: \"\"\n\t\t\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t\t\t\tstyle={linkStyle(\n\t\t\t\t\t\t\t\t\t\t\"edit.php?post_type=elementor-hf\"\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t{__(\"Header & Footer\", \"uael\")}\n\t\t\t\t\t\t\t\t</Link>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t<Link\n\t\t\t\t\t\t\t\tto={routes.widgets.path}\n\t\t\t\t\t\t\t\tclassName={`${\n\t\t\t\t\t\t\t\t\tisActive(\"widgets\") ? \"active-link\" : \"\"\n\t\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t\t\tstyle={linkStyle(\"widgets\")}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{__(\"Widgets\", \"uael\")}\n\t\t\t\t\t\t\t</Link>\n\t\t\t\t\t\t\t<Link\n\t\t\t\t\t\t\t\tto={routes.settings.path}\n\t\t\t\t\t\t\t\tclassName={`${\n\t\t\t\t\t\t\t\t\tisActive(\"settings\") ? \"active-link\" : \"\"\n\t\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t\t\tstyle={linkStyle(\"settings\")}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{__(\"Settings\", \"uael\")}\n\t\t\t\t\t\t\t</Link>\n\t\t\t\t\t\t</nav>\n\t\t\t\t\t</Topbar.Middle>\n\t\t\t\t\t<Topbar.Right className=\"flex flex-col lg:flex-row gap-4 mt-4 md:mt-0\">\n\t\t\t\t\t\t<Topbar.Item>\n\t\t\t\t\t\t\t<DropdownMenu\n\t\t\t\t\t\t\t\tplacement=\"bottom-start\"\n\t\t\t\t\t\t\t\tisOpen={isDropdownOpen}\n\t\t\t\t\t\t\t\tonOpenChange={setIsDropdownOpen}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<DropdownMenu.Trigger>\n\t\t\t\t\t\t\t\t\t<Badge\n\t\t\t\t\t\t\t\t\t\tlabel={__(\"PRO\", \"uael\")}\n\t\t\t\t\t\t\t\t\t\tsize=\"md\"\n\t\t\t\t\t\t\t\t\t\tvariant=\"neutral\"\n\t\t\t\t\t\t\t\t\t\tclassName=\"bg-gradient-to-r from-[#A78BFA] to-[#6005FF] text-white hidden md:flex\"\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t</DropdownMenu.Trigger>\n\t\t\t\t\t\t\t\t<DropdownMenu.ContentWrapper>\n\t\t\t\t\t\t\t\t\t<DropdownMenu.Content className=\"w-52\">\n\t\t\t\t\t\t\t\t\t\t<DropdownMenu.List>\n\t\t\t\t\t\t\t\t\t\t\t<DropdownMenu.Item>\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\"Version\", \"uael\")}\n\t\t\t\t\t\t\t\t\t\t\t</DropdownMenu.Item>\n\t\t\t\t\t\t\t\t\t\t\t{uaelSettingsData.is_lite_active && (\n\t\t\t\t\t\t\t\t\t\t\t\t<DropdownMenu.Item>\n\t\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"flex justify-between w-full\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{`${uaelSettingsData.uaelite_current_version}`}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<img\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tsrc={`${uaelSettingsData.core_badge}`}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\talt=\"CORE\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\theight: \"30px\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\twidth: \"38px\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t</DropdownMenu.Item>\n\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t<DropdownMenu.Item>\n\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"flex justify-between w-full\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t{`${uaelSettingsData.uael_current_version}`}\n\t\t\t\t\t\t\t\t\t\t\t\t\t<img\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tsrc={`${uaelSettingsData.pro_badge}`}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\talt=\"PRO\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\theight: \"30px\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\twidth: \"38px\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t</DropdownMenu.Item>\n\t\t\t\t\t\t\t\t\t\t</DropdownMenu.List>\n\t\t\t\t\t\t\t\t\t</DropdownMenu.Content>\n\t\t\t\t\t\t\t\t</DropdownMenu.ContentWrapper>\n\t\t\t\t\t\t\t</DropdownMenu>\n\t\t\t\t\t\t</Topbar.Item>\n\t\t\t\t\t\t{!uaelSettingsData.hide_settings && (\n\t\t\t\t\t\t\t<Topbar.Item className=\"gap-4 flex items-center uae-help-dropdown relative\">\n\t\t\t\t\t\t\t\t<div\n\t\t\t\t\t\t\t\t\tonClick={toggleHelpDropdown}\n\t\t\t\t\t\t\t\t\tclassName=\"cursor-pointer\"\n\t\t\t\t\t\t\t\t\ttitle=\"Help\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<CircleHelp />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t{isHelpOpen && (\n\t\t\t\t\t\t\t\t\t<div className=\"absolute right-0 top-8 w-64 bg-white border border-gray-200 rounded shadow-md z-50\">\n\t\t\t\t\t\t\t\t\t\t<ul className=\"text-sm text-gray-700\">\n\t\t\t\t\t\t\t\t\t\t\t<li className=\"px-4 py-2 border-b font-semibold\">\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\"Useful Resources\", \"uael\")}\n\t\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t\t\t<li\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"px-4 py-2 hover:bg-gray-100 cursor-pointer flex gap-2 items-center\"\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t\t\thandleRedirect(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs/getting-started-uael/\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<FileText />\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\"Getting Started\", \"uael\")}\n\t\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t\t\t<li\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"px-4 py-2 hover:bg-gray-100 cursor-pointer flex gap-2 items-center\"\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t\t\thandleRedirect(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs-category/widgets/\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<FileText />\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"How to use widgets\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"uael\"\n\t\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t\t\t<li\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"px-4 py-2 hover:bg-gray-100 cursor-pointer flex gap-2 items-center\"\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t\t\thandleRedirect(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs-category/features/\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<FileText />\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"How to use features\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"uael\"\n\t\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t\t\t<li\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"px-4 py-2 hover:bg-gray-100 cursor-pointer flex gap-2 items-center\"\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t\t\thandleRedirect(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs-category/templates/\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<FileText />\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"How to use templates\",\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"uael\"\n\t\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t\t\t<li\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"px-4 py-2 hover:bg-gray-100 cursor-pointer flex gap-2 items-center\"\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t\t\thandleRedirect(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/contact/\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<Headset />\n\t\t\t\t\t\t\t\t\t\t\t\t{__(\"Contact us\", \"uael\")}\n\t\t\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t<div className=\"pb-1\" id=\"uae-whats-new\"></div>\n\t\t\t\t\t\t\t\t<Link to={routes.settings.path}>\n\t\t\t\t\t\t\t\t\t<User\n\t\t\t\t\t\t\t\t\t\tclassName=\"cursor-pointer uae-user-icon\"\n\t\t\t\t\t\t\t\t\t\tstyle={{ color: \"black\" }}\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t</Link>\n\t\t\t\t\t\t\t</Topbar.Item>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</Topbar.Right>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</Topbar>\n\t);\n}\n","const l = {\n  sm: {\n    1: \"grid-cols-1\",\n    2: \"grid-cols-2\",\n    3: \"grid-cols-3\",\n    4: \"grid-cols-4\",\n    5: \"grid-cols-5\",\n    6: \"grid-cols-6\",\n    7: \"grid-cols-7\",\n    8: \"grid-cols-8\",\n    9: \"grid-cols-9\",\n    10: \"grid-cols-10\",\n    11: \"grid-cols-11\",\n    12: \"grid-cols-12\"\n  },\n  md: {\n    1: \"md:grid-cols-1\",\n    2: \"md:grid-cols-2\",\n    3: \"md:grid-cols-3\",\n    4: \"md:grid-cols-4\",\n    5: \"md:grid-cols-5\",\n    6: \"md:grid-cols-6\",\n    7: \"md:grid-cols-7\",\n    8: \"md:grid-cols-8\",\n    9: \"md:grid-cols-9\",\n    10: \"md:grid-cols-10\",\n    11: \"md:grid-cols-11\",\n    12: \"md:grid-cols-12\"\n  },\n  lg: {\n    1: \"lg:grid-cols-1\",\n    2: \"lg:grid-cols-2\",\n    3: \"lg:grid-cols-3\",\n    4: \"lg:grid-cols-4\",\n    5: \"lg:grid-cols-5\",\n    6: \"lg:grid-cols-6\",\n    7: \"lg:grid-cols-7\",\n    8: \"lg:grid-cols-8\",\n    9: \"lg:grid-cols-9\",\n    10: \"lg:grid-cols-10\",\n    11: \"lg:grid-cols-11\",\n    12: \"lg:grid-cols-12\"\n  }\n}, s = {\n  sm: {\n    xs: \"gap-2\",\n    sm: \"gap-4\",\n    md: \"gap-5\",\n    lg: \"gap-6\",\n    xl: \"gap-6\",\n    \"2xl\": \"gap-8\"\n  },\n  md: {\n    xs: \"md:gap-2\",\n    sm: \"md:gap-4\",\n    md: \"md:gap-5\",\n    lg: \"md:gap-6\",\n    xl: \"md:gap-6\",\n    \"2xl\": \"md:gap-8\"\n  },\n  lg: {\n    xs: \"lg:gap-2\",\n    sm: \"lg:gap-4\",\n    md: \"lg:gap-5\",\n    lg: \"lg:gap-6\",\n    xl: \"lg:gap-6\",\n    \"2xl\": \"lg:gap-8\"\n  }\n}, e = {\n  sm: {\n    xs: \"gap-x-2\",\n    sm: \"gap-x-4\",\n    md: \"gap-x-5\",\n    lg: \"gap-x-6\",\n    xl: \"gap-x-6\",\n    \"2xl\": \"gap-x-8\"\n  },\n  md: {\n    xs: \"md:gap-x-2\",\n    sm: \"md:gap-x-4\",\n    md: \"md:gap-x-5\",\n    lg: \"md:gap-x-6\",\n    xl: \"md:gap-x-6\",\n    \"2xl\": \"md:gap-x-8\"\n  },\n  lg: {\n    xs: \"lg:gap-x-2\",\n    sm: \"lg:gap-x-4\",\n    md: \"lg:gap-x-5\",\n    lg: \"lg:gap-x-6\",\n    xl: \"lg:gap-x-6\",\n    \"2xl\": \"lg:gap-x-8\"\n  }\n}, r = {\n  sm: {\n    xs: \"gap-y-2\",\n    sm: \"gap-y-4\",\n    md: \"gap-y-5\",\n    lg: \"gap-y-6\",\n    xl: \"gap-y-6\",\n    \"2xl\": \"gap-y-8\"\n  },\n  md: {\n    xs: \"md:gap-y-2\",\n    sm: \"md:gap-y-4\",\n    md: \"md:gap-y-5\",\n    lg: \"md:gap-y-6\",\n    xl: \"md:gap-y-6\",\n    \"2xl\": \"md:gap-y-8\"\n  },\n  lg: {\n    xs: \"lg:gap-y-2\",\n    sm: \"lg:gap-y-4\",\n    md: \"lg:gap-y-5\",\n    lg: \"lg:gap-y-6\",\n    xl: \"lg:gap-y-6\",\n    \"2xl\": \"lg:gap-y-8\"\n  }\n}, t = {\n  sm: {\n    1: \"col-span-1\",\n    2: \"col-span-2\",\n    3: \"col-span-3\",\n    4: \"col-span-4\",\n    5: \"col-span-5\",\n    6: \"col-span-6\",\n    7: \"col-span-7\",\n    8: \"col-span-8\",\n    9: \"col-span-9\",\n    10: \"col-span-10\",\n    11: \"col-span-11\",\n    12: \"col-span-12\"\n  },\n  md: {\n    1: \"md:col-span-1\",\n    2: \"md:col-span-2\",\n    3: \"md:col-span-3\",\n    4: \"md:col-span-4\",\n    5: \"md:col-span-5\",\n    6: \"md:col-span-6\",\n    7: \"md:col-span-7\",\n    8: \"md:col-span-8\",\n    9: \"md:col-span-9\",\n    10: \"md:col-span-10\",\n    11: \"md:col-span-11\",\n    12: \"md:col-span-12\"\n  },\n  lg: {\n    1: \"lg:col-span-1\",\n    2: \"lg:col-span-2\",\n    3: \"lg:col-span-3\",\n    4: \"lg:col-span-4\",\n    5: \"lg:col-span-5\",\n    6: \"lg:col-span-6\",\n    7: \"lg:col-span-7\",\n    8: \"lg:col-span-8\",\n    9: \"lg:col-span-9\",\n    10: \"lg:col-span-10\",\n    11: \"lg:col-span-11\",\n    12: \"lg:col-span-12\"\n  }\n}, d = {\n  sm: {\n    1: \"col-start-1\",\n    2: \"col-start-2\",\n    3: \"col-start-3\",\n    4: \"col-start-4\",\n    5: \"col-start-5\",\n    6: \"col-start-6\",\n    7: \"col-start-7\",\n    8: \"col-start-8\",\n    9: \"col-start-9\",\n    10: \"col-start-10\",\n    11: \"col-start-11\",\n    12: \"col-start-12\"\n  },\n  md: {\n    1: \"md:col-start-1\",\n    2: \"md:col-start-2\",\n    3: \"md:col-start-3\",\n    4: \"md:col-start-4\",\n    5: \"md:col-start-5\",\n    6: \"md:col-start-6\",\n    7: \"md:col-start-7\",\n    8: \"md:col-start-8\",\n    9: \"md:col-start-9\",\n    10: \"md:col-start-10\",\n    11: \"md:col-start-11\",\n    12: \"md:col-start-12\"\n  },\n  lg: {\n    1: \"lg:col-start-1\",\n    2: \"lg:col-start-2\",\n    3: \"lg:col-start-3\",\n    4: \"lg:col-start-4\",\n    5: \"lg:col-start-5\",\n    6: \"lg:col-start-6\",\n    7: \"lg:col-start-7\",\n    8: \"lg:col-start-8\",\n    9: \"lg:col-start-9\",\n    10: \"lg:col-start-10\",\n    11: \"lg:col-start-11\",\n    12: \"lg:col-start-12\"\n  }\n}, o = {\n  sm: {\n    row: \"grid-flow-row\",\n    column: \"grid-flow-col\",\n    \"row-dense\": \"grid-flow-row-dense\",\n    \"column-dense\": \"grid-flow-col-dense\"\n  },\n  md: {\n    row: \"md:grid-flow-row\",\n    column: \"md:grid-flow-col\",\n    \"row-dense\": \"md:grid-flow-row-dense\",\n    \"column-dense\": \"md:grid-flow-col-dense\"\n  },\n  lg: {\n    row: \"lg:grid-flow-row\",\n    column: \"lg:grid-flow-col\",\n    \"row-dense\": \"lg:grid-flow-row-dense\",\n    \"column-dense\": \"lg:grid-flow-col-dense\"\n  }\n}, g = {\n  sm: {\n    normal: \"justify-normal\",\n    start: \"justify-start\",\n    end: \"justify-end\",\n    center: \"justify-center\",\n    between: \"justify-between\",\n    around: \"justify-around\",\n    evenly: \"justify-evenly\",\n    stretch: \"justify-stretch\"\n  },\n  md: {\n    normal: \"md:justify-normal\",\n    start: \"md:justify-start\",\n    end: \"md:justify-end\",\n    center: \"md:justify-center\",\n    between: \"md:justify-between\",\n    around: \"md:justify-around\",\n    evenly: \"md:justify-evenly\",\n    stretch: \"md:justify-stretch\"\n  },\n  lg: {\n    normal: \"lg:justify-normal\",\n    start: \"lg:justify-start\",\n    end: \"lg:justify-end\",\n    center: \"lg:justify-center\",\n    between: \"lg:justify-between\",\n    around: \"lg:justify-around\",\n    evenly: \"lg:justify-evenly\",\n    stretch: \"lg:justify-stretch\"\n  }\n}, a = {\n  sm: {\n    start: \"items-start\",\n    end: \"items-end\",\n    center: \"items-center\",\n    baseline: \"items-baseline\",\n    stretch: \"items-stretch\"\n  },\n  md: {\n    start: \"md:items-start\",\n    end: \"md:items-end\",\n    center: \"md:items-center\",\n    baseline: \"md:items-baseline\",\n    stretch: \"md:items-stretch\"\n  },\n  lg: {\n    start: \"lg:items-start\",\n    end: \"lg:items-end\",\n    center: \"lg:items-center\",\n    baseline: \"lg:items-baseline\",\n    stretch: \"lg:items-stretch\"\n  }\n}, m = {\n  sm: {\n    start: \"self-start\",\n    end: \"self-end\",\n    center: \"self-center\",\n    baseline: \"self-baseline\",\n    stretch: \"self-stretch\"\n  },\n  md: {\n    start: \"md:self-start\",\n    end: \"md:self-end\",\n    center: \"md:self-center\",\n    baseline: \"md:self-baseline\",\n    stretch: \"md:self-stretch\"\n  },\n  lg: {\n    start: \"lg:self-start\",\n    end: \"lg:self-end\",\n    center: \"lg:self-center\",\n    baseline: \"lg:self-baseline\",\n    stretch: \"lg:self-stretch\"\n  }\n}, c = {\n  sm: {\n    auto: \"justify-self-auto\",\n    start: \"justify-self-start\",\n    end: \"justify-self-end\",\n    center: \"justify-self-center\",\n    baseline: \"justify-self-baseline\",\n    stretch: \"justify-self-stretch\"\n  },\n  md: {\n    auto: \"md:justify-self-auto\",\n    start: \"md:justify-self-start\",\n    end: \"md:justify-self-end\",\n    center: \"md:justify-self-center\",\n    baseline: \"md:justify-self-baseline\",\n    stretch: \"md:justify-self-stretch\"\n  },\n  lg: {\n    auto: \"lg:justify-self-auto\",\n    start: \"lg:justify-self-start\",\n    end: \"lg:justify-self-end\",\n    center: \"lg:justify-self-center\",\n    baseline: \"lg:justify-self-baseline\",\n    stretch: \"lg:justify-self-stretch\"\n  }\n}, n = {\n  sm: {\n    row: \"flex-row\",\n    \"row-reverse\": \"flex-row-reverse\",\n    column: \"flex-col\",\n    \"column-reverse\": \"flex-col-reverse\"\n  },\n  md: {\n    row: \"md:flex-row\",\n    \"row-reverse\": \"md:flex-row-reverse\",\n    column: \"md:flex-col\",\n    \"column-reverse\": \"md:flex-col-reverse\"\n  },\n  lg: {\n    row: \"lg:flex-row\",\n    \"row-reverse\": \"lg:flex-row-reverse\",\n    column: \"lg:flex-col\",\n    \"column-reverse\": \"lg:flex-col-reverse\"\n  }\n}, i = {\n  sm: {\n    wrap: \"flex-wrap\",\n    \"wrap-reverse\": \"flex-wrap-reverse\",\n    nowrap: \"flex-nowrap\"\n  },\n  md: {\n    wrap: \"md:flex-wrap\",\n    \"wrap-reverse\": \"md:flex-wrap-reverse\",\n    nowrap: \"md:flex-nowrap\"\n  },\n  lg: {\n    wrap: \"lg:flex-wrap\",\n    \"wrap-reverse\": \"lg:flex-wrap-reverse\",\n    nowrap: \"lg:flex-nowrap\"\n  }\n}, f = {\n  sm: {\n    1: \"w-full\",\n    2: \"w-1/2\",\n    3: \"w-1/3\",\n    4: \"w-1/4\",\n    5: \"w-1/5\",\n    6: \"w-1/6\",\n    7: \"w-1/7\",\n    8: \"w-1/8\",\n    9: \"w-1/9\",\n    10: \"w-1/10\",\n    11: \"w-1/11\",\n    12: \"w-1/12\"\n  },\n  md: {\n    1: \"md:w-full\",\n    2: \"md:w-1/2\",\n    3: \"md:w-1/3\",\n    4: \"md:w-1/4\",\n    5: \"md:w-1/5\",\n    6: \"md:w-1/6\",\n    7: \"md:w-1/7\",\n    8: \"md:w-1/8\",\n    9: \"md:w-1/9\",\n    10: \"md:w-1/10\",\n    11: \"md:w-1/11\",\n    12: \"md:w-1/12\"\n  },\n  lg: {\n    1: \"lg:w-full\",\n    2: \"lg:w-1/2\",\n    3: \"lg:w-1/3\",\n    4: \"lg:w-1/4\",\n    5: \"lg:w-1/5\",\n    6: \"lg:w-1/6\",\n    7: \"lg:w-1/7\",\n    8: \"lg:w-1/8\",\n    9: \"lg:w-1/9\",\n    10: \"lg:w-1/10\",\n    11: \"lg:w-1/11\",\n    12: \"lg:w-1/12\"\n  }\n}, p = {\n  sm: {\n    1: \"order-1\",\n    2: \"order-2\",\n    3: \"order-3\",\n    4: \"order-4\",\n    5: \"order-5\",\n    6: \"order-6\",\n    7: \"order-7\",\n    8: \"order-8\",\n    9: \"order-9\",\n    10: \"order-10\",\n    11: \"order-11\",\n    12: \"order-12\",\n    first: \"order-first\",\n    last: \"order-last\",\n    none: \"order-none\"\n  },\n  md: {\n    1: \"md:order-1\",\n    2: \"md:order-2\",\n    3: \"md:order-3\",\n    4: \"md:order-4\",\n    5: \"md:order-5\",\n    6: \"md:order-6\",\n    7: \"md:order-7\",\n    8: \"md:order-8\",\n    9: \"md:order-9\",\n    10: \"md:order-10\",\n    11: \"md:order-11\",\n    12: \"md:order-12\",\n    first: \"md:order-first\",\n    last: \"md:order-last\",\n    none: \"md:order-none\"\n  },\n  lg: {\n    1: \"lg:order-1\",\n    2: \"lg:order-2\",\n    3: \"lg:order-3\",\n    4: \"lg:order-4\",\n    5: \"lg:order-5\",\n    6: \"lg:order-6\",\n    7: \"lg:order-7\",\n    8: \"lg:order-8\",\n    9: \"lg:order-9\",\n    10: \"lg:order-10\",\n    11: \"lg:order-11\",\n    12: \"lg:order-12\",\n    first: \"lg:order-first\",\n    last: \"lg:order-last\",\n    none: \"lg:order-none\"\n  }\n}, w = {\n  sm: {\n    0: \"grow-0\",\n    1: \"grow\"\n  },\n  md: {\n    0: \"md:grow-0\",\n    1: \"md:grow\"\n  },\n  lg: {\n    0: \"lg:grow-0\",\n    1: \"lg:grow\"\n  }\n}, u = {\n  sm: {\n    0: \"shrink-0\",\n    1: \"shrink\"\n  },\n  md: {\n    0: \"md:shrink-0\",\n    1: \"md:shrink\"\n  },\n  lg: {\n    0: \"lg:shrink-0\",\n    1: \"lg:shrink\"\n  }\n};\nexport {\n  a as alignClassNames,\n  m as alignSelfClassNames,\n  f as flexColumnClassNames,\n  n as flexDirectionClassNames,\n  w as flexGrowClassNames,\n  p as flexOrderClassNames,\n  u as flexShrinkClassNames,\n  i as flexWrapClassNames,\n  s as gapClassNames,\n  e as gapXClassNames,\n  r as gapYClassNames,\n  t as gridColSpanClassNames,\n  d as gridColStartClassNames,\n  l as gridColumnClassNames,\n  o as gridFlowClassNames,\n  g as justifyClassNames,\n  c as justifySelfClassNames\n};\n//# sourceMappingURL=container-styles.es.js.map\n","const p = (o, r, i, c = \"sm\") => {\n  const t = [];\n  switch (typeof o) {\n    case \"object\":\n      for (const [n, e] of Object.entries(o))\n        r[n] && t.push(\n          r?.[n]?.[e] ?? r?.[n]?.[i?.[n]] ?? \"\"\n        );\n      break;\n    case \"string\":\n    case \"number\":\n      const b = c;\n      t.push(\n        r?.[b]?.[o] ?? r?.[b]?.[i?.[b]] ?? \"\"\n      );\n      break;\n    default:\n      if (o === void 0)\n        break;\n      t.push(\n        r?.[c]?.[i] ?? \"\"\n      );\n      break;\n  }\n  return t.join(\" \");\n};\nexport {\n  p as getClassNames\n};\n//# sourceMappingURL=container-utils.es.js.map\n","import { jsx as c } from \"react/jsx-runtime\";\nimport { cn as g } from \"../../utilities/functions.es.js\";\nimport { gridColumnClassNames as x, gapClassNames as F, gapXClassNames as G, gapYClassNames as I, alignClassNames as X, justifyClassNames as Y, gridFlowClassNames as h, gridColSpanClassNames as k, gridColStartClassNames as q, alignSelfClassNames as z, justifySelfClassNames as A } from \"./container-styles.es.js\";\nimport { getClassNames as s } from \"./container-utils.es.js\";\nconst B = ({\n  className: a,\n  cols: l,\n  gap: e,\n  gapX: o,\n  gapY: m,\n  align: t,\n  justify: r,\n  gridFlow: i,\n  colsSubGrid: C = !1,\n  rowsSubGrid: n = !1,\n  autoRows: N = !1,\n  autoCols: f = !1,\n  children: d,\n  ...u\n}) => {\n  const p = s(l, x, 1), S = s(e, F, \"sm\"), j = s(o, G, \"\"), w = s(m, I, \"\"), y = s(t, X, \"\"), b = s(r, Y, \"\"), v = s(i, h, \"\");\n  return /* @__PURE__ */ c(\n    \"div\",\n    {\n      className: g(\n        \"grid\",\n        {\n          \"grid-cols-subgrid\": C,\n          \"grid-rows-subgrid\": n,\n          \"auto-cols-auto\": f,\n          \"auto-rows-auto\": N\n        },\n        p,\n        S,\n        j,\n        w,\n        y,\n        b,\n        v,\n        a\n      ),\n      ...u,\n      children: d\n    }\n  );\n}, D = ({\n  className: a,\n  children: l,\n  colSpan: e,\n  colStart: o,\n  alignSelf: m,\n  justifySelf: t,\n  ...r\n}) => {\n  const i = s(e, k, 0), C = s(\n    o,\n    q,\n    0\n  ), n = s(\n    m,\n    z,\n    \"\"\n  ), N = s(\n    t,\n    A,\n    \"\"\n  );\n  return /* @__PURE__ */ c(\n    \"div\",\n    {\n      className: g(\n        i,\n        C,\n        n,\n        N,\n        a\n      ),\n      ...r,\n      children: l\n    }\n  );\n};\nB.Item = D;\nexport {\n  D as GridItem,\n  B as default\n};\n//# sourceMappingURL=grid-container.es.js.map\n","import { jsx as e } from \"react/jsx-runtime\";\nimport { createContext as O, useContext as h } from \"react\";\nimport { cn as I } from \"../../utilities/functions.es.js\";\nimport v from \"./grid-container.es.js\";\nimport { getClassNames as s } from \"./container-utils.es.js\";\nimport { flexWrapClassNames as B, gapClassNames as D, gapXClassNames as P, gapYClassNames as W, flexDirectionClassNames as q, justifyClassNames as z, alignClassNames as A, alignSelfClassNames as E, justifySelfClassNames as F, flexGrowClassNames as H, flexShrinkClassNames as J, flexOrderClassNames as K, flexColumnClassNames as L } from \"./container-styles.es.js\";\nconst g = O({}), M = () => h(g), S = ({\n  containerType: a = \"flex\",\n  // flex, (grid - functionality not implemented)\n  gap: r = \"sm\",\n  // xs, sm, md, lg, xl, 2xl\n  gapX: m,\n  gapY: t,\n  direction: N,\n  // row, row-reverse, column, column reverse\n  justify: o,\n  // justify-content (normal, start, end, center, between, around, evenly, stretch)\n  align: n,\n  // align-items (start, end, center, baseline, stretch)\n  wrap: c,\n  // nowrap, wrap, wrap-reverse\n  cols: l,\n  className: C,\n  children: i,\n  ...f\n}) => {\n  if (a === \"grid\")\n    return /* @__PURE__ */ e(\n      g.Provider,\n      {\n        value: {\n          containerType: a\n        },\n        children: /* @__PURE__ */ e(\n          v,\n          {\n            className: C,\n            gap: r,\n            gapX: m,\n            gapY: t,\n            cols: l,\n            children: i,\n            align: n,\n            justify: o,\n            ...f\n          }\n        )\n      }\n    );\n  const d = s(c, B, \"\"), u = s(r, D, \"sm\"), x = s(m, P, \"\"), p = s(t, W, \"\"), w = s(\n    N,\n    q,\n    \"\"\n  ), j = s(\n    o,\n    z,\n    \"\"\n  ), k = s(n, A, \"\"), y = I(\n    \"flex\",\n    d,\n    u,\n    x,\n    p,\n    w,\n    j,\n    k,\n    C\n  ), G = () => a === \"flex\" ? /* @__PURE__ */ e(\"div\", { className: y, children: i }) : /* @__PURE__ */ e(\n    v,\n    {\n      className: C,\n      gap: r,\n      gapX: m,\n      gapY: t,\n      cols: l,\n      children: i,\n      align: n,\n      justify: o,\n      ...f\n    }\n  );\n  return /* @__PURE__ */ e(\n    g.Provider,\n    {\n      value: {\n        containerType: a,\n        cols: l\n      },\n      children: G()\n    }\n  );\n}, b = ({\n  grow: a,\n  shrink: r,\n  order: m,\n  alignSelf: t,\n  justifySelf: N,\n  className: o,\n  children: n,\n  ...c\n}) => {\n  const { containerType: l, cols: C } = M();\n  if (l === \"grid\")\n    return /* @__PURE__ */ e(\n      v.Item,\n      {\n        className: o,\n        alignSelf: t,\n        justifySelf: N,\n        children: n,\n        ...c\n      }\n    );\n  const i = s(\n    t,\n    E,\n    \"\"\n  ), f = s(\n    N,\n    F,\n    \"\"\n  ), d = s(a, H, 0), u = s(r, J, 0), x = s(m, K, 0), p = s(C, L, 1);\n  return /* @__PURE__ */ e(\n    \"div\",\n    {\n      className: I(\n        \"box-border\",\n        d,\n        u,\n        x,\n        i,\n        f,\n        p,\n        o\n      ),\n      children: n\n    }\n  );\n};\nS.Item = b;\nS.displayName = \"Container\";\nb.displayName = \"Container.Item\";\nexport {\n  S as Container,\n  b as Item,\n  S as default\n};\n//# sourceMappingURL=container.es.js.map\n","import { jsxs as t, jsx as n } from \"react/jsx-runtime\";\nimport { cn as a } from \"../../utilities/functions.es.js\";\nconst C = ({\n  title: x = \"\",\n  description: g = \"\",\n  icon: e = null,\n  iconPosition: r = \"right\",\n  // left, right\n  tag: c = \"h2\",\n  // h1, h2, h3, h4, h5, h6\n  size: s = \"sm\",\n  // xs, sm, md, lg\n  className: d = \"\"\n}) => {\n  const m = {\n    xs: \"gap-1 [&>svg]:size-3.5\",\n    sm: \"gap-1 [&>svg]:size-4\",\n    md: \"gap-1.5 [&>svg]:size-5\",\n    lg: \"gap-1.5 [&>svg]:size-5\"\n  };\n  if (!x)\n    return null;\n  const l = () => /* @__PURE__ */ n(c, { className: a(\"font-semibold p-0 m-0\", {\n    xs: \"text-base [&>*]:text-base gap-1\",\n    sm: \"text-lg [&>*]:text-lg gap-1\",\n    md: \"text-xl [&>*]:text-xl gap-1.5\",\n    lg: \"text-2xl [&>*]:text-2xl gap-1.5\"\n  }[s]), children: x }), i = () => /* @__PURE__ */ n(\n    \"p\",\n    {\n      className: a(\n        \"text-text-secondary font-normal my-0\",\n        {\n          xs: \"text-sm\",\n          sm: \"text-sm\",\n          md: \"text-base\",\n          lg: \"text-base\"\n        }[s]\n      ),\n      children: g\n    }\n  );\n  return g ? /* @__PURE__ */ t(\"div\", { className: d, children: [\n    /* @__PURE__ */ t(\"div\", { children: [\n      e && r === \"left\" && /* @__PURE__ */ t(\"div\", { className: a(\"flex items-center\", m[s]), children: [\n        e,\n        l()\n      ] }),\n      e && r === \"right\" && /* @__PURE__ */ t(\"div\", { className: a(\"flex items-center\", m[s]), children: [\n        l(),\n        e\n      ] }),\n      !e && l()\n    ] }),\n    i()\n  ] }) : /* @__PURE__ */ t(\"div\", { className: d, children: [\n    e && r === \"left\" && /* @__PURE__ */ t(\"div\", { className: a(\"flex items-center\", m[s]), children: [\n      e,\n      l()\n    ] }),\n    e && r === \"right\" && /* @__PURE__ */ t(\"div\", { className: a(\"flex items-center\", m[s]), children: [\n      l(),\n      e\n    ] }),\n    !e && l()\n  ] });\n};\nexport {\n  C as Title,\n  C as default\n};\n//# sourceMappingURL=title.es.js.map\n","import React from 'react';\nimport {\n    Title\n} from '@bsf/force-ui';\nimport { __ } from '@wordpress/i18n'; \n\nconst HeaderLine = () => {\n\treturn (\n        <Title\n            className=\"hfe-header-title m-4\"\n            description=\"\"\n            icon={null}\n            iconPosition=\"right\"\n            size=\"xs\"\n            tag=\"h6\"\n            // title={__('Formerly Elementor Header & Footer Builder', 'uael')}\n        />\n\t);\n};\n\nexport default HeaderLine;\n","import { jsx as b } from \"react/jsx-runtime\";\nimport { cn as p } from \"../../utilities/functions.es.js\";\nimport { forwardRef as u } from \"react\";\nconst c = u(\n  ({\n    children: e = null,\n    tag: l = \"label\",\n    size: r = \"sm\",\n    // xs, sm, md\n    className: a = \"\",\n    variant: t = \"neutral\",\n    // neutral, help, error, disabled\n    required: o = !1,\n    ...d\n  }, f) => {\n    const i = \"font-medium text-field-label flex items-center gap-0.5\", n = {\n      xs: \"text-xs [&>*]:text-xs [&>svg]:h-3 [&>svg]:w-3\",\n      sm: \"text-sm [&>*]:text-sm [&>svg]:h-4 [&>svg]:w-4\",\n      md: \"text-base [&>*]:text-base [&>svg]:h-5 [&>svg]:w-5\"\n    }, x = {\n      neutral: \"text-field-label [&>*]:text-field-label\",\n      help: \"text-field-helper [&>*]:text-field-helper\",\n      error: \"text-support-error [&>*]:text-support-error\",\n      disabled: \"text-field-color-disabled disabled cursor-not-allowed [&>*]:text-field-color-disabled\"\n    }, m = {\n      neutral: \"\",\n      help: \"font-normal\",\n      error: \"font-normal\",\n      disabled: \"\"\n    };\n    if (!e)\n      return null;\n    let s = \"\";\n    return o && (s = \"after:content-['*'] after:text-field-required after:ml-0.5\"), /* @__PURE__ */ b(\n      l,\n      {\n        ref: f,\n        className: p(\n          i,\n          n[r],\n          x[t],\n          s,\n          m?.[t],\n          a\n        ),\n        ...d,\n        children: e\n      }\n    );\n  }\n);\nc.displayName = \"Label\";\nexport {\n  c as default\n};\n//# sourceMappingURL=label.es.js.map\n","import { jsx as a, jsxs as d } from \"react/jsx-runtime\";\nimport { forwardRef as A, useMemo as C, useState as E, useCallback as F, isValidElement as H } from \"react\";\nimport { nanoid as I } from \"nanoid\";\nimport { cn as t } from \"../../utilities/functions.es.js\";\nimport N from \"../label/label.es.js\";\nconst M = ({\n  label: e,\n  switchId: g,\n  disabled: r = !1,\n  children: c,\n  size: s\n}) => {\n  const o = {\n    xs: \"text-xs leading-4 font-medium\",\n    sm: \"text-sm leading-5 font-medium\",\n    md: \"text-base leading-6 font-medium\"\n  }, h = {\n    xs: \"text-xs leading-4 font-normal\",\n    sm: \"text-sm leading-5 font-normal\",\n    md: \"text-sm leading-5 font-normal\"\n  }, f = {\n    xs: \"space-y-0.5\",\n    sm: \"space-y-0.5\",\n    md: \"space-y-1\"\n  };\n  if (H(e))\n    return /* @__PURE__ */ d(\n      \"div\",\n      {\n        className: t(\"inline-flex items-center gap-3\", \"items-start\"),\n        children: [\n          c,\n          e\n        ]\n      }\n    );\n  const u = () => {\n    const { heading: n = \"\", description: l = \"\" } = e || {};\n    return /* @__PURE__ */ d(\"div\", { className: t(\"space-y-0.5\", f[s]), children: [\n      n && /* @__PURE__ */ a(\n        N,\n        {\n          htmlFor: g,\n          className: t(\"m-0\", o[s]),\n          ...r && { variant: \"disabled\" },\n          children: n\n        }\n      ),\n      l && /* @__PURE__ */ a(\n        N,\n        {\n          tag: \"p\",\n          variant: \"help\",\n          className: t(\n            \"text-sm font-normal leading-5 m-0\",\n            h[s]\n          ),\n          ...r && { variant: \"disabled\" },\n          children: l\n        }\n      )\n    ] });\n  }, p = !e?.heading && !e?.description, i = !e?.heading || !e?.description ? \"items-center\" : \"items-start\";\n  return p ? c : /* @__PURE__ */ d(\"div\", { className: t(\"inline-flex\", i, \"gap-3\"), children: [\n    c,\n    u()\n  ] });\n}, R = ({\n  id: e,\n  onChange: g,\n  value: r,\n  defaultValue: c = !1,\n  size: s = \"sm\",\n  disabled: o = !1,\n  label: h = { heading: \"\", description: \"\" },\n  name: f,\n  className: b,\n  ...u\n}, p) => {\n  const i = s === \"lg\" ? \"md\" : s, n = C(() => typeof r < \"u\", [r]), l = C(() => e || `switch-${I()}`, []), [w, D] = E(c), m = \"primary\", z = F(\n    () => n ? r : w,\n    [n, r, w]\n  ), L = (j) => {\n    if (o)\n      return;\n    const y = j.target.checked;\n    n || D(y), typeof g == \"function\" && g(y);\n  }, x = {\n    primary: {\n      input: \"bg-toggle-off checked:bg-toggle-on focus:ring focus:ring-toggle-on focus:ring-offset-2 border border-solid border-toggle-off-border checked:border-toggle-on-border shadow-toggleContainer focus:outline-none checked:focus:border-toggle-on-border focus:border-toggle-off-border\",\n      toggleDial: \"bg-toggle-dial-background shadow-toggleDial\"\n    }\n  }, S = {\n    primary: {\n      input: \"group-hover/switch:bg-toggle-off-hover checked:group-hover/switch:bg-toggle-on-hover checked:group-hover/switch:border-toggle-on-border\"\n    }\n  }, v = {\n    md: {\n      container: \"w-11 h-6\",\n      toggleDial: \"size-4 peer-checked:translate-x-5\"\n    },\n    sm: {\n      container: \"w-10 h-5\",\n      toggleDial: \"size-3 peer-checked:translate-x-5\"\n    },\n    xs: {\n      container: \"w-8 h-4\",\n      toggleDial: \"size-2.5 peer-checked:translate-x-3.75\"\n    }\n  }, V = {\n    md: \"group-hover/switch:size-5 group-focus-within/switch:size-5 not-rtl:group-focus-within/switch:left-0.5 rtl:group-focus-within/switch:right-0.5 not-rtl:group-hover/switch:left-0.5 rtl:group-hover/switch:right-0.5\",\n    sm: \"group-hover/switch:size-4 group-focus-within/switch:size-4 not-rtl:group-focus-within/switch:left-0.5 rtl:group-focus-within/switch:right-0.5 not-rtl:group-hover/switch:left-0.5 rtl:group-hover/switch:right-0.5\",\n    xs: \"group-hover/switch:size-3.25 group-focus-within/switch:size-3.25 not-rtl:group-focus-within/switch:left-0.5 rtl:group-focus-within/switch:right-0.5 not-rtl:group-hover/switch:left-0.5 rtl:group-hover/switch:right-0.5\"\n  }, k = {\n    input: \"bg-toggle-off-disabled disabled:border-transparent disabled:cursor-not-allowed checked:disabled:bg-toggle-on-disabled disabled:shadow-toggle-disabled\",\n    toggleDial: \"peer-disabled:cursor-not-allowed\"\n  };\n  return /* @__PURE__ */ a(\n    M,\n    {\n      label: h,\n      switchId: l,\n      disabled: o,\n      size: i,\n      children: /* @__PURE__ */ d(\n        \"div\",\n        {\n          className: t(\n            \"relative group/switch inline-block cursor-pointer rounded-full shrink-0\",\n            v[i].container,\n            b\n          ),\n          children: [\n            /* @__PURE__ */ a(\n              \"input\",\n              {\n                ref: p,\n                id: l,\n                type: \"checkbox\",\n                className: t(\n                  \"peer appearance-none absolute rounded-full cursor-pointer transition-colors duration-300 h-full w-full  before:content-[''] checked:before:content-[''] m-0 checked:[background-image:none]\",\n                  x[m].input,\n                  o && k.input,\n                  !o && S[m].input\n                ),\n                checked: z(),\n                onChange: L,\n                disabled: o,\n                name: f,\n                ...u\n              }\n            ),\n            /* @__PURE__ */ a(\n              \"label\",\n              {\n                htmlFor: l,\n                className: t(\n                  \"peer/toggle-dial bg-white border rounded-full absolute cursor-pointer shadow-md before:content[''] before:transition-opacity before:opacity-0 hover:before:opacity-10 before:hidden border-none transition-all duration-300 top-2/4 not-rtl:left-1 rtl:right-1 -translate-y-2/4 before:w-10 before:h-10 before:rounded-full before:absolute before:top-2/4 not-rtl:before:left-2/4 rtl:before:right-2/4 before:-translate-y-2/4 before:-translate-x-2/4\",\n                  v[i].toggleDial,\n                  x[m].toggleDial,\n                  o && k.toggleDial,\n                  !o && V[i]\n                )\n              }\n            )\n          ]\n        }\n      )\n    }\n  );\n}, $ = A(R);\n$.displayName = \"Switch\";\nexport {\n  R as SwitchComponent,\n  M as SwitchLabel,\n  $ as default\n};\n//# sourceMappingURL=switch.es.js.map\n","/* @ts-self-types=\"./index.d.ts\" */\nimport { urlAlphabet as scopedUrlAlphabet } from './url-alphabet/index.js'\nexport { urlAlphabet } from './url-alphabet/index.js'\nexport let random = bytes => crypto.getRandomValues(new Uint8Array(bytes))\nexport let customRandom = (alphabet, defaultSize, getRandom) => {\n  let mask = (2 << Math.log2(alphabet.length - 1)) - 1\n  let step = -~((1.6 * mask * defaultSize) / alphabet.length)\n  return (size = defaultSize) => {\n    let id = ''\n    while (true) {\n      let bytes = getRandom(step)\n      let j = step | 0\n      while (j--) {\n        id += alphabet[bytes[j] & mask] || ''\n        if (id.length >= size) return id\n      }\n    }\n  }\n}\nexport let customAlphabet = (alphabet, size = 21) =>\n  customRandom(alphabet, size | 0, random)\nexport let nanoid = (size = 21) => {\n  let id = ''\n  let bytes = crypto.getRandomValues(new Uint8Array((size |= 0)))\n  while (size--) {\n    id += scopedUrlAlphabet[bytes[size] & 63]\n  }\n  return id\n}\n","export const urlAlphabet =\n  'useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict'\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Info = createLucideIcon(\"Info\", [\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n  [\"path\", { d: \"M12 16v-4\", key: \"1dtifu\" }],\n  [\"path\", { d: \"M12 8h.01\", key: \"e9boi3\" }]\n]);\n\nexport { Info as default };\n//# sourceMappingURL=info.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Check = createLucideIcon(\"Check\", [[\"path\", { d: \"M20 6 9 17l-5-5\", key: \"1gmf2c\" }]]);\n\nexport { Check as default };\n//# sourceMappingURL=check.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst TriangleAlert = createLucideIcon(\"TriangleAlert\", [\n  [\n    \"path\",\n    {\n      d: \"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3\",\n      key: \"wmoenq\"\n    }\n  ],\n  [\"path\", { d: \"M12 9v4\", key: \"juzpu7\" }],\n  [\"path\", { d: \"M12 17h.01\", key: \"p32p05\" }]\n]);\n\nexport { TriangleAlert as default };\n//# sourceMappingURL=triangle-alert.js.map\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Trash2 = createLucideIcon(\"Trash2\", [\n  [\"path\", { d: \"M3 6h18\", key: \"d0wm0j\" }],\n  [\"path\", { d: \"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6\", key: \"4alrt4\" }],\n  [\"path\", { d: \"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2\", key: \"v07s0e\" }],\n  [\"line\", { x1: \"10\", x2: \"10\", y1: \"11\", y2: \"17\", key: \"1uufr5\" }],\n  [\"line\", { x1: \"14\", x2: \"14\", y1: \"11\", y2: \"17\", key: \"xtxkd\" }]\n]);\n\nexport { Trash2 as default };\n//# sourceMappingURL=trash-2.js.map\n","import { jsxs as z, jsx as o } from \"react/jsx-runtime\";\nimport { forwardRef as j, Fragment as l } from \"react\";\nimport { cn as B } from \"../../utilities/functions.es.js\";\nconst R = j(\n  (u, b) => {\n    const {\n      variant: n = \"primary\",\n      // primary, secondary, outline, ghost, link\n      size: g = \"md\",\n      // xs, sm, md, lg\n      type: c = \"button\",\n      tag: h = \"button\",\n      className: m,\n      children: r,\n      disabled: t = !1,\n      destructive: s = !1,\n      // true, false\n      icon: e = null,\n      // icon component\n      iconPosition: v = \"left\",\n      // left, right,\n      loading: f = !1,\n      ...p\n    } = u, x = \"outline outline-1 border-none cursor-pointer transition-colors duration-300 ease-in-out text-xs font-semibold focus:ring-2 focus:ring-toggle-on focus:ring-offset-2 disabled:text-text-disabled\", y = s && \"focus:ring-focus-error\", w = f ? \"opacity-50 disabled:cursor-not-allowed\" : \"\", N = {\n      primary: \"text-text-on-color bg-button-primary hover:bg-button-primary-hover outline-button-primary hover:outline-button-primary-hover shadow-xs disabled:shadow-none focus:shadow-none disabled:bg-button-disabled disabled:outline-button-disabled\",\n      secondary: \"text-text-on-color bg-button-secondary hover:bg-button-secondary-hover outline-button-secondary hover:outline-button-secondary-hover shadow-xs focus:shadow-none disabled:shadow-none disabled:bg-button-disabled disabled:outline-button-disabled\",\n      outline: \"text-button-tertiary-color outline-border-subtle bg-button-tertiary shadow-sm focus:shadow-none hover:bg-button-tertiary-hover hover:outline-border-subtle disabled:bg-button-tertiary disabled:outline-border-disabled\",\n      ghost: \"text-text-primary bg-transparent outline-transparent hover:bg-button-tertiary-hover\",\n      link: \"outline-none text-link-primary bg-transparent hover:text-link-primary-hover hover:underline p-0 border-0 leading-none\"\n    }[n], C = s && !t ? {\n      primary: \"bg-button-danger hover:bg-button-danger-hover outline-button-danger hover:outline-button-danger-hover\",\n      secondary: \"bg-button-danger hover:bg-button-danger-hover outline-button-danger hover:outline-button-danger-hover\",\n      outline: \"text-button-danger outline outline-1 outline-button-danger hover:outline-button-danger bg-button-tertiary hover:bg-field-background-error\",\n      ghost: \"text-button-danger hover:bg-field-background-error\",\n      link: \"text-button-danger hover:text-button-danger-secondary\"\n    }[n] : \"\", k = {\n      xs: \"p-1 rounded [&>svg]:size-4\",\n      sm: \"p-2 rounded [&>svg]:size-4 gap-0.5\",\n      md: \"p-2.5 rounded-md text-sm [&>svg]:size-5 gap-1\",\n      lg: \"p-3 rounded-lg text-base [&>svg]:size-6 gap-1\"\n    }[g];\n    let a, i = null, d = \"\";\n    return e && (d = \"flex items-center justify-center\", v === \"left\" ? a = e : i = e), /* @__PURE__ */ z(\n      h,\n      {\n        ref: b,\n        type: c,\n        className: B(\n          d,\n          x,\n          k,\n          N,\n          C,\n          y,\n          w,\n          {\n            \"cursor-default\": t\n          },\n          m\n        ),\n        disabled: t,\n        ...p,\n        children: [\n          /* @__PURE__ */ o(l, { children: a }, \"left-icon\"),\n          r ? /* @__PURE__ */ o(\"span\", { className: \"px-1\", children: r }) : null,\n          /* @__PURE__ */ o(l, { children: i }, \"right-icon\")\n        ]\n      }\n    );\n  }\n);\nR.displayName = \"Button\";\nexport {\n  R as default\n};\n//# sourceMappingURL=button.es.js.map\n","import { jsx as a } from \"react/jsx-runtime\";\nimport { isValidElement as m, cloneElement as x } from \"react\";\nimport { Info as c, Check as g, AlertTriangle as f, Trash2 as d } from \"lucide-react\";\nimport { cn as n } from \"../../utilities/functions.es.js\";\nimport u from \"../button/button.es.js\";\nconst l = \"light\", p = \"neutral\", v = \"button\", h = ({\n  theme: t = l,\n  variant: r = p\n}) => {\n  let e = t === \"light\" ? \"text-icon-secondary\" : \"text-icon-inverse\";\n  return e = {\n    info: t === \"light\" ? \"text-support-info\" : \"text-support-info-inverse\",\n    success: t === \"light\" ? \"text-support-success\" : \"text-support-success-inverse\",\n    warning: t === \"light\" ? \"text-support-warning\" : \"text-support-warning-inverse\",\n    error: t === \"light\" ? \"text-support-error\" : \"text-support-error-inverse\"\n  }[r] || e, e;\n}, E = ({\n  icon: t,\n  theme: r = l,\n  variant: e = p\n}) => {\n  const s = \"[&>svg]:h-5 [&>svg]:w-5\", o = h({ theme: r, variant: e });\n  if (t && m(t))\n    return x(t, {\n      className: n(\n        s,\n        o,\n        t?.props?.className ?? \"\"\n      )\n    });\n  const i = {\n    neutral: /* @__PURE__ */ a(c, { className: n(s, o) }),\n    info: /* @__PURE__ */ a(c, { className: n(s, o) }),\n    success: /* @__PURE__ */ a(g, { className: n(s, o) }),\n    warning: /* @__PURE__ */ a(f, { className: n(s, o) }),\n    error: /* @__PURE__ */ a(d, { className: n(s, o) })\n  };\n  return i[e] || i.neutral;\n}, y = ({\n  actionType: t = v,\n  onAction: r = () => {\n  },\n  actionLabel: e = \"\",\n  theme: s = l\n}) => {\n  const o = \"focus:ring-0 focus:ring-offset-0 ring-offset-0 focus:outline-none\";\n  let i = \"text-button-primary border-button-primary hover:border-button-primary hover:text-button-primary-hover\";\n  switch (s === \"dark\" && (i = \"text-text-inverse border-text-inverse hover:border-text-inverse hover:text-text-inverse\"), t) {\n    case \"button\":\n      return /* @__PURE__ */ a(\n        u,\n        {\n          variant: \"outline\",\n          size: \"xs\",\n          onClick: r,\n          className: n(\n            \"rounded\",\n            o,\n            i,\n            s === \"dark\" ? \"bg-transparent hover:bg-transparent\" : \"bg-white hover:bg-white\"\n          ),\n          children: e\n        }\n      );\n    case \"link\":\n      return /* @__PURE__ */ a(\n        u,\n        {\n          variant: \"link\",\n          size: \"xs\",\n          onClick: r,\n          className: n(o, i),\n          children: e\n        }\n      );\n    default:\n      return null;\n  }\n}, A = ({\n  theme: t = l,\n  title: r = \"\",\n  inline: e = !1\n}) => r ? /* @__PURE__ */ a(\n  \"span\",\n  {\n    className: n(\n      \"block\",\n      {\n        light: \"text-text-primary\",\n        dark: \"text-text-inverse\"\n      }[t],\n      \"text-sm leading-5 font-semibold\",\n      e ? \"inline\" : \"block\"\n    ),\n    children: r\n  }\n) : null, I = ({\n  theme: t = l,\n  content: r = \"\",\n  inline: e = !1\n}) => r ? /* @__PURE__ */ a(\n  \"span\",\n  {\n    className: n(\n      {\n        light: \"text-text-primary\",\n        dark: \"text-text-inverse\"\n      }[t],\n      \"block text-sm [&_*]:text-sm leading-5 [&_*]:leading-5 font-normal [word-break:break-word]\",\n      e ? \"inline\" : \"block\"\n    ),\n    children: r\n  }\n) : null, _ = (...t) => (r) => {\n  t.forEach((e) => {\n    typeof e == \"function\" ? e(r) : e && (e.current = r);\n  });\n};\nexport {\n  y as getAction,\n  I as getContent,\n  E as getIcon,\n  h as getIconColor,\n  A as getTitle,\n  _ as mergeRefs\n};\n//# sourceMappingURL=utils.es.js.map\n","import { jsxs as i, jsx as t } from \"react/jsx-runtime\";\nimport { useMemo as U, useState as V, useRef as q, Fragment as g, isValidElement as B, cloneElement as G } from \"react\";\nimport { useFloating as J, offset as K, flip as L, shift as Q, arrow as W, autoUpdate as X, useClick as Y, useHover as Z, safePolygon as _, useFocus as $, useDismiss as ee, useRole as oe, useInteractions as te, useTransitionStyles as se, FloatingPortal as le, FloatingArrow as ne } from \"@floating-ui/react\";\nimport { cn as r } from \"../../utilities/functions.es.js\";\nimport { mergeRefs as ae } from \"../toaster/utils.es.js\";\nconst ie = ({\n  variant: c = \"dark\",\n  // 'light' | 'dark';\n  placement: h = \"bottom\",\n  //  | 'top' | 'top-start' | 'top-end' | 'right' | 'right-start' | 'right-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'left-start' | 'left-end';\n  title: d = \"\",\n  content: f,\n  arrow: x = !1,\n  open: l,\n  setOpen: n,\n  children: s,\n  className: w,\n  tooltipPortalRoot: b,\n  // Root element where the dropdown will be rendered.\n  tooltipPortalId: k,\n  // Id of the dropdown portal where the dropdown will be rendered.\n  boundary: p = \"clippingAncestors\",\n  strategy: y = \"fixed\",\n  // 'fixed' | 'absolute';\n  offset: C = 8,\n  // Offset option or number value. Default is 8.\n  triggers: a = [\"hover\", \"focus\"],\n  // 'click' | 'hover' | 'focus';\n  interactive: v = !1\n}) => {\n  const o = U(\n    () => typeof l == \"boolean\" && typeof n == \"function\",\n    [l, n]\n  ), [F, N] = V(!1), m = q(null), { refs: u, floatingStyles: R, context: e } = J({\n    open: o ? l : F,\n    onOpenChange: o ? n : N,\n    placement: h,\n    strategy: y,\n    middleware: [\n      K(C),\n      L({ boundary: p }),\n      // Ensure this is correctly cast\n      Q({ boundary: p }),\n      // Ensure this is correctly cast\n      W({ element: m })\n    ],\n    whileElementsMounted: X\n  }), P = Y(e, {\n    enabled: !o && a.includes(\"click\")\n  }), E = Z(e, {\n    move: !1,\n    enabled: !o && a.includes(\"hover\"),\n    ...v && { handleClose: _() }\n  }), M = $(e, {\n    enabled: !o && a.includes(\"focus\")\n  }), S = ee(e), T = oe(e, { role: \"tooltip\" }), { getReferenceProps: j, getFloatingProps: A } = te([\n    P,\n    E,\n    M,\n    S,\n    T\n  ]), { isMounted: I, styles: z } = se(e, {\n    duration: 150,\n    initial: { opacity: 0 },\n    open: { opacity: 1 },\n    close: { opacity: 0 }\n  }), D = \"absolute z-20 py-2 px-3 rounded-md text-xs leading-4 shadow-soft-shadow-lg\", H = {\n    light: \"bg-tooltip-background-light text-text-primary\",\n    dark: \"bg-tooltip-background-dark text-text-on-color\"\n  }[c], O = c === \"dark\" ? \"text-tooltip-background-dark\" : \"text-tooltip-background-light\";\n  return /* @__PURE__ */ i(g, { children: [\n    B(s) && /* @__PURE__ */ t(g, { children: G(s, {\n      ref: ae(\n        s.ref,\n        u.setReference\n      ),\n      className: r(s.props.className),\n      ...j()\n    }) }, \"tooltip-reference\"),\n    /* @__PURE__ */ t(le, { id: k, root: b, children: I && /* @__PURE__ */ i(\n      \"div\",\n      {\n        className: r(\n          D,\n          H,\n          \"max-w-80 w-fit\",\n          w\n        ),\n        ref: u.setFloating,\n        style: {\n          ...R,\n          ...z\n        },\n        ...A(),\n        children: [\n          /* @__PURE__ */ i(\"div\", { children: [\n            !!d && /* @__PURE__ */ t(\n              \"span\",\n              {\n                className: \"font-semibold\",\n                children: d\n              },\n              \"tooltip-title\"\n            ),\n            !!f && /* @__PURE__ */ t(\n              \"div\",\n              {\n                className: \"font-normal\",\n                children: f\n              },\n              \"tooltip-content\"\n            )\n          ] }),\n          x && /* @__PURE__ */ t(\n            ne,\n            {\n              ref: m,\n              context: e,\n              className: r(\"fill-current\", O)\n            }\n          )\n        ]\n      }\n    ) })\n  ] });\n};\nie.displayName = \"Tooltip\";\nexport {\n  ie as Tooltip,\n  ie as default\n};\n//# sourceMappingURL=tooltip.es.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Info = createLucideIcon(\"Info\", [\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n  [\"path\", { d: \"M12 16v-4\", key: \"1dtifu\" }],\n  [\"path\", { d: \"M12 8h.01\", key: \"e9boi3\" }]\n]);\n\nexport { Info as default };\n//# sourceMappingURL=info.js.map\n","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"wp\"][\"apiFetch\"];","import React, { useEffect, useState } from 'react'\nimport { Container, Switch, Tooltip, Skeleton } from \"@bsf/force-ui\";\nimport { InfoIcon, FileText } from 'lucide-react';\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\n\n// Create a queue to manage AJAX requests\nconst requestQueue = [];\n\nconst processQueue = () => {\n    if (requestQueue.length === 0) return;\n\n    // Take the first item from the queue and run it\n    const currentRequest = requestQueue.shift();\n    currentRequest();\n};\n\nconst WidgetItem = ({\n    widget,\n    updateCounter,\n    showTooltip\n}) => {\n    const {\n        id,\n        icon,\n        title,\n        infoText,\n        is_pro,\n        is_active,\n        slug,\n        demo_url,\n        doc_url,\n        description\n    } = widget;\n\n    // Track the active state of the widget using React state\n    const [isActive, setIsActive] = useState(widget.is_active);\n    const [isLoading, setIsLoading] = useState(false);\n\n    useEffect(() => {\n        // Update local state when the widget prop changes\n        setIsActive(widget.is_active);\n    }, [widget.is_active, updateCounter]);\n\n    const apiCall = (activateWidget) => {\n        const action = activateWidget ? 'uael_deactivate_widget' : 'uael_activate_widget';\n\n        const formData = new window.FormData();\n        formData.append('action', action);\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n        formData.append('module_id', id);\n        formData.append('is_pro', is_pro);\n\n        try {\n            const data = apiFetch({\n                url: uaelSettingsData.ajax_url,\n                method: 'POST',\n                body: formData,\n            });\n\n            if (data.success) {\n                setIsActive(isActive);  // Update the active state after the request\n            } else if (data.error) {\n                // console.log('AJAX request failed');\n            }\n        } catch (err) {\n            // console.log(\"Error during AJAX request\");\n        } finally {\n            setIsLoading(false);  // Always stop the loading spinner\n            processQueue();\n        }\n    }\n\n    const handleSwitchChange = () => {\n        if (isLoading) return;\n\n        setIsLoading(true);\n\n        if (isActive) {\n            // Add the request to the queue\n            setIsActive(false);\n            requestQueue.push(() => apiCall(isActive));\n        } else {\n            // Add the request to the queue\n            setIsActive(true);\n            requestQueue.push(() => apiCall(isActive));\n        }\n        if (requestQueue.length === 1) {\n            // Start processing the queue if no other request is being processed\n            processQueue();\n        }\n    };\n\n    return (\n        <Container align=\"center\"\n            containerType=\"flex\"\n            direction=\"column\"\n            justify=\"between\"\n            gap=\"\"\n        >\n            <div className='flex items-center justify-between w-full'>\n                <div className={`h-10 w-10 mb-5 ${icon?.props}`} style={{ fontSize: '22px' }}>\n                    {icon}\n                </div>\n\n                <div className='flex items-center gap-x-2' style={{ marginBottom: '15px' }}>\n                    <Switch\n                        onChange={handleSwitchChange} // Updated to use the new function\n                        size='sm'\n                        value={isActive}\n                        className=\"uael-remove-ring\"\n                    />\n                </div>\n            </div>\n\n            <div className='flex flex-col w-full'>\n                <p className='text-sm font-medium text-text-primary pt-3 m-0 pb-1'>{__(title, 'uael')}</p>\n                <div className='flex items-center justify-between w-full'>\n                    {!uaelSettingsData.hide_settings && demo_url && (\n                        <a href={demo_url} target=\"_blank\" rel=\"noopener noreferrer\" className='text-sm text-text-tertiary m-0 mb-1 uael-remove-ring' style={{ textDecoration: 'none', lineHeight: '1.5rem' }}>\n                            {__('View Demo', 'uael')}\n                        </a>\n                    )}\n                    {showTooltip && (\n                        <div className={`${!demo_url ? 'uae-tooltip-wrap' : ''}`}>\n                            <Tooltip\n                                arrow\n                                content={\n                                    <div>\n                                        <span className='font-semibold block mb-2'>{__(title, 'uael')}</span>\n                                        <span className='block mb-2'>{__(description, 'uael')}</span>\n                                        {!uaelSettingsData.hide_settings && doc_url && (\n                                            <a href={doc_url} target=\"_blank\" rel=\"noopener noreferrer\" className='cursor-pointer' style={{ color: '#C8AEFF', textDecoration: 'none' }}>\n                                                <FileText style={{ color: '#C8AEFF', width: '11px', height: '11px', marginRight: '3px' }} />\n                                                {__('Read Documentation', 'uael')}\n                                            </a>\n                                        )}\n                                    </div>\n                                }\n                                placement=\"bottom\"\n                                title=\"\"\n                                triggers={[\n                                    'click'\n                                ]}\n                                variant=\"dark\"\n                                size=\"xs\"\n                            >\n                                <InfoIcon className='h-5 w-5' size={18} color=\"#A0A5B2\" />\n                            </Tooltip>\n                        </div>\n                    )}\n                </div>\n            </div>\n        </Container>\n    )\n}\n\nexport default WidgetItem\n","import React, { useState, useEffect } from 'react';\nimport {\n    Title,\n    Button\n} from '@bsf/force-ui';\nimport { __ } from '@wordpress/i18n';\nimport apiFetch from '@wordpress/api-fetch';\n\nconst TemplateSection = () => {\n    \n\tconst [loading, setLoading] = useState(true);\n\tconst [templatesStatus, setTemplatesStatus] = useState(null); \n    const [redirectUrl, setRedirectUrl] = useState(null); \n\n    useEffect(() => {\n        const fetchSettings = () => {\n            setLoading(true);\n            apiFetch({\n                path: '/uael/v1/templates',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action, // Use the correct nonce\n                },\n            })\n                .then((data) => {\n                    setTemplatesStatus(data.templates_status);\n                    if (data.redirect_url) {\n                        setRedirectUrl(data.redirect_url); // Save URL in state variable\n                    }\n                    setLoading(false); // Stop loading\n                })\n                .catch((err) => {\n                    setLoading(false); // Stop loading\n                });\n        };\n\n        fetchSettings();\n    }, []);\n\n    const handleButtonClick = (e) => {\n        if( 'Activated' === templatesStatus && redirectUrl ) {\n            window.open( redirectUrl, '_blank' );\n        }\n    };\n\n\tif( loading ) {\n\t\treturn;\n\t}\n\n    return (\n        <div className=\"box-border hfe-dashboard-templates p-4 bg-white rounded-lg shadow-md mb-6 uae-subheading\">\n            <div className=\"mb-4\">\n                <img\n                    src={`${uaelSettingsData.templates_url}`}\n                    alt=\"Template Showcase\"\n                    className=\"w-full h-auto rounded\"\n                />\n            </div>\n            <Title\n                className=\"mt-2\"\n                icon={null}\n                iconPosition=\"right\"\n                size=\"xs\"\n                tag=\"h2\"\n                title={__('Build Websites 10x Faster with Templates', 'uael')}\n            />\n            <p className='text-text-secondary mt-2 mb-2 text-sm'>{__('Choose from our professionally designed websites to build your site faster, with easy customization options.', 'uael')}</p>\n                    <Button\n                        className=\"w-full mt-4\"\n                        icon={null}\n                        iconPosition=\"left\"\n                        size=\"md\"\n                        variant=\"secondary\"\n                        // onClick={handleButtonClick}\n                        onClick={() => {\n\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\"https://startertemplates.com/\",\n\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}}\n                    >\n                        {__('Explore Templates', 'uael')}\n                    </Button>\n        </div>\n    );\n};\n\nexport default TemplateSection;","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Headphones = createLucideIcon(\"Headphones\", [\n  [\n    \"path\",\n    {\n      d: \"M3 14h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-7a9 9 0 0 1 18 0v7a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3\",\n      key: \"1xhozi\"\n    }\n  ]\n]);\n\nexport { Headphones as default };\n//# sourceMappingURL=headphones.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst NotepadText = createLucideIcon(\"NotepadText\", [\n  [\"path\", { d: \"M8 2v4\", key: \"1cmpym\" }],\n  [\"path\", { d: \"M12 2v4\", key: \"3427ic\" }],\n  [\"path\", { d: \"M16 2v4\", key: \"4m81vk\" }],\n  [\"rect\", { width: \"16\", height: \"18\", x: \"4\", y: \"4\", rx: \"2\", key: \"1u9h20\" }],\n  [\"path\", { d: \"M8 10h6\", key: \"3oa6kw\" }],\n  [\"path\", { d: \"M8 14h8\", key: \"1fgep2\" }],\n  [\"path\", { d: \"M8 18h5\", key: \"17enja\" }]\n]);\n\nexport { NotepadText as default };\n//# sourceMappingURL=notepad-text.js.map\n","import React from \"react\";\nimport { Title, Container, Button } from \"@bsf/force-ui\";\nimport { Headphones, NotepadText, HelpCircle, StarIcon } from \"lucide-react\";\nimport { __ } from \"@wordpress/i18n\";\n\nconst QuickAccess = () => {\n\treturn (\n\t\t<div\n\t\t\tclassName=\"box-border hfe-dashboard-quick-access p-4 bg-white rounded-lg shadow-md\"\n\t\t\tstyle={{\n\t\t\t\twidth: \"-webkit-fill-available\",\n\t\t\t}}\n\t\t>\n\t\t\t<Title\n\t\t\t\tclassName=\"mb-2\"\n\t\t\t\ticon={null}\n\t\t\t\ticonPosition=\"right\"\n\t\t\t\tsize=\"xs\"\n\t\t\t\ttag=\"h3\"\n\t\t\t\ttitle={__(\"Quick Access\", \"uael\")}\n\t\t\t/>\n\n\t\t\t<Container\n\t\t\t\talign=\"stretch\"\n\t\t\t\tclassName=\"p-1 rounded-lg bg-[#F9FAFB] gap-1\"\n\t\t\t\tcontainerType=\"flex\"\n\t\t\t\tdirection=\"column\"\n\t\t\t\tgap=\"\"\n\t\t\t\tjustify=\"start\"\n\t\t\t\tstyle={{\n\t\t\t\t\twidth: \"100%\",\n\t\t\t\t\tbackgroundColor: \"#F9FAFB\",\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<Container.Item\n\t\t\t\t\talignSelf=\"auto\"\n\t\t\t\t\tclassName=\"p-4 bg-white rounded-lg shadow-container-item\"\n\t\t\t\t\torder=\"none\"\n\t\t\t\t\tshrink={1}\n\t\t\t\t>\n\t\t\t\t\t<Button\n\t\t\t\t\t\tclassName=\"text-black uael-remove-ring\"\n\t\t\t\t\t\ticon={<Headphones />}\n\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\tvariant=\"link\"\n\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\"https://store.brainstormforce.com/support/\",\n\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}}\n\t\t\t\t\t>\n\t\t\t\t\t\t{__(\"VIP Priority Support\", \"uael\")}\n\t\t\t\t\t</Button>\n\t\t\t\t</Container.Item>\n\t\t\t\t<Container.Item\n\t\t\t\t\talignSelf=\"auto\"\n\t\t\t\t\tclassName=\"p-4 bg-white rounded-lg shadow-container-item\"\n\t\t\t\t\torder=\"none\"\n\t\t\t\t\tshrink={1}\n\t\t\t\t>\n\t\t\t\t\t<Button\n\t\t\t\t\t\tclassName=\"text-black uael-remove-ring\"\n\t\t\t\t\t\ticon={<Headphones />}\n\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\tvariant=\"link\"\n\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs/getting-started-uael/\",\n\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}}\n\t\t\t\t\t>\n\t\t\t\t\t\t{__(\"Knowledge Base\", \"uael\")}\n\t\t\t\t\t</Button>\n\t\t\t\t</Container.Item>\n\t\t\t\t<Container.Item className=\"p-4 bg-white rounded-lg shadow-container-item\">\n\t\t\t\t\t<Button\n\t\t\t\t\t\tclassName=\"text-black uael-remove-ring\"\n\t\t\t\t\t\ticon={<HelpCircle />}\n\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\tvariant=\"link\"\n\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs/\",\n\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}}\n\t\t\t\t\t>\n\t\t\t\t\t\t{__(\"Help Centre\", \"uael\")}\n\t\t\t\t\t</Button>\n\t\t\t\t</Container.Item>\n\t\t\t\t{/* <Container.Item className=\"p-4 bg-white rounded-lg shadow-container-item\">\n\t\t\t\t\t<Button\n\t\t\t\t\t\tclassName=\"text-black uael-remove-ring\"\n\t\t\t\t\t\ticon={<StarIcon />}\n\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\tvariant=\"link\"\n\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\"https://wordpress.org/support/plugin/header-footer-elementor/reviews/#new-post\",\n\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}}\n\t\t\t\t\t>\n\t\t\t\t\t\t{__(\"Rate Us\", \"uael\")}\n\t\t\t\t\t</Button>\n\t\t\t\t</Container.Item> */}\n\t\t\t\t<Container.Item className=\"p-4 bg-white rounded-lg shadow-container-item\">\n\t\t\t\t\t<Button\n\t\t\t\t\t\tclassName=\"text-black uael-remove-ring\"\n\t\t\t\t\t\ticon={<NotepadText />}\n\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\tvariant=\"link\"\n\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\"https://ideas.ultimateelementor.com/boards/feature-requests\",\n\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}}\n\t\t\t\t\t>\n\t\t\t\t\t\t{__(\"Request a Feature\", \"uael\")}\n\t\t\t\t\t</Button>\n\t\t\t\t</Container.Item>\n\t\t\t</Container>\n\t\t</div>\n\t);\n};\n\nexport default QuickAccess;\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Plus = createLucideIcon(\"Plus\", [\n  [\"path\", { d: \"M5 12h14\", key: \"1ays0h\" }],\n  [\"path\", { d: \"M12 5v14\", key: \"s699le\" }]\n]);\n\nexport { Plus as default };\n//# sourceMappingURL=plus.js.map\n","import React from \"react\";\nimport { Container, Title, Button } from \"@bsf/force-ui\";\nimport { ExternalLink, Plus } from \"lucide-react\";\nimport { __ , sprintf } from \"@wordpress/i18n\";\n\nconst WelcomeContainer = () => {\n\treturn (\n\t\t<div>\n\t\t\t<Container\n\t\t\t\talign=\"center\"\n\t\t\t\tclassName=\"bg-background-primary border-[0.5px] border-subtle rounded-xl shadow-sm mb-6 p-8 flex flex-col lg:flex-row\"\n\t\t\t\tcontainerType=\"flex\"\n\t\t\t\tdirection=\"row\"\n\t\t\t\tgap=\"sm\"\n\t\t\t>\n\t\t\t\t<Container.Item shrink={1}>\n\t\t\t\t\t<Title\n\t\t\t\t\t\tdescription=\"\"\n\t\t\t\t\t\ticon={null}\n\t\t\t\t\t\ticonPosition=\"right\"\n\t\t\t\t\t\tclassName=\"max-w-lg\"\n\t\t\t\t\t\tsize=\"lg\"\n\t\t\t\t\t\ttag=\"h3\"\n\t\t\t\t\t\ttitle={__(\"Hello,\", \"uael\")}\n\t\t\t\t\t/>\n\t\t\t\t\t<p className=\"text-sm font-medium text-text-tertiary m-0 mt-2\">\n\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\"Effortlessly design modern websites with \" +\n\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name +\n\t\t\t\t\t\t\t\t\" using our powerful range of widgets & features. Get started by selecting an option based on your needs.\",\n\t\t\t\t\t\t\t\"uael\"\n\t\t\t\t\t\t)}\n\t\t\t\t\t</p>\n\t\t\t\t\t<div className=\"flex items-center pt-6 gap-2\">\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tuaelSettingsData.is_lite_active ? (\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\t\ticonPosition=\"right\"\n\t\t\t\t\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\t\t\t\t\tclassName=\"bg-[#6005FF] uael-remove-ring\"\n\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\tbackgroundColor: \"#6005FF\",\n\t\t\t\t\t\t\t\t\t\t\ttransition: \"background-color 0.3s ease\",\n\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\t\t\"#4B00CC\")\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\t\t\"#6005FF\")\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\t\t\t\tuaelSettingsData.uael_hfe_post_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{__(\"Create Header/Footer\", \"uael\")}\n\t\t\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\t\ticon={<Plus />}\n\t\t\t\t\t\t\t\t\t\ticonPosition=\"right\"\n\t\t\t\t\t\t\t\t\t\t// variant=\"primary\"\n\t\t\t\t\t\t\t\t\t\tclassName=\"text-[#6005FF] uael-remove-ring\"\n\t\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\t\tbackgroundColor: \"#DDD6FE\",\n\t\t\t\t\t\t\t\t\t\t\toutline: \"none\",\n\t\t\t\t\t\t\t\t\t\t\t// border: \"none\",\n\t\t\t\t\t\t\t\t\t\t\ttransition: \"background-color 0.3s ease\",\n\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\t\t\"#DDD6FE\")\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\t\t\"#DDD6FE\")\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\t\t\t\tuaelSettingsData.elementor_page_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{__(\"Create New Page\", \"uael\")}\n\t\t\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t) : \n\t\t\t\t\t\t\t(\n\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\ticon={<Plus />}\n\t\t\t\t\t\t\t\t\ticonPosition=\"right\"\n\t\t\t\t\t\t\t\t\t// variant=\"primary\"\n\t\t\t\t\t\t\t\t\tclassName=\"text-[#6005FF] uael-remove-ring\"\n\t\t\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\t\t\tbackgroundColor: \"#DDD6FE\",\n\t\t\t\t\t\t\t\t\t\toutline: \"none\",\n\t\t\t\t\t\t\t\t\t\t// border: \"none\",\n\t\t\t\t\t\t\t\t\t\ttransition: \"background-color 0.3s ease\",\n\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\t\"#DDD6FE\")\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\t\"#DDD6FE\")\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\t\t\tuaelSettingsData.elementor_page_url,\n\t\t\t\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t{__(\"Create New Page\", \"uael\")}\n\t\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\tcolor: \"black\",\n\t\t\t\t\t\t\t\tbackground: \"none\",\n\t\t\t\t\t\t\t\tborder: \"none\",\n\t\t\t\t\t\t\t\tpadding: 0,\n\t\t\t\t\t\t\t\tcursor: \"pointer\",\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t\t(e.currentTarget.style.color = \"#6005ff\")\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t\t(e.currentTarget.style.color = \"black\")\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonClick={() => {\n\t\t\t\t\t\t\t\twindow.open(\n\t\t\t\t\t\t\t\t\t\"https://ultimateelementor.com/docs/getting-started-uael/\",\n\t\t\t\t\t\t\t\t\t\"_blank\"\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{/* <Button\n\t\t\t\t\t\t\t\ticon={<ExternalLink />}\n\t\t\t\t\t\t\t\ticonPosition=\"right\"\n\t\t\t\t\t\t\t\tvariant=\"link\"\n\t\t\t\t\t\t\t\tclassName=\"uael-remove-ring text-black\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{__(\"Read full guide\", \"uael\")}\n\t\t\t\t\t\t\t</Button> */}\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</Container.Item>\n\t\t\t\t<Container.Item className=\"md:mt-0 mt-4\">\n\t\t\t\t\t<iframe\n\t\t\t\t\t\twidth=\"260\"\n\t\t\t\t\t\theight=\"160\"\n\t\t\t\t\t\tsrc=\"https://www.youtube.com/embed/YqWd3VYlxcY\"\n\t\t\t\t\t\tframeBorder=\"0\"\n\t\t\t\t\t\tstyle={{ borderRadius: \"8px\" }}\n\t\t\t\t\t\tallow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture\"\n\t\t\t\t\t\tallowFullScreen\n\t\t\t\t\t/>\n\t\t\t\t</Container.Item>\n\t\t\t</Container>\n\t\t</div>\n\t);\n};\nexport default WelcomeContainer;\n","import arrayWithoutHoles from \"./arrayWithoutHoles.js\";\nimport iterableToArray from \"./iterableToArray.js\";\nimport unsupportedIterableToArray from \"./unsupportedIterableToArray.js\";\nimport nonIterableSpread from \"./nonIterableSpread.js\";\nfunction _toConsumableArray(r) {\n  return arrayWithoutHoles(r) || iterableToArray(r) || unsupportedIterableToArray(r) || nonIterableSpread();\n}\nexport { _toConsumableArray as default };","import arrayLikeToArray from \"./arrayLikeToArray.js\";\nfunction _arrayWithoutHoles(r) {\n  if (Array.isArray(r)) return arrayLikeToArray(r);\n}\nexport { _arrayWithoutHoles as default };","function _iterableToArray(r) {\n  if (\"undefined\" != typeof Symbol && null != r[Symbol.iterator] || null != r[\"@@iterator\"]) return Array.from(r);\n}\nexport { _iterableToArray as default };","function _nonIterableSpread() {\n  throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}\nexport { _nonIterableSpread as default };","function asyncGeneratorStep(n, t, e, r, o, a, c) {\n  try {\n    var i = n[a](c),\n      u = i.value;\n  } catch (n) {\n    return void e(n);\n  }\n  i.done ? t(u) : Promise.resolve(u).then(r, o);\n}\nfunction _asyncToGenerator(n) {\n  return function () {\n    var t = this,\n      e = arguments;\n    return new Promise(function (r, o) {\n      var a = n.apply(t, e);\n      function _next(n) {\n        asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n);\n      }\n      function _throw(n) {\n        asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n);\n      }\n      _next(void 0);\n    });\n  };\n}\nexport { _asyncToGenerator as default };","var __WEBPACK_NAMESPACE_OBJECT__ = window[\"regeneratorRuntime\"];","import { jsxs as X, Fragment as k, jsx as i } from \"react/jsx-runtime\";\nimport { createContext as _, useState as $, useRef as N, useMemo as h, useCallback as G, isValidElement as J, cloneElement as B, useEffect as b, Fragment as w, useContext as Q } from \"react\";\nimport { AnimatePresence as E, motion as O } from \"framer-motion\";\nimport { callAll as W, cn as a } from \"../../utilities/functions.es.js\";\nimport { X as Y } from \"lucide-react\";\nimport { createPortal as Z } from \"react-dom\";\nconst R = _({}), u = () => Q(R), F = {\n  open: {\n    opacity: 1\n  },\n  exit: {\n    opacity: 0\n  }\n}, P = { duration: 0.2 }, r = ({\n  open: e,\n  setOpen: o,\n  children: n,\n  trigger: t = null,\n  className: c,\n  exitOnClickOutside: V = !1,\n  exitOnEsc: q = !0,\n  design: K = \"simple\",\n  scrollLock: M = !0\n}) => {\n  const x = e !== void 0 && o !== void 0, [g, m] = $(!1), f = N(null), v = N(null), l = h(\n    () => x ? e : g,\n    [e, g]\n  ), p = h(\n    () => x ? o : m,\n    [m, m]\n  ), y = () => {\n    l || p(!0);\n  }, d = () => {\n    l && p(!1);\n  }, U = G(() => J(t) ? B(t, {\n    onClick: W(y, t?.props?.onClick)\n  }) : typeof t == \"function\" ? t({ onClick: y }) : null, [t, y, d]), D = (s) => {\n    switch (s.key) {\n      case \"Escape\":\n        q && d();\n        break;\n    }\n  }, C = (s) => {\n    V && f.current && !f.current.contains(s.target) && d();\n  };\n  return b(() => (window.addEventListener(\"keydown\", D), document.addEventListener(\"mousedown\", C), () => {\n    window.removeEventListener(\"keydown\", D), document.removeEventListener(\"mousedown\", C);\n  }), [l]), b(() => {\n    if (!M)\n      return;\n    const s = document.querySelector(\"html\");\n    return l && s && (s.style.overflow = \"hidden\"), () => {\n      s && (s.style.overflow = \"\");\n    };\n  }, [l]), /* @__PURE__ */ X(k, { children: [\n    U(),\n    /* @__PURE__ */ i(\n      R.Provider,\n      {\n        value: {\n          open: l,\n          setOpen: p,\n          handleClose: d,\n          design: K,\n          dialogContainerRef: v,\n          dialogRef: f\n        },\n        children: /* @__PURE__ */ i(\n          \"div\",\n          {\n            ref: v,\n            className: a(\n              \"fixed z-999999 w-0 h-0 overflow-visible\",\n              c\n            ),\n            children: n\n          }\n        )\n      }\n    )\n  ] });\n};\nr.displayName = \"Dialog\";\nconst S = ({\n  children: e,\n  className: o\n}) => {\n  const { open: n, handleClose: t, dialogRef: c } = u();\n  return /* @__PURE__ */ i(E, { children: n && /* @__PURE__ */ i(\n    O.div,\n    {\n      className: \"fixed inset-0 overflow-y-auto\",\n      initial: \"exit\",\n      animate: \"open\",\n      exit: \"exit\",\n      variants: F,\n      role: \"dialog\",\n      transition: P,\n      children: /* @__PURE__ */ i(\"div\", { className: \"flex items-center justify-center min-h-full\", children: /* @__PURE__ */ i(\n        \"div\",\n        {\n          ref: c,\n          className: a(\n            \"flex flex-col gap-5 w-120 h-fit bg-background-primary border border-solid border-border-subtle rounded-xl shadow-soft-shadow-2xl my-5 overflow-hidden\",\n            o\n          ),\n          children: typeof e == \"function\" ? e({ close: t }) : e\n        }\n      ) })\n    }\n  ) });\n};\nS.displayName = \"Dialog.Panel\";\nconst T = ({\n  className: e,\n  ...o\n}) => {\n  const { open: n, dialogContainerRef: t } = u();\n  return t?.current ? /* @__PURE__ */ i(k, { children: Z(\n    /* @__PURE__ */ i(E, { children: n && /* @__PURE__ */ i(\n      O.div,\n      {\n        className: a(\n          \"fixed inset-0 -z-10 bg-background-inverse/90\",\n          e\n        ),\n        ...o,\n        initial: \"exit\",\n        animate: \"open\",\n        exit: \"exit\",\n        variants: F,\n        transition: P\n      }\n    ) }),\n    t.current\n  ) }) : null;\n};\nT.displayName = \"Dialog.Backdrop\";\nconst j = ({\n  children: e,\n  className: o,\n  ...n\n}) => /* @__PURE__ */ i(\"div\", { className: a(\"space-y-2 px-5 pt-5 pb-1\", o), ...n, children: e });\nj.displayName = \"Dialog.Header\";\nconst A = ({\n  children: e,\n  as: o = \"h3\",\n  className: n,\n  ...t\n}) => /* @__PURE__ */ i(\n  o,\n  {\n    className: a(\n      \"text-base font-semibold text-text-primary m-0 p-0\",\n      n\n    ),\n    ...t,\n    children: e\n  }\n);\nA.displayName = \"Dialog.Title\";\nconst I = ({\n  children: e,\n  as: o = \"p\",\n  className: n,\n  ...t\n}) => /* @__PURE__ */ i(\n  o,\n  {\n    className: a(\n      \"text-sm font-normal text-text-secondary my-0 ml-0 mr-1 p-0\",\n      n\n    ),\n    ...t,\n    children: e\n  }\n);\nI.displayName = \"Dialog.Description\";\nconst ee = ({\n  className: e,\n  ...o\n}) => /* @__PURE__ */ i(\n  \"button\",\n  {\n    className: a(\n      \"bg-transparent inline-flex justify-center items-center border-0 p-1 m-0 cursor-pointer focus:outline-none outline-none shadow-none\",\n      e\n    ),\n    \"aria-label\": \"Close dialog\",\n    ...o,\n    children: /* @__PURE__ */ i(Y, { className: \"size-4 text-text-primary shrink-0\" })\n  }\n), L = ({\n  children: e,\n  as: o = w,\n  ...n\n}) => {\n  const { handleClose: t } = u();\n  return e ? o === w ? typeof e == \"function\" ? e({\n    close: t\n  }) : B(e, {\n    onClick: t\n  }) : /* @__PURE__ */ i(o, { ...n, onClick: t, children: e }) : /* @__PURE__ */ i(ee, { onClick: t, ...n });\n};\nL.displayName = \"Dialog.CloseButton\";\nconst z = ({\n  children: e,\n  className: o,\n  ...n\n}) => /* @__PURE__ */ i(\"div\", { className: a(\"px-5\", o), ...n, children: e });\nz.displayName = \"Dialog.Body\";\nconst H = ({\n  children: e,\n  className: o\n}) => {\n  const { design: n, handleClose: t } = u(), c = () => e ? typeof e == \"function\" ? e({ close: t }) : e : null;\n  return /* @__PURE__ */ i(\n    \"div\",\n    {\n      className: a(\n        \"p-4 flex justify-end gap-3\",\n        {\n          \"bg-background-secondary\": n === \"footer-divided\"\n        },\n        o\n      ),\n      children: c()\n    }\n  );\n};\nH.displayName = \"Dialog.Footer\";\nr.Panel = S;\nr.Title = A;\nr.Description = I;\nr.CloseButton = L;\nr.Header = j;\nr.Body = z;\nr.Footer = H;\nr.Backdrop = T;\nexport {\n  ee as DefaultCloseButton,\n  T as DialogBackdrop,\n  z as DialogBody,\n  L as DialogCloseButton,\n  I as DialogDescription,\n  H as DialogFooter,\n  j as DialogHeader,\n  S as DialogPanel,\n  A as DialogTitle,\n  r as default\n};\n//# sourceMappingURL=dialog.es.js.map\n","import React, { useState } from 'react';\nimport { Container, Button, Badge, Dialog } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\n\nconst ExtendWebsiteWidget = ({\n    plugin,\n    setUpdateCounter // Receive setUpdateCounter as a prop\n}) => {\n    const {\n        path,\n        slug,\n        siteUrl,\n        icon,\n        type,\n        name,\n        zipUrl,\n        desc,\n        wporg,\n        isFree,\n        action,\n        status,\n        settings_url\n    } = plugin\n    const [isDialogOpen, setIsDialogOpen] = useState(false);\n    const [pluginData, setPluginData] = useState(null);\n\n    const getAction = (status) => {\n        if (status === 'Activated') {\n            return 'site_redirect';\n        } else if (status === 'Installed') {\n            return 'uael_recommended_plugin_activate';\n        }\n        return 'uael_recommended_plugin_install';\n    };\n\n    const handlePluginAction = (e) => {\n        const action = e.currentTarget.dataset.action;\n        const formData = new window.FormData();\n        const currentPluginData = {\n            init: e.currentTarget.dataset.init,\n            type: e.currentTarget.dataset.type,\n            slug: e.currentTarget.dataset.slug,\n            name: e.currentTarget.dataset.pluginname,\n        };\n\n        switch (action) {\n            case 'uael_recommended_plugin_activate':\n                // Confirmation only for theme activation\n                if (currentPluginData.type === 'theme') {\n                    // Show dialog for confirmation\n                    setPluginData(currentPluginData);\n                    setIsDialogOpen(true);\n                } else {\n                    // Directly activate for non-theme plugins\n                    activatePlugin(currentPluginData);\n                }\n                break;\n\n            case 'uael_recommended_plugin_install':\n\n                // Installation process without any confirmation\n                formData.append(\n                    'action',\n                    currentPluginData.type === 'theme'\n                        ? 'uael_recommended_theme_install'\n                        : 'uael_recommended_plugin_install'\n                );\n                formData.append('_ajax_nonce', uaelSettingsData.installer_nonce);\n                formData.append('slug', currentPluginData.slug);\n\n                e.target.innerText = __('Installing..', 'uael');\n\n                apiFetch({\n                    url: uaelSettingsData.ajax_url,\n                    method: 'POST',\n                    body: formData,\n                }).then((data) => {\n                    if (data.success || data.errorCode === 'folder_exists') {\n                        e.target.innerText = __('Installed', 'uael');\n                        callAnalyticsWebhook(currentPluginData);\n                        if( currentPluginData.type === 'theme' ) {\n                            // Change button state to \"Activate\" after successful installation\n                            const buttonElement = document.querySelector(`[data-slug=\"${currentPluginData.slug}\"]`);\n                            buttonElement.dataset.action = 'uael_recommended_plugin_activate';\n                            e.target.innerText = __('Activate', 'uael');\n                        } else {\n                            activatePlugin(currentPluginData);\n                        }\n                    } else {\n                        e.target.innerText = __('Install', 'uael');\n                        alert(\n                            currentPluginData.type === 'theme'\n                                ? __('Theme Installation failed, Please try again later.', 'uael')\n                                : __('Plugin Installation failed, Please try again later.', 'uael')\n                        );\n                    }\n                });\n                break;\n\n            case 'site_redirect':\n                window.open(siteUrl, '_blank'); // Open siteUrl in a new tab\n                break;\n\n            default:\n                // Do nothing.\n                break;\n        }\n    };\n\n    const callAnalyticsWebhook = (pluginData) => {\n        const webhookUrl = 'https://webhook.suretriggers.com/suretriggers/a7ac4b20-18f9-4ec6-9813-dfac83328d00';\n        const today = new Date().toISOString().split('T')[0];\n        const params = new URLSearchParams({\n            source: 'UAE Pro',\n            target_plugin: pluginData.name,\n            date: today, // Add today's date\n        });\n\n        fetch(`${webhookUrl}?${params.toString()}`, {\n            method: 'GET',\n        })\n        .then(response => response.json())\n        .then(data => {\n            // console.log('Webhook call successful:', data);\n        })\n        .catch(error => {\n            // console.error('Error calling webhook:', error);\n        });\n    }\n\n    const activatePlugin = (pluginData) => {\n        setIsDialogOpen(false);\n        const formData = new window.FormData();\n        formData.append('action', 'uael_recommended_plugin_activate');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n        formData.append('plugin', pluginData.init);\n        formData.append('type', pluginData.type);\n        formData.append('slug', pluginData.slug);\n\n        const buttonElement = document.querySelector(`[data-slug=\"${pluginData.slug}\"]`);\n        const spanElement = buttonElement.querySelector('span');\n\n        spanElement.innerText = __('Activating..', 'uael');\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {            \n            if (data.success) {\n                if (spanElement) { // Check if spanElement is not null\n                    buttonElement.style.color = '#16A34A';\n                    buttonElement.dataset.action = 'site_redirect';\n                    buttonElement.classList.add('uae-plugin-activated');\n                    spanElement.innerText = __('Activated', 'uael');\n                    window.open(settings_url, '_blank');\n                    setTimeout(() => {\n                        // Reload the section or recall the REST API\n                        setUpdateCounter(prev => prev + 1);\n                    }, 5000);\n                }\n            } else {\n                if ('theme' == pluginData.type) {\n                    // console.log(__(`Theme Activation failed, Please try again later.`, 'uael'));\n                } else {\n                    // console.log(__(`Plugin Activation failed, Please try again later.`, 'uael'));\n                }\n                const buttonElement = document.querySelector(`[data-slug=\"${pluginData.slug}\"]`);\n                if (buttonElement) { // Check if buttonElement is not null\n                    const spanElement = buttonElement.querySelector('span');\n                    if (spanElement) { // Check if spanElement is not null\n                        spanElement.innerText = __('Activate', 'uael');\n                    }\n                }\n            }\n        });\n    };\n\n    return (\n        <Container align=\"center\"\n            containerType=\"flex\"\n            direction=\"column\"\n            justify=\"between\"\n            gap=\"lg\"\n        >\n            <div className='flex items-center justify-between w-full'>\n                <div className='h-5 w-5'>\n                    <img\n                        src={icon}\n                        alt=\"Recommended Plugins/Themes\"\n                        className=\"w-full h-auto rounded\"\n                        \tstyle={{\n\t\t\t\t\t\t\twidth: \"140px\",\n\t\t\t\t\t\t\theight: \"140px\",\n\t\t\t\t\t\t\tmarginTop: \"-55px\",\n\t\t\t\t\t\t}}\n\t\t\t\t\t/>\n                </div>\n\n                <div className='flex items-center gap-x-2'>\n                    {/* {isFree && (\n                        <Badge\n                            label={__(\"Free\", \"uael\")}\n                            size=\"xs\"\n                            type=\"pill\"\n                            variant=\"green\"\n                        />\n                    )} */}\n                        <Dialog\n                            design=\"simple\"\n                            open={isDialogOpen}\n                            setOpen={setIsDialogOpen}\n                        >\n                            <Dialog.Backdrop />\n                            <Dialog.Panel>\n                                <Dialog.Header>\n                                    <div className=\"flex items-center justify-between\">\n                                        <Dialog.Title>\n                                        {__('Activate Theme', 'uael')}\n                                        </Dialog.Title>\n                                    </div>\n                                    <Dialog.Description>\n                                        {__('Are you sure you want to switch your current theme to Astra?', 'uael')}\n                                    </Dialog.Description>\n                                </Dialog.Header>\n                                <Dialog.Footer>\n                                    <Button onClick={() => activatePlugin(pluginData)}>\n                                        {__('Yes', 'uael')}\n                                    </Button>\n                                    <Button variant='outline' onClick={() => setIsDialogOpen(false)}>\n                                        {__('Close', 'uael')}\n                                    </Button>\n                                </Dialog.Footer>\n                            </Dialog.Panel>\n                        </Dialog>\n                </div>\n            </div>\n\n            <div className='flex flex-col w-full pb-4'>\n                <p\n                    className='text-base font-medium text-text-primary pb-1 m-0 cursor-pointer'\n                    onClick={() => window.open(plugin.siteurl, '_blank')}\n                    \tstyle={{ marginTop: \"-8px\" }}\n                >{__(name, 'uael')}</p>\n                <p className='text-sm font-medium text-text-tertiary m-0'>{__(desc, 'uael')}</p>\n                <div  className=\"uael-remove-ring\">\n                     <Button\n                        size=\"sm\"\n                        variant=\"link\"\n                        className=\"cursor-pointer uael-remove-ring bg-white hover:bg-gray-100 hover:text-gray-900 hover:shadow-md text-gray-800 rounded mt-4 px-2 py-2 transition-all duration-200 ease-in-out transform hover:scale-105 hover:border-gray-400\"\n                        onClick={handlePluginAction} // Trigger action on click\n                        data-plugin={zipUrl}\n                        data-type={type}\n                        data-pluginname={name}\n                        data-slug={slug}\n                        data-site={siteUrl}\n                        data-init={path}\n                        data-action={getAction(status)}\n                        style={{ outline: \"none\", border: \"1px solid #ccc\" }}\n\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t(e.currentTarget.style.color = \"#5C2EDE\")\n\t\t\t\t\t\t}\n\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t(e.currentTarget.style.color = \"black\")\n\t\t\t\t\t\t}\n                    >\n                        \t{status === \"Activated\"\n\t\t\t\t\t\t\t? __(\"Visit Site\", \"uael\")\n\t\t\t\t\t\t\t: \"Installed\" === status\n\t\t\t\t\t\t\t? __(\"Activate\", \"uael\")\n\t\t\t\t\t\t\t: __(\n\t\t\t\t\t\t\t\t\t\"Install & Activate\",\n\t\t\t\t\t\t\t\t\t\"uael\",\n\t\t\t\t\t\t\t  )}\n                    </Button>\n                </div>\n            </div>\n        </Container>\n    )\n}\n\nexport default ExtendWebsiteWidget\n","import { jsx as c } from \"react/jsx-runtime\";\nimport { cn as n } from \"../../utilities/functions.es.js\";\nconst o = ({\n  variant: r = \"rectangular\",\n  // rectangular, circular\n  className: a,\n  ...e\n}) => {\n  const t = {\n    circular: \"rounded-full bg-gray-200 \",\n    rectangular: \"rounded-md bg-gray-200\"\n  }[r], l = {\n    circular: \"size-10\",\n    rectangular: \"w-96 h-3\"\n  }[r];\n  return /* @__PURE__ */ c(\n    \"div\",\n    {\n      className: n(\n        t,\n        \"animate-pulse\",\n        l,\n        a\n      ),\n      ...e\n    }\n  );\n};\nexport {\n  o as default\n};\n//# sourceMappingURL=skeleton.es.js.map\n","import React, { useState, useEffect } from 'react';\nimport ExtendWebsiteWidget from './ExtendWebsiteWidget';\nimport { Container, Skeleton } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\n\nconst ExtendWebsite = () => {\n    const [plugins, setPlugins] = useState([]);\n    const [loading, setLoading] = useState(true);\n    const [updateCounter, setUpdateCounter] = useState(0);\n    const [allInstalled, setAllInstalled] = useState(false);\n\n    useEffect(() => {\n        const fetchSettings = async () => {\n            setLoading(true);\n            try {\n                const data = await apiFetch({\n                    path: '/uael/v1/plugins',\n                    headers: {\n                        'Content-Type': 'application/json',\n                        'X-WP-Nonce': uaelSettingsData.uael_nonce_action,\n                    },\n                });\n                const pluginsData = convertToPluginsArray(data);\n                setPlugins(pluginsData);\n                \n                // Check if all plugins are installed\n                const areAllInstalled = pluginsData.every(plugin => plugin.is_installed);\n                setAllInstalled(areAllInstalled);\n            } catch (err) {\n                console.error(\"Error fetching plugins:\", err);\n            } finally {\n                setLoading(false);\n            }\n        };\n\n        fetchSettings();\n    }, [updateCounter]);\n\n    function convertToPluginsArray(data) {\n        return Object.keys(data).map((key) => ({\n            path: key,\n            ...data[key],\n        }));\n    }\n\n    // If all plugins are installed, don't render the component\n    if (allInstalled) {\n        return null;\n    }\n\n    return (\n        <div className=\"rounded-lg bg-white w-full mb-6\">\n            <div className=\"flex items-center justify-between p-4\" style={{ paddingBottom: '0' }}>\n                <p className=\"m-0 text-sm font-semibold text-text-primary\">\n                    {__(\"Extend Your Website\", \"uael\")}\n                </p>\n                <div className=\"flex items-center gap-x-2 mr-7\"></div>\n            </div>\n            <div className=\"flex flex-col rounded-lg p-4\" style={{ backgroundColor: \"white\" }}>\n                {loading ? (\n                    <Container\n                        align=\"stretch\"\n                        className=\"gap-1 p-1 grid grid-cols-1 md:grid-cols-1\"\n                        containerType=\"grid\"\n                        justify=\"start\"\n                    >\n                        {[...Array(2)].map((_, index) => (\n                            <Container.Item\n                                key={index}\n                                alignSelf=\"auto\"\n                                style={{ height: '150px' }}\n                                className=\"text-wrap rounded-md shadow-container-item bg-[#F9FAFB] p-4\"\n                            >\n                                <div className=\"flex flex-col gap-6\" style={{ marginTop: '40px' }}>\n                                    <Skeleton className=\"w-12 h-2 rounded-md\" />\n                                    <Skeleton className=\"w-16 h-2 rounded-md\" />\n                                    <Skeleton className=\"w-12 h-2 rounded-md\" />\n                                </div>\n                            </Container.Item>\n                        ))}\n                    </Container>\n                ) : ( \n                    <Container\n                        align=\"stretch\"\n                        className=\"gap-1 p-1 grid grid-cols-1 md:grid-cols-1\"\n                        containerType=\"grid\"\n                        justify=\"start\"\n                        style={{ backgroundColor: \"#F9FAFB\" }}\n                    >\n                        {plugins.slice(0, 1).map((plugin) => (\n                            <Container.Item\n                                key={plugin.slug}\n                                alignSelf=\"auto\"\n                                className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-4\"\n                            >\n                                <ExtendWebsiteWidget plugin={plugin} setUpdateCounter={setUpdateCounter} />\n                            </Container.Item>\n                        ))}\n                    </Container>\n                )}\n            </div>\n        </div>\n    );\n};\n\nexport default ExtendWebsite;\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst ChevronLeft = createLucideIcon(\"ChevronLeft\", [\n  [\"path\", { d: \"m15 18-6-6 6-6\", key: \"1wnfg3\" }]\n]);\n\nexport { ChevronLeft as default };\n//# sourceMappingURL=chevron-left.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst ChevronRight = createLucideIcon(\"ChevronRight\", [\n  [\"path\", { d: \"m9 18 6-6-6-6\", key: \"mthhwq\" }]\n]);\n\nexport { ChevronRight as default };\n//# sourceMappingURL=chevron-right.js.map\n","import { Skeleton } from \"@bsf/force-ui\";\nimport { ChevronRight, ChevronLeft } from \"lucide-react\";\nimport { useState } from \"react\";\nimport { __ } from '@wordpress/i18n';\n\nconst videoData = [\n  {\n    id: 1,\n    videoId: \"kXuXfaetch4\",\n    title: __(\"Video Tutorial 1\", 'uael')\n  },\n  {\n    id: 2,\n    videoId: \"8fu8W4quFg0\",\n    title: __(\"Video Tutorial 2\", 'uael')\n  },\n  {\n    id: 3,\n    videoId: \"wwu4ZzXrhGc\",\n    title: __(\"Video Tutorial 3\", 'uael')\n  },\n  {\n    id: 4,\n    videoId: \"88kTeBv4mWY\",\n    title: __(\"Video Tutorial 4\", 'uael')\n  },\n  {\n    id: 5,\n    videoId: \"NovIe5b2EkQ\",\n    title: __(\"Video Tutorial 5\", 'uael')\n  },\n  {\n    id: 6,\n    videoId: \"kaGfSpGFcnw\",\n    title: __(\"Video Tutorial 6\", 'uael')\n  },\n  {\n    id: 7,\n    videoId: \"7Q-3fAKKhbg\",\n    title: __(\"Video Tutorial 7\", 'uael')\n  },\n  {\n    id: 8,\n    videoId: \"qhFfKf2R-SM\",\n    title: __(\"Video Tutorial 8\", 'uael')\n  },\n  {\n    id: 9,\n    videoId: \"jWzW_oT1iSQ\",\n    title: __(\"Video Tutorial 9\", 'uael')\n  },\n  {\n    id: 10,\n    videoId: \"-FErpbu2F58\",\n    title: __(\"Video Tutorial 10\", 'uael')\n  },\n  {\n    id: 11,\n    videoId: \"hrDAFmPTDgg\",\n    title: __(\"Video Tutorial 11\", 'uael')\n  },\n  {\n    id: 12,\n    videoId: \"2RlvBU_EFV4\",\n    title: __(\"Video Tutorial 12\", 'uael')\n  },\n  {\n    id: 13,\n    videoId: \"7m6FD8Yk3N0\",\n    title: __(\"Video Tutorial 13\", 'uael')\n  },\n  {\n    id: 14,\n    videoId: \"OCD3oZas60w\",\n    title: __(\"Video Tutorial 14\", 'uael')\n  },\n  {\n    id: 15,\n    videoId: \"K4gCczaX-Sg\",\n    title: __(\"Video Tutorial 15\", 'uael')\n  },\n  {\n    id: 16,\n    videoId: \"Izbr-oO0VkU\",\n    title: __(\"Video Tutorial 16\", 'uael')\n  },\n  {\n    id: 17,\n    videoId: \"ruGOgho6RQM\",\n    title: __(\"Video Tutorial 17\", 'uael')\n  },\n  {\n    id: 18,\n    videoId: \"8N_CW1rgvp0\",\n    title: __(\"Video Tutorial 18\", 'uael')\n  },\n  {\n    id: 19,\n    videoId: \"WmrSMl5g3ac\",\n    title: __(\"Video Tutorial 19\", 'uael')\n  },\n  {\n    id: 20,\n    videoId: \"BqXOvmpulQQ\",\n    title: __(\"Video Tutorial 20\", 'uael')\n  },\n  {\n    id: 21,\n    videoId: \"bVfJNMZOsv0\",\n    title: __(\"Video Tutorial 21\", 'uael')\n  },\n  {\n    id: 22,\n    videoId: \"IigQsUdvcRo\",\n    title: __(\"Video Tutorial 22\", 'uael')\n  },\n  {\n    id: 23,\n    videoId: \"tZRjCiUFa-o\",\n    title: __(\"Video Tutorial 23\", 'uael')\n  },\n  {\n    id: 24,\n    videoId: \"TJmcPWToHU0\",\n    title: __(\"Video Tutorial 24\", 'uael')\n  },\n  {\n    id: 25,\n    videoId: \"XuQZzQJbNas\",\n    title: __(\"Video Tutorial 25\", 'uael')\n  },\n  {\n    id: 26,\n    videoId: \"Eh8a3skmVDM\",\n    title: __(\"Video Tutorial 26\", 'uael')\n  },\n  {\n    id: 27,\n    videoId: \"zGvbznihzH8\",\n    title: __(\"Video Tutorial 27\", 'uael')\n  },\n  {\n    id: 28,\n    videoId: \"lgCG5--xyR4\",\n    title: __(\"Video Tutorial 28\", 'uael')\n  },\n  {\n    id: 29,\n    videoId: \"p3zlIYoaaG0\",\n    title: __(\"Video Tutorial 29\", 'uael')\n  },\n];\n\n// New component to handle lazy-loading of YouTube thumbnails\nconst VideoThumbnail = ({ videoId, title, playingVideoId, setPlayingVideoId }) => {\n  const isPlaying = playingVideoId === videoId;\n\n  const handlePlayVideo = () => {\n    setPlayingVideoId(videoId);\n  };\n\n  return (\n    <div className=\"video-thumbnail-container\" onClick={handlePlayVideo} style={{ cursor: 'pointer' }}>\n      {isPlaying ? (\n        <iframe\n          width=\"300\"\n          height=\"180\"\n          src={`https://www.youtube.com/embed/${videoId}?autoplay=1`}\n          frameBorder=\"0\"\n          style={{ borderRadius: \"8px\" }}\n          allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture\"\n          allowFullScreen\n          title={title}\n        />\n      ) : (\n        <div style={{ position: 'relative' }}>\n          <img\n            src={`https://img.youtube.com/vi/${videoId}/maxresdefault.jpg`}\n            alt={title}\n            width=\"300\"\n            height=\"180\"\n            style={{ borderRadius: \"8px\" }}\n          />\n          <img\n            src={`${uaelSettingsData.video_control}`}\n            alt=\"Play\"\n            style={{ left: \"43%\", top: \"50%\", transform: \"translate(-50%, -50%)\" }}\n            className=\"absolute inset-0 w-11 h-11\"\n          />\n        </div>\n      )}\n    </div>\n  );\n};\n\n// VideoTutorials Component\nexport default function VideoTutorials() {\n  const [currentIndex, setCurrentIndex] = useState(0);\n  const [playingVideoId, setPlayingVideoId] = useState(null); // Track the currently playing video\n\n  const nextSlide = () => {\n    if (currentIndex < videoData.length - 3) {\n      setCurrentIndex((prev) => prev + 1);\n    }\n  };\n\n  const prevSlide = () => {\n    if (currentIndex > 0) {\n      setCurrentIndex((prev) => prev - 1);\n    }\n  };\n\n  return (\n    <div className=\"rounded-lg bg-white w-full mb-4\">\n      <div\n        className=\"flex items-center justify-between p-4\"\n        style={{\n          paddingBottom: \"0\",\n        }}\n      >\n        <p className=\"m-0 text-sm pt-4 pl-3 font-semibold text-text-primary\">\n          {__(\"Video Tutorials\", \"uael\")}\n        </p>\n        <div className=\"flex items-center cursor-pointer gap-x-2 mr-7\">\n          <ChevronLeft\n            className={\n              currentIndex === 0 ? \"text-gray-300 cursor-not-allowed\" : \"cursor-pointer\"\n            }\n            onClick={prevSlide}\n          />\n          <ChevronRight\n            className={\n              currentIndex >= videoData.length - 3\n                ? \"text-gray-300 cursor-not-allowed\"\n                : \"cursor-pointer\"\n            }\n            onClick={nextSlide}\n          />\n        </div>\n      </div>\n      <div className=\"overflow-hidden bg-black flex-col rounded-lg pl-2 pr-4 py-2 relative\">\n        <div\n          className=\"flex transition-transform duration-300 ease-in-out\"\n          style={{\n            transform: `translateX(-${currentIndex * (100 / videoData.length)}%)`,\n            width: `${(videoData.length / 2.95) * 100}%`,\n          }}\n        >\n          {videoData.map((video) => (\n            <div key={video.id} className=\"py-2 px-1\">\n              <VideoThumbnail\n                videoId={video.videoId}\n                title={video.title}\n                playingVideoId={playingVideoId}\n                setPlayingVideoId={setPlayingVideoId}\n              />\n            </div>\n          ))}\n        </div>\n      </div>\n    </div>\n  );\n}\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst BadgeCheck = createLucideIcon(\"BadgeCheck\", [\n  [\n    \"path\",\n    {\n      d: \"M3.85 8.62a4 4 0 0 1 4.78-4.77 4 4 0 0 1 6.74 0 4 4 0 0 1 4.78 4.78 4 4 0 0 1 0 6.74 4 4 0 0 1-4.77 4.78 4 4 0 0 1-6.75 0 4 4 0 0 1-4.78-4.77 4 4 0 0 1 0-6.76Z\",\n      key: \"3c2336\"\n    }\n  ],\n  [\"path\", { d: \"m9 12 2 2 4-4\", key: \"dzmm74\" }]\n]);\n\nexport { BadgeCheck as default };\n//# sourceMappingURL=badge-check.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Settings2 = createLucideIcon(\"Settings2\", [\n  [\"path\", { d: \"M20 7h-9\", key: \"3s1dr2\" }],\n  [\"path\", { d: \"M14 17H5\", key: \"gfn3mx\" }],\n  [\"circle\", { cx: \"17\", cy: \"17\", r: \"3\", key: \"18b49y\" }],\n  [\"circle\", { cx: \"7\", cy: \"7\", r: \"3\", key: \"dfmy0x\" }]\n]);\n\nexport { Settings2 as default };\n//# sourceMappingURL=settings-2.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst FolderKanban = createLucideIcon(\"FolderKanban\", [\n  [\n    \"path\",\n    {\n      d: \"M4 20h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.93a2 2 0 0 1-1.66-.9l-.82-1.2A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13c0 1.1.9 2 2 2Z\",\n      key: \"1fr9dc\"\n    }\n  ],\n  [\"path\", { d: \"M8 10v4\", key: \"tgpxqk\" }],\n  [\"path\", { d: \"M12 10v2\", key: \"hh53o1\" }],\n  [\"path\", { d: \"M16 10v6\", key: \"1d6xys\" }]\n]);\n\nexport { FolderKanban as default };\n//# sourceMappingURL=folder-kanban.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Wrench = createLucideIcon(\"Wrench\", [\n  [\n    \"path\",\n    {\n      d: \"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z\",\n      key: \"cbrjhi\"\n    }\n  ]\n]);\n\nexport { Wrench as default };\n//# sourceMappingURL=wrench.js.map\n","import { Container, Skeleton } from \"@bsf/force-ui\";\nimport { __ } from \"@wordpress/i18n\";\nimport { routes } from '../../admin/settings/routes';\nimport { Link, history } from '../../router/index';\nimport { ArrowUpRight } from \"lucide-react\";\nimport { Settings2, BadgeCheck, Image as IconImage, Globe, FolderKanban, Wrench } from \"lucide-react\";\nimport React, { useState } from 'react';\n\nconst QuickSettings = () => {\n\n    const [loading, setLoading] = useState(false);\n\n    const settings = [\n        { label: 'Product License', tab: 1, icon: BadgeCheck },\n        { label: 'Widgets/Features', route: routes.widgets.path, icon: Settings2 },\n        { label: 'Post Skins', tab: 6, icon: FolderKanban },\n        { label: 'Integrations', tab: 5, icon: Wrench },\n    ];\n\n    const handleTabRedirect = (e, tab) => {\n        e.preventDefault();\n        const params = new URLSearchParams(window.location.search);\n        params.set('tab', tab);\n        const query = params.toString();\n        history.push(`${window.location.pathname}${query ? '?' + query : ''}#${routes.settings.path}`);\n    };\n\n    const handleRouteRedirect = (e, route) => {\n        e.preventDefault();\n        history.push(`${window.location.pathname}#${route}`);\n    };\n\n    return (\n        <div className='rounded-lg bg-white w-full mb-4'>\n            <div className='flex flex-col md:flex-row md:items-center md:justify-between p-4'\n                style={{\n                    paddingBottom: '0'\n                }}>\n                <p className='m-0 text-sm font-semibold text-text-primary mb-2 md:mb-0'>{__(\"Quick Settings\", \"uael\")}</p>\n            </div>\n            <div className='flex bg-black flex-col rounded-lg p-4'>\n                {loading ? (\n                    <Container\n                        align=\"stretch\"\n                        className=\"p-2 gap-1.5 grid grid-cols-2 md:grid-cols-4\"\n                        style={{\n                            backgroundColor: \"#F9FAFB\"\n                        }}\n                        containerType=\"grid\"\n                        gap=\"\"\n                        justify=\"start\"\n                    >\n                        {[...Array(4)].map((_, index) => (\n                            <Container.Item\n                                key={index}\n                                alignSelf=\"auto\"\n                                className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-6 space-y-2\"\n                            >\n                                <Skeleton className='w-12 h-2 rounded-md' />\n                                <Skeleton className='w-16 h-2 rounded-md' />\n                                <Skeleton className='w-12 h-2 rounded-md' />\n                            </Container.Item>\n                        ))}\n                    </Container>\n                ) : (\n                    <Container\n                        align=\"stretch\"\n                        className=\"p-1 gap-1.5 grid-cols-2 md:grid-cols-4\"\n                        containerType=\"grid\"\n                        gap=\"\"\n                        justify=\"start\"\n                        style={{\n                            backgroundColor: '#F9FAFB'\n                        }}\n                    >\n                        {settings?.map((setting, index) => {\n                            const Icon = setting.icon;\n                            return (\n                                <Container.Item\n                                    key={index}\n                                    alignSelf=\"auto\"\n                                    className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-4\"\n                                >\n                                    <div className=\"flex flex-col items-start \">\n                                        {Icon && <Icon className=\"h-5 w-5 text-text-secondary\" />}\n                                        <h3 className=\"text-sm font-medium text-text-primary\">{setting.label}</h3>\n                                        <button\n                                            onClick={(e) => setting.route ? handleRouteRedirect(e, setting.route) : handleTabRedirect(e, setting.tab)}\n                                            className=\"text-sm text-text-tertiary cursor-pointer no-underline hover:text-gray-600 bg-transparent border-none p-0 text-left\"\n                                        >\n                                            {__(\"Configure\", \"uael\")}\n                                        </button>\n                                    </div>\n                                </Container.Item>\n                            );\n                        })}\n                    </Container>\n                )}\n            </div>\n        </div>\n    );\n};\n\nexport default QuickSettings;\n","let c = 1;\nclass a {\n  #t;\n  #s;\n  constructor() {\n    this.#t = [], this.#s = [];\n  }\n  // Subscriber pattern.\n  subscribe(t) {\n    return this.#s.push(t), () => {\n      this.#s = this.#s.filter(\n        (s) => s !== t\n      );\n    };\n  }\n  // Publish a new toast.\n  publish(t) {\n    this.#s.forEach((s) => s(t));\n  }\n  // Add a new toast.\n  add(t) {\n    this.#t.push(t), this.publish(t);\n  }\n  // Remove a toast.\n  remove(t) {\n    return this.#t = this.#t.filter((s) => s.id !== t), t;\n  }\n  // Create a new toast.\n  create(t) {\n    const {\n      id: s = void 0,\n      message: e = \"\",\n      jsx: r = void 0,\n      ...n\n    } = t;\n    if (!e && typeof r != \"function\")\n      return;\n    const o = typeof s == \"number\" ? s : c++;\n    return this.#t.find((u) => u.id === o) && (this.#t = this.#t.map((u) => u.id === o ? (this.publish({\n      ...u,\n      title: e,\n      jsx: r,\n      ...n\n    }), { ...u, title: e, jsx: r, ...n }) : u)), this.add({ id: o, title: e, jsx: r, ...n }), o;\n  }\n  // Update a toast.\n  update(t, s) {\n    const { render: e = void 0 } = s;\n    let r = s;\n    switch (typeof e) {\n      case \"function\":\n        r = {\n          jsx: e,\n          ...s\n        };\n        break;\n      case \"string\":\n        r = {\n          title: e,\n          ...s\n        };\n        break;\n    }\n    this.#t = this.#t.map((n) => n.id === t ? (this.publish({ ...n, ...r }), { ...n, ...r }) : n);\n  }\n  // Dismiss toast.\n  dismiss(t) {\n    return t || this.#t.forEach(\n      (s) => this.#s.forEach(\n        (e) => e({ id: s.id, dismiss: !0 })\n      )\n    ), this.#s.forEach(\n      (s) => s({ id: t, dismiss: !0 })\n    ), t;\n  }\n  // History of toasts.\n  history() {\n    return this.#t;\n  }\n  // Types of toasts.\n  // Default toast.\n  default(t = \"\", s = {}) {\n    return this.create({ message: t, type: \"neutral\", ...s });\n  }\n  // Success toast.\n  success(t = \"\", s = {}) {\n    return this.create({ message: t, type: \"success\", ...s });\n  }\n  // Error toast.\n  error(t = \"\", s = {}) {\n    return this.create({ message: t, type: \"error\", ...s });\n  }\n  // Warning toast.\n  warning(t = \"\", s = {}) {\n    return this.create({ message: t, type: \"warning\", ...s });\n  }\n  // Info toast\n  info(t = \"\", s = {}) {\n    return this.create({ message: t, type: \"info\", ...s });\n  }\n  // Custom toast.\n  custom(t, s = {}) {\n    return this.create({\n      jsx: t,\n      type: \"custom\",\n      ...s\n    });\n  }\n}\nconst i = new a(), d = (h, t) => i.default(h, t), p = Object.seal(\n  Object.assign(\n    d,\n    {\n      success: i.success.bind(i),\n      error: i.error.bind(i),\n      warning: i.warning.bind(i),\n      info: i.info.bind(i),\n      custom: i.custom.bind(i),\n      dismiss: i.dismiss.bind(i),\n      update: i.update.bind(i)\n    },\n    {\n      getHistory: i.history.bind(i)\n    }\n  )\n);\nexport {\n  i as ToastState,\n  p as toast\n};\n//# sourceMappingURL=controller.es.js.map\n","const r = {\n  \"top-left\": \"top-0 bottom-0 left-0 justify-start items-start\",\n  \"top-right\": \"top-0 bottom-0 right-0 justify-start items-end\",\n  \"bottom-left\": \"top-0 bottom-0 left-0 justify-end items-start\",\n  \"bottom-right\": \"top-0 bottom-0 right-0 justify-end items-end\"\n}, t = {\n  stack: \"w-[22.5rem]\",\n  inline: \"lg:w-[47.5rem] w-full\"\n}, e = {\n  light: {\n    neutral: \"border-alert-border-neutral bg-alert-background-neutral\",\n    custom: \"border-alert-border-neutral bg-alert-background-neutral\",\n    info: \"border-alert-border-info bg-alert-background-info\",\n    success: \"border-alert-border-green bg-alert-background-green\",\n    warning: \"border-alert-border-warning bg-alert-background-warning\",\n    error: \"border-alert-border-danger bg-alert-background-danger\"\n  },\n  dark: \"bg-background-inverse border-background-inverse\"\n}, o = {\n  light: \"text-icon-secondary\",\n  dark: \"text-icon-inverse\"\n};\nexport {\n  o as closeIconClassNames,\n  t as containerVariantClassNames,\n  r as positionClassNames,\n  e as variantClassNames\n};\n//# sourceMappingURL=component-style.es.js.map\n","import { jsx as r } from \"react/jsx-runtime\";\nimport { memo as i } from \"react\";\nlet e = !1;\nconst u = (t) => i((n) => {\n  const o = n.singleTon;\n  return e && o ? null : (e = !0, /* @__PURE__ */ r(t, { ...n }));\n});\nexport {\n  u as default\n};\n//# sourceMappingURL=withSingleton.es.js.map\n","import { jsx as r, jsxs as g, Fragment as L } from \"react/jsx-runtime\";\nimport { useState as M, useEffect as N, useRef as k } from \"react\";\nimport { X as j } from \"lucide-react\";\nimport { ToastState as F } from \"./controller.es.js\";\nimport { cn as u } from \"../../utilities/functions.es.js\";\nimport { getIcon as T, getTitle as S, getContent as w, getAction as P } from \"./utils.es.js\";\nimport { positionClassNames as z, containerVariantClassNames as D, variantClassNames as h, closeIconClassNames as m } from \"./component-style.es.js\";\nimport { flushSync as R } from \"react-dom\";\nimport { AnimatePresence as V, motion as X } from \"framer-motion\";\nimport $ from \"../../hoc/withSingleton.es.js\";\nconst q = ({\n  position: n = \"top-right\",\n  // top-right/top-left/bottom-right/bottom-left\n  design: d = \"stack\",\n  // stack/inline\n  theme: f = \"light\",\n  // light/dark\n  className: y = \"\",\n  autoDismiss: l = !0,\n  // Auto dismiss the toast after a certain time.\n  dismissAfter: e = 5e3\n  // Time in milliseconds after which the toast will be dismissed.\n}) => {\n  const [p, o] = M([]);\n  N(() => {\n    F.subscribe((i) => {\n      if (i?.dismiss) {\n        o(\n          (s) => s.map(\n            (t) => t.id === i.id ? { ...t, dismiss: !0 } : t\n          )\n        );\n        return;\n      }\n      setTimeout(() => {\n        R(\n          () => o((s) => s.findIndex(\n            (c) => c.id === i.id\n          ) !== -1 ? s.map((c) => c.id === i.id ? { ...c, ...i } : c) : [...s, i])\n        );\n      });\n    });\n  }, []);\n  const a = (i) => {\n    o((s) => s.filter((t) => t.id !== i));\n  };\n  return /* @__PURE__ */ r(\n    \"ul\",\n    {\n      className: u(\n        \"fixed flex flex-col list-none z-20 p-10 pointer-events-none [&>li]:pointer-events-auto gap-3\",\n        z[n] ?? z[\"top-right\"],\n        y\n      ),\n      children: /* @__PURE__ */ r(V, { initial: !1, children: p.map((i) => /* @__PURE__ */ r(\n        X.li,\n        {\n          initial: { opacity: 0, y: 50, scale: 0.7 },\n          animate: { opacity: 1, y: 0, scale: 1 },\n          exit: {\n            opacity: 0,\n            scale: 0.6,\n            transition: { duration: 0.15 }\n          },\n          layoutId: `toast-${i.id}`,\n          children: /* @__PURE__ */ r(\n            B,\n            {\n              toastItem: i,\n              title: i.title,\n              content: i?.description,\n              icon: i?.icon ?? void 0,\n              design: i?.design ?? d,\n              autoDismiss: i?.autoDismiss ?? l,\n              dismissAfter: i?.dismissAfter ?? e,\n              removeToast: a,\n              variant: i.type,\n              theme: i?.theme ?? f\n            }\n          )\n        },\n        i.id\n      )) })\n    }\n  );\n}, B = ({\n  toastItem: n,\n  title: d = \"\",\n  content: f = \"\",\n  autoDismiss: y = !0,\n  dismissAfter: l = 5e3,\n  theme: e = \"light\",\n  // light/dark\n  design: p = \"stack\",\n  // inline/stack\n  icon: o,\n  variant: a = \"neutral\",\n  // neutral/info/success/warning/danger\n  removeToast: i\n  // Function to remove the toast.\n}) => {\n  const s = k(0), t = k(0), c = k(), C = (x, A = l) => {\n    if (!(!y || l < 0))\n      return s.current = (/* @__PURE__ */ new Date()).getTime(), setTimeout(() => {\n        typeof i == \"function\" && i(x.id);\n      }, A);\n  }, E = () => {\n    clearTimeout(c.current), t.current = (/* @__PURE__ */ new Date()).getTime();\n  }, _ = () => {\n    c.current = C(\n      n,\n      l - (t.current - s.current)\n    );\n  };\n  N(() => {\n    const x = l;\n    return c.current = C(n, x), () => {\n      clearTimeout(c.current);\n    };\n  }, []), N(() => {\n    !n?.dismiss || typeof i != \"function\" || i(n.id);\n  }, [n]);\n  const v = () => {\n    typeof i == \"function\" && n?.action?.onClick?.(() => i(n.id));\n  };\n  let b = null;\n  return p === \"stack\" && (b = /* @__PURE__ */ r(\n    \"div\",\n    {\n      className: u(\n        \"flex items-center justify-start p-4 gap-2 relative border border-solid rounded-md shadow-lg\",\n        e === \"dark\" ? h.dark : h.light?.[a],\n        D.stack\n      ),\n      onMouseEnter: E,\n      onMouseLeave: _,\n      children: n.type !== \"custom\" ? /* @__PURE__ */ g(L, { children: [\n        /* @__PURE__ */ r(\"div\", { className: \"self-start flex items-center justify-center [&_svg]:size-5 shrink-0\", children: T({ variant: a, icon: o, theme: e }) }),\n        /* @__PURE__ */ g(\"div\", { className: \"flex flex-col items-start justify-start gap-0.5 mr-6\", children: [\n          S({ title: d, theme: e }),\n          w({ content: f, theme: e }),\n          n?.action?.label && typeof n?.action?.onClick == \"function\" && /* eslint-disable */\n          /* @__PURE__ */ r(\"div\", { className: \"mt-2.5\", children: P({\n            actionLabel: n?.action?.label,\n            actionType: n?.action?.type ?? \"button\",\n            onAction: v,\n            theme: e\n          }) })\n        ] }),\n        /* @__PURE__ */ r(\"div\", { className: \"absolute right-4 top-4 [&_svg]:size-5\", children: /* @__PURE__ */ r(\n          \"button\",\n          {\n            className: u(\n              \"bg-transparent m-0 p-0 border-none focus:outline-none active:outline-none cursor-pointer\",\n              m[e] ?? m.light\n            ),\n            onClick: () => {\n              typeof i == \"function\" && i(n.id);\n            },\n            children: /* @__PURE__ */ r(j, {})\n          }\n        ) })\n      ] }) : n?.jsx?.({\n        close: () => i(n.id),\n        action: n?.action ? { ...n?.action, onClick: v } : null\n      })\n    }\n  )), p === \"inline\" && (b = /* @__PURE__ */ g(\n    \"div\",\n    {\n      className: u(\n        \"flex items-center justify-start p-3 gap-2 relative border border-solid rounded-md shadow-lg\",\n        e === \"dark\" ? h.dark : h.light?.[a],\n        D.inline\n      ),\n      children: [\n        /* @__PURE__ */ r(\"div\", { className: \"self-start flex items-center justify-center [&_svg]:size-5 shrink-0\", children: T({ variant: a, icon: o, theme: e }) }),\n        /* @__PURE__ */ g(\"div\", { className: \"flex items-start justify-start gap-1 mr-10 [&>span:first-child]:shrink-0\", children: [\n          S({ title: d, theme: e }),\n          w({ content: f, theme: e })\n        ] }),\n        /* @__PURE__ */ r(\"div\", { className: \"absolute right-3 top-3 [&_svg]:size-5\", children: /* @__PURE__ */ r(\n          \"button\",\n          {\n            className: u(\n              \"bg-transparent m-0 p-0 border-none focus:outline-none active:outline-none cursor-pointer\",\n              m[e] ?? m.light\n            ),\n            onClick: () => i(n.id),\n            children: /* @__PURE__ */ r(j, {})\n          }\n        ) })\n      ]\n    }\n  )), b;\n}, I = $(q);\nexport {\n  B as Toast,\n  q as Toaster,\n  I as default\n};\n//# sourceMappingURL=toaster.es.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst LoaderCircle = createLucideIcon(\"LoaderCircle\", [\n  [\"path\", { d: \"M21 12a9 9 0 1 1-6.219-8.56\", key: \"13zald\" }]\n]);\n\nexport { LoaderCircle as default };\n//# sourceMappingURL=loader-circle.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst LockOpen = createLucideIcon(\"LockOpen\", [\n  [\"rect\", { width: \"18\", height: \"11\", x: \"3\", y: \"11\", rx: \"2\", ry: \"2\", key: \"1w4ew1\" }],\n  [\"path\", { d: \"M7 11V7a5 5 0 0 1 9.9-1\", key: \"1mm8w8\" }]\n]);\n\nexport { LockOpen as default };\n//# sourceMappingURL=lock-open.js.map\n","import React, { useState } from 'react';\nimport apiFetch from '@wordpress/api-fetch';\nimport { Container, Title, Button, Toaster, toast } from \"@bsf/force-ui\";\nimport { LoaderCircle } from \"lucide-react\";\nimport { __, sprintf } from '@wordpress/i18n';\nimport { LockOpen } from 'lucide-react';\n\nconst License = () => {\n\tconst [licenseKey, setlicenseKey] = useState('');\n\tconst [loading, setLoading] = useState(false);\n\tconst [errorMessage, setErrorMessage] = useState('');\n\n\tconst licenseStatus = uaelSettingsData.license_status;\n\tconst licensePlaceholder = licenseStatus ? __('Your license is active.', 'uael') : __('Paste your license key here', 'uael');\n\tconst isWhiteLabel = uaelSettingsData.is_whitelabel;\n\n\tconst activateHandler = () => {\n\t\tif (!licenseKey) {\n\t\t\ttoast.error(__('Please enter a valid license key!', 'uael'));\n\t\t\tsetErrorMessage(__('Enter a valid license key!', 'uael'));\n\t\t\treturn;\n\t\t}\n\n\t\tsetLoading(true);\n\t\tsetErrorMessage('');\n\n\t\tconst formData = new window.FormData();\n\t\tformData.append('key', licenseKey);\n\t\tformData.append('action', 'uael_license_activation');\n\t\tformData.append('security', uaelSettingsData.license_activation_nonce);\n\n\t\tapiFetch({\n\t\t\turl: uaelSettingsData.ajax_url,\n\t\t\tmethod: 'POST',\n\t\t\tbody: formData,\n\t\t}).then((data) => {\n\t\t\tsetLoading(false);\n\t\t\tif (data.success) {\n\t\t\t\ttoast.success(__('License successfully validated!', 'uael'));\n\t\t\t\tlocation.reload();\n\t\t\t} else {\n\t\t\t\ttoast.error(data.message || __('Please enter a valid license key!', 'uael'));\n\t\t\t\tsetErrorMessage(data.message || __('Enter a valid license key!', 'uael')); // Set error message.\n\t\t\t}\n\t\t});\n\t};\n\n\tconst deactivateHandler = () => {\n\t\tsetLoading(true);\n\t\tsetErrorMessage('');\n\n\t\tconst formData = new window.FormData();\n\t\tformData.append('action', 'uael_license_deactivation');\n\t\tformData.append('security', uaelSettingsData.license_deactivation_nonce);\n\n\t\tapiFetch({\n\t\t\turl: uaelSettingsData.ajax_url,\n\t\t\tmethod: 'POST',\n\t\t\tbody: formData,\n\t\t}).then((data) => {\n\t\t\tsetLoading(false);\n\t\t\tif (data.success) {\n\t\t\t\ttoast.success(__('License successfully deactivated!', 'uael')); // Show toast notification on success\n\t\t\t\tlocation.reload();\n\t\t\t} else {\n\t\t\t\ttoast.error(data.message || __('An error occurred while deactivating license.', 'uael'));\n\t\t\t\tsetErrorMessage(data.message || __('An error occurred while deactivating license.', 'uael'));\n\t\t\t}\n\t\t});\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<Toaster dismissAfter={3000} />\n\t\t\t<Container\n\t\t\t\talign=\"stretch\"\n\t\t\t\tclassName=\"bg-background-primary p-6 rounded-lg \"\n\t\t\t\tcontainerType=\"flex\"\n\t\t\t\tdirection=\"column\"\n\t\t\t\tgap=\"\"\n\t\t\t\tjustify=\"start\"\n\t\t\t\tstyle={{\n\t\t\t\t\tmarginTop: \"24px\",\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<Container.Item className=\"flex flex-col space-y-2\">\n\t\t\t\t\t<span className=\"inline-flex items-center justify-center w-8 h-8 rounded-md border border-solid p-1\" style={{ borderColor: 'rgb(230, 230, 239)' }}>\n\t\t\t\t\t\t<LockOpen size={24} className=\"text-gray-600\" />\n\t\t\t\t\t</span>\n\t\t\t\t\t<h3 className='m-0 flex items-center text-2xl font-semibold'>{licenseStatus ? __('Your License', 'uael') : __('License not active', 'uael')}</h3>\n\t\t\t\t\t{licenseStatus ? (\n\t\t\t\t\t\t<p className=\"text-sm font-normal m-0\">\n\t\t\t\t\t\t\t{sprintf(\n\t\t\t\t\t\t\t\t__('You are using %s Pro!', 'uael'),\n\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t</p>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<p className=\"text-sm font-normal m-0\">\n\t\t\t\t\t\t\t\t{isWhiteLabel ? (\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t{sprintf(\n\t\t\t\t\t\t\t\t\t\t\t__('Activate %s Pro to get professional support and automatic updates from your WordPress dashboard.', 'uael'),\n\t\t\t\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name\n\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t{__('Activate', 'uael')}{' '}\n\t\t\t\t\t\t\t\t\t\t<a\n\t\t\t\t\t\t\t\t\t\t\thref=\"https://ultimateelementor.com/pricing/?utm_source=free-plugin&utm_medium=dashboard&utm_campaign=upgrade\"\n\t\t\t\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t\t\t\t\tclassName='text-link-primary'\n\t\t\t\t\t\t\t\t\t\t\tstyle = {{ color:'#6005FF', }}\n\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t{uaelSettingsData.plugin_short_name} Pro\n\t\t\t\t\t\t\t\t\t\t</a>{' '}\n\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t'to get professional support and automatic updates from your WordPress dashboard.',\n\t\t\t\t\t\t\t\t\t\t\t'uael'\n\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t<p className=\"text-sm font-normal m-0\">\n\t\t\t\t\t\t\t\t{sprintf(\n\t\t\t\t\t\t\t\t\t__('Please enter your valid license key below to activate %s Pro!', 'uael'),\n\t\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t{!isWhiteLabel && (\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t{' '}\n\t\t\t\t\t\t\t\t\t\t<a\n\t\t\t\t\t\t\t\t\t\t\thref=\"https://store.brainstormforce.com/account/\"\n\t\t\t\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t\t\t\t\tclassName='text-link-primary'\n\t\t\t\t\t\t\t\t\t\t\tstyle = {{ color:'#6005FF', }}\n\t\t\t\t\t\t\t\t\t\t>\n\n\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t'Click Here',\n\t\t\t\t\t\t\t\t\t\t'uael'\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</a>{' '}\n\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t'to find your license key.',\n\t\t\t\t\t\t\t\t\t\t\t'uael'\n\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t</>\n\t\t\t\t\t)}\n\t\t\t\t</Container.Item>\n\t\t\t\t<Container.Item\n\t\t\t\t\t\tclassName=\"flex flex-col lg:flex-row gap-1 items-center mt-2 mb-2\"\n\t\t\t\t\t\talignSelf=\"auto\"\n\t\t\t\t\t\torder=\"none\"\n\t\t\t\t\t>\n\t\t\t\t\t\t<input\n\t\t\t\t\t\t\tvalue={licenseKey}\n\t\t\t\t\t\t\tonChange={(e) => setlicenseKey(e.target.value)}\n\t\t\t\t\t\t\tplaceholder={licensePlaceholder}\n\t\t\t\t\t\t\treadOnly={licenseStatus}\n\t\t\t\t\t\t\tsize=\"md\"\n\t\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\t\tclassName={`w-full shrink ${licenseStatus ? 'uael-green-placeholder' : 'uael-default-placeholder'}`}\n\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\theight: '48px',\n\t\t\t\t\t\t\t\toutline: 'none',       // Removes the default outline\n\t\t\t\t\t\t\t\tboxShadow: 'none',     // Removes the default box shadow\n\t\t\t\t\t\t\t\tborderColor: errorMessage ? 'red' : '#e0e0e0',\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tonFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n\t\t\t\t\t\t\tonBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<div className='cursor-pointer shrink'\n\t\t\t\t\t\t\tstyle={{ minWidth: \"fit-content\" }}>\n\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\ticon={loading ? <LoaderCircle className=\"animate-spin\" /> : null}\n\t\t\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\t\t\tstyle = {{ paddingTop: '14px', paddingBottom: '14px', borderColor: '#6005FF', outline: 'none', }}\n\t\t\t\t\t\t\t\tclassName=\"bg-[#6005FF] rounded-md border border-solid hover:bg-[#6005FF]\"\n\t\t\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\"#4B00CC\")\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\t\"#6005FF\")\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tonClick={licenseStatus ? deactivateHandler : activateHandler}\n\t\t\t\t\t\t\t\tdisabled={loading} // Disable button during loading to prevent multiple clicks.\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{loading\n\t\t\t\t\t\t\t\t\t? (licenseStatus ? __('Deactivating...', 'uael') : __('Activating...', 'uael'))\n\t\t\t\t\t\t\t\t\t: (licenseStatus ? __('Deactivate', 'uael') : __('Activate', 'uael'))}\n\t\t\t\t\t\t\t</Button>\n\t\t\t\t\t\t</div>\n\t\t\t\t</Container.Item>\n\t\t\t\t{!isWhiteLabel && (\n\t\t\t\t\t<p className=\"m-0 text-sm font-semibold text-link-primary no-underline mb-2\">\n\t\t\t\t\t\t\t\t<a className='no-underline'\n\t\t\t\t\t\t\t\t\thref={\n\t\t\t\t\t\t\t\t\t\tlicenseStatus\n\t\t\t\t\t\t\t\t\t\t\t? 'https://ultimateelementor.com/pricing/?utm_source=pro-plugin&utm_medium=dashboard&utm_campaign=more-upgrade'\n\t\t\t\t\t\t\t\t\t\t\t: 'https://store.brainstormforce.com/support'\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t\t\tstyle = {{ color:'#6005FF', }}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t{licenseStatus\n\t\t\t\t\t\t\t\t\t\t? __('Get another license?', 'uael')\n\t\t\t\t\t\t\t\t\t\t: __('Need Help?', 'uael')}\n\t\t\t\t\t\t\t\t</a>\n\t\t\t\t\t</p>\n\t\t\t\t)}\n\t\t\t\t{errorMessage && (\n\t\t\t\t\t<p className=\"text-red-500 text-xs\" style={{ color: 'red', marginTop: \"-10px\" }}>{errorMessage}</p> // Show error message below the input field\n\t\t\t\t)}\n\t\t\t</Container>\n\t\t</>\n\t);\n};\n\nexport default License;\n","import { Container } from \"@bsf/force-ui\";\nimport HeaderLine from '@components/HeaderLine'\nimport NavMenu from '@components/NavMenu'\nimport React from 'react'\nimport Widgets from './Widgets'\nimport TemplateSection from './TemplateSection'\nimport QuickAccess from './QuickAccess'\nimport WelcomeContainer from './WelcomeContainer'\nimport ExtendWebsite from './ExtendWebsite'\nimport VideoTutorials from \"./VideoTutorials\";\nimport QuickSettings from './QuickSettings';\nimport License from \"./License\";\n\nconst Dashboard = () => {\n    const width_class = !uaelSettingsData.hide_settings ? 'uael-65-width' : 'w-full';\n\n    return (\n        <>\n            <NavMenu />\n            <div className=\"\">\n                <HeaderLine />\n                <Container\n                    align=\"stretch\"\n                    className=\"p-6 flex flex-col lg:flex-row box-border\"\n                    containerType=\"flex\"\n                    direction=\"row\"\n                    gap=\"sm\"\n                    justify=\"start\"\n                    style={{\n                        width: \"100%\",\n                    }}\n                >\n                    <Container.Item\n                        className={`p-2 ${width_class}`}\n                        alignSelf=\"auto\"\n                        order=\"none\"\n                        shrink={0}\n                    >\n                        {!uaelSettingsData.hide_settings && (\n                            <WelcomeContainer />\n                        )}\n                        <div className=''>\n                            <QuickSettings />\n                        </div>\n                        {/* <Widgets /> */}\n                        {!uaelSettingsData.hide_settings && (\n                            <VideoTutorials />\n                        )}\n                         <ExtendWebsite />\n                    </Container.Item>\n                    {!uaelSettingsData.hide_settings && (\n                        <Container.Item\n                            className=\"p-2 w-full uael-35-width\"\n                            shrink={1}\n                        >\n                                  <TemplateSection />\n                            <div className=\"pt-2\">\n                              <QuickAccess />\n                            </div>\n                            <div className=\"pt-2\">\n                              <License />\n                            </div>\n                        </Container.Item>\n                    )}\n\n                </Container>\n            </div>\n        </>\n    )\n}\n\nexport default Dashboard\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Search = createLucideIcon(\"Search\", [\n  [\"circle\", { cx: \"11\", cy: \"11\", r: \"8\", key: \"4ej97u\" }],\n  [\"path\", { d: \"m21 21-4.3-4.3\", key: \"1qie3q\" }]\n]);\n\nexport { Search as default };\n//# sourceMappingURL=search.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Trash2 = createLucideIcon(\"Trash2\", [\n  [\"path\", { d: \"M3 6h18\", key: \"d0wm0j\" }],\n  [\"path\", { d: \"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6\", key: \"4alrt4\" }],\n  [\"path\", { d: \"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2\", key: \"v07s0e\" }],\n  [\"line\", { x1: \"10\", x2: \"10\", y1: \"11\", y2: \"17\", key: \"1uufr5\" }],\n  [\"line\", { x1: \"14\", x2: \"14\", y1: \"11\", y2: \"17\", key: \"xtxkd\" }]\n]);\n\nexport { Trash2 as default };\n//# sourceMappingURL=trash-2.js.map\n","import React, { useState, useEffect } from 'react';\nimport { Container, Button, Skeleton, Tooltip } from \"@bsf/force-ui\";\nimport { LoaderCircle, SearchIcon, Trash2Icon } from \"lucide-react\";\nimport WidgetItem from '@components/Dashboard/WidgetItem';\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from \"@wordpress/i18n\";\n\nconst FeatureWidgets = () => {\n    const [allWidgetsData, setAllWidgetsData] = useState(null);\n    const [searchTerm, setSearchTerm] = useState('');\n    const [loadingActivate, setLoadingActivate] = useState(false);\n    const [loadingDeactivateUnused, setLoadingDeactivateUnused] = useState(false);\n    const [loadingDeactivate, setLoadingDeactivate] = useState(false);\n    const [loading, setLoading] = useState(true);\n    const [updateCounter, setUpdateCounter] = useState(0);\n    const [showTooltip, setShowTooltip] = useState(true); // Add state for showTooltip\n\n    useEffect(() => {\n        const fetchSettings = () => {\n            setLoading(true);\n            apiFetch({\n                path: '/uael/v1/widgets',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action,\n                },\n            })\n                .then((data) => {\n                    const widgetsData = convertToWidgetsArray(data);\n                    setAllWidgetsData(widgetsData);\n                    setLoading(false);\n                })\n                .catch((err) => {\n                    setLoading(false);\n                });\n        };\n\n        fetchSettings();\n    }, []);\n\n    const handleSearchChange = (event) => {\n        setSearchTerm(event.target.value.toLowerCase());\n    };\n\n    const filteredWidgets = allWidgetsData?.filter(widget =>\n        widget.title.toLowerCase().includes(searchTerm) ||\n        widget.keywords?.some(keyword => keyword.toLowerCase().includes(searchTerm))\n    );\n\n    const handleActivateAll = async () => {\n        setLoadingActivate(true);\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_activate_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingActivate(false);\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: true }))\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else if (data.error) {\n                console.error('AJAX request failed:', data.error);\n            }\n        }).catch((error) => {\n            setLoadingActivate(false);\n            console.error('Error during AJAX request:', error);\n        });\n    };\n\n    const handleDeactivateUnused = async () => {\n        setLoadingDeactivateUnused(true);\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_deactivate_unused_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingDeactivateUnused(false);\n            if (data.success && Array.isArray(data.data?.deactivated)) {\n                const deactivatedSlugs = data.data.deactivated;\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget =>\n                        deactivatedSlugs.includes(widget.id)\n                            ? { ...widget, is_active: false }\n                            : widget\n                    )\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else if (data.error) {\n                console.error('AJAX request failed:', data.error);\n            } else {\n                console.error('Unexpected response structure:', data);\n            }\n        }).catch((error) => {\n            setLoadingDeactivateUnused(false);\n            console.error('Error during AJAX request:', error);\n        });\n    };\n\n    const handleDeactivateAll = async () => {\n        setLoadingDeactivate(true);\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_deactivate_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingDeactivate(false);\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: false }))\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else if (data.error) {\n                console.error('AJAX request failed:', data.error);\n            }\n        }).catch((error) => {\n            setLoadingDeactivate(false);\n            console.error('Error during AJAX request:', error);\n        });\n    };\n\n    function convertToWidgetsArray(data) {\n        const widgets = [];\n        for (const key in data) {\n            if (data.hasOwnProperty(key)) {\n                const widget = data[key];\n                widgets.push({\n                    id: key,\n                    slug: widget.slug,\n                    title: widget.title,\n                    keywords: widget.keywords,\n                    icon: <i className={widget.icon}></i>,\n                    title_url: widget.title_url,\n                    default: widget.default,\n                    doc_url: widget.doc_url,\n                    is_pro: widget.is_pro,\n                    description: widget.description,\n                    is_active: widget.is_activate !== undefined ? widget.is_activate : true,\n                    demo_url: widget.demo_url !== undefined ? widget.demo_url : widget.doc_url\n                });\n            }\n        }\n        return widgets;\n    }\n\n    return (\n        <div className='rounded-lg bg-white w-full mb-4'>\n            <div className='flex flex-col md:flex-row md:items-center md:justify-between p-4'\n                style={{\n                    paddingBottom: '0'\n                }}>\n                <p className='m-0 text-sm font-semibold text-text-primary mb-2 md:mb-0'>{__(\"Widgets / Features\", \"uael\")}</p>\n                <div className='flex flex-col md:flex-row items-center gap-y-2 md:gap-x-2 md:mr-7 relative'>\n                    <SearchIcon\n                        className=\"absolute top-1/2 transform -translate-y-1/2 text-gray-400\"\n                        style={{\n                            backgroundColor: '#F9FAFB',\n                            left: '2%',\n                            width: '18px',\n                            height: '18px'\n                        }} />\n                    <input\n                        type=\"search\"\n                        placeholder={__('Search...', 'uael')}\n                        className=\"mr-2 pl-10 w-full md:w-auto\"\n                        style={{\n                            height: '40px',\n                            borderColor: '#e0e0e0', // Default border color\n                            outline: 'none',       // Removes the default outline\n                            boxShadow: 'none',\n                            backgroundColor: '#F9FAFB',    // Removes the default box shadow\n                        }}\n                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                        onChange={handleSearchChange}\n                    />\n                    <div className=\"flex flex-row gap-2 w-full md:w-auto\">\n                        <Tooltip\n                            arrow\n                            content={\n                                <div>\n                                    <p>{__('Click here to activate all widgets & extensions.', 'uael')}</p>\n                                </div>\n                            }\n                            placement=\"top\"\n                            title=\"\"\n                            triggers={[\n                                'hover'\n                            ]}\n                            variant=\"dark\"\n                            size=\"xs\"\n                        >\n                            <Button\n                                icon={loadingActivate ? <LoaderCircle className=\"animate-spin\" /> : null}\n                                iconPosition=\"left\"\n                                variant=\"outline\"\n                                className=\"uae-bulk-action-button\"\n                                onClick={handleActivateAll}\n                                disabled={!!searchTerm}\n                            >\n                                {loadingActivate ? __('Activating...', 'uael') : __('Activate All', 'uael')}\n                            </Button>\n                        </Tooltip>\n                        <Tooltip \n                            arrow\n                            content={\n                                <div>\n                                    <p>{__('Click here to deactivate all unused widgets, except Extensions.', 'uael')}</p>\n                                </div>\n                            }\n                            placement=\"top\"\n                            title=\"\"\n                            triggers={[\n                                'hover'\n                            ]}\n                            variant=\"dark\"\n                            size=\"xs\"\n                        >\n                            <Button\n                                icon={loadingDeactivateUnused ? <LoaderCircle className=\"animate-spin\" /> : null}\n                                iconPosition=\"left\"\n                                variant=\"outline\"\n                                onClick={handleDeactivateUnused}\n                                className=\"uae-bulk-action-button\"\n                                disabled={!!searchTerm}\n                            >\n                                {loadingDeactivateUnused ? __('Deactivating...', 'uael') : __('Deactivate Unused', 'uael')}\n                            </Button>\n                        </Tooltip>\n                        <Tooltip\n                            arrow\n                            content={\n                                <div>\n                                    <p>{loadingDeactivate ? __('Deactivating...', 'uael') : __('Deactivate All ', 'uael')}</p>\n                                </div>\n                            }\n                            placement=\"top\"\n                            title=\"\"\n                            triggers={[\n                                'hover'\n                            ]}\n                            variant=\"dark\"\n                            size=\"xs\"\n                        >\n                            <Trash2Icon    \n                                className=\"relative text-gray-400\"\n                                onClick={handleDeactivateAll}\n                                style={{\n                                    backgroundColor: '#F9FAFB',\n                                    top: '5%',\n                                    margin: 'auto',\n                                    width: '22px',\n                                    height: '22px'\n                                }}\n                            >\n                                {loadingDeactivate ? __('Deactivating...', 'uael') : __('Deactivate All', 'uael')}\n                            </Trash2Icon>\n                        </Tooltip>\n                      \n                    </div>\n                </div>\n            </div>\n            <div className='flex bg-black flex-col rounded-lg p-4' style={{ minHeight: \"800px\" }}>\n                {loading ? (\n                    <Container\n                        align=\"stretch\"\n                        className=\"p-1 gap-1.5 grid-cols-2 md:grid-cols-4\"\n                        containerType=\"grid\"\n                        gap=\"\"\n                        justify=\"start\"\n                        style={{\n                            backgroundColor: '#F9FAFB'\n                        }}\n                    >\n                        {[...Array(50)].map((_, index) => (\n                            <Container.Item\n                                key={index}\n                                alignSelf=\"auto\"\n                                className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-6 space-y-2\"\n                            >\n                                <Skeleton className='w-12 h-2 rounded-md' />\n                                <Skeleton className='w-16 h-2 rounded-md' />\n                                <Skeleton className='w-12 h-2 rounded-md' />\n                            </Container.Item>\n                        ))}\n                    </Container>\n                ) : (\n                    <Container\n                        align=\"stretch\"\n                        className=\"p-1 gap-1.5 grid-cols-2 md:grid-cols-4\"\n                        containerType=\"grid\"\n                        gap=\"\"\n                        justify=\"start\"\n                        style={{\n                            backgroundColor: '#F9FAFB'\n                        }}\n                    >\n                        {filteredWidgets?.map((widget) => (\n                            <Container.Item\n                                key={widget.id}\n                                alignSelf=\"auto\"\n                                className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-4\"\n                            >\n                                <WidgetItem widget={{ ...widget, updateCounter }} showTooltip={showTooltip} key={widget.id} updateCounter={updateCounter} />\n                            </Container.Item>\n                        ))}\n                    </Container>\n                )}\n            </div>\n        </div>\n    );\n}\n\nexport default FeatureWidgets;","import HeaderLine from '@components/HeaderLine'\nimport NavMenu from '@components/NavMenu'\nimport { Container } from \"@bsf/force-ui\";\nimport React from 'react'\nimport ExtendWebsite from '@components/Dashboard/ExtendWebsite';\nimport QuickAccess from '@components/Dashboard/QuickAccess';\nimport FeatureWidgets from './Features/FeatureWidgets'\n\nconst Features = () => {\n    const width_class = !uaelSettingsData.hide_settings ? 'uael-65-width' : 'w-full';\n    return (\n        <>\n            <NavMenu />\n            <div className=\"\">\n                <HeaderLine />\n                <Container\n                    align=\"stretch\"\n                    className=\"p-6 flex flex-col lg:flex-row box-border\"\n                    containerType=\"flex\"\n                    direction=\"row\"\n                    gap=\"sm\"\n                    justify=\"start\"\n                    style={{\n                        width: \"100%\",\n                    }}\n                >\n                    <Container.Item\n                        className={`p-2 ${width_class}`}\n                        alignSelf=\"auto\"\n                        order=\"none\"\n                        shrink={1}\n                    >\n                        <FeatureWidgets />\n                    </Container.Item>\n                    {!uaelSettingsData.hide_settings && (\n                        <Container.Item\n                            className=\"p-2 uael-35-width\"\n                            shrink={1}\n                        >\n                            <QuickAccess />\n                           <div className='pt-5'>\n                           {/* <ExtendWebsite /> */}\n                           </div>\n                        </Container.Item>\n                    )}\n                </Container>\n            </div>\n        </>\n    )\n}\n\nexport default Features","import React from 'react';\nimport { __ } from \"@wordpress/i18n\";\n\nconst Sidebar = ({ items, onSelectItem, selectedItemId }) => {\n  const handleSelectItem = (item) => {\n    onSelectItem(item); // Trigger onSelectItem callback passed from parent\n  };\n\n  return (\n    <div style={{ padding: \"1rem\", width: \"100%\" }}>\n      {/* Loop through items to render main title, icon, and title */}\n      {items.map((item) => (\n        <div key={item.id} className=\"mb-2\">\n          {item.main && (\n            <p className=\"text-sm text-text-tertiary font-normal mb-2\">\n              {__(item.main, 'uael')}\n            </p>\n          )}\n\n          {/* Each item with icon and title */}\n          <div\n            className={`h-10 flex items-center justify-start gap-2 px-2 rounded-md cursor-pointer ${selectedItemId === item.id ? 'bg-gray-100' : 'bg-background-primary'}`}\n            style={{\n              backgroundColor: selectedItemId === item.id ? '#F9FAFB' : '', // Apply background color when selected\n            }}\n            onClick={() => handleSelectItem(item)}\n          >\n            <span>\n              {selectedItemId === item.id ? item.selected : item.icon}\n            </span>\n            <p className=\"m-0 text-base font-normal\">{__(item.title, 'uael')}</p>\n            {item.badge && (\n              <span\n                style={{\n                  background: '#6005ff',\n                  color: '#fff',\n                  fontSize: '10px',\n                  fontWeight: 600,\n                  lineHeight: 1,\n                  padding: '3px 7px',\n                  borderRadius: '999px',\n                  letterSpacing: '0.02em',\n                }}\n              >\n                {item.badge}\n              </span>\n            )}\n          </div>\n        </div>\n      ))}\n    </div>\n  );\n};\n\nexport default Sidebar;\n","import React from 'react'\n\nconst Content = ({ selectedItem }) => {\n  return (\n    <div className=\"p-6\" style={{ marginLeft: '4px' }}>\n      <div>{selectedItem?.content}</div>\n    </div>\n  )\n}\n\nexport default Content\n","let e={data:\"\"},t=t=>{if(\"object\"==typeof window){let e=(t?t.querySelector(\"#_goober\"):window._goober)||Object.assign(document.createElement(\"style\"),{innerHTML:\" \",id:\"_goober\"});return e.nonce=window.__nonce__,e.parentNode||(t||document.head).appendChild(e),e.firstChild}return t||e},r=e=>{let r=t(e),l=r.data;return r.data=\"\",l},l=/(?:([\\u0080-\\uFFFF\\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\\s*)/g,a=/\\/\\*[^]*?\\*\\/|  +/g,n=/\\n+/g,o=(e,t)=>{let r=\"\",l=\"\",a=\"\";for(let n in e){let c=e[n];\"@\"==n[0]?\"i\"==n[1]?r=n+\" \"+c+\";\":l+=\"f\"==n[1]?o(c,n):n+\"{\"+o(c,\"k\"==n[1]?\"\":t)+\"}\":\"object\"==typeof c?l+=o(c,t?t.replace(/([^,])+/g,e=>n.replace(/([^,]*:\\S+\\([^)]*\\))|([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+\" \"+t:t)):n):null!=c&&(n=/^--/.test(n)?n:n.replace(/[A-Z]/g,\"-$&\").toLowerCase(),a+=o.p?o.p(n,c):n+\":\"+c+\";\")}return r+(t&&a?t+\"{\"+a+\"}\":a)+l},c={},s=e=>{if(\"object\"==typeof e){let t=\"\";for(let r in e)t+=r+s(e[r]);return t}return e},i=(e,t,r,i,p)=>{let u=s(e),d=c[u]||(c[u]=(e=>{let t=0,r=11;for(;t<e.length;)r=101*r+e.charCodeAt(t++)>>>0;return\"go\"+r})(u));if(!c[d]){let t=u!==e?e:(e=>{let t,r,o=[{}];for(;t=l.exec(e.replace(a,\"\"));)t[4]?o.shift():t[3]?(r=t[3].replace(n,\" \").trim(),o.unshift(o[0][r]=o[0][r]||{})):o[0][t[1]]=t[2].replace(n,\" \").trim();return o[0]})(e);c[d]=o(p?{[\"@keyframes \"+d]:t}:t,r?\"\":\".\"+d)}let f=r&&c.g?c.g:null;return r&&(c.g=c[d]),((e,t,r,l)=>{l?t.data=t.data.replace(l,e):-1===t.data.indexOf(e)&&(t.data=r?e+t.data:t.data+e)})(c[d],t,i,f),d},p=(e,t,r)=>e.reduce((e,l,a)=>{let n=t[a];if(n&&n.call){let e=n(r),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;n=t?\".\"+t:e&&\"object\"==typeof e?e.props?\"\":o(e,\"\"):!1===e?\"\":e}return e+l+(null==n?\"\":n)},\"\");function u(e){let r=this||{},l=e.call?e(r.p):e;return i(l.unshift?l.raw?p(l,[].slice.call(arguments,1),r.p):l.reduce((e,t)=>Object.assign(e,t&&t.call?t(r.p):t),{}):l,t(r.target),r.g,r.o,r.k)}let d,f,g,b=u.bind({g:1}),h=u.bind({k:1});function m(e,t,r,l){o.p=t,d=e,f=r,g=l}function w(e,t){let r=this||{};return function(){let l=arguments;function a(n,o){let c=Object.assign({},n),s=c.className||a.className;r.p=Object.assign({theme:f&&f()},c),r.o=/ *go\\d+/.test(s),c.className=u.apply(r,l)+(s?\" \"+s:\"\"),t&&(c.ref=o);let i=e;return e[0]&&(i=c.as||e,delete c.as),g&&i[0]&&g(c),d(i,c)}return t?t(a):a}}export{u as css,r as extractCss,b as glob,h as keyframes,m as setup,w as styled};\n","\"use client\";\nvar Z=e=>typeof e==\"function\",h=(e,t)=>Z(e)?e(t):e;var W=(()=>{let e=0;return()=>(++e).toString()})(),E=(()=>{let e;return()=>{if(e===void 0&&typeof window<\"u\"){let t=matchMedia(\"(prefers-reduced-motion: reduce)\");e=!t||t.matches}return e}})();import{useEffect as ee,useState as te,useRef as oe}from\"react\";var re=20,k=\"default\";var H=(e,t)=>{let{toastLimit:o}=e.settings;switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,o)};case 1:return{...e,toasts:e.toasts.map(r=>r.id===t.toast.id?{...r,...t.toast}:r)};case 2:let{toast:s}=t;return H(e,{type:e.toasts.find(r=>r.id===s.id)?1:0,toast:s});case 3:let{toastId:a}=t;return{...e,toasts:e.toasts.map(r=>r.id===a||a===void 0?{...r,dismissed:!0,visible:!1}:r)};case 4:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(r=>r.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let i=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(r=>({...r,pauseDuration:r.pauseDuration+i}))}}},v=[],j={toasts:[],pausedAt:void 0,settings:{toastLimit:re}},f={},Y=(e,t=k)=>{f[t]=H(f[t]||j,e),v.forEach(([o,s])=>{o===t&&s(f[t])})},_=e=>Object.keys(f).forEach(t=>Y(e,t)),Q=e=>Object.keys(f).find(t=>f[t].toasts.some(o=>o.id===e)),S=(e=k)=>t=>{Y(t,e)},se={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},V=(e={},t=k)=>{let[o,s]=te(f[t]||j),a=oe(f[t]);ee(()=>(a.current!==f[t]&&s(f[t]),v.push([t,s]),()=>{let r=v.findIndex(([l])=>l===t);r>-1&&v.splice(r,1)}),[t]);let i=o.toasts.map(r=>{var l,g,T;return{...e,...e[r.type],...r,removeDelay:r.removeDelay||((l=e[r.type])==null?void 0:l.removeDelay)||(e==null?void 0:e.removeDelay),duration:r.duration||((g=e[r.type])==null?void 0:g.duration)||(e==null?void 0:e.duration)||se[r.type],style:{...e.style,...(T=e[r.type])==null?void 0:T.style,...r.style}}});return{...o,toasts:i}};var ie=(e,t=\"blank\",o)=>({createdAt:Date.now(),visible:!0,dismissed:!1,type:t,ariaProps:{role:\"status\",\"aria-live\":\"polite\"},message:e,pauseDuration:0,...o,id:(o==null?void 0:o.id)||W()}),P=e=>(t,o)=>{let s=ie(t,e,o);return S(s.toasterId||Q(s.id))({type:2,toast:s}),s.id},n=(e,t)=>P(\"blank\")(e,t);n.error=P(\"error\");n.success=P(\"success\");n.loading=P(\"loading\");n.custom=P(\"custom\");n.dismiss=(e,t)=>{let o={type:3,toastId:e};t?S(t)(o):_(o)};n.dismissAll=e=>n.dismiss(void 0,e);n.remove=(e,t)=>{let o={type:4,toastId:e};t?S(t)(o):_(o)};n.removeAll=e=>n.remove(void 0,e);n.promise=(e,t,o)=>{let s=n.loading(t.loading,{...o,...o==null?void 0:o.loading});return typeof e==\"function\"&&(e=e()),e.then(a=>{let i=t.success?h(t.success,a):void 0;return i?n.success(i,{id:s,...o,...o==null?void 0:o.success}):n.dismiss(s),a}).catch(a=>{let i=t.error?h(t.error,a):void 0;i?n.error(i,{id:s,...o,...o==null?void 0:o.error}):n.dismiss(s)}),e};import{useEffect as X,useCallback as A,useRef as ne}from\"react\";var ce=1e3,w=(e,t=\"default\")=>{let{toasts:o,pausedAt:s}=V(e,t),a=ne(new Map).current,i=A((c,m=ce)=>{if(a.has(c))return;let p=setTimeout(()=>{a.delete(c),r({type:4,toastId:c})},m);a.set(c,p)},[]);X(()=>{if(s)return;let c=Date.now(),m=o.map(p=>{if(p.duration===1/0)return;let R=(p.duration||0)+p.pauseDuration-(c-p.createdAt);if(R<0){p.visible&&n.dismiss(p.id);return}return setTimeout(()=>n.dismiss(p.id,t),R)});return()=>{m.forEach(p=>p&&clearTimeout(p))}},[o,s,t]);let r=A(S(t),[t]),l=A(()=>{r({type:5,time:Date.now()})},[r]),g=A((c,m)=>{r({type:1,toast:{id:c,height:m}})},[r]),T=A(()=>{s&&r({type:6,time:Date.now()})},[s,r]),d=A((c,m)=>{let{reverseOrder:p=!1,gutter:R=8,defaultPosition:z}=m||{},O=o.filter(u=>(u.position||z)===(c.position||z)&&u.height),K=O.findIndex(u=>u.id===c.id),B=O.filter((u,I)=>I<K&&u.visible).length;return O.filter(u=>u.visible).slice(...p?[B+1]:[0,B]).reduce((u,I)=>u+(I.height||0)+R,0)},[o]);return X(()=>{o.forEach(c=>{if(c.dismissed)i(c.id,c.removeDelay);else{let m=a.get(c.id);m&&(clearTimeout(m),a.delete(c.id))}})},[o,i]),{toasts:o,handlers:{updateHeight:g,startPause:l,endPause:T,calculateOffset:d}}};import*as y from\"react\";import{styled as J,keyframes as G}from\"goober\";import*as b from\"react\";import{styled as U,keyframes as xe}from\"goober\";import{styled as pe,keyframes as M}from\"goober\";var de=M`\nfrom {\n  transform: scale(0) rotate(45deg);\n\topacity: 0;\n}\nto {\n transform: scale(1) rotate(45deg);\n  opacity: 1;\n}`,me=M`\nfrom {\n  transform: scale(0);\n  opacity: 0;\n}\nto {\n  transform: scale(1);\n  opacity: 1;\n}`,le=M`\nfrom {\n  transform: scale(0) rotate(90deg);\n\topacity: 0;\n}\nto {\n  transform: scale(1) rotate(90deg);\n\topacity: 1;\n}`,C=pe(\"div\")`\n  width: 20px;\n  opacity: 0;\n  height: 20px;\n  border-radius: 10px;\n  background: ${e=>e.primary||\"#ff4b4b\"};\n  position: relative;\n  transform: rotate(45deg);\n\n  animation: ${de} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)\n    forwards;\n  animation-delay: 100ms;\n\n  &:after,\n  &:before {\n    content: '';\n    animation: ${me} 0.15s ease-out forwards;\n    animation-delay: 150ms;\n    position: absolute;\n    border-radius: 3px;\n    opacity: 0;\n    background: ${e=>e.secondary||\"#fff\"};\n    bottom: 9px;\n    left: 4px;\n    height: 2px;\n    width: 12px;\n  }\n\n  &:before {\n    animation: ${le} 0.15s ease-out forwards;\n    animation-delay: 180ms;\n    transform: rotate(90deg);\n  }\n`;import{styled as ue,keyframes as fe}from\"goober\";var Te=fe`\n  from {\n    transform: rotate(0deg);\n  }\n  to {\n    transform: rotate(360deg);\n  }\n`,F=ue(\"div\")`\n  width: 12px;\n  height: 12px;\n  box-sizing: border-box;\n  border: 2px solid;\n  border-radius: 100%;\n  border-color: ${e=>e.secondary||\"#e0e0e0\"};\n  border-right-color: ${e=>e.primary||\"#616161\"};\n  animation: ${Te} 1s linear infinite;\n`;import{styled as ye,keyframes as q}from\"goober\";var ge=q`\nfrom {\n  transform: scale(0) rotate(45deg);\n\topacity: 0;\n}\nto {\n  transform: scale(1) rotate(45deg);\n\topacity: 1;\n}`,he=q`\n0% {\n\theight: 0;\n\twidth: 0;\n\topacity: 0;\n}\n40% {\n  height: 0;\n\twidth: 6px;\n\topacity: 1;\n}\n100% {\n  opacity: 1;\n  height: 10px;\n}`,L=ye(\"div\")`\n  width: 20px;\n  opacity: 0;\n  height: 20px;\n  border-radius: 10px;\n  background: ${e=>e.primary||\"#61d345\"};\n  position: relative;\n  transform: rotate(45deg);\n\n  animation: ${ge} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)\n    forwards;\n  animation-delay: 100ms;\n  &:after {\n    content: '';\n    box-sizing: border-box;\n    animation: ${he} 0.2s ease-out forwards;\n    opacity: 0;\n    animation-delay: 200ms;\n    position: absolute;\n    border-right: 2px solid;\n    border-bottom: 2px solid;\n    border-color: ${e=>e.secondary||\"#fff\"};\n    bottom: 6px;\n    left: 6px;\n    height: 10px;\n    width: 6px;\n  }\n`;var be=U(\"div\")`\n  position: absolute;\n`,Se=U(\"div\")`\n  position: relative;\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  min-width: 20px;\n  min-height: 20px;\n`,Ae=xe`\nfrom {\n  transform: scale(0.6);\n  opacity: 0.4;\n}\nto {\n  transform: scale(1);\n  opacity: 1;\n}`,Pe=U(\"div\")`\n  position: relative;\n  transform: scale(0.6);\n  opacity: 0.4;\n  min-width: 20px;\n  animation: ${Ae} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)\n    forwards;\n`,$=({toast:e})=>{let{icon:t,type:o,iconTheme:s}=e;return t!==void 0?typeof t==\"string\"?b.createElement(Pe,null,t):t:o===\"blank\"?null:b.createElement(Se,null,b.createElement(F,{...s}),o!==\"loading\"&&b.createElement(be,null,o===\"error\"?b.createElement(C,{...s}):b.createElement(L,{...s})))};var Re=e=>`\n0% {transform: translate3d(0,${e*-200}%,0) scale(.6); opacity:.5;}\n100% {transform: translate3d(0,0,0) scale(1); opacity:1;}\n`,Ee=e=>`\n0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}\n100% {transform: translate3d(0,${e*-150}%,-1px) scale(.6); opacity:0;}\n`,ve=\"0%{opacity:0;} 100%{opacity:1;}\",De=\"0%{opacity:1;} 100%{opacity:0;}\",Oe=J(\"div\")`\n  display: flex;\n  align-items: center;\n  background: #fff;\n  color: #363636;\n  line-height: 1.3;\n  will-change: transform;\n  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05);\n  max-width: 350px;\n  pointer-events: auto;\n  padding: 8px 10px;\n  border-radius: 8px;\n`,Ie=J(\"div\")`\n  display: flex;\n  justify-content: center;\n  margin: 4px 10px;\n  color: inherit;\n  flex: 1 1 auto;\n  white-space: pre-line;\n`,ke=(e,t)=>{let s=e.includes(\"top\")?1:-1,[a,i]=E()?[ve,De]:[Re(s),Ee(s)];return{animation:t?`${G(a)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${G(i)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},N=y.memo(({toast:e,position:t,style:o,children:s})=>{let a=e.height?ke(e.position||t||\"top-center\",e.visible):{opacity:0},i=y.createElement($,{toast:e}),r=y.createElement(Ie,{...e.ariaProps},h(e.message,e));return y.createElement(Oe,{className:e.className,style:{...a,...o,...e.style}},typeof s==\"function\"?s({icon:i,message:r}):y.createElement(y.Fragment,null,i,r))});import{css as _e,setup as Ve}from\"goober\";import*as x from\"react\";Ve(x.createElement);var we=({id:e,className:t,style:o,onHeightUpdate:s,children:a})=>{let i=x.useCallback(r=>{if(r){let l=()=>{let g=r.getBoundingClientRect().height;s(e,g)};l(),new MutationObserver(l).observe(r,{subtree:!0,childList:!0,characterData:!0})}},[e,s]);return x.createElement(\"div\",{ref:i,className:t,style:o},a)},Me=(e,t)=>{let o=e.includes(\"top\"),s=o?{top:0}:{bottom:0},a=e.includes(\"center\")?{justifyContent:\"center\"}:e.includes(\"right\")?{justifyContent:\"flex-end\"}:{};return{left:0,right:0,display:\"flex\",position:\"absolute\",transition:E()?void 0:\"all 230ms cubic-bezier(.21,1.02,.73,1)\",transform:`translateY(${t*(o?1:-1)}px)`,...s,...a}},Ce=_e`\n  z-index: 9999;\n  > * {\n    pointer-events: auto;\n  }\n`,D=16,Fe=({reverseOrder:e,position:t=\"top-center\",toastOptions:o,gutter:s,children:a,toasterId:i,containerStyle:r,containerClassName:l})=>{let{toasts:g,handlers:T}=w(o,i);return x.createElement(\"div\",{\"data-rht-toaster\":i||\"\",style:{position:\"fixed\",zIndex:9999,top:D,left:D,right:D,bottom:D,pointerEvents:\"none\",...r},className:l,onMouseEnter:T.startPause,onMouseLeave:T.endPause},g.map(d=>{let c=d.position||t,m=T.calculateOffset(d,{reverseOrder:e,gutter:s,defaultPosition:t}),p=Me(c,m);return x.createElement(we,{id:d.id,key:d.id,onHeightUpdate:T.updateHeight,className:d.visible?Ce:\"\",style:p},d.type===\"custom\"?h(d.message,d):a?a(d):x.createElement(N,{toast:d,position:c}))}))};var zt=n;export{L as CheckmarkIcon,C as ErrorIcon,F as LoaderIcon,N as ToastBar,$ as ToastIcon,Fe as Toaster,zt as default,h as resolveValue,n as toast,w as useToaster,V as useToasterStore};\n//# sourceMappingURL=index.mjs.map","import React, { useState, useEffect } from 'react';\nimport { Container, Title, Label } from \"@bsf/force-ui\";\nimport { __ } from '@wordpress/i18n';\nimport toast, { Toaster } from 'react-hot-toast';\n\nconst radioData = [\n    {\n        id: \"1\",\n        title: __('Option 1 (Recommended)', 'uael'),\n        description: __(\"This option will automatically replace your theme's header and footer files with custom templates from the plugin. It works with most themes and is selected by default.\", \"uael\"),\n        value: \"1\"\n    },\n    {\n        id: \"2\",\n        title: __('Option 2', 'uael'),\n        description: __(\"This option will automatically replace your theme's header and footer files with custom templates from the plugin. It works with most themes and is selected by default.\", \"uael\"),\n        value: \"2\"\n    }\n];\n\nconst ThemeSupport = () => {\n    // State to store the selected radio option\n    const [selectedOption, setSelectedOption] = useState(uaelSettingsData.theme_option);\n\n    const [isInitialLoad, setIsInitialLoad] = useState(true);\n\n    useEffect(() => {\n        setIsInitialLoad(false);\n    }, []);\n\n    const handleRadioChange = (event) => {\n        const newValue = event.target.value;\n        setSelectedOption(newValue); // Update the selected option in state\n\n        // Only send the AJAX call if this is not the initial load\n        if (!isInitialLoad) {\n            saveOption(newValue);\n        }\n    };\n\n    // Function to save the selected option.\n    const saveOption = async (option) => {\n        try {\n            const response = await fetch(uaelSettingsData.ajax_url, {\n                method: 'POST',\n                headers: {\n                    'Content-Type': 'application/x-www-form-urlencoded',\n                },\n                body: new URLSearchParams({\n                    action: 'save_hfe_compatibility_option', // WordPress action for your AJAX handler\n                    hfe_compatibility_option: option,\n                    nonce: uaelSettingsData.ajax_nonce // Nonce for security\n                })\n            });\n\n            const result = await response.json();\n\n            if (result.success) {\n                toast.success(\"Settings saved successfully!\");\n            } else {\n                toast.error(\"Failed to save settings\");\n            }\n        } catch (error) {\n            toast.error(\"Error saving settings\");\n        }\n    };\n\n    return (\n        <>\n            <Title\n                description=\"\"\n                icon={null}\n                iconPosition=\"right\"\n                size=\"sm\"\n                tag=\"h2\"\n                title=\"Theme Support\"\n            />\n            <Container\n                align=\"stretch\"\n                className=\"bg-background-primary p-6 rounded-lg\"\n                containerType=\"flex\"\n                direction=\"column\"\n                gap=\"sm\"\n                justify=\"start\"\n                style={{\n                    marginTop: \"24px\",\n                    maxWidth: \"696px\",\n                }}\n            >\n                <Container.Item className=\"flex flex-col space-y-1\">\n                    <p className='text-base font-semibold m-0'>{__('Select Option to Add Theme Support', 'uael')}</p>\n                    <p className='text-sm font-normal m-0'>\n                        {__(\n                            `To ensure compatibility between the ${uaelSettingsData.plugin_short_name}'s header/footer and your theme, please choose one of the following options to enable theme support:`,\n                            'uael'\n                        )}\n                    </p>\n                </Container.Item>\n                <Container.Item\n                    className=\"p-2 space-y-4\"\n                    alignSelf=\"auto\"\n                    order=\"none\"\n                >\n                    {radioData.map((item) => (\n                        <div key={item.id} className='flex items-start gap-1 justify-center cursor-pointer'>\n                            <input\n                                id={item.id}\n                                value={item.value}\n                                type='radio'\n                                className='mt-1 cursor-pointer uae-radio-field'\n                                name=\"hfe_compatibility_option\" // Group radio buttons\n                                onChange={handleRadioChange} // Track the change\n                                checked={selectedOption === item.value} // Controlled input.\n                            />\n                            <div className='flex flex-col cursor-pointer'>\n                                <Label\n                                    size=\"sm\"\n                                    variant=\"neutral\"\n                                    className='text-sm font-semibold text-text-secondary cursor-pointer flex flex-col items-start justify-start'\n                                    htmlFor={item.id}\n                                >\n                                    {item.title}:\n                                    <p className='m-0 text-sm font-normal text-text-secondary cursor-pointer'>{item.description}</p>\n                                </Label>\n                            </div>\n                        </div>\n                    ))}\n                </Container.Item>\n\n                <div className='flex items-center p-4 border rounded-md text-start' style={{\n                    paddingTop: '16px',\n                    paddingBottom: '16px',\n                    backgroundColor: \"#F3F0FF\",\n                }}>\n                    <p className='m-0'>\n                        <strong>{__('Note:', 'uael')}</strong> {__('If neither option works, please contact your theme author to add support for this plugin.', 'uael')}\n                    </p>\n                </div>\n            </Container>\n\n            <Toaster\n                position=\"top-right\"\n                reverseOrder={false}\n                gutter={8}\n                containerStyle={{\n                    top: 20,\n                    right: 20,\n                    marginTop: '80px',\n                }}\n                toastOptions={{\n                    duration: 5000,\n                    style: {\n                        background: 'white',\n                    },\n                    success: {\n                        duration: 3000,\n                        style: {\n                            color: '',\n                        },\n                        iconTheme: {\n                            primary: '#6005ff',\n                            secondary: '#fff',\n                        },\n                    },\n                }}\n            />\n        </>\n    );\n};\n\nexport default ThemeSupport;\n","import React, { useState, useEffect, useRef } from 'react';\nimport { Container, Title, Switch, Button, Dialog } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ , sprintf } from '@wordpress/i18n';\n\nconst VersionControl = () => {\n    const [betaEnabled, setBetaEnabled] = useState(false);\n    const licenseStatus = uaelSettingsData.license_status;\n    const previousAddonVersions = uaelSettingsData.uael_versions;\n    const previousLiteVersions = uaelSettingsData.uaelite_versions;\n\n    const proVersionRef = useRef(previousAddonVersions[0].value);\n    const liteVersionRef = useRef(previousLiteVersions ? previousLiteVersions[0].value : '');\n\n    const [previousVersionSelect, setPreviousVersion] = useState(previousAddonVersions[0].value);\n    const [liteVersionSelect, setLiteVersionSelect] = useState(previousLiteVersions ? previousLiteVersions[0].value : '');\n    const [productSelect, setProductSelect] = useState('uael');\n    const [freeproductSelect, setFreeproductSelect] = useState('elementor-header-footer');\n\n    const [openPopup, setOpenPopup] = useState(false);\n    const [openLitePopup, setOpenLitePopup] = useState(false);\n\n    // Set default value when the component mounts.\n    useEffect(() => {\n        setBetaEnabled('enable' === uaelSettingsData.beta_enabled);\n    }, [openPopup, openLitePopup]);\n\n    const rollbackClickHandler = () => {\n        setPreviousVersion(proVersionRef.current.value);\n        setProductSelect('uael');\n        setOpenPopup(true);\n    };\n\n    const handleBetaSwitch = (event) => {\n        const allow_beta = event ? 'enable' : 'disable';\n\n        // Update the state of the Switch\n        setBetaEnabled(event);\n\n        // AJAX call to save the new value\n        const formData = new window.FormData();\n        formData.append('allow_beta', allow_beta); // Append allow_beta\n        formData.append('action', 'uael_allow_beta_updates'); // Append action\n        formData.append('nonce', uaelSettingsData.ajax_nonce); // Append nonce\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            if (data.success) {\n                // console.log(\"Beta status updated\");\n            } else {\n                setBetaEnabled(!event); // Revert to previous state\n            }\n        }).catch((error) => {\n            setBetaEnabled(!event); // Revert to previous state\n        });\n    };\n\n    const onCancelClick = () => {\n        setOpenPopup(false);\n    };\n\n    const onContinueClick = () => {\n        const rollbackUrl = uaelSettingsData.uael_rollback_url.replace(\n            'VERSION',\n            previousVersionSelect\n        );\n        setOpenPopup(false);\n        window.location.href = rollbackUrl;\n    };\n\n    const onLiteCancelClick = () => {\n        setOpenLitePopup(false);\n    };\n\n    const onLiteContinueClick = () => {\n        const rollbackUrl = uaelSettingsData.uaelite_rollback_url.replace(\n            'VERSION',\n            liteVersionSelect\n        );\n        setOpenLitePopup(false);\n        window.location.href = rollbackUrl;\n    };\n\n    const handleVersionChange = (event) => {\n        setPreviousVersion(event.target.value);\n    }\n\n    const handleLiteVersionChange = (event) => {\n        setLiteVersionSelect(event.target.value);\n    }\n\n    return (\n        <>\n            <Title\n                description=\"\"\n                icon={null}\n                iconPosition=\"right\"\n                size=\"sm\"\n                tag=\"h2\"\n                title={__('Version Control', 'uael')}\n            />\n            <div\n                className=\"box-border bg-background-primary p-6 rounded-lg\"\n                style={{\n                    marginTop: \"24px\",\n                }}\n            >\n                {uaelSettingsData.is_lite_active && (\n                    <>\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-col lg:flex-row\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                            gap=\"sm\"\n                            justify=\"start\"\n                        >\n                            <Container.Item className=\"shrink flex flex-col space-y-1\">\n                                <p className=\"text-base font-semibold m-0\">\n                                    {sprintf(\n                                        __('Rollback %s to Previous Version', 'uael'),\n                                        uaelSettingsData.plugin_short_name\n                                    )}\n                                </p>\n                                <p className=\"text-sm font-normal m-0\">\n                                    {__('Experiencing an issue with current version? Roll back to a previous version to help troubleshoot the issue.', 'uael')}\n                                </p>\n                            </Container.Item>\n                            <Container.Item\n                                className=\"p-2 flex space-y-4\"\n                                alignSelf=\"auto\"\n                                order=\"none\"\n                            >\n                                <div className=\"bsf-rollback-version\">\n                                    <input type=\"hidden\" name=\"product-name\" id=\"bsf-product-name\" value={'uael'} />\n                                    <select\n                                        id=\"uaeliteVersionRollback\"\n                                        ref={liteVersionRef}\n                                        onBlur={() => {\n                                            setFreeproductSelect('elementor-header-footer');\n                                        }}\n                                        onChange={handleLiteVersionChange}\n                                        style={{\n                                            padding: '8px',\n                                            marginRight: '10px',\n                                            marginTop: '16px',\n                                            cursor: 'pointer',\n                                            borderRadius: '4px',\n                                            height: '44px',\n                                            width: '100px',\n                                        }}\n                                    >\n                                        {previousLiteVersions.map((version) => (\n                                            <option key={version.value} value={version.value}>\n                                                {version.label}\n                                            </option>\n                                        ))}\n                                    </select>\n                                </div>\n\n                                <div className=\"flex flex-col cursor-pointer\">\n                                    <Dialog\n                                        design=\"simple\"\n                                        exitOnEsc\n                                        scrollLock\n                                        open={openLitePopup} // Ensure Dialog is controlled by state\n                                        setOpen={setOpenLitePopup} // Synchronize state\n                                        trigger={<Button style={{ backgroundColor: '#6005ff' }} >{__('Rollback', 'uael')}</Button>}\n                                    >\n                                        <Dialog.Backdrop />\n                                        <Dialog.Panel>\n                                            <Dialog.Header>\n                                                <div className=\"flex items-center justify-between\">\n                                                    <Dialog.Title>\n                                                        {__('Rollback to Previous Version', 'uael')}\n                                                    </Dialog.Title>\n                                                    <Dialog.CloseButton />\n                                                </div>\n                                            </Dialog.Header>\n                                            <Dialog.Body>\n                                                {sprintf(\n                                                    __('Are you sure you want to rollback to %s v%s?', 'uael'),\n                                                    uaelSettingsData.plugin_short_name,\n                                                    liteVersionSelect\n                                                )}\n                                            </Dialog.Body>\n                                            <Dialog.Footer>\n                                                <Button style={{ backgroundColor: '#6005ff' }} onClick={onLiteContinueClick}>\n                                                    {__('Rollback', 'uael')}\n                                                </Button>\n                                                <Button style={{ backgroundColor: '#6005ff' }} onClick={onLiteCancelClick}>\n                                                    {__('Cancel', 'uael')}\n                                                </Button>\n                                            </Dialog.Footer>\n                                        </Dialog.Panel>\n                                    </Dialog>\n                                </div>\n                            </Container.Item>\n                        </Container>\n                        <div\n                            className=\"border border-subtle\"\n                            style={{\n                                height: '2px',\n                                backgroundColor: '#E5E7EB',\n                                marginTop: '16px',\n                                marginBottom: '16px',\n                            }}\n                        />\n                    </>\n                )}\n                {licenseStatus && (\n                    <>\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-col lg:flex-row\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                            gap=\"sm\"\n                            justify=\"start\"\n                        >\n                            <Container.Item className=\"shrink flex flex-col space-y-1\">\n                                <p className=\"text-base font-semibold m-0\">\n                                    {sprintf(\n                                        __('Rollback %s Pro to Previous Version', 'uael'),\n                                        uaelSettingsData.plugin_short_name\n                                    )}\n                                </p>\n                                <p className=\"text-sm font-normal m-0\">\n                                    {__('Experiencing an issue with current version? Roll back to a previous version to help troubleshoot the issue.', 'uael')}\n                                </p>\n                            </Container.Item>\n                            <Container.Item\n                                className=\"p-2 flex space-y-4\"\n                                alignSelf=\"auto\"\n                                order=\"none\"\n                            >\n                                <div className=\"bsf-rollback-version\">\n                                    <input type=\"hidden\" name=\"product-name\" id=\"bsf-product-name\" value={'uael'} />\n                                    <select\n                                        id=\"uaelVersionRollback\"\n                                        ref={proVersionRef}\n                                        onBlur={(e) => {\n                                            setProductSelect('uael');\n                                            e.target.style.borderColor = '#e0e0e0'; \n                                        }}\n                                        onChange={handleVersionChange}\n                                        style={{\n                                            padding: '8px',\n                                            marginRight: '10px',\n                                            marginTop: '16px',\n                                            cursor: 'pointer',\n                                            borderRadius: '4px',\n                                            height: '40px',\n                                            width: '100px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',\n                                            // marginTop: '16px'     // Removes the default box shadow\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    >\n                                        {previousAddonVersions.map((version) => (\n                                            <option key={version.value} value={version.value}>\n                                                {version.label}\n                                            </option>\n                                        ))}\n                                    </select>\n                                </div>\n\n                                <div className=\"flex flex-col cursor-pointer\">\n                                    <Dialog\n                                        design=\"simple\"\n                                        exitOnEsc\n                                        scrollLock\n                                        open={openPopup} // Ensure Dialog is controlled by state\n                                        setOpen={setOpenPopup} // Synchronize state\n                                        trigger={<Button style={{ backgroundColor: '#6005ff' }}>{__('Rollback', 'uael')}</Button>}\n                                    >\n                                        <Dialog.Backdrop />\n                                        <Dialog.Panel>\n                                            <Dialog.Header>\n                                                <div className=\"flex items-center justify-between\">\n                                                    <Dialog.Title>\n                                                        {__('Rollback to Previous Version', 'uael')}\n                                                    </Dialog.Title>\n                                                    <Dialog.CloseButton />\n                                                </div>\n                                            </Dialog.Header>\n                                            <Dialog.Body>\n                                                {__(`Are you sure you want to rollback to ${uaelSettingsData.plugin_name} v${previousVersionSelect}?`, 'uael')}\n                                            </Dialog.Body>\n                                            <Dialog.Footer>\n                                                <Button onClick={onContinueClick} style={{ backgroundColor: '#6005ff' }}>\n                                                    {__('Rollback', 'uael')}\n                                                </Button>\n                                                <Button onClick={onCancelClick} style={{ backgroundColor: '#6005ff' }}>\n                                                    {__('Cancel', 'uael')}\n                                                </Button>\n                                            </Dialog.Footer>\n                                        </Dialog.Panel>\n                                    </Dialog>\n                                </div>\n                            </Container.Item>\n                        </Container>\n                        <div\n                            className=\"border border-subtle\"\n                            style={{\n                                height: '2px',\n                                backgroundColor: '#E5E7EB',\n                                marginTop: '16px',\n                                marginBottom: '16px',\n                            }}\n                        />\n                    </>\n                )}\n                <Container\n                    align=\"stretch\"\n                    className=\"flex flex-col lg:flex-row\"\n                    containerType=\"flex\"\n                    direction=\"column\"\n                    gap=\"sm\"\n                    justify=\"start\"\n                >\n                    <Container.Item className=\"shrink flex flex-col space-y-1\">\n                        <div className=\"text-base font-semibold m-0 mb-2\">\n                            {__('Enable Beta Version', 'uael')}\n                        </div>\n                        <div className=\"text-sm font-normal m-0\">\n                            {sprintf(\n                                __(\n                                    'Turn this on to get notified when a new beta version of %s is available. The beta version will not install automatically. You will need to install it manually. We recommend using it only in a test environment.',\n                                    'uael'\n                                ),\n                                uaelSettingsData.plugin_name\n                            )}\n                        </div>\n                        <div className=\"text-sm font-normal mt-2 pt-2\">\n                            {__('Please read ', 'uael')}\n                            <a\n                                href=\"https://ultimateelementor.com/docs/enabling-automatic-beta-updates-for-uael/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin\"\n                                className=\"uael-link-color no-underline uael-remove-ring\"\n                                target=\"_blank\"\n                                rel=\"noopener noreferrer\"\n                            >\n                                {__('this article', 'uael')}\n                            </a>\n                            {__(' to know more.', 'uael')}\n                        </div>\n                    </Container.Item>\n                    <Container.Item\n                        className=\"shrink-0 p-2 flex space-y-6\"\n                        alignSelf=\"auto\"\n                        order=\"none\"\n                        style={{ marginTop: '40px' }}\n                    >\n                        <Switch\n                            size=\"lg\"\n                            value={betaEnabled} // Set switch state\n                            onChange={handleBetaSwitch} // Handle switch change\n                        />\n                    </Container.Item>\n                </Container>\n            </div>\n        </>\n    );\n};\n\nexport default VersionControl;\n","import React, { useState, useEffect, useRef } from 'react';\nimport { Container, Title, Button, Switch, Dialog } from \"@bsf/force-ui\";\nimport { __ } from '@wordpress/i18n';\nimport toast, { Toaster } from 'react-hot-toast';\n\n\nconst UsageTracking = () => {\n    const [isActive, setIsActive] = useState(true);\n    useEffect(() => {\n        // Default to on for new users. Only turn off if explicitly set to 'no'.\n        setIsActive(uaelSettingsData.analytics_status !== 'no');\n    }, []);\n    const handleSwitchChange = async () => {\n        const newIsActive = !isActive;\n        setIsActive(newIsActive);\n\n        try {\n            const response = await fetch(uaelSettingsData.ajax_url, {\n                method: 'POST',\n                headers: {\n                    'Content-Type': 'application/x-www-form-urlencoded',\n                },\n                body: new URLSearchParams({\n                    action: 'uael_save_analytics_option', // WordPress action for your AJAX handler.\n                    uae_usage_optin: newIsActive ? 'yes' : 'no',\n                    nonce: uaelSettingsData.ajax_nonce // Nonce for security.\n                })\n            });\n\n            const result = await response.json();\n\n            if (result.success) {\n                toast.success(__('Settings saved successfully!', 'uael'));\n            } else {\n                toast.error(__('Failed to save settings!', 'uael'));\n            }\n        } catch (error) {\n            toast.error(__('Failed to save settings!', 'uael'));\n        }\n\n        // setIsLoading(false);\n    };\n\n    return (\n        <>\n            <hr className=\"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle\" style={{ marginTop: '20px', marginBottom: '20px', borderColor: '#E5E7EB' }} />\n            <Container\n                align=\"center\"\n                className=\"flex flex-col lg:flex-row\"\n                containerType=\"flex\"\n                direction=\"column\"\n                gap=\"sm\"\n                justify=\"start\"\n            >\n                <Container.Item\n                    className=\"p-2 flex space-y-4\"\n                    alignSelf=\"auto\"\n                    order=\"none\"\n                    style={{maxWidth:\"100%\"}}\n                >\n                    <div className='flex flex-row items-start justify-start px-1 gap-3'>\n                        <Switch\n                            onChange={handleSwitchChange}\n                            size='sm'\n                            value={isActive}\n                            className=\"hfe-remove-ring\"\n                        />\n                        <div className='flex flex-col justify-start px-1 gap-3'>\n                            <span className=\"font-normal text-text-primary m-0\">\n                                {__(\n                                    \"Help shape the future of Ultimate Addons for Elementor Pro. Share how you use the plugin so we can build features that matter, fix issues faster, and make smarter decisions. \",\n                                    \"uael\"\n                                )}\n                                <a\n                                    href=\"https://store.brainstormforce.com/usage-tracking/?utm_source=wp_dashboard&utm_medium=general_settings&utm_campaign=usage_tracking\"\n                                    target=\"_blank\"\n                                    rel=\"noopener noreferrer\"\n                                    className=\"text-link-primary\"\n                                >\n                                    {__(\"Learn More\", \"uael\")}\n                                </a>\n                            </span>\n                        </div>\n                        <Toaster\n                            position=\"top-right\"\n                            reverseOrder={false}\n                            gutter={8}\n                            containerStyle={{\n                                top: 20,\n                                right: 20,\n                                marginTop: '40px',\n                            }}\n                            toastOptions={{\n                                duration: 1000,\n                                style: {\n                                    background: 'white',\n                                },\n                                success: {\n                                    duration: 2000,\n                                    style: {\n                                        color: '',\n                                    },\n                                    iconTheme: {\n                                        primary: '#6005ff',\n                                        secondary: '#fff',\n                                    },\n                                },\n                            }}\n                        />\n                    </div>\n                </Container.Item>\n            </Container>\n        </>\n    );\n}\n\nexport default UsageTracking;\n","import React, { useState } from 'react';\nimport { __, sprintf } from '@wordpress/i18n';\nimport apiFetch from '@wordpress/api-fetch';\nimport { Container, Title, Button } from \"@bsf/force-ui\";\nimport { LoaderCircle } from \"lucide-react\";\nimport { Toaster, toast } from 'react-hot-toast';\nimport UsageTracking from './UsageTracking';\nimport { LockOpen } from 'lucide-react';\n\n\nconst MyAccount = () => {\n\tconst [licenseKey, setlicenseKey] = useState('');\n\tconst [loading, setLoading] = useState(false);\n\tconst [errorMessage, setErrorMessage] = useState('');\n\n\tconst licenseStatus = uaelSettingsData.license_status;\n\tconst licensePlaceholder = licenseStatus ? __('Your license is active.', 'uael') : __('Paste your license key here', 'uael');\n\tconst isWhiteLabel = uaelSettingsData.is_whitelabel;\n\n\tconst activateHandler = () => {\n\t\tif (!licenseKey) {\n\t\t\ttoast.error(__('Please enter a valid license key!', 'uael'));\n\t\t\tsetErrorMessage(__('Enter a valid license key!', 'uael'));\n\t\t\treturn;\n\t\t}\n\n\t\tsetLoading(true);\n\t\tsetErrorMessage('');\n\n\t\tconst formData = new window.FormData();\n\t\tformData.append('key', licenseKey);\n\t\tformData.append('action', 'uael_license_activation');\n\t\tformData.append('security', uaelSettingsData.license_activation_nonce);\n\n\t\tapiFetch({\n\t\t\turl: uaelSettingsData.ajax_url,\n\t\t\tmethod: 'POST',\n\t\t\tbody: formData,\n\t\t}).then((data) => {\n\t\t\tsetLoading(false);\n\t\t\tif (data.success) {\n\t\t\t\ttoast.success(__('License successfully validated!', 'uael'));\n\t\t\t\tlocation.reload();\n\t\t\t} else {\n\t\t\t\ttoast.error(data.message || __('Please enter a valid license key!', 'uael'));\n\t\t\t\tsetErrorMessage(data.message || __('Enter a valid license key!', 'uael')); // Set error message.\n\t\t\t}\n\t\t});\n\t};\n\n\tconst deactivateHandler = () => {\n\t\tsetLoading(true);\n\t\tsetErrorMessage('');\n\n\t\tconst formData = new window.FormData();\n\t\tformData.append('action', 'uael_license_deactivation');\n\t\tformData.append('security', uaelSettingsData.license_deactivation_nonce);\n\n\t\tapiFetch({\n\t\t\turl: uaelSettingsData.ajax_url,\n\t\t\tmethod: 'POST',\n\t\t\tbody: formData,\n\t\t}).then((data) => {\n\t\t\tsetLoading(false);\n\t\t\tif (data.success) {\n\t\t\t\ttoast.success(__('License successfully deactivated!', 'uael')); // Show toast notification on success\n\t\t\t\tlocation.reload();\n\t\t\t} else {\n\t\t\t\ttoast.error(data.message || __('An error occurred while deactivating license.', 'uael'));\n\t\t\t\tsetErrorMessage(data.message || __('An error occurred while deactivating license.', 'uael'));\n\t\t\t}\n\t\t});\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<Toaster\n\t\t\t\tposition=\"top-right\"\n\t\t\t\treverseOrder={false}\n\t\t\t\tgutter={8}\n\t\t\t\tcontainerStyle={{\n\t\t\t\t\ttop: 20,\n\t\t\t\t\tright: 20,\n\t\t\t\t\tmarginTop: '40px',\n\t\t\t\t}}\n\t\t\t\ttoastOptions={{\n\t\t\t\t\tduration: 5000,\n\t\t\t\t\tstyle: {\n\t\t\t\t\t\tbackground: 'white',\n\t\t\t\t\t},\n\t\t\t\t\tsuccess: {\n\t\t\t\t\t\tduration: 3000,\n\t\t\t\t\t\ticonTheme: {\n\t\t\t\t\t\t\tprimary: '#6005ff',\n\t\t\t\t\t\t\tsecondary: '#fff',\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t}}\n\t\t\t/>\n\t\t\t<Title\n\t\t\t\tdescription=\"\"\n\t\t\t\ticon={null}\n\t\t\t\ticonPosition=\"right\"\n\t\t\t\tsize=\"sm\"\n\t\t\t\ttag=\"h2\"\n\t\t\t\ttitle={__('My Account', 'uael')}\n\t\t\t/>\n\t\t\t<Container\n\t\t\t\talign=\"stretch\"\n\t\t\t\tclassName=\"bg-background-primary p-6 rounded-lg uael-78-width\"\n\t\t\t\tcontainerType=\"flex\"\n\t\t\t\tdirection=\"column\"\n\t\t\t\tgap=\"\"\n\t\t\t\tjustify=\"start\"\n\t\t\t\tstyle={{\n\t\t\t\t\tmarginTop: \"24px\",\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<Container.Item className=\"flex flex-col space-y-2\">\n\t\t\t\t\t<span className=\"inline-flex items-center justify-center w-8 h-8 rounded-md border border-solid p-1\" style={{ borderColor: 'rgb(230, 230, 239)' }}>\n\t\t\t\t\t\t<LockOpen size={24} className=\"text-gray-600\" />\n\t\t\t\t\t</span>\n\t\t\t\t\t<h3 className='m-0 flex items-center text-2xl font-semibold'>{licenseStatus ? __('Your License', 'uael') : __('License not active', 'uael')}</h3>\n\t\t\t\t\t\t{licenseStatus ? (\n\t\t\t\t\t\t\t<p className=\"text-sm font-normal m-0\">\n\t\t\t\t\t\t\t\t{sprintf(\n\t\t\t\t\t\t\t\t\t__('You are using %s Pro!', 'uael'),\n\t\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t<p className=\"text-sm font-normal m-0\">\n\t\t\t\t\t\t\t\t\t{isWhiteLabel ? (\n\t\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t\t{sprintf(\n\t\t\t\t\t\t\t\t\t\t\t\t__('Activate %s Pro to get professional support and automatic updates from your WordPress dashboard.', 'uael'),\n\t\t\t\t\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name\n\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t\t{__('Activate', 'uael')}{' '}\n\t\t\t\t\t\t\t\t\t\t\t<a\n\t\t\t\t\t\t\t\t\t\t\t\thref=\"https://ultimateelementor.com/pricing/?utm_source=free-plugin&utm_medium=account-setting&utm_campaign=upgrade\"\n\t\t\t\t\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t\t\t\t\t\tclassName='text-link-primary'\n\t\t\t\t\t\t\t\t\t\t\t\tstyle = {{ color:'#6005FF', }}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t{uaelSettingsData.plugin_short_name} Pro\n\t\t\t\t\t\t\t\t\t\t\t</a>{' '}\n\t\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t\t'to get professional support and automatic updates from your WordPress dashboard.',\n\t\t\t\t\t\t\t\t\t\t\t\t'uael'\n\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t\t<p className=\"text-sm font-normal m-0\">\n\t\t\t\t\t\t\t\t\t{sprintf(\n\t\t\t\t\t\t\t\t\t\t__('Please enter your valid license key below to activate %s Pro!', 'uael'),\n\t\t\t\t\t\t\t\t\t\tuaelSettingsData.plugin_short_name\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t{!isWhiteLabel && (\n\t\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t\t{' '}\n\t\t\t\t\t\t\t\t\t\t\t<a\n\t\t\t\t\t\t\t\t\t\t\t\thref=\"https://store.brainstormforce.com/account/\"\n\t\t\t\t\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t\t\t\t\t\tclassName='text-link-primary'\n\t\t\t\t\t\t\t\t\t\t\t\tstyle = {{ color:'#6005FF', }}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t{__( 'Click Here','uael' )}\n\t\t\t\t\t\t\t\t\t\t\t</a>{' '}\n\t\t\t\t\t\t\t\t\t\t\t{__(\n\t\t\t\t\t\t\t\t\t\t\t\t'to find your license key.',\n\t\t\t\t\t\t\t\t\t\t\t\t'uael'\n\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t</p>\n\t\t\t\t\t\t\t</>\n\t\t\t\t\t)}\n\t\t\t\t</Container.Item>\n\t\t\t\t<Container.Item\n\t\t\t\t\tclassName=\"flex flex-col lg:flex-row gap-1 items-center space-y-2\"\n\t\t\t\t\talignSelf=\"auto\"\n\t\t\t\t\torder=\"none\"\n\t\t\t\t>\n\t\t\t\t\t<input\n\t\t\t\t\t\tvalue={licenseKey}\n\t\t\t\t\t\tonChange={(e) => setlicenseKey(e.target.value)}\n\t\t\t\t\t\tplaceholder={licensePlaceholder}\n\t\t\t\t\t\treadOnly={licenseStatus}\n\t\t\t\t\t\tsize=\"md\"\n\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\tclassName={`w-full shrink ${licenseStatus ? 'uael-green-placeholder' : 'uael-default-placeholder'}`}\n\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\theight: '48px',\n\t\t\t\t\t\t\toutline: 'none',       // Removes the default outline\n\t\t\t\t\t\t\tboxShadow: 'none',     // Removes the default box shadow\n\t\t\t\t\t\t\tborderColor: errorMessage ? 'red' : '#e0e0e0',\n\t\t\t\t\t\t}}\n\t\t\t\t\t\tonFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n\t\t\t\t\t\tonBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n\t\t\t\t\t/>\n\t\t\t\t\t<div className='cursor-pointer mb-2 shrink'\n\t\t\t\t\t\tstyle={{ minWidth: \"fit-content\" }}>\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\ticon={loading ? <LoaderCircle className=\"animate-spin\" /> : null}\n\t\t\t\t\t\t\ticonPosition=\"left\"\n\t\t\t\t\t\t\tstyle = {{ paddingTop: '14px', paddingBottom: '14px', borderColor: '#6005FF', outline: 'none', }}\n\t\t\t\t\t\t\tclassName=\"bg-[#6005FF] rounded-md border border-solid hover:bg-[#6005FF] mb-2\"\n\t\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\t\tonMouseEnter={(e) =>\n\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\"#4B00CC\")\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonMouseLeave={(e) =>\n\t\t\t\t\t\t\t\t(e.currentTarget.style.backgroundColor =\n\t\t\t\t\t\t\t\t\t\"#6005FF\")\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonClick={licenseStatus ? deactivateHandler : activateHandler}\n\t\t\t\t\t\t\tdisabled={loading} // Disable button during loading to prevent multiple clicks.\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{loading\n\t\t\t\t\t\t\t\t? (licenseStatus ? __('Deactivating...', 'uael') : __('Activating...', 'uael'))\n\t\t\t\t\t\t\t\t: (licenseStatus ? __('Deactivate', 'uael') : __('Activate', 'uael'))}\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t</div>\n\t\t\t\t</Container.Item>\n\t\t\t\t{!isWhiteLabel && (\n\t\t\t\t\t<p className=\"m-0 text-sm font-semibold text-link-primary no-underline mb-2\">\n\t\t\t\t\t\t\t<a className='no-underline'\n\t\t\t\t\t\t\t\thref={\n\t\t\t\t\t\t\t\t\tlicenseStatus\n\t\t\t\t\t\t\t\t\t? 'https://ultimateelementor.com/pricing/?utm_source=pro-plugin&utm_medium=account-setting&utm_campaign=more-upgrade'\n\t\t\t\t\t\t\t\t\t: 'https://store.brainstormforce.com/support'\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t\tstyle = {{ color:'#6005FF', }}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{licenseStatus\n\t\t\t\t\t\t\t\t? __('Get another license?', 'uael')\n\t\t\t\t\t\t\t\t: __('Need Help?', 'uael')}\n\t\t\t\t\t\t\t</a>\n\t\t\t\t\t</p>\n\t\t\t\t)}\n\t\t\t\t{errorMessage && (\n\t\t\t\t\t<p className=\"text-red-500 text-xs\" style={{ color: 'red', marginTop: \"-10px\" }}>{errorMessage}</p> // Show error message below the input field\n\t\t\t\t)}\n\t\t\t\t<UsageTracking />\n\t\t\t</Container>\n\n\t\t</>\n\t);\n};\n\nexport default MyAccount;\n","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst LoaderCircle = createLucideIcon(\"LoaderCircle\", [\n  [\"path\", { d: \"M21 12a9 9 0 1 1-6.219-8.56\", key: \"13zald\" }]\n]);\n\nexport { LoaderCircle as default };\n//# sourceMappingURL=loader-circle.js.map\n","import { jsx as r } from \"react/jsx-runtime\";\nimport { cn as n } from \"../../utilities/functions.es.js\";\nimport { LoaderCircle as o } from \"lucide-react\";\nconst d = ({\n  variant: a = \"primary\",\n  // primary, secondary\n  size: e = \"md\",\n  // sm, md, lg, xl,\n  icon: s = null,\n  className: m = \"\"\n}) => {\n  const i = {\n    primary: \"text-brand-primary-600\",\n    secondary: \"text-background-primary\"\n  }[a], t = {\n    sm: \"[&>svg]:size-4\",\n    md: \"[&>svg]:size-5\",\n    lg: \"[&>svg]:size-6\",\n    xl: \"[&>svg]:size-8\"\n  }[e];\n  return /* @__PURE__ */ r(\n    \"span\",\n    {\n      className: n(\"flex\", t, i, m),\n      children: s || /* @__PURE__ */ r(o, { className: \"animate-spin shrink-0\" })\n    }\n  );\n};\nexport {\n  d as Loader,\n  d as default\n};\n//# sourceMappingURL=loader.es.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst RefreshCcw = createLucideIcon(\"RefreshCcw\", [\n  [\"path\", { d: \"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8\", key: \"14sxne\" }],\n  [\"path\", { d: \"M3 3v5h5\", key: \"1xhq8a\" }],\n  [\"path\", { d: \"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16\", key: \"1hlbsb\" }],\n  [\"path\", { d: \"M16 16h5v5\", key: \"ccwih5\" }]\n]);\n\nexport { RefreshCcw as default };\n//# sourceMappingURL=refresh-ccw.js.map\n","import React, { useState, useEffect, useCallback } from 'react'\nimport { Container, Title, Button, Loader } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\nimport toast, { Toaster } from 'react-hot-toast';\nimport { FileText, LoaderCircle, RefreshCcw } from 'lucide-react';\nimport debounce from 'lodash.debounce';\n\nconst Integrations = () => {\n\n    const [settings, setSettings] = useState({\n        google_api: '', // Match the key with the backend\n        developer_mode: false,\n        language: '',\n        google_places_api: '',\n        yelp_api: '',\n        recaptcha_v3_key: '',\n        recaptcha_v3_secretkey: '',\n        recaptcha_v3_score: '0.5',\n        google_client_id: '',\n        facebook_app_id: '',\n        facebook_app_secret: '',\n        uael_share_button: '',\n        uael_maxmind_geolocation_license_key: '',\n        uael_maxmind_geolocation_db_path: '',\n        uael_twitter_feed_consumer_key: '',\n        uael_twitter_feed_consumer_secret: '',\n        instagram_app_id: '',\n        instagram_app_secret: '',\n        instagram_app_token: '',\n        cloudflare_turnstile_site_key: '',\n        cloudflare_turnstile_secret_key: '',\n    });\n\n    const [loading, setLoading] = useState(true);\n    const [error, setError] = useState(null);\n    const [successMessage, setSuccessMessage] = useState('');\n    const [isSaving, setIsSaving] = useState(false);\n    const [tokenRefresh, setTokenRefresh] = useState(false);\n    const [maxmindStatus, setMaxmindStatus] = useState('success');\n\n    const languagesData = typeof window.uaeLanguagesData === 'object' && window.uaeLanguagesData !== null\n        ? Object.entries(window.uaeLanguagesData)\n        : []; // Convert object to array of [key, value] pairs\n\n    useEffect(() => {\n        const fetchSettings = () => {\n            setLoading(true);\n            setError(null);\n            apiFetch({\n                path: '/uael/v1/settings',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action, // Use the correct nonce\n                },\n            })\n                .then((data) => {\n                    setSettings(data); // Set the fetched settings\n                    setLoading(false); // Stop loading\n                })\n                .catch((err) => {\n                    setError(err.message); // Set error message\n                    setLoading(false); // Stop loading\n                });\n\n        };\n\n        fetchSettings();\n    }, []);\n\n    const validateApi = (apiKey, source) => {\n\n        if ('' === apiKey || '' === source) {\n            return;\n        }\n        const api_type = 'google' === source ? 'Google Places API Key' : ('facebook' === source ? 'Facebook Access Token' : 'Yelp API Key');\n\n        apiFetch({\n            path: '/uael/v1/validateApiKey',\n            method: 'POST',\n            headers: {\n                'Content-Type': 'application/json',\n                'X-WP-Nonce': uaelSettingsData.uael_nonce_action, // Use the correct nonce\n            },\n            body: JSON.stringify({ apiKey, source }),\n        }).then((data) => {\n            if (data.success) {\n                toast.success(`${api_type} authenticated successfully!`);\n            } else {\n                toast.error(`Entered ${api_type} is invalid`);\n            }\n        }).catch((error) => {\n            toast.error(error.message);\n        });\n    };\n\n    const debouncedValidateApi = useCallback(debounce(validateApi, 500), []);\n\n    const handleChange = (name, value) => {\n\n        setSettings(prevSettings => ({\n            ...prevSettings,\n            [name]: value\n        }));\n\n        if ('google_places_api' === name) {\n            debouncedValidateApi(value, 'google');\n        }\n        if ('yelp_api' === name) {\n            debouncedValidateApi(value, 'yelp');\n        }\n\n        if ('uael_share_button' === name) {\n            debouncedValidateApi(value, 'facebook');\n        }\n    };\n\n    const generateInstagramAccessToken = () => {\n        const refreshTokenURL = 'https://graph.instagram.com/refresh_access_token';\n\n        if (settings.instagram_app_token) {\n            setTokenRefresh(true);\n\n            fetch(refreshTokenURL + `?grant_type=ig_refresh_token&access_token=${settings.instagram_app_token}`, {\n                method: 'GET',\n                headers: {\n                    'Content-Type': 'application/json',\n                },\n            })\n                .then((response) => response.json())\n                .then((data) => {\n                    setTokenRefresh(false);\n\n                    if (data.access_token) {\n                        setSettings((prevSettings) => ({\n                            ...prevSettings,\n                            instagram_app_token: data.access_token, // Update with the new token\n                        }));\n                        toast.success(\"Access token refreshed successfully\");\n                    } else if (data.error) {\n                        toast.error(data.error.message || \"An error occurred while refreshing the token.\");\n                    }\n                })\n                .catch((error) => {\n                    setTokenRefresh(false);\n                    toast.error(\"Failed to refresh the access token. Please try again.\");\n                });\n        }\n    };\n\n    const handleSubmit = (e) => {\n        e.preventDefault();\n        setError(null);\n        setIsSaving(true);\n\n        apiFetch({\n            path: '/uael/v1/settings',\n            method: 'POST',\n            headers: {\n                'Content-Type': 'application/json',\n                'X-WP-Nonce': uaelSettingsData.uael_nonce_action,\n            },\n            data: settings,\n        })\n            .then((data) => {\n                if (data.maxmind_status === 'error') {\n                    setMaxmindStatus('error');\n                } else {\n                    setMaxmindStatus('success');\n                }\n                setSuccessMessage('Settings saved successfully!'); // Set success message\n                toast.success('Settings saved successfully!'); // Show toast notification\n            })\n            .catch((err) => {\n                toast.error('Settings cannot be saved!'); // Show toast notification\n            })\n            .finally(() => {\n                setIsSaving(false);\n            });\n    };\n\n    if (loading) {\n        return (\n            <div className='h-screen w-screen flex items-center justify-center' style={{ position: 'relative' }}>\n                <Loader icon={null} size=\"lg\" className=\"bg-transparent relative uae-loader-icon\" />\n            </div>\n        );\n    }\n\n    if (error) {\n        return <div>Error: {error}</div>;\n    }\n\n    return (\n        <form\n            onSubmit={handleSubmit}\n        >\n            <div\n                className='rounded-lg uael-settings-page'\n            >\n                <div className='flex flex-row items-center justify-between' style={{ paddingBottom: '24px' }} >\n                    <Title\n                        description=\"\"\n                        icon={null}\n                        iconPosition=\"right\"\n                        size=\"sm\"\n                        tag=\"h2\"\n                        title={__('Integrations', 'uael')}\n                    />\n\n                    <div className='flex items-center justify-between [&_h2]:text-[#6005ff]' style={{ gap: '22px' }}>\n                        {/* <div className='flex items-center gap-1 cursor-pointer' style={{ position: 'relative' }}>\n                            <FileText style={{ color: '#6005ff', size: '20px' }} />\n                            <a href=\"https://ultimateelementor.com/docs/how-to-white-label-uael/\" target=\"_blank\" className='text-[#6005ff] text-sm font-medium no-underline' style={{ color: '#6005ff', boxShadow: 'none' }}>{__('Read Documentation', 'uael')}</a>\n                        </div> */}\n                        <Button\n                            type=\"submit\"\n                            style={{ backgroundColor: '#6005ff', position: 'relative' }}\n                            className=\"flex items-center justify-center\"\n                            icon={isSaving ? <LoaderCircle className=\"animate-spin\" /> : null}\n                            iconPosition=\"left\"\n                            disabled={isSaving}\n                        >\n                            {isSaving ? __('Saving...', 'uael') : __('Save', 'uael')}\n                        </Button>\n                    </div>\n                </div>\n\n                <div className=\"w-full flex flex-col gap-8\" style={{ marginTop: \"24px\" }}>\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Google Map', 'uael')}\n                                description=\"\"\n                                className=\"\"\n                            />\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('API Key', 'uael')}\n                                    description={\n                                        !uaelSettingsData.hide_settings ? (\n                                            <>\n                                                {__('Note: This setting is required if you wish to use Google Map in your website. ', 'uael')}\n                                                <a\n                                                    href={`${uaelSettingsData.uael_domain}docs/create-google-map-api-key/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                    target=\"_blank\"\n                                                    rel=\"noopener noreferrer\"\n                                                    className=\"uael-link-color no-underline\"\n                                                >\n                                                    {__('Need Help?', 'uael')}\n                                                </a>.\n                                            </>\n                                        ) : ''\n                                    }\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"text\"\n                                    name=\"google_api\" // Match the key with the backend\n                                    value={settings.google_api}\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Paste your API Key here', 'uael')}\n                                    className='w-full border border-subtle'\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n\n                            <div className='border border-subtle' style={{ height: '2px', backgroundColor: '#E5E7EB', marginTop: '16px' }} />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Localization Language', 'uael')}\n                                    description={\n                                        !uaelSettingsData.hide_settings ? (\n                                            <>\n                                                {__('Note: This setting sets localization language to google map. The language affects the names of controls, copyright notices, driving directions, and control labels. ', 'uael')}\n                                                <a\n                                                    href={`${uaelSettingsData.uael_domain}docs/how-to-display-uaels-google-maps-widget-in-your-local-language/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                    target=\"_blank\"\n                                                    rel=\"noopener noreferrer\"\n                                                    className=\"uael-link-color no-underline\"\n                                                >\n                                                    {__('Need Help?', 'uael')}\n                                                </a>.\n                                            </>\n                                        ) : ''\n                                    }\n                                    className=\"uae-subtitle\"\n                                />\n                                <select\n                                    name=\"language\"\n                                    value={settings.language}\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    className=\"border border-subtle rounded p-2 w-full\"\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n\n                                >\n                                    <option value=\"\">Default</option>\n                                    {languagesData.map(([code, name]) => (\n                                        <option key={code} value={code}>\n                                            {name}\n                                        </option>\n                                    ))}\n                                </select>\n                            </Container.Item>\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Business Reviews', 'uael')}\n                                description=\"\"\n                                className=\"\"\n                            />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Google Places API Key', 'uael')}\n                                    description={\n                                        !uaelSettingsData.hide_settings ? (\n                                            <>\n                                                {__('Note: This setting is required if you wish to use Google Places Reviews in your website. ', 'uael')}\n                                                <a\n                                                    href={`${uaelSettingsData.uael_domain}docs/get-google-places-api-key/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                    target=\"_blank\"\n                                                    rel=\"noopener noreferrer\"\n                                                    className=\"uael-link-color no-underline\"\n                                                >\n                                                    {__('Need Help?', 'uael')}\n                                                </a>\n                                            </>\n                                        ) : ''\n                                    }\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"text\"\n                                    name=\"google_places_api\" // Match the key with the backend\n                                    value={settings.google_places_api}\n                                    className='w-full border border-subtle'\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Enter Google Places API Key', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                                <p className='text-sm font-medium mt-2'>\n                                    {!uaelSettingsData.hide_settings && (\n                                        <>\n                                            {__('Google now requires an active billing account associated with your API Key. To enable billing click ', 'uael')}\n                                            <a\n                                                href={'https://console.cloud.google.com/projectselector2/billing/enable'}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('here!', 'uael')}\n                                            </a>\n                                        </>\n                                    )}\n                                </p>\n                            </Container.Item>\n\n                            <div className='border border-subtle' style={{ height: '2px', backgroundColor: '#E5E7EB', marginTop: '16px' }} />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Yelp API Key', 'uael')}\n                                    description={\n                                        !uaelSettingsData.hide_settings ? (\n                                            <>\n                                                {__('Note: This setting is required if you wish to use Yelp Reviews in your website. ', 'uael')}\n                                                <a\n                                                    href={`${uaelSettingsData.uael_domain}docs/get-yelp-api-key/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                    target=\"_blank\"\n                                                    rel=\"noopener noreferrer\"\n                                                    className=\"uael-link-color no-underline\"\n                                                >\n                                                    {__('Need Help?', 'uael')}\n                                                </a>\n                                            </>\n                                        ) : ''\n                                    }\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"text\"\n                                    name=\"yelp_api\" // Match the key with the backend\n                                    value={settings.yelp_api}\n                                    className='w-full border border-subtle px-2'\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Enter Yelp API Key', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Setup reCAPTCHA v3', 'uael')}\n                                description={\n                                    !uaelSettingsData.hide_settings ? (\n                                        <>\n                                            {__('Note: ', 'uael')}\n                                            <a\n                                                href={'https://www.google.com/recaptcha/about/'}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('reCAPTCHA v3', 'uael')}\n                                            </a>\n                                            {__(' is a free service by Google that protects your website from spam and abuse. It does this while letting your valid users pass through with ease. ', 'uael')}\n                                            <a\n                                                href={'https://ultimateelementor.com/docs/user-registration-form-with-recaptcha/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin'}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Need Help?', 'uael')}\n                                            </a>\n                                        </>\n                                    ) : ''\n                                }\n                            />\n\n                            <Container.Item className=\"flex flex-col space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Site key', 'uael')}\n                                    description=\"\"\n                                    className=\"uae-subtitle\"\n                                />\n                                {/* <p className='font-normal text-field-label text-base'>{__('Site key', 'uael')}</p> */}\n                                <input\n                                    type=\"text\"\n                                    name=\"recaptcha_v3_key\" // Match the key with the backend\n                                    value={settings.recaptcha_v3_key}\n                                    className='w-full border border-subtle px-2'\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Enter reCAPTCHA v3 Key', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        // marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('Secret key', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('Secret key', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"recaptcha_v3_secretkey\" // Match the key with the backend\n                                        value={settings.recaptcha_v3_secretkey}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        className='w-full border border-subtle px-2'\n                                        placeholder={__('Enter reCAPTCHA v3 Secret Key', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('Score Threshold', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('Score Threshold', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"recaptcha_v3_score\" // Match the key with the backend\n                                        value={settings.recaptcha_v3_score}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        className='w-full border border-subtle px-2'\n                                        placeholder={__('Enter reCAPTCHA v3 Score', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n                            </div>\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Setup Cloudflare Turnstile', 'uael')}\n                                description={\n                                    !uaelSettingsData.hide_settings ? (\n                                        <>\n                                            {__('Note: ', 'uael')}\n                                            <a\n                                                href={'https://www.cloudflare.com/products/turnstile/'}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Cloudflare Turnstile', 'uael')}\n                                            </a>\n                                            {__(' is a privacy-first alternative to CAPTCHA that protects your website from spam and abuse. ', 'uael')}\n                                            <a\n                                                href={'https://ultimateelementor.com/docs/how-to-setup-cloudflare-turnstile/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin'}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Need Help?', 'uael')}\n                                            </a>\n                                        </>\n                                    ) : ''\n                                }\n                            />\n\n                            <Container.Item className=\"flex flex-col space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Site key', 'uael')}\n                                    description=\"\"\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"text\"\n                                    name=\"cloudflare_turnstile_site_key\"\n                                    value={settings.cloudflare_turnstile_site_key}\n                                    className='w-full border border-subtle px-2'\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Enter Cloudflare Turnstile Site Key', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n\n                            <Container.Item className=\"flex flex-col space-y-1 space-x-2 mt-1\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Secret key', 'uael')}\n                                    description=\"\"\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"password\"\n                                    name=\"cloudflare_turnstile_secret_key\"\n                                    value={settings.cloudflare_turnstile_secret_key}\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    className='w-full border border-subtle px-2'\n                                    placeholder={__('Enter Cloudflare Turnstile Secret Key', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Login Form', 'uael')}\n                                description=\"\"\n                                className=\"\"\n                            />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Google Client ID', 'uael')}\n                                    description={\n                                        !uaelSettingsData.hide_settings ? (\n                                            <>\n                                                {__('Note: This setting is required if you wish to use Login with Google in your website. ', 'uael')}\n                                                <a\n                                                    href={`${uaelSettingsData.uael_domain}docs/create-google-client-id-for-login-form-widget/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                    target=\"_blank\"\n                                                    rel=\"noopener noreferrer\"\n                                                    className=\"uael-link-color no-underline\"\n                                                >\n                                                    {__('Need Help?', 'uael')}\n                                                </a>\n                                            </>\n                                        ) : ''\n                                    }\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"text\"\n                                    name=\"google_client_id\"\n                                    value={settings.google_client_id}\n                                    className=\"w-full border border-subtle rounded p-2\"\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Enter Google Client ID', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n\n                            <div className='border border-subtle' style={{ height: '2px', backgroundColor: '#E5E7EB', marginTop: '16px' }} />\n\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"xs\"\n                                tag=\"h2\"\n                                title={__('Facebook App Details', 'uael')}\n                                description={\n                                    !uaelSettingsData.hide_settings ? (\n                                        <>\n                                            {__('Note: This setting is required if you wish to use Login with Google in your website. ', 'uael')}\n                                            <a\n                                                href={`${uaelSettingsData.uael_domain}docs/create-facebook-app-id-for-login-form-widget/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Need Help?', 'uael')}\n                                            </a>\n                                        </>\n                                    ) : ''\n                                }\n                                className=\"\"\n                            />\n\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('App ID', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('App ID', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"facebook_app_id\" // Match the key with the backend\n                                        value={settings.facebook_app_id}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter Facebook App ID', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                        className='w-full border border-subtle px-2'\n                                    />\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('App Secret', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('App Secret', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"facebook_app_secret\" // Match the key with the backend\n                                        value={settings.facebook_app_secret}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter Facebook App Secret', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                        className='w-full border border-subtle px-2'\n                                    />\n                                </Container.Item>\n                            </div>\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Social Share', 'uael')}\n                                description=\"\"\n                                className=\"\"\n                            />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title\n                                    icon={null}\n                                    iconPosition=\"right\"\n                                    size=\"xs\"\n                                    tag=\"h2\"\n                                    title={__('Facebook Access Token', 'uael')}\n                                    description={\n                                        !uaelSettingsData.hide_settings ? (\n                                            <>\n                                                {__('Note: This setting is required if you wish to fetch share count of your post/page from Facebook. ', 'uael')}\n                                                <a\n                                                    href={`${uaelSettingsData.uael_domain}docs/display-share-count-for-facebook/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                    target=\"_blank\"\n                                                    rel=\"noopener noreferrer\"\n                                                    className=\"uael-link-color no-underline\"\n                                                >\n                                                    {__('Need Help?', 'uael')}\n                                                </a>\n                                            </>\n                                        ) : ''\n                                    }\n                                    className=\"uae-subtitle\"\n                                />\n                                <input\n                                    type=\"text\"\n                                    name=\"uael_share_button\" // Match the key with the backend\n                                    value={settings.uael_share_button}\n                                    className=\"w-full border border-subtle rounded p-2\"\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder=\"\"\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                        marginTop: '16px'\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('MaxMind Geolocation', 'uael')}\n                                description={\n                                    !uaelSettingsData.hide_settings ? (\n                                        <>\n                                            {__('Note: An integration for utilizing MaxMind to do Geolocation lookups. Please note that this integration will only do Country lookups. ', 'uael')}\n                                            <a\n                                                href={`${uaelSettingsData.uael_domain}docs/display-conditions-geolocation/?utm_source=uael-pro-dashboard&utm_medium=uael-menu-page&utm_campaign=uael-pro-plugin`}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Need Help?', 'uael')}\n                                            </a>\n                                        </>\n                                    ) : ''\n                                }\n                                className=\"\"\n                            />\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('License Key', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('License Key', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"uael_maxmind_geolocation_license_key\" // Match the key with the backend\n                                        value={settings.uael_maxmind_geolocation_license_key}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter MaxMind License Key', 'uael')}\n                                        className='w-full border border-subtle px-2'\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('Database File Path', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('Database File Path', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        disabled\n                                        name=\"uael_maxmind_geolocation_db_path\" // Match the key with the backend\n                                        placeholder={uaelSettingsData.maxmind_db_path}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                        className='w-full border border-subtle px-2'\n                                    />\n                                </Container.Item>\n                            </div>\n                            {maxmindStatus === 'error' && (\n                                <div className=\"error-message font-normal my-0 text-sm\">\n                                    {__('The MaxMind license key is invalid. If you have recently created this key, you may need to wait for it to become active.', 'uael')}\n                                </div>\n                            )}\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Twitter Feed', 'uael')}\n                                description={\n                                    !uaelSettingsData.hide_settings ? (\n                                        <>\n                                            {__('Note: To display your Twitter Feed on your website, you\\'ll need to acquire Twitter\\'s basic plan and obtain your Twitter Consumer Key and Consumer Secret Key. For guidance on obtaining these keys, ', 'uael')}\n                                            <a\n                                                href={`${uaelSettingsData.uael_domain}docs/twitter-feed-widget/?utm_source=uael-pro-dashboard&utm_medium=uael-editor-screen&utm_campaign=uael-pro-plugin`}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Need Help?', 'uael')}\n                                            </a>\n                                        </>\n                                    ) : ''\n                                }\n                                className=\"\"\n                            />\n\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('Consumer Key', 'uael')}\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('Consumer Key', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"uael_twitter_feed_consumer_key\" // Match the key with the backend\n                                        value={settings.uael_twitter_feed_consumer_key}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter Twitter Consumer Key', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                        className='w-full border border-subtle px-2'\n                                    />\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('Consumer Secret', 'uael')}\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('Consumer Secret', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"uael_twitter_feed_consumer_secret\" // Match the key with the backend\n                                        value={settings.uael_twitter_feed_consumer_secret}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter Twitter Consumer Secret', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                        className='w-full border border-subtle px-2'\n                                    />\n                                </Container.Item>\n                            </div>\n\n                        </Container>\n\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n                            <Title\n                                icon={null}\n                                iconPosition=\"right\"\n                                size=\"sm\"\n                                tag=\"h2\"\n                                title={__('Instagram Feed - Instagram Product API Details', 'uael')}\n                                description={\n                                    !uaelSettingsData.hide_settings ? (\n                                        <>\n                                            {__('Note: This setting is required if you wish to use Instagram Feed in your website. ', 'uael')}\n                                            <a\n                                                href={`${uaelSettingsData.uael_domain}docs/instagram-feed-widget/?utm_source=uael-pro-dashboard&utm_medium=uael-editor-screen&utm_campaign=uael-pro-plugin`}\n                                                target=\"_blank\"\n                                                rel=\"noopener noreferrer\"\n                                                className=\"uael-link-color no-underline\"\n                                            >\n                                                {__('Need Help?', 'uael')}\n                                            </a>\n                                        </>\n                                    ) : ''\n                                }\n                                className=\"\"\n                            />\n\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('App ID', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('App ID', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"instagram_app_id\" // Match the key with the backend\n                                        value={settings.instagram_app_id}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter Instagram App ID', 'uael')}\n                                        className='w-full border border-subtle px-2'\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('App Secret', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('App Secret', 'uael')}</p> */}\n                                    <input\n                                        type=\"text\"\n                                        name=\"instagram_app_secret\" // Match the key with the backend\n                                        value={settings.instagram_app_secret}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Enter Instagram App Secret', 'uael')}\n                                        className='w-full border border-subtle px-2'\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                            // marginTop: '16px'\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n                            </div>\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2 mt-1\">\n                                <div className='flex flex-row items-center justify-between pb-1'>\n                                    <Title\n                                        icon={null}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        tag=\"h2\"\n                                        title={__('Access Token', 'uael')}\n                                        description=\"\"\n                                        className=\"uae-subtitle\"\n                                    />\n                                    {/* <p className='font-normal text-field-label text-base'>{__('Access Token', 'uael')}</p> */}\n                                    <Button\n                                        icon={tokenRefresh ? <LoaderCircle className=\"animate-spin\" /> : <RefreshCcw style={{ color: \"#6005FF\" }} />}\n                                        className=\"uael-remove-ring\"\n                                        variant=\"link\"\n                                        iconPosition=\"left\"\n                                        onClick={generateInstagramAccessToken}\n                                        style={{ width: 'fit-content', outline: 'none', textDecoration: 'none', color: '#6005FF' }}\n                                    >\n                                        {tokenRefresh ? __('Refreshing token...', 'uael') : __('Refresh Access Token', 'uael')}\n                                    </Button>\n                                </div>\n                                <input\n                                    type=\"text\"\n                                    name=\"instagram_app_token\" // Match the key with the backend\n                                    value={settings.instagram_app_token}\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Enter Instagram Access Token', 'uael')}\n                                    className='w-full border border-subtle'\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',     // Removes the default box shadow\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n                        </Container>\n                        <Button\n                            type=\"submit\"\n                            style={{ backgroundColor: '#6005ff' }}\n                            icon={isSaving ? <LoaderCircle className=\"animate-spin\" /> : null}\n                            iconPosition=\"left\"\n                            disabled={isSaving}\n                            className=\"w-full mt-4 sticky\"\n                        >\n                            {isSaving ? __('Saving...', 'uael') : __('Save', 'uael')}\n                        </Button>\n\n                        <Toaster\n                            position=\"top-right\"\n                            reverseOrder={false}\n                            gutter={8}\n                            containerStyle={{\n                                top: 20,\n                                right: 20,\n                                marginTop: '80px',\n                            }}\n                            toastOptions={{\n                                duration: 5000,\n                                style: {\n                                    background: 'white',\n                                },\n                                success: {\n                                    duration: 3000,\n                                    style: {\n                                        color: '',\n                                    },\n                                    iconTheme: {\n                                        primary: '#6005ff',\n                                        secondary: '#fff',\n                                    },\n                                },\n                            }}\n                        />\n                </div>\n            </div>\n        </form>\n    );\n}\n\nexport default Integrations\n","import React, { useState, useEffect } from 'react'\nimport { Container, Title, Button, Switch, Loader } from \"@bsf/force-ui\";\nimport { LoaderCircle, FileText } from 'lucide-react';\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\nimport toast, { Toaster } from 'react-hot-toast';\n\nconst Branding = (args) => {\n    const [settings, setSettings] = useState({\n        author: '',\n        author_url: '',\n        plugin_name: '',\n        short_name: '',\n        description: '',\n        hide_branding: false,\n        logo_url: '',\n        internal_help_links: false,\n        replace_logo: false\n    });\n\n    const [loading, setLoading] = useState(true);\n    const [isSaving, setIsSaving] = useState(false);\n\n    // Fetch branding settings on component mount\n    useEffect(() => {\n        const fetchBrandingSettings = () => {\n            setLoading(true);\n\n            apiFetch({\n                path: '/uael/v1/branding',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action,\n                },\n            })\n                .then((data) => {\n                    setSettings({\n                        author: data.agency.author || '',\n                        author_url: data.agency.author_url || '',\n                        plugin_name: data.plugin.name || '',\n                        short_name: data.plugin.short_name || '',\n                        description: data.plugin.description || '',\n                        hide_branding: ('1' === data.agency.hide_branding || 'enable' === data.agency.hide_branding) ? true : false,\n                        replace_logo: 'enable' === data.replace_logo ? true : false,\n                        logo_url: data.logo_url || '',\n                        internal_help_links: 'enable' === data.internal_help_links ? true : false,\n                    });\n                    setLoading(false);\n                })\n                .catch((error) => {\n                    console.error('Error fetching branding settings:', error);\n                    toast.error(__('Error fetching settings. Please try again.', 'uael'));\n                    setLoading(false);\n                });\n        };\n\n        fetchBrandingSettings();\n    }, []);\n\n    if (loading) {\n        return (\n            <div className='h-screen w-screen flex items-center justify-center' style={{ position: 'relative' }}>\n                <Loader icon={null} size=\"lg\" className=\"bg-transparent relative uae-loader-icon\" />\n            </div>\n        );\n    }\n\n    const handleChange = (name, value) => {\n        setSettings(prev => ({ ...prev, [name]: value }));\n    };\n\n    const handleSubmit = (e) => {\n        e.preventDefault();\n        setIsSaving(true);\n\n        const dataToSend = {\n            agency: {\n                author: settings.author,\n                author_url: settings.author_url,\n                hide_branding: settings.hide_branding ? 'enable' : 'disable',\n            },\n            plugin: {\n                name: settings.plugin_name,\n                short_name: settings.short_name,\n                description: settings.description,\n            },\n            logo_url: settings.logo_url,\n            internal_help_links: settings.internal_help_links ? 'enable' : 'disable',\n            replace_logo: settings.replace_logo ? 'enable' : 'disable',\n        };\n\n        fetch('/wp-json/uael/v1/branding', {\n            method: 'POST',\n            headers: {\n                'Content-Type': 'application/json',\n                'X-WP-Nonce': uaelSettingsData.uael_nonce_action,\n            },\n            body: JSON.stringify(dataToSend),\n        })\n            .then((response) => {\n                if (!response.ok) {\n                    throw new Error('Network response was not ok');\n                }\n                return response.json();\n            })\n            .then(() => {\n                toast.success(__('Settings saved successfully!', 'uael'));\n                location.reload();\n            })\n            .catch((error) => {\n                console.error('Error saving settings:', error);\n                toast.error(__('Error saving settings. Please try again.', 'uael'));\n            })\n            .finally(() => {\n                setIsSaving(false);\n            });\n    };\n\n    return (\n        <form onSubmit={handleSubmit}>\n            <div\n                className='rounded-lg'\n            >\n                <div className='flex flex-row items-center justify-between' style={{ paddingBottom: '24px' }} >\n                    <Title\n                        description=\"\"\n                        icon={null}\n                        iconPosition=\"right\"\n                        size=\"sm\"\n                        tag=\"h2\"\n                        title={__('White Label', 'uael')}\n                    />\n\n                    <div className='flex items-center justify-between [&_h2]:text-[#6005ff]' style={{ gap: '22px' }}>\n                        <div className='flex items-center gap-1 cursor-pointer' style={{ position: 'relative' }}>\n                            <FileText style={{ color: '#6005ff', size: '20px' }} />\n                            <a href=\"https://ultimateelementor.com/docs/how-to-white-label-uael/\" target=\"_blank\" className='text-[#6005ff] text-sm font-medium no-underline' style={{ color: '#6005ff', boxShadow: 'none' }}>{__('Read Documentation', 'uael')}</a>\n                        </div>\n                        <Button\n                            type=\"submit\"\n                            style={{ backgroundColor: '#6005ff', position: 'relative' }}\n                            className=\"flex items-center justify-center\"\n                            icon={isSaving ? <LoaderCircle className=\"animate-spin\" /> : null}\n                            iconPosition=\"left\"\n                            disabled={isSaving}\n                        >\n                            {isSaving ? __('Saving...', 'uael') : __('Save', 'uael')}\n                        </Button>\n                    </div>\n                </div>\n                <div className=\"w-full\" style={{ marginTop: \"24px\" }}>\n                        <Container\n                            align=\"stretch\"\n                            className=\"flex flex-column bg-background-primary p-6 rounded-lg\"\n                            containerType=\"flex\"\n                            direction=\"column\"\n                        >\n\n                            <Title size=\"sm\" tag=\"h2\" title={__('Plugins Details', 'uael')} description={__('You can change the author name and plugin details that are displayed in the WordPress backend.', 'uael')} />\n\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <div className='text-base text-field-label font-semibold m-0 mb-2'>Author</div>\n                                    <input\n                                        label={__('Author:', 'uael')}\n                                        name=\"author\"\n                                        type=\"text\"\n                                        value={settings.author}\n                                        className='w-full border border-subtle px-2'\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Brainstorm Force', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <div className='text-base text-field-label font-semibold m-0 mb-2'>Author URL</div>\n                                    <input\n                                        label={__('Author URL:', 'uael')}\n                                        name=\"author_url\"\n                                        className='w-full border border-subtle px-2'\n                                        type=\"url\"\n                                        value={settings.author_url}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('https://www.brainstormforce.com', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n                            </div>\n\n                            <div className=\"flex flex-row items-center mt-1 w-full gap-3\">\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <div className='text-base text-field-label font-semibold m-0 mb-2'>Plugin Name</div>\n                                    <input\n                                        label={__('Plugin Name:', 'uael')}\n                                        name=\"plugin_name\"\n                                        type=\"text\"\n                                        className='w-full border border-subtle px-2'\n                                        value={settings.plugin_name}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('Ultimate Addons', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n\n                                <Container.Item className=\"flex flex-col space-y-1 basis-1/2 flex-1\">\n                                    <div className='text-base text-field-label font-semibold m-0 mb-2'>Plugin Short Name</div>\n                                    <input\n                                        label={__('Plugin Short Name:', 'uael')}\n                                        name=\"short_name\"\n                                        type=\"text\"\n                                        className='w-full border border-subtle px-2'\n                                        value={settings.short_name}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('UAE', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',     // Removes the default box shadow\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n                            </div>\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <div className='text-base text-field-label font-semibold m-0'>Plugin Description</div>\n                                <input\n                                    label={__('Plugin Description:', 'uael')}\n                                    name=\"description\"\n                                    type=\"text\"\n                                    className='w-full border border-subtle'\n                                    value={settings.description}\n                                    onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                    placeholder={__('Ultimate Addons is a premium extension for Elementor...', 'uael')}\n                                    style={{\n                                        height: '48px',\n                                        borderColor: '#e0e0e0', // Default border color\n                                        outline: 'none',       // Removes the default outline\n                                        boxShadow: 'none',\n                                        marginTop: '16px'     // Removes the default box shadow\n                                    }}\n                                    onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                    onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                />\n                            </Container.Item>\n\n                            <div className='border border-subtle' style={{ height: '2px', backgroundColor: '#E5E7EB', marginTop: '6px' }} />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <div className='flex flex-row items-center justify-between px-1'>\n                                    <div>\n                                        <Title size=\"xs\" tag=\"h3\" title={__('Replace or Hide Logo', 'uael')} className=\"mt-4\" description={__('Enable this option to hide the default logo or replace it with your own logo. (Note: To hide the logo, leave the logo URL field empty.)', 'uael')} />\n                                    </div>\n                                    <Switch\n                                        onChange={(e) => handleChange('replace_logo', e)}\n                                        size='md'\n                                        value={settings.replace_logo}\n                                        className=\"uael-remove-ring\"\n                                    />\n                                </div>\n                            </Container.Item>\n                            {settings.replace_logo && (\n                                <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                    <div className='text-base text-field-label font-semibold m-0'>{__('Enter logo URL to replace', 'uael')}</div>\n                                    <input\n                                        label={__('Replace Plugin Logo URL:', 'uael')}\n                                        name=\"logo_url\"\n                                        type=\"url\"\n                                        className='w-full border border-subtle'\n                                        value={settings.logo_url}\n                                        onChange={(e) => handleChange(e.target.name, e.target.value)}\n                                        placeholder={__('https://www.example.com/logo.svg', 'uael')}\n                                        style={{\n                                            height: '48px',\n                                            borderColor: '#e0e0e0', // Default border color\n                                            outline: 'none',       // Removes the default outline\n                                            boxShadow: 'none',\n                                            marginTop: '16px'     // Removes the default box shadow\n                                        }}\n                                        onFocus={(e) => e.target.style.borderColor = '#6005FF'} // Apply focus color\n                                        onBlur={(e) => e.target.style.borderColor = '#e0e0e0'}  // Revert to default color\n                                    />\n                                </Container.Item>\n                            )}\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <div className='flex flex-row items-center justify-between px-1'>\n                                    <div>\n                                        <Title size=\"xs\" tag=\"h3\" title={__('Hide White Label Settings', 'uael')} className=\"mt-4\" description={__('Enabling this option will hide the White Label settings. To access it again, re-activate the plugin.', 'uael')} />\n                                    </div>\n                                    <Switch\n                                        onChange={(e) => handleChange('hide_branding', e)}\n                                        size='md'\n                                        value={settings.hide_branding}\n                                    />\n                                </div>\n                            </Container.Item>\n\n                            <div className='border border-subtle' style={{ height: '2px', backgroundColor: '#E5E7EB', marginTop: '6px' }} />\n\n                            <Container.Item className=\"flex flex-col w-full space-y-1 space-x-2\">\n                                <Title size=\"sm\" tag=\"h2\" title={__('Elementor Editor Area', 'uael')} className=\"mt-1\" />\n                                <div className='flex flex-row items-center justify-between px-1'>\n                                    <Title size=\"xs\" tag=\"h3\" title={__('Show Help Links', 'uael')} className=\"mt-4\" description={__('Display internal help links in widget editor area.', 'uael')} />\n\n                                    <Switch\n                                        onChange={(e) => handleChange('internal_help_links', e)}\n                                        size='md'\n                                        value={settings.internal_help_links}\n                                    />\n                                </div>\n                            </Container.Item>\n\n                        </Container>\n                </div>\n                <Toaster\n                    position=\"top-right\"\n                    reverseOrder={false}\n                    gutter={8}\n                    containerStyle={{\n                        top: 20,\n                        right: 20,\n                        marginTop: '80px',\n                    }}\n                    toastOptions={{\n                        duration: 5000,\n                        style: {\n                            background: 'white',\n                        },\n                        success: {\n                            duration: 3000,\n                            style: {\n                                color: '',\n                            },\n                            iconTheme: {\n                                primary: '#6005ff',\n                                secondary: '#fff',\n                            },\n                        },\n                    }}\n                />\n            </div>\n        </form>\n    );\n}\n\nexport default Branding\n","import React, { useEffect, useState } from 'react'\nimport { Container, Switch } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\n\n// Create a queue to manage AJAX requests\nconst requestQueue = [];\n\nconst processQueue = () => {\n    if (requestQueue.length === 0) return;\n\n    // Take the first item from the queue and run it\n    const currentRequest = requestQueue.shift();\n    currentRequest();\n};\n\nconst PostWidgetItem = ({\n    widget,\n    updateCounter\n}) => {\n    const {\n        id,\n        image,\n        title,\n    } = widget\n\n    // Track the active state of the widget using React state\n    const [isActive, setIsActive] = useState(widget.is_active);\n    const [isLoading, setIsLoading] = useState(false);\n\n    useEffect(() => {\n        setIsActive(widget.is_active);\n    }, [widget.is_active, updateCounter]);\n\n    const apiCall = (activateWidget) => {\n        const action = activateWidget ? 'uael_deactivate_widget' : 'uael_activate_widget';\n\n        const formData = new window.FormData();\n        formData.append('action', action);\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n        formData.append('module_id', id);\n\n        try {\n            const data = apiFetch({\n                url: uaelSettingsData.ajax_url,\n                method: 'POST',\n                body: formData,\n            });\n\n            if (data.success) {\n                setIsActive(isActive);  // Update the active state after the request\n            } else if (data.error) {\n                // console.log('AJAX request failed');\n            }\n        } catch (err) {\n            // console.log(\"Error during AJAX request\");\n        } finally {\n            setIsLoading(false);  // Always stop the loading spinner\n            processQueue();\n        }\n    }\n\n    const handleSwitchChange = () => {\n        if (isLoading) return;\n\n        setIsLoading(true);\n\n        if (isActive) {\n            // Add the request to the queue\n            setIsActive(false);\n            requestQueue.push(() => apiCall(isActive));\n        } else {\n            // Add the request to the queue\n            setIsActive(true);\n            requestQueue.push(() => apiCall(isActive));\n        }\n\n        // Update the active state immediately\n        if (requestQueue.length === 1) {\n            // Start processing the queue if no other request is being processed\n            processQueue();\n        }\n    };\n\n    return (\n        <Container align=\"center\"\n            containerType=\"flex\"\n            direction=\"row\"\n            justify=\"between\"\n            gap=\"\"\n        >\n            <div className='flex flex-col w-full'>\n                <div className='flex items-center justify-between w-full'>\n                    <p className='text-sm font-medium text-text-primary pt-3 m-0 pb-1'>{title}</p>\n                    <div className='flex items-center'>\n                        <Switch\n                            onChange={handleSwitchChange}\n                            size='sm'\n                            value={isActive}\n                        />\n                    </div>\n                </div>\n                <img\n                    src={image}\n                    alt=\"Custom SVG\"\n                    className=\"mt-2\"\n                />\n            </div>\n        </Container>\n    )\n}\n\nexport default PostWidgetItem","import React, { useState, useEffect } from 'react';\nimport { Container, Title, Button, Skeleton, Loader } from \"@bsf/force-ui\";\nimport { LoaderCircle } from 'lucide-react';\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from '@wordpress/i18n';\nimport PostWidgetItem from '@components/Dashboard/PostWidgetItem';\nimport toast, { Toaster } from 'react-hot-toast';\n\nconst PostSkins = () => {\n    const [allWidgetsData, setAllWidgetsData] = useState(null);\n    const [loadingActivate, setLoadingActivate] = useState(false);\n    const [loadingDeactivate, setLoadingDeactivate] = useState(false);\n    const [updateCounter, setUpdateCounter] = useState(0);\n    const [loading, setLoading] = useState(true);\n\n    useEffect(() => {\n        const fetchSettings = () => {\n            setLoading(true);\n            apiFetch({\n                path: '/uael/v1/postskins',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action, // Use the correct nonce\n                },\n            })\n                .then((data) => {\n                    const widgetsData = convertToWidgetsArray(data);\n                    setAllWidgetsData(widgetsData);\n                    setLoading(false); // Stop loading\n                })\n                .catch((err) => {\n                    setLoading(false); // Stop loading\n                });\n        };\n\n        fetchSettings();\n    }, []);\n\n    const handleActivateAll = async () => {\n        setLoadingActivate(true);\n\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_activate_skins');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingActivate(false);\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: true }))\n                );\n                setUpdateCounter(prev => prev + 1)\n                toast.success(__('All skins activated successfully!.', 'uael'));\n            } else if (data.error) {\n                console.error('AJAX request failed:', data.error);\n                toast.error(__('Failed to activate all skins.', 'uael'));\n            }\n        }).catch((error) => {\n            setLoadingActivate(false);\n            console.error('Error during AJAX request:', error);\n            toast.error(__('An error occurred while activating all skins.', 'uael'));\n        });\n    };\n\n    const handleDeactivateAll = async () => {\n        setLoadingDeactivate(true);\n\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_deactivate_skins');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingDeactivate(false);\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: false }))\n                );\n                setUpdateCounter(prev => prev + 1);\n                toast.success(__('All skins deactivated successfully!.', 'uael'));\n            } else if (data.error) {\n                console.error('AJAX request failed:', data.error);\n                toast.error(__('Failed to deactivate all skins.', 'uael'));\n            }\n        }).catch((error) => {\n            setLoadingDeactivate(false);\n            console.error('Error during AJAX request:', error);\n            toast.error(__('An error occurred while deactivating all skins.', 'uael'));\n        });\n    };\n\n    function convertToWidgetsArray(data) {\n        const widgets = [];\n\n        for (const key in data) {\n            if (data.hasOwnProperty(key)) {\n                const widget = data[key];\n                widgets.push({\n                    id: key,\n                    slug: widget.slug,\n                    title: widget.title,\n                    image: widget.image,\n                    default: widget.default,\n                    is_active: widget.is_activate !== undefined ? widget.is_activate : true,\n                });\n            }\n        }\n\n        return widgets;\n    }\n\n    if (loading) {\n        return (\n            <div className='h-screen w-screen flex items-center justify-center' style={{ position: 'relative' }}>\n                <Loader icon={null} size=\"lg\" className=\"bg-transparent relative uae-loader-icon\" />\n            </div>\n        );\n    }\n\n    return (\n        <>\n            <Toaster\n                position=\"top-right\"\n                reverseOrder={false}\n                gutter={8}\n                containerStyle={{\n                    top: 20,\n                    right: 20,\n                    marginTop: '40px',\n                }}\n                toastOptions={{\n                    duration: 5000,\n                    style: {\n                        background: 'white',\n                    },\n                    success: {\n                        duration: 3000,\n                        iconTheme: {\n                            primary: '#6005ff',\n                            secondary: '#fff',\n                        },\n                    },\n                }}\n            />\n            <Title\n                description=\"\"\n                icon={null}\n                iconPosition=\"right\"\n                size=\"sm\"\n                tag=\"h2\"\n                title={__(\"Post Widget Skins\", \"uael\")}\n            />\n            <div className='rounded-lg bg-white mb-4'>\n                <div className='flex flex-col md:flex-row items-center justify-between p-4' \n                style={{\n                    paddingBottom: '0',\n                    marginTop: '16px',\n                }}>\n                    <p className='m-0 text-sm font-semibold text-text-primary'>Skins</p>\n                    <div className='flex items-center gap-x-2 mr-7'>\n                        <Button\n                            icon={loadingActivate ? <LoaderCircle className=\"animate-spin\" /> : null}\n                            iconPosition=\"left\"\n                            variant=\"outline\"\n                            className=\"uae-bulk-action-button\"\n                            onClick={handleActivateAll}\n                        >\n                            {loadingActivate ? 'Activating...' : 'Activate All'}\n                        </Button>\n                        <Button\n                            icon={loadingDeactivate ? <LoaderCircle className=\"animate-spin\" /> : null}\n                            iconPosition=\"left\"\n                            variant=\"outline\"\n                            onClick={handleDeactivateAll}\n                            className=\"uae-bulk-action-button\"\n                        >\n                            {loadingDeactivate ? 'Deactivating...' : 'Deactivate All'}\n                        </Button>\n                    </div>\n                </div>\n                <div className='flex bg-black flex-col rounded-lg p-4'>\n                    {loading ? (\n                        <Container\n                            align=\"stretch\"\n                            className=\"p-2 gap-1.5\"\n                            cols={1}\n                            style={{\n                                backgroundColor: \"#F9FAFB\", height: '380px'\n                            }}\n                            containerType=\"grid\"\n                            gap=\"\"\n                            justify=\"start\"\n                        >\n                            {[...Array(4)].map((_, index) => (\n                                <Container.Item\n                                    key={index}\n                                    alignSelf=\"auto\"\n                                    className=\"text-wrap rounded-md bg-background-primary p-6 space-y-2\"\n                                >\n                                    <Skeleton className='w-12 h-2 rounded-md' />\n                                    <Skeleton className='w-16 h-2 rounded-md' />\n                                    <Skeleton className='w-12 h-2 rounded-md' />\n                                </Container.Item>\n                            ))}\n                        </Container>\n                    ) : (\n                        <Container\n                            align=\"stretch\"\n                            className=\"p-2 gap-1.5 grid grid-cols-1 md:grid-cols-2\"\n                            containerType=\"grid\"\n                            gap=\"\"\n                            justify=\"start\"\n                            style={{ backgroundColor: '#F9FAFB' }}\n                        >\n                            {allWidgetsData?.slice(0, 4).map((widget) => (\n                                <Container.Item\n                                    key={widget.id}\n                                    alignSelf=\"auto\"\n                                    className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-4\"\n                                >\n                                    <PostWidgetItem widget={{ ...widget, updateCounter }} key={widget.id} updateCounter={updateCounter} />\n                                </Container.Item>\n                            ))}\n                        </Container>\n                    )}\n                </div>\n            </div>\n        </>\n    );\n}\n\nexport default PostSkins;\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst RotateCw = createLucideIcon(\"RotateCw\", [\n  [\"path\", { d: \"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8\", key: \"1p45f6\" }],\n  [\"path\", { d: \"M21 3v5h-5\", key: \"1q7to0\" }]\n]);\n\nexport { RotateCw as default };\n//# sourceMappingURL=rotate-cw.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Sun = createLucideIcon(\"Sun\", [\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"4\", key: \"4exip2\" }],\n  [\"path\", { d: \"M12 2v2\", key: \"tus03m\" }],\n  [\"path\", { d: \"M12 20v2\", key: \"1lh1kg\" }],\n  [\"path\", { d: \"m4.93 4.93 1.41 1.41\", key: \"149t6j\" }],\n  [\"path\", { d: \"m17.66 17.66 1.41 1.41\", key: \"ptbguv\" }],\n  [\"path\", { d: \"M2 12h2\", key: \"1t8f8n\" }],\n  [\"path\", { d: \"M20 12h2\", key: \"1q8mjw\" }],\n  [\"path\", { d: \"m6.34 17.66-1.41 1.41\", key: \"1m8zz5\" }],\n  [\"path\", { d: \"m19.07 4.93-1.41 1.41\", key: \"1shlcs\" }]\n]);\n\nexport { Sun as default };\n//# sourceMappingURL=sun.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst FilePenLine = createLucideIcon(\"FilePenLine\", [\n  [\n    \"path\",\n    {\n      d: \"m18 5-2.414-2.414A2 2 0 0 0 14.172 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2\",\n      key: \"142zxg\"\n    }\n  ],\n  [\n    \"path\",\n    {\n      d: \"M21.378 12.626a1 1 0 0 0-3.004-3.004l-4.01 4.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z\",\n      key: \"2t3380\"\n    }\n  ],\n  [\"path\", { d: \"M8 18h1\", key: \"13wk12\" }]\n]);\n\nexport { FilePenLine as default };\n//# sourceMappingURL=file-pen-line.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Server = createLucideIcon(\"Server\", [\n  [\"rect\", { width: \"20\", height: \"8\", x: \"2\", y: \"2\", rx: \"2\", ry: \"2\", key: \"ngkwjq\" }],\n  [\"rect\", { width: \"20\", height: \"8\", x: \"2\", y: \"14\", rx: \"2\", ry: \"2\", key: \"iecqi9\" }],\n  [\"line\", { x1: \"6\", x2: \"6.01\", y1: \"6\", y2: \"6\", key: \"16zg32\" }],\n  [\"line\", { x1: \"6\", x2: \"6.01\", y1: \"18\", y2: \"18\", key: \"nzw8ys\" }]\n]);\n\nexport { Server as default };\n//# sourceMappingURL=server.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Clock = createLucideIcon(\"Clock\", [\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n  [\"polyline\", { points: \"12 6 12 12 16 14\", key: \"68esgv\" }]\n]);\n\nexport { Clock as default };\n//# sourceMappingURL=clock.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Copy = createLucideIcon(\"Copy\", [\n  [\"rect\", { width: \"14\", height: \"14\", x: \"8\", y: \"8\", rx: \"2\", ry: \"2\", key: \"17jyea\" }],\n  [\"path\", { d: \"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2\", key: \"zix9uf\" }]\n]);\n\nexport { Copy as default };\n//# sourceMappingURL=copy.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst ExternalLink = createLucideIcon(\"ExternalLink\", [\n  [\"path\", { d: \"M15 3h6v6\", key: \"1q9fwt\" }],\n  [\"path\", { d: \"M10 14 21 3\", key: \"gplh6r\" }],\n  [\"path\", { d: \"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\", key: \"a6xqqp\" }]\n]);\n\nexport { ExternalLink as default };\n//# sourceMappingURL=external-link.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Check = createLucideIcon(\"Check\", [[\"path\", { d: \"M20 6 9 17l-5-5\", key: \"1gmf2c\" }]]);\n\nexport { Check as default };\n//# sourceMappingURL=check.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Sparkles = createLucideIcon(\"Sparkles\", [\n  [\n    \"path\",\n    {\n      d: \"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z\",\n      key: \"4pj2yx\"\n    }\n  ],\n  [\"path\", { d: \"M20 3v4\", key: \"1olli1\" }],\n  [\"path\", { d: \"M22 5h-4\", key: \"1gvqau\" }],\n  [\"path\", { d: \"M4 17v2\", key: \"vumght\" }],\n  [\"path\", { d: \"M5 18H3\", key: \"zchphs\" }]\n]);\n\nexport { Sparkles as default };\n//# sourceMappingURL=sparkles.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst TriangleAlert = createLucideIcon(\"TriangleAlert\", [\n  [\n    \"path\",\n    {\n      d: \"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3\",\n      key: \"wmoenq\"\n    }\n  ],\n  [\"path\", { d: \"M12 9v4\", key: \"juzpu7\" }],\n  [\"path\", { d: \"M12 17h.01\", key: \"p32p05\" }]\n]);\n\nexport { TriangleAlert as default };\n//# sourceMappingURL=triangle-alert.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Lock = createLucideIcon(\"Lock\", [\n  [\"rect\", { width: \"18\", height: \"11\", x: \"3\", y: \"11\", rx: \"2\", ry: \"2\", key: \"1w4ew1\" }],\n  [\"path\", { d: \"M7 11V7a5 5 0 0 1 10 0v4\", key: \"fwvmzm\" }]\n]);\n\nexport { Lock as default };\n//# sourceMappingURL=lock.js.map\n","import React, { useState, useEffect, useMemo, useRef } from 'react';\nimport { Switch, Tooltip, Title } from \"@bsf/force-ui\";\nimport { __, sprintf } from '@wordpress/i18n';\nimport toast, { Toaster } from 'react-hot-toast';\nimport apiFetch from '@wordpress/api-fetch';\nimport {\n\tCopy, Check, ExternalLink, Sparkles,\n\tRotateCw, ChevronRight, Search,\n\tSun, FilePenLine, Server, Clock, Lock,\n\tAlertTriangle,\n} from 'lucide-react';\n\n// WP MCP Adapter feature plugin — required for the dedicated MCP endpoint.\nconst MCP_ADAPTER_GITHUB = 'https://github.com/WordPress/mcp-adapter';\nconst MCP_ADAPTER_DOWNLOAD = 'https://github.com/WordPress/mcp-adapter/releases/latest/download/mcp-adapter.zip';\n\n// Brand purple is needed as a JS value for the react-hot-toast icon theme\n// (a component prop, not a stylable element). All visual styling lives in\n// src/styles.css under .uae-ai-tools.\nconst BRAND = '#6005ff';\n\n// ───────── Reusable bits ─────────\n\nconst Card = ({ children }) => <div className=\"uae-ai-card\">{children}</div>;\n\nconst CardHead = ({ title, description, right }) => (\n\t<div className=\"uae-ai-cardhead\">\n\t\t<div className=\"uae-ai-cardhead-main\">\n\t\t\t<h3 className=\"uae-ai-c-ink text-base font-semibold m-0\">{title}</h3>\n\t\t\t{description && <p className=\"uae-ai-c-muted text-sm font-normal m-0\">{description}</p>}\n\t\t</div>\n\t\t{right}\n\t</div>\n);\n\nconst HeaderBadge = ({ tone = 'ok', dot, dotClass = '', children }) => (\n\t<span className={`uae-ai-hbadge text-xs font-semibold ${tone === 'ok' ? 'is-ok' : ''}`}>\n\t\t{dot && <span className={`uae-ai-hbadge-dot ${dotClass}`} />}\n\t\t{children}\n\t</span>\n);\n\nconst Chip = ({ tone = 'ok', children }) => (\n\t<span className={`uae-ai-chip text-xxs font-semibold ${tone === 'ok' ? 'is-ok' : 'is-muted'}`}>\n\t\t<span className=\"uae-ai-chip-dot\" />\n\t\t{children}\n\t</span>\n);\n\n// ───────── Main component ─────────\n\nconst AITools = () => {\n\t// Guard the localized global so a missing/blocked localize script degrades\n\t// gracefully instead of throwing a ReferenceError and white-screening.\n\tconst uaelSettingsData = window.uaelSettingsData || {};\n\tconst initialSettings = uaelSettingsData.mcp_settings || {};\n\tconst isAbilitiesApiActive = uaelSettingsData.is_abilities_api_active;\n\tconst isMcpAdapterActive = uaelSettingsData.is_mcp_adapter_active;\n\tconst isAngieActive = uaelSettingsData.is_angie_active;\n\tconst siteUrl = uaelSettingsData.site_url || window.location.origin;\n\tconst currentUser = uaelSettingsData.current_user || 'admin';\n\tconst restUrl = uaelSettingsData.rest_url || (siteUrl.replace(/\\/$/, '') + '/wp-json/');\n\tconst appPasswordUrl = uaelSettingsData.application_passwords_url || (siteUrl + '/wp-admin/profile.php#application-passwords-section');\n\n\tconst [settings, setSettings] = useState({\n\t\tenable_abilities: initialSettings.enable_abilities ?? false,\n\t\tallow_modifications: initialSettings.allow_modifications ?? true,\n\t\tdedicated_server: initialSettings.dedicated_server ?? false,\n\t\tangie_enabled: initialSettings.angie_enabled ?? false,\n\t\tdisabled_abilities: initialSettings.disabled_abilities ?? [],\n\t});\n\n\t// Mirror of `settings` that is always current within the same tick. Toggle\n\t// handlers read/update this ref instead of the (possibly stale) `settings`\n\t// closure, so flipping two switches in quick succession accumulates correctly\n\t// instead of one overwriting the other.\n\tconst settingsRef = useRef(settings);\n\tuseEffect(() => { settingsRef.current = settings; }, [settings]);\n\n\tconst [saving, setSaving] = useState(false);\n\tconst [abilities, setAbilities] = useState([]);\n\tconst [expandedGroups, setExpandedGroups] = useState({});\n\tconst [pageTab, setPageTab] = useState('overview');\n\tconst [scopeTab, setScopeTab] = useState('uae-only');\n\tconst [copied, setCopied] = useState(false);\n\tconst [promptCopied, setPromptCopied] = useState(false);\n\tconst [searchQuery, setSearchQuery] = useState('');\n\tconst [filterMode, setFilterMode] = useState('all');\n\n\tuseEffect(() => {\n\t\tapiFetch({\n\t\t\tpath: '/uael/v1/mcp-abilities',\n\t\t\theaders: { 'X-WP-Nonce': uaelSettingsData.uael_nonce_action },\n\t\t}).then((data) => {\n\t\t\tif (Array.isArray(data)) setAbilities(data);\n\t\t}).catch(() => {});\n\t}, []);\n\n\t// Bounce off Server & Connect tab if its pre-conditions go away.\n\tuseEffect(() => {\n\t\tif (pageTab === 'server' && (!settings.enable_abilities || !settings.dedicated_server)) {\n\t\t\tsetPageTab('overview');\n\t\t}\n\t}, [pageTab, settings.enable_abilities, settings.dedicated_server]);\n\n\tconst namespaceLabels = {\n\t\t'hfe-info': __('Plugin Info', 'uael'),\n\t\t'hfe-pages': __('Pages', 'uael'),\n\t\t'hfe-templates': __('Templates & Builder', 'uael'),\n\t\t'hfe-widgets': __('Widgets', 'uael'),\n\t\t'hfe-extensions': __('Extensions', 'uael'),\n\t\t'hfe-display-rules': __('Display Rules', 'uael'),\n\t\t'hfe-active-templates': __('Active Templates', 'uael'),\n\t\t'hfe-theme-compat': __('Theme', 'uael'),\n\t\t'hfe-settings': __('Settings', 'uael'),\n\t\t'hfe-shortcodes': __('Shortcode', 'uael'),\n\t\t'hfe-design': __('Design System', 'uael'),\n\t\t'hfe-maintenance': __('Maintenance', 'uael'),\n\t\t'hfe-pro': __('Pro Features', 'uael'),\n\t\t'uael-info': __('Plugin Info', 'uael'),\n\t\t'uael-skins': __('Post Skins', 'uael'),\n\t\t'uael-settings': __('Integrations & Branding', 'uael'),\n\t\t'uael-widgets': __('Widget Management', 'uael'),\n\t\t'uael-builder': __('Page Builder', 'uael'),\n\t\t'uael-pages': __('Page Management', 'uael'),\n\t\t'uael-design': __('Design System', 'uael'),\n\t\t'uael-maintenance': __('Maintenance', 'uael'),\n\t};\n\n\tconst namespaceDescriptions = {\n\t\t'hfe-info': __('Plugin version, health, and compatibility info', 'uael'),\n\t\t'hfe-pages': __('Create and manage WordPress pages', 'uael'),\n\t\t'hfe-templates': __('Create, edit, and manage templates and page layouts', 'uael'),\n\t\t'hfe-widgets': __('Activate, deactivate, and list available widgets', 'uael'),\n\t\t'hfe-extensions': __('Toggle Scroll to Top and Reading Progress Bar', 'uael'),\n\t\t'hfe-display-rules': __('Control where templates appear on your site', 'uael'),\n\t\t'hfe-active-templates': __('See which header/footer is active on any page', 'uael'),\n\t\t'hfe-theme-compat': __('Theme detection and compatibility settings', 'uael'),\n\t\t'hfe-settings': __('Read and update plugin configuration', 'uael'),\n\t\t'hfe-shortcodes': __('Render template shortcodes', 'uael'),\n\t\t'hfe-design': __('Get site colors, fonts, and spacing', 'uael'),\n\t\t'hfe-maintenance': __('Clear caches and run maintenance tasks', 'uael'),\n\t\t'hfe-pro': __('UAE Pro upgrade information and pricing', 'uael'),\n\t\t'uael-info': __('Plugin version, widgets, and compatibility info', 'uael'),\n\t\t'uael-skins': __('Manage post display skins', 'uael'),\n\t\t'uael-settings': __('Manage API keys and white-label branding', 'uael'),\n\t\t'uael-widgets': __('Activate, deactivate, and list Pro widgets', 'uael'),\n\t\t'uael-builder': __('Build and modify page layouts with Elementor', 'uael'),\n\t\t'uael-pages': __('Create and manage WordPress pages', 'uael'),\n\t\t'uael-design': __('Get site colors, fonts, and spacing', 'uael'),\n\t\t'uael-maintenance': __('Clear caches and run maintenance tasks', 'uael'),\n\t};\n\n\tconst groupedAbilities = useMemo(() => {\n\t\tconst groups = {};\n\t\tabilities.forEach((ability) => {\n\t\t\tconst cat = ability.category || 'other';\n\t\t\tif (!groups[cat]) groups[cat] = [];\n\t\t\tgroups[cat].push(ability);\n\t\t});\n\t\treturn groups;\n\t}, [abilities]);\n\n\tconst readCount = useMemo(() => abilities.filter(a => a.readonly).length, [abilities]);\n\tconst writeCount = abilities.length - readCount;\n\n\tconst isAbilityEnabled = (a) => {\n\t\tif (!settings.enable_abilities) return false;\n\t\tif (!a.readonly && !settings.allow_modifications) return false;\n\t\treturn !settings.disabled_abilities.includes(a.name);\n\t};\n\n\tconst enabledCount = useMemo(\n\t\t() => abilities.filter(isAbilityEnabled).length,\n\t\t[abilities, settings.enable_abilities, settings.allow_modifications, settings.disabled_abilities]\n\t);\n\n\tconst isGroupOn = (ns) => (groupedAbilities[ns] || []).every(a => !settings.disabled_abilities.includes(a.name));\n\n\tconst groupEnabledCount = (list) => list.filter(a => !settings.disabled_abilities.includes(a.name)).length;\n\n\t// ── Save ──\n\t// Serialize saves: chain each POST after the previous one settles so rapid\n\t// toggles commit in the order the user made them, not the order the network\n\t// happens to complete them (which could let a stale write land last).\n\tconst saveChainRef = useRef(Promise.resolve());\n\n\t// Last state the server actually confirmed. The optimistic UI is reverted to\n\t// this when a save fails, so the toggles never drift from what is persisted.\n\tconst lastSavedRef = useRef(settings);\n\n\t// Monotonic id for each queued save. A failed save only rolls the UI back if\n\t// no newer change was queued after it; otherwise that pending save reconciles.\n\tconst saveSeqRef = useRef(0);\n\n\tconst doSave = async (data, seq) => {\n\t\tsetSaving(true);\n\t\ttry {\n\t\t\tconst res = await apiFetch({\n\t\t\t\tpath: '/uael/v1/mcp-settings',\n\t\t\t\tmethod: 'POST',\n\t\t\t\theaders: { 'Content-Type': 'application/json', 'X-WP-Nonce': uaelSettingsData.uael_nonce_action },\n\t\t\t\tbody: JSON.stringify(data),\n\t\t\t});\n\t\t\tif (!res || !res.success) {\n\t\t\t\tthrow new Error(res && res.message ? res.message : 'save_failed');\n\t\t\t}\n\t\t\tlastSavedRef.current = data;\n\t\t\ttoast.success(__('Settings saved.', 'uael'));\n\t\t} catch (e) {\n\t\t\t// Surface the failure and undo the optimistic change so the UI matches\n\t\t\t// the server. Skip the revert if a newer save is already queued — it\n\t\t\t// carries the cumulative state and will land the correct values.\n\t\t\tif (seq === saveSeqRef.current) {\n\t\t\t\t// Clone so the reference differs from the current state object,\n\t\t\t\t// otherwise React bails out of the re-render and the failed\n\t\t\t\t// toggle would not visually revert.\n\t\t\t\tconst restored = { ...lastSavedRef.current };\n\t\t\t\tsettingsRef.current = restored;\n\t\t\t\tsetSettings(restored);\n\t\t\t}\n\t\t\ttoast.error(__('Failed to save settings.', 'uael'));\n\t\t} finally {\n\t\t\tsetSaving(false);\n\t\t}\n\t};\n\n\tconst saveSettings = (data) => {\n\t\tconst seq = ++saveSeqRef.current;\n\t\tsaveChainRef.current = saveChainRef.current.then(\n\t\t\t() => doSave(data, seq),\n\t\t\t() => doSave(data, seq)\n\t\t);\n\t\treturn saveChainRef.current;\n\t};\n\n\tconst handleToggle = (key, value) => {\n\t\tconst updated = { ...settingsRef.current, [key]: value };\n\t\tsettingsRef.current = updated;\n\t\tsetSettings(updated);\n\t\tsaveSettings(updated);\n\t};\n\n\tconst handleGroupToggle = (ns, enabled) => {\n\t\tconst groupNames = (groupedAbilities[ns] || []).map(a => a.name);\n\t\tlet disabled = [...settingsRef.current.disabled_abilities];\n\t\tif (enabled) {\n\t\t\tdisabled = disabled.filter(n => !groupNames.includes(n));\n\t\t} else {\n\t\t\tgroupNames.forEach(n => { if (!disabled.includes(n)) disabled.push(n); });\n\t\t}\n\t\tconst updated = { ...settingsRef.current, disabled_abilities: disabled };\n\t\tsettingsRef.current = updated;\n\t\tsetSettings(updated);\n\t\tsaveSettings(updated);\n\t};\n\n\tconst handleAbilityToggle = (name, enabled) => {\n\t\tlet disabled = [...settingsRef.current.disabled_abilities];\n\t\tif (enabled) disabled = disabled.filter(n => n !== name);\n\t\telse if (!disabled.includes(name)) disabled.push(name);\n\t\tconst updated = { ...settingsRef.current, disabled_abilities: disabled };\n\t\tsettingsRef.current = updated;\n\t\tsetSettings(updated);\n\t\tsaveSettings(updated);\n\t};\n\n\tconst handleResetDefaults = () => {\n\t\tconst defaults = {\n\t\t\tenable_abilities: false,\n\t\t\tallow_modifications: true,\n\t\t\tdedicated_server: false,\n\t\t\tangie_enabled: false,\n\t\t\tdisabled_abilities: [],\n\t\t};\n\t\tsettingsRef.current = defaults;\n\t\tsetSettings(defaults);\n\t\tsaveSettings(defaults);\n\t\tsetPageTab('overview');\n\t};\n\n\t// ── Connect snippet ──\n\tconst siteHostname = useMemo(() => {\n\t\ttry { return new URL(restUrl).hostname.replace(/[^a-zA-Z0-9-]/g, '-'); }\n\t\tcatch (e) { return 'site'; }\n\t}, [restUrl]);\n\n\tconst isUaeOnly = scopeTab === 'uae-only';\n\tconst serverName = isUaeOnly ? `${siteHostname}-uae` : `${siteHostname}-global`;\n\tconst serverUrl = isUaeOnly ? `${restUrl}uae/mcp` : `${restUrl}mcp/mcp-adapter-default-server`;\n\tconst mcpServerEntry = {\n\t\tcommand: 'npx',\n\t\targs: ['-y', '@automattic/mcp-wordpress-remote@latest'],\n\t\tenv: { WP_API_URL: serverUrl, WP_API_USERNAME: currentUser, WP_API_PASSWORD: 'your-application-password' },\n\t};\n\tconst mcpConfig = JSON.stringify({ mcpServers: { [serverName]: mcpServerEntry } }, null, 2);\n\tconst serverEntryJson = JSON.stringify({ [serverName]: mcpServerEntry }, null, 2);\n\n\tconst aiPrompt = `Add this MCP server to my AI client so I can connect to my WordPress site:\n${serverEntryJson}\n\nSteps:\n1. Ask which AI client I use if unsure (Claude Code, Claude Desktop, Cursor, Windsurf, VS Code, ChatGPT, etc.) and what OS I'm on (macOS, Windows, Linux) — both are needed to locate the correct config file.\n\n2. Ask for my Application Password upfront (before proceeding to any other steps). The placeholder in the JSON above says \"your-application-password\" — replace it with what I provide. If I don't have one, direct me to:\n   ${appPasswordUrl}\n\n3. If using ChatGPT:\n   Go to Settings → Connectors → Add Connector and paste this URL as the Connector URL:\n   ${serverUrl}\n\n   Use HTTP Basic Auth with my WordPress username and an Application Password.\n\n   If I don't have an Application Password, direct me to:\n   ${appPasswordUrl}\n\n   See also:\n   https://developers.openai.com/apps-sdk/deploy/connect-chatgpt\n\n   Skip steps 4–8.\n\n4. Locate the correct MCP config file for my client and OS. Verify the path exists on my system — do not guess. If it doesn't exist, confirm the path with me before creating.\n\n5. Merge into existing config if present — do NOT overwrite other MCP server entries. For VS Code, use \"servers\" key instead of \"mcpServers\".\n\n6. Detect my Node.js setup by running:\n   which npx && node --version && echo $PATH\n\n   - If you can run terminal commands directly (e.g. Claude Code, Cursor, Windsurf, VS Code agent), run this yourself.\n   - If you are sandboxed and cannot run terminal commands (e.g. Claude Desktop, ChatGPT), ask me to run it and paste the output back.\n   - Requires Node.js v20 or v22. If below v20 or v23+, warn me and stop.\n   - Set \"command\" to the full npx path from \"which npx\" — never use a path from your own environment.\n   - Add \"PATH\" to \"env\" using the actual $PATH output — include the node bin directory, Homebrew paths (/opt/homebrew/bin, /usr/local/bin), and system paths.\n   - MCP servers don't inherit the user's shell PATH, so include everything needed for node, npx, and git.\n\n7. If you're sandboxed (e.g. Claude Desktop) and can't write to the real filesystem, don't write to a sandbox path. Instead, output the final JSON in a code block with the file path so I can save it manually.\n\n8. Verify the final JSON is valid and confirm what was added.`;\n\n\tconst handleCopyConfig = () => {\n\t\tnavigator.clipboard.writeText(mcpConfig).then(() => {\n\t\t\tsetCopied(true);\n\t\t\ttoast.success(__('Copied to clipboard', 'uael'));\n\t\t\tsetTimeout(() => setCopied(false), 2000);\n\t\t});\n\t};\n\tconst handleCopyEndpoint = () => {\n\t\tnavigator.clipboard.writeText(serverUrl).then(() => {\n\t\t\ttoast.success(__('Endpoint copied to clipboard', 'uael'));\n\t\t});\n\t};\n\tconst handleCopyPrompt = () => {\n\t\tnavigator.clipboard.writeText(aiPrompt).then(() => {\n\t\t\tsetPromptCopied(true);\n\t\t\ttoast.success(__('Prompt copied! Paste it into your AI client.', 'uael'));\n\t\t\tsetTimeout(() => setPromptCopied(false), 2000);\n\t\t});\n\t};\n\n\t// ── Ability search/filter ──\n\tconst matchesFilter = (a) => {\n\t\tif (filterMode === 'read' && !a.readonly) return false;\n\t\tif (filterMode === 'write' && a.readonly) return false;\n\t\tif (searchQuery) {\n\t\t\tconst q = searchQuery.toLowerCase();\n\t\t\treturn (a.label || '').toLowerCase().includes(q) || (a.description || '').toLowerCase().includes(q) || a.name.toLowerCase().includes(q);\n\t\t}\n\t\treturn true;\n\t};\n\n\tconst expandAll = () => {\n\t\tconst allKeys = Object.keys(groupedAbilities);\n\t\tconst allOpen = allKeys.every(k => expandedGroups[k]);\n\t\tsetExpandedGroups(allOpen ? {} : Object.fromEntries(allKeys.map(k => [k, true])));\n\t};\n\n\t// ── Hard empty state — the Abilities API itself is unavailable ──\n\tif (!isAbilitiesApiActive) {\n\t\treturn (\n\t\t\t<div className=\"uae-ai-tools uae-ai-empty\">\n\t\t\t\t<Title description=\"\" icon={null} iconPosition=\"right\" size=\"sm\" tag=\"h2\" title={__('AI Tools', 'uael')} />\n\t\t\t\t<div className=\"uae-ai-empty-note text-sm\">\n\t\t\t\t\t<strong className=\"uae-ai-c-ink\">{__('Requires WordPress 6.8+', 'uael')}</strong>{' '}\n\t\t\t\t\t{__('AI Tools requires WordPress 6.8 or later, which includes the Abilities API.', 'uael')}\n\t\t\t\t</div>\n\t\t\t\t<Toaster position=\"top-right\" />\n\t\t\t</div>\n\t\t);\n\t}\n\n\tconst enabled = settings.enable_abilities;\n\tconst mcpOn = enabled && settings.dedicated_server;\n\tconst editOn = enabled && settings.allow_modifications;\n\tconst angieOn = enabled && settings.angie_enabled && isAngieActive;\n\n\tconst progressPct = abilities.length ? Math.round((enabledCount / abilities.length) * 100) : 0;\n\n\t// ── Render ──\n\treturn (\n\t\t<div className=\"uae-ai-tools\">\n\n\t\t\t{/* Page header */}\n\t\t\t<div className=\"uae-ai-header\">\n\t\t\t\t<div>\n\t\t\t\t\t<Title description=\"\" icon={null} iconPosition=\"right\" size=\"sm\" tag=\"h2\" title={__('AI Tools', 'uael')} />\n\t\t\t\t\t<div className=\"uae-ai-badges\">\n\t\t\t\t\t\t{enabled\n\t\t\t\t\t\t\t? <HeaderBadge tone=\"ok\" dot>{__('Abilities enabled', 'uael')}</HeaderBadge>\n\t\t\t\t\t\t\t: <HeaderBadge tone=\"neutral\" dot>{__('Abilities disabled', 'uael')}</HeaderBadge>}\n\t\t\t\t\t\t<HeaderBadge tone=\"neutral\" dot dotClass={enabled ? 'is-blue' : 'is-grey'}>\n\t\t\t\t\t\t\t{sprintf(__('%1$d / %2$d abilities', 'uael'), enabled ? enabledCount : 0, abilities.length || 0)}\n\t\t\t\t\t\t</HeaderBadge>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<button\n\t\t\t\t\tonClick={handleResetDefaults}\n\t\t\t\t\tdisabled={false}\n\t\t\t\t\tclassName=\"uae-ai-reset text-xs font-medium\"\n\t\t\t\t>\n\t\t\t\t\t<RotateCw size={14} />\n\t\t\t\t\t{__('Reset to defaults', 'uael')}\n\t\t\t\t</button>\n\t\t\t</div>\n\n\t\t\t{/* Settings card with 4 toggles */}\n\t\t\t<Card>\n\t\t\t\t<CardHead\n\t\t\t\t\ttitle={__('Settings', 'uael')}\n\t\t\t\t\tdescription={__('Control how UAE registers AI tools with WordPress and exposes them to clients.', 'uael')}\n\t\t\t\t/>\n\t\t\t\t<div>\n\t\t\t\t\t{/* Master toggle */}\n\t\t\t\t\t<ToggleRow\n\t\t\t\t\t\temphasized\n\t\t\t\t\t\ticon={<Sun size={18} />}\n\t\t\t\t\t\ttitle={__('Enable Abilities', 'uael')}\n\t\t\t\t\t\tdescription={__(\"Register UAE AI tools with WordPress so they can be used by MCP clients (such as Claude, Cursor, and VS Code) and Elementor's Angie assistant. Disabled by default — enable this option to expose AI tools.\", 'uael')}\n\t\t\t\t\t\tvalue={settings.enable_abilities}\n\t\t\t\t\t\tonChange={(v) => handleToggle('enable_abilities', v)}\n\t\t\t\t\t/>\n\n\t\t\t\t\t<ToggleRow\n\t\t\t\t\t\ticon={<FilePenLine size={18} />}\n\t\t\t\t\t\ttitle={__('Enable Edit Abilities', 'uael')}\n\t\t\t\t\t\ttag=\"write\"\n\t\t\t\t\t\tlocked={!enabled}\n\t\t\t\t\t\tdescription={__('When enabled, AI clients can create, edit, and delete templates, pages, and widget settings. When disabled, AI clients have read-only access to your data.', 'uael')}\n\t\t\t\t\t\tvalue={settings.allow_modifications}\n\t\t\t\t\t\tonChange={(v) => handleToggle('allow_modifications', v)}\n\t\t\t\t\t\tdisabled={!enabled}\n\t\t\t\t\t/>\n\n\t\t\t\t\t<ToggleRow\n\t\t\t\t\t\ticon={<Server size={18} />}\n\t\t\t\t\t\ttitle={__('Enable MCP Server', 'uael')}\n\t\t\t\t\t\tlocked={!enabled}\n\t\t\t\t\t\tdescription={__('Creates a dedicated UAE MCP endpoint that AI clients like Claude, Cursor, and VS Code can connect to. When disabled, the endpoint is removed and external AI clients cannot discover or call any UAE abilities.', 'uael')}\n\t\t\t\t\t\tvalue={settings.dedicated_server}\n\t\t\t\t\t\tonChange={(v) => handleToggle('dedicated_server', v)}\n\t\t\t\t\t\tdisabled={!enabled}\n\t\t\t\t\t/>\n\n\t\t\t\t\t<ToggleRow\n\t\t\t\t\t\ticon={<Clock size={18} />}\n\t\t\t\t\t\ttitle={__('Angie Integration', 'uael')}\n\t\t\t\t\t\tlocked={!enabled || !isAngieActive}\n\t\t\t\t\t\tdescription={isAngieActive\n\t\t\t\t\t\t\t? __(\"Enable UAE abilities within Elementor's Angie AI assistant so it can use them in-browser without an external MCP client.\", 'uael')\n\t\t\t\t\t\t\t: __('Install and activate the Angie plugin to use in-browser AI.', 'uael')}\n\t\t\t\t\t\tvalue={settings.angie_enabled && isAngieActive}\n\t\t\t\t\t\tonChange={(v) => handleToggle('angie_enabled', v)}\n\t\t\t\t\t\tdisabled={!enabled || !isAngieActive}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t</Card>\n\n\t\t\t{/* Tabs + panels — only when master is on */}\n\t\t\t{enabled && (\n\t\t\t\t<>\n\t\t\t\t\t<div className=\"uae-ai-tabs\">\n\t\t\t\t\t\t<TabButton active={pageTab === 'overview'} onClick={() => setPageTab('overview')}>\n\t\t\t\t\t\t\t{__('Overview', 'uael')}\n\t\t\t\t\t\t</TabButton>\n\t\t\t\t\t\t<TabButton active={pageTab === 'abilities'} onClick={() => setPageTab('abilities')}>\n\t\t\t\t\t\t\t{__('Abilities', 'uael')}\n\t\t\t\t\t\t\t<span className={`uae-ai-tab-count text-xxs font-semibold ${pageTab === 'abilities' ? 'is-active' : ''}`}>\n\t\t\t\t\t\t\t\t{abilities.length}\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</TabButton>\n\t\t\t\t\t\t{mcpOn && (\n\t\t\t\t\t\t\t<TabButton active={pageTab === 'server'} onClick={() => setPageTab('server')}>\n\t\t\t\t\t\t\t\t{__('Server & Connect', 'uael')}\n\t\t\t\t\t\t\t</TabButton>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</div>\n\n\t\t\t\t\t{/* Overview */}\n\t\t\t\t\t{pageTab === 'overview' && (\n\t\t\t\t\t\t<Card>\n\t\t\t\t\t\t\t<CardHead title={__('Connection status', 'uael')} description={__('How AI clients reach your site right now', 'uael')} />\n\n\t\t\t\t\t\t\t{/* System status banner */}\n\t\t\t\t\t\t\t<div className={`uae-ai-connbanner ${enabled ? 'is-active' : 'is-off'}`}>\n\t\t\t\t\t\t\t\t<span className=\"uae-ai-connbanner-dot\" />\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-connbanner-main\">\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-connbanner-title text-sm font-semibold\">\n\t\t\t\t\t\t\t\t\t\t{enabled\n\t\t\t\t\t\t\t\t\t\t\t? __('AI Tools are active', 'uael')\n\t\t\t\t\t\t\t\t\t\t\t: __('AI Tools are off', 'uael')}\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-connbanner-sub text-xs\">\n\t\t\t\t\t\t\t\t\t\t{enabled\n\t\t\t\t\t\t\t\t\t\t\t? sprintf(\n\t\t\t\t\t\t\t\t\t\t\t\t/* translators: 1: MCP server state, 2: access mode, 3: enabled count, 4: total */\n\t\t\t\t\t\t\t\t\t\t\t\t__('%1$s · %2$s · %3$d of %4$d abilities exposed', 'uael'),\n\t\t\t\t\t\t\t\t\t\t\t\tmcpOn ? __('MCP server on', 'uael') : __('MCP server off', 'uael'),\n\t\t\t\t\t\t\t\t\t\t\t\teditOn ? __('Read & write', 'uael') : __('Read-only', 'uael'),\n\t\t\t\t\t\t\t\t\t\t\t\tenabledCount,\n\t\t\t\t\t\t\t\t\t\t\t\tabilities.length\n\t\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t\t\t: __('Enable “Enable Abilities” above to connect AI clients.', 'uael')}\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t{/* Status cards */}\n\t\t\t\t\t\t\t<div className=\"uae-ai-conngrid\">\n\t\t\t\t\t\t\t\t{/* External MCP server */}\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard\">\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-head\">\n\t\t\t\t\t\t\t\t\t\t<span className=\"uae-ai-conncard-title text-sm font-semibold\">{__('External MCP server', 'uael')}</span>\n\t\t\t\t\t\t\t\t\t\t<span className={`uae-ai-pill ${mcpOn ? 'is-ok' : 'is-muted'}`}>{mcpOn ? __('Ready', 'uael') : __('Server off', 'uael')}</span>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t{mcpOn ? (\n\t\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-endpoint\">\n\t\t\t\t\t\t\t\t\t\t\t\t<span className=\"is-mono text-xs\">{serverUrl}</span>\n\t\t\t\t\t\t\t\t\t\t\t\t<button onClick={handleCopyEndpoint} className=\"uae-ai-iconbtn\" aria-label={__('Copy endpoint', 'uael')}>\n\t\t\t\t\t\t\t\t\t\t\t\t\t<Copy size={13} />\n\t\t\t\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t<button onClick={() => setPageTab('server')} className=\"uae-ai-connlink text-xs font-medium\">\n\t\t\t\t\t\t\t\t\t\t\t\t{__('Connect a client', 'uael')} <ChevronRight size={13} />\n\t\t\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-hint text-xs\">{__('Turn on Enable MCP Server above to expose the endpoint.', 'uael')}</div>\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t\t{/* Angie (in-editor) */}\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard\">\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-head\">\n\t\t\t\t\t\t\t\t\t\t<span className=\"uae-ai-conncard-title text-sm font-semibold\">{__('Angie (in-editor)', 'uael')}</span>\n\t\t\t\t\t\t\t\t\t\t<span className={`uae-ai-pill ${angieOn ? 'is-ok' : 'is-muted'}`}>\n\t\t\t\t\t\t\t\t\t\t\t{isAngieActive ? (angieOn ? __('Enabled', 'uael') : __('Disabled', 'uael')) : __('Not installed', 'uael')}\n\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-hint text-xs\">\n\t\t\t\t\t\t\t\t\t\t{isAngieActive\n\t\t\t\t\t\t\t\t\t\t\t? (angieOn\n\t\t\t\t\t\t\t\t\t\t\t\t? __('UAE tools are available in Elementor’s in-browser AI.', 'uael')\n\t\t\t\t\t\t\t\t\t\t\t\t: __('Turn on Angie Integration above to use it in the editor.', 'uael'))\n\t\t\t\t\t\t\t\t\t\t\t: __('Install the Angie plugin to use in-browser AI.', 'uael')}\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t\t{/* Abilities exposed */}\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard\">\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-head\">\n\t\t\t\t\t\t\t\t\t\t<span className=\"uae-ai-conncard-title text-sm font-semibold\">{__('Abilities exposed', 'uael')}</span>\n\t\t\t\t\t\t\t\t\t\t<span className=\"uae-ai-conncard-count text-sm font-bold\">{enabled ? enabledCount : 0}<span className=\"uae-ai-c-muted text-xs font-medium\"> / {abilities.length}</span></span>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-progress-track\" style={{ marginBottom: '10px' }}>\n\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-progress-bar\" style={{ width: `${enabled ? progressPct : 0}%` }} />\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<button onClick={() => setPageTab('abilities')} className=\"uae-ai-connlink text-xs font-medium\">\n\t\t\t\t\t\t\t\t\t\t{__('Manage abilities', 'uael')} <ChevronRight size={13} />\n\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t\t{/* Access mode */}\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard\">\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-head\">\n\t\t\t\t\t\t\t\t\t\t<span className=\"uae-ai-conncard-title text-sm font-semibold\">{__('Access mode', 'uael')}</span>\n\t\t\t\t\t\t\t\t\t\t<span className={`uae-ai-pill ${editOn ? 'is-brand' : 'is-muted'}`}>{editOn ? __('Read & write', 'uael') : __('Read-only', 'uael')}</span>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-conncard-hint text-xs\">\n\t\t\t\t\t\t\t\t\t\t{editOn\n\t\t\t\t\t\t\t\t\t\t\t? __('AI can create, edit and delete. Toggle “Enable Edit Abilities” above for read-only.', 'uael')\n\t\t\t\t\t\t\t\t\t\t\t: __('AI can only read your data. Toggle “Enable Edit Abilities” above to allow changes.', 'uael')}\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t{/* Quick actions */}\n\t\t\t\t\t\t\t{enabled && (\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-connactions\">\n\t\t\t\t\t\t\t\t\t<a href={appPasswordUrl} target=\"_blank\" rel=\"noreferrer\" className=\"uae-ai-connbtn text-xs font-medium\">\n\t\t\t\t\t\t\t\t\t\t<ExternalLink size={13} /> {__('Create application password', 'uael')}\n\t\t\t\t\t\t\t\t\t</a>\n\t\t\t\t\t\t\t\t\t{mcpOn && (\n\t\t\t\t\t\t\t\t\t\t<button onClick={() => setPageTab('server')} className=\"uae-ai-connbtn text-xs font-medium\">\n\t\t\t\t\t\t\t\t\t\t\t<Server size={13} /> {__('Server & connect', 'uael')}\n\t\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t</Card>\n\t\t\t\t\t)}\n\n\t\t\t\t\t{/* Abilities */}\n\t\t\t\t\t{pageTab === 'abilities' && (\n\t\t\t\t\t\t<Card>\n\t\t\t\t\t\t\t<CardHead\n\t\t\t\t\t\t\t\ttitle={__('Ability toggles', 'uael')}\n\t\t\t\t\t\t\t\tdescription={__('Choose exactly which actions AI tools are allowed to perform', 'uael')}\n\t\t\t\t\t\t\t\tright={<Chip tone=\"ok\">{sprintf(__('%1$d of %2$d enabled', 'uael'), enabledCount, abilities.length)}</Chip>}\n\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t{/* Search + filters */}\n\t\t\t\t\t\t\t<div className=\"uae-ai-toolbar\">\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-search\">\n\t\t\t\t\t\t\t\t\t<Search size={14} className=\"uae-ai-c-muted\" />\n\t\t\t\t\t\t\t\t\t<input\n\t\t\t\t\t\t\t\t\t\tvalue={searchQuery}\n\t\t\t\t\t\t\t\t\t\tonChange={(e) => setSearchQuery(e.target.value)}\n\t\t\t\t\t\t\t\t\t\taria-label={__('Search abilities', 'uael')}\n\t\t\t\t\t\t\t\t\t\tplaceholder={__('Search abilities - e.g. widget, page, skin …', 'uael')}\n\t\t\t\t\t\t\t\t\t\tclassName=\"uae-ai-search-input text-sm\"\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-filters\">\n\t\t\t\t\t\t\t\t\t<FilterChip active={filterMode === 'all'} onClick={() => setFilterMode('all')} count={abilities.length}>{__('All', 'uael')}</FilterChip>\n\t\t\t\t\t\t\t\t\t<FilterChip active={filterMode === 'read'} onClick={() => setFilterMode('read')} count={readCount}>{__('Read', 'uael')}</FilterChip>\n\t\t\t\t\t\t\t\t\t<FilterChip active={filterMode === 'write'} onClick={() => setFilterMode('write')} count={writeCount}>{__('Write', 'uael')}</FilterChip>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\tonClick={expandAll}\n\t\t\t\t\t\t\t\t\tclassName=\"uae-ai-expand text-sm font-medium\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t{Object.keys(groupedAbilities).every(k => expandedGroups[k])\n\t\t\t\t\t\t\t\t\t\t? __('Collapse all', 'uael')\n\t\t\t\t\t\t\t\t\t\t: __('Expand all', 'uael')}\n\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t{/* Groups */}\n\t\t\t\t\t\t\t{Object.entries(groupedAbilities).map(([ns, list]) => {\n\t\t\t\t\t\t\t\tconst filtered = list.filter(matchesFilter);\n\t\t\t\t\t\t\t\tif (filtered.length === 0) return null;\n\t\t\t\t\t\t\t\tconst isOpen = !!expandedGroups[ns];\n\t\t\t\t\t\t\t\tconst onCount = groupEnabledCount(list);\n\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t<div key={ns} className=\"uae-ai-group\">\n\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-group-head\">\n\t\t\t\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\t\t\t\t\tclassName=\"uae-ai-group-toggle\"\n\t\t\t\t\t\t\t\t\t\t\t\taria-expanded={isOpen}\n\t\t\t\t\t\t\t\t\t\t\t\taria-controls={`uae-ai-group-${ns}`}\n\t\t\t\t\t\t\t\t\t\t\t\tonClick={() => setExpandedGroups(p => ({ ...p, [ns]: !p[ns] }))}\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<ChevronRight size={12} className={`uae-ai-group-chevron ${isOpen ? 'is-open' : ''}`} />\n\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-group-letter text-xs font-bold\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t{(namespaceLabels[ns] || ns).charAt(0)}\n\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-group-info\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-c-ink text-sm font-semibold\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{namespaceLabels[ns] || ns}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<span className=\"uae-ai-c-muted text-xs font-medium\" style={{ marginLeft: 6 }}>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{sprintf(__('%d abilities', 'uael'), list.length)}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t{namespaceDescriptions[ns] && (\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-c-muted text-xs\">{namespaceDescriptions[ns]}</div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t<Chip tone={onCount === list.length ? 'ok' : 'muted'}>\n\t\t\t\t\t\t\t\t\t\t\t\t\t{onCount}/{list.length} {__('on', 'uael')}\n\t\t\t\t\t\t\t\t\t\t\t\t</Chip>\n\t\t\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t\t\t\t<Switch\n\t\t\t\t\t\t\t\t\t\t\t\tsize=\"sm\"\n\t\t\t\t\t\t\t\t\t\t\t\tvalue={isGroupOn(ns)}\n\t\t\t\t\t\t\t\t\t\t\t\tonChange={(v) => handleGroupToggle(ns, v)}\n\t\t\t\t\t\t\t\t\t\t\t\tdisabled={false}\n\t\t\t\t\t\t\t\t\t\t\t\taria-label={sprintf(__('Toggle all %s abilities', 'uael'), namespaceLabels[ns] || ns)}\n\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t{isOpen && (\n\t\t\t\t\t\t\t\t\t\t\t<div id={`uae-ai-group-${ns}`}>\n\t\t\t\t\t\t\t\t\t\t\t\t{filtered.map((ability) => (\n\t\t\t\t\t\t\t\t\t\t\t\t\t<div key={ability.name} className=\"uae-ai-arow\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-arow-title uae-ai-c-ink text-sm font-semibold\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{ability.label || ability.name}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<TypeTag readonly={ability.readonly} />\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-c-muted text-xs\">{ability.description}</div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<span />\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t<Switch\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tsize=\"sm\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tvalue={isAbilityEnabled(ability)}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tonChange={(v) => handleAbilityToggle(ability.name, v)}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tdisabled={!ability.readonly && !settings.allow_modifications}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\taria-label={sprintf(__('Toggle %s', 'uael'), ability.label || ability.name)}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t})}\n\t\t\t\t\t\t</Card>\n\t\t\t\t\t)}\n\n\t\t\t\t\t{/* Server & Connect — the WP MCP Adapter plugin powers the live endpoint.\n\t\t\t\t\t    The connect flow is always shown so users understand the setup; when the\n\t\t\t\t\t    adapter is missing we surface a notice above it. */}\n\t\t\t\t\t{pageTab === 'server' && mcpOn && (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t{!isMcpAdapterActive && <McpAdapterNotice />}\n\t\t\t\t\t\t\t<Card>\n\t\t\t\t\t\t\t\t<CardHead\n\t\t\t\t\t\t\t\t\ttitle={__('Connect your AI client', 'uael')}\n\t\t\t\t\t\t\t\t\tdescription={isMcpAdapterActive\n\t\t\t\t\t\t\t\t\t\t? __(\"UAE's MCP endpoint is live. Wire it into your AI tool below.\", 'uael')\n\t\t\t\t\t\t\t\t\t\t: __('Once the WP MCP Adapter plugin is active, this is how you connect your AI client.', 'uael')}\n\t\t\t\t\t\t\t\t\tright={isMcpAdapterActive\n\t\t\t\t\t\t\t\t\t\t? <Chip tone=\"ok\">{__('Endpoint live', 'uael')}</Chip>\n\t\t\t\t\t\t\t\t\t\t: <Chip tone=\"muted\">{__('Setup required', 'uael')}</Chip>}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-panel\">\n\t\t\t\t\t\t\t\t<ol className=\"uae-ai-steps text-sm\">\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t{__('Create an Application Password', 'uael')}\n\t\t\t\t\t\t\t\t\t\t{' — '}\n\t\t\t\t\t\t\t\t\t\t<a href={appPasswordUrl} target=\"_blank\" rel=\"noopener noreferrer\" className=\"uae-ai-link\">\n\t\t\t\t\t\t\t\t\t\t\t{__('Open Application Passwords', 'uael')}\n\t\t\t\t\t\t\t\t\t\t\t<ExternalLink size={13} />\n\t\t\t\t\t\t\t\t\t\t</a>\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t{__('Add to your AI client:', 'uael')}{' '}\n\t\t\t\t\t\t\t\t\t\t<a href=\"https://developer.wordpress.org/news/2026/02/from-abilities-to-ai-agents-introducing-the-wordpress-mcp-adapter/\" target=\"_blank\" rel=\"noopener noreferrer\" className=\"uae-ai-link\">\n\t\t\t\t\t\t\t\t\t\t\t{__('Learn More', 'uael')}\n\t\t\t\t\t\t\t\t\t\t\t<ExternalLink size={13} />\n\t\t\t\t\t\t\t\t\t\t</a>\n\t\t\t\t\t\t\t\t\t\t<ul className=\"uae-ai-substeps\">\n\t\t\t\t\t\t\t\t\t\t\t<li><strong>{__('Claude Code', 'uael')}</strong>: <code className=\"uae-ai-inlinecode text-xs\">.mcp.json</code></li>\n\t\t\t\t\t\t\t\t\t\t\t<li><strong>{__('Claude Desktop', 'uael')}</strong>: <code className=\"uae-ai-inlinecode text-xs\">claude_desktop_config.json</code></li>\n\t\t\t\t\t\t\t\t\t\t\t<li><strong>{__('Cursor', 'uael')}</strong>: <code className=\"uae-ai-inlinecode text-xs\">.cursor/mcp.json</code></li>\n\t\t\t\t\t\t\t\t\t\t\t<li><strong>{__('VS Code', 'uael')}</strong>: <code className=\"uae-ai-inlinecode text-xs\">.vscode/mcp.json</code></li>\n\t\t\t\t\t\t\t\t\t\t\t<li><strong>{__('ChatGPT', 'uael')}</strong>: {__('go to Settings → Connectors → Add Connector, paste the endpoint URL, and use your WordPress username + Application Password.', 'uael')}</li>\n\t\t\t\t\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t\t<li>\n\t\t\t\t\t\t\t\t\t\t{__('Replace', 'uael')} <code className=\"uae-ai-inlinecode text-xs\">\"your-application-password\"</code> {__('in the JSON with the password from Step 1.', 'uael')}\n\t\t\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t\t</ol>\n\n\t\t\t\t\t\t\t\t{/* UAE Only / Global */}\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-scope\">\n\t\t\t\t\t\t\t\t\t<ScopeBtn active={scopeTab === 'uae-only'} onClick={() => setScopeTab('uae-only')}>{__('UAE Only', 'uael')}</ScopeBtn>\n\t\t\t\t\t\t\t\t\t<ScopeBtn active={scopeTab === 'global'} onClick={() => setScopeTab('global')}>{__('Global', 'uael')}</ScopeBtn>\n\t\t\t\t\t\t\t\t</div>\n\n\t\t\t\t\t\t\t\t{/* Code block */}\n\t\t\t\t\t\t\t\t<div className=\"uae-ai-code\">\n\t\t\t\t\t\t\t\t\t<div className=\"uae-ai-code-actions\">\n\t\t\t\t\t\t\t\t\t\t<Tooltip content={__('Copy setup prompt for AI client', 'uael')} delay={50} arrow>\n\t\t\t\t\t\t\t\t\t\t\t<button onClick={handleCopyPrompt} className=\"uae-ai-iconbtn\" aria-label={__('Copy setup prompt', 'uael')}>\n\t\t\t\t\t\t\t\t\t\t\t\t{promptCopied ? <Check size={14} color=\"#95E1A0\" /> : <Sparkles size={14} />}\n\t\t\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t\t\t</Tooltip>\n\t\t\t\t\t\t\t\t\t\t<Tooltip content={__('Copy JSON config', 'uael')} delay={50} arrow>\n\t\t\t\t\t\t\t\t\t\t\t<button onClick={handleCopyConfig} className=\"uae-ai-iconbtn\" aria-label={__('Copy JSON config', 'uael')}>\n\t\t\t\t\t\t\t\t\t\t\t\t{copied ? <Check size={14} color=\"#95E1A0\" /> : <Copy size={14} />}\n\t\t\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t\t\t</Tooltip>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<pre className=\"uae-ai-code-pre text-xs\">\n\t\t\t\t\t\t\t\t\t\t{mcpConfig}\n\t\t\t\t\t\t\t\t\t</pre>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</Card>\n\t\t\t\t\t\t</>\n\t\t\t\t\t)}\n\t\t\t\t</>\n\t\t\t)}\n\n\t\t\t<Toaster\n\t\t\t\tposition=\"top-right\" reverseOrder={false} gutter={8}\n\t\t\t\tcontainerStyle={{ top: 20, right: 20, marginTop: 80 }}\n\t\t\t\ttoastOptions={{ duration: 5000, style: { background: 'white' }, success: { duration: 3000, iconTheme: { primary: BRAND, secondary: '#fff' } } }}\n\t\t\t/>\n\t\t</div>\n\t);\n};\n\n// ───────── Sub-components ─────────\n\nconst McpAdapterNotice = () => (\n\t<div className=\"uae-ai-notice\" role=\"status\">\n\t\t<AlertTriangle size={20} className=\"uae-ai-notice-icon\" />\n\t\t<div className=\"uae-ai-notice-main\">\n\t\t\t<div className=\"uae-ai-notice-title uae-ai-c-ink text-base font-semibold\">\n\t\t\t\t{__('MCP Adapter plugin not detected', 'uael')}\n\t\t\t</div>\n\t\t\t<p className=\"uae-ai-notice-body uae-ai-c-ink2 text-sm m-0\">\n\t\t\t\t{__('To connect AI clients to your site, the', 'uael')}{' '}\n\t\t\t\t<a className=\"uae-ai-notice-link\" href={MCP_ADAPTER_GITHUB} target=\"_blank\" rel=\"noopener noreferrer\">\n\t\t\t\t\t{__('WP MCP Adapter', 'uael')}\n\t\t\t\t</a>{' '}\n\t\t\t\t{__('plugin is required. Download the latest release from GitHub, upload it via Plugins > Add New > Upload Plugin, and activate.', 'uael')}\n\t\t\t</p>\n\t\t\t<a className=\"uae-ai-notice-btn text-sm font-semibold\" href={MCP_ADAPTER_DOWNLOAD} target=\"_blank\" rel=\"noopener noreferrer\">\n\t\t\t\t{__('Download from GitHub', 'uael')}\n\t\t\t</a>\n\t\t</div>\n\t</div>\n);\n\nconst ToggleRow = ({ emphasized, icon, title, description, tag, locked, value, onChange, disabled, switchSize = 'sm' }) => (\n\t<div className={`uae-ai-trow ${emphasized ? 'is-emphasized' : ''} ${locked ? 'is-locked' : ''}`}>\n\t\t<div className=\"uae-ai-trow-icon\">\n\t\t\t{icon}\n\t\t</div>\n\t\t<div className=\"uae-ai-trow-body\">\n\t\t\t<div className={`uae-ai-trow-title uae-ai-c-ink font-semibold ${emphasized ? 'text-base' : 'text-sm'}`}>\n\t\t\t\t{title}\n\t\t\t\t{tag === 'write' && <span className=\"uae-ai-tag is-write text-xxs font-semibold\">{__('Write', 'uael')}</span>}\n\t\t\t\t{tag === 'read' && <span className=\"uae-ai-tag is-read text-xxs font-semibold\">{__('Read', 'uael')}</span>}\n\t\t\t\t{locked && <Lock size={12} className=\"uae-ai-c-muted\" />}\n\t\t\t</div>\n\t\t\t<div className=\"uae-ai-trow-desc uae-ai-c-muted text-sm\">\n\t\t\t\t{description}\n\t\t\t</div>\n\t\t</div>\n\t\t<Switch size={switchSize} value={!!value} onChange={onChange} disabled={disabled} aria-label={typeof title === 'string' ? title : undefined} />\n\t</div>\n);\n\nconst TabButton = ({ active, onClick, children }) => (\n\t<button\n\t\tonClick={onClick}\n\t\tclassName={`uae-ai-tab text-sm ${active ? 'is-active font-semibold' : 'font-medium'}`}\n\t>\n\t\t{children}\n\t</button>\n);\n\nconst FilterChip = ({ active, onClick, count, children }) => (\n\t<button\n\t\tonClick={onClick}\n\t\tclassName={`uae-ai-fchip text-xs ${active ? 'is-active' : ''}`}\n\t>\n\t\t{children}\n\t\t<span className=\"uae-ai-fchip-count text-xxs\">{count}</span>\n\t</button>\n);\n\nconst ScopeBtn = ({ active, onClick, children }) => (\n\t<button\n\t\tonClick={onClick}\n\t\tclassName={`uae-ai-scope-btn text-sm ${active ? 'is-active font-semibold' : 'font-medium'}`}\n\t>\n\t\t{children}\n\t</button>\n);\n\nconst TypeTag = ({ readonly }) => (\n\t<span className={`uae-ai-tag text-xxs font-semibold ${readonly ? 'is-read' : 'is-write'}`}>\n\t\t{readonly ? __('Read', 'uael') : __('Write', 'uael')}\n\t</span>\n);\n\nexport default AITools;\n","import React, { useState, useEffect } from 'react'\nimport { Container } from \"@bsf/force-ui\";\nimport Sidebar from './Sidebar';\nimport Content from './Content';\nimport NavMenu from '@components/NavMenu';\nimport HeaderLine from '@components/HeaderLine';\nimport ThemeSupport from './ThemeSupport';\nimport VersionControl from './VersionControl';\nimport MyAccount from './MyAccount';\nimport Integrations from './Integrations';\nimport Branding from './Branding';\nimport PostSkins from './PostSkins';\nimport AITools from './AITools';\nimport { __ } from '@wordpress/i18n';\n\nconst Settings = () => {\n    const items = [\n        {\n            id: 1,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.user_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.user__selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            title: __('My Account', 'uael'),\n            content: <MyAccount />\n        },\n        {\n            id: 2,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.theme_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.theme__selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            main: __('Editor', 'uael'),\n            title: __('Theme Support', 'uael'),\n            content: <ThemeSupport />\n        },\n        {\n            id: 3,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.version_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.version__selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            main: __('Utilities', 'uael'),\n            title:  __('Version Control', 'uael'),\n            content: <VersionControl />\n        },\n        {\n            id: 4,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.branding_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.branding__selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            main: '',\n            title: __('White Label', 'uael'),\n            content: <Branding />\n        },\n        {\n            id: 5,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.integrations_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.integrations__selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            main: __('Preferences', 'uael'),\n            title: __('Integrations', 'uael'),\n            content: <Integrations />\n        },\n        {\n            id: 6,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.postskins_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.postskins_selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            main: __('Skins', 'uael'),\n            title: __('Post Widget Skins', 'uael'),\n            content: <PostSkins />\n        },\n        {\n            id: 7,\n            icon: (\n                <img\n                    src={`${uaelSettingsData.ai_tools_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            selected: (\n                <img\n                    src={`${uaelSettingsData.ai_tools__selected_url}`}\n                    alt=\"Custom SVG\"\n                    className=\"object-contain\"\n                />\n            ),\n            main: __('AI', 'uael'),\n            title: __('AI Tools', 'uael'),\n            badge: __('NEW', 'uael'),\n            content: <AITools />\n        }\n    ].filter(item => {\n        if ( ( 'no' === uaelSettingsData.show_theme_support ) && item.id === 2 ) {\n            return false;\n        }\n\n        if (uaelSettingsData.hide_settings) {\n            return item.id !== 3 && item.id !== 4;\n        }\n\n        return true;\n    });\n\n    // Default state: Set 'My Account' (first item) as the default when the settings tab is clicked\n    const [selectedItem, setSelectedItem] = useState(() => {\n        const savedItemId = localStorage.getItem('selectedItemId');\n        const savedItem = items.find(item => item.id === Number(savedItemId));\n        return savedItem || items[0]; // Default to the first item if no saved item is found\n    });\n\n    useEffect(() => {\n        // Store selectedItemId in localStorage (or other persistent storage) to retain selection\n        localStorage.setItem('selectedItemId', selectedItem.id.toString());\n    }, [selectedItem]);\n\n    useEffect(() => {\n        const params = new URLSearchParams(window.location.search);\n        const tab = params.get('tab');\n        if (tab) {\n            const itemId = Number(tab);\n            const item = items.find(item => item.id === itemId);\n            if (item) {\n                setSelectedItem(item);\n            }\n        }\n    }, []);\n\n    const handleSelectItem = (item) => {\n        setSelectedItem(item);\n    };\n\n    const handleSettingsTabClick = () => {\n        setSelectedItem(items[0]); // Set \"My Account\" as the default item when settings tab is clicked\n    };\n\n    return (\n        <>\n            <NavMenu onSettingsTabClick={handleSettingsTabClick} /> {/* Ensure Settings tab triggers this */}\n            <div>\n                <HeaderLine />\n                <Container align=\"stretch\" className=\"p-1 flex-col lg:flex-row uae-settings-page\" containerType=\"flex\" direction=\"row\" gap=\"sm\" justify=\"start\" style={{ height: \"100%\" }}>\n                    <Container.Item className=\"p-2 uae-sticky-outer-wrapper\" alignSelf=\"auto\" order=\"none\" shrink={1} style={{ backgroundColor: \"#ffffff\" }}>\n                        <div className='uae-sticky-sidebar'>\n                            <Sidebar items={items} onSelectItem={handleSelectItem} selectedItemId={selectedItem.id} />\n                        </div>\n                    </Container.Item>\n                    <Container.Item className=\"p-2 flex w-full justify-center items-start uae-hide-scrollbar\" alignSelf=\"auto\" order=\"none\" shrink={1} style={{ height: \"calc(100vh - 1px)\", overflowY: \"auto\" }}>\n                        <div className=\"uael-78-width\">\n                            <Content selectedItem={selectedItem} />\n                        </div>\n                    </Container.Item>\n                </Container>\n            </div>\n        </>\n    );\n};\n\nexport default Settings;","/**\n * @license lucide-react v0.417.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst Plus = createLucideIcon(\"Plus\", [\n  [\"path\", { d: \"M5 12h14\", key: \"1ays0h\" }],\n  [\"path\", { d: \"M12 5v14\", key: \"s699le\" }]\n]);\n\nexport { Plus as default };\n//# sourceMappingURL=plus.js.map\n","import { cn as n } from \"../../utilities/functions.es.js\";\nconst d = (t, r, e, o) => {\n  const i = `absolute rounded-full transition-colors duration-500 ${e[o].dot}`;\n  return t === \"dot\" ? n(\n    i,\n    e[o].dot,\n    r ? \"bg-brand-primary-600\" : \"bg-text-tertiary\"\n  ) : t === \"number\" ? n(\n    i,\n    e[o].dot,\n    r ? \"text-brand-primary-600\" : \"text-text-tertiary\",\n    \"flex items-center justify-center\"\n  ) : t === \"icon\" ? n(\n    i,\n    r ? \"text-brand-primary-600\" : \"text-text-tertiary\",\n    \"flex items-center justify-center\"\n  ) : \"\";\n}, u = (t, r, e) => n(\n  \"relative flex items-center rounded-full justify-center transition-colors z-10 duration-500 ring-1\",\n  t ? \"ring-brand-primary-600\" : \"ring-border-subtle\",\n  r[e].ring\n), l = (t, r) => n(\n  \"rounded-full text-brand-primary-600 transition-colors duration-300\",\n  t[r].dot,\n  t[r].ring\n);\nexport {\n  l as completedStepCommonClasses,\n  d as getVariantClasses,\n  u as stepWrapperClasses\n};\n//# sourceMappingURL=utils.es.js.map\n","import { jsx as e, jsxs as N, Fragment as P } from \"react/jsx-runtime\";\nimport x from \"react\";\nimport { cn as c } from \"../../utilities/functions.es.js\";\nimport { Check as v, Plus as I } from \"lucide-react\";\nimport { completedStepCommonClasses as j, stepWrapperClasses as L, getVariantClasses as E } from \"./utils.es.js\";\nconst F = {\n  sm: {\n    dot: \"size-2.5\",\n    ring: \"size-5\",\n    numberIcon: \"size-5 text-tiny\",\n    icon: \"size-5\",\n    label: \"text-xs\"\n  },\n  md: {\n    dot: \"size-3\",\n    ring: \"size-6\",\n    numberIcon: \"size-6 text-sm\",\n    icon: \"size-6\",\n    label: \"text-sm\"\n  },\n  lg: {\n    dot: \"size-3.5\",\n    ring: \"size-7\",\n    numberIcon: \"size-7 text-md\",\n    icon: \"size-7\",\n    label: \"text-sm\"\n  }\n}, V = ({\n  variant: r = \"dot\",\n  size: f = \"sm\",\n  type: n = \"inline\",\n  currentStep: t = 1,\n  children: s,\n  className: l,\n  lineClassName: m = \"min-w-10\",\n  completedVariant: d = \"icon\",\n  completedIcon: o = /* @__PURE__ */ e(v, {}),\n  ...b\n}) => {\n  const p = x.Children.count(s);\n  t === -1 && (t = p + 1);\n  const a = x.Children.map(s, (u, i) => {\n    const g = i + 1 < t, h = i + 1 === t, C = i + 1 === p, y = {\n      isCompleted: g,\n      isCurrent: h,\n      sizeClasses: F,\n      size: f,\n      variant: r,\n      type: n,\n      isLast: C,\n      index: i,\n      lineClassName: m,\n      completedVariant: d,\n      completedIcon: o\n    };\n    return /* @__PURE__ */ e(x.Fragment, { children: x.isValidElement(u) ? x.cloneElement(u, y) : u }, i);\n  });\n  return /* @__PURE__ */ e(\n    \"div\",\n    {\n      className: c(\n        \"flex w-full\",\n        l,\n        n === \"inline\" ? \"items-center justify-between\" : \"\"\n      ),\n      ...b,\n      children: a\n    }\n  );\n}, z = ({\n  labelText: r = \"\",\n  icon: f = /* @__PURE__ */ e(I, {}),\n  isCurrent: n,\n  isCompleted: t,\n  className: s,\n  type: l,\n  variant: m,\n  sizeClasses: d,\n  size: o,\n  isLast: b,\n  index: p,\n  lineClassName: a,\n  completedVariant: u = \"icon\",\n  completedIcon: i = /* @__PURE__ */ e(v, {}),\n  ...g\n}) => {\n  const h = O(\n    m,\n    t,\n    n,\n    d,\n    o,\n    f,\n    p,\n    u,\n    i\n  ), C = {\n    lg: \"left-[calc(50%+14px)] right-[calc(-50%+14px)]\",\n    md: \"left-[calc(50%+12px)] right-[calc(-50%+12px)]\",\n    sm: \"left-[calc(50%+10px)] right-[calc(-50%+10px)]\"\n  }, y = {\n    lg: \"top-3.5\",\n    md: \"top-3\",\n    sm: \"top-2.5\"\n  }, w = () => {\n    if (r) {\n      const k = c(\n        d[o].label,\n        \"text-text-tertiary\",\n        n ? \"text-brand-primary-600\" : \"\",\n        \"break-word\",\n        // max width for inline and stack\n        l === \"stack\" ? \"mt-2 transform max-w-xs\" : \"mx-2 max-w-32\"\n      );\n      return /* @__PURE__ */ e(\"span\", { className: k, children: r });\n    }\n    return null;\n  }, S = () => {\n    if (!b) {\n      const k = c(\n        \"block\",\n        t ? \"border-brand-primary-600\" : \"border-border-subtle\",\n        a\n      );\n      return l === \"stack\" ? /* @__PURE__ */ e(\n        \"div\",\n        {\n          className: c(\n            \"relative\",\n            \"flex\",\n            \"border-solid\",\n            \"border-y\",\n            \"absolute\",\n            t ? \"border-brand-primary-600\" : \"border-border-subtle\",\n            y[o],\n            C[o]\n          ),\n          children: /* @__PURE__ */ e(\"span\", { className: \"block\" })\n        }\n      ) : /* @__PURE__ */ e(\"div\", { className: \"flex-1\", children: /* @__PURE__ */ e(\n        \"span\",\n        {\n          className: c(\n            \"mr-2 border-y border-solid\",\n            !r && \"ml-2\",\n            k\n          )\n        }\n      ) });\n    }\n    return null;\n  };\n  return l === \"stack\" ? /* @__PURE__ */ N(\"div\", { className: \"relative flex-1 justify-center\", children: [\n    /* @__PURE__ */ N(\n      \"div\",\n      {\n        className: c(\"flex items-center flex-col\", s),\n        ...g,\n        children: [\n          h,\n          w()\n        ]\n      }\n    ),\n    S()\n  ] }) : /* @__PURE__ */ N(P, { children: [\n    /* @__PURE__ */ N(\"div\", { className: c(\"flex items-center\", s), ...g, children: [\n      h,\n      w()\n    ] }),\n    S()\n  ] });\n};\nz.displayName = \"ProgressSteps.Step\";\nconst O = (r, f, n, t, s, l, m, d = \"icon\", o = /* @__PURE__ */ e(v, {})) => {\n  if (f)\n    return d === \"number\" ? /* @__PURE__ */ e(\n      \"span\",\n      {\n        className: c(\n          j(t, s),\n          \"flex items-center justify-center bg-brand-primary-600 text-text-on-color rounded-full\"\n        ),\n        children: m + 1\n      }\n    ) : /* @__PURE__ */ e(\"span\", { className: j(t, s), children: o });\n  const b = L(!!n, t, s), p = E(\n    r,\n    n,\n    t,\n    s\n  );\n  let a = null;\n  return r === \"number\" ? a = m + 1 : r === \"icon\" && l && (a = l), /* @__PURE__ */ e(\"span\", { className: b, children: /* @__PURE__ */ e(\"span\", { className: p, children: a }) });\n};\nV.Step = z;\nexport {\n  z as ProgressStep,\n  V as ProgressSteps,\n  O as createStepContent,\n  V as default\n};\n//# sourceMappingURL=progress-steps.es.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst X = createLucideIcon(\"X\", [\n  [\"path\", { d: \"M18 6 6 18\", key: \"1bl5f8\" }],\n  [\"path\", { d: \"m6 6 12 12\", key: \"d8bk6v\" }]\n]);\n\nexport { X as default };\n//# sourceMappingURL=x.js.map\n","/**\n * @license lucide-react v0.446.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst ArrowRight = createLucideIcon(\"ArrowRight\", [\n  [\"path\", { d: \"M5 12h14\", key: \"1ays0h\" }],\n  [\"path\", { d: \"m12 5 7 7-7 7\", key: \"xquz4c\" }]\n]);\n\nexport { ArrowRight as default };\n//# sourceMappingURL=arrow-right.js.map\n","import React, { useState, useEffect } from 'react';\nimport { Container, Button, Skeleton } from \"@bsf/force-ui\";\nimport { LoaderCircle, SearchIcon } from \"lucide-react\";\nimport WidgetItem from '@components/Dashboard/WidgetItem';\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from \"@wordpress/i18n\";\n\nconst OnboardingWidgets = () => {\n\n    const [allWidgetsData, setAllWidgetsData] = useState(null); // Initialize state.\n    const [searchTerm, setSearchTerm] = useState('');\n    const [loadingActivate, setLoadingActivate] = useState(false); // Loading state for activate button\n    const [loadingDeactivate, setLoadingDeactivate] = useState(false);\n    const [loading, setLoading] = useState(true);\n    const [updateCounter, setUpdateCounter] = useState(0);\n\n\n    useEffect(() => {\n        const fetchSettings = () => {\n            setLoading(true);\n            apiFetch({\n                path: '/uael/v1/widgets',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action, // Use the correct nonce\n                },\n            })\n                .then((data) => {\n                    const widgetsData = convertToWidgetsArray(data)\n                    setAllWidgetsData(widgetsData);\n                    setLoading(false); // Stop loading\n                })\n                .catch((err) => {\n                    setLoading(false); // Stop loading\n                });\n        };\n\n        fetchSettings();\n    }, []);\n\n    // New function to handle search input change\n    const handleSearchChange = (event) => {\n        setSearchTerm(event.target.value.toLowerCase());\n    };\n\n    // Filter widgets based on search term\n    const filteredWidgets = allWidgetsData?.filter(widget =>\n        widget.title.toLowerCase().includes(searchTerm) ||\n        widget.keywords?.some(keyword => keyword.toLowerCase().includes(searchTerm))\n    );\n\n    const handleActivateAll = async () => {\n\n        setLoadingActivate(true);\n\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_activate_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingActivate(false);\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: true }))\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else if (data.error) {\n                setLoadingActivate(false);\n                console.error('Error during AJAX request:', error);\n            }\n        }).catch((error) => {\n            setLoadingActivate(false);\n            console.error('Error during AJAX request:', error);\n        });\n    };\n\n    const handleDeactivateAll = async () => {\n        setLoadingDeactivate(true);\n\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_deactivate_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        apiFetch({\n            url: uaelSettingsData.ajax_url,\n            method: 'POST',\n            body: formData,\n        }).then((data) => {\n            setLoadingDeactivate(false);\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: false }))\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else if (data.error) {\n                console.error('AJAX request failed:', data.error);\n            }\n        }).catch((error) => {\n            setLoadingDeactivate(false);\n            console.error('Error during AJAX request:', error);\n        });\n    };\n\n    function convertToWidgetsArray(data) {\n        const widgets = [];\n\n        for (const key in data) {\n            if (data.hasOwnProperty(key)) {\n                const widget = data[key];\n                widgets.push({\n                    id: key, // Using the key as 'widgetTitle'\n                    slug: widget.slug,\n                    title: widget.title,\n                    keywords: widget.keywords,\n                    icon: <i className={widget.icon}></i>,\n                    title_url: widget.title_url,\n                    default: widget.default,\n                    doc_url: widget.doc_url,\n                    is_pro: widget.is_pro,\n                    description: widget.description,\n                    is_active: widget.is_activate !== undefined ? widget.is_activate : true, // Check if is_activate is set\n                    demo_url: widget.demo_url !== undefined ? widget.demo_url : widget.doc_url\n                });\n            }\n        }\n\n        return widgets;\n    }\n\n    return (\n        <div className='rounded-lg w-full mb-4' >\n            <div className='flex flex-col md:flex-row md:items-center md:justify-between p-4' style={{ paddingTop: '1.5rem' }}>\n                <h4 className='m-0 font-semibold text-text-primary mb-2 md:mb-0'>{__(\"WIDGETS\", \"uael\")}</h4>\n                <div className='flex flex-col md:flex-row items-center gap-y-2 md:gap-x-2 md:mr-7 relative' style={{ paddingRight: '0.75rem' }}>\n                    <div className=\"flex flex-row w-full md:w-auto\">\n                        <Button\n                            icon={loadingActivate ? <LoaderCircle className=\"animate-spin\" /> : null}\n                            iconPosition=\"left\"\n                            variant=\"outline\"\n                            className=\"uael-bulk-action-button uael-remove-ring\"\n                            onClick={handleActivateAll} // Attach the onClick event.\n                            disabled={!!searchTerm}\n                            style={{ borderTopRightRadius: '0px', borderBottomRightRadius: '0px', borderRight: '0px', fontSize: '0.9em' }}\n                        >\n                            {loadingActivate ? __('Activating...', 'uael') : __('Activate All', 'uael')}\n                        </Button>\n\n                        <Button\n                            icon={loadingDeactivate ? <LoaderCircle className=\"animate-spin\" /> : null} // Loader for deactivate button.\n                            iconPosition=\"left\"\n                            variant=\"outline\"\n                            onClick={handleDeactivateAll}\n                            className=\"uael-bulk-action-button uael-remove-ring\"\n                            disabled={!!searchTerm}\n                            style={{ borderTopLeftRadius: '0px', borderBottomLeftRadius: '0px', fontSize: '0.9em' }}\n                        >\n                            {loadingDeactivate ? __('Deactivating...', 'uael') : __('Deactivate All', 'uael')}\n                        </Button>\n                    </div>\n                </div>\n            </div>\n            <div\n                className=\"uael-custom-scrollbar bg-background-secondary p-1 rounded-lg max-h-80\" style={{ overflow: 'auto', maxHeight: '20rem', paddingTop: '0' }}>\n                <div className='flex bg-black flex-col p-3' style={{ minHeight: \"800px\", paddingTop: '0' }}>\n                    {loading ? (\n                        <Container\n                            align=\"stretch\"\n                            className=\"p-2 gap-1.5 grid grid-cols-2 md:grid-cols-4\"\n                            style={{\n                                backgroundColor: \"#F9FAFB\"\n                            }}\n                            containerType=\"grid\"\n                            gap=\"\"\n                            justify=\"start\"\n                        >\n                            {[...Array(30)].map((_, index) => (\n                                <Container.Item\n                                    key={index}\n                                    alignSelf=\"auto\"\n                                    className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-8 space-y-2\"\n                                >\n                                    <Skeleton className='w-12 h-2 rounded-md' />\n                                    <Skeleton className='w-16 h-2 rounded-md' />\n                                    <Skeleton className='w-12 h-2 rounded-md' />\n                                </Container.Item>\n                            ))}\n                        </Container>\n                    ) : (\n                        <Container\n                            align=\"stretch\"\n                            className=\"p-1 gap-1.5 grid-cols-2 md:grid-cols-4\"\n                            containerType=\"grid\"\n                            gap=\"\"\n                            justify=\"start\"\n                            style={{\n                                paddingTop: '0'\n                            }}\n                        >\n                            {filteredWidgets?.map((widget) => (\n                                <Container.Item\n                                    key={widget.id}\n                                    alignSelf=\"auto\"\n                                    className=\"text-wrap rounded-md shadow-container-item bg-background-primary p-4\"\n                                >\n                                    <WidgetItem widget={{ ...widget, updateCounter }} key={widget.id} updateCounter={updateCounter} />\n                                </Container.Item>\n                            ))}\n                        </Container>\n                    )}\n                </div>\n            </div>\n        </div>\n    )\n}\n\nexport default OnboardingWidgets\n","import React, { useState, useEffect } from 'react';\nimport { Button } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { ChevronLeft, ChevronRight, ArrowRight } from \"lucide-react\";\nimport { Link } from \"../../router/index\";\nimport { routes } from \"../../admin/settings/routes\";\nimport { __ } from \"@wordpress/i18n\";\nimport OnboardingWidgets from './OnboardingWidgets';\n\nconst WidgetsOnboarding = ({ widgets, updateCounter, setCurrentStep, markStepCompleted, markStepSkipped }) => {\n    const [allWidgetsData, setAllWidgetsData] = useState([]);\n    const [isLoading, setIsLoading] = useState(false);\n\n    // Queue for managing requests\n    const requestQueue = [];\n\n    const processQueue = async () => {\n        while (requestQueue.length > 0) {\n            const currentRequest = requestQueue.shift();\n            await currentRequest();\n        }\n        setIsLoading(false);\n    };\n\n    useEffect(() => {\n        const fetchSettings = async () => {\n            try {\n                setIsLoading(true);\n                const data = await apiFetch({\n                    path: '/uael/v1/widgets',\n                    headers: {\n                        'Content-Type': 'application/json',\n                        'X-WP-Nonce': uaelSettingsData.uael_nonce_action,\n                    },\n                });\n                setAllWidgetsData(convertToWidgetsArray(data));\n            } catch (error) {\n                console.error('Failed to fetch widgets:', error);\n            } finally {\n                setIsLoading(false);\n            }\n        };\n        fetchSettings();\n    }, [updateCounter]);\n\n    const apiCall = async (widget, activateWidget) => {\n        try {\n            const formData = new window.FormData();\n            formData.append('action', activateWidget ? 'uael_activate_widget' : 'uael_deactivate_widget');\n            formData.append('nonce', uael_admin_data.nonce);\n            formData.append('module_id', widget.id);\n            formData.append('is_pro', widget.is_pro);\n\n            const response = await apiFetch({\n                url: uael_admin_data.ajax_url,\n                method: 'POST',\n                body: formData,\n            });\n\n            if (response.success) {\n                widget.is_active = activateWidget;\n                setAllWidgetsData([...allWidgetsData]);\n            }\n        } catch (error) {\n            console.error('API request failed:', error);\n        }\n    };\n\n    const handleSwitchChange = (widget) => {\n        if (isLoading) return;\n\n        // Optimistically update the state\n        const updatedWidgets = allWidgetsData.map(w =>\n            w.id === widget.id ? { ...w, is_active: !w.is_active } : w\n        );\n        setAllWidgetsData(updatedWidgets);\n\n        // Add the API call to the request queue\n        requestQueue.push(() => apiCall(widget, !widget.is_active));\n        if (requestQueue.length === 1) {\n            processQueue();\n        }\n    };\n\n    const convertToWidgetsArray = (data) => {\n        return Object.entries(data).map(([key, widget]) => ({\n            id: key,\n            ...widget,\n            is_active: widget.is_activate !== undefined ? widget.is_activate : true,\n        }));\n    };\n    return (\n        <div className=\"flex flex-col gap-4\">\n            <div className=\"bg-background-secondary uael-min-700\" >\n                <form>\n                    <div className=\"md:w-[47rem] box-border mx-auto space-y-4\">\n                        <OnboardingWidgets/>\n                    </div>\n                </form>\n            </div>\n            <div className=\"flex justify-between items-center pt-1 px-4 gap-4 uael-onboarding-bottom\">\n                <Button\n                    className=\"flex items-center gap-1 uael-remove-ring\"\n                    icon={<ChevronLeft />}\n                    variant=\"outline\"\n                    onClick={() => setCurrentStep(1)}\n                >\n                    {__(\"Back\", \"uael\")}\n                </Button>\n                <div className=\"flex justify-end items-center gap-3\">\n                    \n                    <Button\n                        className=\"uael-remove-ring\"\n                        variant=\"ghost\"\n                        onClick={() => {\n                            markStepSkipped( 'configure' );\n                            setCurrentStep(3);\n                        }}\n                    >\n                        {' '}\n                        {__(\"Skip\", \"uael\")}\n                    </Button>\n                    <Button\n                        className=\"flex items-center gap-1 uael-remove-ring\"\n                        icon={<ArrowRight />}\n                        iconPosition=\"right\"\n                        style={{\n                            backgroundColor: \"#6005FF\",\n                            transition: \"background-color 0.3s ease\",\n                            padding: \"12px\"\n                        }}\n                        onClick={() => {\n                            markStepCompleted( 'configure' );\n                            setCurrentStep(3);\n                        }}\n                    >\n                        {__(\" Continue Setup\", \"uael\")}\n                    </Button>\n                </div>\n            </div>\n        </div>\n    );\n};\n\nexport default WidgetsOnboarding;","import React, { useState, useEffect } from 'react';\nimport { Container, Skeleton, Title, Label } from \"@bsf/force-ui\";\nimport apiFetch from '@wordpress/api-fetch';\nimport { __ } from \"@wordpress/i18n\";\nimport WidgetsOnboarding from '@components/Dashboard/WidgetsOnboarding';\n\nconst FeatureWidgetsOnboarding = ({ setCurrentStep, markStepCompleted, markStepSkipped }) => {\n\n    const [allWidgetsData, setAllWidgetsData] = useState(null); // Initialize state.\n    const [searchTerm, setSearchTerm] = useState('');\n    const [loadingActivate, setLoadingActivate] = useState(false); // Loading state for activate button\n    const [loadingDeactivate, setLoadingDeactivate] = useState(false);\n    const [loading, setLoading] = useState(true);\n    const [updateCounter, setUpdateCounter] = useState(0);\n\n\n    useEffect(() => {\n        const fetchSettings = () => {\n            setLoading(true);\n            apiFetch({\n                path: '/uael/v1/widgets',\n                headers: {\n                    'Content-Type': 'application/json',\n                    'X-WP-Nonce': uaelSettingsData.uael_nonce_action, // Use the correct nonce\n                },\n            })\n                .then((data) => {\n                    const widgetsData = convertToWidgetsArray(data)\n                    setAllWidgetsData(widgetsData);\n                    setLoading(false); // Stop loading\n                })\n                .catch((err) => {\n                    setLoading(false); // Stop loading\n                });\n        };\n\n        fetchSettings();\n\n        history.pushState(null, \"\", window.location.href);\n\n        const handleBackButton = (event) => {\n            event.preventDefault();\n            localStorage.setItem('currentStep', '1');\n            window.location.reload();\n        };\n    \n        window.addEventListener('popstate', handleBackButton);\n    \n        return () => {\n            window.removeEventListener('popstate', handleBackButton);\n        };\n        \n    }, []);\n\n    // New function to handle search input change\n    const handleSearchChange = (event) => {\n        setSearchTerm(event.target.value.toLowerCase());\n    };\n\n    // Filter widgets based on search term\n    const filteredWidgets = allWidgetsData?.filter(widget =>\n        widget.title.toLowerCase().includes(searchTerm) ||\n        widget.keywords?.some(keyword => keyword.toLowerCase().includes(searchTerm))\n    );\n\n    const handleActivateAll = async () => {\n        setLoadingActivate(true);\n\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_activate_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        try {\n            const data = await apiFetch({\n                url: uaelSettingsData.ajax_url,\n                method: 'POST',\n                body: formData,\n            });\n\n            setLoadingActivate(false);\n\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: true }))\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else {\n                console.error('Error during AJAX request:', data.error);\n            }\n        } catch (error) {\n            setLoadingActivate(false);\n            console.error('Error during AJAX request:', error);\n        }\n    };\n\n    const handleDeactivateAll = async () => {\n        setLoadingDeactivate(true);\n\n        const formData = new window.FormData();\n        formData.append('action', 'uael_bulk_deactivate_widgets');\n        formData.append('nonce', uaelSettingsData.ajax_nonce);\n\n        try {\n            const data = await apiFetch({\n                url: uaelSettingsData.ajax_url,\n                method: 'POST',\n                body: formData,\n            });\n\n            setLoadingDeactivate(false);\n\n            if (data.success) {\n                setAllWidgetsData(prevWidgets =>\n                    prevWidgets.map(widget => ({ ...widget, is_active: false }))\n                );\n                setUpdateCounter(prev => prev + 1);\n            } else {\n                console.error('Error during AJAX request:', data.error);\n            }\n        } catch (error) {\n            setLoadingDeactivate(false);\n            console.error('Error during AJAX request:', error);\n        }\n    };\n\n    function convertToWidgetsArray(data) {\n        const widgets = [];\n\n        for (const key in data) {\n            if (data.hasOwnProperty(key)) {\n                const widget = data[key];\n                widgets.push({\n                    id: key, // Using the key as 'widgetTitle'\n                    slug: widget.slug,\n                    title: widget.title,\n                    keywords: widget.keywords,\n                    icon: <i className={widget.icon}></i>,\n                    title_url: widget.title_url,\n                    default: widget.default,\n                    doc_url: widget.doc_url,\n                    is_pro: widget.is_pro,\n                    description: widget.description,\n                    is_active: widget.is_activate !== undefined ? widget.is_activate : true, // Check if is_activate is set\n                    demo_url: widget.demo_url !== undefined ? widget.demo_url : widget.doc_url\n                });\n            }\n        }\n\n        return widgets;\n    }\n\n    return (\n        <div className='rounded-lg bg-white p-6 uae-onboarding-customize'>\n            <h1 className=\"text-text-primary m-0 mb-2\" style={{ fontSize: '1.4rem', lineHeight: '1.3em' }}>\n                {__(\"Customize Your UAE Setup\", \"uael\")}\n            </h1>\n            <span className=\"text-md font-medium text-text-tertiary m-0\" style={{ lineHeight: '1.6em'}}>\n                {__(\n                    \"Activate only what you need to keep your website fast and optimized.\",\n                    \"uael\"\n                )}\n            </span>\n            <div className='flex bg-black flex-col rounded-lg' style={{ marginTop: '2rem' }}>\n                {loading ? (\n                    <Container\n                    align=\"stretch\"\n                    className=\"p-2 gap-1.5 grid grid-cols-2 md:grid-cols-4\"\n                    style={{\n                        backgroundColor: \"#F9FAFB\"\n                    }}\n                    containerType=\"grid\"\n                    gap=\"\"\n                    justify=\"start\"\n                >\n                    {[...Array(30)].map((_, index) => (\n                        <Container.Item\n                            key={index}\n                            alignSelf=\"auto\"\n                            style={{ padding: '3.5rem' }}\n                            className=\"text-wrap rounded-md shadow-container-item bg-background-primary space-y-2\"\n                        >\n                            <Skeleton className='w-12 h-2 rounded-md' />\n                            <Skeleton className='w-16 h-2 rounded-md' />\n                            <Skeleton className='w-12 h-2 rounded-md' />\n                        </Container.Item>\n                    ))}\n                </Container>\n                ) : (\n                    <Container\n                        align=\"stretch\"\n                    >\n                        <WidgetsOnboarding setCurrentStep={setCurrentStep} widgets={filteredWidgets} updateCounter={updateCounter} markStepCompleted={markStepCompleted} markStepSkipped={markStepSkipped} />\n                    </Container>\n                )}\n            </div>\n        </div>\n    )\n}\n\nexport default FeatureWidgetsOnboarding\n","import React, { useEffect, useRef, useCallback } from \"react\";\nimport { Container, Topbar, Button, ProgressSteps } from \"@bsf/force-ui\";\nimport { Link } from \"../../router/link\";\nimport { routes } from \"../../admin/settings/routes\";\nimport { X } from \"lucide-react\";\nimport { __ } from \"@wordpress/i18n\";\nimport Welcome from \"./Welcome\";\nimport Build from \"./Build\";\nimport Configure from \"./Configure\";\n// import Success from \"./Success\";\n\nconst steps = [\n    { label: \"Welcome\", component: Welcome },\n    { label: \"Configure\", component: Configure },\n    { label: \"Create\", component: Build },\n];\n\n// Step number → slug mapping.\nconst stepNames = { 1: 'welcome', 2: 'configure', 3: 'success' };\n\n/**\n * Send the onboarding analytics blob to the server.\n *\n * @param {Object} data Analytics data with completed_steps, skipped_steps, etc.\n */\nconst saveOnboardingAnalytics = ( data ) => {\n    const body = new URLSearchParams();\n    body.append( 'action', 'uael_save_onboarding_analytics' );\n    body.append( 'nonce', uaelSettingsData.ajax_nonce );\n    body.append( 'exited_early', data.exitedEarly ? 'true' : 'false' );\n    body.append( 'exit_at_step', data.exitAtStep || '' );\n\n    ( data.completedSteps || [] ).forEach( ( s ) => body.append( 'completed_steps[]', s ) );\n    ( data.skippedSteps || [] ).forEach( ( s ) => body.append( 'skipped_steps[]', s ) );\n\n    fetch( uaelSettingsData.ajax_url, {\n        method: 'POST',\n        headers: { 'Content-Type': 'application/x-www-form-urlencoded' },\n        body,\n    } ).catch( ( err ) => console.error( 'Onboarding analytics error:', err ) );\n};\n\nconst Onboarding = () => {\n    const [currentStep, setCurrentStep] = React.useState(() => {\n        const savedStep = localStorage.getItem(\"currentStep\");\n        return savedStep ? parseInt(savedStep, 10) : 1;\n    });\n\n    // Track which steps were completed vs skipped across the journey.\n    const stepsCompleted = useRef( JSON.parse( localStorage.getItem( 'uael_onboarding_steps_completed' ) || '[]' ) );\n    const stepsSkipped   = useRef( JSON.parse( localStorage.getItem( 'uael_onboarding_steps_skipped' ) || '[]' ) );\n\n    // Record a step as completed (localStorage only — no server call per step).\n    const markStepCompleted = useCallback( ( stepName ) => {\n        if ( ! stepsCompleted.current.includes( stepName ) ) {\n            stepsCompleted.current.push( stepName );\n            localStorage.setItem( 'uael_onboarding_steps_completed', JSON.stringify( stepsCompleted.current ) );\n        }\n    }, [] );\n\n    // Record a step as skipped (localStorage only).\n    const markStepSkipped = useCallback( ( stepName ) => {\n        if ( ! stepsSkipped.current.includes( stepName ) ) {\n            stepsSkipped.current.push( stepName );\n            localStorage.setItem( 'uael_onboarding_steps_skipped', JSON.stringify( stepsSkipped.current ) );\n        }\n    }, [] );\n\n    useEffect(() => {\n        localStorage.setItem(\"currentStep\", currentStep);\n    }, [currentStep]);\n\n    useEffect(() => {\n        const timer = setTimeout(() => {\n            localStorage.removeItem(\"currentStep\");\n        }, 180000); // 3 minutes in milliseconds.\n\n        return () => clearTimeout(timer); // Clear the timeout if the component unmounts.\n    }, []);\n\n    // \"Exit\" button — send blob with early exit flag, then clean up.\n    // Skip on step 3 (success) because the blob was already saved when Build mounted.\n    const handleExit = () => {\n        if ( currentStep >= 3 ) {\n            return;\n        }\n        saveOnboardingAnalytics( {\n            exitedEarly: true,\n            exitAtStep: stepNames[ currentStep ] || '',\n            completedSteps: stepsCompleted.current,\n            skippedSteps: stepsSkipped.current,\n        } );\n        localStorage.removeItem( 'uael_onboarding_steps_completed' );\n        localStorage.removeItem( 'uael_onboarding_steps_skipped' );\n    };\n\n    const StepComponent = steps[currentStep - 1]?.component;\n\n    return (\n        <div>\n            <div className=\"w-full pb-10\">\n                <div className=\"flex flex-col items-center justify-center\">\n                    <Topbar className=\"bg-none\" style={{ background: \"none\" }}>\n                        <Topbar.Left>\n                            <Topbar.Item>\n                                {uaelSettingsData.uae_logo && (\n                                    <Link to={routes.dashboard.path}>\n                                        <img\n                                            src={`${uaelSettingsData.uae_logo}`}\n                                            alt=\"Logo\"\n                                            className=\"cursor-pointer\"\n                                            style={{ height: \"35px\" }}\n                                        />\n                                    </Link>\n                                )}\n                            </Topbar.Item>\n                        </Topbar.Left>\n                        <Topbar.Middle>\n                            <Topbar.Item>\n                                <ProgressSteps\n                                    currentStep={currentStep}\n\t\t\t\t\t\t\t\t\tclassName=\"uae-steps\"\n                                    variant=\"number\"\n                                >\n                                    {steps.map((step, index) => (\n                                        <ProgressSteps.Step\n                                            key={index}\n                                            className=\"font-bold\"\n                                            labelText={step.label}\n                                            size=\"md\"\n                                        />\n                                    ))}\n                                </ProgressSteps>\n                            </Topbar.Item>\n                        </Topbar.Middle>\n                        <Topbar.Right>\n                            <Topbar.Item>\n                                <Link className=\"uael-remove-ring\" to={routes.dashboard.path}\n                                style={{ marginLeft: '125px'}}\n                                onClick={handleExit}>\n                                    <Button\n                                        icon={<X className=\"size-4\" />}\n                                        iconPosition=\"right\"\n                                        size=\"xs\"\n                                        variant=\"ghost\"\n                                        className=\"uael-remove-ring\"\n                                    ></Button>\n                                </Link>\n                            </Topbar.Item>\n                        </Topbar.Right>\n                    </Topbar>\n                </div>\n            </div>\n\n            <div className=\"flex items-center justify-center\">\n                {StepComponent && (\n                    <StepComponent\n                        currentStep={currentStep}\n                        setCurrentStep={setCurrentStep}\n                        saveOnboardingAnalytics={saveOnboardingAnalytics}\n                        markStepCompleted={markStepCompleted}\n                        markStepSkipped={markStepSkipped}\n                        stepsCompleted={stepsCompleted}\n                        stepsSkipped={stepsSkipped}\n                    />\n                )}\n            </div>\n        </div>\n    );\n};\n\nexport default Onboarding;\n","import React from 'react';\nimport { Button } from '@bsf/force-ui';\nimport { __ } from \"@wordpress/i18n\";\n\nconst Welcome = ({ setCurrentStep, markStepCompleted }) => {\n    return (\n        <div className=\"bg-background-primary border-[0.5px] items-start justify-center border-subtle rounded-xl shadow-sm mb-6 p-8 flex flex-col\" style={{ maxWidth: '55%' }}>\n            <div className=\"px-1\">\n                <div className=\"flex flex-col\">\n                    <h1 className=\"text-text-primary m-0 mb-2 uael-65-width\" style={{ fontSize: '1.6rem', lineHeight: '1.3em' }}>\n                        <span className=\"block\">{__(\n                            \"Thank You For Choosing\",\n                            \"uael\"\n                        )}\n                        </span>\n                        <span className=\"block\">{__(\n                            \"Ultimate Addons for Elementor\",\n                            \"uael\"\n                        )}\n                    </span>\n                    </h1>\n                    <span className=\"text-md font-medium text-text-tertiary m-0 mb-6 uael-88-width\" style={{ lineHeight: '1.5em' }}>\n                        {__(\n                            \"We're excited to have you onboard. Get ready to create stunning headers, footers, and custom blocks with ease while keeping your website lightweight and fast.\",\n                            \"uael\"\n                        )}\n                    </span>\n                </div>\n                <img\n                    alt=\"Welcome\"\n                    className=\"w-full h-auto mb-6 mt-2\"\n                    src={`${uaelSettingsData.welcome_banner}`}\n                    loading=\"lazy\"\n                />\n                <Button\n                    iconPosition=\"right\"\n                    variant=\"primary\"\n                    className=\"bg-[#6005FF] uael-remove-ring p-3 px-5 font-bold mt-2\"\n                    style={{\n                        backgroundColor: \"#6005FF\",\n                        transition: \"background-color 0.3s ease\",\n                    }}\n                    onMouseEnter={(e) =>\n                    (e.currentTarget.style.backgroundColor =\n                        \"#4B00CC\")\n                    }\n                    onMouseLeave={(e) =>\n                    (e.currentTarget.style.backgroundColor =\n                        \"#6005FF\")\n                    }\n                    onClick={() => {\n                        markStepCompleted( 'welcome' );\n                        setCurrentStep(2);\n                    }}\n                >\n                    {__(\"Let's Get Started\", \"uael\")}\n                </Button>\n            </div>\n        </div>\n    );\n};\n\nexport default Welcome;","import React from 'react'\nimport { __ } from \"@wordpress/i18n\";\nimport FeatureWidgetsOnboarding from '@components/Widgets/Features/FeatureWidgetsOnboarding';\n\nconst Configure = ({ setCurrentStep, markStepCompleted, markStepSkipped }) => {\n    return (\n        <FeatureWidgetsOnboarding setCurrentStep={setCurrentStep} markStepCompleted={markStepCompleted} markStepSkipped={markStepSkipped} />\n    )\n}\n\nexport default Configure\n","import React, { useEffect, useState } from 'react';\nimport { Container, Button, Switch, Title, Dialog, Input } from '@bsf/force-ui';\nimport { X, Check, Plus, ArrowRight, Package } from 'lucide-react';\nimport toast, { Toaster } from 'react-hot-toast';\nimport { Link } from \"../../router/index\"\nimport { __ } from \"@wordpress/i18n\";\nimport { routes } from \"../../admin/settings/routes\";\n\nconst OnboardingBuild = ({ setCurrentStep, saveOnboardingAnalytics, stepsCompleted, stepsSkipped }) => {\n    const [isDialogOpen, setIsDialogOpen] = useState(false);\n    const [email, setEmail] = useState('');\n    const [isSubmitted, setIsSubmitted] = useState(false);\n\n    useEffect(() => {\n        setEmail(uaelSettingsData.user_email);\n\n        // Send onboarding analytics blob — user reached the success screen.\n        const completed = stepsCompleted?.current || JSON.parse( localStorage.getItem( 'uael_onboarding_steps_completed' ) || '[]' );\n        const skipped   = stepsSkipped?.current || JSON.parse( localStorage.getItem( 'uael_onboarding_steps_skipped' ) || '[]' );\n        saveOnboardingAnalytics( {\n            exitedEarly: false,\n            exitAtStep: '',\n            completedSteps: completed,\n            skippedSteps: skipped,\n        } );\n\n        // Clean up journey localStorage.\n        localStorage.removeItem( 'uael_onboarding_steps_completed' );\n        localStorage.removeItem( 'uael_onboarding_steps_skipped' );\n\n        history.pushState(null, \"\", window.location.href);\n\n        const handleBackButton = (event) => {\n            event.preventDefault();\n            localStorage.setItem('currentStep', '2');\n            window.location.reload();\n        };\n    \n        window.addEventListener('popstate', handleBackButton);\n    \n        return () => {\n            window.removeEventListener('popstate', handleBackButton);\n        };\n\n    }, [uaelSettingsData.user_email]);\n\n    return (\n        <div className=\"bg-background-primary border-[0.5px] border-subtle rounded-xl shadow-sm mb-6 p-8\" style={{ maxWidth: '55%' }}>\n            <div className=\"flex items-start uael-display-flex\">\n                {/* Left Content */}\n                <div className=\"flex flex-col items-start\" style={{ paddingRight: '35px' }}>\n                    <h1 className=\"text-text-primary m-0 mb-2\" style={{ fontSize: '1.6rem', lineHeight: '1.3em' }}>\n                        {__(\"You're all set!🚀\", \"uael\")}\n                    </h1>\n                    <span className=\"text-md font-medium text-text-tertiary m-0 mb-4 uael-88-width\" style={{ lineHeight: '1.6em' }}>\n\n                    { uaelSettingsData.is_lite_active ? (\n                        <>\n                            {__(\n                                \"Start creating headers, footers, or pages with UAE and take your website to the next level\",\n                                \"uael\"\n                            )}\n                        </>\n                    ) : (\n                        <>\n                            {__(\n                                \"Start creating amazing designs with UAE and take your website to the next level\",\n                                \"uael\"\n                            )}\n                        </>\n                    )}\n                    </span>\n                    <span className=\"font-bold m-0 pt-2\">\n                        {__(\"Here’s how to get started:\", \"uael\")}\n                    </span>\n\n                    { uaelSettingsData.is_lite_active ? (\n                        <ol className=\"list-decimal text-text-tertiary text-sm\" style={{ marginLeft: '1.4em', lineHeight: '1.6em', paddingBottom: '0.5rem' }}>\n                            <li>{__('Click on “Create” button', 'uael')}</li>\n                            <li>{__('Use the Elementor editor to customize your header, footer, page or post according to your preferences', 'uael')}</li>\n                            <li>{__('Use UAE widgets for your designs', 'uael')}</li>\n                            <li>{__('Click “Publish” to make it live', 'uael')}</li>\n                        </ol>\n                    ) : (\n                        <ol className=\"list-decimal text-text-tertiary text-sm\" style={{ marginLeft: '1.4em', lineHeight: '1.6em', paddingBottom: '0.5rem' }}>\n                            <li>{__('Click on “Create New Page” button', 'uael')}</li>\n                            <li>{__('Use the Elementor editor to customize your page/post according to your preferences', 'uael')}</li>\n                            <li>{__('Use UAE widgets to design your pages.', 'uael')}</li>\n                            <li>{__('Click “Publish” to make it live', 'uael')}</li>\n                        </ol>\n                    )}\n                </div>\n\n                {/* Right Content - Image */}\n                <div className=\"w-1/2\" style={{ textAlign: 'end' }}>\n                    <img\n                        alt=\"Build\"\n                        className=\"w-full object-contain\"\n                        style={{ height: '210px', width: 'auto' }}\n                        src={`${uaelSettingsData.build_banner}`}\n                        loading=\"lazy\"\n                    />\n                </div>\n            </div>\n            <div className='flex flex-row gap-1 pb-4 uael-display-flex'>\n                { uaelSettingsData.is_lite_active ? (\n                    <>\n                        <Button\n                            icon={<ArrowRight />}\n                            iconPosition=\"right\"\n                            variant=\"primary\"\n                            className=\"bg-[#6005FF] uael-remove-ring mr-2\"\n                            style={{\n                                backgroundColor: \"#6005FF\",\n                                transition: \"background-color 0.3s ease\",\n                            }}\n                            onMouseEnter={(e) =>\n                                (e.currentTarget.style.backgroundColor =\n                                    \"#4B00CC\")\n                            }\n                            onMouseLeave={(e) =>\n                                (e.currentTarget.style.backgroundColor =\n                                    \"#6005FF\")\n                            }\n                            onClick={() => {\n                                window.open(\n                                    uaelSettingsData.uael_hfe_post_url,\n                                    \"_blank\"\n                                );\n                            }}\n                        >\n                            {__(\"Create Header/Footer\", \"uael\")}\n                        </Button>\n                        <Button\n                            icon={<Plus />}\n                            iconPosition=\"right\"\n                            variant=\"outline\"\n                            className=\"uael-remove-ring\"\n                            style={{\n                                color: \"#6005FF\",\n                                borderColor: \"#6005FF\",\n                            }}\n                            onMouseEnter={(e) =>\n                                (e.currentTarget.style.color =\n                                    \"#000000\") &&\n                                (e.currentTarget.style.borderColor =\n                                    \"#000000\")\n                            }\n                            onMouseLeave={(e) =>\n                                (e.currentTarget.style.color =\n                                    \"#6005FF\") &&\n                                (e.currentTarget.style.borderColor =\n                                    \"#6005FF\")\n                            }\n                            onClick={() => {\n                                window.open(\n                                    uaelSettingsData.elementor_page_url,\n                                    \"_blank\"\n                                );\n                            }}\n                        >\n                            {__(\"Create New Page\", \"uael\")}\n                        </Button>\n                    </>\n                ) : (\n                    <Button\n                        icon={<Plus />}\n                        iconPosition=\"right\"\n                        variant=\"primary\"\n                        className=\"bg-[#6005FF] uael-remove-ring\"\n                        style={{\n                            backgroundColor: \"#6005FF\",\n                            transition: \"background-color 0.3s ease\",\n                        }}\n                        onMouseEnter={(e) =>\n                        (e.currentTarget.style.backgroundColor =\n                            \"#4B00CC\")\n                        }\n                        onMouseLeave={(e) =>\n                        (e.currentTarget.style.backgroundColor =\n                            \"#6005FF\")\n                        }\n                        onClick={() => {\n                            window.open(\n                                uaelSettingsData.elementor_page_url,\n                                \"_blank\"\n                            );\n                        }}\n                    >\n                        {__(\"Create New Page\", \"uael\")}\n                    </Button>\n                )}\n\n                <Link\n                    to={routes.dashboard.path}\n\n                >\n                    <Button\n                        icon={<ArrowRight />}\n                        iconPosition=\"right\"\n                        variant=\"ghost\"\n                        className=\"uael-remove-ring\"\n                        onMouseLeave={(e) =>\n                            (e.currentTarget.style.color =\n                                \"#000000\") &&\n                            (e.currentTarget.style.borderColor =\n                                \"#000000\")\n                        }\n                        onMouseEnter={(e) =>\n                            (e.currentTarget.style.color =\n                                \"#6005FF\") &&\n                            (e.currentTarget.style.borderColor =\n                                \"#6005FF\")\n                        }\n                    >\n                        {__(\"Go To Dashboard\", \"uael\")}\n                    </Button>\n                </Link>\n\n            </div>\n        </div>\n    )\n}\n\nexport default OnboardingBuild;","import React from 'react'\nimport { Container, Topbar, Button, ProgressSteps, Label, Title } from '@bsf/force-ui'\nimport { Link } from \"../../router/link\";\nimport { routes } from \"../../admin/settings/routes\";\nimport { X, Check } from 'lucide-react';\nimport { __ } from \"@wordpress/i18n\";\nimport Welcome from './Welcome';\nimport OB from './index'\n\nconst Onboarding = () => {\n\n    return (\n        <>\n        <OB />\n        </>\n    )\n}\n\nexport default Onboarding\n","import { useState, useEffect } from 'react';\nimport { Router, Route, Link } from './index';\nimport Dashboard from '@components/Dashboard/Dashboard';\nimport Features from '@components/Widgets/Features';\nimport Settings from '@components/Settings/Settings';\nimport { routes } from 'admin/settings/routes';\nimport { Loader } from '@bsf/force-ui';\nimport Onboarding from '@components/Onboarding/Onboarding.jsx';\n\n\nconst CustomRouter = () => {\n  const [loaded, setLoaded] = useState(false);\n   const firstTimeUser = false\n\n  useEffect(() => {\n    setTimeout(() => {\n      setLoaded(true);\n    }, 1000); // Simulating a load delay of 1 second\n  }, []);\n\n  if (!loaded) {\n    return (\n      <div\n        className=\"loading-spinner flex items-center justify-center h-screen\"\n        style={{ background: \"#F9FAFB\" }}\n      >\n        <Loader icon={null} size=\"lg\" variant=\"primary\" />\n      </div>\n    );\n  }\n\n  return (\n    <Router routes={routes} defaultRoute={routes?.dashboard?.path}>\n    <Route path={routes.dashboard.path}><Dashboard /></Route>\n    <Route path={routes.onboarding.path}><Onboarding /></Route>\n    <Route path={routes.widgets.path}><Features /></Route>\n    <Route path={routes.settings.path}><Settings /></Route>\n  </Router>\n  );\n};\n\nexport default CustomRouter;","import { useState, useEffect } from \"react\";\nimport \"@fontsource/figtree\"; // Defaults to weight 400\nimport \"@fontsource/figtree/400.css\"; // Specify weight\nimport \"@fontsource/figtree/400-italic.css\"; // Specify weight and style\nimport CustomRouter from \"router/customRouter\";\nimport { Loader } from \"@bsf/force-ui\";\n\nconst App = () => {\n\tconst [loaded, setLoaded] = useState(false);\n\n\t// scroll top on route change\n\twindow.onhashchange = () => {\n\t\twindow.scrollTo(0, 0);\n\t};\n\n\t// Simulate loading (replace with actual loading logic if needed)\n\tuseEffect(() => {\n\t\tsetTimeout(() => {\n\t\t\tsetLoaded(true);\n\t\t}, 1000); // Simulating a load delay of 1 second\n\t}, []);\n\n\tif (!loaded) {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclassName=\"loading-spinner flex items-center justify-center h-screen\"\n\t\t\t\tstyle={{ background: \"#F9FAFB\" }}\n\t\t\t>\n\t\t\t\t<Loader icon={null} size=\"lg\" variant=\"primary\" />\n\t\t\t</div>\n\t\t);\n\t}\n\n\treturn (\n\t\t<div className=\"app-container font-figtree\">\n\t\t\t<CustomRouter />\n\t\t</div>\n\t);\n};\n\nexport default App;\n","import { createRoot } from \"react-dom/client\"; // Import from react-dom/client for React 18\nimport domReady from \"@wordpress/dom-ready\";\nimport NavMenu from '@components/NavMenu'\nimport App from \"./App\";\nimport \"./styles.css\";\n\ndomReady(() => {\n\tconst rootElement = document.getElementById(\"uae-settings-app\");\n\tif (rootElement) {\n\t\tconst root = createRoot(rootElement); // Use createRoot() for React 18\n\t\troot.render(<App />);\n\t}\n\t\n\tif( uaelSettingsData.is_lite_active ) {\n\t\tif ( window.location.href === uaelSettingsData.header_footer_builder || \"yes\" === uaelSettingsData.is_hfe_post ) {\n\t\t\tconst navMenuElement = document.getElementById(\"hfe-admin-top-bar-root\");\n\t\t\tif (navMenuElement) {\n\t\t\t\tconst newDiv = document.createElement(\"div\");\n\t\t\t\tnewDiv.id = \"uae-settings-app\";\n\t\t\t\tnavMenuElement.appendChild(newDiv);\n\t\t\n\t\t\t\tconst navMenuRoot = createRoot(newDiv);\n\t\t\t\tnavMenuRoot.render(<NavMenu />);\n\t\t\t}\n\t\t}\n\t}\n});\n"],"names":["leafPrototypes","getProto","reTrim","reIsBadHex","reIsBinary","reIsOctal","freeParseInt","parseInt","freeGlobal","g","Object","freeSelf","self","root","Function","objectToString","prototype","toString","nativeMax","Math","max","nativeMin","min","now","Date","isObject","value","type","toNumber","isObjectLike","call","isSymbol","other","valueOf","replace","isBinary","test","slice","module","exports","func","wait","options","lastArgs","lastThis","maxWait","result","timerId","lastCallTime","lastInvokeTime","leading","maxing","trailing","TypeError","invokeFunc","time","args","thisArg","undefined","apply","shouldInvoke","timeSinceLastCall","timerExpired","trailingEdge","setTimeout","remainingWait","debounced","isInvoking","arguments","this","leadingEdge","cancel","clearTimeout","flush","path","decode","decodeURIComponent","delimiter","DEFAULT_DELIMITER","regexp","keys","end","sensitive","flags","sources","input","pathsToArray","data","parse","tokens","flatten","push","toRegExpSource","originalPath","pattern","join","escape","RegExp","pathToRegexp","decoders","map","key","NOOP_VALUE","split","m","exec","params","create","i","length","decoder","name","ID_START","ID_CONTINUE","SIMPLE_TOKENS","str","TokenData","constructor","PathError","message","text","super","encodePath","chars","index","pos","quoteStart","consumeUntil","endType","output","token","cur","paths","init","Array","isArray","p","seq","backtrack","isSafeSegmentParam","negate","includes","has","hasOwnProperty","e","encode","encodeURIComponent","stringify","obj","prefix","pairs","isNaN","query","part","parser","createRoot","hydrateRoot","f","k","Symbol","for","l","n","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","ref","__self","__source","q","c","a","b","d","h","defaultProps","$$typeof","props","_owner","current","Fragment","jsx","jsxs","window","hasOwn","classNames","classes","arg","appendClass","parseValue","newClass","default","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","getter","__esModule","getPrototypeOf","__proto__","t","mode","then","ns","r","def","indexOf","getOwnPropertyNames","forEach","definition","o","defineProperty","enumerable","get","globalThis","prop","toStringTag","_arrayLikeToArray","_unsupportedIterableToArray","from","_slicedToArray","iterator","u","next","done","createClassGroupUtils","config","classMap","createClassMap","conflictingClassGroups","conflictingClassGroupModifiers","getClassGroupId","className","classParts","shift","getGroupRecursive","getGroupIdForArbitraryProperty","getConflictingClassGroupIds","classGroupId","hasPostfixModifier","conflicts","classPartObject","currentClassPart","nextClassPartObject","nextPart","classGroupFromNextClassPart","validators","classRest","find","validator","arbitraryPropertyRegex","arbitraryPropertyClassName","property","substring","theme","Map","getPrefixedClassGroupEntries","entries","classGroups","classGroup","processClassesRecursively","classDefinition","isThemeGetter","getPart","currentClassPartObject","pathPart","set","classGroupEntries","fromEntries","createLruCache","maxCacheSize","cacheSize","cache","previousCache","update","createParseClassName","separator","experimentalParseClassName","isSeparatorSingleCharacter","firstSeparatorCharacter","separatorLength","parseClassName","modifiers","postfixModifierPosition","bracketDepth","modifierStart","currentCharacter","baseClassNameWithImportantModifier","hasImportantModifier","startsWith","baseClassName","maybePostfixModifierPosition","sortModifiers","sortedModifiers","unsortedModifiers","modifier","sort","SPLIT_CLASSES_REGEX","twJoin","argument","resolvedValue","string","toValue","mix","createTailwindMerge","createConfigFirst","createConfigRest","configUtils","cacheGet","cacheSet","functionToCall","classList","reduce","previousConfig","createConfigCurrent","createConfigUtils","tailwindMerge","cachedResult","classGroupsInConflict","trim","originalClassName","Boolean","variantModifier","modifierId","classId","conflictGroups","group","mergeClassList","fromTheme","themeGetter","arbitraryValueRegex","fractionRegex","stringLengths","Set","tshirtUnitRegex","lengthUnitRegex","colorFunctionRegex","shadowRegex","imageRegex","isLength","isNumber","isArbitraryLength","getIsArbitraryValue","isLengthOnly","Number","isArbitraryNumber","isInteger","isPercent","endsWith","isArbitraryValue","isTshirtSize","sizeLabels","isArbitrarySize","isNever","isArbitraryPosition","imageLabels","isArbitraryImage","isImage","isArbitraryShadow","isShadow","isAny","label","testValue","getDefaultConfig","colors","spacing","blur","brightness","borderColor","borderRadius","borderSpacing","borderWidth","contrast","grayscale","hueRotate","invert","gap","gradientColorStops","gradientColorStopPositions","inset","margin","opacity","padding","saturate","scale","sepia","skew","space","translate","getSpacingWithAutoAndArbitrary","getSpacingWithArbitrary","getLengthWithEmptyAndArbitrary","getNumberWithAutoAndArbitrary","getZeroAndEmpty","getNumberAndArbitrary","aspect","container","columns","box","display","float","clear","isolation","object","overflow","overscroll","position","start","top","right","bottom","left","visibility","z","basis","flex","grow","shrink","order","col","span","row","justify","content","items","px","py","ps","pe","pt","pr","pb","pl","mx","my","ms","me","mt","mr","mb","ml","w","screen","size","font","tracking","list","placeholder","decoration","indent","align","whitespace","break","hyphens","bg","repeat","via","to","rounded","border","divide","outline","ring","shadow","filter","table","caption","transition","duration","ease","delay","animate","transform","rotate","origin","accent","appearance","cursor","caret","resize","scroll","snap","touch","select","fill","stroke","sr","twMerge","clsx","xxs","xs","sm","md","lg","xl","children","s","displayName","center","hasWindow","getNodeName","node","isNode","nodeName","toLowerCase","getWindow","_node$ownerDocument","ownerDocument","defaultView","getDocumentElement","_ref","document","documentElement","Node","isElement","Element","isHTMLElement","HTMLElement","isShadowRoot","ShadowRoot","Left","Middle","Right","Item","invalidOverflowDisplayValues","isOverflowElement","element","overflowX","overflowY","tableElements","isTableElement","topLayerSelectors","isTopLayer","some","selector","matches","_e","transformProperties","willChangeValues","containValues","isContainingBlock","elementOrCss","webkit","isWebKit","css","containerType","backdropFilter","willChange","contain","CSS","supports","lastTraversableNodeNames","isLastTraversableNode","getComputedStyle","getNodeScroll","scrollLeft","scrollTop","scrollX","scrollY","getParentNode","assignedSlot","parentNode","host","getNearestOverflowAncestor","body","getOverflowAncestors","traverseIframes","_node$ownerDocument2","scrollableAncestor","isBody","win","frameElement","getFrameElement","concat","visualViewport","parent","activeElement","doc","_activeElement","shadowRoot","contains","child","rootNode","getRootNode","getPlatform","uaData","navigator","userAgentData","platform","getUserAgent","brands","brand","version","userAgent","isSafari","vendor","isAndroid","re","isMouseLikePointerType","pointerType","strict","values","getDocument","isEventTargetWithin","event","composedPath","target","getTarget","isTypeableElement","candidateSelector","NoElement","msMatchesSelector","webkitMatchesSelector","_element$getRootNode","_isInert","lookUp","_node$getAttribute","inertAtt","getAttribute","closest","_getCandidatesIteratively","elements","includeContainer","candidates","elementsToCheck","tagName","assigned","assignedElements","nestedCandidates","scopeParent","getShadowRoot","validShadowRoot","shadowRootFilter","_nestedCandidates","unshift","hasTabIndex","getTabIndex","Error","tabIndex","_node$getAttribute2","attValue","isContentEditable","sortOrderedTabbables","documentOrder","isInput","isZeroArea","_node$getBoundingClie","getBoundingClientRect","width","height","isNodeMatchingSelectorFocusable","disabled","isHiddenInput","displayCheck","checkVisibility","checkOpacity","opacityProperty","contentVisibilityAuto","visibilityProperty","checkVisibilityCSS","nodeUnderDetails","parentElement","originalNode","_nodeRoot","_nodeRootHost","_nodeRootHost$ownerDo","nodeRoot","nodeRootHost","attached","_nodeRoot2","_nodeRootHost2","_nodeRootHost2$ownerD","isNodeAttached","getClientRects","isHidden","isDetailsWithSummary","item","isDisabledFromFieldset","isNodeMatchingSelectorTabbable","isRadio","radioSet","radioScope","form","queryRadios","querySelectorAll","err","console","error","checked","nodes","getCheckedRadio","isTabbableRadio","isNonTabbableRadio","isShadowRootTabbable","shadowHostNode","_sortByOrder","regularTabbables","orderedTabbables","isScope","candidateTabindex","getSortOrderTabIndex","acc","sortable","tabbable","bind","el","getCandidates","round","floor","createCoords","v","x","y","oppositeSideMap","oppositeAlignmentMap","clamp","evaluate","param","getSide","placement","getAlignment","getOppositeAxis","axis","getAxisLength","yAxisSides","getSideAxis","getAlignmentAxis","getOppositeAlignmentPlacement","alignment","lrPlacement","rlPlacement","tbPlacement","btPlacement","getOppositePlacement","side","getPaddingObject","expandPaddingObject","rectToClientRect","rect","computeCoordsFromPlacement","rtl","reference","floating","sideAxis","alignmentAxis","alignLength","isVertical","commonX","commonY","commonAlign","coords","async","detectOverflow","state","_await$platform$isEle","rects","strategy","boundary","rootBoundary","elementContext","altBoundary","paddingObject","clippingClientRect","getClippingRect","contextElement","offsetParent","getOffsetParent","offsetScale","getScale","elementClientRect","convertOffsetParentRelativeRectToViewportRelativeRect","originSides","getCssDimensions","parseFloat","hasOffset","offsetWidth","offsetHeight","shouldFallback","$","unwrapElement","domElement","isFinite","noOffsets","getVisualOffsets","offsetLeft","offsetTop","includeScale","isFixedStrategy","clientRect","visualOffsets","isFixed","floatingOffsetParent","shouldAddVisualOffsets","offsetWin","currentWin","currentIFrame","iframeScale","iframeRect","clientLeft","paddingLeft","clientTop","paddingTop","getWindowScrollBarX","leftScroll","getHTMLOffset","htmlRect","absoluteOrFixed","getClientRectFromClippingAncestor","clippingAncestor","html","clientWidth","clientHeight","visualViewportBased","windowScrollbarX","bodyStyles","bodyMarginInline","compatMode","marginLeft","marginRight","clippingStableScrollbarWidth","abs","getViewportRect","scrollWidth","scrollHeight","direction","getDocumentRect","getInnerBoundingClientRect","hasFixedPositionAncestor","stopNode","getRectRelativeToOffsetParent","isOffsetParentAnElement","offsets","setLeftRTLScrollbarOffset","offsetRect","htmlOffset","isStaticPositioned","getTrueOffsetParent","polyfill","rawOffsetParent","svgOffsetParent","currentNode","getContainingBlock","topLayer","clippingAncestors","currentContainingBlockComputedStyle","elementIsFixed","computedStyle","currentNodeIsContaining","ancestor","getClippingElementAncestors","_c","firstClippingAncestor","clippingRect","accRect","getElementRects","getOffsetParentFn","getDimensionsFn","getDimensions","floatingDimensions","isRTL","rectsAreEqual","autoUpdate","ancestorScroll","ancestorResize","elementResize","ResizeObserver","layoutShift","IntersectionObserver","animationFrame","referenceEl","ancestors","addEventListener","passive","cleanupIo","onMove","timeoutId","io","cleanup","_io","disconnect","refresh","skip","threshold","elementRectForRootMargin","rootMargin","isFirstUpdate","handleObserve","ratio","intersectionRatio","observe","observeMove","frameId","reobserveFrame","resizeObserver","firstEntry","unobserve","cancelAnimationFrame","requestAnimationFrame","_resizeObserver","prevRefRect","frameLoop","nextRefRect","_resizeObserver2","removeEventListener","fn","_middlewareData$offse","_middlewareData$arrow","middlewareData","diffCoords","mainAxisMulti","crossAxisMulti","rawValue","mainAxis","crossAxis","convertValueToCoords","offset","arrow","alignmentOffset","checkMainAxis","checkCrossAxis","limiter","detectOverflowOptions","mainAxisCoord","crossAxisCoord","maxSide","limitedCoords","enabled","_middlewareData$flip","initialPlacement","fallbackPlacements","specifiedFallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment","initialSideAxis","isBasePlacement","oppositePlacement","getExpandedPlacements","hasFallbackAxisSideDirection","isStart","getSideList","getOppositeAxisPlacements","placements","overflows","overflowsData","flip","sides","mainAlignmentSide","getAlignmentSides","every","_middlewareData$flip2","_overflowsData$filter","nextIndex","nextPlacement","reset","resetPlacement","_overflowsData$filter2","currentSideAxis","arrowDimensions","isYAxis","minProp","maxProp","clientProp","endDiff","startDiff","arrowOffsetParent","clientSize","centerToReference","largestPossiblePadding","minPadding","maxPadding","min$1","shouldAddOffset","centerOffset","mergedOptions","platformWithCache","middleware","validMiddleware","statefulPlacement","resetCount","_platform$detectOverf","nextX","nextY","computePosition","useLayoutEffect","deepEqual","getDPR","devicePixelRatio","roundByDPR","dpr","useLatestRef","arrow$1","deps","SafeReact","useSafeInsertionEffect","useInsertionEffect","useEffectEvent","callback","_len","_key","useEffect","_extends","assign","source","serverHandoffComplete","count","genId","random","useId","id","setId","FloatingArrow","context","tipRadius","strokeWidth","staticOffset","style","restStyle","rest","clipPathId","setIsRTL","isVerticalSide","computedStaticOffset","computedStrokeWidth","halfStrokeWidth","svgX","svgY","isCustomShape","yOffsetProp","xOffsetProp","arrowX","arrowY","dValue","rotation","viewBox","pointerEvents","clipPath","FloatingNodeContext","FloatingTreeContext","useFloatingParentNodeId","_React$useContext","useFloatingTree","createAttribute","useRef","safePolygonIdentifier","getDelay","getChildren","allChildren","_node$context","parentId","open","currentChildren","_currentChildren","_node$context2","getTabbableOptions","getTabbableIn","allTabbable","reverse","activeIndex","isOutsideEvent","containerElement","currentTarget","relatedTarget","disableFocusInside","dataset","tabindex","setAttribute","enableFocusInside","removeAttribute","HIDDEN_STYLES","clip","whiteSpace","setActiveElementOnTab","FocusGuard","role","setRole","restProps","PortalContext","attr","FloatingPortal","preserveTabOrder","portalNode","uniqueId","portalContext","usePortalContext","setPortalNode","portalNodeRef","remove","queueMicrotask","existingIdRoot","getElementById","subRoot","createElement","appendChild","idWrapper","useFloatingPortalNode","focusManagerState","setFocusManagerState","beforeOutsideRef","afterOutsideRef","beforeInsideRef","afterInsideRef","modal","shouldRenderGuards","onFocus","Provider","_beforeInsideRef$curr","focus","prevTabbable","refs","domReference","_afterInsideRef$curre","nextTabbable","closeOnFocusOut","onOpenChange","nativeEvent","FOCUSABLE_ATTRIBUTE","isButtonTarget","isSpaceIgnored","useClick","dataRef","eventOption","toggle","ignoreMouse","keyboardHandlers","stickIfOpen","pointerTypeRef","didKeyDownRef","onPointerDown","onMouseDown","button","openEvent","preventDefault","onClick","onKeyDown","defaultPrevented","onKeyUp","bubbleHandlerKeys","pointerdown","mousedown","click","captureHandlerKeys","normalizeProp","normalizable","_normalizable$escapeK","_normalizable$outside","escapeKey","outsidePress","useDismiss","unstable_outsidePress","outsidePressEvent","referencePress","referencePressEvent","bubbles","capture","tree","outsidePressFn","insideReactTreeRef","endedOrStartedInsideRef","escapeKeyBubbles","outsidePressBubbles","escapeKeyCapture","outsidePressCapture","isComposingRef","closeOnEscapeKeyDown","_dataRef$current$floa","nodeId","floatingContext","nodesRef","stopPropagation","shouldDismiss","_child$context","__escapeKeyBubbles","isReactEvent","closeOnEscapeKeyDownCapture","_getTarget2","_getTarget","closeOnPressOutside","_dataRef$current$floa2","insideReactTree","endedOrStartedInside","inertSelector","markers","targetRootAncestor","nextParent","marker","canScrollX","canScrollY","xCond","offsetX","offsetY","targetIsInsideChildren","_child$context2","__outsidePressBubbles","closeOnPressOutsideCapture","_getTarget4","_getTarget3","compositionTimeout","onScroll","handleCompositionStart","handleCompositionEnd","_doc$defaultView","onMouseUp","internalRootContext","onOpenChangeProp","elementsProp","floatingId","events","emit","_map$get","handler","on","listener","off","_map$get2","createPubSub","nested","positionReference","setPositionReference","reason","useFloatingRootContext","rootContext","computedElements","_domReference","setDomReference","_setPositionReference","domReferenceRef","externalReference","externalFloating","whileElementsMounted","setData","isPositioned","latestMiddleware","setLatestMiddleware","_reference","_setReference","_floating","_setFloating","setReference","referenceRef","setFloating","floatingRef","floatingEl","hasWhileElementsMounted","whileElementsMountedRef","platformRef","openRef","fullData","isMountedRef","floatingStyles","initialStyles","useFloating","computedPositionReference","useFocus","visibleOnly","blockFocusRef","timeoutRef","keyboardModalityRef","onBlur","pressure","detail","isVirtualPointerEvent","onMouseLeave","maxTouchPoints","movedToFocusGuard","hasAttribute","activeEl","ACTIVE_KEY","SELECTED_KEY","mergeProps","userProps","propsList","elementKey","isItem","domUserProps","_","__","validProps","propsOrGetProps","val","useInteractions","referenceDeps","floatingDeps","itemDeps","getReferenceProps","getFloatingProps","getItemProps","componentRoleToAriaRoleMap","useRole","_componentRoleToAriaR","ariaRole","referenceId","isNested","floatingProps","active","selected","commonProps","camelCaseToKebabCase","ofs","execWithArgsOrReturn","valueOrFn","useTransitionStyles","initial","unstable_initial","unstable_open","close","unstable_close","common","unstable_common","fnArgs","isNumberDuration","openDuration","closeDuration","styles","setStyles","isMounted","status","setStatus","durationMs","setIsMounted","timeout","useDelayUnmount","frame","useTransitionStatus","initialRef","closeRef","commonRef","closeStyles","commonStyles","openStyles","transitionProperty","transitionDuration","isPointInPolygon","point","polygon","isInside","j","xi","yi","xj","yj","safePolygon","buffer","blockPointerEvents","requireIntent","hasLanded","lastX","lastY","lastCursorTime","performance","onClose","clientX","clientY","clientPoint","isLeave","isOverFloatingEl","isOverReferenceEl","refRect","cursorLeaveFromRight","cursorLeaveFromBottom","isOverReferenceRect","isFloatingWider","isFloatingTaller","_ref2","rectPoly","cursorSpeed","currentTime","elapsedTime","deltaX","deltaY","distance","sqrt","getCursorSpeed","_ref3","cursorPointOne","cursorPointTwo","getPolygon","__options","createDOMMotionComponentProxy","componentFactory","Proxy","componentCache","_target","isAnimationControls","isKeyframesTarget","shallowCompare","prev","prevLength","isVariantLabel","getValueState","visualElement","getVelocity","resolveVariantFromProps","custom","velocity","variants","resolveVariant","getProps","variantPriorityOrder","variantProps","memo","supportsScrollTimeline","ScrollTimeline","BaseGroupPlaybackControls","animations","stop","runAll","finished","Promise","all","animation","getAll","propName","setAll","newValue","attachTimeline","timeline","fallback","subscriptions","speed","startTime","methodName","controls","play","pause","complete","GroupPlaybackControls","onResolve","onReject","catch","getValueTransition","maxGeneratorDuration","calcGeneratorDuration","generator","Infinity","isGenerator","onfinish","isBezierDefinition","easing","supportsFlags","linearEasing","memoSupports","supportsFlag","memoized","_a","supportsLinearEasing","progress","toFromDifference","generateLinearEasing","resolution","points","numPoints","isWaapiSupportedEasing","supportedWaapiEasing","cubicBezierAsString","linear","easeIn","easeOut","easeInOut","circIn","circOut","backIn","backOut","mapEasingToNativeEasing","segmentEasing","isDragging","isDragActive","setupGesture","elementOrSelector","resolveElements","gestureAbortController","AbortController","signal","abort","filterEvents","isNodeOrChild","isPrimaryPointer","isPrimary","focusableElements","isPressing","WeakSet","firePointerEvent","dispatchEvent","PointerEvent","isValidPressEvent","secondsToMilliseconds","seconds","millisecondsToSeconds","milliseconds","any","transformPropOrder","transformProps","positionalKeys","resolveFinalValueInKeyframes","stepsOrder","createRenderBatcher","scheduleNextBatch","allowKeepAlive","runNextFrame","useDefaultElapsed","delta","timestamp","isProcessing","flagRunNextFrame","steps","thisFrame","nextFrame","flushNextFrame","toKeepAlive","latestFrameData","triggerCallback","step","schedule","keepAlive","immediate","queue","add","delete","process","frameData","createRenderStep","read","resolveKeyframes","preRender","render","postRender","processBatch","cancelFrame","frameSteps","clearTime","newTime","addUniqueItem","arr","removeItem","splice","SubscriptionManager","notify","numSubscriptions","getSize","velocityPerSecond","frameDuration","collectMotionValues","MotionValue","canTrackVelocity","updateAndNotify","updatedAt","setPrevFrameValue","setCurrent","change","renderRequest","hasAnimated","owner","prevFrameValue","prevUpdatedAt","onChange","subscription","eventName","unsubscribe","clearListeners","eventManagers","attach","passiveEffect","stopPassiveEffect","setWithVelocity","jump","endAnimation","getPrevious","startAnimation","resolve","animationStart","animationComplete","clearAnimation","animationCancel","isAnimating","destroy","motionValue","setMotionValue","hasValue","getValue","addValue","isMotionValue","addValueToWillChange","camelToDash","optimizedAppearDataAttribute","getOptimisedAppearId","calcBezier","a1","a2","cubicBezier","mX1","mY1","mX2","mY2","lowerBound","upperBound","currentX","currentT","binarySubdivide","mirrorEasing","reverseEasing","backInOut","anticipate","pow","sin","acos","circInOut","isZeroValueString","isNone","number","alpha","sanitize","floatRegex","singleColorRegex","isColorString","testProp","isNullish","splitColor","aName","bName","cName","match","rgbUnit","clampRgbUnit","rgba","red","green","blue","alpha$1","hex","createUnitType","unit","degrees","percent","vh","vw","progressPercentage","hsla","hue","saturation","lightness","color","colorRegex","NUMBER_TOKEN","COLOR_TOKEN","complexRegex","analyseComplexValue","originalValue","indexes","var","types","parsedValue","parseComplexValue","createTransformer","numSections","convertNumbersToZero","complex","_b","getAnimatableNone","parsed","transformer","maxDefaults","applyDefaultFilter","defaultValue","functionRegex","functions","browserNumberValueTypes","borderTopWidth","borderRightWidth","borderBottomWidth","borderLeftWidth","radius","borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius","maxWidth","maxHeight","paddingRight","paddingBottom","marginTop","marginBottom","backgroundPositionX","backgroundPositionY","transformValueTypes","rotateX","rotateY","rotateZ","scaleX","scaleY","scaleZ","skewX","skewY","translateX","translateY","translateZ","perspective","transformPerspective","originX","originY","originZ","numberValueTypes","zIndex","fillOpacity","strokeOpacity","numOctaves","defaultValueTypes","backgroundColor","outlineColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","WebkitFilter","getDefaultValueType","defaultValueType","invalidTemplates","isNumOrPxType","getPosFromMatrix","matrix","getTranslateFromMatrix","pos2","pos3","_bbox","matrix3d","transformKeys","nonTranslationalTransformKeys","positionalValues","toResolve","isScheduled","anyNeedsMeasurement","measureAllKeyframes","resolversToMeasure","resolver","needsMeasurement","elementsToMeasure","transformsToRestore","removedTransforms","removeNonTranslationalTransform","measureInitialState","restore","measureEndState","suspendedScrollY","scrollTo","readAllKeyframes","readKeyframes","KeyframeResolver","unresolvedKeyframes","onComplete","isAsync","isComplete","scheduleResolve","currentValue","finalKeyframe","valueAsRead","readValue","setFinalKeyframe","renderEndStyles","resume","warning","invariant","isNumericalString","checkStringStartsWith","isCSSVariableName","startsAsVariableToken","isCSSVariableToken","singleCssVariableRegex","splitCSSVariableRegex","getVariableValue","depth","token1","token2","parseCSSVariable","resolved","getPropertyValue","trimmed","testValueType","dimensionValueTypes","findDimensionValueType","DOMKeyframesResolver","keyframe","resolveNoneKeyframes","originType","targetType","noneKeyframeIndexes","animatableTemplate","noneIndex","makeNoneKeyframesAnimatable","pageYOffset","measuredOrigin","measureViewportBox","measureKeyframe","finalKeyframeIndex","unsetTransformName","unsetTransformValue","isAnimatable","canAnimate","keyframes","originKeyframe","targetKeyframe","isOriginAnimatable","isTargetAnimatable","hasKeyframesChanged","isNotNull","getFinalKeyframe","repeatType","resolvedKeyframes","BaseAnimation","autoplay","repeatDelay","isStopped","hasAttemptedResolve","createdAt","updateFinishedPromise","calcStartTime","resolvedAt","_resolved","onKeyframesResolved","onUpdate","resolveFinishedPromise","resolvedAnimation","initPlayback","onPostResolved","reject","currentFinishedPromise","mixNumber","hueToRgb","mixImmediate","mixLinearColor","fromExpo","expo","colorTypes","asRGBA","getColorType","model","hslaToRgba","mixColor","fromRGBA","toRGBA","blended","combineFunctions","pipe","transformers","invisibleValues","getMixer","mixComplex","mixArray","mixObject","numValues","blendValue","template","originStats","targetStats","mixVisibility","orderedOrigin","pointers","originIndex","originValue","matchOrder","mixer","calcGeneratorVelocity","resolveValue","prevT","springDefaults","rootIterations","calcAngularFreq","undampedFreq","dampingRatio","durationKeys","physicsKeys","isSpringType","spring","optionsOrVisualDuration","bounce","visualDuration","restSpeed","restDelta","stiffness","damping","mass","isResolvedFromDuration","springOptions","PI","derived","envelope","derivative","exponentialDecay","exp","initialGuess","approximateRoot","findSpring","getSpringOptions","initialVelocity","initialDelta","undampedAngularFreq","isGranularScale","resolveSpring","angularFreq","cos","dampedAngularFreq","freqForT","sinh","cosh","calculatedDuration","currentVelocity","isBelowVelocityThreshold","isBelowDisplacementThreshold","inertia","power","timeConstant","bounceDamping","bounceStiffness","modifyTarget","nearestBoundary","amplitude","ideal","calcDelta","calcLatest","applyFriction","latest","timeReachedBoundary","spring$1","checkCatchBoundary","isOutOfBounds","hasUpdatedFrame","easingLookup","easingDefinitionToFunction","x1","y1","x2","y2","keyframeValues","times","easingFunctions","isEasingArray","absoluteTimes","convertOffsetToTimes","remaining","offsetProgress","fillOffset","defaultOffset","mapTimeToKeyframe","isClamp","inputLength","isZeroDeltaRange","mixers","customMixer","mixerFactory","numMixers","easingFunction","createMixers","interpolator","progressInRange","interpolate","frameloopDriver","passTimestamp","generators","decay","tween","percentToProgress","MainThreadAnimation","holdTime","cancelTime","playbackSpeed","pendingPlayState","teardown","onStop","KeyframeResolver$1","keyframes$1","generatorFactory","mapPercentToKeyframes","mirroredGenerator","resolvedDuration","totalDuration","tick","sample","timeWithoutDelay","isInDelayPhase","elapsed","frameGenerator","currentIteration","iterationProgress","isAnimationFinished","finish","driver","newSpeed","hasChanged","onPlay","stopDriver","acceleratedValues","supportsWaapi","unsupportedEasingFunctions","AcceleratedAnimation","pregeneratedAnimation","sampleAnimation","pregeneratedKeyframes","pregenerateKeyframes","valueName","keyframeOptions","iterations","startWaapiAnimation","pendingTimeline","playbackRate","playState","sampleTime","transformTemplate","underDampedSpring","keyframesTransition","getDefaultTransition","valueKey","animateMotionValue","isHandoff","valueTransition","when","_delay","delayChildren","staggerChildren","staggerDirection","isTransitionDefined","shouldSkip","shouldBlockAnimation","protectedKeys","needsAnimating","shouldBlock","animateTarget","targetAndTransition","transitionOverride","transitionEnd","animationTypeState","animationState","getState","latestValues","valueTarget","MotionHandoffAnimation","appearId","shouldReduceMotion","setTarget","animateVariant","variant","presenceContext","getAnimation","getChildAnimations","variantChildren","forwardDelay","maxStaggerDuration","generateStaggerDuration","sortByTreeOrder","animateChildren","first","last","sortNodePosition","numVariantProps","getVariantContext","isControllingVariants","reversePriorityOrder","numAnimationTypes","createAnimationState","resolvedDefinition","animateVisualElement","animateList","createState","isInitialRender","buildResolvedTypeValues","animateChanges","changedActiveType","removedKeys","encounteredKeys","removedVariantIndex","typeState","propIsVariant","activeDelta","isActive","isInherited","manuallyAnimateOnMount","prevProp","variantDidChange","checkVariantsDidChange","shouldAnimateType","handledRemovedValues","definitionList","resolvedValues","prevResolvedValues","allKeys","markToAnimate","liveStyle","valueHasChanged","blockInitialAnimation","fallbackAnimation","fallbackTarget","getBaseTarget","shouldAnimate","setActive","setAnimateFunction","makeAnimator","createTypeState","whileInView","whileHover","whileTap","whileDrag","whileFocus","exit","Feature","updateAnimationControlsSubscription","unmountControls","subscribe","mount","prevAnimate","prevProps","unmount","isPresent","onExitComplete","prevIsPresent","prevPresenceContext","exitAnimation","register","addDomEvent","extractEventInfo","pageX","pageY","addPointerEvent","addPointerInfo","PanSession","handlers","transformPagePoint","contextWindow","dragSnapToOrigin","startEvent","lastMoveEvent","lastMoveEventInfo","updatePoint","info","getPanInfo","history","isPanStarted","isDistancePastThreshold","xDelta","yDelta","distance2D","onStart","handlePointerMove","transformPoint","handlePointerUp","onEnd","onSessionEnd","resumeAnimation","panInfo","initialInfo","onSessionStart","removeListeners","updateHandlers","subtractPoint","lastDevicePoint","startDevicePoint","timeDelta","timestampedPoint","lastPoint","isRefObject","calcLength","calcAxisDelta","originPoint","calcBoxDelta","calcRelativeAxis","relative","calcRelativeAxisPosition","layout","calcRelativePosition","calcRelativeAxisConstraints","calcViewportAxisConstraints","layoutAxis","constraintsAxis","defaultElastic","resolveAxisElastic","dragElastic","minLabel","maxLabel","resolvePointElastic","createBox","eachAxis","convertBoundingBoxToBox","isIdentityScale","hasScale","hasTransform","has2DTranslate","is2DTranslate","scalePoint","applyPointDelta","boxScale","applyAxisDelta","applyBoxDelta","TREE_SCALE_SNAP_MIN","TREE_SCALE_SNAP_MAX","translateAxis","transformAxis","axisTranslate","axisScale","axisOrigin","transformBox","instance","topLeft","bottomRight","transformBoxPoints","getContextWindow","elementDragControls","WeakMap","VisualElementDragControls","openDragLock","currentDirection","constraints","hasMutatedConstraints","elastic","originEvent","snapToCursor","panSession","pauseAnimation","stopAnimation","drag","dragPropagation","onDragStart","resolveConstraints","projection","isAnimationBlocked","getAxisMotionValue","measuredAxis","layoutBox","dragDirectionLock","onDirectionLock","onDrag","lockThreshold","getCurrentDirection","updateAxis","getAnimationState","getTransformPagePoint","onDragEnd","_point","shouldDrag","axisValue","applyConstraints","dragConstraints","measure","prevConstraints","resolveRefConstraints","calcRelativeConstraints","resolveDragElastic","relativeConstraints","rebaseAxisConstraints","onMeasureDragConstraints","constraintsElement","constraintsBox","rootProjectionNode","viewportBox","measurePageBox","measuredConstraints","calcViewportConstraints","userConstraints","convertBoxToBoundingBox","dragMomentum","dragTransition","onDragTransitionEnd","momentumAnimations","startAxisValueAnimation","dragKey","toUpperCase","scalePositionWithinConstraints","boxProgress","sourceLength","targetLength","calcOrigin","updateScroll","updateLayout","addListeners","stopPointerListener","dragListener","measureDragConstraints","stopMeasureLayoutListener","stopResizeListener","stopLayoutUpdateListener","hasLayoutChanged","asyncHandler","PresenceContext","createContext","usePresence","useContext","safeToRemove","useCallback","LayoutGroupContext","SwitchLayoutGroupContext","globalProjectionState","hasAnimatedSinceResize","hasEverUpdated","pixelsToPercent","pixels","correctBorderRadius","correct","correctBoxShadow","treeScale","projectionDelta","original","xScale","yScale","averageScale","scaleCorrectors","microtask","cancelMicrotask","MeasureLayoutWithContext","Component","componentDidMount","layoutGroup","switchLayoutGroup","layoutId","correctors","defaultScaleCorrectors","didUpdate","setOptions","getSnapshotBeforeUpdate","layoutDependency","willUpdate","promote","relegate","stack","getStack","members","componentDidUpdate","currentAnimation","isLead","componentWillUnmount","promoteContext","scheduleCheckAfterUnmount","deregister","MeasureLayout","applyTo","boxShadow","compareByDepth","FlatTree","isDirty","resolveMotionValue","unwrappedValue","isCustomValue","borders","numBorders","asNumber","isPx","getRadius","radiusName","easeCrossfadeIn","compress","easeCrossfadeOut","copyAxisInto","originAxis","copyBoxInto","originBox","copyAxisDeltaInto","originDelta","removePointDelta","removeAxisTransforms","transforms","scaleKey","originKey","sourceAxis","removeAxisDelta","xKeys","yKeys","removeBoxTransforms","sourceBox","isAxisDeltaZero","isDeltaZero","axisEquals","axisEqualsRounded","boxEqualsRounded","aspectRatio","axisDeltaEquals","NodeStack","scheduleRender","prevLead","lead","indexOfNode","findIndex","member","preserveFollowOpacity","show","resumeFrom","preserveOpacity","snapshot","animationValues","isUpdating","isLayoutDirty","crossfade","hide","exitAnimationComplete","resumingFrom","removeLeadSnapshot","metrics","totalNodes","resolvedTargetDeltas","recalculatedProjection","isDebug","MotionDebug","transformAxes","hiddenVisibility","resetDistortingTransform","sharedAnimationValues","setStaticValue","cancelTreeOptimisedTransformAnimations","projectionNode","hasCheckedOptimisedAppear","MotionHasOptimisedAnimation","MotionCancelOptimisedAnimation","createProjectionNode","attachResizeListener","defaultParent","measureScroll","checkIsScrollRoot","resetTransform","animationId","isTreeAnimating","isProjectionDirty","isSharedProjectionDirty","isTransformDirty","updateManuallyBlocked","updateBlockedByResize","isSVG","needsReset","shouldResetTransform","eventHandlers","hasTreeAnimated","updateScheduled","scheduleUpdate","projectionUpdateScheduled","checkUpdateFailed","clearAllSnapshots","updateProjection","propagateDirtyNodes","resolveTargetDelta","calcProjection","cleanDirtyNodes","record","resolvedRelativeTargetAt","hasProjected","isVisible","animationProgress","sharedNodes","notifyListeners","subscriptionManager","hasListeners","SVGElement","cancelDelay","resizeUnblockUpdate","checkElapsed","finishAnimation","registerSharedNode","hasRelativeTargetChanged","newLayout","isTreeAnimationBlocked","relativeTarget","layoutTransition","defaultLayoutTransition","onLayoutAnimationStart","onLayoutAnimationComplete","targetChanged","targetLayout","hasOnlyRelativeTargetChanged","layoutRoot","setAnimationOrigin","animationOptions","blockUpdate","unblockUpdate","isUpdateBlocked","startUpdate","resetSkewAndRotation","getTransformTemplate","shouldNotifyListeners","prevTransformTemplateValue","updateSnapshot","clearMeasurements","clearIsLayoutDirty","resetTransformStyle","notifyLayoutUpdate","clearSnapshot","removeLeadSnapshots","scheduleUpdateProjection","alwaysMeasureLayout","prevLayout","layoutCorrected","phase","layoutScroll","isRoot","wasRoot","isResetRequested","hasProjection","transformTemplateValue","transformTemplateHasChanged","removeTransform","pageBox","removeElementScroll","roundAxis","measuredBox","checkNodeWasScrollRoot","boxWithoutScroll","applyTransform","transformOnly","withTransforms","boxWithoutTransform","setTargetDelta","targetDelta","forceRelativeParentToResolveTarget","relativeParent","forceRecalculation","getLead","isShared","attemptToResolveRelativeTarget","getClosestProjectingParent","relativeTargetOrigin","targetWithTransforms","isProjecting","canSkip","pendingAnimation","prevTreeScaleX","prevTreeScaleY","treePath","isSharedTransition","treeLength","applyTreeDeltas","prevProjectionDelta","createProjectionDeltas","notifyAll","projectionDeltaWithTransform","snapshotLatestValues","mixedValues","relativeLayout","isSharedLayoutAnimation","isOnlyMember","shouldCrossfadeOpacity","hasOpacityCrossfade","prevRelativeTarget","mixTargetDelta","mixAxisDelta","mixAxis","mixBox","boxEquals","follow","opacityExit","borderLabel","followRadius","leadRadius","mixValues","motionValue$1","animateSingleValue","completeAnimation","applyTransformsToTarget","shouldAnimatePositionOnly","animationType","xLength","yLength","initialPromotionConfig","shouldPreserveFollowOpacity","getPrevLead","hasDistortingTransform","resetValues","getProjectionStyles","styleProp","emptyStyles","valuesToRender","latestTransform","xTranslate","yTranslate","zTranslate","elementScaleX","elementScaleY","buildProjectionTransform","transformOrigin","corrected","num","resetTree","measuredLayout","axisSnapshot","layoutDelta","visualDelta","parentSnapshot","parentLayout","relativeSnapshot","onBeforeLayoutMeasure","userAgentContains","roundPoint","DocumentProjectionNode","HTMLProjectionNode","documentNode","pan","removePointerDownListener","pointerDownEvent","session","createPanHandlers","onPanSessionStart","onPanStart","onPan","onPanEnd","removeGroupControls","dragControls","ProjectionNode","handleHoverEvent","lifecycle","handlePressEvent","observerCallbacks","observers","fireObserverCallback","entry","fireAllObserverCallbacks","thresholdNames","gestureAnimations","inView","hasEnteredView","isInView","startObserver","viewport","amount","once","rootInteresectionObserver","lookupRoot","rootObservers","JSON","initIntersectionObserver","observeIntersection","isIntersecting","onViewportEnter","onViewportLeave","prevViewport","hasViewportOptionChanged","tap","onPressStart","eventOptions","cancelEvents","startPress","onPressEnd","onPointerEnd","endEvent","success","onPointerUp","onPointerCancel","upEvent","useGlobalTarget","cancelEvent","isElementKeyboardAccessible","focusEvent","handleKeydown","handleKeyup","enableKeyboardPress","press","globalTapTarget","isFocusVisible","hover","onHoverStart","onPointerEnter","enterEvent","onHoverEnd","onPointerLeave","leaveEvent","LazyContext","MotionConfigContext","isStatic","reducedMotion","MotionContext","isVariantNode","variantLabelsAsDependency","isBrowser","featureProps","featureDefinitions","isEnabled","motionComponentSymbol","useMotionRef","visualState","externalRef","onMount","useIsomorphicLayoutEffect","useVisualElement","createVisualElement","ProjectionNodeConstructor","lazyContext","reducedMotionConfig","visualElementRef","renderer","initialLayoutGroupConfig","getClosestProjectingNode","optimisedAppearId","wantsHandoff","MotionHandoffIsComplete","MotionIsMounted","updateFeatures","MotionHandoffMarkAsComplete","allowProjection","createRendererMotionComponent","preloadedFeatures","useRender","useVisualState","MotionComponent","configAndProps","useLayoutId","inherit","getCurrentTreeVariants","useMemo","useCreateMotionContext","layoutProjection","combined","getProjectionFunctionality","features","loadFeatures","ForwardRefMotionComponent","forwardRef","layoutGroupId","lowercaseSVGElements","isSVGComponent","useConstant","makeUseVisualState","make","scrapeMotionValuesFromProps","createRenderState","makeLatestValues","renderState","makeState","scrapeMotionValues","motionValues","isControllingVariants$1","isVariantNode$1","isInitialAnimationBlocked","variantToSet","getValueAsType","translateAlias","numTransforms","buildHTMLStyles","vars","hasTransformOrigin","valueAsType","transformString","transformIsDefault","valueIsDefault","buildTransform","dashKeys","array","camelKeys","buildSVGAttrs","attrX","attrY","attrScale","pathLength","pathSpacing","pathOffset","isSVGTag","attrs","dimensions","calcSVGTransformOrigin","useDashCase","buildSVGPath","tag","renderHTML","setProperty","camelCaseAttributes","renderSVG","_styleProp","isForcedMotionValue","newValues","charAt","layoutProps","svgMotionConfig","needsMeasure","getBBox","updateSVGDimensions","htmlMotionConfig","copyRawValuesOnly","useHTMLProps","htmlProps","useInitialMotionValues","useStyle","draggable","userSelect","WebkitUserSelect","WebkitTouchCallout","touchAction","onTap","onTapStart","validMotionProps","isValidMotionProp","shouldForward","isValidProp","require","useSVGProps","_isStatic","visualProps","rawStyles","createUseRender","forwardMotionProps","filteredProps","isDom","filterProps","elementProps","renderedChildren","createMotionComponentFactory","prefersReducedMotion","hasReducedMotionListener","valueTypes","visualElementStore","propEventHandlers","VisualElement","_props","_prevProps","_visualElement","valueSubscriptions","prevMotionValues","propEventSubscriptions","notifyUpdate","triggerBuild","renderInstance","renderScheduledAt","baseTarget","initialValues","initialMotionValues","removeFromVariantTree","addVariantChild","bindToMotionValue","matchMedia","motionMediaQuery","setReducedMotionPreferences","addListener","initPrefersReducedMotion","feature","valueIsTransform","removeOnChange","latestValue","removeOnRenderRequest","removeSyncCheck","MotionCheckAppearSync","sortInstanceNodePosition","featureDefinition","FeatureConstructor","build","measureInstanceViewportBox","getStaticValue","nextValue","prevValue","existingValue","removeValue","updateMotionValuesFromProps","handleChildMotionValue","getVariant","getClosestVariantNode","closestVariantNode","removeValueFromRenderState","getBaseTargetFromProps","readValueFromInstance","findValueType","setBaseTarget","valueFromInitial","DOMVisualElement","compareDocumentPosition","childSubscription","textContent","HTMLVisualElement","defaultType","SVGVisualElement","motion","PopChildMeasure","childRef","sizeRef","PopChild","nonce","motionPopId","head","sheet","insertRule","removeChild","PresenceChild","presenceAffectsLayout","presenceChildren","newChildrenMap","memoizedOnExitComplete","childId","getChildKey","onlyElements","filtered","Children","isValidElement","AnimatePresence","propagate","isParentPresent","presentChildren","presentKeys","pendingPresentChildren","exitComplete","diffedChildren","setDiffedChildren","useState","setRenderedChildren","exitingChildren","nextChildren","forceRender","isEveryExitComplete","isExitComplete","mergeClasses","defaultAttributes","xmlns","strokeLinecap","strokeLinejoin","Icon","absoluteStrokeWidth","iconNode","createLucideIcon","iconName","ChevronDown","C","N","M","heading","showArrowOnHover","onMouseEnter","visible","hidden","closed","ul","I","solid","dashed","dotted","double","none","List","Separator","S","E","F","R","L","T","W","A","handleClose","toArray","D","P","as","Trigger","Content","Portal","ContentWrapper","X","icon","closable","disableHover","neutral","yellow","inverse","pill","CircleHelp","cx","cy","FileText","Headset","User","routes","dashboard","widgets","settings","headerFooterBuilder","onboarding","_typeof","toPropertyKey","toPrimitive","String","_defineProperties","configurable","writable","_getPrototypeOf","setPrototypeOf","_setPrototypeOf","_defineProperty","Action","locationToRoute","location","pathname","hash","qs","search","BeforeUnloadEventType","promptBeforeUnload","returnValue","createEvents","_options$window","globalHistory","getIndexAndLocation","_window$location","idx","usr","blockedPopTx","blockers","nextAction","Pop","_getIndexAndLocation","nextLocation","action","retry","go","applyTx","_getIndexAndLocation2","listeners","createHref","_ref$pathname","_ref$search","_ref$hash","getNextLocation","parsedPath","hashIndex","substr","searchIndex","parsePath","getHistoryStateAndUrl","allowTx","_getIndexAndLocation3","replaceState","Push","_getHistoryStateAndUr","historyState","url","pushState","Replace","_getHistoryStateAndUr2","back","forward","listen","block","blocker","unblock","createBrowserHistory","RouterContext","wp","route","Route","onRoute","matched","checkMatch","React","cloneElement","Link","activeClassName","_objectSpread","uaelSettingsData","header_footer_builder","href","currentHash","changeSearch","newSearch","uaepro_settings_url","Router","_Component","_this","_classCallCheck","ReferenceError","_callSuper","localStorage","setItem","setState","unlisten","handleRouteChange","defaultRoute","_inherits","_createClass","_this$props","_this$state","NotFound","isMatched","routerContextValue","is404","__awaiter","_arguments","fulfilled","rejected","WhatsNewRSSDefaultArgs","rssFeedURL","uniqueKey","loaderIcon","viewAll","link","triggerButton","beforeBtn","afterBtn","notification","setLastPostUnixTime","getLastPostUnixTime","flyout","title","innerContent","titleLink","additionalClasses","excerpt","wordLimit","moreSymbol","readMore","closeOnEsc","closeOnOverlayClick","closeBtnIcon","formatDate","onOpen","onReady","WhatsNewRSS","rssFeedURLs","lastPostUnixTime","multiLastPostUnixTime","notificationsCount","multiNotificationCount","hasNewFeeds","multiHasNewFeeds","validateArgs","parseDefaults","setElement","getElement","setID","setRSSFeedURLs","WhatsNewRSSCacheUtils","setInstanceID","getID","RSS_Fetch_Instance","WhatsNewRSSFetch","RSS_View_Instance","WhatsNewRSSView","setNotificationsCount","setTriggers","warn","getArgs","requiredArg","querySelector","_rssFeedURL","ID","btoa","isMultiFeedRSS","_item","getRSSFeedURLs","fetchData","res","currentPostUnixTime","date","setNotification","getNotificationsCount","getTriggerButtonID","getFlyoutID","flyoutInner","flyoutCloseBtn","getFlyoutCloseBtnID","multiFeedNav","getFlyoutMultiFeedNavID","injectContents","innerHTML","isNewPost","contentTitle","postLink","createExcerpt","description","listChildrenPosts","innerContentWrapper","setIsLoading","scrollBarWidth","innerWidth","styleSheet","cssRules","navBtns","navBtn","setMultiFeedTabNotificationCount","feedKey","currentFeedKey","innerContentClassName","handleFlyoutClose","instanceID","prefixer","prefixKey","_setDataExpiry","expiry","getTime","sessionStorage","_isDataExpired","getItem","setSessionData","getSessionData","unixTime","SESSION_DATA_EXPIRY","LAST_LATEST_POST","SESSION","RSS","feed","sessionCache","fetchPromises","fetch","DOMParser","parseFromString","contentEncoded","rssDate","createTriggerButton","createFlyOut","isLoading","flyoutWrapper","notificationBadge","wrapperClasses","notificationCount","tabBtn","_count","readMoreLink","words","rawExcerpt","_children","details","summary","itemsWrapper","postContentDoc","post_content","itemDiv","post_title","post_date","outerHTML","currentDate","difference","hour","minute","day","week","month","minutes","hours","days","weeks","months","updateNavMenuActiveState","currentPath","parentLi","itemText","NavMenu","_useState2","isDropdownOpen","setIsDropdownOpen","_useState4","isHelpOpen","setIsHelpOpen","handleClickOutside","linkStyle","borderBottom","handleRedirect","instanceRef","styleId","getCSS","addStyleIfNotExists","useWhatsNewRSS","dayOfWeek","toLocaleDateString","weekday","getDate","year","getFullYear","Topbar","icon_url","src","alt","is_lite_active","DropdownMenu","isOpen","Badge","uaelite_current_version","core_badge","uael_current_version","pro_badge","hide_settings","column","normal","between","around","evenly","stretch","baseline","auto","wrap","nowrap","B","cols","gapX","gapY","gridFlow","colsSubGrid","rowsSubGrid","autoRows","autoCols","colSpan","colStart","alignSelf","justifySelf","iconPosition","Title","required","help","switchId","htmlFor","bytes","crypto","getRandomValues","Uint8Array","primary","toggleDial","Info","Check","TriangleAlert","Trash2","destructive","loading","secondary","ghost","actionType","onAction","actionLabel","inline","light","dark","ie","setOpen","tooltipPortalRoot","tooltipPortalId","triggers","interactive","mouseOnly","restMs","move","handleCloseRef","delayRef","handlerRef","restTimeoutRef","blockMouseMoveRef","performedPointerEventsMutationRef","unbindMouseMoveRef","restTimeoutPendingRef","isHoverOpen","_dataRef$current$open","onLeave","closeWithDelay","runElseBranch","closeDelay","cleanupMouseMoveHandler","clearPointerEvents","isClickLikeOpenEvent","_elements$floating","onScrollMouseLeave","_elements$floating2","openDelay","_handleCloseRef$curre","_tree$nodesRef$curren","parentFloating","setPointerRef","onMouseMove","handleMouseMove","movementX","movementY","H","O","requestQueue","processQueue","currentRequest","widget","updateCounter","showTooltip","is_pro","infoText","demo_url","is_active","slug","doc_url","setIsActive","apiCall","activateWidget","formData","FormData","append","ajax_nonce","apiFetch","ajax_url","method","Container","fontSize","Switch","rel","textDecoration","lineHeight","Tooltip","InfoIcon","setLoading","setTemplatesStatus","_useState6","setRedirectUrl","headers","uael_nonce_action","templates_status","redirect_url","templates_url","Button","Headphones","NotepadText","rx","HelpCircle","Plus","plugin_short_name","uael_hfe_post_url","elementor_page_url","background","frameBorder","allow","allowFullScreen","asyncGeneratorStep","_asyncToGenerator","_next","_throw","trigger","exitOnClickOutside","V","exitOnEsc","design","K","scrollLock","U","dialogContainerRef","dialogRef","div","ee","Panel","Description","CloseButton","Header","Body","Footer","Backdrop","plugin","setUpdateCounter","siteUrl","zipUrl","desc","wporg","isFree","settings_url","isDialogOpen","setIsDialogOpen","pluginData","setPluginData","activatePlugin","buttonElement","spanElement","innerText","Dialog","siteurl","currentPluginData","pluginname","installer_nonce","errorCode","today","toISOString","URLSearchParams","target_plugin","response","json","callAnalyticsWebhook","alert","getAction","circular","rectangular","plugins","setPlugins","_useState8","allInstalled","setAllInstalled","convertToPluginsArray","fetchSettings","_regeneratorRuntime","_callee","pluginsData","areAllInstalled","_t","_context","sent","is_installed","_toConsumableArray","Skeleton","ExtendWebsiteWidget","ChevronLeft","ChevronRight","videoData","videoId","VideoThumbnail","playingVideoId","setPlayingVideoId","isPlaying","video_control","VideoTutorials","currentIndex","setCurrentIndex","video","BadgeCheck","Settings2","FolderKanban","Wrench","tab","setting","handleRouteRedirect","handleTabRedirect","publish","dismiss","seal","getHistory","toastItem","autoDismiss","dismissAfter","removeToast","singleTon","li","LoaderCircle","LockOpen","ry","licenseKey","setlicenseKey","errorMessage","setErrorMessage","licenseStatus","license_status","licensePlaceholder","isWhiteLabel","is_whitelabel","Toaster","sprintf","readOnly","minWidth","license_deactivation_nonce","toast","reload","license_activation_nonce","width_class","HeaderLine","WelcomeContainer","QuickSettings","ExtendWebsite","TemplateSection","QuickAccess","License","Search","allWidgetsData","setAllWidgetsData","searchTerm","setSearchTerm","loadingActivate","setLoadingActivate","loadingDeactivateUnused","setLoadingDeactivateUnused","_useState0","loadingDeactivate","setLoadingDeactivate","_useState10","_useState12","_useState14","widgetsData","keywords","title_url","is_activate","convertToWidgetsArray","filteredWidgets","_widget$keywords","keyword","handleActivateAll","prevWidgets","handleDeactivateUnused","_callee2","_context2","_data$data","deactivated","deactivatedSlugs","handleDeactivateAll","_callee3","_context3","SearchIcon","Trash2Icon","minHeight","WidgetItem","FeatureWidgets","onSelectItem","selectedItemId","main","handleSelectItem","badge","fontWeight","letterSpacing","selectedItem","charCodeAt","raw","_goober","__nonce__","firstChild","Z","toastLimit","toasts","toastId","dismissed","pausedAt","pauseDuration","Y","se","blank","ariaProps","toasterId","Q","dismissAll","removeAll","promise","de","le","Te","ge","he","be","Se","Ae","Pe","iconTheme","Re","Ee","Oe","Ie","ke","we","onHeightUpdate","MutationObserver","subtree","childList","characterData","Ce","Fe","reverseOrder","toastOptions","gutter","containerStyle","containerClassName","removeDelay","defaultPosition","updateHeight","startPause","endPause","calculateOffset","justifyContent","Me","zt","radioData","theme_option","selectedOption","setSelectedOption","isInitialLoad","setIsInitialLoad","handleRadioChange","saveOption","option","hfe_compatibility_option","_x","Label","betaEnabled","setBetaEnabled","previousAddonVersions","uael_versions","previousLiteVersions","uaelite_versions","proVersionRef","liteVersionRef","previousVersionSelect","setPreviousVersion","liteVersionSelect","setLiteVersionSelect","setProductSelect","setFreeproductSelect","openPopup","setOpenPopup","openLitePopup","setOpenLitePopup","beta_enabled","rollbackUrl","uaelite_rollback_url","plugin_name","uael_rollback_url","allow_beta","analytics_status","handleSwitchChange","newIsActive","uae_usage_optin","UsageTracking","RefreshCcw","google_api","developer_mode","language","google_places_api","yelp_api","recaptcha_v3_key","recaptcha_v3_secretkey","recaptcha_v3_score","google_client_id","facebook_app_id","facebook_app_secret","uael_share_button","uael_maxmind_geolocation_license_key","uael_maxmind_geolocation_db_path","uael_twitter_feed_consumer_key","uael_twitter_feed_consumer_secret","instagram_app_id","instagram_app_secret","instagram_app_token","cloudflare_turnstile_site_key","cloudflare_turnstile_secret_key","setSettings","setError","setSuccessMessage","isSaving","setIsSaving","tokenRefresh","setTokenRefresh","maxmindStatus","setMaxmindStatus","languagesData","uaeLanguagesData","debouncedValidateApi","debounce","apiKey","api_type","handleChange","prevSettings","Loader","onSubmit","maxmind_status","uael_domain","code","maxmind_db_path","access_token","author","author_url","short_name","hide_branding","logo_url","internal_help_links","replace_logo","agency","dataToSend","ok","image","PostWidgetItem","RotateCw","Sun","FilePenLine","Server","Clock","Copy","ExternalLink","Sparkles","Lock","Card","CardHead","HeaderBadge","_ref3$tone","tone","dot","_ref3$dotClass","dotClass","Chip","_ref4","_ref4$tone","McpAdapterNotice","AlertTriangle","ToggleRow","_ref8","emphasized","locked","_ref8$switchSize","switchSize","TabButton","_ref9","FilterChip","_ref0","ScopeBtn","_ref1","TypeTag","_ref10","readonly","_initialSettings$enab","_initialSettings$allo","_initialSettings$dedi","_initialSettings$angi","_initialSettings$disa","initialSettings","mcp_settings","isAbilitiesApiActive","is_abilities_api_active","isMcpAdapterActive","is_mcp_adapter_active","isAngieActive","is_angie_active","site_url","currentUser","current_user","restUrl","rest_url","appPasswordUrl","application_passwords_url","enable_abilities","allow_modifications","dedicated_server","angie_enabled","disabled_abilities","settingsRef","setSaving","abilities","setAbilities","expandedGroups","setExpandedGroups","pageTab","setPageTab","scopeTab","setScopeTab","copied","setCopied","promptCopied","setPromptCopied","_useState16","searchQuery","setSearchQuery","_useState18","filterMode","setFilterMode","namespaceLabels","namespaceDescriptions","groupedAbilities","groups","ability","cat","category","readCount","writeCount","isAbilityEnabled","enabledCount","isGroupOn","saveChainRef","lastSavedRef","saveSeqRef","doSave","_ref5","restored","_x2","saveSettings","handleToggle","updated","siteHostname","URL","hostname","isUaeOnly","serverName","serverUrl","mcpServerEntry","command","env","WP_API_URL","WP_API_USERNAME","WP_API_PASSWORD","mcpConfig","mcpServers","serverEntryJson","aiPrompt","matchesFilter","mcpOn","editOn","angieOn","progressPct","defaults","clipboard","writeText","allOpen","_ref6","_ref7","onCount","groupEnabledCount","groupNames","handleGroupToggle","handleAbilityToggle","user_url","user__selected_url","MyAccount","theme_url","theme__selected_url","ThemeSupport","version_url","version__selected_url","VersionControl","branding_url","branding__selected_url","Branding","integrations_url","integrations__selected_url","Integrations","postskins_url","postskins_selected_url","PostSkins","ai_tools_url","ai_tools__selected_url","AITools","show_theme_support","savedItemId","setSelectedItem","itemId","onSettingsTabClick","Sidebar","numberIcon","currentStep","lineClassName","completedVariant","completedIcon","isCompleted","isCurrent","sizeClasses","isLast","labelText","Step","ArrowRight","borderRight","setCurrentStep","markStepCompleted","markStepSkipped","OnboardingWidgets","handleBackButton","WidgetsOnboarding","component","welcome_banner","FeatureWidgetsOnboarding","saveOnboardingAnalytics","stepsCompleted","stepsSkipped","setEmail","user_email","completed","skipped","exitedEarly","exitAtStep","completedSteps","skippedSteps","textAlign","build_banner","stepNames","_steps","_React$useState2","savedStep","stepName","timer","StepComponent","uae_logo","ProgressSteps","OB","_routes$dashboard","loaded","setLoaded","Dashboard","Onboarding","Features","Settings","onhashchange","CustomRouter","domReady","rootElement","App","is_hfe_post","navMenuElement","newDiv"],"sourceRoot":""}