@sledge-app/react-instant-search 0.0.80 → 0.0.82
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/ProductFilterWidget/ProductFilterWidget.d.ts +1 -1
- package/dist/components/ProductFilterWidget/ProductFilterWidget.d.ts.map +1 -1
- package/dist/components/ProductFilterWidget/ProductFilterWidgetInitSelector.d.ts.map +1 -1
- package/dist/components/SearchIconWidget/SearchIconWidgetInitSelector.d.ts.map +1 -1
- package/dist/components/SearchIconWidget/SearchIconWidgetPopup.d.ts.map +1 -1
- package/dist/components/SearchResultWidget/SearchResultWidget.d.ts +1 -0
- package/dist/components/SearchResultWidget/SearchResultWidget.d.ts.map +1 -1
- package/dist/components/SearchResultWidget/SearchResultWidgetInitSelector.d.ts.map +1 -1
- package/dist/components/SearchWidget/SearchWidget.d.ts.map +1 -1
- package/dist/components/SearchWidget/SearchWidgetInitSelector.d.ts.map +1 -1
- package/dist/sledge-react-instant-search.cjs +1 -1
- package/dist/sledge-react-instant-search.cjs.map +1 -1
- package/dist/sledge-react-instant-search.js +149 -99
- package/dist/sledge-react-instant-search.js.map +1 -1
- package/dist/vendor-024ba8ae.cjs +2 -0
- package/dist/vendor-024ba8ae.cjs.map +1 -0
- package/dist/{vendor-eeee87f8.js → vendor-90dfd914.js} +18 -637
- package/dist/vendor-90dfd914.js.map +1 -0
- package/package.json +1 -1
- package/dist/vendor-b4f78627.cjs +0 -2
- package/dist/vendor-b4f78627.cjs.map +0 -1
- package/dist/vendor-eeee87f8.js.map +0 -1
package/dist/vendor-b4f78627.cjs
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";const e=require("react"),t=require("react-dom");function n(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const n in e)if("default"!==n){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}return t.default=e,Object.freeze(t)}const r=n(e),o=n(t);function i(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var s,a={exports:{}},l={};var c,u={};"production"===process.env.NODE_ENV?a.exports=function(){if(s)return l;s=1;var t=e,n=Symbol.for("react.element"),r=Symbol.for("react.fragment"),o=Object.prototype.hasOwnProperty,i=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,r){var s,l={},c=null,u=null;for(s in void 0!==r&&(c=""+r),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)o.call(t,s)&&!a.hasOwnProperty(s)&&(l[s]=t[s]);if(e&&e.defaultProps)for(s in t=e.defaultProps)void 0===l[s]&&(l[s]=t[s]);return{$$typeof:n,type:e,key:c,ref:u,props:l,_owner:i.current}}return l.Fragment=r,l.jsx=c,l.jsxs=c,l}():a.exports=(c||(c=1,"production"!==process.env.NODE_ENV&&function(){var t=e,n=Symbol.for("react.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),m=Symbol.for("react.offscreen"),v=Symbol.iterator,g="@@iterator",y=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function b(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];!function(e,t,n){var r=y.ReactDebugCurrentFrame.getStackAddendum();""!==r&&(t+="%s",n=n.concat([r]));var o=n.map((function(e){return String(e)}));o.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,o)}("error",e,n)}var w,x=!1,E=!1,S=!1,P=!1,C=!1;function T(e){return e.displayName||"Context"}function R(e){if(null==e)return null;if("number"==typeof e.tag&&b("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),"function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case o:return"Fragment";case r:return"Portal";case s:return"Profiler";case i:return"StrictMode";case d:return"Suspense";case f:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case l:return T(e)+".Consumer";case a:return T(e._context)+".Provider";case c:return function(e,t,n){var r=e.displayName;if(r)return r;var o=t.displayName||t.name||"";return""!==o?n+"("+o+")":n}(e,e.render,"ForwardRef");case p:var t=e.displayName||null;return null!==t?t:R(e.type)||"Memo";case h:var n=e,u=n._payload,m=n._init;try{return R(m(u))}catch(v){return null}}return null}w=Symbol.for("react.module.reference");var A,O,D,k,_,L,M,I=Object.assign,V=0;function $(){}$.__reactDisabledLog=!0;var N,F=y.ReactCurrentDispatcher;function j(e,t,n){if(void 0===N)try{throw Error()}catch(o){var r=o.stack.trim().match(/\n( *(at )?)/);N=r&&r[1]||""}return"\n"+N+e}var B,W=!1,H="function"==typeof WeakMap?WeakMap:Map;function U(e,t){if(!e||W)return"";var n,r=B.get(e);if(void 0!==r)return r;W=!0;var o,i=Error.prepareStackTrace;Error.prepareStackTrace=void 0,o=F.current,F.current=null,function(){if(0===V){A=console.log,O=console.info,D=console.warn,k=console.error,_=console.group,L=console.groupCollapsed,M=console.groupEnd;var e={configurable:!0,enumerable:!0,value:$,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}V++}();try{if(t){var s=function(){throw Error()};if(Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(s,[])}catch(h){n=h}Reflect.construct(e,[],s)}else{try{s.call()}catch(h){n=h}e.call(s.prototype)}}else{try{throw Error()}catch(h){n=h}e()}}catch(m){if(m&&n&&"string"==typeof m.stack){for(var a=m.stack.split("\n"),l=n.stack.split("\n"),c=a.length-1,u=l.length-1;c>=1&&u>=0&&a[c]!==l[u];)u--;for(;c>=1&&u>=0;c--,u--)if(a[c]!==l[u]){if(1!==c||1!==u)do{if(c--,--u<0||a[c]!==l[u]){var d="\n"+a[c].replace(" at new "," at ");return e.displayName&&d.includes("<anonymous>")&&(d=d.replace("<anonymous>",e.displayName)),"function"==typeof e&&B.set(e,d),d}}while(c>=1&&u>=0);break}}}finally{W=!1,F.current=o,function(){if(0==--V){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:I({},e,{value:A}),info:I({},e,{value:O}),warn:I({},e,{value:D}),error:I({},e,{value:k}),group:I({},e,{value:_}),groupCollapsed:I({},e,{value:L}),groupEnd:I({},e,{value:M})})}V<0&&b("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}(),Error.prepareStackTrace=i}var f=e?e.displayName||e.name:"",p=f?j(f):"";return"function"==typeof e&&B.set(e,p),p}function z(e,t,n){if(null==e)return"";if("function"==typeof e)return U(e,!(!(r=e.prototype)||!r.isReactComponent));var r;if("string"==typeof e)return j(e);switch(e){case d:return j("Suspense");case f:return j("SuspenseList")}if("object"==typeof e)switch(e.$$typeof){case c:return U(e.render,!1);case p:return z(e.type,t,n);case h:var o=e,i=o._payload,s=o._init;try{return z(s(i),t,n)}catch(a){}}return""}B=new H;var Y=Object.prototype.hasOwnProperty,K={},X=y.ReactDebugCurrentFrame;function q(e){if(e){var t=e._owner,n=z(e.type,e._source,t?t.type:null);X.setExtraStackFrame(n)}else X.setExtraStackFrame(null)}var G=Array.isArray;function Z(e){return G(e)}function J(e){return""+e}function Q(e){if(function(e){try{return J(e),!1}catch(t){return!0}}(e))return b("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",function(e){return"function"==typeof Symbol&&Symbol.toStringTag&&e[Symbol.toStringTag]||e.constructor.name||"Object"}(e)),J(e)}var ee,te,ne,re=y.ReactCurrentOwner,oe={key:!0,ref:!0,__self:!0,__source:!0};ne={};var ie=function(e,t,r,o,i,s,a){var l={$$typeof:n,type:e,key:t,ref:r,props:a,_owner:s,_store:{}};return Object.defineProperty(l._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(l,"_self",{configurable:!1,enumerable:!1,writable:!1,value:o}),Object.defineProperty(l,"_source",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.freeze&&(Object.freeze(l.props),Object.freeze(l)),l};function se(e,t,n,r,o){var i,s={},a=null,l=null;for(i in void 0!==n&&(Q(n),a=""+n),function(e){if(Y.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return void 0!==e.key}(t)&&(Q(t.key),a=""+t.key),function(e){if(Y.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return void 0!==e.ref}(t)&&(l=t.ref,function(e,t){if("string"==typeof e.ref&&re.current&&t&&re.current.stateNode!==t){var n=R(re.current.type);ne[n]||(b('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',R(re.current.type),e.ref),ne[n]=!0)}}(t,o)),t)Y.call(t,i)&&!oe.hasOwnProperty(i)&&(s[i]=t[i]);if(e&&e.defaultProps){var c=e.defaultProps;for(i in c)void 0===s[i]&&(s[i]=c[i])}if(a||l){var u="function"==typeof e?e.displayName||e.name||"Unknown":e;a&&function(e,t){var n=function(){ee||(ee=!0,b("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};n.isReactWarning=!0,Object.defineProperty(e,"key",{get:n,configurable:!0})}(s,u),l&&function(e,t){var n=function(){te||(te=!0,b("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};n.isReactWarning=!0,Object.defineProperty(e,"ref",{get:n,configurable:!0})}(s,u)}return ie(e,a,l,o,r,re.current,s)}var ae,le=y.ReactCurrentOwner,ce=y.ReactDebugCurrentFrame;function ue(e){if(e){var t=e._owner,n=z(e.type,e._source,t?t.type:null);ce.setExtraStackFrame(n)}else ce.setExtraStackFrame(null)}function de(e){return"object"==typeof e&&null!==e&&e.$$typeof===n}function fe(){if(le.current){var e=R(le.current.type);if(e)return"\n\nCheck the render method of `"+e+"`."}return""}ae=!1;var pe={};function he(e,t){if(e._store&&!e._store.validated&&null==e.key){e._store.validated=!0;var n=function(e){var t=fe();if(!t){var n="string"==typeof e?e:e.displayName||e.name;n&&(t="\n\nCheck the top-level render call using <"+n+">.")}return t}(t);if(!pe[n]){pe[n]=!0;var r="";e&&e._owner&&e._owner!==le.current&&(r=" It was passed a child from "+R(e._owner.type)+"."),ue(e),b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',n,r),ue(null)}}}function me(e,t){if("object"==typeof e)if(Z(e))for(var n=0;n<e.length;n++){var r=e[n];de(r)&&he(r,t)}else if(de(e))e._store&&(e._store.validated=!0);else if(e){var o=function(e){if(null===e||"object"!=typeof e)return null;var t=v&&e[v]||e[g];return"function"==typeof t?t:null}(e);if("function"==typeof o&&o!==e.entries)for(var i,s=o.call(e);!(i=s.next()).done;)de(i.value)&&he(i.value,t)}}function ve(e){var t,n=e.type;if(null!=n&&"string"!=typeof n){if("function"==typeof n)t=n.propTypes;else{if("object"!=typeof n||n.$$typeof!==c&&n.$$typeof!==p)return;t=n.propTypes}if(t){var r=R(n);!function(e,t,n,r,o){var i=Function.call.bind(Y);for(var s in e)if(i(e,s)){var a=void 0;try{if("function"!=typeof e[s]){var l=Error((r||"React class")+": "+n+" type `"+s+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[s]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}a=e[s](t,s,r,n,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(c){a=c}!a||a instanceof Error||(q(o),b("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",r||"React class",n,s,typeof a),q(null)),a instanceof Error&&!(a.message in K)&&(K[a.message]=!0,q(o),b("Failed %s type: %s",n,a.message),q(null))}}(t,e.props,"prop",r,e)}else void 0===n.PropTypes||ae||(ae=!0,b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",R(n)||"Unknown"));"function"!=typeof n.getDefaultProps||n.getDefaultProps.isReactClassApproved||b("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function ge(e,t,r,u,v,g){var y=function(e){return"string"==typeof e||"function"==typeof e||!!(e===o||e===s||C||e===i||e===d||e===f||P||e===m||x||E||S)||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===p||e.$$typeof===a||e.$$typeof===l||e.$$typeof===c||e.$$typeof===w||void 0!==e.getModuleId)}(e);if(!y){var T="";(void 0===e||"object"==typeof e&&null!==e&&0===Object.keys(e).length)&&(T+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var A,O=function(e){return void 0!==e?"\n\nCheck your code at "+e.fileName.replace(/^.*[\\\/]/,"")+":"+e.lineNumber+".":""}(v);T+=O||fe(),null===e?A="null":Z(e)?A="array":void 0!==e&&e.$$typeof===n?(A="<"+(R(e.type)||"Unknown")+" />",T=" Did you accidentally export a JSX literal instead of a component?"):A=typeof e,b("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",A,T)}var D=se(e,t,r,v,g);if(null==D)return D;if(y){var k=t.children;if(void 0!==k)if(u)if(Z(k)){for(var _=0;_<k.length;_++)me(k[_],e);Object.freeze&&Object.freeze(k)}else b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else me(k,e)}return e===o?function(e){for(var t=Object.keys(e.props),n=0;n<t.length;n++){var r=t[n];if("children"!==r&&"key"!==r){ue(e),b("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",r),ue(null);break}}null!==e.ref&&(ue(e),b("Invalid attribute `ref` supplied to `React.Fragment`."),ue(null))}(D):ve(D),D}var ye=function(e,t,n){return ge(e,t,n,!1)},be=function(e,t,n){return ge(e,t,n,!0)};u.Fragment=o,u.jsx=ye,u.jsxs=be}()),u);var d=a.exports,f=t;"production"===process.env.NODE_ENV?(f.createRoot,f.hydrateRoot):f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;var p,h={};var m,v={};"production"===process.env.NODE_ENV?function(){if(p)return h;p=1;var t=e,n="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},r=t.useState,o=t.useEffect,i=t.useLayoutEffect,s=t.useDebugValue;function a(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!n(e,r)}catch(o){return!0}}var l="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),l=r({inst:{value:n,getSnapshot:t}}),c=l[0].inst,u=l[1];return i((function(){c.value=n,c.getSnapshot=t,a(c)&&u({inst:c})}),[e,n,t]),o((function(){return a(c)&&u({inst:c}),e((function(){a(c)&&u({inst:c})}))}),[e]),s(n),n};h.useSyncExternalStore=void 0!==t.useSyncExternalStore?t.useSyncExternalStore:l}():m||(m=1,"production"!==process.env.NODE_ENV&&function(){"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error);var t=e,n=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function r(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),o=1;o<t;o++)r[o-1]=arguments[o];!function(e,t,r){var o=n.ReactDebugCurrentFrame.getStackAddendum();""!==o&&(t+="%s",r=r.concat([o]));var i=r.map((function(e){return String(e)}));i.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,i)}("error",e,r)}var o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=t.useState,s=t.useEffect,a=t.useLayoutEffect,l=t.useDebugValue,c=!1,u=!1;function d(e){var t=e.getSnapshot,n=e.value;try{var r=t();return!o(n,r)}catch(i){return!0}}var f="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t,n){return t()}:function(e,n,f){c||void 0!==t.startTransition&&(c=!0,r("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var p=n();if(!u){var h=n();o(p,h)||(r("The result of getSnapshot should be cached to avoid an infinite loop"),u=!0)}var m=i({inst:{value:p,getSnapshot:n}}),v=m[0].inst,g=m[1];return a((function(){v.value=p,v.getSnapshot=n,d(v)&&g({inst:v})}),[e,p,n]),s((function(){return d(v)&&g({inst:v}),e((function(){d(v)&&g({inst:v})}))}),[e]),l(p),p},p=void 0!==t.useSyncExternalStore?t.useSyncExternalStore:f;v.useSyncExternalStore=p,"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error)}());const g=()=>{},y=g(),b=Object,w=e=>e===y,x=e=>"function"==typeof e,E=(e,t)=>({...e,...t}),S=new WeakMap;let P=0;const C=e=>{const t=typeof e,n=e&&e.constructor,r=n==Date;let o,i;if(b(e)!==e||r||n==RegExp)o=r?e.toJSON():"symbol"==t?e.toString():"string"==t?JSON.stringify(e):""+e;else{if(o=S.get(e),o)return o;if(o=++P+"~",S.set(e,o),n==Array){for(o="@",i=0;i<e.length;i++)o+=C(e[i])+",";S.set(e,o)}if(n==b){o="#";const t=b.keys(e).sort();for(;!w(i=t.pop());)w(e[i])||(o+=i+":"+C(e[i])+",");S.set(e,o)}}return o},T=new WeakMap,R={},A={},O="undefined",D=typeof window!=O,k=typeof document!=O;let _=!0;const[L,M]=D&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[g,g],I={isOnline:()=>_,isVisible:()=>{const e=k&&document.visibilityState;return w(e)||"hidden"!==e}},V={initFocus:e=>(k&&document.addEventListener("visibilitychange",e),L("focus",e),()=>{k&&document.removeEventListener("visibilitychange",e),M("focus",e)}),initReconnect:e=>{const t=()=>{_=!0,e()},n=()=>{_=!1};return L("online",t),L("offline",n),()=>{M("online",t),M("offline",n)}}};e.useId;const $=!D||"Deno"in window,N="undefined"!=typeof navigator&&navigator.connection,F=!$&&N&&(["slow-2g","2g"].includes(N.effectiveType)||N.saveData),j=e=>{if(x(e))try{e=e()}catch(n){e=""}const t=e;return[e="string"==typeof e?e:(Array.isArray(e)?e.length:e)?C(e):"",t]};let B=0;const W=()=>++B;async function H(...e){const[t,n,r,o]=e,i=E({populateCache:!0,throwOnError:!0},"boolean"==typeof o?{revalidate:o}:o||{});let s=i.populateCache;const a=i.rollbackOnError;let l=i.optimisticData;const c=!1!==i.revalidate,u=i.throwOnError;if(x(n)){const e=n,r=[],o=t.keys();for(const n of o)!/^\$(inf|sub)\$/.test(n)&&e(t.get(n)._k)&&r.push(n);return Promise.all(r.map(d))}return d(n);async function d(n){const[o]=j(n);if(!o)return;const[i,d]=((e,t)=>{const n=T.get(e);return[()=>!w(t)&&e.get(t)||R,r=>{if(!w(t)){const o=e.get(t);t in A||(A[t]=o),n[5](t,E(o,r),o||R)}},n[6],()=>!w(t)&&t in A?A[t]:!w(t)&&e.get(t)||R]})(t,o),[f,p,h,m]=T.get(t),v=()=>{const e=f[o];return c&&(delete h[o],delete m[o],e&&e[0])?e[0](2).then((()=>i().data)):i().data};if(e.length<3)return v();let g,b=r;const S=W();p[o]=[S,0];const P=!w(l),C=i(),O=C.data,D=C._c,k=w(D)?O:D;if(P&&(l=x(l)?l(k,O):l,d({data:l,_c:k})),x(b))try{b=b(k)}catch(_){g=_}if(b&&x(b.then)){if(b=await b.catch((e=>{g=e})),S!==p[o][0]){if(g)throw g;return b}g&&P&&(e=>"function"==typeof a?a(e):!1!==a)(g)&&(s=!0,d({data:k,_c:y}))}if(s&&!g)if(x(s)){const e=s(b,k);d({data:e,error:y,_c:y})}else d({data:b,error:y,_c:y});if(p[o][1]=W(),Promise.resolve(v()).then((()=>{d({_c:y})})),!g)return b;if(u)throw g}}const U=(e,t)=>{for(const n in e)e[n][0]&&e[n][0](t)},[z,Y]=((e,t)=>{if(!T.has(e)){const n=E(V,t),r={},o=H.bind(y,e);let i=g;const s={},a=(e,t)=>{const n=s[e]||[];return s[e]=n,n.push(t),()=>n.splice(n.indexOf(t),1)},l=(t,n,r)=>{e.set(t,n);const o=s[t];if(o)for(const e of o)e(n,r)},c=()=>{if(!T.has(e)&&(T.set(e,[r,{},{},{},o,l,a]),!$)){const t=n.initFocus(setTimeout.bind(y,U.bind(y,r,0))),o=n.initReconnect(setTimeout.bind(y,U.bind(y,r,1)));i=()=>{t&&t(),o&&o(),T.delete(e)}}};return c(),[e,o,c,i]}return[e,T.get(e)[4]]})(new Map);E({onLoadingSlow:g,onSuccess:g,onError:g,onErrorRetry:(e,t,n,r,o)=>{const i=n.errorRetryCount,s=o.retryCount,a=~~((Math.random()+.5)*(1<<(s<8?s:8)))*n.errorRetryInterval;!w(i)&&s>i||setTimeout(r,a,o)},onDiscarded:g,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:F?1e4:5e3,focusThrottleInterval:5e3,dedupingInterval:2e3,loadingTimeout:F?5e3:3e3,compare:(e,t)=>C(e)==C(t),isPaused:()=>!1,cache:z,mutate:Y,fallback:{}},I),e.createContext({});const K=D&&window.__SWR_DEVTOOLS_USE__;function X(){return X=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},X.apply(this,arguments)}function q(t,n=[]){let r=[];const o=()=>{const n=r.map((t=>e.createContext(t)));return function(r){const o=(null==r?void 0:r[t])||n;return e.useMemo((()=>({[`__scope${t}`]:{...r,[t]:o}})),[r,o])}};return o.scopeName=t,[function(n,o){const i=e.createContext(o),s=r.length;function a(n){const{scope:r,children:o,...a}=n,l=(null==r?void 0:r[t][s])||i,c=e.useMemo((()=>a),Object.values(a));return e.createElement(l.Provider,{value:c},o)}return r=[...r,o],a.displayName=n+"Provider",[a,function(r,a){const l=(null==a?void 0:a[t][s])||i,c=e.useContext(l);if(c)return c;if(void 0!==o)return o;throw new Error(`\`${r}\` must be used within \`${n}\``)}]},G(o,...n)]}function G(...t){const n=t[0];if(1===t.length)return n;const r=()=>{const r=t.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(t){const o=r.reduce(((e,{useScope:n,scopeName:r})=>({...e,...n(t)[`__scope${r}`]})),{});return e.useMemo((()=>({[`__scope${n.scopeName}`]:o})),[o])}};return r.scopeName=n.scopeName,r}function Z(...e){return t=>e.forEach((e=>function(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}(e,t)))}function J(...t){return e.useCallback(Z(...t),t)}function Q(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}(K?window.__SWR_DEVTOOLS_USE__:[]).concat((e=>(t,n,r)=>e(t,n&&((...e)=>{const[r]=j(t),[,,,o]=T.get(z);if(r.startsWith("$inf$"))return n(...e);const i=o[r];return w(i)?n(...e):(delete o[r],i)}),r))),K&&(window.__SWR_DEVTOOLS_REACT__=e),e.use;const ee=Boolean(null===globalThis||void 0===globalThis?void 0:globalThis.document)?e.useLayoutEffect:()=>{},te=r["useId".toString()]||(()=>{});let ne=0;function re(e){const[t,n]=r.useState(te());return ee((()=>{e||n((e=>null!=e?e:String(ne++)))}),[e]),e||(t?`radix-${t}`:"")}function oe(t){const n=e.useRef(t);return e.useEffect((()=>{n.current=t})),e.useMemo((()=>(...e)=>{var t;return null===(t=n.current)||void 0===t?void 0:t.call(n,...e)}),[])}function ie({prop:t,defaultProp:n,onChange:r=(()=>{})}){const[o,i]=function({defaultProp:t,onChange:n}){const r=e.useState(t),[o]=r,i=e.useRef(o),s=oe(n);return e.useEffect((()=>{i.current!==o&&(s(o),i.current=o)}),[o,i,s]),r}({defaultProp:n,onChange:r}),s=void 0!==t,a=s?t:o,l=oe(r);return[a,e.useCallback((e=>{if(s){const n="function"==typeof e?e(t):e;n!==t&&l(n)}else i(e)}),[s,t,i,l])]}const se=e.forwardRef(((t,n)=>{const{children:r,...o}=t,i=e.Children.toArray(r),s=i.find(ce);if(s){const t=s.props.children,r=i.map((n=>n===s?e.Children.count(t)>1?e.Children.only(null):e.isValidElement(t)?t.props.children:null:n));return e.createElement(ae,X({},o,{ref:n}),e.isValidElement(t)?e.cloneElement(t,void 0,r):null)}return e.createElement(ae,X({},o,{ref:n}),r)}));se.displayName="Slot";const ae=e.forwardRef(((t,n)=>{const{children:r,...o}=t;return e.isValidElement(r)?e.cloneElement(r,{...ue(o,r.props),ref:Z(n,r.ref)}):e.Children.count(r)>1?e.Children.only(null):null}));ae.displayName="SlotClone";const le=({children:t})=>e.createElement(e.Fragment,null,t);function ce(t){return e.isValidElement(t)&&t.type===le}function ue(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...e)=>{i(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...i}:"className"===r&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}const de=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((t,n)=>{const r=e.forwardRef(((t,r)=>{const{asChild:o,...i}=t,s=o?se:n;return e.useEffect((()=>{window[Symbol.for("radix-ui")]=!0}),[]),e.createElement(s,X({},i,{ref:r}))}));return r.displayName=`Primitive.${n}`,{...t,[n]:r}}),{});const fe="dismissableLayer.update",pe="dismissableLayer.pointerDownOutside",he="dismissableLayer.focusOutside";let me;const ve=e.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),ge=e.forwardRef(((t,n)=>{var r;const{disableOutsidePointerEvents:o=!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:a,onInteractOutside:l,onDismiss:c,...u}=t,d=e.useContext(ve),[f,p]=e.useState(null),h=null!==(r=null==f?void 0:f.ownerDocument)&&void 0!==r?r:null===globalThis||void 0===globalThis?void 0:globalThis.document,[,m]=e.useState({}),v=J(n,(e=>p(e))),g=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=g.indexOf(y),w=f?g.indexOf(f):-1,x=d.layersWithOutsidePointerEventsDisabled.size>0,E=w>=b,S=function(t,n=(null===globalThis||void 0===globalThis?void 0:globalThis.document)){const r=oe(t),o=e.useRef(!1),i=e.useRef((()=>{}));return e.useEffect((()=>{const e=e=>{if(e.target&&!o.current){let t=function(){be(pe,r,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(n.removeEventListener("click",i.current),i.current=t,n.addEventListener("click",i.current,{once:!0})):t()}o.current=!1},t=window.setTimeout((()=>{n.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(t),n.removeEventListener("pointerdown",e),n.removeEventListener("click",i.current)}}),[n,r]),{onPointerDownCapture:()=>o.current=!0}}((e=>{const t=e.target,n=[...d.branches].some((e=>e.contains(t)));E&&!n&&(null==s||s(e),null==l||l(e),e.defaultPrevented||null==c||c())}),h),P=function(t,n=(null===globalThis||void 0===globalThis?void 0:globalThis.document)){const r=oe(t),o=e.useRef(!1);return e.useEffect((()=>{const e=e=>{if(e.target&&!o.current){be(he,r,{originalEvent:e},{discrete:!1})}};return n.addEventListener("focusin",e),()=>n.removeEventListener("focusin",e)}),[n,r]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}((e=>{const t=e.target;[...d.branches].some((e=>e.contains(t)))||(null==a||a(e),null==l||l(e),e.defaultPrevented||null==c||c())}),h);return function(t,n=(null===globalThis||void 0===globalThis?void 0:globalThis.document)){const r=oe(t);e.useEffect((()=>{const e=e=>{"Escape"===e.key&&r(e)};return n.addEventListener("keydown",e),()=>n.removeEventListener("keydown",e)}),[r,n])}((e=>{w===d.layers.size-1&&(null==i||i(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))}),h),e.useEffect((()=>{if(f)return o&&(0===d.layersWithOutsidePointerEventsDisabled.size&&(me=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),ye(),()=>{o&&1===d.layersWithOutsidePointerEventsDisabled.size&&(h.body.style.pointerEvents=me)}}),[f,h,o,d]),e.useEffect((()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),ye())}),[f,d]),e.useEffect((()=>{const e=()=>m({});return document.addEventListener(fe,e),()=>document.removeEventListener(fe,e)}),[]),e.createElement(de.div,X({},u,{ref:v,style:{pointerEvents:x?E?"auto":"none":void 0,...t.style},onFocusCapture:Q(t.onFocusCapture,P.onFocusCapture),onBlurCapture:Q(t.onBlurCapture,P.onBlurCapture),onPointerDownCapture:Q(t.onPointerDownCapture,S.onPointerDownCapture)}))}));function ye(){const e=new CustomEvent(fe);document.dispatchEvent(e)}function be(e,n,r,{discrete:o}){const i=r.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});n&&i.addEventListener(e,n,{once:!0}),o?function(e,n){e&&t.flushSync((()=>e.dispatchEvent(n)))}(i,s):i.dispatchEvent(s)}const we="focusScope.autoFocusOnMount",xe="focusScope.autoFocusOnUnmount",Ee={bubbles:!1,cancelable:!0},Se=e.forwardRef(((t,n)=>{const{loop:r=!1,trapped:o=!1,onMountAutoFocus:i,onUnmountAutoFocus:s,...a}=t,[l,c]=e.useState(null),u=oe(i),d=oe(s),f=e.useRef(null),p=J(n,(e=>c(e))),h=e.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;e.useEffect((()=>{if(o){let e=function(e){if(h.paused||!l)return;const t=e.target;l.contains(t)?f.current=t:Re(f.current,{select:!0})},t=function(e){!h.paused&&l&&(l.contains(e.relatedTarget)||Re(f.current,{select:!0}))};return document.addEventListener("focusin",e),document.addEventListener("focusout",t),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t)}}}),[o,l,h.paused]),e.useEffect((()=>{if(l){Ae.add(h);const t=document.activeElement;if(!l.contains(t)){const n=new CustomEvent(we,Ee);l.addEventListener(we,u),l.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Re(r,{select:t}),document.activeElement!==n)return}((e=Pe(l),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&Re(l))}return()=>{l.removeEventListener(we,u),setTimeout((()=>{const e=new CustomEvent(xe,Ee);l.addEventListener(xe,d),l.dispatchEvent(e),e.defaultPrevented||Re(null!=t?t:document.body,{select:!0}),l.removeEventListener(xe,d),Ae.remove(h)}),0)}}var e}),[l,u,d,h]);const m=e.useCallback((e=>{if(!r&&!o)return;if(h.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,n=document.activeElement;if(t&&n){const t=e.currentTarget,[o,i]=function(e){const t=Pe(e),n=Ce(t,e),r=Ce(t.reverse(),e);return[n,r]}(t);o&&i?e.shiftKey||n!==i?e.shiftKey&&n===o&&(e.preventDefault(),r&&Re(i,{select:!0})):(e.preventDefault(),r&&Re(o,{select:!0})):n===t&&e.preventDefault()}}),[r,o,h.paused]);return e.createElement(de.div,X({tabIndex:-1},a,{ref:p,onKeyDown:m}))}));function Pe(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ce(e,t){for(const n of e)if(!Te(n,{upTo:t}))return n}function Te(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function Re(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}const Ae=function(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=Oe(e,t),e.unshift(t)},remove(t){var n;e=Oe(e,t),null===(n=e[0])||void 0===n||n.resume()}}}();function Oe(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}const De=e.forwardRef(((n,r)=>{var o;const{container:i=(null===globalThis||void 0===globalThis||null===(o=globalThis.document)||void 0===o?void 0:o.body),...s}=n;return i?t.createPortal(e.createElement(de.div,X({},s,{ref:r})),i):null}));const ke=n=>{const{present:r,children:o}=n,i=function(n){const[r,o]=e.useState(),i=e.useRef({}),s=e.useRef(n),a=e.useRef("none"),l=n?"mounted":"unmounted",[c,u]=function(t,n){return e.useReducer(((e,t)=>{const r=n[e][t];return null!=r?r:e}),t)}(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return e.useEffect((()=>{const e=_e(i.current);a.current="mounted"===c?e:"none"}),[c]),ee((()=>{const e=i.current,t=s.current;if(t!==n){const r=a.current,o=_e(e);if(n)u("MOUNT");else if("none"===o||"none"===(null==e?void 0:e.display))u("UNMOUNT");else{u(t&&r!==o?"ANIMATION_OUT":"UNMOUNT")}s.current=n}}),[n,u]),ee((()=>{if(r){const e=e=>{const n=_e(i.current).includes(e.animationName);e.target===r&&n&&t.flushSync((()=>u("ANIMATION_END")))},n=e=>{e.target===r&&(a.current=_e(i.current))};return r.addEventListener("animationstart",n),r.addEventListener("animationcancel",e),r.addEventListener("animationend",e),()=>{r.removeEventListener("animationstart",n),r.removeEventListener("animationcancel",e),r.removeEventListener("animationend",e)}}u("ANIMATION_END")}),[r,u]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:e.useCallback((e=>{e&&(i.current=getComputedStyle(e)),o(e)}),[])}}(r),s="function"==typeof o?o({present:i.isPresent}):e.Children.only(o),a=J(i.ref,s.ref);return"function"==typeof o||i.isPresent?e.cloneElement(s,{ref:a}):null};function _e(e){return(null==e?void 0:e.animationName)||"none"}ke.displayName="Presence";let Le=0;function Me(){e.useEffect((()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(e=n[0])&&void 0!==e?e:Ie()),document.body.insertAdjacentElement("beforeend",null!==(t=n[1])&&void 0!==t?t:Ie()),Le++,()=>{1===Le&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),Le--}}),[])}function Ie(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}var Ve=function(){return Ve=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},Ve.apply(this,arguments)};function $e(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}"function"==typeof SuppressedError&&SuppressedError;var Ne="right-scroll-bar-position",Fe="width-before-scroll-bar";function je(t,n){return r=n||null,o=function(e){return t.forEach((function(t){return function(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}(t,e)}))},(i=e.useState((function(){return{value:r,callback:o,facade:{get current(){return i.value},set current(e){var t=i.value;t!==e&&(i.value=e,i.callback(e,t))}}}}))[0]).callback=o,i.facade;var r,o,i}function Be(e){return e}var We=function(e){var t=e.sideCar,n=$e(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var o=t.read();if(!o)throw new Error("Sidecar medium not found");return r.createElement(o,Ve({},n))};We.isSideCarExport=!0;var He=function(e){void 0===e&&(e={});var t=function(e,t){void 0===t&&(t=Be);var n=[],r=!1;return{read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var o=t(e,r);return n.push(o),function(){n=n.filter((function(e){return e!==o}))}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var o=n;n=[],o.forEach(e),t=n}var i=function(){var n=t;t=[],n.forEach(e)},s=function(){return Promise.resolve().then(i)};s(),n={push:function(e){t.push(e),s()},filter:function(e){return t=t.filter(e),n}}}}}(null);return t.options=Ve({async:!0,ssr:!1},e),t}(),Ue=function(){},ze=r.forwardRef((function(e,t){var n=r.useRef(null),o=r.useState({onScrollCapture:Ue,onWheelCapture:Ue,onTouchMoveCapture:Ue}),i=o[0],s=o[1],a=e.forwardProps,l=e.children,c=e.className,u=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,h=e.noIsolation,m=e.inert,v=e.allowPinchZoom,g=e.as,y=void 0===g?"div":g,b=$e(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),w=p,x=je([n,t]),E=Ve(Ve({},b),i);return r.createElement(r.Fragment,null,d&&r.createElement(w,{sideCar:He,removeScrollBar:u,shards:f,noIsolation:h,inert:m,setCallbacks:s,allowPinchZoom:!!v,lockRef:n}),a?r.cloneElement(r.Children.only(l),Ve(Ve({},E),{ref:x})):r.createElement(y,Ve({},E,{className:c,ref:x}),l))}));ze.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},ze.classNames={fullWidth:Fe,zeroRight:Ne};function Ye(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=function(){if("undefined"!=typeof __webpack_nonce__)return __webpack_nonce__}();return t&&e.setAttribute("nonce",t),e}var Ke=function(){var e=0,t=null;return{add:function(n){var r,o;0==e&&(t=Ye())&&(o=n,(r=t).styleSheet?r.styleSheet.cssText=o:r.appendChild(document.createTextNode(o)),function(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}(t)),e++},remove:function(){!--e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Xe=function(){var e,t=(e=Ke(),function(t,n){r.useEffect((function(){return e.add(t),function(){e.remove()}}),[t&&n])});return function(e){var n=e.styles,r=e.dynamic;return t(n,r),null}},qe={left:0,top:0,right:0,gap:0},Ge=function(e){return parseInt(e||"",10)||0},Ze=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return qe;var t=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],o=t["padding"===e?"paddingRight":"marginRight"];return[Ge(n),Ge(r),Ge(o)]}(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Je=Xe(),Qe=function(e,t,n,r){var o=e.left,i=e.top,s=e.right,a=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(a,"px ").concat(r,";\n }\n body {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(o,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(s,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(a,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(Ne," {\n right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(Fe," {\n margin-right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(Ne," .").concat(Ne," {\n right: 0 ").concat(r,";\n }\n \n .").concat(Fe," .").concat(Fe," {\n margin-right: 0 ").concat(r,";\n }\n \n body {\n ").concat("--removed-body-scroll-bar-size",": ").concat(a,"px;\n }\n")},et=function(e){var t=e.noRelative,n=e.noImportant,o=e.gapMode,i=void 0===o?"margin":o,s=r.useMemo((function(){return Ze(i)}),[i]);return r.createElement(Je,{styles:Qe(s,!t,i,n?"":"!important")})},tt=!1;if("undefined"!=typeof window)try{var nt=Object.defineProperty({},"passive",{get:function(){return tt=!0,!0}});window.addEventListener("test",nt,nt),window.removeEventListener("test",nt,nt)}catch(ty){tt=!1}var rt=!!tt&&{passive:!1},ot=function(e,t){var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!function(e){return"TEXTAREA"===e.tagName}(e)&&"visible"===n[t])},it=function(e,t){var n=t;do{if("undefined"!=typeof ShadowRoot&&n instanceof ShadowRoot&&(n=n.host),st(e,n)){var r=at(e,n);if(r[1]>r[2])return!0}n=n.parentNode}while(n&&n!==document.body);return!1},st=function(e,t){return"v"===e?function(e){return ot(e,"overflowY")}(t):function(e){return ot(e,"overflowX")}(t)},at=function(e,t){return"v"===e?[(n=t).scrollTop,n.scrollHeight,n.clientHeight]:function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]}(t);var n},lt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ct=function(e){return[e.deltaX,e.deltaY]},ut=function(e){return e&&"current"in e?e.current:e},dt=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},ft=0,pt=[];const ht=(mt=function(e){var t=r.useRef([]),n=r.useRef([0,0]),o=r.useRef(),i=r.useState(ft++)[0],s=r.useState((function(){return Xe()}))[0],a=r.useRef(e);r.useEffect((function(){a.current=e}),[e]),r.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var t=function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([e.lockRef.current],(e.shards||[]).map(ut),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(i))})),function(){document.body.classList.remove("block-interactivity-".concat(i)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(i))}))}}}),[e.inert,e.lockRef.current,e.shards]);var l=r.useCallback((function(e,t){if("touches"in e&&2===e.touches.length)return!a.current.allowPinchZoom;var r,i=lt(e),s=n.current,l="deltaX"in e?e.deltaX:s[0]-i[0],c="deltaY"in e?e.deltaY:s[1]-i[1],u=e.target,d=Math.abs(l)>Math.abs(c)?"h":"v";if("touches"in e&&"h"===d&&"range"===u.type)return!1;var f=it(d,u);if(!f)return!0;if(f?r=d:(r="v"===d?"h":"v",f=it(d,u)),!f)return!1;if(!o.current&&"changedTouches"in e&&(l||c)&&(o.current=r),!r)return!0;var p=o.current||r;return function(e,t,n,r,o){var i=function(e,t){return"h"===e&&"rtl"===t?-1:1}(e,window.getComputedStyle(t).direction),s=i*r,a=n.target,l=t.contains(a),c=!1,u=s>0,d=0,f=0;do{var p=at(e,a),h=p[0],m=p[1]-p[2]-i*h;(h||m)&&st(e,a)&&(d+=m,f+=h),a=a.parentNode}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(u&&(o&&0===d||!o&&s>d)||!u&&(o&&0===f||!o&&-s>f))&&(c=!0),c}(p,t,e,"h"===p?l:c,!0)}),[]),c=r.useCallback((function(e){var n=e;if(pt.length&&pt[pt.length-1]===s){var r="deltaY"in n?ct(n):lt(n),o=t.current.filter((function(e){return e.name===n.type&&e.target===n.target&&(t=e.delta,o=r,t[0]===o[0]&&t[1]===o[1]);var t,o}))[0];if(o&&o.should)n.cancelable&&n.preventDefault();else if(!o){var i=(a.current.shards||[]).map(ut).filter(Boolean).filter((function(e){return e.contains(n.target)}));(i.length>0?l(n,i[0]):!a.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),u=r.useCallback((function(e,n,r,o){var i={name:e,delta:n,target:r,should:o};t.current.push(i),setTimeout((function(){t.current=t.current.filter((function(e){return e!==i}))}),1)}),[]),d=r.useCallback((function(e){n.current=lt(e),o.current=void 0}),[]),f=r.useCallback((function(t){u(t.type,ct(t),t.target,l(t,e.lockRef.current))}),[]),p=r.useCallback((function(t){u(t.type,lt(t),t.target,l(t,e.lockRef.current))}),[]);r.useEffect((function(){return pt.push(s),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",c,rt),document.addEventListener("touchmove",c,rt),document.addEventListener("touchstart",d,rt),function(){pt=pt.filter((function(e){return e!==s})),document.removeEventListener("wheel",c,rt),document.removeEventListener("touchmove",c,rt),document.removeEventListener("touchstart",d,rt)}}),[]);var h=e.removeScrollBar,m=e.inert;return r.createElement(r.Fragment,null,m?r.createElement(s,{styles:dt(i)}):null,h?r.createElement(et,{gapMode:"margin"}):null)},He.useMedium(mt),We);var mt,vt=r.forwardRef((function(e,t){return r.createElement(ze,Ve({},e,{ref:t,sideCar:ht}))}));vt.classNames=ze.classNames;const gt=vt;var yt=new WeakMap,bt=new WeakMap,wt={},xt=0,Et=function(e){return e&&(e.host||Et(e.parentNode))},St=function(e,t,n,r){var o=function(e,t){return t.map((function(t){if(e.contains(t))return t;var n=Et(t);return n&&e.contains(n)?n:(console.error("aria-hidden",t,"in not contained inside",e,". Doing nothing"),null)})).filter((function(e){return Boolean(e)}))}(t,Array.isArray(e)?e:[e]);wt[n]||(wt[n]=new WeakMap);var i=wt[n],s=[],a=new Set,l=new Set(o),c=function(e){e&&!a.has(e)&&(a.add(e),c(e.parentNode))};o.forEach(c);var u=function(e){e&&!l.has(e)&&Array.prototype.forEach.call(e.children,(function(e){if(a.has(e))u(e);else{var t=e.getAttribute(r),o=null!==t&&"false"!==t,l=(yt.get(e)||0)+1,c=(i.get(e)||0)+1;yt.set(e,l),i.set(e,c),s.push(e),1===l&&o&&bt.set(e,!0),1===c&&e.setAttribute(n,"true"),o||e.setAttribute(r,"true")}}))};return u(t),a.clear(),xt++,function(){s.forEach((function(e){var t=yt.get(e)-1,o=i.get(e)-1;yt.set(e,t),i.set(e,o),t||(bt.has(e)||e.removeAttribute(r),bt.delete(e)),o||e.removeAttribute(n)})),--xt||(yt=new WeakMap,yt=new WeakMap,bt=new WeakMap,wt={})}},Pt=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body}(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),St(r,o,n,"aria-hidden")):function(){return null}};const Ct="Dialog",[Tt,Rt]=q(Ct),[At,Ot]=Tt(Ct),Dt="DialogPortal",[kt,_t]=Tt(Dt,{forceMount:void 0}),Lt="DialogOverlay",Mt=e.forwardRef(((t,n)=>{const r=_t(Lt,t.__scopeDialog),{forceMount:o=r.forceMount,...i}=t,s=Ot(Lt,t.__scopeDialog);return s.modal?e.createElement(ke,{present:o||s.open},e.createElement(It,X({},i,{ref:n}))):null})),It=e.forwardRef(((t,n)=>{const{__scopeDialog:r,...o}=t,i=Ot(Lt,r);return e.createElement(gt,{as:se,allowPinchZoom:!0,shards:[i.contentRef]},e.createElement(de.div,X({"data-state":Bt(i.open)},o,{ref:n,style:{pointerEvents:"auto",...o.style}})))})),Vt="DialogContent",$t=e.forwardRef(((t,n)=>{const r=_t(Vt,t.__scopeDialog),{forceMount:o=r.forceMount,...i}=t,s=Ot(Vt,t.__scopeDialog);return e.createElement(ke,{present:o||s.open},s.modal?e.createElement(Nt,X({},i,{ref:n})):e.createElement(Ft,X({},i,{ref:n})))})),Nt=e.forwardRef(((t,n)=>{const r=Ot(Vt,t.__scopeDialog),o=e.useRef(null),i=J(n,r.contentRef,o);return e.useEffect((()=>{const e=o.current;if(e)return Pt(e)}),[]),e.createElement(jt,X({},t,{ref:i,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Q(t.onCloseAutoFocus,(e=>{var t;e.preventDefault(),null===(t=r.triggerRef.current)||void 0===t||t.focus()})),onPointerDownOutside:Q(t.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey;(2===t.button||n)&&e.preventDefault()})),onFocusOutside:Q(t.onFocusOutside,(e=>e.preventDefault()))}))})),Ft=e.forwardRef(((t,n)=>{const r=Ot(Vt,t.__scopeDialog),o=e.useRef(!1);return e.createElement(jt,X({},t,{ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:e=>{var n,i;(null===(n=t.onCloseAutoFocus)||void 0===n||n.call(t,e),e.defaultPrevented)||(o.current||null===(i=r.triggerRef.current)||void 0===i||i.focus(),e.preventDefault());o.current=!1},onInteractOutside:e=>{var n,i;null===(n=t.onInteractOutside)||void 0===n||n.call(t,e),e.defaultPrevented||(o.current=!0);const s=e.target;(null===(i=r.triggerRef.current)||void 0===i?void 0:i.contains(s))&&e.preventDefault()}}))})),jt=e.forwardRef(((t,n)=>{const{__scopeDialog:r,trapFocus:o,onOpenAutoFocus:i,onCloseAutoFocus:s,...a}=t,l=Ot(Vt,r),c=J(n,e.useRef(null));return Me(),e.createElement(e.Fragment,null,e.createElement(Se,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:i,onUnmountAutoFocus:s},e.createElement(ge,X({role:"dialog",id:l.contentId,"aria-describedby":l.descriptionId,"aria-labelledby":l.titleId,"data-state":Bt(l.open)},a,{ref:c,onDismiss:()=>l.onOpenChange(!1)}))),!1)}));function Bt(e){return e?"open":"closed"}const Wt=t=>{const{__scopeDialog:n,children:r,open:o,defaultOpen:i,onOpenChange:s,modal:a=!0}=t,l=e.useRef(null),c=e.useRef(null),[u=!1,d]=ie({prop:o,defaultProp:i,onChange:s});return e.createElement(At,{scope:n,triggerRef:l,contentRef:c,contentId:re(),titleId:re(),descriptionId:re(),open:u,onOpenChange:d,onOpenToggle:e.useCallback((()=>d((e=>!e))),[d]),modal:a},r)},Ht=t=>{const{__scopeDialog:n,forceMount:r,children:o,container:i}=t,s=Ot(Dt,n);return e.createElement(kt,{scope:n,forceMount:r},e.Children.map(o,(t=>e.createElement(ke,{present:r||s.open},e.createElement(De,{asChild:!0,container:i},t)))))},Ut=Mt,zt=$t;function Yt(e){return e.split("-")[0]}function Kt(e){return e.split("-")[1]}function Xt(e){return["top","bottom"].includes(Yt(e))?"x":"y"}function qt(e){return"y"===e?"height":"width"}function Gt(e,t,n){let{reference:r,floating:o}=e;const i=r.x+r.width/2-o.width/2,s=r.y+r.height/2-o.height/2,a=Xt(t),l=qt(a),c=r[l]/2-o[l]/2,u="x"===a;let d;switch(Yt(t)){case"top":d={x:i,y:r.y-o.height};break;case"bottom":d={x:i,y:r.y+r.height};break;case"right":d={x:r.x+r.width,y:s};break;case"left":d={x:r.x-o.width,y:s};break;default:d={x:r.x,y:r.y}}switch(Kt(t)){case"start":d[a]-=c*(n&&u?-1:1);break;case"end":d[a]+=c*(n&&u?-1:1)}return d}function Zt(e){return"number"!=typeof e?(t=e,{top:0,right:0,bottom:0,left:0,...t}):{top:e,right:e,bottom:e,left:e};var t}function Jt(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}async function Qt(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:i,rects:s,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=t,h=Zt(p),m=a[f?"floating"===d?"reference":"floating":d],v=Jt(await i.getClippingRect({element:null==(n=await(null==i.isElement?void 0:i.isElement(m)))||n?m:m.contextElement||await(null==i.getDocumentElement?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:u,strategy:l})),g=Jt(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({rect:"floating"===d?{...s.floating,x:r,y:o}:s.reference,offsetParent:await(null==i.getOffsetParent?void 0:i.getOffsetParent(a.floating)),strategy:l}):s[d]);return{top:v.top-g.top+h.top,bottom:g.bottom-v.bottom+h.bottom,left:v.left-g.left+h.left,right:g.right-v.right+h.right}}const en=Math.min,tn=Math.max;function nn(e,t,n){return tn(e,en(t,n))}const rn=e=>({name:"arrow",options:e,async fn(t){const{element:n,padding:r=0}=null!=e?e:{},{x:o,y:i,placement:s,rects:a,platform:l}=t;if(null==n)return{};const c=Zt(r),u={x:o,y:i},d=Xt(s),f=Kt(s),p=qt(d),h=await l.getDimensions(n),m="y"===d?"top":"left",v="y"===d?"bottom":"right",g=a.reference[p]+a.reference[d]-u[d]-a.floating[p],y=u[d]-a.reference[d],b=await(null==l.getOffsetParent?void 0:l.getOffsetParent(n));let w=b?"y"===d?b.clientHeight||0:b.clientWidth||0:0;0===w&&(w=a.floating[p]);const x=g/2-y/2,E=c[m],S=w-h[p]-c[v],P=w/2-h[p]/2+x,C=nn(E,P,S),T=("start"===f?c[m]:c[v])>0&&P!==C&&a.reference[p]<=a.floating[p];return{[d]:u[d]-(T?P<E?E-P:S-P:0),data:{[d]:C,centerOffset:P-C}}}}),on={left:"right",right:"left",bottom:"top",top:"bottom"};function sn(e){return e.replace(/left|right|bottom|top/g,(e=>on[e]))}const an={start:"end",end:"start"};function ln(e){return e.replace(/start|end/g,(e=>an[e]))}const cn=["top","right","bottom","left"];cn.reduce(((e,t)=>e.concat(t,t+"-start",t+"-end")),[]);const un=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:i,initialPlacement:s,platform:a,elements:l}=t,{mainAxis:c=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f="bestFit",flipAlignment:p=!0,...h}=e,m=Yt(r),v=[s,...d||(m!==s&&p?function(e){const t=sn(e);return[ln(e),t,ln(t)]}(s):[sn(s)])],g=await Qt(t,h),y=[];let b=(null==(n=o.flip)?void 0:n.overflows)||[];if(c&&y.push(g[m]),u){const{main:e,cross:t}=function(e,t,n){void 0===n&&(n=!1);const r=Kt(e),o=Xt(e),i=qt(o);let s="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=sn(s)),{main:s,cross:sn(s)}}(r,i,await(null==a.isRTL?void 0:a.isRTL(l.floating)));y.push(g[e],g[t])}if(b=[...b,{placement:r,overflows:y}],!y.every((e=>e<=0))){var w,x;const e=(null!=(w=null==(x=o.flip)?void 0:x.index)?w:0)+1,t=v[e];if(t)return{data:{index:e,overflows:b},reset:{placement:t}};let n="bottom";switch(f){case"bestFit":{var E;const e=null==(E=b.map((e=>[e,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:E[0].placement;e&&(n=e);break}case"initialPlacement":n=s}if(r!==n)return{reset:{placement:n}}}return{}}}};function dn(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function fn(e){return cn.some((t=>e[t]>=0))}const pn=function(e){let{strategy:t="referenceHidden",...n}=void 0===e?{}:e;return{name:"hide",async fn(e){const{rects:r}=e;switch(t){case"referenceHidden":{const t=dn(await Qt(e,{...n,elementContext:"reference"}),r.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:fn(t)}}}case"escaped":{const t=dn(await Qt(e,{...n,altBoundary:!0}),r.floating);return{data:{escapedOffsets:t,escaped:fn(t)}}}default:return{}}}}};function hn(e){return"x"===e?"y":"x"}const mn=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:s=!1,limiter:a={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=e,c={x:n,y:r},u=await Qt(t,l),d=Xt(Yt(o)),f=hn(d);let p=c[d],h=c[f];if(i){const e="y"===d?"bottom":"right";p=nn(p+u["y"===d?"top":"left"],p,p-u[e])}if(s){const e="y"===f?"bottom":"right";h=nn(h+u["y"===f?"top":"left"],h,h-u[e])}const m=a.fn({...t,[d]:p,[f]:h});return{...m,data:{x:m.x-n,y:m.y-r}}}}};function vn(e){return e&&e.document&&e.location&&e.alert&&e.setInterval}function gn(e){if(null==e)return window;if(!vn(e)){const t=e.ownerDocument;return t&&t.defaultView||window}return e}function yn(e){return gn(e).getComputedStyle(e)}function bn(e){return vn(e)?"":e?(e.nodeName||"").toLowerCase():""}function wn(){const e=navigator.userAgentData;return null!=e&&e.brands?e.brands.map((e=>e.brand+"/"+e.version)).join(" "):navigator.userAgent}function xn(e){return e instanceof gn(e).HTMLElement}function En(e){return e instanceof gn(e).Element}function Sn(e){return"undefined"!=typeof ShadowRoot&&(e instanceof gn(e).ShadowRoot||e instanceof ShadowRoot)}function Pn(e){const{overflow:t,overflowX:n,overflowY:r}=yn(e);return/auto|scroll|overlay|hidden/.test(t+r+n)}function Cn(e){return["table","td","th"].includes(bn(e))}function Tn(e){const t=/firefox/i.test(wn()),n=yn(e);return"none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||["transform","perspective"].includes(n.willChange)||t&&"filter"===n.willChange||t&&!!n.filter&&"none"!==n.filter}function Rn(){return!/^((?!chrome|android).)*safari/i.test(wn())}const An=Math.min,On=Math.max,Dn=Math.round;function kn(e,t,n){var r,o,i,s;void 0===t&&(t=!1),void 0===n&&(n=!1);const a=e.getBoundingClientRect();let l=1,c=1;t&&xn(e)&&(l=e.offsetWidth>0&&Dn(a.width)/e.offsetWidth||1,c=e.offsetHeight>0&&Dn(a.height)/e.offsetHeight||1);const u=En(e)?gn(e):window,d=!Rn()&&n,f=(a.left+(d&&null!=(r=null==(o=u.visualViewport)?void 0:o.offsetLeft)?r:0))/l,p=(a.top+(d&&null!=(i=null==(s=u.visualViewport)?void 0:s.offsetTop)?i:0))/c,h=a.width/l,m=a.height/c;return{width:h,height:m,top:p,right:f+h,bottom:p+m,left:f,x:f,y:p}}function _n(e){return(t=e,(t instanceof gn(t).Node?e.ownerDocument:e.document)||window.document).documentElement;var t}function Ln(e){return En(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Mn(e){return kn(_n(e)).left+Ln(e).scrollLeft}function In(e,t,n){const r=xn(t),o=_n(t),i=kn(e,r&&function(e){const t=kn(e);return Dn(t.width)!==e.offsetWidth||Dn(t.height)!==e.offsetHeight}(t),"fixed"===n);let s={scrollLeft:0,scrollTop:0};const a={x:0,y:0};if(r||!r&&"fixed"!==n)if(("body"!==bn(t)||Pn(o))&&(s=Ln(t)),xn(t)){const e=kn(t,!0);a.x=e.x+t.clientLeft,a.y=e.y+t.clientTop}else o&&(a.x=Mn(o));return{x:i.left+s.scrollLeft-a.x,y:i.top+s.scrollTop-a.y,width:i.width,height:i.height}}function Vn(e){return"html"===bn(e)?e:e.assignedSlot||e.parentNode||(Sn(e)?e.host:null)||_n(e)}function $n(e){return xn(e)&&"fixed"!==getComputedStyle(e).position?e.offsetParent:null}function Nn(e){const t=gn(e);let n=$n(e);for(;n&&Cn(n)&&"static"===getComputedStyle(n).position;)n=$n(n);return n&&("html"===bn(n)||"body"===bn(n)&&"static"===getComputedStyle(n).position&&!Tn(n))?t:n||function(e){let t=Vn(e);for(Sn(t)&&(t=t.host);xn(t)&&!["html","body"].includes(bn(t));){if(Tn(t))return t;t=t.parentNode}return null}(e)||t}function Fn(e){if(xn(e))return{width:e.offsetWidth,height:e.offsetHeight};const t=kn(e);return{width:t.width,height:t.height}}function jn(e){const t=Vn(e);return["html","body","#document"].includes(bn(t))?e.ownerDocument.body:xn(t)&&Pn(t)?t:jn(t)}function Bn(e,t){var n;void 0===t&&(t=[]);const r=jn(e),o=r===(null==(n=e.ownerDocument)?void 0:n.body),i=gn(r),s=o?[i].concat(i.visualViewport||[],Pn(r)?r:[]):r,a=t.concat(s);return o?a:a.concat(Bn(s))}function Wn(e,t,n){return"viewport"===t?Jt(function(e,t){const n=gn(e),r=_n(e),o=n.visualViewport;let i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;const e=Rn();(e||!e&&"fixed"===t)&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a,y:l}}(e,n)):En(t)?function(e,t){const n=kn(e,!1,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft;return{top:r,left:o,x:o,y:r,right:o+e.clientWidth,bottom:r+e.clientHeight,width:e.clientWidth,height:e.clientHeight}}(t,n):Jt(function(e){var t;const n=_n(e),r=Ln(e),o=null==(t=e.ownerDocument)?void 0:t.body,i=On(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=On(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0);let a=-r.scrollLeft+Mn(e);const l=-r.scrollTop;return"rtl"===yn(o||n).direction&&(a+=On(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}(_n(e)))}function Hn(e){const t=Bn(e),n=["absolute","fixed"].includes(yn(e).position)&&xn(e)?Nn(e):e;return En(n)?t.filter((e=>En(e)&&function(e,t){const n=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&Sn(n)){let n=t;do{if(n&&e===n)return!0;n=n.parentNode||n.host}while(n)}return!1}(e,n)&&"body"!==bn(e))):[]}const Un={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[..."clippingAncestors"===n?Hn(t):[].concat(n),r],s=i[0],a=i.reduce(((e,n)=>{const r=Wn(t,n,o);return e.top=On(r.top,e.top),e.right=An(r.right,e.right),e.bottom=An(r.bottom,e.bottom),e.left=On(r.left,e.left),e}),Wn(t,s,o));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=xn(n),i=_n(n);if(n===i)return t;let s={scrollLeft:0,scrollTop:0};const a={x:0,y:0};if((o||!o&&"fixed"!==r)&&(("body"!==bn(n)||Pn(i))&&(s=Ln(n)),xn(n))){const e=kn(n,!0);a.x=e.x+n.clientLeft,a.y=e.y+n.clientTop}return{...t,x:t.x-s.scrollLeft+a.x,y:t.y-s.scrollTop+a.y}},isElement:En,getDimensions:Fn,getOffsetParent:Nn,getDocumentElement:_n,getElementRects:e=>{let{reference:t,floating:n,strategy:r}=e;return{reference:In(t,Nn(n),r),floating:{...Fn(n),x:0,y:0}}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>"rtl"===yn(e).direction};function zn(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:s=!0,animationFrame:a=!1}=r,l=o&&!a,c=i&&!a,u=l||c?[...En(e)?Bn(e):[],...Bn(t)]:[];u.forEach((e=>{l&&e.addEventListener("scroll",n,{passive:!0}),c&&e.addEventListener("resize",n)}));let d,f=null;if(s){let r=!0;f=new ResizeObserver((()=>{r||n(),r=!1})),En(e)&&!a&&f.observe(e),f.observe(t)}let p=a?kn(e):null;return a&&function t(){const r=kn(e);!p||r.x===p.x&&r.y===p.y&&r.width===p.width&&r.height===p.height||n(),p=r,d=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{l&&e.removeEventListener("scroll",n),c&&e.removeEventListener("resize",n)})),null==(e=f)||e.disconnect(),f=null,a&&cancelAnimationFrame(d)}}const Yn=(e,t,n)=>(async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:s}=n,a=await(null==s.isRTL?void 0:s.isRTL(t));let l=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:u}=Gt(l,r,a),d=r,f={},p=0;for(let h=0;h<i.length;h++){const{name:n,fn:m}=i[h],{x:v,y:g,data:y,reset:b}=await m({x:c,y:u,initialPlacement:r,placement:d,strategy:o,middlewareData:f,rects:l,platform:s,elements:{reference:e,floating:t}});c=null!=v?v:c,u=null!=g?g:u,f={...f,[n]:{...f[n],...y}},b&&p<=50&&(p++,"object"==typeof b&&(b.placement&&(d=b.placement),b.rects&&(l=!0===b.rects?await s.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:c,y:u}=Gt(l,d,a))),h=-1)}return{x:c,y:u,placement:d,strategy:o,middlewareData:f}})(e,t,{platform:Un,...n});var Kn="undefined"!=typeof document?e.useLayoutEffect:e.useEffect;function Xn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;0!=r--;)if(!Xn(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!Object.prototype.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){const n=o[r];if(("_owner"!==n||!e.$$typeof)&&!Xn(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function qn(e){let{middleware:t,placement:n="bottom",strategy:i="absolute",whileElementsMounted:s}=void 0===e?{}:e;const a=r.useRef(null),l=r.useRef(null),c=function(e){const t=r.useRef(e);return Kn((()=>{t.current=e})),t}(s),u=r.useRef(null),[d,f]=r.useState({x:null,y:null,strategy:i,placement:n,middlewareData:{}}),[p,h]=r.useState(t);Xn(null==p?void 0:p.map((e=>{let{options:t}=e;return t})),null==t?void 0:t.map((e=>{let{options:t}=e;return t})))||h(t);const m=r.useCallback((()=>{a.current&&l.current&&Yn(a.current,l.current,{middleware:p,placement:n,strategy:i}).then((e=>{v.current&&o.flushSync((()=>{f(e)}))}))}),[p,n,i]);Kn((()=>{v.current&&m()}),[m]);const v=r.useRef(!1);Kn((()=>(v.current=!0,()=>{v.current=!1})),[]);const g=r.useCallback((()=>{if("function"==typeof u.current&&(u.current(),u.current=null),a.current&&l.current)if(c.current){const e=c.current(a.current,l.current,m);u.current=e}else m()}),[m,c]),y=r.useCallback((e=>{a.current=e,g()}),[g]),b=r.useCallback((e=>{l.current=e,g()}),[g]),w=r.useMemo((()=>({reference:a,floating:l})),[]);return r.useMemo((()=>({...d,update:m,refs:w,reference:y,floating:b})),[d,m,w,y,b])}const Gn=e=>{const{element:t,padding:n}=e;return{name:"arrow",options:e,fn(e){return r=t,Object.prototype.hasOwnProperty.call(r,"current")?null!=t.current?rn({element:t.current,padding:n}).fn(e):{}:t?rn({element:t,padding:n}).fn(e):{};var r}}},Zn=e.forwardRef(((t,n)=>{const{children:r,width:o=10,height:i=5,...s}=t;return e.createElement(de.svg,X({},s,{ref:n,width:o,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),t.asChild?r:e.createElement("polygon",{points:"0,0 30,0 15,10"}))}));function Jn(t){const[n,r]=e.useState(void 0);return ee((()=>{if(t){r({width:t.offsetWidth,height:t.offsetHeight});const e=new ResizeObserver((e=>{if(!Array.isArray(e))return;if(!e.length)return;const n=e[0];let o,i;if("borderBoxSize"in n){const e=n.borderBoxSize,t=Array.isArray(e)?e[0]:e;o=t.inlineSize,i=t.blockSize}else o=t.offsetWidth,i=t.offsetHeight;r({width:o,height:i})}));return e.observe(t,{box:"border-box"}),()=>e.unobserve(t)}r(void 0)}),[t]),n}const Qn="Popper",[er,tr]=q(Qn),[nr,rr]=er(Qn),or=e.forwardRef(((t,n)=>{const{__scopePopper:r,virtualRef:o,...i}=t,s=rr("PopperAnchor",r),a=e.useRef(null),l=J(n,a);return e.useEffect((()=>{s.onAnchorChange((null==o?void 0:o.current)||a.current)})),o?null:e.createElement(de.div,X({},i,{ref:l}))})),ir="PopperContent",[sr,ar]=er(ir),[lr,cr]=er(ir,{hasParent:!1,positionUpdateFns:new Set}),ur=e.forwardRef(((t,n)=>{var r,o,i,s,a,l,c,u;const{__scopePopper:d,side:f="bottom",sideOffset:p=0,align:h="center",alignOffset:m=0,arrowPadding:v=0,collisionBoundary:g=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:w=!1,avoidCollisions:x=!0,onPlaced:E,...S}=t,P=rr(ir,d),[C,T]=e.useState(null),R=J(n,(e=>T(e))),[A,O]=e.useState(null),D=Jn(A),k=null!==(r=null==D?void 0:D.width)&&void 0!==r?r:0,_=null!==(o=null==D?void 0:D.height)&&void 0!==o?o:0,L=f+("center"!==h?"-"+h:""),M="number"==typeof y?y:{top:0,right:0,bottom:0,left:0,...y},I=Array.isArray(g)?g:[g],V=I.length>0,$={padding:M,boundary:I.filter(pr),altBoundary:V},{reference:N,floating:F,strategy:j,x:B,y:W,placement:H,middlewareData:U,update:z}=qn({strategy:"fixed",placement:L,whileElementsMounted:zn,middleware:[hr(),(X={mainAxis:p+_,alignmentAxis:m},void 0===X&&(X=0),{name:"offset",options:X,async fn(e){const{x:t,y:n}=e,r=await async function(e,t){const{placement:n,platform:r,elements:o}=e,i=await(null==r.isRTL?void 0:r.isRTL(o.floating)),s=Yt(n),a=Kt(n),l="x"===Xt(n),c=["left","top"].includes(s)?-1:1,u=i&&l?-1:1,d="function"==typeof t?t(e):t;let{mainAxis:f,crossAxis:p,alignmentAxis:h}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return a&&"number"==typeof h&&(p="end"===a?-1*h:h),l?{x:p*u,y:f*c}:{x:f*c,y:p*u}}(e,X);return{x:t+r.x,y:n+r.y,data:r}}}),x?mn({mainAxis:!0,crossAxis:!1,limiter:"partial"===b?(void 0===K&&(K={}),{options:K,fn(e){const{x:t,y:n,placement:r,rects:o,middlewareData:i}=e,{offset:s=0,mainAxis:a=!0,crossAxis:l=!0}=K,c={x:t,y:n},u=Xt(r),d=hn(u);let f=c[u],p=c[d];const h="function"==typeof s?s({...o,placement:r}):s,m="number"==typeof h?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(a){const e="y"===u?"height":"width",t=o.reference[u]-o.floating[e]+m.mainAxis,n=o.reference[u]+o.reference[e]-m.mainAxis;f<t?f=t:f>n&&(f=n)}if(l){var v,g,y,b;const e="y"===u?"width":"height",t=["top","left"].includes(Yt(r)),n=o.reference[d]-o.floating[e]+(t&&null!=(v=null==(g=i.offset)?void 0:g[d])?v:0)+(t?0:m.crossAxis),s=o.reference[d]+o.reference[e]+(t?0:null!=(y=null==(b=i.offset)?void 0:b[d])?y:0)-(t?m.crossAxis:0);p<n?p=n:p>s&&(p=s)}return{[u]:f,[d]:p}}}):void 0,...$}):void 0,A?Gn({element:A,padding:v}):void 0,x?un({...$}):void 0,(Y={...$,apply:({elements:e,availableWidth:t,availableHeight:n})=>{e.floating.style.setProperty("--radix-popper-available-width",`${t}px`),e.floating.style.setProperty("--radix-popper-available-height",`${n}px`)}},void 0===Y&&(Y={}),{name:"size",options:Y,async fn(e){const{placement:t,rects:n,platform:r,elements:o}=e,{apply:i,...s}=Y,a=await Qt(e,s),l=Yt(t),c=Kt(t);let u,d;"top"===l||"bottom"===l?(u=l,d=c===(await(null==r.isRTL?void 0:r.isRTL(o.floating))?"start":"end")?"left":"right"):(d=l,u="end"===c?"top":"bottom");const f=tn(a.left,0),p=tn(a.right,0),h=tn(a.top,0),m=tn(a.bottom,0),v={availableHeight:n.floating.height-(["left","right"].includes(t)?2*(0!==h||0!==m?h+m:tn(a.top,a.bottom)):a[u]),availableWidth:n.floating.width-(["top","bottom"].includes(t)?2*(0!==f||0!==p?f+p:tn(a.left,a.right)):a[d])},g=await r.getDimensions(o.floating);null==i||i({...e,...v});const y=await r.getDimensions(o.floating);return g.width!==y.width||g.height!==y.height?{reset:{rects:!0}}:{}}}),mr({arrowWidth:k,arrowHeight:_}),w?pn({strategy:"referenceHidden"}):void 0].filter(fr)});var Y,K,X;ee((()=>{N(P.anchor)}),[N,P.anchor]);const q=null!==B&&null!==W,[G,Z]=vr(H),Q=oe(E);ee((()=>{q&&(null==Q||Q())}),[q,Q]);const te=null===(i=U.arrow)||void 0===i?void 0:i.x,ne=null===(s=U.arrow)||void 0===s?void 0:s.y,re=0!==(null===(a=U.arrow)||void 0===a?void 0:a.centerOffset),[ie,se]=e.useState();ee((()=>{C&&se(window.getComputedStyle(C).zIndex)}),[C]);const{hasParent:ae,positionUpdateFns:le}=cr(ir,d),ce=!ae;e.useLayoutEffect((()=>{if(!ce)return le.add(z),()=>{le.delete(z)}}),[ce,le,z]),ee((()=>{ce&&q&&Array.from(le).reverse().forEach((e=>requestAnimationFrame(e)))}),[ce,q,le]);const ue={"data-side":G,"data-align":Z,...S,ref:R,style:{...S.style,animation:q?void 0:"none",opacity:null!==(l=U.hide)&&void 0!==l&&l.referenceHidden?0:void 0}};return e.createElement("div",{ref:F,"data-radix-popper-content-wrapper":"",style:{position:j,left:0,top:0,transform:q?`translate3d(${Math.round(B)}px, ${Math.round(W)}px, 0)`:"translate3d(0, -200%, 0)",minWidth:"max-content",zIndex:ie,"--radix-popper-transform-origin":[null===(c=U.transformOrigin)||void 0===c?void 0:c.x,null===(u=U.transformOrigin)||void 0===u?void 0:u.y].join(" ")},dir:t.dir},e.createElement(sr,{scope:d,placedSide:G,onArrowChange:O,arrowX:te,arrowY:ne,shouldHideArrow:re},ce?e.createElement(lr,{scope:d,hasParent:!0,positionUpdateFns:le},e.createElement(de.div,ue)):e.createElement(de.div,ue)))})),dr={top:"bottom",right:"left",bottom:"top",left:"right"};function fr(e){return void 0!==e}function pr(e){return null!==e}const hr=()=>({name:"anchorCssProperties",fn(e){const{rects:t,elements:n}=e,{width:r,height:o}=t.reference;return n.floating.style.setProperty("--radix-popper-anchor-width",`${r}px`),n.floating.style.setProperty("--radix-popper-anchor-height",`${o}px`),{}}}),mr=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,s;const{placement:a,rects:l,middlewareData:c}=t,u=0!==(null===(n=c.arrow)||void 0===n?void 0:n.centerOffset),d=u?0:e.arrowWidth,f=u?0:e.arrowHeight,[p,h]=vr(a),m={start:"0%",center:"50%",end:"100%"}[h],v=(null!==(r=null===(o=c.arrow)||void 0===o?void 0:o.x)&&void 0!==r?r:0)+d/2,g=(null!==(i=null===(s=c.arrow)||void 0===s?void 0:s.y)&&void 0!==i?i:0)+f/2;let y="",b="";return"bottom"===p?(y=u?m:`${v}px`,b=-f+"px"):"top"===p?(y=u?m:`${v}px`,b=`${l.floating.height+f}px`):"right"===p?(y=-f+"px",b=u?m:`${g}px`):"left"===p&&(y=`${l.floating.width+f}px`,b=u?m:`${g}px`),{data:{x:y,y:b}}}});function vr(e){const[t,n="center"]=e.split("-");return[t,n]}const gr=t=>{const{__scopePopper:n,children:r}=t,[o,i]=e.useState(null);return e.createElement(nr,{scope:n,anchor:o,onAnchorChange:i},r)},yr=or,br=ur,wr=e.forwardRef((function(t,n){const{__scopePopper:r,...o}=t,i=ar("PopperArrow",r),s=dr[i.placedSide];return e.createElement("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0}},e.createElement(Zn,X({},o,{ref:n,style:{...o.style,display:"block"}})))})),xr="Popover",[Er,Sr]=q(xr,[tr]),Pr=tr(),[Cr,Tr]=Er(xr),Rr=e.forwardRef(((t,n)=>{const{__scopePopover:r,...o}=t,i=Tr("PopoverTrigger",r),s=Pr(r),a=J(n,i.triggerRef),l=e.createElement(de.button,X({type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":Vr(i.open)},o,{ref:a,onClick:Q(t.onClick,i.onOpenToggle)}));return i.hasCustomAnchor?l:e.createElement(yr,X({asChild:!0},s),l)})),Ar="PopoverPortal",[Or,Dr]=Er(Ar,{forceMount:void 0}),kr="PopoverContent",_r=e.forwardRef(((t,n)=>{const r=Dr(kr,t.__scopePopover),{forceMount:o=r.forceMount,...i}=t,s=Tr(kr,t.__scopePopover);return e.createElement(ke,{present:o||s.open},s.modal?e.createElement(Lr,X({},i,{ref:n})):e.createElement(Mr,X({},i,{ref:n})))})),Lr=e.forwardRef(((t,n)=>{const r=Tr(kr,t.__scopePopover),o=e.useRef(null),i=J(n,o),s=e.useRef(!1);return e.useEffect((()=>{const e=o.current;if(e)return Pt(e)}),[]),e.createElement(gt,{as:se,allowPinchZoom:!0},e.createElement(Ir,X({},t,{ref:i,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Q(t.onCloseAutoFocus,(e=>{var t;e.preventDefault(),s.current||null===(t=r.triggerRef.current)||void 0===t||t.focus()})),onPointerDownOutside:Q(t.onPointerDownOutside,(e=>{const t=e.detail.originalEvent,n=0===t.button&&!0===t.ctrlKey,r=2===t.button||n;s.current=r}),{checkForDefaultPrevented:!1}),onFocusOutside:Q(t.onFocusOutside,(e=>e.preventDefault()),{checkForDefaultPrevented:!1})})))})),Mr=e.forwardRef(((t,n)=>{const r=Tr(kr,t.__scopePopover),o=e.useRef(!1);return e.createElement(Ir,X({},t,{ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:e=>{var n,i;(null===(n=t.onCloseAutoFocus)||void 0===n||n.call(t,e),e.defaultPrevented)||(o.current||null===(i=r.triggerRef.current)||void 0===i||i.focus(),e.preventDefault());o.current=!1},onInteractOutside:e=>{var n,i;null===(n=t.onInteractOutside)||void 0===n||n.call(t,e),e.defaultPrevented||(o.current=!0);const s=e.target;(null===(i=r.triggerRef.current)||void 0===i?void 0:i.contains(s))&&e.preventDefault()}}))})),Ir=e.forwardRef(((t,n)=>{const{__scopePopover:r,trapFocus:o,onOpenAutoFocus:i,onCloseAutoFocus:s,disableOutsidePointerEvents:a,onEscapeKeyDown:l,onPointerDownOutside:c,onFocusOutside:u,onInteractOutside:d,...f}=t,p=Tr(kr,r),h=Pr(r);return Me(),e.createElement(Se,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:i,onUnmountAutoFocus:s},e.createElement(ge,{asChild:!0,disableOutsidePointerEvents:a,onInteractOutside:d,onEscapeKeyDown:l,onPointerDownOutside:c,onFocusOutside:u,onDismiss:()=>p.onOpenChange(!1)},e.createElement(br,X({"data-state":Vr(p.open),role:"dialog",id:p.contentId},h,f,{ref:n,style:{...f.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}}))))}));function Vr(e){return e?"open":"closed"}const $r=t=>{const{__scopePopover:n,children:r,open:o,defaultOpen:i,onOpenChange:s,modal:a=!1}=t,l=Pr(n),c=e.useRef(null),[u,d]=e.useState(!1),[f=!1,p]=ie({prop:o,defaultProp:i,onChange:s});return e.createElement(gr,l,e.createElement(Cr,{scope:n,contentId:re(),triggerRef:c,open:f,onOpenChange:p,onOpenToggle:e.useCallback((()=>p((e=>!e))),[p]),hasCustomAnchor:u,onCustomAnchorAdd:e.useCallback((()=>d(!0)),[]),onCustomAnchorRemove:e.useCallback((()=>d(!1)),[]),modal:a},r))},Nr=Rr,Fr=t=>{const{__scopePopover:n,forceMount:r,children:o,container:i}=t,s=Tr(Ar,n);return e.createElement(Or,{scope:n,forceMount:r},e.createElement(ke,{present:r||s.open},e.createElement(De,{asChild:!0,container:i},o)))},jr=_r,Br=e.forwardRef(((t,n)=>{const{__scopePopover:r,...o}=t,i=Tr("PopoverClose",r);return e.createElement(de.button,X({type:"button"},o,{ref:n,onClick:Q(t.onClick,(()=>i.onOpenChange(!1)))}))})),Wr=e.forwardRef(((t,n)=>{const{__scopePopover:r,...o}=t,i=Pr(r);return e.createElement(wr,X({},i,o,{ref:n}))})),Hr="Progress",Ur=100,[zr,Yr]=q(Hr),[Kr,Xr]=zr(Hr),qr=e.forwardRef(((t,n)=>{const{__scopeProgress:r,value:o,max:i,getValueLabel:s=Gr,...a}=t,l=Qr(i)?i:Ur,c=eo(o,l)?o:null,u=Jr(c)?s(c,l):void 0;return e.createElement(Kr,{scope:r,value:c,max:l},e.createElement(de.div,X({"aria-valuemax":l,"aria-valuemin":0,"aria-valuenow":Jr(c)?c:void 0,"aria-valuetext":u,role:"progressbar","data-state":Zr(c,l),"data-value":null!=c?c:void 0,"data-max":l},a,{ref:n})))}));qr.propTypes={max(e,t,n){const r=e[t],o=String(r);return r&&!Qr(r)?new Error(function(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`100\`.`}(o,n)):null},value(e,t,n){const r=e[t],o=String(r),i=Qr(e.max)?e.max:Ur;return null==r||eo(r,i)?null:new Error(function(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:\n - a positive number\n - less than the value passed to \`max\` (or 100 if no \`max\` prop is set)\n - \`null\` if the progress is indeterminate.\n\nDefaulting to \`null\`.`}(o,n))}};function Gr(e,t){return`${Math.round(e/t*100)}%`}function Zr(e,t){return null==e?"indeterminate":e===t?"complete":"loading"}function Jr(e){return"number"==typeof e}function Qr(e){return Jr(e)&&!isNaN(e)&&e>0}function eo(e,t){return Jr(e)&&!isNaN(e)&&e<=t&&e>=0}const to=qr,no=e.forwardRef(((t,n)=>{var r;const{__scopeProgress:o,...i}=t,s=Xr("ProgressIndicator",o);return e.createElement(de.div,X({"data-state":Zr(s.value,s.max),"data-value":null!==(r=s.value)&&void 0!==r?r:void 0,"data-max":s.max},i,{ref:n}))}));function ro(t){const n=e.useRef({value:t,previous:t});return e.useMemo((()=>(n.current.value!==t&&(n.current.previous=n.current.value,n.current.value=t),n.current.previous)),[t])}const oo="Checkbox",[io,so]=q(oo),[ao,lo]=io(oo),co=e.forwardRef(((t,n)=>{const{__scopeCheckbox:r,name:o,checked:i,defaultChecked:s,required:a,disabled:l,value:c="on",onCheckedChange:u,...d}=t,[f,p]=e.useState(null),h=J(n,(e=>p(e))),m=e.useRef(!1),v=!f||Boolean(f.closest("form")),[g=!1,y]=ie({prop:i,defaultProp:s,onChange:u}),b=e.useRef(g);return e.useEffect((()=>{const e=null==f?void 0:f.form;if(e){const t=()=>y(b.current);return e.addEventListener("reset",t),()=>e.removeEventListener("reset",t)}}),[f,y]),e.createElement(ao,{scope:r,state:g,disabled:l},e.createElement(de.button,X({type:"button",role:"checkbox","aria-checked":fo(g)?"mixed":g,"aria-required":a,"data-state":po(g),"data-disabled":l?"":void 0,disabled:l,value:c},d,{ref:h,onKeyDown:Q(t.onKeyDown,(e=>{"Enter"===e.key&&e.preventDefault()})),onClick:Q(t.onClick,(e=>{y((e=>!!fo(e)||!e)),v&&(m.current=e.isPropagationStopped(),m.current||e.stopPropagation())}))})),v&&e.createElement(uo,{control:f,bubbles:!m.current,name:o,value:c,checked:g,required:a,disabled:l,style:{transform:"translateX(-100%)"}}))})),uo=t=>{const{control:n,checked:r,bubbles:o=!0,...i}=t,s=e.useRef(null),a=ro(r),l=Jn(n);return e.useEffect((()=>{const e=s.current,t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,"checked").set;if(a!==r&&n){const t=new Event("click",{bubbles:o});e.indeterminate=fo(r),n.call(e,!fo(r)&&r),e.dispatchEvent(t)}}),[a,r,o]),e.createElement("input",X({type:"checkbox","aria-hidden":!0,defaultChecked:!fo(r)&&r},i,{tabIndex:-1,ref:s,style:{...t.style,...l,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function fo(e){return"indeterminate"===e}function po(e){return fo(e)?"indeterminate":e?"checked":"unchecked"}const ho=co,mo=e.forwardRef(((t,n)=>{const{__scopeCheckbox:r,forceMount:o,...i}=t,s=lo("CheckboxIndicator",r);return e.createElement(ke,{present:o||fo(s.state)||!0===s.state},e.createElement(de.span,X({"data-state":po(s.state),"data-disabled":s.disabled?"":void 0},i,{ref:n,style:{pointerEvents:"none",...t.style}})))}));function vo(e,[t,n]){return Math.min(n,Math.max(t,e))}const go=e.createContext(void 0);function yo(t){const n=e.useContext(go);return t||n||"ltr"}const bo=["PageUp","PageDown"],wo=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],xo={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},Eo="Slider",[So,Po,Co]=function(t){const n=t+"CollectionProvider",[r,o]=q(n),[i,s]=r(n,{collectionRef:{current:null},itemMap:new Map}),a=t+"CollectionSlot",l=t+"CollectionItemSlot",c="data-radix-collection-item";return[{Provider:t=>{const{scope:n,children:r}=t,o=e.useRef(null),s=e.useRef(new Map).current;return e.createElement(i,{scope:n,itemMap:s,collectionRef:o},r)},Slot:e.forwardRef(((t,n)=>{const{scope:r,children:o}=t,i=J(n,s(a,r).collectionRef);return e.createElement(se,{ref:i},o)})),ItemSlot:e.forwardRef(((t,n)=>{const{scope:r,children:o,...i}=t,a=e.useRef(null),u=J(n,a),d=s(l,r);return e.useEffect((()=>(d.itemMap.set(a,{ref:a,...i}),()=>{d.itemMap.delete(a)}))),e.createElement(se,{[c]:"",ref:u},o)}))},function(n){const r=s(t+"CollectionConsumer",n);return e.useCallback((()=>{const e=r.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${c}]`));return Array.from(r.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)))}),[r.collectionRef,r.itemMap])},o]}(Eo),[To,Ro]=q(Eo,[Co]),[Ao,Oo]=To(Eo),Do=e.forwardRef(((t,n)=>{const{name:r,min:o=0,max:i=100,step:s=1,orientation:a="horizontal",disabled:l=!1,minStepsBetweenThumbs:c=0,defaultValue:u=[o],value:d,onValueChange:f=(()=>{}),onValueCommit:p=(()=>{}),inverted:h=!1,...m}=t,[v,g]=e.useState(null),y=J(n,(e=>g(e))),b=e.useRef(new Set),w=e.useRef(0),x="horizontal"===a,E=!v||Boolean(v.closest("form")),S=x?Lo:Mo,[P=[],C]=ie({prop:d,defaultProp:u,onChange:e=>{var t;null===(t=[...b.current][w.current])||void 0===t||t.focus(),f(e)}}),T=e.useRef(P);function R(e,t,{commit:n}={commit:!1}){const r=function(e){return(String(e).split(".")[1]||"").length}(s),a=function(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}(Math.round((e-o)/s)*s+o,r),l=vo(a,[o,i]);C(((e=[])=>{const r=function(e=[],t,n){const r=[...e];return r[n]=t,r.sort(((e,t)=>e-t))}(e,l,t);if(function(e,t){if(t>0){const n=function(e){return e.slice(0,-1).map(((t,n)=>e[n+1]-t))}(e);return Math.min(...n)>=t}return!0}(r,c*s)){w.current=r.indexOf(l);const t=String(r)!==String(e);return t&&n&&p(r),t?r:e}return e}))}return e.createElement(Ao,{scope:t.__scopeSlider,disabled:l,min:o,max:i,valueIndexToChangeRef:w,thumbs:b.current,values:P,orientation:a},e.createElement(So.Provider,{scope:t.__scopeSlider},e.createElement(So.Slot,{scope:t.__scopeSlider},e.createElement(S,X({"aria-disabled":l,"data-disabled":l?"":void 0},m,{ref:y,onPointerDown:Q(m.onPointerDown,(()=>{l||(T.current=P)})),min:o,max:i,inverted:h,onSlideStart:l?void 0:function(e){const t=function(e,t){if(1===e.length)return 0;const n=e.map((e=>Math.abs(e-t))),r=Math.min(...n);return n.indexOf(r)}(P,e);R(e,t)},onSlideMove:l?void 0:function(e){R(e,w.current)},onSlideEnd:l?void 0:function(){const e=T.current[w.current];P[w.current]!==e&&p(P)},onHomeKeyDown:()=>!l&&R(o,0,{commit:!0}),onEndKeyDown:()=>!l&&R(i,P.length-1,{commit:!0}),onStepKeyDown:({event:e,direction:t})=>{if(!l){const n=bo.includes(e.key)||e.shiftKey&&wo.includes(e.key)?10:1,r=w.current;R(P[r]+s*n*t,r,{commit:!0})}}})))),E&&P.map(((t,n)=>e.createElement(Wo,{key:n,name:r?r+(P.length>1?"[]":""):void 0,value:t}))))})),[ko,_o]=To(Eo,{startEdge:"left",endEdge:"right",size:"width",direction:1}),Lo=e.forwardRef(((t,n)=>{const{min:r,max:o,dir:i,inverted:s,onSlideStart:a,onSlideMove:l,onSlideEnd:c,onStepKeyDown:u,...d}=t,[f,p]=e.useState(null),h=J(n,(e=>p(e))),m=e.useRef(),v=yo(i),g="ltr"===v,y=g&&!s||!g&&s;function b(e){const t=m.current||f.getBoundingClientRect(),n=Uo([0,t.width],y?[r,o]:[o,r]);return m.current=t,n(e-t.left)}return e.createElement(ko,{scope:t.__scopeSlider,startEdge:y?"left":"right",endEdge:y?"right":"left",direction:y?1:-1,size:"width"},e.createElement(Io,X({dir:v,"data-orientation":"horizontal"},d,{ref:h,style:{...d.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:e=>{const t=b(e.clientX);null==a||a(t)},onSlideMove:e=>{const t=b(e.clientX);null==l||l(t)},onSlideEnd:()=>{m.current=void 0,null==c||c()},onStepKeyDown:e=>{const t=xo[y?"from-left":"from-right"].includes(e.key);null==u||u({event:e,direction:t?-1:1})}})))})),Mo=e.forwardRef(((t,n)=>{const{min:r,max:o,inverted:i,onSlideStart:s,onSlideMove:a,onSlideEnd:l,onStepKeyDown:c,...u}=t,d=e.useRef(null),f=J(n,d),p=e.useRef(),h=!i;function m(e){const t=p.current||d.current.getBoundingClientRect(),n=Uo([0,t.height],h?[o,r]:[r,o]);return p.current=t,n(e-t.top)}return e.createElement(ko,{scope:t.__scopeSlider,startEdge:h?"bottom":"top",endEdge:h?"top":"bottom",size:"height",direction:h?1:-1},e.createElement(Io,X({"data-orientation":"vertical"},u,{ref:f,style:{...u.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:e=>{const t=m(e.clientY);null==s||s(t)},onSlideMove:e=>{const t=m(e.clientY);null==a||a(t)},onSlideEnd:()=>{p.current=void 0,null==l||l()},onStepKeyDown:e=>{const t=xo[h?"from-bottom":"from-top"].includes(e.key);null==c||c({event:e,direction:t?-1:1})}})))})),Io=e.forwardRef(((t,n)=>{const{__scopeSlider:r,onSlideStart:o,onSlideMove:i,onSlideEnd:s,onHomeKeyDown:a,onEndKeyDown:l,onStepKeyDown:c,...u}=t,d=Oo(Eo,r);return e.createElement(de.span,X({},u,{ref:n,onKeyDown:Q(t.onKeyDown,(e=>{"Home"===e.key?(a(e),e.preventDefault()):"End"===e.key?(l(e),e.preventDefault()):bo.concat(wo).includes(e.key)&&(c(e),e.preventDefault())})),onPointerDown:Q(t.onPointerDown,(e=>{const t=e.target;t.setPointerCapture(e.pointerId),e.preventDefault(),d.thumbs.has(t)?t.focus():o(e)})),onPointerMove:Q(t.onPointerMove,(e=>{e.target.hasPointerCapture(e.pointerId)&&i(e)})),onPointerUp:Q(t.onPointerUp,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&(t.releasePointerCapture(e.pointerId),s(e))}))}))})),Vo=e.forwardRef(((t,n)=>{const{__scopeSlider:r,...o}=t,i=Oo("SliderTrack",r);return e.createElement(de.span,X({"data-disabled":i.disabled?"":void 0,"data-orientation":i.orientation},o,{ref:n}))})),$o="SliderRange",No=e.forwardRef(((t,n)=>{const{__scopeSlider:r,...o}=t,i=Oo($o,r),s=_o($o,r),a=J(n,e.useRef(null)),l=i.values.length,c=i.values.map((e=>Ho(e,i.min,i.max))),u=l>1?Math.min(...c):0,d=100-Math.max(...c);return e.createElement(de.span,X({"data-orientation":i.orientation,"data-disabled":i.disabled?"":void 0},o,{ref:a,style:{...t.style,[s.startEdge]:u+"%",[s.endEdge]:d+"%"}}))})),Fo="SliderThumb",jo=e.forwardRef(((t,n)=>{const r=Po(t.__scopeSlider),[o,i]=e.useState(null),s=J(n,(e=>i(e))),a=e.useMemo((()=>o?r().findIndex((e=>e.ref.current===o)):-1),[r,o]);return e.createElement(Bo,X({},t,{ref:s,index:a}))})),Bo=e.forwardRef(((t,n)=>{const{__scopeSlider:r,index:o,...i}=t,s=Oo(Fo,r),a=_o(Fo,r),[l,c]=e.useState(null),u=J(n,(e=>c(e))),d=Jn(l),f=s.values[o],p=void 0===f?0:Ho(f,s.min,s.max),h=function(e,t){return t>2?`Value ${e+1} of ${t}`:2===t?["Minimum","Maximum"][e]:void 0}(o,s.values.length),m=null==d?void 0:d[a.size],v=m?function(e,t,n){const r=e/2,o=Uo([0,50],[0,r]);return(r-o(t)*n)*n}(m,p,a.direction):0;return e.useEffect((()=>{if(l)return s.thumbs.add(l),()=>{s.thumbs.delete(l)}}),[l,s.thumbs]),e.createElement("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[a.startEdge]:`calc(${p}% + ${v}px)`}},e.createElement(So.ItemSlot,{scope:t.__scopeSlider},e.createElement(de.span,X({role:"slider","aria-label":t["aria-label"]||h,"aria-valuemin":s.min,"aria-valuenow":f,"aria-valuemax":s.max,"aria-orientation":s.orientation,"data-orientation":s.orientation,"data-disabled":s.disabled?"":void 0,tabIndex:s.disabled?void 0:0},i,{ref:u,style:void 0===f?{display:"none"}:t.style,onFocus:Q(t.onFocus,(()=>{s.valueIndexToChangeRef.current=o}))}))))})),Wo=t=>{const{value:n,...r}=t,o=e.useRef(null),i=ro(n);return e.useEffect((()=>{const e=o.current,t=window.HTMLInputElement.prototype,r=Object.getOwnPropertyDescriptor(t,"value").set;if(i!==n&&r){const t=new Event("input",{bubbles:!0});r.call(e,n),e.dispatchEvent(t)}}),[i,n]),e.createElement("input",X({style:{display:"none"}},r,{ref:o,defaultValue:n}))};function Ho(e,t,n){return 100/(n-t)*(e-t)}function Uo(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}const zo=Do,Yo=Vo,Ko=No,Xo=jo;function qo(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(null==e||e(r),!1===n||!r.defaultPrevented)return null==t?void 0:t(r)}}function Go(...e){return t=>e.forEach((e=>function(e,t){"function"==typeof e?e(t):null!=e&&(e.current=t)}(e,t)))}function Zo(...t){return e.useCallback(Go(...t),t)}function Jo(t,n=[]){let r=[];const o=()=>{const n=r.map((t=>e.createContext(t)));return function(r){const o=(null==r?void 0:r[t])||n;return e.useMemo((()=>({[`__scope${t}`]:{...r,[t]:o}})),[r,o])}};return o.scopeName=t,[function(n,o){const i=e.createContext(o),s=r.length;function a(n){const{scope:r,children:o,...a}=n,l=(null==r?void 0:r[t][s])||i,c=e.useMemo((()=>a),Object.values(a));return e.createElement(l.Provider,{value:c},o)}return r=[...r,o],a.displayName=n+"Provider",[a,function(r,a){const l=(null==a?void 0:a[t][s])||i,c=e.useContext(l);if(c)return c;if(void 0!==o)return o;throw new Error(`\`${r}\` must be used within \`${n}\``)}]},Qo(o,...n)]}function Qo(...t){const n=t[0];if(1===t.length)return n;const r=()=>{const r=t.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(t){const o=r.reduce(((e,{useScope:n,scopeName:r})=>({...e,...n(t)[`__scope${r}`]})),{});return e.useMemo((()=>({[`__scope${n.scopeName}`]:o})),[o])}};return r.scopeName=n.scopeName,r}const ei=e.forwardRef(((t,n)=>{const{children:r,...o}=t,i=e.Children.toArray(r),s=i.find(ri);if(s){const t=s.props.children,r=i.map((n=>n===s?e.Children.count(t)>1?e.Children.only(null):e.isValidElement(t)?t.props.children:null:n));return e.createElement(ti,X({},o,{ref:n}),e.isValidElement(t)?e.cloneElement(t,void 0,r):null)}return e.createElement(ti,X({},o,{ref:n}),r)}));ei.displayName="Slot";const ti=e.forwardRef(((t,n)=>{const{children:r,...o}=t;return e.isValidElement(r)?e.cloneElement(r,{...oi(o,r.props),ref:n?Go(n,r.ref):r.ref}):e.Children.count(r)>1?e.Children.only(null):null}));ti.displayName="SlotClone";const ni=({children:t})=>e.createElement(e.Fragment,null,t);function ri(t){return e.isValidElement(t)&&t.type===ni}function oi(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...e)=>{i(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...i}:"className"===r&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}const ii=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((t,n)=>{const r=e.forwardRef(((t,r)=>{const{asChild:o,...i}=t,s=o?ei:n;return e.useEffect((()=>{window[Symbol.for("radix-ui")]=!0}),[]),e.createElement(s,X({},i,{ref:r}))}));return r.displayName=`Primitive.${n}`,{...t,[n]:r}}),{});function si(t){const n=t+"CollectionProvider",[r,o]=Jo(n),[i,s]=r(n,{collectionRef:{current:null},itemMap:new Map}),a=t+"CollectionSlot",l=t+"CollectionItemSlot",c="data-radix-collection-item";return[{Provider:t=>{const{scope:n,children:r}=t,o=e.useRef(null),s=e.useRef(new Map).current;return e.createElement(i,{scope:n,itemMap:s,collectionRef:o},r)},Slot:e.forwardRef(((t,n)=>{const{scope:r,children:o}=t,i=Zo(n,s(a,r).collectionRef);return e.createElement(ei,{ref:i},o)})),ItemSlot:e.forwardRef(((t,n)=>{const{scope:r,children:o,...i}=t,a=e.useRef(null),u=Zo(n,a),d=s(l,r);return e.useEffect((()=>(d.itemMap.set(a,{ref:a,...i}),()=>{d.itemMap.delete(a)}))),e.createElement(ei,{[c]:"",ref:u},o)}))},function(n){const r=s(t+"CollectionConsumer",n);return e.useCallback((()=>{const e=r.collectionRef.current;if(!e)return[];const t=Array.from(e.querySelectorAll(`[${c}]`));return Array.from(r.itemMap.values()).sort(((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current)))}),[r.collectionRef,r.itemMap])},o]}const ai=Boolean(null===globalThis||void 0===globalThis?void 0:globalThis.document)?e.useLayoutEffect:()=>{},li=r["useId".toString()]||(()=>{});let ci=0;function ui(e){const[t,n]=r.useState(li());return ai((()=>{e||n((e=>null!=e?e:String(ci++)))}),[e]),e||(t?`radix-${t}`:"")}function di(t){const n=e.useRef(t);return e.useEffect((()=>{n.current=t})),e.useMemo((()=>(...e)=>{var t;return null===(t=n.current)||void 0===t?void 0:t.call(n,...e)}),[])}function fi({prop:t,defaultProp:n,onChange:r=(()=>{})}){const[o,i]=function({defaultProp:t,onChange:n}){const r=e.useState(t),[o]=r,i=e.useRef(o),s=di(n);return e.useEffect((()=>{i.current!==o&&(s(o),i.current=o)}),[o,i,s]),r}({defaultProp:n,onChange:r}),s=void 0!==t,a=s?t:o,l=di(r);return[a,e.useCallback((e=>{if(s){const n="function"==typeof e?e(t):e;n!==t&&l(n)}else i(e)}),[s,t,i,l])]}const pi=e.createContext(void 0);function hi(t){const n=e.useContext(pi);return t||n||"ltr"}const mi="rovingFocusGroup.onEntryFocus",vi={bubbles:!1,cancelable:!0},gi="RovingFocusGroup",[yi,bi,wi]=si(gi),[xi,Ei]=Jo(gi,[wi]),[Si,Pi]=xi(gi),Ci=e.forwardRef(((t,n)=>e.createElement(yi.Provider,{scope:t.__scopeRovingFocusGroup},e.createElement(yi.Slot,{scope:t.__scopeRovingFocusGroup},e.createElement(Ti,X({},t,{ref:n})))))),Ti=e.forwardRef(((t,n)=>{const{__scopeRovingFocusGroup:r,orientation:o,loop:i=!1,dir:s,currentTabStopId:a,defaultCurrentTabStopId:l,onCurrentTabStopIdChange:c,onEntryFocus:u,...d}=t,f=e.useRef(null),p=Zo(n,f),h=hi(s),[m=null,v]=fi({prop:a,defaultProp:l,onChange:c}),[g,y]=e.useState(!1),b=di(u),w=bi(r),x=e.useRef(!1),[E,S]=e.useState(0);return e.useEffect((()=>{const e=f.current;if(e)return e.addEventListener(mi,b),()=>e.removeEventListener(mi,b)}),[b]),e.createElement(Si,{scope:r,orientation:o,dir:h,loop:i,currentTabStopId:m,onItemFocus:e.useCallback((e=>v(e)),[v]),onItemShiftTab:e.useCallback((()=>y(!0)),[]),onFocusableItemAdd:e.useCallback((()=>S((e=>e+1))),[]),onFocusableItemRemove:e.useCallback((()=>S((e=>e-1))),[])},e.createElement(ii.div,X({tabIndex:g||0===E?-1:0,"data-orientation":o},d,{ref:p,style:{outline:"none",...t.style},onMouseDown:qo(t.onMouseDown,(()=>{x.current=!0})),onFocus:qo(t.onFocus,(e=>{const t=!x.current;if(e.target===e.currentTarget&&t&&!g){const t=new CustomEvent(mi,vi);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){const e=w().filter((e=>e.focusable));Oi([e.find((e=>e.active)),e.find((e=>e.id===m)),...e].filter(Boolean).map((e=>e.ref.current)))}}x.current=!1})),onBlur:qo(t.onBlur,(()=>y(!1)))})))})),Ri=e.forwardRef(((t,n)=>{const{__scopeRovingFocusGroup:r,focusable:o=!0,active:i=!1,tabStopId:s,...a}=t,l=ui(),c=s||l,u=Pi("RovingFocusGroupItem",r),d=u.currentTabStopId===c,f=bi(r),{onFocusableItemAdd:p,onFocusableItemRemove:h}=u;return e.useEffect((()=>{if(o)return p(),()=>h()}),[o,p,h]),e.createElement(yi.ItemSlot,{scope:r,id:c,focusable:o,active:i},e.createElement(ii.span,X({tabIndex:d?0:-1,"data-orientation":u.orientation},a,{ref:n,onMouseDown:qo(t.onMouseDown,(e=>{o?u.onItemFocus(c):e.preventDefault()})),onFocus:qo(t.onFocus,(()=>u.onItemFocus(c))),onKeyDown:qo(t.onKeyDown,(e=>{if("Tab"===e.key&&e.shiftKey)return void u.onItemShiftTab();if(e.target!==e.currentTarget)return;const t=function(e,t,n){const r=function(e,t){return"rtl"!==t?e:"ArrowLeft"===e?"ArrowRight":"ArrowRight"===e?"ArrowLeft":e}(e.key,n);return"vertical"===t&&["ArrowLeft","ArrowRight"].includes(r)||"horizontal"===t&&["ArrowUp","ArrowDown"].includes(r)?void 0:Ai[r]}(e,u.orientation,u.dir);if(void 0!==t){e.preventDefault();let o=f().filter((e=>e.focusable)).map((e=>e.ref.current));if("last"===t)o.reverse();else if("prev"===t||"next"===t){"prev"===t&&o.reverse();const i=o.indexOf(e.currentTarget);o=u.loop?(r=i+1,(n=o).map(((e,t)=>n[(r+t)%n.length]))):o.slice(i+1)}setTimeout((()=>Oi(o)))}var n,r}))})))})),Ai={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Oi(e){const t=document.activeElement;for(const n of e){if(n===t)return;if(n.focus(),document.activeElement!==t)return}}const Di=Ci,ki=Ri;function _i(t){const[n,r]=e.useState(void 0);return ai((()=>{if(t){r({width:t.offsetWidth,height:t.offsetHeight});const e=new ResizeObserver((e=>{if(!Array.isArray(e))return;if(!e.length)return;const n=e[0];let o,i;if("borderBoxSize"in n){const e=n.borderBoxSize,t=Array.isArray(e)?e[0]:e;o=t.inlineSize,i=t.blockSize}else o=t.offsetWidth,i=t.offsetHeight;r({width:o,height:i})}));return e.observe(t,{box:"border-box"}),()=>e.unobserve(t)}r(void 0)}),[t]),n}function Li(t){const n=e.useRef({value:t,previous:t});return e.useMemo((()=>(n.current.value!==t&&(n.current.previous=n.current.value,n.current.value=t),n.current.previous)),[t])}const Mi=n=>{const{present:r,children:o}=n,i=function(n){const[r,o]=e.useState(),i=e.useRef({}),s=e.useRef(n),a=e.useRef("none"),l=n?"mounted":"unmounted",[c,u]=function(t,n){return e.useReducer(((e,t)=>{const r=n[e][t];return null!=r?r:e}),t)}(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return e.useEffect((()=>{const e=Ii(i.current);a.current="mounted"===c?e:"none"}),[c]),ai((()=>{const e=i.current,t=s.current;if(t!==n){const r=a.current,o=Ii(e);if(n)u("MOUNT");else if("none"===o||"none"===(null==e?void 0:e.display))u("UNMOUNT");else{u(t&&r!==o?"ANIMATION_OUT":"UNMOUNT")}s.current=n}}),[n,u]),ai((()=>{if(r){const e=e=>{const n=Ii(i.current).includes(e.animationName);e.target===r&&n&&t.flushSync((()=>u("ANIMATION_END")))},n=e=>{e.target===r&&(a.current=Ii(i.current))};return r.addEventListener("animationstart",n),r.addEventListener("animationcancel",e),r.addEventListener("animationend",e),()=>{r.removeEventListener("animationstart",n),r.removeEventListener("animationcancel",e),r.removeEventListener("animationend",e)}}u("ANIMATION_END")}),[r,u]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:e.useCallback((e=>{e&&(i.current=getComputedStyle(e)),o(e)}),[])}}(r),s="function"==typeof o?o({present:i.isPresent}):e.Children.only(o),a=Zo(i.ref,s.ref);return"function"==typeof o||i.isPresent?e.cloneElement(s,{ref:a}):null};function Ii(e){return(null==e?void 0:e.animationName)||"none"}Mi.displayName="Presence";const Vi="Radio",[$i,Ni]=Jo(Vi),[Fi,ji]=$i(Vi),Bi=e.forwardRef(((t,n)=>{const{__scopeRadio:r,name:o,checked:i=!1,required:s,disabled:a,value:l="on",onCheck:c,...u}=t,[d,f]=e.useState(null),p=Zo(n,(e=>f(e))),h=e.useRef(!1),m=!d||Boolean(d.closest("form"));return e.createElement(Fi,{scope:r,checked:i,disabled:a},e.createElement(ii.button,X({type:"button",role:"radio","aria-checked":i,"data-state":Ui(i),"data-disabled":a?"":void 0,disabled:a,value:l},u,{ref:p,onClick:qo(t.onClick,(e=>{i||null==c||c(),m&&(h.current=e.isPropagationStopped(),h.current||e.stopPropagation())}))})),m&&e.createElement(Hi,{control:d,bubbles:!h.current,name:o,value:l,checked:i,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))})),Wi=e.forwardRef(((t,n)=>{const{__scopeRadio:r,forceMount:o,...i}=t,s=ji("RadioIndicator",r);return e.createElement(Mi,{present:o||s.checked},e.createElement(ii.span,X({"data-state":Ui(s.checked),"data-disabled":s.disabled?"":void 0},i,{ref:n})))})),Hi=t=>{const{control:n,checked:r,bubbles:o=!0,...i}=t,s=e.useRef(null),a=Li(r),l=_i(n);return e.useEffect((()=>{const e=s.current,t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,"checked").set;if(a!==r&&n){const t=new Event("click",{bubbles:o});n.call(e,r),e.dispatchEvent(t)}}),[a,r,o]),e.createElement("input",X({type:"radio","aria-hidden":!0,defaultChecked:r},i,{tabIndex:-1,ref:s,style:{...t.style,...l,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ui(e){return e?"checked":"unchecked"}const zi=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Yi="RadioGroup",[Ki,Xi]=Jo(Yi,[Ei,Ni]),qi=Ei(),Gi=Ni(),[Zi,Ji]=Ki(Yi),Qi=e.forwardRef(((t,n)=>{const{__scopeRadioGroup:r,name:o,defaultValue:i,value:s,required:a=!1,disabled:l=!1,orientation:c,dir:u,loop:d=!0,onValueChange:f,...p}=t,h=qi(r),m=hi(u),[v,g]=fi({prop:s,defaultProp:i,onChange:f});return e.createElement(Zi,{scope:r,name:o,required:a,disabled:l,value:v,onValueChange:g},e.createElement(Di,X({asChild:!0},h,{orientation:c,dir:m,loop:d}),e.createElement(ii.div,X({role:"radiogroup","aria-required":a,"aria-orientation":c,"data-disabled":l?"":void 0,dir:m},p,{ref:n}))))})),es=e.forwardRef(((t,n)=>{const{__scopeRadioGroup:r,disabled:o,...i}=t,s=Ji("RadioGroupItem",r),a=s.disabled||o,l=qi(r),c=Gi(r),u=e.useRef(null),d=Zo(n,u),f=s.value===i.value,p=e.useRef(!1);return e.useEffect((()=>{const e=e=>{zi.includes(e.key)&&(p.current=!0)},t=()=>p.current=!1;return document.addEventListener("keydown",e),document.addEventListener("keyup",t),()=>{document.removeEventListener("keydown",e),document.removeEventListener("keyup",t)}}),[]),e.createElement(ki,X({asChild:!0},l,{focusable:!a,active:f}),e.createElement(Bi,X({disabled:a,required:s.required,checked:f},c,i,{name:s.name,ref:d,onCheck:()=>s.onValueChange(i.value),onKeyDown:qo((e=>{"Enter"===e.key&&e.preventDefault()})),onFocus:qo(i.onFocus,(()=>{var e;p.current&&(null===(e=u.current)||void 0===e||e.click())}))})))})),ts=e.forwardRef(((t,n)=>{const{__scopeRadioGroup:r,...o}=t,i=Gi(r);return e.createElement(Wi,X({},i,o,{ref:n}))}));function ns(e,[t,n]){return Math.min(n,Math.max(t,e))}const rs="dismissableLayer.update",os="dismissableLayer.pointerDownOutside",is="dismissableLayer.focusOutside";let ss;const as=e.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),ls=e.forwardRef(((t,n)=>{var r;const{disableOutsidePointerEvents:o=!1,onEscapeKeyDown:i,onPointerDownOutside:s,onFocusOutside:a,onInteractOutside:l,onDismiss:c,...u}=t,d=e.useContext(as),[f,p]=e.useState(null),h=null!==(r=null==f?void 0:f.ownerDocument)&&void 0!==r?r:null===globalThis||void 0===globalThis?void 0:globalThis.document,[,m]=e.useState({}),v=Zo(n,(e=>p(e))),g=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=g.indexOf(y),w=f?g.indexOf(f):-1,x=d.layersWithOutsidePointerEventsDisabled.size>0,E=w>=b,S=function(t,n=(null===globalThis||void 0===globalThis?void 0:globalThis.document)){const r=di(t),o=e.useRef(!1),i=e.useRef((()=>{}));return e.useEffect((()=>{const e=e=>{if(e.target&&!o.current){let t=function(){us(os,r,o,{discrete:!0})};const o={originalEvent:e};"touch"===e.pointerType?(n.removeEventListener("click",i.current),i.current=t,n.addEventListener("click",i.current,{once:!0})):t()}o.current=!1},t=window.setTimeout((()=>{n.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(t),n.removeEventListener("pointerdown",e),n.removeEventListener("click",i.current)}}),[n,r]),{onPointerDownCapture:()=>o.current=!0}}((e=>{const t=e.target,n=[...d.branches].some((e=>e.contains(t)));E&&!n&&(null==s||s(e),null==l||l(e),e.defaultPrevented||null==c||c())}),h),P=function(t,n=(null===globalThis||void 0===globalThis?void 0:globalThis.document)){const r=di(t),o=e.useRef(!1);return e.useEffect((()=>{const e=e=>{if(e.target&&!o.current){us(is,r,{originalEvent:e},{discrete:!1})}};return n.addEventListener("focusin",e),()=>n.removeEventListener("focusin",e)}),[n,r]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}((e=>{const t=e.target;[...d.branches].some((e=>e.contains(t)))||(null==a||a(e),null==l||l(e),e.defaultPrevented||null==c||c())}),h);return function(t,n=(null===globalThis||void 0===globalThis?void 0:globalThis.document)){const r=di(t);e.useEffect((()=>{const e=e=>{"Escape"===e.key&&r(e)};return n.addEventListener("keydown",e),()=>n.removeEventListener("keydown",e)}),[r,n])}((e=>{w===d.layers.size-1&&(null==i||i(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))}),h),e.useEffect((()=>{if(f)return o&&(0===d.layersWithOutsidePointerEventsDisabled.size&&(ss=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),cs(),()=>{o&&1===d.layersWithOutsidePointerEventsDisabled.size&&(h.body.style.pointerEvents=ss)}}),[f,h,o,d]),e.useEffect((()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),cs())}),[f,d]),e.useEffect((()=>{const e=()=>m({});return document.addEventListener(rs,e),()=>document.removeEventListener(rs,e)}),[]),e.createElement(ii.div,X({},u,{ref:v,style:{pointerEvents:x?E?"auto":"none":void 0,...t.style},onFocusCapture:qo(t.onFocusCapture,P.onFocusCapture),onBlurCapture:qo(t.onBlurCapture,P.onBlurCapture),onPointerDownCapture:qo(t.onPointerDownCapture,S.onPointerDownCapture)}))}));function cs(){const e=new CustomEvent(rs);document.dispatchEvent(e)}function us(e,n,r,{discrete:o}){const i=r.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});n&&i.addEventListener(e,n,{once:!0}),o?function(e,n){e&&t.flushSync((()=>e.dispatchEvent(n)))}(i,s):i.dispatchEvent(s)}let ds=0;function fs(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}const ps="focusScope.autoFocusOnMount",hs="focusScope.autoFocusOnUnmount",ms={bubbles:!1,cancelable:!0},vs=e.forwardRef(((t,n)=>{const{loop:r=!1,trapped:o=!1,onMountAutoFocus:i,onUnmountAutoFocus:s,...a}=t,[l,c]=e.useState(null),u=di(i),d=di(s),f=e.useRef(null),p=Zo(n,(e=>c(e))),h=e.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;e.useEffect((()=>{if(o){let e=function(e){if(h.paused||!l)return;const t=e.target;l.contains(t)?f.current=t:ws(f.current,{select:!0})},t=function(e){if(h.paused||!l)return;const t=e.relatedTarget;null!==t&&(l.contains(t)||ws(f.current,{select:!0}))},n=function(e){const t=document.activeElement;for(const n of e)n.removedNodes.length>0&&(null!=l&&l.contains(t)||ws(l))};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return l&&r.observe(l,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[o,l,h.paused]),e.useEffect((()=>{if(l){xs.add(h);const t=document.activeElement;if(!l.contains(t)){const n=new CustomEvent(ps,ms);l.addEventListener(ps,u),l.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(ws(r,{select:t}),document.activeElement!==n)return}((e=gs(l),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&ws(l))}return()=>{l.removeEventListener(ps,u),setTimeout((()=>{const e=new CustomEvent(hs,ms);l.addEventListener(hs,d),l.dispatchEvent(e),e.defaultPrevented||ws(null!=t?t:document.body,{select:!0}),l.removeEventListener(hs,d),xs.remove(h)}),0)}}var e}),[l,u,d,h]);const m=e.useCallback((e=>{if(!r&&!o)return;if(h.paused)return;const t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,n=document.activeElement;if(t&&n){const t=e.currentTarget,[o,i]=function(e){const t=gs(e),n=ys(t,e),r=ys(t.reverse(),e);return[n,r]}(t);o&&i?e.shiftKey||n!==i?e.shiftKey&&n===o&&(e.preventDefault(),r&&ws(i,{select:!0})):(e.preventDefault(),r&&ws(o,{select:!0})):n===t&&e.preventDefault()}}),[r,o,h.paused]);return e.createElement(ii.div,X({tabIndex:-1},a,{ref:p,onKeyDown:m}))}));function gs(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{const t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ys(e,t){for(const n of e)if(!bs(n,{upTo:t}))return n}function bs(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function ws(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}const xs=function(){let e=[];return{add(t){const n=e[0];t!==n&&(null==n||n.pause()),e=Es(e,t),e.unshift(t)},remove(t){var n;e=Es(e,t),null===(n=e[0])||void 0===n||n.resume()}}}();function Es(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}function Ss(e){return e.split("-")[1]}function Ps(e){return"y"===e?"height":"width"}function Cs(e){return e.split("-")[0]}function Ts(e){return["top","bottom"].includes(Cs(e))?"x":"y"}function Rs(e,t,n){let{reference:r,floating:o}=e;const i=r.x+r.width/2-o.width/2,s=r.y+r.height/2-o.height/2,a=Ts(t),l=Ps(a),c=r[l]/2-o[l]/2,u="x"===a;let d;switch(Cs(t)){case"top":d={x:i,y:r.y-o.height};break;case"bottom":d={x:i,y:r.y+r.height};break;case"right":d={x:r.x+r.width,y:s};break;case"left":d={x:r.x-o.width,y:s};break;default:d={x:r.x,y:r.y}}switch(Ss(t)){case"start":d[a]-=c*(n&&u?-1:1);break;case"end":d[a]+=c*(n&&u?-1:1)}return d}function As(e,t){return"function"==typeof e?e(t):e}function Os(e){return"number"!=typeof e?(t=e,{top:0,right:0,bottom:0,left:0,...t}):{top:e,right:e,bottom:e,left:e};var t}function Ds(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}async function ks(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:i,rects:s,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=As(t,e),h=Os(p),m=a[f?"floating"===d?"reference":"floating":d],v=Ds(await i.getClippingRect({element:null==(n=await(null==i.isElement?void 0:i.isElement(m)))||n?m:m.contextElement||await(null==i.getDocumentElement?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:u,strategy:l})),g="floating"===d?{...s.floating,x:r,y:o}:s.reference,y=await(null==i.getOffsetParent?void 0:i.getOffsetParent(a.floating)),b=await(null==i.isElement?void 0:i.isElement(y))&&await(null==i.getScale?void 0:i.getScale(y))||{x:1,y:1},w=Ds(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({rect:g,offsetParent:y,strategy:l}):g);return{top:(v.top-w.top+h.top)/b.y,bottom:(w.bottom-v.bottom+h.bottom)/b.y,left:(v.left-w.left+h.left)/b.x,right:(w.right-v.right+h.right)/b.x}}const _s=Math.min,Ls=Math.max;function Ms(e,t,n){return Ls(e,_s(t,n))}const Is=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:s,elements:a}=t,{element:l,padding:c=0}=As(e,t)||{};if(null==l)return{};const u=Os(c),d={x:n,y:r},f=Ts(o),p=Ps(f),h=await s.getDimensions(l),m="y"===f,v=m?"top":"left",g=m?"bottom":"right",y=m?"clientHeight":"clientWidth",b=i.reference[p]+i.reference[f]-d[f]-i.floating[p],w=d[f]-i.reference[f],x=await(null==s.getOffsetParent?void 0:s.getOffsetParent(l));let E=x?x[y]:0;E&&await(null==s.isElement?void 0:s.isElement(x))||(E=a.floating[y]||i.floating[p]);const S=b/2-w/2,P=E/2-h[p]/2-1,C=_s(u[v],P),T=_s(u[g],P),R=C,A=E-h[p]-T,O=E/2-h[p]/2+S,D=Ms(R,O,A),k=null!=Ss(o)&&O!=D&&i.reference[p]/2-(O<R?C:T)-h[p]/2<0?O<R?R-O:A-O:0;return{[f]:d[f]-k,data:{[f]:D,centerOffset:O-D+k}}}}),Vs=["top","right","bottom","left"];Vs.reduce(((e,t)=>e.concat(t,t+"-start",t+"-end")),[]);const $s={left:"right",right:"left",bottom:"top",top:"bottom"};function Ns(e){return e.replace(/left|right|bottom|top/g,(e=>$s[e]))}const Fs={start:"end",end:"start"};function js(e){return e.replace(/start|end/g,(e=>Fs[e]))}const Bs=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:i,initialPlacement:s,platform:a,elements:l}=t,{mainAxis:c=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:h=!0,...m}=As(e,t),v=Cs(r),g=Cs(s)===s,y=await(null==a.isRTL?void 0:a.isRTL(l.floating)),b=d||(g||!h?[Ns(s)]:function(e){const t=Ns(e);return[js(e),t,js(t)]}(s));d||"none"===p||b.push(...function(e,t,n,r){const o=Ss(e);let i=function(e,t,n){const r=["left","right"],o=["right","left"],i=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?i:s;default:return[]}}(Cs(e),"start"===n,r);return o&&(i=i.map((e=>e+"-"+o)),t&&(i=i.concat(i.map(js)))),i}(s,h,p,y));const w=[s,...b],x=await ks(t,m),E=[];let S=(null==(n=o.flip)?void 0:n.overflows)||[];if(c&&E.push(x[v]),u){const{main:e,cross:t}=function(e,t,n){void 0===n&&(n=!1);const r=Ss(e),o=Ts(e),i=Ps(o);let s="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Ns(s)),{main:s,cross:Ns(s)}}(r,i,y);E.push(x[e],x[t])}if(S=[...S,{placement:r,overflows:E}],!E.every((e=>e<=0))){var P,C;const e=((null==(P=o.flip)?void 0:P.index)||0)+1,t=w[e];if(t)return{data:{index:e,overflows:S},reset:{placement:t}};let n=null==(C=S.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:C.placement;if(!n)switch(f){case"bestFit":{var T;const e=null==(T=S.map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:T[0];e&&(n=e);break}case"initialPlacement":n=s}if(r!==n)return{reset:{placement:n}}}return{}}}};function Ws(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Hs(e){return Vs.some((t=>e[t]>=0))}const Us=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=As(e,t);switch(r){case"referenceHidden":{const e=Ws(await ks(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:Hs(e)}}}case"escaped":{const e=Ws(await ks(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:Hs(e)}}}default:return{}}}}};function zs(e){return"x"===e?"y":"x"}const Ys=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:s=!1,limiter:a={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=As(e,t),c={x:n,y:r},u=await ks(t,l),d=Ts(Cs(o)),f=zs(d);let p=c[d],h=c[f];if(i){const e="y"===d?"bottom":"right";p=Ms(p+u["y"===d?"top":"left"],p,p-u[e])}if(s){const e="y"===f?"bottom":"right";h=Ms(h+u["y"===f?"top":"left"],h,h-u[e])}const m=a.fn({...t,[d]:p,[f]:h});return{...m,data:{x:m.x-n,y:m.y-r}}}}},Ks=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:i}=t,{apply:s=(()=>{}),...a}=As(e,t),l=await ks(t,a),c=Cs(n),u=Ss(n),d="x"===Ts(n),{width:f,height:p}=r.floating;let h,m;"top"===c||"bottom"===c?(h=c,m=u===(await(null==o.isRTL?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(m=c,h="end"===u?"top":"bottom");const v=p-l[h],g=f-l[m],y=!t.middlewareData.shift;let b=v,w=g;if(d){const e=f-l.left-l.right;w=u||y?_s(g,e):e}else{const e=p-l.top-l.bottom;b=u||y?_s(v,e):e}if(y&&!u){const e=Ls(l.left,0),t=Ls(l.right,0),n=Ls(l.top,0),r=Ls(l.bottom,0);d?w=f-2*(0!==e||0!==t?e+t:Ls(l.left,l.right)):b=p-2*(0!==n||0!==r?n+r:Ls(l.top,l.bottom))}await s({...t,availableWidth:w,availableHeight:b});const x=await o.getDimensions(i.floating);return f!==x.width||p!==x.height?{reset:{rects:!0}}:{}}}};function Xs(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function qs(e){return Xs(e).getComputedStyle(e)}function Gs(e){return e instanceof Xs(e).Node}function Zs(e){return Gs(e)?(e.nodeName||"").toLowerCase():"#document"}function Js(e){return e instanceof HTMLElement||e instanceof Xs(e).HTMLElement}function Qs(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Xs(e).ShadowRoot||e instanceof ShadowRoot)}function ea(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=qs(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function ta(e){return["table","td","th"].includes(Zs(e))}function na(e){const t=ra(),n=qs(e);return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function ra(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function oa(e){return["html","body","#document"].includes(Zs(e))}const ia=Math.min,sa=Math.max,aa=Math.round,la=Math.floor,ca=e=>({x:e,y:e});function ua(e){const t=qs(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Js(e),i=o?e.offsetWidth:n,s=o?e.offsetHeight:r,a=aa(n)!==i||aa(r)!==s;return a&&(n=i,r=s),{width:n,height:r,$:a}}function da(e){return e instanceof Element||e instanceof Xs(e).Element}function fa(e){return da(e)?e:e.contextElement}function pa(e){const t=fa(e);if(!Js(t))return ca(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=ua(t);let s=(i?aa(n.width):n.width)/r,a=(i?aa(n.height):n.height)/o;return s&&Number.isFinite(s)||(s=1),a&&Number.isFinite(a)||(a=1),{x:s,y:a}}const ha=ca(0);function ma(e){const t=Xs(e);return ra()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:ha}function va(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),i=fa(e);let s=ca(1);t&&(r?da(r)&&(s=pa(r)):s=pa(e));const a=(l=i,void 0===(c=n)&&(c=!1),!(u=r)||c&&u!==Xs(l)||!c?ca(0):ma(i));var l,c,u;let d=(o.left+a.x)/s.x,f=(o.top+a.y)/s.y,p=o.width/s.x,h=o.height/s.y;if(i){const e=Xs(i),t=r&&da(r)?Xs(r):r;let n=e.frameElement;for(;n&&r&&t!==e;){const e=pa(n),t=n.getBoundingClientRect(),r=getComputedStyle(n),o=t.left+(n.clientLeft+parseFloat(r.paddingLeft))*e.x,i=t.top+(n.clientTop+parseFloat(r.paddingTop))*e.y;d*=e.x,f*=e.y,p*=e.x,h*=e.y,d+=o,f+=i,n=Xs(n).frameElement}}return Ds({width:p,height:h,x:d,y:f})}function ga(e){return da(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function ya(e){var t;return null==(t=(Gs(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function ba(e){return va(ya(e)).left+ga(e).scrollLeft}function wa(e){if("html"===Zs(e))return e;const t=e.assignedSlot||e.parentNode||Qs(e)&&e.host||ya(e);return Qs(t)?t.host:t}function xa(e){const t=wa(e);return oa(t)?e.ownerDocument?e.ownerDocument.body:e.body:Js(t)&&ea(t)?t:xa(t)}function Ea(e,t){var n;void 0===t&&(t=[]);const r=xa(e),o=r===(null==(n=e.ownerDocument)?void 0:n.body),i=Xs(r);return o?t.concat(i,i.visualViewport||[],ea(r)?r:[]):t.concat(r,Ea(r))}function Sa(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=Xs(e),r=ya(e),o=n.visualViewport;let i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;const e=ra();(!e||e&&"fixed"===t)&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a,y:l}}(e,n);else if("document"===t)r=function(e){const t=ya(e),n=ga(e),r=e.ownerDocument.body,o=sa(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=sa(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+ba(e);const a=-n.scrollTop;return"rtl"===qs(r).direction&&(s+=sa(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:s,y:a}}(ya(e));else if(da(t))r=function(e,t){const n=va(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=Js(e)?pa(e):ca(1);return{width:e.clientWidth*i.x,height:e.clientHeight*i.y,x:o*i.x,y:r*i.y}}(t,n);else{const n=ma(e);r={...t,x:t.x-n.x,y:t.y-n.y}}return Ds(r)}function Pa(e,t){const n=wa(e);return!(n===t||!da(n)||oa(n))&&("fixed"===qs(n).position||Pa(n,t))}function Ca(e,t,n){const r=Js(t),o=ya(t),i="fixed"===n,s=va(e,!0,i,t);let a={scrollLeft:0,scrollTop:0};const l=ca(0);if(r||!r&&!i)if(("body"!==Zs(t)||ea(o))&&(a=ga(t)),Js(t)){const e=va(t,!0,i,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else o&&(l.x=ba(o));return{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function Ta(e,t){return Js(e)&&"fixed"!==qs(e).position?t?t(e):e.offsetParent:null}function Ra(e,t){const n=Xs(e);if(!Js(e))return n;let r=Ta(e,t);for(;r&&ta(r)&&"static"===qs(r).position;)r=Ta(r,t);return r&&("html"===Zs(r)||"body"===Zs(r)&&"static"===qs(r).position&&!na(r))?n:r||function(e){let t=wa(e);for(;Js(t)&&!oa(t);){if(na(t))return t;t=wa(t)}return null}(e)||n}const Aa={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=Js(n),i=ya(n);if(n===i)return t;let s={scrollLeft:0,scrollTop:0},a=ca(1);const l=ca(0);if((o||!o&&"fixed"!==r)&&(("body"!==Zs(n)||ea(i))&&(s=ga(n)),Js(n))){const e=va(n);a=pa(n),l.x=e.x+n.clientLeft,l.y=e.y+n.clientTop}return{width:t.width*a.x,height:t.height*a.y,x:t.x*a.x-s.scrollLeft*a.x+l.x,y:t.y*a.y-s.scrollTop*a.y+l.y}},getDocumentElement:ya,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[..."clippingAncestors"===n?function(e,t){const n=t.get(e);if(n)return n;let r=Ea(e).filter((e=>da(e)&&"body"!==Zs(e))),o=null;const i="fixed"===qs(e).position;let s=i?wa(e):e;for(;da(s)&&!oa(s);){const t=qs(s),n=na(s);n||"fixed"!==t.position||(o=null),(i?!n&&!o:!n&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||ea(s)&&!n&&Pa(e,s))?r=r.filter((e=>e!==s)):o=t,s=wa(s)}return t.set(e,r),r}(t,this._c):[].concat(n),r],s=i[0],a=i.reduce(((e,n)=>{const r=Sa(t,n,o);return e.top=sa(r.top,e.top),e.right=ia(r.right,e.right),e.bottom=ia(r.bottom,e.bottom),e.left=sa(r.left,e.left),e}),Sa(t,s,o));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}},getOffsetParent:Ra,getElementRects:async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||Ra,i=this.getDimensions;return{reference:Ca(t,await o(n),r),floating:{x:0,y:0,...await i(n)}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){return ua(e)},getScale:pa,isElement:da,isRTL:function(e){return"rtl"===getComputedStyle(e).direction}};function Oa(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:a="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=fa(e),u=o||i?[...c?Ea(c):[],...Ea(t)]:[];u.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),i&&e.addEventListener("resize",n)}));const d=c&&a?function(e,t){let n,r=null;const o=ya(e);function i(){clearTimeout(n),r&&r.disconnect(),r=null}return function s(a,l){void 0===a&&(a=!1),void 0===l&&(l=1),i();const{left:c,top:u,width:d,height:f}=e.getBoundingClientRect();if(a||t(),!d||!f)return;const p={rootMargin:-la(u)+"px "+-la(o.clientWidth-(c+d))+"px "+-la(o.clientHeight-(u+f))+"px "+-la(c)+"px",threshold:sa(0,ia(1,l))||1};let h=!0;function m(e){const t=e[0].intersectionRatio;if(t!==l){if(!h)return s();t?s(!1,t):n=setTimeout((()=>{s(!1,1e-7)}),100)}h=!1}try{r=new IntersectionObserver(m,{...p,root:o.ownerDocument})}catch(v){r=new IntersectionObserver(m,p)}r.observe(e)}(!0),i}(c,n):null;let f,p=-1,h=null;s&&(h=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&h&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{h&&h.observe(t)}))),n()})),c&&!l&&h.observe(c),h.observe(t));let m=l?va(e):null;return l&&function t(){const r=va(e);!m||r.x===m.x&&r.y===m.y&&r.width===m.width&&r.height===m.height||n(),m=r,f=requestAnimationFrame(t)}(),n(),()=>{u.forEach((e=>{o&&e.removeEventListener("scroll",n),i&&e.removeEventListener("resize",n)})),d&&d(),h&&h.disconnect(),h=null,l&&cancelAnimationFrame(f)}}const Da=(e,t,n)=>{const r=new Map,o={platform:Aa,...n},i={...o.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:s}=n,a=i.filter(Boolean),l=await(null==s.isRTL?void 0:s.isRTL(t));let c=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:u,y:d}=Rs(c,r,l),f=r,p={},h=0;for(let m=0;m<a.length;m++){const{name:n,fn:i}=a[m],{x:v,y:g,data:y,reset:b}=await i({x:u,y:d,initialPlacement:r,placement:f,strategy:o,middlewareData:p,rects:c,platform:s,elements:{reference:e,floating:t}});u=null!=v?v:u,d=null!=g?g:d,p={...p,[n]:{...p[n],...y}},b&&h<=50&&(h++,"object"==typeof b&&(b.placement&&(f=b.placement),b.rects&&(c=!0===b.rects?await s.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:u,y:d}=Rs(c,f,l))),m=-1)}return{x:u,y:d,placement:f,strategy:o,middlewareData:p}})(e,t,{...o,platform:i})},ka=e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&(o=n,{}.hasOwnProperty.call(o,"current"))?null!=n.current?Is({element:n.current,padding:r}).fn(t):{}:n?Is({element:n,padding:r}).fn(t):{};var o}});var _a="undefined"!=typeof document?e.useLayoutEffect:e.useEffect;function La(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;0!=r--;)if(!La(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){const n=o[r];if(("_owner"!==n||!e.$$typeof)&&!La(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function Ma(e){if("undefined"==typeof window)return 1;return(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ia(e,t){const n=Ma(e);return Math.round(t*n)/n}function Va(e){const t=r.useRef(e);return _a((()=>{t.current=e})),t}const $a=e.forwardRef(((t,n)=>{const{children:r,width:o=10,height:i=5,...s}=t;return e.createElement(ii.svg,X({},s,{ref:n,width:o,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),t.asChild?r:e.createElement("polygon",{points:"0,0 30,0 15,10"}))})),Na="Popper",[Fa,ja]=Jo(Na),[Ba,Wa]=Fa(Na),Ha=e.forwardRef(((t,n)=>{const{__scopePopper:r,virtualRef:o,...i}=t,s=Wa("PopperAnchor",r),a=e.useRef(null),l=Zo(n,a);return e.useEffect((()=>{s.onAnchorChange((null==o?void 0:o.current)||a.current)})),o?null:e.createElement(ii.div,X({},i,{ref:l}))})),Ua="PopperContent",[za,Ya]=Fa(Ua),Ka=e.forwardRef(((t,n)=>{var i,s,a,l,c,u,d,f;const{__scopePopper:p,side:h="bottom",sideOffset:m=0,align:v="center",alignOffset:g=0,arrowPadding:y=0,collisionBoundary:b=[],collisionPadding:w=0,sticky:x="partial",hideWhenDetached:E=!1,avoidCollisions:S=!0,onPlaced:P,...C}=t,T=Wa(Ua,p),[R,A]=e.useState(null),O=Zo(n,(e=>A(e))),[D,k]=e.useState(null),_=_i(D),L=null!==(i=null==_?void 0:_.width)&&void 0!==i?i:0,M=null!==(s=null==_?void 0:_.height)&&void 0!==s?s:0,I=h+("center"!==v?"-"+v:""),V="number"==typeof w?w:{top:0,right:0,bottom:0,left:0,...w},$=Array.isArray(b)?b:[b],N=$.length>0,F={padding:V,boundary:$.filter(qa),altBoundary:N},{refs:j,floatingStyles:B,placement:W,isPositioned:H,middlewareData:U}=function(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:i=[],platform:s,elements:{reference:a,floating:l}={},transform:c=!0,whileElementsMounted:u,open:d}=e,[f,p]=r.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,m]=r.useState(i);La(h,i)||m(i);const[v,g]=r.useState(null),[y,b]=r.useState(null),w=r.useCallback((e=>{e!=P.current&&(P.current=e,g(e))}),[g]),x=r.useCallback((e=>{e!==C.current&&(C.current=e,b(e))}),[b]),E=a||v,S=l||y,P=r.useRef(null),C=r.useRef(null),T=r.useRef(f),R=Va(u),A=Va(s),O=r.useCallback((()=>{if(!P.current||!C.current)return;const e={placement:t,strategy:n,middleware:h};A.current&&(e.platform=A.current),Da(P.current,C.current,e).then((e=>{const t={...e,isPositioned:!0};D.current&&!La(T.current,t)&&(T.current=t,o.flushSync((()=>{p(t)})))}))}),[h,t,n,A]);_a((()=>{!1===d&&T.current.isPositioned&&(T.current.isPositioned=!1,p((e=>({...e,isPositioned:!1}))))}),[d]);const D=r.useRef(!1);_a((()=>(D.current=!0,()=>{D.current=!1})),[]),_a((()=>{if(E&&(P.current=E),S&&(C.current=S),E&&S){if(R.current)return R.current(E,S,O);O()}}),[E,S,O,R]);const k=r.useMemo((()=>({reference:P,floating:C,setReference:w,setFloating:x})),[w,x]),_=r.useMemo((()=>({reference:E,floating:S})),[E,S]),L=r.useMemo((()=>{const e={position:n,left:0,top:0};if(!_.floating)return e;const t=Ia(_.floating,f.x),r=Ia(_.floating,f.y);return c?{...e,transform:"translate("+t+"px, "+r+"px)",...Ma(_.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,c,_.floating,f.x,f.y]);return r.useMemo((()=>({...f,update:O,refs:k,elements:_,floatingStyles:L})),[f,O,k,_,L])}({strategy:"fixed",placement:I,whileElementsMounted:Oa,elements:{reference:T.anchor},middleware:[(Y={mainAxis:m+M,alignmentAxis:g},void 0===Y&&(Y=0),{name:"offset",options:Y,async fn(e){const{x:t,y:n}=e,r=await async function(e,t){const{placement:n,platform:r,elements:o}=e,i=await(null==r.isRTL?void 0:r.isRTL(o.floating)),s=Cs(n),a=Ss(n),l="x"===Ts(n),c=["left","top"].includes(s)?-1:1,u=i&&l?-1:1,d=As(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:h}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return a&&"number"==typeof h&&(p="end"===a?-1*h:h),l?{x:p*u,y:f*c}:{x:f*c,y:p*u}}(e,Y);return{x:t+r.x,y:n+r.y,data:r}}}),S&&Ys({mainAxis:!0,crossAxis:!1,limiter:"partial"===x?(void 0===z&&(z={}),{options:z,fn(e){const{x:t,y:n,placement:r,rects:o,middlewareData:i}=e,{offset:s=0,mainAxis:a=!0,crossAxis:l=!0}=As(z,e),c={x:t,y:n},u=Ts(r),d=zs(u);let f=c[u],p=c[d];const h=As(s,e),m="number"==typeof h?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(a){const e="y"===u?"height":"width",t=o.reference[u]-o.floating[e]+m.mainAxis,n=o.reference[u]+o.reference[e]-m.mainAxis;f<t?f=t:f>n&&(f=n)}if(l){var v,g;const e="y"===u?"width":"height",t=["top","left"].includes(Cs(r)),n=o.reference[d]-o.floating[e]+(t&&(null==(v=i.offset)?void 0:v[d])||0)+(t?0:m.crossAxis),s=o.reference[d]+o.reference[e]+(t?0:(null==(g=i.offset)?void 0:g[d])||0)-(t?m.crossAxis:0);p<n?p=n:p>s&&(p=s)}return{[u]:f,[d]:p}}}):void 0,...F}),S&&Bs({...F}),Ks({...F,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{const{width:o,height:i}=t.reference,s=e.floating.style;s.setProperty("--radix-popper-available-width",`${n}px`),s.setProperty("--radix-popper-available-height",`${r}px`),s.setProperty("--radix-popper-anchor-width",`${o}px`),s.setProperty("--radix-popper-anchor-height",`${i}px`)}}),D&&ka({element:D,padding:y}),Ga({arrowWidth:L,arrowHeight:M}),E&&Us({strategy:"referenceHidden"})]});var z,Y;const[K,q]=Za(W),G=di(P);ai((()=>{H&&(null==G||G())}),[H,G]);const Z=null===(a=U.arrow)||void 0===a?void 0:a.x,J=null===(l=U.arrow)||void 0===l?void 0:l.y,Q=0!==(null===(c=U.arrow)||void 0===c?void 0:c.centerOffset),[ee,te]=e.useState();return ai((()=>{R&&te(window.getComputedStyle(R).zIndex)}),[R]),e.createElement("div",{ref:j.setFloating,"data-radix-popper-content-wrapper":"",style:{...B,transform:H?B.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ee,"--radix-popper-transform-origin":[null===(u=U.transformOrigin)||void 0===u?void 0:u.x,null===(d=U.transformOrigin)||void 0===d?void 0:d.y].join(" ")},dir:t.dir},e.createElement(za,{scope:p,placedSide:K,onArrowChange:k,arrowX:Z,arrowY:J,shouldHideArrow:Q},e.createElement(ii.div,X({"data-side":K,"data-align":q},C,{ref:O,style:{...C.style,animation:H?void 0:"none",opacity:null!==(f=U.hide)&&void 0!==f&&f.referenceHidden?0:void 0}}))))})),Xa={top:"bottom",right:"left",bottom:"top",left:"right"};function qa(e){return null!==e}const Ga=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,s;const{placement:a,rects:l,middlewareData:c}=t,u=0!==(null===(n=c.arrow)||void 0===n?void 0:n.centerOffset),d=u?0:e.arrowWidth,f=u?0:e.arrowHeight,[p,h]=Za(a),m={start:"0%",center:"50%",end:"100%"}[h],v=(null!==(r=null===(o=c.arrow)||void 0===o?void 0:o.x)&&void 0!==r?r:0)+d/2,g=(null!==(i=null===(s=c.arrow)||void 0===s?void 0:s.y)&&void 0!==i?i:0)+f/2;let y="",b="";return"bottom"===p?(y=u?m:`${v}px`,b=-f+"px"):"top"===p?(y=u?m:`${v}px`,b=`${l.floating.height+f}px`):"right"===p?(y=-f+"px",b=u?m:`${g}px`):"left"===p&&(y=`${l.floating.width+f}px`,b=u?m:`${g}px`),{data:{x:y,y:b}}}});function Za(e){const[t,n="center"]=e.split("-");return[t,n]}const Ja=t=>{const{__scopePopper:n,children:r}=t,[o,i]=e.useState(null);return e.createElement(Ba,{scope:n,anchor:o,onAnchorChange:i},r)},Qa=Ha,el=Ka,tl=e.forwardRef((function(t,n){const{__scopePopper:r,...o}=t,i=Ya("PopperArrow",r),s=Xa[i.placedSide];return e.createElement("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0}},e.createElement($a,X({},o,{ref:n,style:{...o.style,display:"block"}})))})),nl=e.forwardRef(((n,r)=>{var o;const{container:i=(null===globalThis||void 0===globalThis||null===(o=globalThis.document)||void 0===o?void 0:o.body),...s}=n;return i?t.createPortal(e.createElement(ii.div,X({},s,{ref:r})),i):null})),rl=e.forwardRef(((t,n)=>e.createElement(ii.span,X({},t,{ref:n,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...t.style}})))),ol=rl,il=[" ","Enter","ArrowUp","ArrowDown"],sl=[" ","Enter"],al="Select",[ll,cl,ul]=si(al),[dl,fl]=Jo(al,[ul,ja]),pl=ja(),[hl,ml]=dl(al),[vl,gl]=dl(al),yl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,disabled:o=!1,...i}=t,s=pl(r),a=ml("SelectTrigger",r),l=a.disabled||o,c=Zo(n,a.onTriggerChange),u=cl(r),[d,f,p]=Yl((e=>{const t=u().filter((e=>!e.disabled)),n=t.find((e=>e.value===a.value)),r=Kl(t,e,n);void 0!==r&&a.onValueChange(r.value)})),h=()=>{l||(a.onOpenChange(!0),p())};return e.createElement(Qa,X({asChild:!0},s),e.createElement(ii.button,X({type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:l,"data-disabled":l?"":void 0,"data-placeholder":void 0===a.value?"":void 0},i,{ref:c,onClick:qo(i.onClick,(e=>{e.currentTarget.focus()})),onPointerDown:qo(i.onPointerDown,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&(h(),a.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)},e.preventDefault())})),onKeyDown:qo(i.onKeyDown,(e=>{const t=""!==d.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||f(e.key),t&&" "===e.key||il.includes(e.key)&&(h(),e.preventDefault())}))})))})),bl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,className:o,style:i,children:s,placeholder:a,...l}=t,c=ml("SelectValue",r),{onValueNodeHasChildrenChange:u}=c,d=void 0!==s,f=Zo(n,c.onValueNodeChange);return ai((()=>{u(d)}),[u,d]),e.createElement(ii.span,X({},l,{ref:f,style:{pointerEvents:"none"}}),void 0===c.value&&void 0!==a?a:s)})),wl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,children:o,...i}=t;return e.createElement(ii.span,X({"aria-hidden":!0},i,{ref:n}),o||"▼")})),xl="SelectContent",El=e.forwardRef(((n,r)=>{const o=ml(xl,n.__scopeSelect),[i,s]=e.useState();if(ai((()=>{s(new DocumentFragment)}),[]),!o.open){const r=i;return r?t.createPortal(e.createElement(Pl,{scope:n.__scopeSelect},e.createElement(ll.Slot,{scope:n.__scopeSelect},e.createElement("div",null,n.children))),r):null}return e.createElement(Tl,X({},n,{ref:r}))})),Sl=10,[Pl,Cl]=dl(xl),Tl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,position:o="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:s,onPointerDownOutside:a,side:l,sideOffset:c,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:h,sticky:m,hideWhenDetached:v,avoidCollisions:g,...y}=t,b=ml(xl,r),[w,x]=e.useState(null),[E,S]=e.useState(null),P=Zo(n,(e=>x(e))),[C,T]=e.useState(null),[R,A]=e.useState(null),O=cl(r),[D,k]=e.useState(!1),_=e.useRef(!1);e.useEffect((()=>{if(w)return Pt(w)}),[w]),e.useEffect((()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(e=n[0])&&void 0!==e?e:fs()),document.body.insertAdjacentElement("beforeend",null!==(t=n[1])&&void 0!==t?t:fs()),ds++,()=>{1===ds&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),ds--}}),[]);const L=e.useCallback((e=>{const[t,...n]=O().map((e=>e.ref.current)),[r]=n.slice(-1),o=document.activeElement;for(const i of e){if(i===o)return;if(null==i||i.scrollIntoView({block:"nearest"}),i===t&&E&&(E.scrollTop=0),i===r&&E&&(E.scrollTop=E.scrollHeight),null==i||i.focus(),document.activeElement!==o)return}}),[O,E]),M=e.useCallback((()=>L([C,w])),[L,C,w]);e.useEffect((()=>{D&&M()}),[D,M]);const{onOpenChange:I,triggerPointerDownPosRef:V}=b;e.useEffect((()=>{if(w){let e={x:0,y:0};const t=t=>{var n,r,o,i;e={x:Math.abs(Math.round(t.pageX)-(null!==(n=null===(r=V.current)||void 0===r?void 0:r.x)&&void 0!==n?n:0)),y:Math.abs(Math.round(t.pageY)-(null!==(o=null===(i=V.current)||void 0===i?void 0:i.y)&&void 0!==o?o:0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():w.contains(n.target)||I(!1),document.removeEventListener("pointermove",t),V.current=null};return null!==V.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}}),[w,I,V]),e.useEffect((()=>{const e=()=>I(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[I]);const[$,N]=Yl((e=>{const t=O().filter((e=>!e.disabled)),n=t.find((e=>e.ref.current===document.activeElement)),r=Kl(t,e,n);r&&setTimeout((()=>r.ref.current.focus()))})),F=e.useCallback(((e,t,n)=>{const r=!_.current&&!n;(void 0!==b.value&&b.value===t||r)&&(T(e),r&&(_.current=!0))}),[b.value]),j=e.useCallback((()=>null==w?void 0:w.focus()),[w]),B=e.useCallback(((e,t,n)=>{const r=!_.current&&!n;(void 0!==b.value&&b.value===t||r)&&A(e)}),[b.value]),W="popper"===o?Al:Rl,H=W===Al?{side:l,sideOffset:c,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:h,sticky:m,hideWhenDetached:v,avoidCollisions:g}:{};return e.createElement(Pl,{scope:r,content:w,viewport:E,onViewportChange:S,itemRefCallback:F,selectedItem:C,onItemLeave:j,itemTextRefCallback:B,focusSelectedItem:M,selectedItemText:R,position:o,isPositioned:D,searchRef:$},e.createElement(gt,{as:ei,allowPinchZoom:!0},e.createElement(vs,{asChild:!0,trapped:b.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:qo(i,(e=>{var t;null===(t=b.trigger)||void 0===t||t.focus({preventScroll:!0}),e.preventDefault()}))},e.createElement(ls,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>b.onOpenChange(!1)},e.createElement(W,X({role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:e=>e.preventDefault()},y,H,{onPlaced:()=>k(!0),ref:P,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:qo(y.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||N(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=O().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout((()=>L(t))),e.preventDefault()}}))}))))))})),Rl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,onPlaced:o,...i}=t,s=ml(xl,r),a=Cl(xl,r),[l,c]=e.useState(null),[u,d]=e.useState(null),f=Zo(n,(e=>d(e))),p=cl(r),h=e.useRef(!1),m=e.useRef(!0),{viewport:v,selectedItem:g,selectedItemText:y,focusSelectedItem:b}=a,w=e.useCallback((()=>{if(s.trigger&&s.valueNode&&l&&u&&v&&g&&y){const e=s.trigger.getBoundingClientRect(),t=u.getBoundingClientRect(),n=s.valueNode.getBoundingClientRect(),r=y.getBoundingClientRect();if("rtl"!==s.dir){const o=r.left-t.left,i=n.left-o,s=e.left-i,a=e.width+s,c=Math.max(a,t.width),u=window.innerWidth-Sl,d=ns(i,[Sl,u-c]);l.style.minWidth=a+"px",l.style.left=d+"px"}else{const o=t.right-r.right,i=window.innerWidth-n.right-o,s=window.innerWidth-e.right-i,a=e.width+s,c=Math.max(a,t.width),u=window.innerWidth-Sl,d=ns(i,[Sl,u-c]);l.style.minWidth=a+"px",l.style.right=d+"px"}const i=p(),a=window.innerHeight-2*Sl,c=v.scrollHeight,d=window.getComputedStyle(u),f=parseInt(d.borderTopWidth,10),m=parseInt(d.paddingTop,10),b=parseInt(d.borderBottomWidth,10),w=f+m+c+parseInt(d.paddingBottom,10)+b,x=Math.min(5*g.offsetHeight,w),E=window.getComputedStyle(v),S=parseInt(E.paddingTop,10),P=parseInt(E.paddingBottom,10),C=e.top+e.height/2-Sl,T=a-C,R=g.offsetHeight/2,A=f+m+(g.offsetTop+R),O=w-A;if(A<=C){const e=g===i[i.length-1].ref.current;l.style.bottom="0px";const t=u.clientHeight-v.offsetTop-v.offsetHeight,n=A+Math.max(T,R+(e?P:0)+t+b);l.style.height=n+"px"}else{const e=g===i[0].ref.current;l.style.top="0px";const t=Math.max(C,f+v.offsetTop+(e?S:0)+R)+O;l.style.height=t+"px",v.scrollTop=A-C+v.offsetTop}l.style.margin=`${Sl}px 0`,l.style.minHeight=x+"px",l.style.maxHeight=a+"px",null==o||o(),requestAnimationFrame((()=>h.current=!0))}}),[p,s.trigger,s.valueNode,l,u,v,g,y,s.dir,o]);ai((()=>w()),[w]);const[x,E]=e.useState();ai((()=>{u&&E(window.getComputedStyle(u).zIndex)}),[u]);const S=e.useCallback((e=>{e&&!0===m.current&&(w(),null==b||b(),m.current=!1)}),[w,b]);return e.createElement(Ol,{scope:r,contentWrapper:l,shouldExpandOnScrollRef:h,onScrollButtonChange:S},e.createElement("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:x}},e.createElement(ii.div,X({},i,{ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}}))))})),Al=e.forwardRef(((t,n)=>{const{__scopeSelect:r,align:o="start",collisionPadding:i=Sl,...s}=t,a=pl(r);return e.createElement(el,X({},a,s,{ref:n,align:o,collisionPadding:i,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}}))})),[Ol,Dl]=dl(xl,{}),kl="SelectViewport",_l=e.forwardRef(((t,n)=>{const{__scopeSelect:r,...o}=t,i=Cl(kl,r),s=Dl(kl,r),a=Zo(n,i.onViewportChange),l=e.useRef(0);return e.createElement(e.Fragment,null,e.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"}}),e.createElement(ll.Slot,{scope:r},e.createElement(ii.div,X({"data-radix-select-viewport":"",role:"presentation"},o,{ref:a,style:{position:"relative",flex:1,overflow:"auto",...o.style},onScroll:qo(o.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=s;if(null!=r&&r.current&&n){const e=Math.abs(l.current-t.scrollTop);if(e>0){const r=window.innerHeight-2*Sl,o=parseFloat(n.style.minHeight),i=parseFloat(n.style.height),s=Math.max(o,i);if(s<r){const o=s+e,i=Math.min(r,o),a=o-i;n.style.height=i+"px","0px"===n.style.bottom&&(t.scrollTop=a>0?a:0,n.style.justifyContent="flex-end")}}}l.current=t.scrollTop}))}))))}));dl("SelectGroup");const Ll="SelectItem",[Ml,Il]=dl(Ll),Vl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,value:o,disabled:i=!1,textValue:s,...a}=t,l=ml(Ll,r),c=Cl(Ll,r),u=l.value===o,[d,f]=e.useState(null!=s?s:""),[p,h]=e.useState(!1),m=Zo(n,(e=>{var t;return null===(t=c.itemRefCallback)||void 0===t?void 0:t.call(c,e,o,i)})),v=ui(),g=()=>{i||(l.onValueChange(o),l.onOpenChange(!1))};return e.createElement(Ml,{scope:r,value:o,disabled:i,textId:v,isSelected:u,onItemTextChange:e.useCallback((e=>{f((t=>{var n;return t||(null!==(n=null==e?void 0:e.textContent)&&void 0!==n?n:"").trim()}))}),[])},e.createElement(ll.ItemSlot,{scope:r,value:o,disabled:i,textValue:d},e.createElement(ii.div,X({role:"option","aria-labelledby":v,"data-highlighted":p?"":void 0,"aria-selected":u&&p,"data-state":u?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1},a,{ref:m,onFocus:qo(a.onFocus,(()=>h(!0))),onBlur:qo(a.onBlur,(()=>h(!1))),onPointerUp:qo(a.onPointerUp,g),onPointerMove:qo(a.onPointerMove,(e=>{var t;i?null===(t=c.onItemLeave)||void 0===t||t.call(c):e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:qo(a.onPointerLeave,(e=>{var t;e.currentTarget===document.activeElement&&(null===(t=c.onItemLeave)||void 0===t||t.call(c))})),onKeyDown:qo(a.onKeyDown,(e=>{var t;""!==(null===(t=c.searchRef)||void 0===t?void 0:t.current)&&" "===e.key||(sl.includes(e.key)&&g()," "===e.key&&e.preventDefault())}))}))))})),$l="SelectItemText",Nl=e.forwardRef(((n,r)=>{const{__scopeSelect:o,className:i,style:s,...a}=n,l=ml($l,o),c=Cl($l,o),u=Il($l,o),d=gl($l,o),[f,p]=e.useState(null),h=Zo(r,(e=>p(e)),u.onItemTextChange,(e=>{var t;return null===(t=c.itemTextRefCallback)||void 0===t?void 0:t.call(c,e,u.value,u.disabled)})),m=null==f?void 0:f.textContent,v=e.useMemo((()=>e.createElement("option",{key:u.value,value:u.value,disabled:u.disabled},m)),[u.disabled,u.value,m]),{onNativeOptionAdd:g,onNativeOptionRemove:y}=d;return ai((()=>(g(v),()=>y(v))),[g,y,v]),e.createElement(e.Fragment,null,e.createElement(ii.span,X({id:u.textId},a,{ref:h})),u.isSelected&&l.valueNode&&!l.valueNodeHasChildren?t.createPortal(a.children,l.valueNode):null)})),Fl=e.forwardRef(((t,n)=>{const{__scopeSelect:r,...o}=t;return Il("SelectItemIndicator",r).isSelected?e.createElement(ii.span,X({"aria-hidden":!0},o,{ref:n})):null})),jl="SelectScrollUpButton",Bl=e.forwardRef(((t,n)=>{const r=Cl(jl,t.__scopeSelect),o=Dl(jl,t.__scopeSelect),[i,s]=e.useState(!1),a=Zo(n,o.onScrollButtonChange);return ai((()=>{if(r.viewport&&r.isPositioned){let e=function(){const e=t.scrollTop>0;s(e)};const t=r.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[r.viewport,r.isPositioned]),i?e.createElement(Ul,X({},t,{ref:a,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=r;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}})):null})),Wl="SelectScrollDownButton",Hl=e.forwardRef(((t,n)=>{const r=Cl(Wl,t.__scopeSelect),o=Dl(Wl,t.__scopeSelect),[i,s]=e.useState(!1),a=Zo(n,o.onScrollButtonChange);return ai((()=>{if(r.viewport&&r.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;s(n)};const t=r.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[r.viewport,r.isPositioned]),i?e.createElement(Ul,X({},t,{ref:a,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=r;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}})):null})),Ul=e.forwardRef(((t,n)=>{const{__scopeSelect:r,onAutoScroll:o,...i}=t,s=Cl("SelectScrollButton",r),a=e.useRef(null),l=cl(r),c=e.useCallback((()=>{null!==a.current&&(window.clearInterval(a.current),a.current=null)}),[]);return e.useEffect((()=>()=>c()),[c]),ai((()=>{var e;const t=l().find((e=>e.ref.current===document.activeElement));null==t||null===(e=t.ref.current)||void 0===e||e.scrollIntoView({block:"nearest"})}),[l]),e.createElement(ii.div,X({"aria-hidden":!0},i,{ref:n,style:{flexShrink:0,...i.style},onPointerDown:qo(i.onPointerDown,(()=>{null===a.current&&(a.current=window.setInterval(o,50))})),onPointerMove:qo(i.onPointerMove,(()=>{var e;null===(e=s.onItemLeave)||void 0===e||e.call(s),null===a.current&&(a.current=window.setInterval(o,50))})),onPointerLeave:qo(i.onPointerLeave,(()=>{c()}))}))})),zl=e.forwardRef(((t,n)=>{const{value:r,...o}=t,i=e.useRef(null),s=Zo(n,i),a=Li(r);return e.useEffect((()=>{const e=i.current,t=window.HTMLSelectElement.prototype,n=Object.getOwnPropertyDescriptor(t,"value").set;if(a!==r&&n){const t=new Event("change",{bubbles:!0});n.call(e,r),e.dispatchEvent(t)}}),[a,r]),e.createElement(rl,{asChild:!0},e.createElement("select",X({},o,{ref:s,defaultValue:r})))}));function Yl(t){const n=di(t),r=e.useRef(""),o=e.useRef(0),i=e.useCallback((e=>{const t=r.current+e;n(t),function e(t){r.current=t,window.clearTimeout(o.current),""!==t&&(o.current=window.setTimeout((()=>e("")),1e3))}(t)}),[n]),s=e.useCallback((()=>{r.current="",window.clearTimeout(o.current)}),[]);return e.useEffect((()=>()=>window.clearTimeout(o.current)),[]),[r,i,s]}function Kl(e,t,n){const r=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,o=n?e.indexOf(n):-1;let i=(s=e,a=Math.max(o,0),s.map(((e,t)=>s[(a+t)%s.length])));var s,a;1===r.length&&(i=i.filter((e=>e!==n)));const l=i.find((e=>e.textValue.toLowerCase().startsWith(r.toLowerCase())));return l!==n?l:void 0}zl.displayName="BubbleSelect";const Xl=t=>{const{__scopeSelect:n,children:r,open:o,defaultOpen:i,onOpenChange:s,value:a,defaultValue:l,onValueChange:c,dir:u,name:d,autoComplete:f,disabled:p,required:h}=t,m=pl(n),[v,g]=e.useState(null),[y,b]=e.useState(null),[w,x]=e.useState(!1),E=hi(u),[S=!1,P]=fi({prop:o,defaultProp:i,onChange:s}),[C,T]=fi({prop:a,defaultProp:l,onChange:c}),R=e.useRef(null),A=!v||Boolean(v.closest("form")),[O,D]=e.useState(new Set),k=Array.from(O).map((e=>e.props.value)).join(";");return e.createElement(Ja,m,e.createElement(hl,{required:h,scope:n,trigger:v,onTriggerChange:g,valueNode:y,onValueNodeChange:b,valueNodeHasChildren:w,onValueNodeHasChildrenChange:x,contentId:ui(),value:C,onValueChange:T,open:S,onOpenChange:P,dir:E,triggerPointerDownPosRef:R,disabled:p},e.createElement(ll.Provider,{scope:n},e.createElement(vl,{scope:t.__scopeSelect,onNativeOptionAdd:e.useCallback((e=>{D((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:e.useCallback((e=>{D((t=>{const n=new Set(t);return n.delete(e),n}))}),[])},r)),A?e.createElement(zl,{key:k,"aria-hidden":!0,required:h,tabIndex:-1,name:d,autoComplete:f,value:C,onChange:e=>T(e.target.value),disabled:p},void 0===C?e.createElement("option",{value:""}):null,Array.from(O)):null))},ql=yl,Gl=bl,Zl=wl,Jl=t=>e.createElement(nl,X({asChild:!0},t)),Ql=El,ec=_l,tc=Vl,nc=Nl,rc=Fl,oc=Bl,ic=Hl,sc=e.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),ac=e.createContext({}),lc=e.createContext(null),cc="undefined"!=typeof document,uc=cc?e.useLayoutEffect:e.useEffect,dc=e.createContext({strict:!1});function fc(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function pc(e){return"string"==typeof e||Array.isArray(e)}function hc(e){return"object"==typeof e&&"function"==typeof e.start}const mc=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],vc=["initial",...mc];function gc(e){return hc(e.animate)||vc.some((t=>pc(e[t])))}function yc(e){return Boolean(gc(e)||e.variants)}function bc(t){const{initial:n,animate:r}=function(e,t){if(gc(e)){const{initial:t,animate:n}=e;return{initial:!1===t||pc(t)?t:void 0,animate:pc(n)?n:void 0}}return!1!==e.inherit?t:{}}(t,e.useContext(ac));return e.useMemo((()=>({initial:n,animate:r})),[wc(n),wc(r)])}function wc(e){return Array.isArray(e)?e.join(" "):e}const xc={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Ec={};for(const ry in xc)Ec[ry]={isEnabled:e=>xc[ry].some((t=>!!e[t]))};function Sc(t){const n=e.useRef(null);return null===n.current&&(n.current=t()),n.current}const Pc={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let Cc=1;const Tc=e.createContext({}),Rc=e.createContext({}),Ac=Symbol.for("motionComponentSymbol");function Oc({preloadedFeatures:t,createVisualElement:n,useRender:o,useVisualState:i,Component:s}){t&&function(e){for(const t in e)Ec[t]={...Ec[t],...e[t]}}(t);const a=e.forwardRef((function(a,l){let c;const u={...e.useContext(sc),...a,layoutId:Dc(a)},{isStatic:d}=u,f=bc(a),p=d?void 0:Sc((()=>{if(Pc.hasEverUpdated)return Cc++})),h=i(a,d);if(!d&&cc){f.visualElement=function(t,n,r,o){const{visualElement:i}=e.useContext(ac),s=e.useContext(dc),a=e.useContext(lc),l=e.useContext(sc).reducedMotion,c=e.useRef();o=o||s.renderer,!c.current&&o&&(c.current=o(t,{visualState:n,parent:i,props:r,presenceContext:a,blockInitialAnimation:!!a&&!1===a.initial,reducedMotionConfig:l}));const u=c.current;return e.useInsertionEffect((()=>{u&&u.update(r,a)})),uc((()=>{u&&u.render()})),e.useEffect((()=>{u&&u.updateFeatures()})),(window.HandoffAppearAnimations?uc:e.useEffect)((()=>{u&&u.animationState&&u.animationState.animateChanges()})),u}(s,h,u,n);const r=e.useContext(Rc),o=e.useContext(dc).strict;f.visualElement&&(c=f.visualElement.loadFeatures(u,o,t,p,r))}return r.createElement(ac.Provider,{value:f},c&&f.visualElement?r.createElement(c,{visualElement:f.visualElement,...u}):null,o(s,a,p,function(t,n,r){return e.useCallback((e=>{e&&t.mount&&t.mount(e),n&&(e?n.mount(e):n.unmount()),r&&("function"==typeof r?r(e):fc(r)&&(r.current=e))}),[n])}(h,f.visualElement,l),h,d,f.visualElement))}));return a[Ac]=s,a}function Dc({layoutId:t}){const n=e.useContext(Tc).id;return n&&void 0!==t?n+"-"+t:t}function kc(e){function t(t,n={}){return Oc(e(t,n))}if("undefined"==typeof Proxy)return t;const n=new Map;return new Proxy(t,{get:(e,r)=>(n.has(r)||n.set(r,t(r)),n.get(r))})}const _c=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Lc(e){return"string"==typeof e&&!e.includes("-")&&!!(_c.indexOf(e)>-1||/[A-Z]/.test(e))}const Mc={};const Ic=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Vc=new Set(Ic);function $c(e,{layout:t,layoutId:n}){return Vc.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!Mc[e]||"opacity"===e)}const Nc=e=>Boolean(e&&e.getVelocity),Fc={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},jc=Ic.length;const Bc=e=>t=>"string"==typeof t&&t.startsWith(e),Wc=Bc("--"),Hc=Bc("var(--"),Uc=(e,t)=>t&&"number"==typeof e?t.transform(e):e,zc=(e,t,n)=>Math.min(Math.max(n,e),t),Yc={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},Kc={...Yc,transform:e=>zc(0,1,e)},Xc={...Yc,default:1},qc=e=>Math.round(1e5*e)/1e5,Gc=/(-)?([\d]*\.?[\d])+/g,Zc=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,Jc=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function Qc(e){return"string"==typeof e}const eu=e=>({test:t=>Qc(t)&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),tu=eu("deg"),nu=eu("%"),ru=eu("px"),ou=eu("vh"),iu=eu("vw"),su={...nu,parse:e=>nu.parse(e)/100,transform:e=>nu.transform(100*e)},au={...Yc,transform:Math.round},lu={borderWidth:ru,borderTopWidth:ru,borderRightWidth:ru,borderBottomWidth:ru,borderLeftWidth:ru,borderRadius:ru,radius:ru,borderTopLeftRadius:ru,borderTopRightRadius:ru,borderBottomRightRadius:ru,borderBottomLeftRadius:ru,width:ru,maxWidth:ru,height:ru,maxHeight:ru,size:ru,top:ru,right:ru,bottom:ru,left:ru,padding:ru,paddingTop:ru,paddingRight:ru,paddingBottom:ru,paddingLeft:ru,margin:ru,marginTop:ru,marginRight:ru,marginBottom:ru,marginLeft:ru,rotate:tu,rotateX:tu,rotateY:tu,rotateZ:tu,scale:Xc,scaleX:Xc,scaleY:Xc,scaleZ:Xc,skew:tu,skewX:tu,skewY:tu,distance:ru,translateX:ru,translateY:ru,translateZ:ru,x:ru,y:ru,z:ru,perspective:ru,transformPerspective:ru,opacity:Kc,originX:su,originY:su,originZ:ru,zIndex:au,fillOpacity:Kc,strokeOpacity:Kc,numOctaves:au};function cu(e,t,n,r){const{style:o,vars:i,transform:s,transformOrigin:a}=e;let l=!1,c=!1,u=!0;for(const d in t){const e=t[d];if(Wc(d)){i[d]=e;continue}const n=lu[d],r=Uc(e,n);if(Vc.has(d)){if(l=!0,s[d]=r,!u)continue;e!==(n.default||0)&&(u=!1)}else d.startsWith("origin")?(c=!0,a[d]=r):o[d]=r}if(t.transform||(l||r?o.transform=function(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,o){let i="";for(let s=0;s<jc;s++){const t=Ic[s];void 0!==e[t]&&(i+=`${Fc[t]||t}(${e[t]}) `)}return t&&!e.z&&(i+="translateZ(0)"),i=i.trim(),o?i=o(e,r?"":i):n&&r&&(i="none"),i}(e.transform,n,u,r):o.transform&&(o.transform="none")),c){const{originX:e="50%",originY:t="50%",originZ:n=0}=a;o.transformOrigin=`${e} ${t} ${n}`}}const uu=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function du(e,t,n){for(const r in t)Nc(t[r])||$c(r,n)||(e[r]=t[r])}function fu(t,n,r){const o={};return du(o,t.style||{},t),Object.assign(o,function({transformTemplate:t},n,r){return e.useMemo((()=>{const e=uu();return cu(e,n,{enableHardwareAcceleration:!r},t),Object.assign({},e.vars,e.style)}),[n])}(t,n,r)),t.transformValues?t.transformValues(o):o}function pu(e,t,n){const r={},o=fu(e,t,n);return e.drag&&!1!==e.dragListener&&(r.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=o,r}const hu=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","transformValues","custom","inherit","onLayoutAnimationStart","onLayoutAnimationComplete","onLayoutMeasure","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","ignoreStrict","viewport"]);function mu(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||hu.has(e)}let vu=e=>!mu(e);try{(gu=require("@emotion/is-prop-valid").default)&&(vu=e=>e.startsWith("on")?!mu(e):gu(e))}catch(ny){}var gu;function yu(e,t,n){return"string"==typeof e?e:ru.transform(t+n*e)}const bu={offset:"stroke-dashoffset",array:"stroke-dasharray"},wu={offset:"strokeDashoffset",array:"strokeDasharray"};function xu(e,{attrX:t,attrY:n,originX:r,originY:o,pathLength:i,pathSpacing:s=1,pathOffset:a=0,...l},c,u,d){if(cu(e,l,c,d),u)return void(e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox));e.attrs=e.style,e.style={};const{attrs:f,style:p,dimensions:h}=e;f.transform&&(h&&(p.transform=f.transform),delete f.transform),h&&(void 0!==r||void 0!==o||p.transform)&&(p.transformOrigin=function(e,t,n){return`${yu(t,e.x,e.width)} ${yu(n,e.y,e.height)}`}(h,void 0!==r?r:.5,void 0!==o?o:.5)),void 0!==t&&(f.x=t),void 0!==n&&(f.y=n),void 0!==i&&function(e,t,n=1,r=0,o=!0){e.pathLength=1;const i=o?bu:wu;e[i.offset]=ru.transform(-r);const s=ru.transform(t),a=ru.transform(n);e[i.array]=`${s} ${a}`}(f,i,s,a,!1)}const Eu=()=>({...uu(),attrs:{}}),Su=e=>"string"==typeof e&&"svg"===e.toLowerCase();function Pu(t,n,r,o){const i=e.useMemo((()=>{const e=Eu();return xu(e,n,{enableHardwareAcceleration:!1},Su(o),t.transformTemplate),{...e.attrs,style:{...e.style}}}),[n]);if(t.style){const e={};du(e,t.style,t),i.style={...e,...i.style}}return i}function Cu(t=!1){return(n,r,o,i,{latestValues:s},a)=>{const l=(Lc(n)?Pu:pu)(r,s,a,n),c=function(e,t,n){const r={};for(const o in e)"values"===o&&"object"==typeof e.values||(vu(o)||!0===n&&mu(o)||!t&&!mu(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}(r,"string"==typeof n,t),u={...c,...l,ref:i},{children:d}=r,f=e.useMemo((()=>Nc(d)?d.get():d),[d]);return o&&(u["data-projection-id"]=o),e.createElement(n,{...u,children:f})}}const Tu=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase();function Ru(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const i in n)e.style.setProperty(i,n[i])}const Au=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Ou(e,t,n,r){Ru(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(Au.has(o)?o:Tu(o),t.attrs[o])}function Du(e,t){const{style:n}=e,r={};for(const o in n)(Nc(n[o])||t.style&&Nc(t.style[o])||$c(o,e))&&(r[o]=n[o]);return r}function ku(e,t){const n=Du(e,t);for(const r in e)if(Nc(e[r])||Nc(t[r])){n["x"===r||"y"===r?"attr"+r.toUpperCase():r]=e[r]}return n}function _u(e,t,n,r={},o={}){return"function"==typeof t&&(t=t(void 0!==n?n:e.custom,r,o)),"string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t&&(t=t(void 0!==n?n:e.custom,r,o)),t}const Lu=e=>Array.isArray(e),Mu=e=>Boolean(e&&"object"==typeof e&&e.mix&&e.toValue),Iu=e=>Lu(e)?e[e.length-1]||0:e;function Vu(e){const t=Nc(e)?e.get():e;return Mu(t)?t.toValue():t}const $u=t=>(n,r)=>{const o=e.useContext(ac),i=e.useContext(lc),s=()=>function({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,o,i){const s={latestValues:Nu(r,o,i,e),renderState:t()};return n&&(s.mount=e=>n(r,e,s)),s}(t,n,o,i);return r?s():Sc(s)};function Nu(e,t,n,r){const o={},i=r(e,{});for(const f in i)o[f]=Vu(i[f]);let{initial:s,animate:a}=e;const l=gc(e),c=yc(e);t&&c&&!l&&!1!==e.inherit&&(void 0===s&&(s=t.initial),void 0===a&&(a=t.animate));let u=!!n&&!1===n.initial;u=u||!1===s;const d=u?a:s;if(d&&"boolean"!=typeof d&&!hc(d)){(Array.isArray(d)?d:[d]).forEach((t=>{const n=_u(e,t);if(!n)return;const{transitionEnd:r,transition:i,...s}=n;for(const e in s){let t=s[e];if(Array.isArray(t)){t=t[u?t.length-1:0]}null!==t&&(o[e]=t)}for(const e in r)o[e]=r[e]}))}return o}const Fu={useVisualState:$u({scrapeMotionValuesFromProps:ku,createRenderState:Eu,onMount:(e,t,{renderState:n,latestValues:r})=>{try{n.dimensions="function"==typeof t.getBBox?t.getBBox():t.getBoundingClientRect()}catch(o){n.dimensions={x:0,y:0,width:0,height:0}}xu(n,r,{enableHardwareAcceleration:!1},Su(t.tagName),e.transformTemplate),Ou(t,n)}})},ju={useVisualState:$u({scrapeMotionValuesFromProps:Du,createRenderState:uu})};function Bu(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const Wu=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary;function Hu(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const Uu=e=>t=>Wu(t)&&e(t,Hu(t));function zu(e,t,n,r){return Bu(e,t,Uu(n),r)}const Yu=(e,t)=>n=>t(e(n)),Ku=(...e)=>e.reduce(Yu);function Xu(e){let t=null;return()=>{const n=()=>{t=null};return null===t&&(t=e,n)}}const qu=Xu("dragHorizontal"),Gu=Xu("dragVertical");function Zu(e){let t=!1;if("y"===e)t=Gu();else if("x"===e)t=qu();else{const e=qu(),n=Gu();e&&n?t=()=>{e(),n()}:(e&&e(),n&&n())}return t}function Ju(){const e=Zu(!0);return!e||(e(),!1)}class Qu{constructor(e){this.isMounted=!1,this.node=e}update(){}}const ed={delta:0,timestamp:0,isProcessing:!1};let td=!0,nd=!1;const rd=["read","update","preRender","render","postRender"],od=rd.reduce(((e,t)=>(e[t]=function(e){let t=[],n=[],r=0,o=!1,i=!1;const s=new WeakSet,a={schedule:(e,i=!1,a=!1)=>{const l=a&&o,c=l?t:n;return i&&s.add(e),-1===c.indexOf(e)&&(c.push(e),l&&o&&(r=t.length)),e},cancel:e=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1),s.delete(e)},process:l=>{if(o)i=!0;else{if(o=!0,[t,n]=[n,t],n.length=0,r=t.length,r)for(let n=0;n<r;n++){const r=t[n];r(l),s.has(r)&&(a.schedule(r),e())}o=!1,i&&(i=!1,a.process(l))}}};return a}((()=>nd=!0)),e)),{}),id=rd.reduce(((e,t)=>{const n=od[t];return e[t]=(e,t=!1,r=!1)=>(nd||ud(),n.schedule(e,t,r)),e}),{}),sd=rd.reduce(((e,t)=>(e[t]=od[t].cancel,e)),{}),ad=rd.reduce(((e,t)=>(e[t]=()=>od[t].process(ed),e)),{}),ld=e=>od[e].process(ed),cd=e=>{nd=!1,ed.delta=td?1e3/60:Math.max(Math.min(e-ed.timestamp,40),1),ed.timestamp=e,ed.isProcessing=!0,rd.forEach(ld),ed.isProcessing=!1,nd&&(td=!1,requestAnimationFrame(cd))},ud=()=>{nd=!0,td=!0,ed.isProcessing||requestAnimationFrame(cd)};function dd(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End");return zu(e.current,n,((n,o)=>{if("touch"===n.type||Ju())return;const i=e.getProps();e.animationState&&i.whileHover&&e.animationState.setActive("whileHover",t),i[r]&&id.update((()=>i[r](n,o)))}),{passive:!e.getProps()[r]})}const fd=(e,t)=>!!t&&(e===t||fd(e,t.parentElement)),pd=e=>e;function hd(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,Hu(n))}const md=new WeakMap,vd=new WeakMap,gd=e=>{const t=md.get(e.target);t&&t(e)},yd=e=>{e.forEach(gd)};function bd(e,t,n){const r=function({root:e,...t}){const n=e||document;vd.has(n)||vd.set(n,{});const r=vd.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(yd,{root:e,...t})),r[o]}(t);return md.set(e,n),r.observe(e),()=>{md.delete(e),r.unobserve(e)}}const wd={some:0,all:1};const xd={inView:{Feature:class extends Qu{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:o}=e,i={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:wd[r]};return bd(this.node.current,i,(e=>{const{isIntersecting:t}=e;if(this.isInView===t)return;if(this.isInView=t,o&&!t&&this.hasEnteredView)return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);const{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),i=t?n:r;i&&i(e)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends Qu{constructor(){super(...arguments),this.removeStartListeners=pd,this.removeEndListeners=pd,this.removeAccessibleListeners=pd,this.startPointerPress=(e,t)=>{if(this.removeEndListeners(),this.isPressing)return;const n=this.node.getProps(),r=zu(window,"pointerup",((e,t)=>{if(!this.checkPressEnd())return;const{onTap:n,onTapCancel:r}=this.node.getProps();id.update((()=>{fd(this.node.current,e.target)?n&&n(e,t):r&&r(e,t)}))}),{passive:!(n.onTap||n.onPointerUp)}),o=zu(window,"pointercancel",((e,t)=>this.cancelPress(e,t)),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=Ku(r,o),this.startPress(e,t)},this.startAccessiblePress=()=>{const e=Bu(this.node.current,"keydown",(e=>{if("Enter"!==e.key||this.isPressing)return;this.removeEndListeners(),this.removeEndListeners=Bu(this.node.current,"keyup",(e=>{"Enter"===e.key&&this.checkPressEnd()&&hd("up",((e,t)=>{const{onTap:n}=this.node.getProps();n&&id.update((()=>n(e,t)))}))})),hd("down",((e,t)=>{this.startPress(e,t)}))})),t=Bu(this.node.current,"blur",(()=>{this.isPressing&&hd("cancel",((e,t)=>this.cancelPress(e,t)))}));this.removeAccessibleListeners=Ku(e,t)}}startPress(e,t){this.isPressing=!0;const{onTapStart:n,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&id.update((()=>n(e,t)))}checkPressEnd(){this.removeEndListeners(),this.isPressing=!1;return this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!Ju()}cancelPress(e,t){if(!this.checkPressEnd())return;const{onTapCancel:n}=this.node.getProps();n&&id.update((()=>n(e,t)))}mount(){const e=this.node.getProps(),t=zu(this.node.current,"pointerdown",this.startPointerPress,{passive:!(e.onTapStart||e.onPointerStart)}),n=Bu(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Ku(t,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}},focus:{Feature:class extends Qu{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Ku(Bu(this.node.current,"focus",(()=>this.onFocus())),Bu(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends Qu{mount(){this.unmount=Ku(dd(this.node,!0),dd(this.node,!1))}unmount(){}}}};function Ed(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function Sd(e,t,n){const r=e.getProps();return _u(r,t,void 0!==n?n:r.custom,function(e){const t={};return e.values.forEach(((e,n)=>t[n]=e.get())),t}(e),function(e){const t={};return e.values.forEach(((e,n)=>t[n]=e.getVelocity())),t}(e))}const Pd="data-"+Tu("framerAppearId");let Cd=pd,Td=pd;"production"!==process.env.NODE_ENV&&(Cd=(e,t)=>{e||"undefined"==typeof console||console.warn(t)},Td=(e,t)=>{if(!e)throw new Error(t)});const Rd=e=>1e3*e,Ad=e=>e/1e3,Od=!1,Dd=e=>Array.isArray(e)&&"number"==typeof e[0];function kd(e){return Boolean(!e||"string"==typeof e&&Ld[e]||Dd(e)||Array.isArray(e)&&e.every(kd))}const _d=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Ld={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:_d([0,.65,.55,1]),circOut:_d([.55,0,1,.45]),backIn:_d([.31,.01,.66,-.59]),backOut:_d([.33,1.53,.69,.99])};function Md(e){if(e)return Dd(e)?_d(e):Array.isArray(e)?e.map(Md):Ld[e]}const Id={waapi:()=>Object.hasOwnProperty.call(Element.prototype,"animate")},Vd={},$d={};for(const ry in Id)$d[ry]=()=>(void 0===Vd[ry]&&(Vd[ry]=Id[ry]()),Vd[ry]);const Nd=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Fd=1e-7,jd=12;function Bd(e,t,n,r){if(e===t&&n===r)return pd;const o=t=>function(e,t,n,r,o){let i,s,a=0;do{s=t+(n-t)/2,i=Nd(s,r,o)-e,i>0?n=s:t=s}while(Math.abs(i)>Fd&&++a<jd);return s}(t,0,1,e,n);return e=>0===e||1===e?e:Nd(o(e),t,r)}const Wd=Bd(.42,0,1,1),Hd=Bd(0,0,.58,1),Ud=Bd(.42,0,.58,1),zd=e=>Array.isArray(e)&&"number"!=typeof e[0],Yd=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Kd=e=>t=>1-e(1-t),Xd=e=>1-Math.sin(Math.acos(e)),qd=Kd(Xd),Gd=Yd(qd),Zd=Bd(.33,1.53,.69,.99),Jd=Kd(Zd),Qd=Yd(Jd),ef={linear:pd,easeIn:Wd,easeInOut:Ud,easeOut:Hd,circIn:Xd,circInOut:Gd,circOut:qd,backIn:Jd,backInOut:Qd,backOut:Zd,anticipate:e=>(e*=2)<1?.5*Jd(e):.5*(2-Math.pow(2,-10*(e-1)))},tf=e=>{if(Array.isArray(e)){Td(4===e.length,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,o]=e;return Bd(t,n,r,o)}return"string"==typeof e?(Td(void 0!==ef[e],`Invalid easing type '${e}'`),ef[e]):e},nf=(e,t)=>n=>Boolean(Qc(n)&&Jc.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),rf=(e,t,n)=>r=>{if(!Qc(r))return r;const[o,i,s,a]=r.match(Gc);return{[e]:parseFloat(o),[t]:parseFloat(i),[n]:parseFloat(s),alpha:void 0!==a?parseFloat(a):1}},of={...Yc,transform:e=>Math.round((e=>zc(0,255,e))(e))},sf={test:nf("rgb","red"),parse:rf("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+of.transform(e)+", "+of.transform(t)+", "+of.transform(n)+", "+qc(Kc.transform(r))+")"};const af={test:nf("#"),parse:function(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}},transform:sf.transform},lf={test:nf("hsl","hue"),parse:rf("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+nu.transform(qc(t))+", "+nu.transform(qc(n))+", "+qc(Kc.transform(r))+")"},cf={test:e=>sf.test(e)||af.test(e)||lf.test(e),parse:e=>sf.test(e)?sf.parse(e):lf.test(e)?lf.parse(e):af.parse(e),transform:e=>Qc(e)?e:e.hasOwnProperty("red")?sf.transform(e):lf.transform(e)},uf=(e,t,n)=>-n*e+n*t+e;function df(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}const ff=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},pf=[af,sf,lf];function hf(e){const t=(n=e,pf.find((e=>e.test(n))));var n;Td(Boolean(t),`'${e}' is not an animatable color. Use the equivalent color code instead.`);let r=t.parse(e);return t===lf&&(r=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let o=0,i=0,s=0;if(t/=100){const r=n<.5?n*(1+t):n+t-n*t,a=2*n-r;o=df(a,r,e+1/3),i=df(a,r,e),s=df(a,r,e-1/3)}else o=i=s=n;return{red:Math.round(255*o),green:Math.round(255*i),blue:Math.round(255*s),alpha:r}}(r)),r}const mf=(e,t)=>{const n=hf(e),r=hf(t),o={...n};return e=>(o.red=ff(n.red,r.red,e),o.green=ff(n.green,r.green,e),o.blue=ff(n.blue,r.blue,e),o.alpha=uf(n.alpha,r.alpha,e),sf.transform(o))},vf="${c}",gf="${n}";function yf(e){"number"==typeof e&&(e=`${e}`);const t=[];let n=0,r=0;const o=e.match(Zc);o&&(n=o.length,e=e.replace(Zc,vf),t.push(...o.map(cf.parse)));const i=e.match(Gc);return i&&(r=i.length,e=e.replace(Gc,gf),t.push(...i.map(Yc.parse))),{values:t,numColors:n,numNumbers:r,tokenised:e}}function bf(e){return yf(e).values}function wf(e){const{values:t,numColors:n,tokenised:r}=yf(e),o=t.length;return e=>{let t=r;for(let r=0;r<o;r++)t=t.replace(r<n?vf:gf,r<n?cf.transform(e[r]):qc(e[r]));return t}}const xf=e=>"number"==typeof e?0:e;const Ef={test:function(e){var t,n;return isNaN(e)&&Qc(e)&&((null===(t=e.match(Gc))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(Zc))||void 0===n?void 0:n.length)||0)>0},parse:bf,createTransformer:wf,getAnimatableNone:function(e){const t=bf(e);return wf(e)(t.map(xf))}};function Sf(e,t){return"number"==typeof e?n=>uf(e,t,n):cf.test(e)?mf(e,t):Tf(e,t)}const Pf=(e,t)=>{const n=[...e],r=n.length,o=e.map(((e,n)=>Sf(e,t[n])));return e=>{for(let t=0;t<r;t++)n[t]=o[t](e);return n}},Cf=(e,t)=>{const n={...e,...t},r={};for(const o in n)void 0!==e[o]&&void 0!==t[o]&&(r[o]=Sf(e[o],t[o]));return e=>{for(const t in r)n[t]=r[t](e);return n}},Tf=(e,t)=>{const n=Ef.createTransformer(t),r=yf(e),o=yf(t);return r.numColors===o.numColors&&r.numNumbers>=o.numNumbers?Ku(Pf(r.values,o.values),n):(Cd(!0,`Complex values '${e}' and '${t}' 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=>`${n>0?t:e}`)},Rf=(e,t,n)=>{const r=t-e;return 0===r?1:(n-e)/r},Af=(e,t)=>n=>uf(e,t,n);function Of(e,t,n){const r=[],o=n||("number"==typeof(i=e[0])?Af:"string"==typeof i?cf.test(i)?mf:Tf:Array.isArray(i)?Pf:"object"==typeof i?Cf:Af);var i;const s=e.length-1;for(let a=0;a<s;a++){let n=o(e[a],e[a+1]);if(t){const e=Array.isArray(t)?t[a]||pd:t;n=Ku(e,n)}r.push(n)}return r}function Df(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const i=e.length;if(Td(i===t.length,"Both input and output ranges must be the same length"),1===i)return()=>t[0];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=Of(t,r,o),a=s.length,l=t=>{let n=0;if(a>1)for(;n<e.length-2&&!(t<e[n+1]);n++);const r=Rf(e[n],e[n+1],t);return s[n](r)};return n?t=>l(zc(e[0],e[i-1],t)):l}function kf(e){const t=[0];return function(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=Rf(0,t,r);e.push(uf(n,1,o))}}(t,e.length-1),t}function _f({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=zd(r)?r.map(tf):tf(r),i={done:!1,value:t[0]},s=function(e,t){return e.map((e=>e*t))}(n&&n.length===t.length?n:kf(t),e),a=Df(s,t,{ease:Array.isArray(o)?o:(l=t,c=o,l.map((()=>c||Ud)).splice(0,l.length-1))});var l,c;return{calculatedDuration:e,next:t=>(i.value=a(t),i.done=t>=e,i)}}function Lf(e,t){return t?e*(1e3/t):0}const Mf=5;function If(e,t,n){const r=Math.max(t-Mf,0);return Lf(n-e(r),t-r)}const Vf=.001,$f=.01,Nf=10,Ff=.05,jf=1;function Bf({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let o,i;Cd(e<=Rd(Nf),"Spring duration must be 10 seconds or less");let s=1-t;s=zc(Ff,jf,s),e=zc($f,Nf,Ad(e)),s<1?(o=t=>{const r=t*s,o=r*e,i=r-n,a=Hf(t,s),l=Math.exp(-o);return Vf-i/a*l},i=t=>{const r=t*s*e,i=r*n+n,a=Math.pow(s,2)*Math.pow(t,2)*e,l=Math.exp(-r),c=Hf(Math.pow(t,2),s);return(-o(t)+Vf>0?-1:1)*((i-a)*l)/c}):(o=t=>Math.exp(-t*e)*((t-n)*e+1)-Vf,i=t=>Math.exp(-t*e)*(e*e*(n-t)));const a=function(e,t,n){let r=n;for(let o=1;o<Wf;o++)r-=e(r)/t(r);return r}(o,i,5/e);if(e=Rd(e),isNaN(a))return{stiffness:100,damping:10,duration:e};{const t=Math.pow(a,2)*r;return{stiffness:t,damping:2*s*Math.sqrt(r*t),duration:e}}}const Wf=12;function Hf(e,t){return e*Math.sqrt(1-t*t)}const Uf=["duration","bounce"],zf=["stiffness","damping","mass"];function Yf(e,t){return t.some((t=>void 0!==e[t]))}function Kf({keyframes:e,restDelta:t,restSpeed:n,...r}){const o=e[0],i=e[e.length-1],s={done:!1,value:o},{stiffness:a,damping:l,mass:c,velocity:u,duration:d,isResolvedFromDuration:f}=function(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!Yf(e,zf)&&Yf(e,Uf)){const n=Bf(e);t={...t,...n,velocity:0,mass:1},t.isResolvedFromDuration=!0}return t}(r),p=u?-Ad(u):0,h=l/(2*Math.sqrt(a*c)),m=i-o,v=Ad(Math.sqrt(a/c)),g=Math.abs(m)<5;let y;if(n||(n=g?.01:2),t||(t=g?.005:.5),h<1){const e=Hf(v,h);y=t=>{const n=Math.exp(-h*v*t);return i-n*((p+h*v*m)/e*Math.sin(e*t)+m*Math.cos(e*t))}}else if(1===h)y=e=>i-Math.exp(-v*e)*(m+(p+v*m)*e);else{const e=v*Math.sqrt(h*h-1);y=t=>{const n=Math.exp(-h*v*t),r=Math.min(e*t,300);return i-n*((p+h*v*m)*Math.sinh(r)+e*m*Math.cosh(r))/e}}return{calculatedDuration:f&&d||null,next:e=>{const r=y(e);if(f)s.done=e>=d;else{let o=p;0!==e&&(o=h<1?If(y,e,r):0);const a=Math.abs(o)<=n,l=Math.abs(i-r)<=t;s.done=a&&l}return s.value=s.done?i:r,s}}}function Xf({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],f={done:!1,value:d},p=e=>void 0===a?l:void 0===l||Math.abs(a-e)<Math.abs(l-e)?a:l;let h=n*t;const m=d+h,v=void 0===s?m:s(m);v!==m&&(h=v-d);const g=e=>-h*Math.exp(-e/r),y=e=>v+g(e),b=e=>{const t=g(e),n=y(e);f.done=Math.abs(t)<=c,f.value=f.done?v:n};let w,x;const E=e=>{var t;(t=f.value,void 0!==a&&t<a||void 0!==l&&t>l)&&(w=e,x=Kf({keyframes:[f.value,p(f.value)],velocity:If(y,e,f.value),damping:o,stiffness:i,restDelta:c,restSpeed:u}))};return E(0),{calculatedDuration:null,next:e=>{let t=!1;return x||void 0!==w||(t=!0,b(e),E(e)),void 0!==w&&e>w?x.next(e-w):(!t&&b(e),f)}}}const qf=e=>{const t=({timestamp:t})=>e(t);return{start:()=>id.update(t,!0),stop:()=>sd.update(t),now:()=>ed.isProcessing?ed.timestamp:performance.now()}},Gf={decay:Xf,inertia:Xf,tween:_f,keyframes:_f,spring:Kf},Zf=2e4;function Jf(e){let t=0;let n=e.next(t);for(;!n.done&&t<Zf;)t+=50,n=e.next(t);return t>=Zf?1/0:t}function Qf({autoplay:e=!0,delay:t=0,driver:n=qf,keyframes:r,type:o="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:a="loop",onPlay:l,onStop:c,onComplete:u,onUpdate:d,...f}){let p,h,m=1,v=!1;const g=()=>{p&&p(),h=new Promise((e=>{p=e}))};let y;g();const b=Gf[o]||_f;let w;b!==_f&&"number"!=typeof r[0]&&(w=Df([0,100],r,{clamp:!1}),r=[0,100]);const x=b({...f,keyframes:r});let E;"mirror"===a&&(E=b({...f,keyframes:[...r].reverse(),velocity:-(f.velocity||0)}));let S="idle",P=null,C=null,T=null;null===x.calculatedDuration&&i&&(x.calculatedDuration=Jf(x));const{calculatedDuration:R}=x;let A=1/0,O=1/0;null!==R&&(A=R+s,O=A*(i+1)-s);let D=0;const k=e=>{if(null===C)return;m>0&&(C=Math.min(C,e)),D=null!==P?P:(e-C)*m;const n=D-t,o=n<0;D=Math.max(n,0),"finished"===S&&null===P&&(D=O);let l=D,c=x;if(i){const e=D/A;let t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,i+1);const r=Boolean(t%2);r&&("reverse"===a?(n=1-n,s&&(n-=s/A)):"mirror"===a&&(c=E));let o=zc(0,1,n);D>O&&(o="reverse"===a&&r?1:0),l=o*A}const u=o?{done:!1,value:r[0]}:c.next(l);w&&(u.value=w(u.value));let{done:f}=u;o||null===R||(f=D>=O);const p=null===P&&("finished"===S||"running"===S&&f||m<0&&D<=0);return d&&d(u.value),p&&M(),u},_=()=>{y&&y.stop(),y=void 0},L=()=>{S="idle",_(),g(),C=T=null},M=()=>{S="finished",u&&u(),_(),g()},I=()=>{if(v)return;y||(y=n(k));const e=y.now();l&&l(),S="running",null!==P?C=e-P:C||(C=e),T=C,P=null,y.start()};e&&I();const V={then:(e,t)=>h.then(e,t),get time(){return Ad(D)},set time(e){e=Rd(e),D=e,null===P&&y&&0!==m?C=y.now()-e/m:P=e},get duration(){const e=null===x.calculatedDuration?Jf(x):x.calculatedDuration;return Ad(e)},get speed(){return m},set speed(e){e!==m&&y&&(m=e,V.time=Ad(D))},get state(){return S},play:I,pause:()=>{S="paused",P=D},stop:()=>{v=!0,"idle"!==S&&(S="idle",c&&c(),L())},cancel:()=>{null!==T&&k(T),L()},complete:()=>{S="finished"},sample:e=>(C=0,k(e))};return V}const ep=new Set(["opacity","clipPath","filter","transform","backgroundColor"]);function tp(e,t,{onUpdate:n,onComplete:r,...o}){if(!($d.waapi()&&ep.has(t)&&!o.repeatDelay&&"mirror"!==o.repeatType&&0!==o.damping&&"inertia"!==o.type))return!1;let i,s,a=!1;const l=()=>{s=new Promise((e=>{i=e}))};l();let{keyframes:c,duration:u=300,ease:d}=o;if(((e,t)=>"spring"===t.type||"backgroundColor"===e||!kd(t.ease))(t,o)){const e=Qf({...o,repeat:0,delay:0});let t={done:!1,value:c[0]};const n=[];let r=0;for(;!t.done&&r<2e4;)t=e.sample(r),n.push(t.value),r+=10;c=n,u=r-10,d="linear"}const f=function(e,t,n,{delay:r=0,duration:o,repeat:i=0,repeatType:s="loop",ease:a,times:l}={}){const c={[t]:n};l&&(c.offset=l);const u=Md(a);return Array.isArray(u)&&(c.easing=u),e.animate(c,{delay:r,duration:o,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:"reverse"===s?"alternate":"normal"})}(e.owner.current,t,c,{...o,duration:u,ease:d}),p=()=>{id.update((()=>f.cancel())),i(),l()};return f.onfinish=()=>{e.set(function(e,{repeat:t,repeatType:n="loop"}){return e[t&&"loop"!==n&&t%2==1?0:e.length-1]}(c,o)),r&&r(),p()},{then:(e,t)=>s.then(e,t),get time(){return Ad(f.currentTime||0)},set time(e){f.currentTime=Rd(e)},get speed(){return f.playbackRate},set speed(e){f.playbackRate=e},get duration(){return Ad(u)},play:()=>{a||f.play()},pause:()=>f.pause(),stop:()=>{if(a=!0,"idle"===f.playState)return;const{currentTime:t}=f;if(t){const n=Qf({...o,autoplay:!1});e.setWithVelocity(n.sample(t-10).value,n.sample(t).value,10)}p()},complete:()=>f.finish(),cancel:p}}const np={type:"spring",stiffness:500,damping:25,restSpeed:10},rp={type:"keyframes",duration:.8},op={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},ip=(e,{keyframes:t})=>t.length>2?rp:Vc.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:np:op,sp=(e,t)=>"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Ef.test(t)||t.startsWith("url("))),ap=new Set(["brightness","contrast","saturate","opacity"]);function lp(e){const[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;const[r]=n.match(Gc)||[];if(!r)return e;const o=n.replace(r,"");let i=ap.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+o+")"}const cp=/([a-z-]*)\(.*?\)/g,up={...Ef,getAnimatableNone:e=>{const t=e.match(cp);return t?t.map(lp).join(" "):e}},dp={...lu,color:cf,backgroundColor:cf,outlineColor:cf,fill:cf,stroke:cf,borderColor:cf,borderTopColor:cf,borderRightColor:cf,borderBottomColor:cf,borderLeftColor:cf,filter:up,WebkitFilter:up},fp=e=>dp[e];function pp(e,t){let n=fp(e);return n!==up&&(n=Ef),n.getAnimatableNone?n.getAnimatableNone(t):void 0}function hp(e){return 0===e||"string"==typeof e&&0===parseFloat(e)&&-1===e.indexOf(" ")}function mp(e){return"number"==typeof e?0:pp("",e)}function vp(e,t){return e[t]||e.default||e}const gp=(e,t,n,r={})=>o=>{const i=vp(r,e)||{},s=i.delay||r.delay||0;let{elapsed:a=0}=r;a-=Rd(s);const l=function(e,t,n,r){const o=sp(t,n);let i=void 0!==r.from?r.from:e.get();if("none"===i&&o&&"string"==typeof n?i=pp(t,n):hp(i)&&"string"==typeof n?i=mp(n):!Array.isArray(n)&&hp(n)&&"string"==typeof i&&(n=mp(i)),Array.isArray(n)){for(let e=0;e<n.length;e++)null===n[e]&&(n[e]=0===e?i:n[e-1]);return n}return[i,n]}(t,e,n,i),c=l[0],u=l[l.length-1],d=sp(e,c),f=sp(e,u);Cd(d===f,`You are trying to animate ${e} from "${c}" to "${u}". ${c} is not an animatable value - to enable this animation set ${c} to a value animatable to ${u} via the \`style\` property.`);let p={keyframes:l,velocity:t.getVelocity(),ease:"easeOut",...i,delay:-a,onUpdate:e=>{t.set(e),i.onUpdate&&i.onUpdate(e)},onComplete:()=>{o(),i.onComplete&&i.onComplete()}};if(function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:c,...u}){return!!Object.keys(u).length}(i)||(p={...p,...ip(e,p)}),p.duration&&(p.duration=Rd(p.duration)),p.repeatDelay&&(p.repeatDelay=Rd(p.repeatDelay)),!d||!f||Od||!1===i.type)return function({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const o=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:pd,pause:pd,stop:pd,then:e=>(e(),Promise.resolve()),cancel:pd,complete:pd});return t?Qf({keyframes:[0,1],duration:0,delay:t,onComplete:o}):o()}(p);if(t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const n=tp(t,e,p);if(n)return n}return Qf(p)};function yp(e){return Boolean(Nc(e)&&e.add)}const bp=e=>/^0[^.\s]+$/.test(e);function wp(e,t){-1===e.indexOf(t)&&e.push(t)}function xp(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class Ep{constructor(){this.subscriptions=[]}add(e){return wp(this.subscriptions,e),()=>xp(this.subscriptions,e)}notify(e,t,n){const r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](e,t,n);else for(let o=0;o<r;o++){const r=this.subscriptions[o];r&&r(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Sp=new Set;function Pp(e,t,n){e||Sp.has(t)||(console.warn(t),n&&console.warn(n),Sp.add(t))}class Cp{constructor(e,t={}){var n;this.version="10.10.0",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(e,t=!0)=>{this.prev=this.current,this.current=e;const{delta:n,timestamp:r}=ed;this.lastUpdated!==r&&(this.timeDelta=n,this.lastUpdated=r,id.postRender(this.scheduleVelocityCheck)),this.prev!==this.current&&this.events.change&&this.events.change.notify(this.current),this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>id.postRender(this.velocityCheck),this.velocityCheck=({timestamp:e})=>{e!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=e,this.canTrackVelocity=(n=this.current,!isNaN(parseFloat(n))),this.owner=t.owner}onChange(e){return"production"!==process.env.NODE_ENV&&Pp(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new Ep);const n=this.events[e].add(t);return"change"===e?()=>{n(),id.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=e,this.timeDelta=n}jump(e){this.updateAndNotify(e),this.prev=e,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?Lf(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(e){return this.stop(),new Promise((t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()})).then((()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()}))}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Tp(e,t){return new Cp(e,t)}const Rp=e=>t=>t.test(e),Ap=[Yc,ru,nu,tu,iu,ou,{test:e=>"auto"===e,parse:e=>e}],Op=e=>Ap.find(Rp(e)),Dp=[...Ap,cf,Ef],kp=e=>Dp.find(Rp(e));function _p(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Tp(n))}function Lp(e,t){if(!t)return;return(t[e]||t.default||t).from}function Mp({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}function Ip(e,t,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=e.makeTargetAnimatable(t);const l=e.getValue("willChange");r&&(i=r);const c=[],u=o&&e.animationState&&e.animationState.getState()[o];for(const d in a){const t=e.getValue(d),r=a[d];if(!t||void 0===r||u&&Mp(u,d))continue;const o={delay:n,elapsed:0,...i};if(window.HandoffAppearAnimations&&!t.hasAnimated){const n=e.getProps()[Pd];n&&(o.elapsed=window.HandoffAppearAnimations(n,d,t,id))}t.start(gp(d,t,r,e.shouldReduceMotion&&Vc.has(d)?{type:!1}:o));const s=t.animation;yp(l)&&(l.add(d),s.then((()=>l.remove(d)))),c.push(s)}return s&&Promise.all(c).then((()=>{s&&function(e,t){const n=Sd(e,t);let{transitionEnd:r={},transition:o={},...i}=n?e.makeTargetAnimatable(n,!1):{};i={...i,...r};for(const s in i)_p(e,s,Iu(i[s]))}(e,s)})),c}function Vp(e,t,n={}){const r=Sd(e,t,n.custom);let{transition:o=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const i=r?()=>Promise.all(Ip(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(r=0)=>{const{delayChildren:i=0,staggerChildren:s,staggerDirection:a}=o;return function(e,t,n=0,r=0,o=1,i){const s=[],a=(e.variantChildren.size-1)*r,l=1===o?(e=0)=>e*r:(e=0)=>a-e*r;return Array.from(e.variantChildren).sort($p).forEach(((e,r)=>{e.notify("AnimationStart",t),s.push(Vp(e,t,{...i,delay:n+l(r)}).then((()=>e.notify("AnimationComplete",t))))})),Promise.all(s)}(e,t,i+r,s,a,n)}:()=>Promise.resolve(),{when:a}=o;if(a){const[e,t]="beforeChildren"===a?[i,s]:[s,i];return e().then((()=>t()))}return Promise.all([i(),s(n.delay)])}function $p(e,t){return e.sortNodePosition(t)}const Np=[...mc].reverse(),Fp=mc.length;function jp(e){return t=>Promise.all(t.map((({animation:t,options:n})=>function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t)){const o=t.map((t=>Vp(e,t,n)));r=Promise.all(o)}else if("string"==typeof t)r=Vp(e,t,n);else{const o="function"==typeof t?Sd(e,t,n.custom):t;r=Promise.all(Ip(e,o,n))}return r.then((()=>e.notify("AnimationComplete",t)))}(e,t,n))))}function Bp(e){let t=jp(e);const n={animate:Hp(!0),whileInView:Hp(),whileHover:Hp(),whileTap:Hp(),whileDrag:Hp(),whileFocus:Hp(),exit:Hp()};let r=!0;const o=(t,n)=>{const r=Sd(e,n);if(r){const{transition:e,transitionEnd:n,...o}=r;t={...t,...o,...n}}return t};function i(i,s){const a=e.getProps(),l=e.getVariantContext(!0)||{},c=[],u=new Set;let d={},f=1/0;for(let t=0;t<Fp;t++){const p=Np[t],h=n[p],m=void 0!==a[p]?a[p]:l[p],v=pc(m),g=p===s?h.isActive:null;!1===g&&(f=t);let y=m===l[p]&&m!==a[p]&&v;if(y&&r&&e.manuallyAnimateOnMount&&(y=!1),h.protectedKeys={...d},!h.isActive&&null===g||!m&&!h.prevProp||hc(m)||"boolean"==typeof m)continue;const b=Wp(h.prevProp,m);let w=b||p===s&&h.isActive&&!y&&v||t>f&&v;const x=Array.isArray(m)?m:[m];let E=x.reduce(o,{});!1===g&&(E={});const{prevResolvedValues:S={}}=h,P={...S,...E},C=e=>{w=!0,u.delete(e),h.needsAnimating[e]=!0};for(const e in P){const t=E[e],n=S[e];d.hasOwnProperty(e)||(t!==n?Lu(t)&&Lu(n)?!Ed(t,n)||b?C(e):h.protectedKeys[e]=!0:void 0!==t?C(e):u.add(e):void 0!==t&&u.has(e)?C(e):h.protectedKeys[e]=!0)}h.prevProp=m,h.prevResolvedValues=E,h.isActive&&(d={...d,...E}),r&&e.blockInitialAnimation&&(w=!1),w&&!y&&c.push(...x.map((e=>({animation:e,options:{type:p,...i}}))))}if(u.size){const t={};u.forEach((n=>{const r=e.getBaseTarget(n);void 0!==r&&(t[n]=r)})),c.push({animation:t})}let p=Boolean(c.length);return r&&!1===a.initial&&!e.manuallyAnimateOnMount&&(p=!1),r=!1,p?t(c):Promise.resolve()}return{animateChanges:i,setActive:function(t,r,o){var s;if(n[t].isActive===r)return Promise.resolve();null===(s=e.variantChildren)||void 0===s||s.forEach((e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,r)})),n[t].isActive=r;const a=i(o,t);for(const e in n)n[e].protectedKeys={};return a},setAnimateFunction:function(n){t=n(e)},getState:()=>n}}function Wp(e,t){return"string"==typeof t?t!==e:!!Array.isArray(t)&&!Ed(t,e)}function Hp(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}let Up=0;const zp={animation:{Feature:class extends Qu{constructor(e){super(e),e.animationState||(e.animationState=Bp(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();this.unmount(),hc(e)&&(this.unmount=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){}}},exit:{Feature:class extends Qu{constructor(){super(...arguments),this.id=Up++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:t,custom:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===r)return;const o=this.node.animationState.setActive("exit",!e,{custom:null!=n?n:this.node.getProps().custom});t&&!e&&o.then((()=>t(this.id)))}mount(){const{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}}},Yp=(e,t)=>Math.abs(e-t);class Kp{constructor(e,t,{transformPagePoint:n}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const e=Gp(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){const n=Yp(e.x,t.x),r=Yp(e.y,t.y);return Math.sqrt(n**2+r**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;const{point:r}=e,{timestamp:o}=ed;this.history.push({...r,timestamp:o});const{onStart:i,onMove:s}=this.handlers;t||(i&&i(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),s&&s(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=Xp(t,this.transformPagePoint),id.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{if(this.end(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const{onEnd:n,onSessionEnd:r}=this.handlers,o=Gp("pointercancel"===e.type?this.lastMoveEventInfo:Xp(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,o),r&&r(e,o)},!Wu(e))return;this.handlers=t,this.transformPagePoint=n;const r=Xp(Hu(e),this.transformPagePoint),{point:o}=r,{timestamp:i}=ed;this.history=[{...o,timestamp:i}];const{onSessionStart:s}=t;s&&s(e,Gp(r,this.history)),this.removeListeners=Ku(zu(window,"pointermove",this.handlePointerMove),zu(window,"pointerup",this.handlePointerUp),zu(window,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),sd.update(this.updatePoint)}}function Xp(e,t){return t?{point:t(e.point)}:e}function qp(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Gp({point:e},t){return{point:e,delta:qp(e,Jp(t)),offset:qp(e,Zp(t)),velocity:Qp(t,.1)}}function Zp(e){return e[0]}function Jp(e){return e[e.length-1]}function Qp(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=Jp(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>Rd(t)));)n--;if(!r)return{x:0,y:0};const i=Ad(o.timestamp-r.timestamp);if(0===i)return{x:0,y:0};const s={x:(o.x-r.x)/i,y:(o.y-r.y)/i};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function eh(e){return e.max-e.min}function th(e,t=0,n=.01){return Math.abs(e-t)<=n}function nh(e,t,n,r=.5){e.origin=r,e.originPoint=uf(t.min,t.max,e.origin),e.scale=eh(n)/eh(t),(th(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=uf(n.min,n.max,e.origin)-e.originPoint,(th(e.translate)||isNaN(e.translate))&&(e.translate=0)}function rh(e,t,n,r){nh(e.x,t.x,n.x,r?r.originX:void 0),nh(e.y,t.y,n.y,r?r.originY:void 0)}function oh(e,t,n){e.min=n.min+t.min,e.max=e.min+eh(t)}function ih(e,t,n){e.min=t.min-n.min,e.max=e.min+eh(t)}function sh(e,t,n){ih(e.x,t.x,n.x),ih(e.y,t.y,n.y)}function ah(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function lh(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}const ch=.35;function uh(e,t,n){return{min:dh(e,t),max:dh(e,n)}}function dh(e,t){return"number"==typeof e?e:e[t]||0}const fh=()=>({x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}),ph=()=>({x:{min:0,max:0},y:{min:0,max:0}});function hh(e){return[e("x"),e("y")]}function mh({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function vh(e){return void 0===e||1===e}function gh({scale:e,scaleX:t,scaleY:n}){return!vh(e)||!vh(t)||!vh(n)}function yh(e){return gh(e)||bh(e)||e.z||e.rotate||e.rotateX||e.rotateY}function bh(e){return wh(e.x)||wh(e.y)}function wh(e){return e&&"0%"!==e}function xh(e,t,n){return n+t*(e-n)}function Eh(e,t,n,r,o){return void 0!==o&&(e=xh(e,o,r)),xh(e,n,r)+t}function Sh(e,t=0,n=1,r,o){e.min=Eh(e.min,t,n,r,o),e.max=Eh(e.max,t,n,r,o)}function Ph(e,{x:t,y:n}){Sh(e.x,t.translate,t.scale,t.originPoint),Sh(e.y,n.translate,n.scale,n.originPoint)}function Ch(e){return Number.isInteger(e)||e>1.0000000000001||e<.999999999999?e:1}function Th(e,t){e.min=e.min+t,e.max=e.max+t}function Rh(e,t,[n,r,o]){const i=void 0!==t[o]?t[o]:.5,s=uf(e.min,e.max,i);Sh(e,t[n],t[r],s,t.scale)}const Ah=["x","scaleX","originX"],Oh=["y","scaleY","originY"];function Dh(e,t){Rh(e.x,t,Ah),Rh(e.y,t,Oh)}function kh(e,t){return mh(function(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}const _h=new WeakMap;class Lh{constructor(e){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ph(),this.visualElement=e}start(e,{snapToCursor:t=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;this.panSession=new Kp(e,{onSessionStart:e=>{this.stopAnimation(),t&&this.snapToCursor(Hu(e,"page").point)},onStart:(e,t)=>{const{drag:n,dragPropagation:r,onDragStart:o}=this.getProps();if(n&&!r&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=Zu(n),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),hh((e=>{let t=this.getAxisMotionValue(e).get()||0;if(nu.test(t)){const{projection:n}=this.visualElement;if(n&&n.layout){const r=n.layout.layoutBox[e];if(r){t=eh(r)*(parseFloat(t)/100)}}}this.originPoint[e]=t})),o&&id.update((()=>o(e,t)));const{animationState:i}=this.visualElement;i&&i.setActive("whileDrag",!0)},onMove:(e,t)=>{const{dragPropagation:n,dragDirectionLock:r,onDirectionLock:o,onDrag:i}=this.getProps();if(!n&&!this.openGlobalLock)return;const{offset:s}=t;if(r&&null===this.currentDirection)return this.currentDirection=function(e,t=10){let n=null;Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x");return n}(s),void(null!==this.currentDirection&&o&&o(this.currentDirection));this.updateAxis("x",t.point,s),this.updateAxis("y",t.point,s),this.visualElement.render(),i&&i(e,t)},onSessionEnd:(e,t)=>this.stop(e,t)},{transformPagePoint:this.visualElement.getTransformPagePoint()})}stop(e,t){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:r}=t;this.startAnimation(r);const{onDragEnd:o}=this.getProps();o&&id.update((()=>o(e,t)))}cancel(){this.isDragging=!1;const{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){const{drag:r}=this.getProps();if(!n||!Mh(e,r,this.currentDirection))return;const o=this.getAxisMotionValue(e);let i=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(i=function(e,{min:t,max:n},r){return void 0!==t&&e<t?e=r?uf(t,e,r.min):Math.max(e,t):void 0!==n&&e>n&&(e=r?uf(n,e,r.max):Math.min(e,n)),e}(i,this.constraints[e],this.elastic[e])),o.set(i)}resolveConstraints(){const{dragConstraints:e,dragElastic:t}=this.getProps(),{layout:n}=this.visualElement.projection||{},r=this.constraints;e&&fc(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!e||!n)&&function(e,{top:t,left:n,bottom:r,right:o}){return{x:ah(e.x,n,o),y:ah(e.y,t,r)}}(n.layoutBox,e),this.elastic=function(e=ch){return!1===e?e=0:!0===e&&(e=ch),{x:uh(e,"left","right"),y:uh(e,"top","bottom")}}(t),r!==this.constraints&&n&&this.constraints&&!this.hasMutatedConstraints&&hh((e=>{this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){const n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(n.layoutBox[e],this.constraints[e]))}))}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!fc(e))return!1;const n=e.current;Td(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const o=function(e,t,n){const r=kh(e,n),{scroll:o}=t;return o&&(Th(r.x,o.offset.x),Th(r.y,o.offset.y)),r}(n,r.root,this.visualElement.getTransformPagePoint());let i=function(e,t){return{x:lh(e.x,t.x),y:lh(e.y,t.y)}}(r.layout.layoutBox,o);if(t){const e=t(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(i));this.hasMutatedConstraints=!!e,e&&(i=mh(e))}return i}startAnimation(e){const{drag:t,dragMomentum:n,dragElastic:r,dragTransition:o,dragSnapToOrigin:i,onDragTransitionEnd:s}=this.getProps(),a=this.constraints||{},l=hh((s=>{if(!Mh(s,t,this.currentDirection))return;let l=a&&a[s]||{};i&&(l={min:0,max:0});const c=r?200:1e6,u=r?40:1e7,d={type:"inertia",velocity:n?e[s]:0,bounceStiffness:c,bounceDamping:u,timeConstant:750,restDelta:1,restSpeed:10,...o,...l};return this.startAxisValueAnimation(s,d)}));return Promise.all(l).then(s)}startAxisValueAnimation(e,t){const n=this.getAxisMotionValue(e);return n.start(gp(e,n,0,t))}stopAnimation(){hh((e=>this.getAxisMotionValue(e).stop()))}getAxisMotionValue(e){const t="_drag"+e.toUpperCase(),n=this.visualElement.getProps(),r=n[t];return r||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){hh((t=>{const{drag:n}=this.getProps();if(!Mh(t,n,this.currentDirection))return;const{projection:r}=this.visualElement,o=this.getAxisMotionValue(t);if(r&&r.layout){const{min:n,max:i}=r.layout.layoutBox[t];o.set(e[t]-uf(n,i,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!fc(t)||!n||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};hh((e=>{const t=this.getAxisMotionValue(e);if(t){const n=t.get();r[e]=function(e,t){let n=.5;const r=eh(e),o=eh(t);return o>r?n=Rf(t.min,t.max-r,e.min):r>o&&(n=Rf(e.min,e.max-o,t.min)),zc(0,1,n)}({min:n,max:n},this.constraints[e])}}));const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),hh((t=>{if(!Mh(t,e,null))return;const n=this.getAxisMotionValue(t),{min:o,max:i}=this.constraints[t];n.set(uf(o,i,r[t]))}))}addListeners(){if(!this.visualElement.current)return;_h.set(this.visualElement,this);const e=zu(this.visualElement.current,"pointerdown",(e=>{const{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)})),t=()=>{const{dragConstraints:e}=this.getProps();fc(e)&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),t();const o=Bu(window,"resize",(()=>this.scalePositionWithinConstraints())),i=n.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(hh((t=>{const n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))})),this.visualElement.render())}));return()=>{o(),e(),r(),i&&i()}}getProps(){const e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:o=!1,dragElastic:i=ch,dragMomentum:s=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:o,dragElastic:i,dragMomentum:s}}}function Mh(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}const Ih=e=>(t,n)=>{e&&id.update((()=>e(t,n)))};function Vh(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const $h={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!ru.test(e))return e;e=parseFloat(e)}return`${Vh(e,t.target.x)}% ${Vh(e,t.target.y)}%`}},Nh=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;const Fh=4;function jh(e,t,n=1){Td(n<=Fh,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,o]=function(e){const t=Nh.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);return i?i.trim():Hc(o)?jh(o,t,n+1):o}const Bh="_$css",Wh={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=e.includes("var("),i=[];o&&(e=e.replace(Nh,(e=>(i.push(e),Bh))));const s=Ef.parse(e);if(s.length>5)return r;const a=Ef.createTransformer(e),l="number"!=typeof s[0]?1:0,c=n.x.scale*t.x,u=n.y.scale*t.y;s[0+l]/=c,s[1+l]/=u;const d=uf(c,u,.5);"number"==typeof s[2+l]&&(s[2+l]/=d),"number"==typeof s[3+l]&&(s[3+l]/=d);let f=a(s);if(o){let e=0;f=f.replace(Bh,(()=>{const t=i[e];return e++,t}))}return f}};class Hh extends e.Component{componentDidMount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:o}=e;var i;i=zh,Object.assign(Mc,i),o&&(t.group&&t.group.add(o),n&&n.register&&r&&n.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",(()=>{this.safeToRemove()})),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),Pc.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:t,visualElement:n,drag:r,isPresent:o}=this.props,i=n.projection;return i?(i.isPresent=o,r||e.layoutDependency!==t||void 0===t?i.willUpdate():this.safeToRemove(),e.isPresent!==o&&(o?i.promote():i.relegate()||id.postRender((()=>{const e=i.getStack();e&&e.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),!e.currentAnimation&&e.isLead()&&this.safeToRemove())}componentWillUnmount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function Uh(t){const[n,r]=function(){const t=e.useContext(lc);if(null===t)return[!0,null];const{isPresent:n,onExitComplete:r,register:o}=t,i=e.useId();return e.useEffect((()=>o(i)),[]),!n&&r?[!1,()=>r&&r(i)]:[!0]}(),o=e.useContext(Tc);return e.createElement(Hh,{...t,layoutGroup:o,switchLayoutGroup:e.useContext(Rc),isPresent:n,safeToRemove:r})}const zh={borderRadius:{...$h,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:$h,borderTopRightRadius:$h,borderBottomLeftRadius:$h,borderBottomRightRadius:$h,boxShadow:Wh},Yh=["TopLeft","TopRight","BottomLeft","BottomRight"],Kh=Yh.length,Xh=e=>"string"==typeof e?parseFloat(e):e,qh=e=>"number"==typeof e||ru.test(e);function Gh(e,t){return void 0!==e[t]?e[t]:e.borderRadius}const Zh=Qh(0,.5,qd),Jh=Qh(.5,.95,pd);function Qh(e,t,n){return r=>r<e?0:r>t?1:n(Rf(e,t,r))}function em(e,t){e.min=t.min,e.max=t.max}function tm(e,t){em(e.x,t.x),em(e.y,t.y)}function nm(e,t,n,r,o){return e=xh(e-=t,1/n,r),void 0!==o&&(e=xh(e,1/o,r)),e}function rm(e,t,[n,r,o],i,s){!function(e,t=0,n=1,r=.5,o,i=e,s=e){nu.test(t)&&(t=parseFloat(t),t=uf(s.min,s.max,t/100)-s.min);if("number"!=typeof t)return;let a=uf(i.min,i.max,r);e===i&&(a-=t),e.min=nm(e.min,t,n,a,o),e.max=nm(e.max,t,n,a,o)}(e,t[n],t[r],t[o],t.scale,i,s)}const om=["x","scaleX","originX"],im=["y","scaleY","originY"];function sm(e,t,n,r){rm(e.x,t,om,n?n.x:void 0,r?r.x:void 0),rm(e.y,t,im,n?n.y:void 0,r?r.y:void 0)}function am(e){return 0===e.translate&&1===e.scale}function lm(e){return am(e.x)&&am(e.y)}function cm(e,t){return e.x.min===t.x.min&&e.x.max===t.x.max&&e.y.min===t.y.min&&e.y.max===t.y.max}function um(e){return eh(e.x)/eh(e.y)}class dm{constructor(){this.members=[]}add(e){wp(this.members,e),e.scheduleRender()}remove(e){if(xp(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){const t=this.members.findIndex((t=>e===t));if(0===t)return!1;let n;for(let r=t;r>=0;r--){const e=this.members[r];if(!1!==e.isPresent){n=e;break}}return!!n&&(this.promote(n),!0)}promote(e,t){const n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:r}=e.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach((e=>{const{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((e=>{e.instance&&e.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function fm(e,t,n){let r="";const o=e.x.translate/t.x,i=e.y.translate/t.y;if((o||i)&&(r=`translate3d(${o}px, ${i}px, 0) `),1===t.x&&1===t.y||(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:e,rotateX:t,rotateY:o}=n;e&&(r+=`rotate(${e}deg) `),t&&(r+=`rotateX(${t}deg) `),o&&(r+=`rotateY(${o}deg) `)}const s=e.x.scale*t.x,a=e.y.scale*t.y;return 1===s&&1===a||(r+=`scale(${s}, ${a})`),r||"none"}const pm=(e,t)=>e.depth-t.depth;class hm{constructor(){this.children=[],this.isDirty=!1}add(e){wp(this.children,e),this.isDirty=!0}remove(e){xp(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(pm),this.isDirty=!1,this.children.forEach(e)}}const mm=["","X","Y","Z"];let vm=0;const gm={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function ym({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(e,n={},r=(null==t?void 0:t())){this.id=vm++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.potentialNodes=new Map,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{var e;gm.totalNodes=gm.resolvedTargetDeltas=gm.recalculatedProjection=0,this.nodes.forEach(xm),this.nodes.forEach(Rm),this.nodes.forEach(Am),this.nodes.forEach(Em),e=gm,window.MotionDebug&&window.MotionDebug.record(e)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.elementId=e,this.latestValues=n,this.root=r?r.root||r:this,this.path=r?[...r.path,r]:[],this.parent=r,this.depth=r?r.depth+1:0,e&&this.root.registerPotentialNode(e,this);for(let t=0;t<this.path.length;t++)this.path[t].shouldResetTransform=!0;this.root===this&&(this.nodes=new hm)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new Ep),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){const n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}registerPotentialNode(e,t){this.potentialNodes.set(e,t)}mount(t,n=!1){if(this.instance)return;var r;this.isSVG=(r=t)instanceof SVGElement&&"svg"!==r.tagName,this.instance=t;const{layoutId:o,layout:i,visualElement:s}=this.options;if(s&&!s.current&&s.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.elementId&&this.root.potentialNodes.delete(this.elementId),n&&(i||o)&&(this.isLayoutDirty=!0),e){let n;const r=()=>this.root.updateBlockedByResize=!1;e(t,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){const n=performance.now(),r=({timestamp:o})=>{const i=o-n;i>=t&&(sd.read(r),e(i-t))};return id.read(r,!0),()=>sd.read(r)}(r,250),Pc.hasAnimatedSinceResize&&(Pc.hasAnimatedSinceResize=!1,this.nodes.forEach(Tm))}))}o&&this.root.registerSharedNode(o,this),!1!==this.options.animate&&s&&(o||i)&&this.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const o=this.options.transition||s.getDefaultTransition()||Mm,{onLayoutAnimationStart:i,onLayoutAnimationComplete:a}=s.getProps(),l=!this.targetLayout||!cm(this.targetLayout,r)||n,c=!t&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||c||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,c);const t={...vp(o,"layout"),onPlay:i,onComplete:a};(s.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||0!==this.animationProgress||Tm(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,sd.preRender(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Om),this.animationId++)}getTransformTemplate(){const{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let o=0;o<this.path.length;o++){const e=this.path[o];e.shouldResetTransform=!0,e.updateScroll("snapshot"),e.options.layoutRoot&&e.willUpdate(!1)}const{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;const r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}didUpdate(){if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(Pm);this.isUpdating&&(this.isUpdating=!1,this.potentialNodes.size&&(this.potentialNodes.forEach(Im),this.potentialNodes.clear()),this.nodes.forEach(Cm),this.nodes.forEach(bm),this.nodes.forEach(wm),this.clearAllSnapshots(),ad.update(),ad.preRender(),ad.render())}clearAllSnapshots(){this.nodes.forEach(Sm),this.sharedNodes.forEach(Dm)}scheduleUpdateProjection(){id.preRender(this.updateProjection,!1,!0)}scheduleCheckAfterUnmount(){id.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure())}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let n=0;n<this.path.length;n++){this.path[n].updateScroll()}const e=this.layout;this.layout=this.measure(!1),this.layoutCorrected=ph(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=Boolean(this.options.layoutScroll&&this.instance);this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t&&(this.scroll={animationId:this.root.animationId,phase:e,isRoot:r(this.instance),offset:n(this.instance)})}resetTransform(){if(!o)return;const e=this.isLayoutDirty||this.shouldResetTransform,t=this.projectionDelta&&!lm(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,i=r!==this.prevTransformTemplateValue;e&&(t||yh(this.latestValues)||i)&&(o(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){const t=this.measurePageBox();let n=this.removeElementScroll(t);var r;return e&&(n=this.removeTransform(n)),Vm((r=n).x),Vm(r.y),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:e}=this.options;if(!e)return ph();const t=e.measureViewportBox(),{scroll:n}=this.root;return n&&(Th(t.x,n.offset.x),Th(t.y,n.offset.y)),t}removeElementScroll(e){const t=ph();tm(t,e);for(let n=0;n<this.path.length;n++){const r=this.path[n],{scroll:o,options:i}=r;if(r!==this.root&&o&&i.layoutScroll){if(o.isRoot){tm(t,e);const{scroll:n}=this.root;n&&(Th(t.x,-n.offset.x),Th(t.y,-n.offset.y))}Th(t.x,o.offset.x),Th(t.y,o.offset.y)}}return t}applyTransform(e,t=!1){const n=ph();tm(n,e);for(let r=0;r<this.path.length;r++){const e=this.path[r];!t&&e.options.layoutScroll&&e.scroll&&e!==e.root&&Dh(n,{x:-e.scroll.offset.x,y:-e.scroll.offset.y}),yh(e.latestValues)&&Dh(n,e.latestValues)}return yh(this.latestValues)&&Dh(n,this.latestValues),n}removeTransform(e){const t=ph();tm(t,e);for(let n=0;n<this.path.length;n++){const e=this.path[n];if(!e.instance)continue;if(!yh(e.latestValues))continue;gh(e.latestValues)&&e.updateSnapshot();const r=ph();tm(r,e.measurePageBox()),sm(t,e.latestValues,e.snapshot?e.snapshot.layoutBox:void 0,r)}return yh(this.latestValues)&&sm(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}resolveTargetDelta(e=!1){var t;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const r=Boolean(this.resumingFrom)||this!==n;if(!(e||r&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget))return;const{layout:o,layoutId:i}=this.options;if(this.layout&&(o||i)){if(this.resolvedRelativeTargetAt=ed.timestamp,!this.targetDelta&&!this.relativeTarget){const e=this.getClosestProjectingParent();e&&e.layout?(this.relativeParent=e,this.relativeTarget=ph(),this.relativeTargetOrigin=ph(),sh(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),tm(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){var s,a,l;if(this.target||(this.target=ph(),this.targetWithTransforms=ph()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.relativeParent.resolvedRelativeTargetAt!==ed.timestamp&&this.relativeParent.resolveTargetDelta(!0),s=this.target,a=this.relativeTarget,l=this.relativeParent.target,oh(s.x,a.x,l.x),oh(s.y,a.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):tm(this.target,this.layout.layoutBox),Ph(this.target,this.targetDelta)):tm(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const e=this.getClosestProjectingParent();e&&Boolean(e.resumingFrom)===Boolean(this.resumingFrom)&&!e.options.layoutScroll&&e.target?(this.relativeParent=e,this.relativeTarget=ph(),this.relativeTargetOrigin=ph(),sh(this.relativeTargetOrigin,this.target,e.target),tm(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}gm.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(this.parent&&!gh(this.parent.latestValues)&&!bh(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;const t=this.getLead(),n=Boolean(this.resumingFrom)||this!==t;let r=!0;if((this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===ed.timestamp&&(r=!1),r)return;const{layout:o,layoutId:i}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!o&&!i)return;tm(this.layoutCorrected,this.layout.layoutBox),function(e,t,n,r=!1){const o=n.length;if(!o)return;let i,s;t.x=t.y=1;for(let a=0;a<o;a++){i=n[a],s=i.projectionDelta;const o=i.instance;o&&o.style&&"contents"===o.style.display||(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&Dh(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Ph(e,s)),r&&yh(i.latestValues)&&Dh(e,i.latestValues))}t.x=Ch(t.x),t.y=Ch(t.y)}(this.layoutCorrected,this.treeScale,this.path,n);const{target:s}=t;if(!s)return;this.projectionDelta||(this.projectionDelta=fh(),this.projectionDeltaWithTransform=fh());const a=this.treeScale.x,l=this.treeScale.y,c=this.projectionTransform;rh(this.projectionDelta,this.layoutCorrected,s,this.latestValues),this.projectionTransform=fm(this.projectionDelta,this.treeScale),this.projectionTransform===c&&this.treeScale.x===a&&this.treeScale.y===l||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",s)),gm.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){if(this.options.scheduleRender&&this.options.scheduleRender(),e){const e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}setAnimationOrigin(e,t=!1){const n=this.snapshot,r=n?n.latestValues:{},o={...this.latestValues},i=fh();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;const s=ph(),a=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),c=!l||l.members.length<=1,u=Boolean(a&&!c&&!0===this.options.crossfade&&!this.path.some(Lm));let d;this.animationProgress=0,this.mixTargetDelta=t=>{const n=t/1e3;var l,f,p,h;km(i.x,e.x,n),km(i.y,e.y,n),this.setTargetDelta(i),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(sh(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),l=this.relativeTarget,f=this.relativeTargetOrigin,p=s,h=n,_m(l.x,f.x,p.x,h),_m(l.y,f.y,p.y,h),d&&cm(this.relativeTarget,d)&&(this.isProjectionDirty=!1),d||(d=ph()),tm(d,this.relativeTarget)),a&&(this.animationValues=o,function(e,t,n,r,o,i){o?(e.opacity=uf(0,void 0!==n.opacity?n.opacity:1,Zh(r)),e.opacityExit=uf(void 0!==t.opacity?t.opacity:1,0,Jh(r))):i&&(e.opacity=uf(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let s=0;s<Kh;s++){const o=`border${Yh[s]}Radius`;let i=Gh(t,o),a=Gh(n,o);void 0===i&&void 0===a||(i||(i=0),a||(a=0),0===i||0===a||qh(i)===qh(a)?(e[o]=Math.max(uf(Xh(i),Xh(a),r),0),(nu.test(a)||nu.test(i))&&(e[o]+="%")):e[o]=a)}(t.rotate||n.rotate)&&(e.rotate=uf(t.rotate||0,n.rotate||0,r))}(o,r,this.latestValues,n,u,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(sd.update(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=id.update((()=>{Pc.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){const r=Nc(e)?e:Tp(e);return r.start(gp("",r,t,n)),r.animation}(0,1e3,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0}))}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const e=this.getLead();let{targetWithTransforms:t,target:n,layout:r,latestValues:o}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&$m(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||ph();const t=eh(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;const r=eh(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}tm(t,n),Dh(t,o),rh(this.projectionDeltaWithTransform,this.layoutCorrected,t,o)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new dm);this.sharedNodes.get(e).add(t);const n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){const e=this.getStack();return!e||e.lead===this}getLead(){var e;const{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;const{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){const{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){const r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){const e=this.getStack();return!!e&&e.relegate(this)}resetRotation(){const{visualElement:e}=this.options;if(!e)return;let t=!1;const{latestValues:n}=e;if((n.rotate||n.rotateX||n.rotateY||n.rotateZ)&&(t=!0),!t)return;const r={};for(let o=0;o<mm.length;o++){const t="rotate"+mm[o];n[t]&&(r[t]=n[t],e.setStaticValue(t,0))}e.render();for(const o in r)e.setStaticValue(o,r[o]);e.scheduleRender()}getProjectionStyles(e={}){var t,n;const r={};if(!this.instance||this.isSVG)return r;if(!this.isVisible)return{visibility:"hidden"};r.visibility="";const o=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=Vu(e.pointerEvents)||"",r.transform=o?o(this.latestValues,""):"none",r;const i=this.getLead();if(!this.projectionDelta||!this.layout||!i.target){const t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=Vu(e.pointerEvents)||""),this.hasProjected&&!yh(this.latestValues)&&(t.transform=o?o({},""):"none",this.hasProjected=!1),t}const s=i.animationValues||i.latestValues;this.applyTransformsToTarget(),r.transform=fm(this.projectionDeltaWithTransform,this.treeScale,s),o&&(r.transform=o(s,r.transform));const{x:a,y:l}=this.projectionDelta;r.transformOrigin=`${100*a.origin}% ${100*l.origin}% 0`,i.animationValues?r.opacity=i===this?null!==(n=null!==(t=s.opacity)&&void 0!==t?t:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:s.opacityExit:r.opacity=i===this?void 0!==s.opacity?s.opacity:"":void 0!==s.opacityExit?s.opacityExit:0;for(const c in Mc){if(void 0===s[c])continue;const{correct:e,applyTo:t}=Mc[c],n="none"===r.transform?s[c]:e(s[c],i);if(t){const e=t.length;for(let o=0;o<e;o++)r[t[o]]=n}else r[c]=n}return this.options.layoutId&&(r.pointerEvents=i===this?Vu(e.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((e=>{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()})),this.root.nodes.forEach(Pm),this.root.sharedNodes.clear()}}}function bm(e){e.updateLayout()}function wm(e){var t;const n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:t,measuredBox:r}=e.layout,{animationType:o}=e.options,i=n.source!==e.layout.source;"size"===o?hh((e=>{const r=i?n.measuredBox[e]:n.layoutBox[e],o=eh(r);r.min=t[e].min,r.max=r.min+o})):$m(o,n.layoutBox,t)&&hh((r=>{const o=i?n.measuredBox[r]:n.layoutBox[r],s=eh(t[r]);o.max=o.min+s,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+s)}));const s=fh();rh(s,t,n.layoutBox);const a=fh();i?rh(a,e.applyTransform(r,!0),n.measuredBox):rh(a,t,n.layoutBox);const l=!lm(s);let c=!1;if(!e.resumeFrom){const r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){const{snapshot:o,layout:i}=r;if(o&&i){const s=ph();sh(s,n.layoutBox,o.layoutBox);const a=ph();sh(a,t,i.layoutBox),cm(s,a)||(c=!0),r.options.layoutRoot&&(e.relativeTarget=a,e.relativeTargetOrigin=s,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeTargetChanged:c})}else if(e.isLead()){const{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function xm(e){gm.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=Boolean(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Em(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Sm(e){e.clearSnapshot()}function Pm(e){e.clearMeasurements()}function Cm(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Tm(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0}function Rm(e){e.resolveTargetDelta()}function Am(e){e.calcProjection()}function Om(e){e.resetRotation()}function Dm(e){e.removeLeadSnapshot()}function km(e,t,n){e.translate=uf(t.translate,0,n),e.scale=uf(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function _m(e,t,n,r){e.min=uf(t.min,n.min,r),e.max=uf(t.max,n.max,r)}function Lm(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}const Mm={duration:.45,ease:[.4,0,.1,1]};function Im(e,t){let n=e.root;for(let o=e.path.length-1;o>=0;o--)if(Boolean(e.path[o].instance)){n=e.path[o];break}const r=(n&&n!==e.root?n.instance:document).querySelector(`[data-projection-id="${t}"]`);r&&e.mount(r,!0)}function Vm(e){e.min=Math.round(e.min),e.max=Math.round(e.max)}function $m(e,t,n){return"position"===e||"preserve-aspect"===e&&!th(um(t),um(n),.2)}const Nm=ym({attachResizeListener:(e,t)=>Bu(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Fm={current:void 0},jm=ym({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Fm.current){const e=new Nm(0,{});e.mount(window),e.setOptions({layoutScroll:!0}),Fm.current=e}return Fm.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>Boolean("fixed"===window.getComputedStyle(e).position)}),Bm={pan:{Feature:class extends Qu{constructor(){super(...arguments),this.removePointerDownListener=pd}onPointerDown(e){this.session=new Kp(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint()})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Ih(e),onStart:Ih(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&id.update((()=>r(e,t)))}}}mount(){this.removePointerDownListener=zu(this.node.current,"pointerdown",(e=>this.onPointerDown(e)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends Qu{constructor(e){super(e),this.removeGroupControls=pd,this.removeListeners=pd,this.controls=new Lh(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||pd}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:jm,MeasureLayout:Uh}},Wm=new Set(["width","height","top","left","right","bottom","x","y"]),Hm=e=>Wm.has(e),Um=e=>e===Yc||e===ru,zm=(e,t)=>parseFloat(e.split(", ")[t]),Ym=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/);if(o)return zm(o[1],t);{const t=r.match(/^matrix\((.+)\)$/);return t?zm(t[1],e):0}},Km=new Set(["x","y","z"]),Xm=Ic.filter((e=>!Km.has(e)));const qm={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:Ym(4,13),y:Ym(5,14)},Gm=(e,t,n={},r={})=>{t={...t},r={...r};const o=Object.keys(t).filter(Hm);let i=[],s=!1;const a=[];if(o.forEach((o=>{const l=e.getValue(o);if(!e.hasValue(o))return;let c=n[o],u=Op(c);const d=t[o];let f;if(Lu(d)){const e=d.length,t=null===d[0]?1:0;c=d[t],u=Op(c);for(let n=t;n<e;n++)f?Td(Op(d[n])===f,"All keyframes must be of the same type"):(f=Op(d[n]),Td(f===u||Um(u)&&Um(f),"Keyframes must be of the same dimension as the current value"))}else f=Op(d);if(u!==f)if(Um(u)&&Um(f)){const e=l.get();"string"==typeof e&&l.set(parseFloat(e)),"string"==typeof d?t[o]=parseFloat(d):Array.isArray(d)&&f===ru&&(t[o]=d.map(parseFloat))}else(null==u?void 0:u.transform)&&(null==f?void 0:f.transform)&&(0===c||0===d)?0===c?l.set(f.transform(c)):t[o]=u.transform(d):(s||(i=function(e){const t=[];return Xm.forEach((n=>{const r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),t.length&&e.render(),t}(e),s=!0),a.push(o),r[o]=void 0!==r[o]?r[o]:t[o],l.jump(d))})),a.length){const n=a.indexOf("height")>=0?window.pageYOffset:null,o=((e,t,n)=>{const r=t.measureViewportBox(),o=t.current,i=getComputedStyle(o),{display:s}=i,a={};"none"===s&&t.setStaticValue("display",e.display||"block"),n.forEach((e=>{a[e]=qm[e](r,i)})),t.render();const l=t.measureViewportBox();return n.forEach((n=>{const r=t.getValue(n);r&&r.jump(a[n]),e[n]=qm[n](l,i)})),e})(t,e,a);return i.length&&i.forEach((([t,n])=>{e.getValue(t).set(n)})),e.render(),cc&&null!==n&&window.scrollTo({top:n}),{target:o,transitionEnd:r}}return{target:t,transitionEnd:r}};function Zm(e,t,n,r){return(e=>Object.keys(e).some(Hm))(t)?Gm(e,t,n,r):{target:t,transitionEnd:r}}const Jm=(e,t,n,r)=>{const o=function(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach((e=>{const t=e.get();if(!Hc(t))return;const n=jh(t,r);n&&e.set(n)}));for(const o in t){const e=t[o];if(!Hc(e))continue;const i=jh(e,r);i&&(t[o]=i,n||(n={}),void 0===n[o]&&(n[o]=e))}return{target:t,transitionEnd:n}}(e,t,r);return Zm(e,t=o.target,n,r=o.transitionEnd)},Qm={current:null},ev={current:!1};const tv=new WeakMap,nv=Object.keys(Ec),rv=nv.length,ov=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],iv=vc.length;class sv{constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,visualState:o},i={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.scheduleRender=()=>id.render(this.render,!1,!0);const{latestValues:s,renderState:a}=o;this.latestValues=s,this.baseTarget={...s},this.initialValues=t.initial?{...s}:{},this.renderState=a,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.options=i,this.isControllingVariants=gc(t),this.isVariantNode=yc(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(e&&e.current);const{willChange:l,...c}=this.scrapeMotionValuesFromProps(t,{});for(const u in c){const e=c[u];void 0!==s[u]&&Nc(e)&&(e.set(s[u],!1),yp(l)&&l.add(u))}}scrapeMotionValuesFromProps(e,t){return{}}mount(e){this.current=e,tv.set(e,this),this.projection&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((e,t)=>this.bindToMotionValue(t,e))),ev.current||function(){if(ev.current=!0,cc)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Qm.current=e.matches;e.addListener(t),t()}else Qm.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||Qm.current),"production"!==process.env.NODE_ENV&&Pp(!0!==this.shouldReduceMotion,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){tv.delete(this.current),this.projection&&this.projection.unmount(),sd.update(this.notifyUpdate),sd.render(this.render),this.valueSubscriptions.forEach((e=>e())),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features)this.features[e].unmount();this.current=null}bindToMotionValue(e,t){const n=Vc.has(e),r=t.on("change",(t=>{this.latestValues[e]=t,this.props.onUpdate&&id.update(this.notifyUpdate,!1,!0),n&&this.projection&&(this.projection.isTransformDirty=!0)})),o=t.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(e,(()=>{r(),o()}))}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}loadFeatures({children:e,...t},n,r,o,i){let s,a;if("production"!==process.env.NODE_ENV&&r&&n){const e="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";t.ignoreStrict?Cd(!1,e):Td(!1,e)}for(let l=0;l<rv;l++){const e=nv[l],{isEnabled:n,Feature:r,ProjectionNode:o,MeasureLayout:i}=Ec[e];o&&(s=o),n(t)&&(!this.features[e]&&r&&(this.features[e]=new r(this)),i&&(a=i))}if(!this.projection&&s){this.projection=new s(o,this.latestValues,this.parent&&this.parent.projection);const{layoutId:e,layout:n,drag:r,dragConstraints:a,layoutScroll:l,layoutRoot:c}=t;this.projection.setOptions({layoutId:e,layout:n,alwaysMeasureLayout:Boolean(r)||a&&fc(a),visualElement:this,scheduleRender:()=>this.scheduleRender(),animationType:"string"==typeof n?n:"both",initialPromotionConfig:i,layoutScroll:l,layoutRoot:c})}return a}updateFeatures(){for(const e in this.features){const t=this.features[e];t.isMounted?t.update(this.props,this.prevProps):(t.mount(),t.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ph()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}makeTargetAnimatable(e,t=!0){return this.makeTargetAnimatableFromInstance(e,this.props,t)}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let n=0;n<ov.length;n++){const t=ov[n];this.propEventSubscriptions[t]&&(this.propEventSubscriptions[t](),delete this.propEventSubscriptions[t]);const r=e["on"+t];r&&(this.propEventSubscriptions[t]=this.on(t,r))}this.prevMotionValues=function(e,t,n){const{willChange:r}=t;for(const o in t){const i=t[o],s=n[o];if(Nc(i))e.addValue(o,i),yp(r)&&r.add(o),"development"===process.env.NODE_ENV&&Pp("10.10.0"===i.version,`Attempting to mix Framer Motion versions ${i.version} with 10.10.0 may not work as expected.`);else if(Nc(s))e.addValue(o,Tp(i,{owner:e})),yp(r)&&r.remove(o);else if(s!==i)if(e.hasValue(o)){const t=e.getValue(o);!t.hasAnimated&&t.set(i)}else{const t=e.getStaticValue(o);e.addValue(o,Tp(void 0!==t?t:i,{owner:e}))}}for(const o in n)void 0===t[o]&&e.removeValue(o);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(e=!1){if(e)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const e=this.parent&&this.parent.getVariantContext()||{};return void 0!==this.props.initial&&(e.initial=this.props.initial),e}const t={};for(let n=0;n<iv;n++){const e=vc[n],r=this.props[e];(pc(r)||!1===r)&&(t[e]=r)}return t}addVariantChild(e){const t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){t!==this.values.get(e)&&(this.removeValue(e),this.bindToMotionValue(e,t)),this.values.set(e,t),this.latestValues[e]=t.get()}removeValue(e){this.values.delete(e);const t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=Tp(t,{owner:this}),this.addValue(e,n)),n}readValue(e){return void 0===this.latestValues[e]&&this.current?this.readValueFromInstance(this.current,e,this.options):this.latestValues[e]}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;const{initial:n}=this.props,r="string"==typeof n||"object"==typeof n?null===(t=_u(this.props,n))||void 0===t?void 0:t[e]:void 0;if(n&&void 0!==r)return r;const o=this.getBaseTargetFromProps(this.props,e);return void 0===o||Nc(o)?void 0!==this.initialValues[e]&&void 0===r?void 0:this.baseTarget[e]:o}on(e,t){return this.events[e]||(this.events[e]=new Ep),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class av extends sv{sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}makeTargetAnimatableFromInstance({transition:e,transitionEnd:t,...n},{transformValues:r},o){let i=function(e,t,n){const r={};for(const o in e){const e=Lp(o,t);if(void 0!==e)r[o]=e;else{const e=n.getValue(o);e&&(r[o]=e.get())}}return r}(n,e||{},this);if(r&&(t&&(t=r(t)),n&&(n=r(n)),i&&(i=r(i))),o){!function(e,t,n){var r,o;const i=Object.keys(t).filter((t=>!e.hasValue(t))),s=i.length;if(s)for(let a=0;a<s;a++){const s=i[a],l=t[s];let c=null;Array.isArray(l)&&(c=l[0]),null===c&&(c=null!==(o=null!==(r=n[s])&&void 0!==r?r:e.readValue(s))&&void 0!==o?o:t[s]),null!=c&&("string"==typeof c&&(/^\-?\d*\.?\d+$/.test(c)||bp(c))?c=parseFloat(c):!kp(c)&&Ef.test(l)&&(c=pp(s,l)),e.addValue(s,Tp(c,{owner:e})),void 0===n[s]&&(n[s]=c),null!==c&&e.setBaseTarget(s,c))}}(this,n,i);const e=Jm(this,n,i,t);t=e.transitionEnd,n=e.target}return{transition:e,transitionEnd:t,...n}}}class lv extends av{readValueFromInstance(e,t){if(Vc.has(t)){const e=fp(t);return e&&e.default||0}{const r=(n=e,window.getComputedStyle(n)),o=(Wc(t)?r.getPropertyValue(t):r[t])||0;return"string"==typeof o?o.trim():o}var n}measureInstanceViewportBox(e,{transformPagePoint:t}){return kh(e,t)}build(e,t,n,r){cu(e,t,n,r.transformTemplate)}scrapeMotionValuesFromProps(e,t){return Du(e,t)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;Nc(e)&&(this.childSubscription=e.on("change",(e=>{this.current&&(this.current.textContent=`${e}`)})))}renderInstance(e,t,n,r){Ru(e,t,n,r)}}class cv extends av{constructor(){super(...arguments),this.isSVGTag=!1}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(Vc.has(t)){const e=fp(t);return e&&e.default||0}return t=Au.has(t)?t:Tu(t),e.getAttribute(t)}measureInstanceViewportBox(){return ph()}scrapeMotionValuesFromProps(e,t){return ku(e,t)}build(e,t,n,r){xu(e,t,n,this.isSVGTag,r.transformTemplate)}renderInstance(e,t,n,r){Ou(e,t,0,r)}mount(e){this.isSVGTag=Su(e.tagName),super.mount(e)}}const uv=(e,t)=>Lc(e)?new cv(t,{enableHardwareAcceleration:!1}):new lv(t,{enableHardwareAcceleration:!0}),dv={...zp,...xd,...Bm,...{layout:{ProjectionNode:jm,MeasureLayout:Uh}}},fv=kc(((e,t)=>function(e,{forwardMotionProps:t=!1},n,r){return{...Lc(e)?Fu:ju,preloadedFeatures:n,useRender:Cu(t),createVisualElement:r,Component:e}}(e,t,dv,uv)));var pv,hv={exports:{}},mv={exports:{}},vv={};var gv,yv,bv,wv,xv,Ev,Sv,Pv,Cv,Tv,Rv,Av,Ov,Dv,kv={};function _v(){return yv||(yv=1,"production"===process.env.NODE_ENV?mv.exports=function(){if(pv)return vv;pv=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,g=e?Symbol.for("react.responder"):60118,y=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var f=e.$$typeof;switch(f){case t:switch(e=e.type){case l:case c:case r:case i:case o:case d:return e;default:switch(e=e&&e.$$typeof){case a:case u:case h:case p:case s:return e;default:return f}}case n:return f}}}function w(e){return b(e)===c}return vv.AsyncMode=l,vv.ConcurrentMode=c,vv.ContextConsumer=a,vv.ContextProvider=s,vv.Element=t,vv.ForwardRef=u,vv.Fragment=r,vv.Lazy=h,vv.Memo=p,vv.Portal=n,vv.Profiler=i,vv.StrictMode=o,vv.Suspense=d,vv.isAsyncMode=function(e){return w(e)||b(e)===l},vv.isConcurrentMode=w,vv.isContextConsumer=function(e){return b(e)===a},vv.isContextProvider=function(e){return b(e)===s},vv.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},vv.isForwardRef=function(e){return b(e)===u},vv.isFragment=function(e){return b(e)===r},vv.isLazy=function(e){return b(e)===h},vv.isMemo=function(e){return b(e)===p},vv.isPortal=function(e){return b(e)===n},vv.isProfiler=function(e){return b(e)===i},vv.isStrictMode=function(e){return b(e)===o},vv.isSuspense=function(e){return b(e)===d},vv.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===c||e===i||e===o||e===d||e===f||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===p||e.$$typeof===s||e.$$typeof===a||e.$$typeof===u||e.$$typeof===v||e.$$typeof===g||e.$$typeof===y||e.$$typeof===m)},vv.typeOf=b,vv}():mv.exports=(gv||(gv=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,g=e?Symbol.for("react.responder"):60118,y=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var f=e.$$typeof;switch(f){case t:var m=e.type;switch(m){case l:case c:case r:case i:case o:case d:return m;default:var v=m&&m.$$typeof;switch(v){case a:case u:case h:case p:case s:return v;default:return f}}case n:return f}}}var w=l,x=c,E=a,S=s,P=t,C=u,T=r,R=h,A=p,O=n,D=i,k=o,_=d,L=!1;function M(e){return b(e)===c}kv.AsyncMode=w,kv.ConcurrentMode=x,kv.ContextConsumer=E,kv.ContextProvider=S,kv.Element=P,kv.ForwardRef=C,kv.Fragment=T,kv.Lazy=R,kv.Memo=A,kv.Portal=O,kv.Profiler=D,kv.StrictMode=k,kv.Suspense=_,kv.isAsyncMode=function(e){return L||(L=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),M(e)||b(e)===l},kv.isConcurrentMode=M,kv.isContextConsumer=function(e){return b(e)===a},kv.isContextProvider=function(e){return b(e)===s},kv.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},kv.isForwardRef=function(e){return b(e)===u},kv.isFragment=function(e){return b(e)===r},kv.isLazy=function(e){return b(e)===h},kv.isMemo=function(e){return b(e)===p},kv.isPortal=function(e){return b(e)===n},kv.isProfiler=function(e){return b(e)===i},kv.isStrictMode=function(e){return b(e)===o},kv.isSuspense=function(e){return b(e)===d},kv.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===c||e===i||e===o||e===d||e===f||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===p||e.$$typeof===s||e.$$typeof===a||e.$$typeof===u||e.$$typeof===v||e.$$typeof===g||e.$$typeof===y||e.$$typeof===m)},kv.typeOf=b}()),kv)),mv.exports}function Lv(){if(wv)return bv;wv=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return bv=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(ty){return!1}}()?Object.assign:function(r,o){for(var i,s,a=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(r),l=1;l<arguments.length;l++){for(var c in i=Object(arguments[l]))t.call(i,c)&&(a[c]=i[c]);if(e){s=e(i);for(var u=0;u<s.length;u++)n.call(i,s[u])&&(a[s[u]]=i[s[u]])}}return a},bv}function Mv(){if(Ev)return xv;Ev=1;return xv="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function Iv(){return Pv?Sv:(Pv=1,Sv=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var Vv=_v();hv.exports=function(){if(Av)return Rv;Av=1;var e=_v(),t=Lv(),n=Mv(),r=Iv(),o=function(){if(Tv)return Cv;Tv=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=Mv(),n={},r=Iv();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(n){}}}function o(o,i,s,a,l){if("production"!==process.env.NODE_ENV)for(var c in o)if(r(o,c)){var u;try{if("function"!=typeof o[c]){var d=Error((a||"React class")+": "+s+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=o[c](i,c,a,s,null,t)}catch(p){u=p}if(!u||u instanceof Error||e((a||"React class")+": type specification of "+s+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in n)){n[u.message]=!0;var f=l?l():"";e("Failed "+s+" type: "+u.message+(null!=f?f:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},Cv=o}(),i=function(){};function s(){return null}return"production"!==process.env.NODE_ENV&&(i=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(n){}}),Rv=function(a,l){var c="function"==typeof Symbol&&Symbol.iterator,u="@@iterator",d="<<anonymous>>",f={array:v("array"),bigint:v("bigint"),bool:v("boolean"),func:v("function"),number:v("number"),object:v("object"),string:v("string"),symbol:v("symbol"),any:m(s),arrayOf:function(e){return m((function(t,r,o,i,s){if("function"!=typeof e)return new h("Property `"+s+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var a=t[r];if(!Array.isArray(a))return new h("Invalid "+i+" `"+s+"` of type `"+b(a)+"` supplied to `"+o+"`, expected an array.");for(var l=0;l<a.length;l++){var c=e(a,l,o,i,s+"["+l+"]",n);if(c instanceof Error)return c}return null}))},element:m((function(e,t,n,r,o){var i=e[t];return a(i)?null:new h("Invalid "+r+" `"+o+"` of type `"+b(i)+"` supplied to `"+n+"`, expected a single ReactElement.")})),elementType:m((function(t,n,r,o,i){var s=t[n];return e.isValidElementType(s)?null:new h("Invalid "+o+" `"+i+"` of type `"+b(s)+"` supplied to `"+r+"`, expected a single ReactElement type.")})),instanceOf:function(e){return m((function(t,n,r,o,i){if(!(t[n]instanceof e)){var s=e.name||d;return new h("Invalid "+o+" `"+i+"` of type `"+((a=t[n]).constructor&&a.constructor.name?a.constructor.name:d)+"` supplied to `"+r+"`, expected instance of `"+s+"`.")}var a;return null}))},node:m((function(e,t,n,r,o){return y(e[t])?null:new h("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return m((function(t,o,i,s,a){if("function"!=typeof e)return new h("Property `"+a+"` of component `"+i+"` has invalid PropType notation inside objectOf.");var l=t[o],c=b(l);if("object"!==c)return new h("Invalid "+s+" `"+a+"` of type `"+c+"` supplied to `"+i+"`, expected an object.");for(var u in l)if(r(l,u)){var d=e(l,u,i,s,a+"."+u,n);if(d instanceof Error)return d}return null}))},oneOf:function(e){return Array.isArray(e)?m((function(t,n,r,o,i){for(var s=t[n],a=0;a<e.length;a++)if(p(s,e[a]))return null;var l=JSON.stringify(e,(function(e,t){return"symbol"===w(t)?String(t):t}));return new h("Invalid "+o+" `"+i+"` of value `"+String(s)+"` supplied to `"+r+"`, expected one of "+l+".")})):("production"!==process.env.NODE_ENV&&i(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),s)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&i("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+x(o)+" at index "+t+"."),s}return m((function(t,o,i,s,a){for(var l=[],c=0;c<e.length;c++){var u=(0,e[c])(t,o,i,s,a,n);if(null==u)return null;u.data&&r(u.data,"expectedType")&&l.push(u.data.expectedType)}return new h("Invalid "+s+" `"+a+"` supplied to `"+i+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")}))},shape:function(e){return m((function(t,r,o,i,s){var a=t[r],l=b(a);if("object"!==l)return new h("Invalid "+i+" `"+s+"` of type `"+l+"` supplied to `"+o+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return g(o,i,s,c,w(u));var d=u(a,c,o,i,s+"."+c,n);if(d)return d}return null}))},exact:function(e){return m((function(o,i,s,a,l){var c=o[i],u=b(c);if("object"!==u)return new h("Invalid "+a+" `"+l+"` of type `"+u+"` supplied to `"+s+"`, expected `object`.");var d=t({},o[i],e);for(var f in d){var p=e[f];if(r(e,f)&&"function"!=typeof p)return g(s,a,l,f,w(p));if(!p)return new h("Invalid "+a+" `"+l+"` key `"+f+"` supplied to `"+s+"`.\nBad object: "+JSON.stringify(o[i],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var m=p(c,f,s,a,l+"."+f,n);if(m)return m}return null}))}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function h(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function m(e){if("production"!==process.env.NODE_ENV)var t={},r=0;function o(o,s,a,c,u,f,p){if(c=c||d,f=f||a,p!==n){if(l){var m=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw m.name="Invariant Violation",m}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var v=c+":"+a;!t[v]&&r<3&&(i("You are manually calling a React.PropTypes validation function for the `"+f+"` prop on `"+c+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[v]=!0,r++)}}return null==s[a]?o?null===s[a]?new h("The "+u+" `"+f+"` is marked as required in `"+c+"`, but its value is `null`."):new h("The "+u+" `"+f+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(s,a,c,u,f)}var s=o.bind(null,!1);return s.isRequired=o.bind(null,!0),s}function v(e){return m((function(t,n,r,o,i,s){var a=t[n];return b(a)!==e?new h("Invalid "+o+" `"+i+"` of type `"+w(a)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null}))}function g(e,t,n,r,o){return new h((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function y(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(y);if(null===e||a(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e[u]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!y(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!y(o[1]))return!1}return!0;default:return!1}}function b(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function w(e){if(null==e)return""+e;var t=b(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function x(e){var t=w(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return h.prototype=Error.prototype,f.checkPropTypes=o,f.resetWarningCache=o.resetWarningCache,f.PropTypes=f,f},Rv}()(Vv.isElement,!0)}else hv.exports=function(){if(Dv)return Ov;Dv=1;var e=Mv();function t(){}function n(){}return n.resetWarningCache=t,Ov=function(){function r(t,n,r,o,i,s){if(s!==e){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function o(){return r}r.isRequired=r;var i={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return i.PropTypes=i,i}}()();const $v=i(hv.exports);function Nv(){return Nv=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Nv.apply(this,arguments)}function Fv(e,t){return(Fv=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var jv=function(t){var n,r;function o(){return t.apply(this,arguments)||this}r=t,(n=o).prototype=Object.create(r.prototype),n.prototype.constructor=n,Fv(n,r);var i=o.prototype;return i.getColumns=function(){var t=this.props,n=t.children,r=t.columnsCount,o=Array.from({length:r},(function(){return[]}));return e.Children.forEach(n,(function(t,n){t&&e.isValidElement(t)&&o[n%r].push(t)})),o},i.renderColumns=function(){var t=this.props.gutter;return this.getColumns().map((function(n,r){return e.createElement("div",{key:r,style:{display:"flex",flexDirection:"column",justifyContent:"flex-start",alignContent:"stretch",flex:1,width:0,gap:t}},n.map((function(e){return e})))}))},i.render=function(){var t=this.props,n=t.gutter,r=t.className,o=t.style;return e.createElement("div",{style:Nv({display:"flex",flexDirection:"row",justifyContent:"center",alignContent:"stretch",boxSizing:"border-box",width:"100%",gap:n},o),className:r},this.renderColumns())},o}(e.Component);jv.propTypes="production"!==process.env.NODE_ENV?{children:$v.oneOfType([$v.arrayOf($v.node),$v.node]).isRequired,columnsCount:$v.number,gutter:$v.string,className:$v.string,style:$v.object}:{},jv.defaultProps={columnsCount:3,gutter:"0",className:null,style:{}};var Bv="undefined"!=typeof window?e.useLayoutEffect:e.useEffect,Wv=function(){var t=function(){var t=e.useState(!1),n=t[0],r=t[1];return Bv((function(){r(!0)}),[]),n}(),n=e.useState(0),r=n[0],o=n[1],i=e.useCallback((function(){t&&o(window.innerWidth)}),[t]);return Bv((function(){if(t)return window.addEventListener("resize",i),i(),function(){return window.removeEventListener("resize",i)}}),[t,i]),r},Hv=function(t){var n=t.columnsCountBreakPoints,r=void 0===n?{350:1,750:2,900:3}:n,o=t.children,i=t.className,s=void 0===i?null:i,a=t.style,l=void 0===a?null:a,c=Wv(),u=e.useMemo((function(){var e=Object.keys(r).sort((function(e,t){return e-t})),t=e.length>0?r[e[0]]:1;return e.forEach((function(e){e<c&&(t=r[e])})),t}),[c,r]);return e.createElement("div",{className:s,style:l},e.Children.map(o,(function(t,n){return e.cloneElement(t,{key:n,columnsCount:u})})))};Hv.propTypes="production"!==process.env.NODE_ENV?{children:$v.oneOfType([$v.arrayOf($v.node),$v.node]).isRequired,columnsCountBreakPoints:$v.object,className:$v.string,style:$v.object}:{};const[Uv,zv]=Jo("Tooltip",[ja]),Yv=ja(),Kv=700,Xv="tooltip.open",[qv,Gv]=Uv("TooltipProvider"),Zv="Tooltip",[Jv,Qv]=Uv(Zv),eg="TooltipTrigger",tg=e.forwardRef(((t,n)=>{const{__scopeTooltip:r,...o}=t,i=Qv(eg,r),s=Gv(eg,r),a=Yv(r),l=Zo(n,e.useRef(null),i.onTriggerChange),c=e.useRef(!1),u=e.useRef(!1),d=e.useCallback((()=>c.current=!1),[]);return e.useEffect((()=>()=>document.removeEventListener("pointerup",d)),[d]),e.createElement(Qa,X({asChild:!0},a),e.createElement(ii.button,X({"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute},o,{ref:l,onPointerMove:qo(t.onPointerMove,(e=>{"touch"!==e.pointerType&&(u.current||s.isPointerInTransitRef.current||(i.onTriggerEnter(),u.current=!0))})),onPointerLeave:qo(t.onPointerLeave,(()=>{i.onTriggerLeave(),u.current=!1})),onPointerDown:qo(t.onPointerDown,(()=>{c.current=!0,document.addEventListener("pointerup",d,{once:!0})})),onFocus:qo(t.onFocus,(()=>{c.current||i.onOpen()})),onBlur:qo(t.onBlur,i.onClose),onClick:qo(t.onClick,i.onClose)})))})),ng="TooltipPortal",[rg,og]=Uv(ng,{forceMount:void 0}),ig="TooltipContent",sg=e.forwardRef(((t,n)=>{const r=og(ig,t.__scopeTooltip),{forceMount:o=r.forceMount,side:i="top",...s}=t,a=Qv(ig,t.__scopeTooltip);return e.createElement(Mi,{present:o||a.open},a.disableHoverableContent?e.createElement(ug,X({side:i},s,{ref:n})):e.createElement(ag,X({side:i},s,{ref:n})))})),ag=e.forwardRef(((t,n)=>{const r=Qv(ig,t.__scopeTooltip),o=Gv(ig,t.__scopeTooltip),i=e.useRef(null),s=Zo(n,i),[a,l]=e.useState(null),{trigger:c,onClose:u}=r,d=i.current,{onPointerInTransitChange:f}=o,p=e.useCallback((()=>{l(null),f(!1)}),[f]),h=e.useCallback(((e,t)=>{const n=e.currentTarget,r={x:e.clientX,y:e.clientY},o=function(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}(r,function(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}(r,n.getBoundingClientRect())),i=function(e){const t=e.slice();return t.sort(((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:e.y>t.y?1:0)),function(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const n=e[r];for(;t.length>=2;){const e=t[t.length-1],r=t[t.length-2];if(!((e.x-r.x)*(n.y-r.y)>=(e.y-r.y)*(n.x-r.x)))break;t.pop()}t.push(n)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const t=e[r];for(;n.length>=2;){const e=n[n.length-1],r=n[n.length-2];if(!((e.x-r.x)*(t.y-r.y)>=(e.y-r.y)*(t.x-r.x)))break;n.pop()}n.push(t)}return n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}(t)}([...o,...function(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}(t.getBoundingClientRect())]);l(i),f(!0)}),[f]);return e.useEffect((()=>()=>p()),[p]),e.useEffect((()=>{if(c&&d){const e=e=>h(e,d),t=e=>h(e,c);return c.addEventListener("pointerleave",e),d.addEventListener("pointerleave",t),()=>{c.removeEventListener("pointerleave",e),d.removeEventListener("pointerleave",t)}}}),[c,d,h,p]),e.useEffect((()=>{if(a){const e=e=>{const t=e.target,n={x:e.clientX,y:e.clientY},r=(null==c?void 0:c.contains(t))||(null==d?void 0:d.contains(t)),o=!function(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,s=t.length-1;i<t.length;s=i++){const e=t[i].x,a=t[i].y,l=t[s].x,c=t[s].y;a>r!=c>r&&n<(l-e)*(r-a)/(c-a)+e&&(o=!o)}return o}(n,a);r?p():o&&(p(),u())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}}),[c,d,a,u,p]),e.createElement(ug,X({},t,{ref:s}))})),[lg,cg]=Uv(Zv,{isInside:!1}),ug=e.forwardRef(((t,n)=>{const{__scopeTooltip:r,children:o,"aria-label":i,onEscapeKeyDown:s,onPointerDownOutside:a,...l}=t,c=Qv(ig,r),u=Yv(r),{onClose:d}=c;return e.useEffect((()=>(document.addEventListener(Xv,d),()=>document.removeEventListener(Xv,d))),[d]),e.useEffect((()=>{if(c.trigger){const e=e=>{const t=e.target;null!=t&&t.contains(c.trigger)&&d()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}}),[c.trigger,d]),e.createElement(ls,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:e=>e.preventDefault(),onDismiss:d},e.createElement(el,X({"data-state":c.stateAttribute},u,l,{ref:n,style:{...l.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),e.createElement(ni,null,o),e.createElement(lg,{scope:r,isInside:!0},e.createElement(ol,{id:c.contentId,role:"tooltip"},i||o))))}));const dg=t=>{const{__scopeTooltip:n,delayDuration:r=Kv,skipDelayDuration:o=300,disableHoverableContent:i=!1,children:s}=t,[a,l]=e.useState(!0),c=e.useRef(!1),u=e.useRef(0);return e.useEffect((()=>{const e=u.current;return()=>window.clearTimeout(e)}),[]),e.createElement(qv,{scope:n,isOpenDelayed:a,delayDuration:r,onOpen:e.useCallback((()=>{window.clearTimeout(u.current),l(!1)}),[]),onClose:e.useCallback((()=>{window.clearTimeout(u.current),u.current=window.setTimeout((()=>l(!0)),o)}),[o]),isPointerInTransitRef:c,onPointerInTransitChange:e.useCallback((e=>{c.current=e}),[]),disableHoverableContent:i},s)},fg=t=>{const{__scopeTooltip:n,children:r,open:o,defaultOpen:i=!1,onOpenChange:s,disableHoverableContent:a,delayDuration:l}=t,c=Gv(Zv,t.__scopeTooltip),u=Yv(n),[d,f]=e.useState(null),p=ui(),h=e.useRef(0),m=null!=a?a:c.disableHoverableContent,v=null!=l?l:c.delayDuration,g=e.useRef(!1),[y=!1,b]=fi({prop:o,defaultProp:i,onChange:e=>{e?(c.onOpen(),document.dispatchEvent(new CustomEvent(Xv))):c.onClose(),null==s||s(e)}}),w=e.useMemo((()=>y?g.current?"delayed-open":"instant-open":"closed"),[y]),x=e.useCallback((()=>{window.clearTimeout(h.current),g.current=!1,b(!0)}),[b]),E=e.useCallback((()=>{window.clearTimeout(h.current),b(!1)}),[b]),S=e.useCallback((()=>{window.clearTimeout(h.current),h.current=window.setTimeout((()=>{g.current=!0,b(!0)}),v)}),[v,b]);return e.useEffect((()=>()=>window.clearTimeout(h.current)),[]),e.createElement(Ja,u,e.createElement(Jv,{scope:n,contentId:p,open:y,stateAttribute:w,trigger:d,onTriggerChange:f,onTriggerEnter:e.useCallback((()=>{c.isOpenDelayed?S():x()}),[c.isOpenDelayed,S,x]),onTriggerLeave:e.useCallback((()=>{m?E():window.clearTimeout(h.current)}),[E,m]),onOpen:x,onClose:E,disableHoverableContent:m},r))},pg=tg,hg=t=>{const{__scopeTooltip:n,forceMount:r,children:o,container:i}=t,s=Qv(ng,n);return e.createElement(rg,{scope:n,forceMount:r},e.createElement(Mi,{present:r||s.open},e.createElement(nl,{asChild:!0,container:i},o)))},mg=sg,vg=e.forwardRef(((t,n)=>{const{__scopeTooltip:r,...o}=t,i=Yv(r);return cg("TooltipArrow",r).isInside?null:e.createElement(tl,X({},i,o,{ref:n}))}));const gg="ScrollArea",[yg,bg]=q(gg),[wg,xg]=yg(gg),Eg=e.forwardRef(((t,n)=>{const{__scopeScrollArea:r,type:o="hover",dir:i,scrollHideDelay:s=600,...a}=t,[l,c]=e.useState(null),[u,d]=e.useState(null),[f,p]=e.useState(null),[h,m]=e.useState(null),[v,g]=e.useState(null),[y,b]=e.useState(0),[w,x]=e.useState(0),[E,S]=e.useState(!1),[P,C]=e.useState(!1),T=J(n,(e=>c(e))),R=yo(i);return e.createElement(wg,{scope:r,type:o,dir:R,scrollHideDelay:s,scrollArea:l,viewport:u,onViewportChange:d,content:f,onContentChange:p,scrollbarX:h,onScrollbarXChange:m,scrollbarXEnabled:E,onScrollbarXEnabledChange:S,scrollbarY:v,onScrollbarYChange:g,scrollbarYEnabled:P,onScrollbarYEnabledChange:C,onCornerWidthChange:b,onCornerHeightChange:x},e.createElement(de.div,X({dir:R},a,{ref:T,style:{position:"relative","--radix-scroll-area-corner-width":y+"px","--radix-scroll-area-corner-height":w+"px",...t.style}})))})),Sg=e.forwardRef(((t,n)=>{const{__scopeScrollArea:r,children:o,...i}=t,s=xg("ScrollAreaViewport",r),a=J(n,e.useRef(null),s.onViewportChange);return e.createElement(e.Fragment,null,e.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"}}),e.createElement(de.div,X({"data-radix-scroll-area-viewport":""},i,{ref:a,style:{overflowX:s.scrollbarXEnabled?"scroll":"hidden",overflowY:s.scrollbarYEnabled?"scroll":"hidden",...t.style}}),e.createElement("div",{ref:s.onContentChange,style:{minWidth:"100%",display:"table"}},o)))})),Pg="ScrollAreaScrollbar",Cg=e.forwardRef(((t,n)=>{const{forceMount:r,...o}=t,i=xg(Pg,t.__scopeScrollArea),{onScrollbarXEnabledChange:s,onScrollbarYEnabledChange:a}=i,l="horizontal"===t.orientation;return e.useEffect((()=>(l?s(!0):a(!0),()=>{l?s(!1):a(!1)})),[l,s,a]),"hover"===i.type?e.createElement(Tg,X({},o,{ref:n,forceMount:r})):"scroll"===i.type?e.createElement(Rg,X({},o,{ref:n,forceMount:r})):"auto"===i.type?e.createElement(Ag,X({},o,{ref:n,forceMount:r})):"always"===i.type?e.createElement(Og,X({},o,{ref:n})):null})),Tg=e.forwardRef(((t,n)=>{const{forceMount:r,...o}=t,i=xg(Pg,t.__scopeScrollArea),[s,a]=e.useState(!1);return e.useEffect((()=>{const e=i.scrollArea;let t=0;if(e){const n=()=>{window.clearTimeout(t),a(!0)},r=()=>{t=window.setTimeout((()=>a(!1)),i.scrollHideDelay)};return e.addEventListener("pointerenter",n),e.addEventListener("pointerleave",r),()=>{window.clearTimeout(t),e.removeEventListener("pointerenter",n),e.removeEventListener("pointerleave",r)}}}),[i.scrollArea,i.scrollHideDelay]),e.createElement(ke,{present:r||s},e.createElement(Ag,X({"data-state":s?"visible":"hidden"},o,{ref:n})))})),Rg=e.forwardRef(((t,n)=>{const{forceMount:r,...o}=t,i=xg(Pg,t.__scopeScrollArea),s="horizontal"===t.orientation,a=Xg((()=>c("SCROLL_END")),100),[l,c]=(u="hidden",d={hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}},e.useReducer(((e,t)=>{const n=d[e][t];return null!=n?n:e}),u));var u,d;return e.useEffect((()=>{if("idle"===l){const e=window.setTimeout((()=>c("HIDE")),i.scrollHideDelay);return()=>window.clearTimeout(e)}}),[l,i.scrollHideDelay,c]),e.useEffect((()=>{const e=i.viewport,t=s?"scrollLeft":"scrollTop";if(e){let n=e[t];const r=()=>{const r=e[t];n!==r&&(c("SCROLL"),a()),n=r};return e.addEventListener("scroll",r),()=>e.removeEventListener("scroll",r)}}),[i.viewport,s,c,a]),e.createElement(ke,{present:r||"hidden"!==l},e.createElement(Og,X({"data-state":"hidden"===l?"hidden":"visible"},o,{ref:n,onPointerEnter:Q(t.onPointerEnter,(()=>c("POINTER_ENTER"))),onPointerLeave:Q(t.onPointerLeave,(()=>c("POINTER_LEAVE")))})))})),Ag=e.forwardRef(((t,n)=>{const r=xg(Pg,t.__scopeScrollArea),{forceMount:o,...i}=t,[s,a]=e.useState(!1),l="horizontal"===t.orientation,c=Xg((()=>{if(r.viewport){const e=r.viewport.offsetWidth<r.viewport.scrollWidth,t=r.viewport.offsetHeight<r.viewport.scrollHeight;a(l?e:t)}}),10);return qg(r.viewport,c),qg(r.content,c),e.createElement(ke,{present:o||s},e.createElement(Og,X({"data-state":s?"visible":"hidden"},i,{ref:n})))})),Og=e.forwardRef(((t,n)=>{const{orientation:r="vertical",...o}=t,i=xg(Pg,t.__scopeScrollArea),s=e.useRef(null),a=e.useRef(0),[l,c]=e.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),u=Wg(l.viewport,l.content),d={...o,sizes:l,onSizesChange:c,hasThumb:Boolean(u>0&&u<1),onThumbChange:e=>s.current=e,onThumbPointerUp:()=>a.current=0,onThumbPointerDown:e=>a.current=e};function f(e,t){return function(e,t,n,r="ltr"){const o=Hg(n),i=o/2,s=t||i,a=o-s,l=n.scrollbar.paddingStart+s,c=n.scrollbar.size-n.scrollbar.paddingEnd-a,u=n.content-n.viewport,d="ltr"===r?[0,u]:[-1*u,0];return zg([l,c],d)(e)}(e,a.current,l,t)}return"horizontal"===r?e.createElement(Dg,X({},d,{ref:n,onThumbPositionChange:()=>{if(i.viewport&&s.current){const e=Ug(i.viewport.scrollLeft,l,i.dir);s.current.style.transform=`translate3d(${e}px, 0, 0)`}},onWheelScroll:e=>{i.viewport&&(i.viewport.scrollLeft=e)},onDragScroll:e=>{i.viewport&&(i.viewport.scrollLeft=f(e,i.dir))}})):"vertical"===r?e.createElement(kg,X({},d,{ref:n,onThumbPositionChange:()=>{if(i.viewport&&s.current){const e=Ug(i.viewport.scrollTop,l);s.current.style.transform=`translate3d(0, ${e}px, 0)`}},onWheelScroll:e=>{i.viewport&&(i.viewport.scrollTop=e)},onDragScroll:e=>{i.viewport&&(i.viewport.scrollTop=f(e))}})):null})),Dg=e.forwardRef(((t,n)=>{const{sizes:r,onSizesChange:o,...i}=t,s=xg(Pg,t.__scopeScrollArea),[a,l]=e.useState(),c=e.useRef(null),u=J(n,c,s.onScrollbarXChange);return e.useEffect((()=>{c.current&&l(getComputedStyle(c.current))}),[c]),e.createElement(Mg,X({"data-orientation":"horizontal"},i,{ref:u,sizes:r,style:{bottom:0,left:"rtl"===s.dir?"var(--radix-scroll-area-corner-width)":0,right:"ltr"===s.dir?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Hg(r)+"px",...t.style},onThumbPointerDown:e=>t.onThumbPointerDown(e.x),onDragScroll:e=>t.onDragScroll(e.x),onWheelScroll:(e,n)=>{if(s.viewport){const r=s.viewport.scrollLeft+e.deltaX;t.onWheelScroll(r),Yg(r,n)&&e.preventDefault()}},onResize:()=>{c.current&&s.viewport&&a&&o({content:s.viewport.scrollWidth,viewport:s.viewport.offsetWidth,scrollbar:{size:c.current.clientWidth,paddingStart:Bg(a.paddingLeft),paddingEnd:Bg(a.paddingRight)}})}}))})),kg=e.forwardRef(((t,n)=>{const{sizes:r,onSizesChange:o,...i}=t,s=xg(Pg,t.__scopeScrollArea),[a,l]=e.useState(),c=e.useRef(null),u=J(n,c,s.onScrollbarYChange);return e.useEffect((()=>{c.current&&l(getComputedStyle(c.current))}),[c]),e.createElement(Mg,X({"data-orientation":"vertical"},i,{ref:u,sizes:r,style:{top:0,right:"ltr"===s.dir?0:void 0,left:"rtl"===s.dir?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Hg(r)+"px",...t.style},onThumbPointerDown:e=>t.onThumbPointerDown(e.y),onDragScroll:e=>t.onDragScroll(e.y),onWheelScroll:(e,n)=>{if(s.viewport){const r=s.viewport.scrollTop+e.deltaY;t.onWheelScroll(r),Yg(r,n)&&e.preventDefault()}},onResize:()=>{c.current&&s.viewport&&a&&o({content:s.viewport.scrollHeight,viewport:s.viewport.offsetHeight,scrollbar:{size:c.current.clientHeight,paddingStart:Bg(a.paddingTop),paddingEnd:Bg(a.paddingBottom)}})}}))})),[_g,Lg]=yg(Pg),Mg=e.forwardRef(((t,n)=>{const{__scopeScrollArea:r,sizes:o,hasThumb:i,onThumbChange:s,onThumbPointerUp:a,onThumbPointerDown:l,onThumbPositionChange:c,onDragScroll:u,onWheelScroll:d,onResize:f,...p}=t,h=xg(Pg,r),[m,v]=e.useState(null),g=J(n,(e=>v(e))),y=e.useRef(null),b=e.useRef(""),w=h.viewport,x=o.content-o.viewport,E=oe(d),S=oe(c),P=Xg(f,10);function C(e){if(y.current){const t=e.clientX-y.current.left,n=e.clientY-y.current.top;u({x:t,y:n})}}return e.useEffect((()=>{const e=e=>{const t=e.target;(null==m?void 0:m.contains(t))&&E(e,x)};return document.addEventListener("wheel",e,{passive:!1}),()=>document.removeEventListener("wheel",e,{passive:!1})}),[w,m,x,E]),e.useEffect(S,[o,S]),qg(m,P),qg(h.content,P),e.createElement(_g,{scope:r,scrollbar:m,hasThumb:i,onThumbChange:oe(s),onThumbPointerUp:oe(a),onThumbPositionChange:S,onThumbPointerDown:oe(l)},e.createElement(de.div,X({},p,{ref:g,style:{position:"absolute",...p.style},onPointerDown:Q(t.onPointerDown,(e=>{if(0===e.button){e.target.setPointerCapture(e.pointerId),y.current=m.getBoundingClientRect(),b.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",C(e)}})),onPointerMove:Q(t.onPointerMove,C),onPointerUp:Q(t.onPointerUp,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),document.body.style.webkitUserSelect=b.current,y.current=null}))})))})),Ig="ScrollAreaThumb",Vg=e.forwardRef(((t,n)=>{const{forceMount:r,...o}=t,i=Lg(Ig,t.__scopeScrollArea);return e.createElement(ke,{present:r||i.hasThumb},e.createElement($g,X({ref:n},o)))})),$g=e.forwardRef(((t,n)=>{const{__scopeScrollArea:r,style:o,...i}=t,s=xg(Ig,r),a=Lg(Ig,r),{onThumbPositionChange:l}=a,c=J(n,(e=>a.onThumbChange(e))),u=e.useRef(),d=Xg((()=>{u.current&&(u.current(),u.current=void 0)}),100);return e.useEffect((()=>{const e=s.viewport;if(e){const t=()=>{if(d(),!u.current){const t=Kg(e,l);u.current=t,l()}};return l(),e.addEventListener("scroll",t),()=>e.removeEventListener("scroll",t)}}),[s.viewport,d,l]),e.createElement(de.div,X({"data-state":a.hasThumb?"visible":"hidden"},i,{ref:c,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...o},onPointerDownCapture:Q(t.onPointerDownCapture,(e=>{const t=e.target.getBoundingClientRect(),n=e.clientX-t.left,r=e.clientY-t.top;a.onThumbPointerDown({x:n,y:r})})),onPointerUp:Q(t.onPointerUp,a.onThumbPointerUp)}))})),Ng="ScrollAreaCorner",Fg=e.forwardRef(((t,n)=>{const r=xg(Ng,t.__scopeScrollArea),o=Boolean(r.scrollbarX&&r.scrollbarY);return"scroll"!==r.type&&o?e.createElement(jg,X({},t,{ref:n})):null})),jg=e.forwardRef(((t,n)=>{const{__scopeScrollArea:r,...o}=t,i=xg(Ng,r),[s,a]=e.useState(0),[l,c]=e.useState(0),u=Boolean(s&&l);return qg(i.scrollbarX,(()=>{var e;const t=(null===(e=i.scrollbarX)||void 0===e?void 0:e.offsetHeight)||0;i.onCornerHeightChange(t),c(t)})),qg(i.scrollbarY,(()=>{var e;const t=(null===(e=i.scrollbarY)||void 0===e?void 0:e.offsetWidth)||0;i.onCornerWidthChange(t),a(t)})),u?e.createElement(de.div,X({},o,{ref:n,style:{width:s,height:l,position:"absolute",right:"ltr"===i.dir?0:void 0,left:"rtl"===i.dir?0:void 0,bottom:0,...t.style}})):null}));function Bg(e){return e?parseInt(e,10):0}function Wg(e,t){const n=e/t;return isNaN(n)?0:n}function Hg(e){const t=Wg(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function Ug(e,t,n="ltr"){const r=Hg(t),o=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,i=t.scrollbar.size-o,s=t.content-t.viewport,a=i-r,l=vo(e,"ltr"===n?[0,s]:[-1*s,0]);return zg([0,s],[0,a])(l)}function zg(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function Yg(e,t){return e>0&&e<t}const Kg=(e,t=(()=>{}))=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return function o(){const i={left:e.scrollLeft,top:e.scrollTop},s=n.left!==i.left,a=n.top!==i.top;(s||a)&&t(),n=i,r=window.requestAnimationFrame(o)}(),()=>window.cancelAnimationFrame(r)};function Xg(t,n){const r=oe(t),o=e.useRef(0);return e.useEffect((()=>()=>window.clearTimeout(o.current)),[]),e.useCallback((()=>{window.clearTimeout(o.current),o.current=window.setTimeout(r,n)}),[r,n])}function qg(e,t){const n=oe(t);ee((()=>{let t=0;if(e){const r=new ResizeObserver((()=>{cancelAnimationFrame(t),t=window.requestAnimationFrame(n)}));return r.observe(e),()=>{window.cancelAnimationFrame(t),r.unobserve(e)}}}),[e,n])}const Gg=Eg,Zg=Sg,Jg=Cg,Qg=Vg,ey=Fg;exports.$57acba87d6e25586$export$6521433ed15a34db=Qg,exports.$57acba87d6e25586$export$9a4e88b92edfce6b=Jg,exports.$57acba87d6e25586$export$ac61190d9fc311a9=ey,exports.$57acba87d6e25586$export$be92b6f5f03c0fe9=Gg,exports.$57acba87d6e25586$export$d5c6c08dc2d3ca7=Zg,exports.$5d3850c4d0b4e6c7$export$602eac185826482c=Ht,exports.$5d3850c4d0b4e6c7$export$7c6e2c02157bb7d2=zt,exports.$5d3850c4d0b4e6c7$export$be92b6f5f03c0fe9=Wt,exports.$5d3850c4d0b4e6c7$export$c6fdb837b070b4ff=Ut,exports.$67824d98245208a0$export$adb584737d712b70=no,exports.$67824d98245208a0$export$be92b6f5f03c0fe9=to,exports.$a093c7e1ec25a057$export$21b07c8f274aebd5=vg,exports.$a093c7e1ec25a057$export$2881499e37b75b9a=dg,exports.$a093c7e1ec25a057$export$41fb9f06171c75f4=pg,exports.$a093c7e1ec25a057$export$602eac185826482c=hg,exports.$a093c7e1ec25a057$export$7c6e2c02157bb7d2=mg,exports.$a093c7e1ec25a057$export$be92b6f5f03c0fe9=fg,exports.$cb5cc270b50c6fcd$export$21b07c8f274aebd5=Wr,exports.$cb5cc270b50c6fcd$export$41fb9f06171c75f4=Nr,exports.$cb5cc270b50c6fcd$export$602eac185826482c=Fr,exports.$cb5cc270b50c6fcd$export$7c6e2c02157bb7d2=jr,exports.$cb5cc270b50c6fcd$export$be92b6f5f03c0fe9=$r,exports.$cb5cc270b50c6fcd$export$f39c2d165cd861fe=Br,exports.$cc7e05a45900e73f$export$2f60d3ec9ad468f2=oc,exports.$cc7e05a45900e73f$export$41fb9f06171c75f4=ql,exports.$cc7e05a45900e73f$export$4c8d1a57a761ef94=Gl,exports.$cc7e05a45900e73f$export$602eac185826482c=Jl,exports.$cc7e05a45900e73f$export$6d08773d2e66f8f2=tc,exports.$cc7e05a45900e73f$export$7c6e2c02157bb7d2=Ql,exports.$cc7e05a45900e73f$export$be92b6f5f03c0fe9=Xl,exports.$cc7e05a45900e73f$export$bf1aedc3039c8d63=ic,exports.$cc7e05a45900e73f$export$c3468e2714d175fa=rc,exports.$cc7e05a45900e73f$export$d5c6c08dc2d3ca7=ec,exports.$cc7e05a45900e73f$export$d6e5bf9c43ea9319=nc,exports.$cc7e05a45900e73f$export$f04a61298a47a40f=Zl,exports.$e698a72e93240346$export$adb584737d712b70=mo,exports.$e698a72e93240346$export$be92b6f5f03c0fe9=ho,exports.$f99a8c78507165f7$export$6d08773d2e66f8f2=es,exports.$f99a8c78507165f7$export$adb584737d712b70=ts,exports.$f99a8c78507165f7$export$be92b6f5f03c0fe9=Qi,exports.$faa2e61a3361514f$export$13921ac0cc260818=Yo,exports.$faa2e61a3361514f$export$6521433ed15a34db=Xo,exports.$faa2e61a3361514f$export$9a58ef0d7ad3278c=Ko,exports.$faa2e61a3361514f$export$be92b6f5f03c0fe9=zo,exports.Masonry=jv,exports.MasonryResponsive=Hv,exports.jsxRuntimeExports=d,exports.motion=fv;
|
|
2
|
-
//# sourceMappingURL=vendor-b4f78627.cjs.map
|