@ctlyst.id/voila-ui 1.20.0 → 1.20.2
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/index.js +23 -23
- package/dist/index.mjs +1837 -1825
- package/dist/style.css +1 -1
- package/dist/types/components/form/field.d.ts +1 -0
- package/dist/types/components/form/input.d.ts +1 -0
- package/dist/types/components/form/textarea.d.ts +1 -0
- package/dist/types/components/modal/modal.d.ts +2 -0
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -14,17 +14,17 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var Vu;function wy(){return Vu||(Vu=1,process.env.NODE_ENV!=="production"&&function(){var e=u,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),
|
|
18
|
-
`+B+
|
|
17
|
+
*/var Vu;function wy(){return Vu||(Vu=1,process.env.NODE_ENV!=="production"&&function(){var e=u,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),y=Symbol.iterator,E="@@iterator";function T(b){if(b===null||typeof b!="object")return null;var F=y&&b[y]||b[E];return typeof F=="function"?F:null}var S=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function m(b){{for(var F=arguments.length,Q=new Array(F>1?F-1:0),fe=1;fe<F;fe++)Q[fe-1]=arguments[fe];x("error",b,Q)}}function x(b,F,Q){{var fe=S.ReactDebugCurrentFrame,xe=fe.getStackAddendum();xe!==""&&(F+="%s",Q=Q.concat([xe]));var Se=Q.map(function(be){return String(be)});Se.unshift("Warning: "+F),Function.prototype.apply.call(console[b],console,Se)}}var _=!1,$=!1,M=!1,D=!1,N=!1,j;j=Symbol.for("react.module.reference");function K(b){return!!(typeof b=="string"||typeof b=="function"||b===r||b===o||N||b===i||b===l||b===d||D||b===p||_||$||M||typeof b=="object"&&b!==null&&(b.$$typeof===h||b.$$typeof===f||b.$$typeof===s||b.$$typeof===a||b.$$typeof===c||b.$$typeof===j||b.getModuleId!==void 0))}function V(b,F,Q){var fe=b.displayName;if(fe)return fe;var xe=F.displayName||F.name||"";return xe!==""?Q+"("+xe+")":Q}function P(b){return b.displayName||"Context"}function v(b){if(b==null)return null;if(typeof b.tag=="number"&&m("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof b=="function")return b.displayName||b.name||null;if(typeof b=="string")return b;switch(b){case r:return"Fragment";case n:return"Portal";case o:return"Profiler";case i:return"StrictMode";case l:return"Suspense";case d:return"SuspenseList"}if(typeof b=="object")switch(b.$$typeof){case a:var F=b;return P(F)+".Consumer";case s:var Q=b;return P(Q._context)+".Provider";case c:return V(b,b.render,"ForwardRef");case f:var fe=b.displayName||null;return fe!==null?fe:v(b.type)||"Memo";case h:{var xe=b,Se=xe._payload,be=xe._init;try{return v(be(Se))}catch{return null}}}return null}var C=Object.assign,I=0,k,U,G,ue,W,L,oe;function X(){}X.__reactDisabledLog=!0;function q(){{if(I===0){k=console.log,U=console.info,G=console.warn,ue=console.error,W=console.group,L=console.groupCollapsed,oe=console.groupEnd;var b={configurable:!0,enumerable:!0,value:X,writable:!0};Object.defineProperties(console,{info:b,log:b,warn:b,error:b,group:b,groupCollapsed:b,groupEnd:b})}I++}}function ne(){{if(I--,I===0){var b={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:C({},b,{value:k}),info:C({},b,{value:U}),warn:C({},b,{value:G}),error:C({},b,{value:ue}),group:C({},b,{value:W}),groupCollapsed:C({},b,{value:L}),groupEnd:C({},b,{value:oe})})}I<0&&m("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var ae=S.ReactCurrentDispatcher,B;function H(b,F,Q){{if(B===void 0)try{throw Error()}catch(xe){var fe=xe.stack.trim().match(/\n( *(at )?)/);B=fe&&fe[1]||""}return`
|
|
18
|
+
`+B+b}}var J=!1,ee;{var te=typeof WeakMap=="function"?WeakMap:Map;ee=new te}function Z(b,F){if(!b||J)return"";{var Q=ee.get(b);if(Q!==void 0)return Q}var fe;J=!0;var xe=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var Se;Se=ae.current,ae.current=null,q();try{if(F){var be=function(){throw Error()};if(Object.defineProperty(be.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(be,[])}catch(We){fe=We}Reflect.construct(b,[],be)}else{try{be.call()}catch(We){fe=We}b.call(be.prototype)}}else{try{throw Error()}catch(We){fe=We}b()}}catch(We){if(We&&fe&&typeof We.stack=="string"){for(var ye=We.stack.split(`
|
|
19
19
|
`),Ge=fe.stack.split(`
|
|
20
20
|
`),Ne=ye.length-1,Le=Ge.length-1;Ne>=1&&Le>=0&&ye[Ne]!==Ge[Le];)Le--;for(;Ne>=1&&Le>=0;Ne--,Le--)if(ye[Ne]!==Ge[Le]){if(Ne!==1||Le!==1)do if(Ne--,Le--,Le<0||ye[Ne]!==Ge[Le]){var Ue=`
|
|
21
|
-
`+ye[Ne].replace(" at new "," at ");return
|
|
21
|
+
`+ye[Ne].replace(" at new "," at ");return b.displayName&&Ue.includes("<anonymous>")&&(Ue=Ue.replace("<anonymous>",b.displayName)),typeof b=="function"&&ee.set(b,Ue),Ue}while(Ne>=1&&Le>=0);break}}}finally{J=!1,ae.current=Se,ne(),Error.prepareStackTrace=xe}var Bt=b?b.displayName||b.name:"",br=Bt?H(Bt):"";return typeof b=="function"&&ee.set(b,br),br}function ge(b,F,Q){return Z(b,!1)}function Te(b){var F=b.prototype;return!!(F&&F.isReactComponent)}function Ie(b,F,Q){if(b==null)return"";if(typeof b=="function")return Z(b,Te(b));if(typeof b=="string")return H(b);switch(b){case l:return H("Suspense");case d:return H("SuspenseList")}if(typeof b=="object")switch(b.$$typeof){case c:return ge(b.render);case f:return Ie(b.type,F,Q);case h:{var fe=b,xe=fe._payload,Se=fe._init;try{return Ie(Se(xe),F,Q)}catch{}}}return""}var Ae=Object.prototype.hasOwnProperty,$e={},Ye=S.ReactDebugCurrentFrame;function je(b){if(b){var F=b._owner,Q=Ie(b.type,b._source,F?F.type:null);Ye.setExtraStackFrame(Q)}else Ye.setExtraStackFrame(null)}function vt(b,F,Q,fe,xe){{var Se=Function.call.bind(Ae);for(var be in b)if(Se(b,be)){var ye=void 0;try{if(typeof b[be]!="function"){var Ge=Error((fe||"React class")+": "+Q+" type `"+be+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof b[be]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw Ge.name="Invariant Violation",Ge}ye=b[be](F,be,fe,Q,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(Ne){ye=Ne}ye&&!(ye instanceof Error)&&(je(xe),m("%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).",fe||"React class",Q,be,typeof ye),je(null)),ye instanceof Error&&!(ye.message in $e)&&($e[ye.message]=!0,je(xe),m("Failed %s type: %s",Q,ye.message),je(null))}}}var Xe=Array.isArray;function Rt(b){return Xe(b)}function st(b){{var F=typeof Symbol=="function"&&Symbol.toStringTag,Q=F&&b[Symbol.toStringTag]||b.constructor.name||"Object";return Q}}function Ft(b){try{return Pe(b),!1}catch{return!0}}function Pe(b){return""+b}function Ot(b){if(Ft(b))return m("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",st(b)),Pe(b)}var gt=S.ReactCurrentOwner,bn={key:!0,ref:!0,__self:!0,__source:!0},Xt,Nt,Fe;Fe={};function Mt(b){if(Ae.call(b,"ref")){var F=Object.getOwnPropertyDescriptor(b,"ref").get;if(F&&F.isReactWarning)return!1}return b.ref!==void 0}function Gt(b){if(Ae.call(b,"key")){var F=Object.getOwnPropertyDescriptor(b,"key").get;if(F&&F.isReactWarning)return!1}return b.key!==void 0}function On(b,F){if(typeof b.ref=="string"&>.current&&F&>.current.stateNode!==F){var Q=v(gt.current.type);Fe[Q]||(m('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',v(gt.current.type),b.ref),Fe[Q]=!0)}}function Zt(b,F){{var Q=function(){Xt||(Xt=!0,m("%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)",F))};Q.isReactWarning=!0,Object.defineProperty(b,"key",{get:Q,configurable:!0})}}function yr(b,F){{var Q=function(){Nt||(Nt=!0,m("%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)",F))};Q.isReactWarning=!0,Object.defineProperty(b,"ref",{get:Q,configurable:!0})}}var mn=function(b,F,Q,fe,xe,Se,be){var ye={$$typeof:t,type:b,key:F,ref:Q,props:be,_owner:Se};return ye._store={},Object.defineProperty(ye._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(ye,"_self",{configurable:!1,enumerable:!1,writable:!1,value:fe}),Object.defineProperty(ye,"_source",{configurable:!1,enumerable:!1,writable:!1,value:xe}),Object.freeze&&(Object.freeze(ye.props),Object.freeze(ye)),ye};function Br(b,F,Q,fe,xe){{var Se,be={},ye=null,Ge=null;Q!==void 0&&(Ot(Q),ye=""+Q),Gt(F)&&(Ot(F.key),ye=""+F.key),Mt(F)&&(Ge=F.ref,On(F,xe));for(Se in F)Ae.call(F,Se)&&!bn.hasOwnProperty(Se)&&(be[Se]=F[Se]);if(b&&b.defaultProps){var Ne=b.defaultProps;for(Se in Ne)be[Se]===void 0&&(be[Se]=Ne[Se])}if(ye||Ge){var Le=typeof b=="function"?b.displayName||b.name||"Unknown":b;ye&&Zt(be,Le),Ge&&yr(be,Le)}return mn(b,ye,Ge,xe,fe,gt.current,be)}}var Qt=S.ReactCurrentOwner,wn=S.ReactDebugCurrentFrame;function jt(b){if(b){var F=b._owner,Q=Ie(b.type,b._source,F?F.type:null);wn.setExtraStackFrame(Q)}else wn.setExtraStackFrame(null)}var xn;xn=!1;function En(b){return typeof b=="object"&&b!==null&&b.$$typeof===t}function Xn(){{if(Qt.current){var b=v(Qt.current.type);if(b)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+
|
|
23
|
+
Check the render method of \``+b+"`."}return""}}function vo(b){{if(b!==void 0){var F=b.fileName.replace(/^.*[\\\/]/,""),Q=b.lineNumber;return`
|
|
24
24
|
|
|
25
|
-
Check your code at `+F+":"+Q+"."}return""}}var Gn={};function Zn(
|
|
25
|
+
Check your code at `+F+":"+Q+"."}return""}}var Gn={};function Zn(b){{var F=Xn();if(!F){var Q=typeof b=="string"?b:b.displayName||b.name;Q&&(F=`
|
|
26
26
|
|
|
27
|
-
Check the top-level render call using <`+Q+">.")}return F}}function Cn(y,F){{if(!y._store||y._store.validated||y.key!=null)return;y._store.validated=!0;var Q=Zn(F);if(Gn[Q])return;Gn[Q]=!0;var fe="";y&&y._owner&&y._owner!==Qt.current&&(fe=" It was passed a child from "+v(y._owner.type)+"."),jt(y),m('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',Q,fe),jt(null)}}function cn(y,F){{if(typeof y!="object")return;if(Rt(y))for(var Q=0;Q<y.length;Q++){var fe=y[Q];En(fe)&&Cn(fe,F)}else if(En(y))y._store&&(y._store.validated=!0);else if(y){var xe=T(y);if(typeof xe=="function"&&xe!==y.entries)for(var Se=xe.call(y),be;!(be=Se.next()).done;)En(be.value)&&Cn(be.value,F)}}}function Qn(y){{var F=y.type;if(F==null||typeof F=="string")return;var Q;if(typeof F=="function")Q=F.propTypes;else if(typeof F=="object"&&(F.$$typeof===c||F.$$typeof===f))Q=F.propTypes;else return;if(Q){var fe=v(F);vt(Q,y.props,"prop",fe,y)}else if(F.PropTypes!==void 0&&!xn){xn=!0;var xe=v(F);m("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",xe||"Unknown")}typeof F.getDefaultProps=="function"&&!F.getDefaultProps.isReactClassApproved&&m("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Mn(y){{for(var F=Object.keys(y.props),Q=0;Q<F.length;Q++){var fe=F[Q];if(fe!=="children"&&fe!=="key"){jt(y),m("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",fe),jt(null);break}}y.ref!==null&&(jt(y),m("Invalid attribute `ref` supplied to `React.Fragment`."),jt(null))}}function vn(y,F,Q,fe,xe,Se){{var be=K(y);if(!be){var ye="";(y===void 0||typeof y=="object"&&y!==null&&Object.keys(y).length===0)&&(ye+=" 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 Ge=vo(xe);Ge?ye+=Ge:ye+=Xn();var Ne;y===null?Ne="null":Rt(y)?Ne="array":y!==void 0&&y.$$typeof===t?(Ne="<"+(v(y.type)||"Unknown")+" />",ye=" Did you accidentally export a JSX literal instead of a component?"):Ne=typeof y,m("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Ne,ye)}var Le=Br(y,F,Q,xe,Se);if(Le==null)return Le;if(be){var Ue=F.children;if(Ue!==void 0)if(fe)if(Rt(Ue)){for(var Bt=0;Bt<Ue.length;Bt++)cn(Ue[Bt],y);Object.freeze&&Object.freeze(Ue)}else m("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 cn(Ue,y)}return y===r?Mn(Le):Qn(Le),Le}}function _n(y,F,Q){return vn(y,F,Q,!0)}function Jn(y,F,Q){return vn(y,F,Q,!1)}var Vt=Jn,er=_n;wo.Fragment=r,wo.jsx=Vt,wo.jsxs=er}()),wo}process.env.NODE_ENV==="production"?Da.exports=by():Da.exports=wy();var D=Da.exports;function ie(){return ie=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},ie.apply(this,arguments)}function sn(e,t=[]){let n=[];function r(o,s){const a=u.createContext(s),c=n.length;n=[...n,s];function l(f){const{scope:h,children:p,...w}=f,E=(h==null?void 0:h[e][c])||a,T=u.useMemo(()=>w,Object.values(w));return u.createElement(E.Provider,{value:T},p)}function d(f,h){const p=(h==null?void 0:h[e][c])||a,w=u.useContext(p);if(w)return w;if(s!==void 0)return s;throw new Error(`\`${f}\` must be used within \`${o}\``)}return l.displayName=o+"Provider",[l,d]}const i=()=>{const o=n.map(s=>u.createContext(s));return function(a){const c=(a==null?void 0:a[e])||o;return u.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return i.scopeName=e,[r,xy(i,...t)]}function xy(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const s=r.reduce((a,{useScope:c,scopeName:l})=>{const f=c(o)[`__scope${l}`];return{...a,...f}},{});return u.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function Ey(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Np(...e){return t=>e.forEach(n=>Ey(n,t))}function Qe(...e){return u.useCallback(Np(...e),e)}const no=u.forwardRef((e,t)=>{const{children:n,...r}=e,i=u.Children.toArray(n),o=i.find(Cy);if(o){const s=o.props.children,a=i.map(c=>c===o?u.Children.count(s)>1?u.Children.only(null):u.isValidElement(s)?s.props.children:null:c);return u.createElement(Oa,ie({},r,{ref:t}),u.isValidElement(s)?u.cloneElement(s,void 0,a):null)}return u.createElement(Oa,ie({},r,{ref:t}),n)});no.displayName="Slot";const Oa=u.forwardRef((e,t)=>{const{children:n,...r}=e;return u.isValidElement(n)?u.cloneElement(n,{..._y(r,n.props),ref:t?Np(t,n.ref):n.ref}):u.Children.count(n)>1?u.Children.only(null):null});Oa.displayName="SlotClone";const jp=({children:e})=>u.createElement(u.Fragment,null,e);function Cy(e){return u.isValidElement(e)&&e.type===jp}function _y(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...a)=>{o(...a),i(...a)}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function os(e){const t=e+"CollectionProvider",[n,r]=sn(t),[i,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=p=>{const{scope:w,children:E}=p,T=u.useRef(null),S=u.useRef(new Map).current;return u.createElement(i,{scope:w,itemMap:S,collectionRef:T},E)},a=e+"CollectionSlot",c=u.forwardRef((p,w)=>{const{scope:E,children:T}=p,S=o(a,E),m=Qe(w,S.collectionRef);return u.createElement(no,{ref:m},T)}),l=e+"CollectionItemSlot",d="data-radix-collection-item",f=u.forwardRef((p,w)=>{const{scope:E,children:T,...S}=p,m=u.useRef(null),x=Qe(w,m),_=o(l,E);return u.useEffect(()=>(_.itemMap.set(m,{ref:m,...S}),()=>void _.itemMap.delete(m))),u.createElement(no,{[d]:"",ref:x},T)});function h(p){const w=o(e+"CollectionConsumer",p);return u.useCallback(()=>{const T=w.collectionRef.current;if(!T)return[];const S=Array.from(T.querySelectorAll(`[${d}]`));return Array.from(w.itemMap.values()).sort((_,$)=>S.indexOf(_.ref.current)-S.indexOf($.ref.current))},[w.collectionRef,w.itemMap])}return[{Provider:s,Slot:c,ItemSlot:f},h,r]}function De(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function qt(e){const t=u.useRef(e);return u.useEffect(()=>{t.current=e}),u.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}function pn({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,i]=Ty({defaultProp:t,onChange:n}),o=e!==void 0,s=o?e:r,a=qt(n),c=u.useCallback(l=>{if(o){const f=typeof l=="function"?l(e):l;f!==e&&a(f)}else i(l)},[o,e,i,a]);return[s,c]}function Ty({defaultProp:e,onChange:t}){const n=u.useState(e),[r]=n,i=u.useRef(r),o=qt(t);return u.useEffect(()=>{i.current!==r&&(o(r),i.current=r)},[r,i,o]),n}const Sy=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],He=Sy.reduce((e,t)=>{const n=u.forwardRef((r,i)=>{const{asChild:o,...s}=r,a=o?no:t;return u.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),u.createElement(a,ie({},s,{ref:i}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Vp(e,t){e&&fn.flushSync(()=>e.dispatchEvent(t))}const Wt=globalThis!=null&&globalThis.document?u.useLayoutEffect:()=>{};function $y(e,t){return u.useReducer((n,r)=>{const i=t[n][r];return i??n},e)}const hr=e=>{const{present:t,children:n}=e,r=Py(t),i=typeof n=="function"?n({present:r.isPresent}):u.Children.only(n),o=Qe(r.ref,i.ref);return typeof n=="function"||r.isPresent?u.cloneElement(i,{ref:o}):null};hr.displayName="Presence";function Py(e){const[t,n]=u.useState(),r=u.useRef({}),i=u.useRef(e),o=u.useRef("none"),s=e?"mounted":"unmounted",[a,c]=$y(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return u.useEffect(()=>{const l=li(r.current);o.current=a==="mounted"?l:"none"},[a]),Wt(()=>{const l=r.current,d=i.current;if(d!==e){const h=o.current,p=li(l);e?c("MOUNT"):p==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(d&&h!==p?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,c]),Wt(()=>{if(t){const l=f=>{const p=li(r.current).includes(f.animationName);f.target===t&&p&&fn.flushSync(()=>c("ANIMATION_END"))},d=f=>{f.target===t&&(o.current=li(r.current))};return t.addEventListener("animationstart",d),t.addEventListener("animationcancel",l),t.addEventListener("animationend",l),()=>{t.removeEventListener("animationstart",d),t.removeEventListener("animationcancel",l),t.removeEventListener("animationend",l)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:u.useCallback(l=>{l&&(r.current=getComputedStyle(l)),n(l)},[])}}function li(e){return(e==null?void 0:e.animationName)||"none"}const Ry=he["useId".toString()]||(()=>{});let Iy=0;function Bn(e){const[t,n]=he.useState(Ry());return Wt(()=>{e||n(r=>r??String(Iy++))},[e]),e||(t?`radix-${t}`:"")}const Lp="Collapsible",[Ay,Fp]=sn(Lp),[Dy,vc]=Ay(Lp),Oy=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:o,onOpenChange:s,...a}=e,[c=!1,l]=pn({prop:r,defaultProp:i,onChange:s});return u.createElement(Dy,{scope:n,disabled:o,contentId:Bn(),open:c,onOpenToggle:u.useCallback(()=>l(d=>!d),[l])},u.createElement(He.div,ie({"data-state":gc(c),"data-disabled":o?"":void 0},a,{ref:t})))}),My="CollapsibleTrigger",ky=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,i=vc(My,n);return u.createElement(He.button,ie({type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":gc(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled},r,{ref:t,onClick:De(e.onClick,i.onOpenToggle)}))}),Bp="CollapsibleContent",Ny=u.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=vc(Bp,e.__scopeCollapsible);return u.createElement(hr,{present:n||i.open},({present:o})=>u.createElement(jy,ie({},r,{ref:t,present:o})))}),jy=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:i,...o}=e,s=vc(Bp,n),[a,c]=u.useState(r),l=u.useRef(null),d=Qe(t,l),f=u.useRef(0),h=f.current,p=u.useRef(0),w=p.current,E=s.open||a,T=u.useRef(E),S=u.useRef();return u.useEffect(()=>{const m=requestAnimationFrame(()=>T.current=!1);return()=>cancelAnimationFrame(m)},[]),Wt(()=>{const m=l.current;if(m){S.current=S.current||{transitionDuration:m.style.transitionDuration,animationName:m.style.animationName},m.style.transitionDuration="0s",m.style.animationName="none";const x=m.getBoundingClientRect();f.current=x.height,p.current=x.width,T.current||(m.style.transitionDuration=S.current.transitionDuration,m.style.animationName=S.current.animationName),c(r)}},[s.open,r]),u.createElement(He.div,ie({"data-state":gc(s.open),"data-disabled":s.disabled?"":void 0,id:s.contentId,hidden:!E},o,{ref:d,style:{"--radix-collapsible-content-height":h?`${h}px`:void 0,"--radix-collapsible-content-width":w?`${w}px`:void 0,...e.style}}),E&&i)});function gc(e){return e?"open":"closed"}const Vy=Oy,Ly=ky,Fy=Ny,By=u.createContext(void 0);function is(e){const t=u.useContext(By);return e||t||"ltr"}const mr="Accordion",Hy=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[yc,Wy,Uy]=os(mr),[ss,vD]=sn(mr,[Uy,Fp]),bc=Fp(),Hp=u.forwardRef((e,t)=>{const{type:n,...r}=e,i=r,o=r;return u.createElement(yc.Provider,{scope:e.__scopeAccordion},n==="multiple"?u.createElement(qy,ie({},o,{ref:t})):u.createElement(Ky,ie({},i,{ref:t})))});Hp.propTypes={type(e){const t=e.value||e.defaultValue;return e.type&&!["single","multiple"].includes(e.type)?new Error("Invalid prop `type` supplied to `Accordion`. Expected one of `single | multiple`."):e.type==="multiple"&&typeof t=="string"?new Error("Invalid prop `type` supplied to `Accordion`. Expected `single` when `defaultValue` or `value` is type `string`."):e.type==="single"&&Array.isArray(t)?new Error("Invalid prop `type` supplied to `Accordion`. Expected `multiple` when `defaultValue` or `value` is type `string[]`."):null}};const[Wp,Yy]=ss(mr),[Up,zy]=ss(mr,{collapsible:!1}),Ky=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},collapsible:o=!1,...s}=e,[a,c]=pn({prop:n,defaultProp:r,onChange:i});return u.createElement(Wp,{scope:e.__scopeAccordion,value:a?[a]:[],onItemOpen:c,onItemClose:u.useCallback(()=>o&&c(""),[o,c])},u.createElement(Up,{scope:e.__scopeAccordion,collapsible:o},u.createElement(Yp,ie({},s,{ref:t}))))}),qy=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...o}=e,[s=[],a]=pn({prop:n,defaultProp:r,onChange:i}),c=u.useCallback(d=>a((f=[])=>[...f,d]),[a]),l=u.useCallback(d=>a((f=[])=>f.filter(h=>h!==d)),[a]);return u.createElement(Wp,{scope:e.__scopeAccordion,value:s,onItemOpen:c,onItemClose:l},u.createElement(Up,{scope:e.__scopeAccordion,collapsible:!0},u.createElement(Yp,ie({},o,{ref:t}))))}),[Xy,as]=ss(mr),Yp=u.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:r,dir:i,orientation:o="vertical",...s}=e,a=u.useRef(null),c=Qe(a,t),l=Wy(n),f=is(i)==="ltr",h=De(e.onKeyDown,p=>{var w;if(!Hy.includes(p.key))return;const E=p.target,T=l().filter(j=>{var K;return!((K=j.ref.current)!==null&&K!==void 0&&K.disabled)}),S=T.findIndex(j=>j.ref.current===E),m=T.length;if(S===-1)return;p.preventDefault();let x=S;const _=0,$=m-1,O=()=>{x=S+1,x>$&&(x=_)},M=()=>{x=S-1,x<_&&(x=$)};switch(p.key){case"Home":x=_;break;case"End":x=$;break;case"ArrowRight":o==="horizontal"&&(f?O():M());break;case"ArrowDown":o==="vertical"&&O();break;case"ArrowLeft":o==="horizontal"&&(f?M():O());break;case"ArrowUp":o==="vertical"&&M();break}const N=x%m;(w=T[N].ref.current)===null||w===void 0||w.focus()});return u.createElement(Xy,{scope:n,disabled:r,direction:i,orientation:o},u.createElement(yc.Slot,{scope:n},u.createElement(He.div,ie({},s,{"data-orientation":o,ref:c,onKeyDown:r?void 0:h}))))}),Ma="AccordionItem",[Gy,wc]=ss(Ma),Zy=u.forwardRef((e,t)=>{const{__scopeAccordion:n,value:r,...i}=e,o=as(Ma,n),s=Yy(Ma,n),a=bc(n),c=Bn(),l=r&&s.value.includes(r)||!1,d=o.disabled||e.disabled;return u.createElement(Gy,{scope:n,open:l,disabled:d,triggerId:c},u.createElement(Vy,ie({"data-orientation":o.orientation,"data-state":zp(l)},a,i,{ref:t,disabled:d,open:l,onOpenChange:f=>{f?s.onItemOpen(r):s.onItemClose(r)}})))}),Qy="AccordionHeader",Jy=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,i=as(mr,n),o=wc(Qy,n);return u.createElement(He.h3,ie({"data-orientation":i.orientation,"data-state":zp(o.open),"data-disabled":o.disabled?"":void 0},r,{ref:t}))}),Lu="AccordionTrigger",e0=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,i=as(mr,n),o=wc(Lu,n),s=zy(Lu,n),a=bc(n);return u.createElement(yc.ItemSlot,{scope:n},u.createElement(Ly,ie({"aria-disabled":o.open&&!s.collapsible||void 0,"data-orientation":i.orientation,id:o.triggerId},a,r,{ref:t})))}),t0="AccordionContent",n0=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,i=as(mr,n),o=wc(t0,n),s=bc(n);return u.createElement(Fy,ie({role:"region","aria-labelledby":o.triggerId,"data-orientation":i.orientation},s,r,{ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}}))});function zp(e){return e?"open":"closed"}const r0=Hp,o0=Zy,i0=Jy,s0=e0,a0=n0;function Kp(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=Kp(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Re(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=Kp(e))&&(r&&(r+=" "),r+=t);return r}const c0=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(r0,{className:Re("accordion-root",t),...n,ref:r,children:e})),Gs=(e,t)=>{const n=Object.values(e).map(r=>r[t]);return n.every(r=>typeof r=="string")?n.join(" ").trim():n.reduce((r,i)=>Object.assign(r,i),{})},l0=(e,t)=>{const r=Object.keys(e).map(o=>e[o].properties).reduce((o,s)=>new Set([...Array.from(o),...Array.from(s)]),new Set),i={};return Object.keys(t).forEach(o=>{r.has(o)||(i[o]=t[o])}),i},cs=(e,t,n)=>{const i=[...Object.keys(e).map(l=>e[l](t)),...n??[]],o=Gs(i,"className"),s=Gs(i,"otherProps"),a=Gs(i,"style");return{otherProps:l0(e,s),className:o,style:a}},{backgroundAtoms:u0,borderAtoms:d0,commonAtoms:Fu,flexAtoms:Bu,positionAtoms:f0,radiiAtoms:p0,shadowAtoms:h0,sizesAtoms:m0,spaceAtoms:v0,typographyAtoms:g0}=Et.atoms,ht=u.forwardRef(({as:e,children:t,id:n,className:r,isDisabled:i,isColumn:o,...s},a)=>{const c=e||"div",l=Fu({display:o?"flex":s.display}),d=Bu({flexWrap:o?"wrap":s.flexWrap}),{className:f,otherProps:h,style:p}=cs({commonAtoms:Fu,flexAtoms:Bu,positionAtoms:f0,spaceAtoms:v0,sizesAtoms:m0,borderAtoms:d0,typographyAtoms:g0,radiiAtoms:p0,backgroundAtoms:u0,shadowAtoms:h0},s,[l,d]);return D.jsx(c,{ref:a,className:Re(f,r),disabled:i,style:p,...h,children:t})});ht.displayName="Box";ht.defaultProps={id:"base",as:"div",className:void 0,isDisabled:void 0,"data-test-id":void 0,isColumn:!1};const xc=({children:e,withShadow:t,bgColor:n,...r})=>D.jsx(ht,{boxShadow:t?"$raised":"$none",bgColor:"$white",...r,children:e});xc.displayName="Card";xc.defaultProps={withShadow:!1};var y0="ifvo3u0";const{sizesAtoms:Hu,spaceAtoms:Wu,commonAtoms:Uu,flexAtoms:b0}=Et.atoms,Ec=({children:e,isFluid:t,className:n,display:r,...i})=>{const s=Hu({width:"$full",maxW:t?"$full":"$lg"}),a=Wu({mx:"$auto",my:"$0"}),c=Uu({display:r}),{className:l,style:d}=cs({flexAtoms:b0,sizesAtoms:Hu,spaceAtoms:Wu,commonAtoms:Uu},i,[s,a,c]);return D.jsx("div",{className:Re("vds-container",!t&&y0,l,n),style:d,...i,children:e})};Ec.displayName="Container";Ec.defaultProps={display:"block",children:null,isFluid:!1,className:void 0};const{commonAtoms:Yu,spaceAtoms:w0,sizesAtoms:x0,radiiAtoms:E0,flexAtoms:C0,backgroundAtoms:_0}=Et.atoms,Lt=u.forwardRef(({as:e,children:t,id:n,className:r,...i},o)=>{const s=e||"div",a=Yu({display:"flex"}),{className:c,otherProps:l,style:d}=cs({flexAtoms:C0,commonAtoms:Yu,spaceAtoms:w0,sizesAtoms:x0,radiiAtoms:E0,backgroundAtoms:_0},i,[a]);return D.jsx(s,{"data-test-id":i["data-test-id"],ref:o,className:Re(c,r),style:d,...l,children:t})});Lt.defaultProps={id:"base",as:"div",className:void 0,"data-test-id":void 0};Lt.displayName="Flex";const{gridAtoms:T0,commonAtoms:S0,spaceAtoms:$0,sizesAtoms:P0,radiiAtoms:R0}=Et.atoms,Cc=u.forwardRef(({as:e,children:t,id:n,className:r,...i},o)=>{const s=e||"div",a=Et.atoms.commonAtoms({display:"grid"}),{className:c,otherProps:l,style:d}=cs({gridAtoms:T0,commonAtoms:S0,spaceAtoms:$0,sizesAtoms:P0,radiiAtoms:R0},i,[a]);return D.jsx(s,{"data-test-id":i["data-test-id"],ref:o,className:Re(c,r),style:d,...l,children:t})});Cc.displayName="Grid";Cc.defaultProps={id:"base",as:"div",className:void 0,"data-test-id":void 0};const I0={horizontal:"row",vertical:"column",horizontalReverse:"row-reverse",verticalReverse:"column-reverse"},A0=e=>e?I0[e]:void 0,zu={1:"wrap",0:"nowrap"},D0=e=>e?typeof e=="boolean"?zu[1]:zu[0]:void 0,Ir=u.forwardRef(({as:e="div",alignItems:t,children:n,justifyContent:r,direction:i,gap:o,wrap:s=!0,content:a,...c},l)=>{const d=A0(i),f=D0(s);return D.jsx(Lt,{ref:l,"data-test-id":c["data-test-id"],alignItems:t,display:"flex",as:e,direction:d,wrap:f,gap:o,justifyContent:r,...c,children:n})});Ir.defaultProps={as:"div",alignItems:void 0,direction:"vertical",justifyContent:void 0,gap:"4",wrap:!0,"data-test-id":void 0};Ir.displayName="Stack";function O0(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ku(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ku(Object(n),!0).forEach(function(r){O0(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ku(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var M0=(e,t,n)=>{for(var r of Object.keys(e)){var i;if(e[r]!==((i=t[r])!==null&&i!==void 0?i:n[r]))return!1}return!0},ft=e=>t=>{var n=e.defaultClassName,r=qu(qu({},e.defaultVariants),t);for(var i in r){var o,s=(o=r[i])!==null&&o!==void 0?o:e.defaultVariants[i];if(s!=null){var a=s;typeof a=="boolean"&&(a=a===!0?"true":"false");var c=e.variantClassNames[i][a];c&&(n+=" "+c)}}for(var[l,d]of e.compoundVariants)M0(l,r,e.defaultVariants)&&(n+=" "+d);return n},k0=ft({defaultClassName:"",variantClassNames:{textStyle:{heading1:"_1ccbe2w0",heading2:"_1ccbe2w1",heading3:"_1ccbe2w2",heading4:"_1ccbe2w3",heading5:"_1ccbe2w4",heading6:"_1ccbe2w5",subheading1:"_1ccbe2w6",subheading2:"_1ccbe2w7",subtitle1:"_1ccbe2w8",subtitle2:"_1ccbe2w9",body1:"_1ccbe2wa",body2:"_1ccbe2wb",caption:"_1ccbe2wc",footer:"_1ccbe2wd"},isStrikethrough:{true:"_1ccbe2we"}},defaultVariants:{},compoundVariants:[]});const Kt=u.forwardRef(({as:e="p",children:t,textStyle:n,isStrikethrough:r,className:i,...o},s)=>D.jsx(ht,{as:e,ref:s,className:Re(k0({textStyle:n,isStrikethrough:r}),i),...o,children:t}));Kt.displayName="Text";Kt.defaultProps={as:"p"};var N0="_13vyt6x7",j0="_13vyt6x5",V0="_13vyt6x6",L0="_13vyt6x2",F0="_13vyt6x3",B0="_13vyt6x4";const H0=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(a0,{className:Re(j0,t),...n,ref:r,children:D.jsx(ht,{className:V0,children:e})})),W0=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(o0,{className:Re(L0,t),...n,ref:r,children:e}));var ka={exports:{}},xo={};/**
|
|
27
|
+
Check the top-level render call using <`+Q+">.")}return F}}function Cn(b,F){{if(!b._store||b._store.validated||b.key!=null)return;b._store.validated=!0;var Q=Zn(F);if(Gn[Q])return;Gn[Q]=!0;var fe="";b&&b._owner&&b._owner!==Qt.current&&(fe=" It was passed a child from "+v(b._owner.type)+"."),jt(b),m('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',Q,fe),jt(null)}}function cn(b,F){{if(typeof b!="object")return;if(Rt(b))for(var Q=0;Q<b.length;Q++){var fe=b[Q];En(fe)&&Cn(fe,F)}else if(En(b))b._store&&(b._store.validated=!0);else if(b){var xe=T(b);if(typeof xe=="function"&&xe!==b.entries)for(var Se=xe.call(b),be;!(be=Se.next()).done;)En(be.value)&&Cn(be.value,F)}}}function Qn(b){{var F=b.type;if(F==null||typeof F=="string")return;var Q;if(typeof F=="function")Q=F.propTypes;else if(typeof F=="object"&&(F.$$typeof===c||F.$$typeof===f))Q=F.propTypes;else return;if(Q){var fe=v(F);vt(Q,b.props,"prop",fe,b)}else if(F.PropTypes!==void 0&&!xn){xn=!0;var xe=v(F);m("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",xe||"Unknown")}typeof F.getDefaultProps=="function"&&!F.getDefaultProps.isReactClassApproved&&m("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Mn(b){{for(var F=Object.keys(b.props),Q=0;Q<F.length;Q++){var fe=F[Q];if(fe!=="children"&&fe!=="key"){jt(b),m("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",fe),jt(null);break}}b.ref!==null&&(jt(b),m("Invalid attribute `ref` supplied to `React.Fragment`."),jt(null))}}function vn(b,F,Q,fe,xe,Se){{var be=K(b);if(!be){var ye="";(b===void 0||typeof b=="object"&&b!==null&&Object.keys(b).length===0)&&(ye+=" 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 Ge=vo(xe);Ge?ye+=Ge:ye+=Xn();var Ne;b===null?Ne="null":Rt(b)?Ne="array":b!==void 0&&b.$$typeof===t?(Ne="<"+(v(b.type)||"Unknown")+" />",ye=" Did you accidentally export a JSX literal instead of a component?"):Ne=typeof b,m("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Ne,ye)}var Le=Br(b,F,Q,xe,Se);if(Le==null)return Le;if(be){var Ue=F.children;if(Ue!==void 0)if(fe)if(Rt(Ue)){for(var Bt=0;Bt<Ue.length;Bt++)cn(Ue[Bt],b);Object.freeze&&Object.freeze(Ue)}else m("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 cn(Ue,b)}return b===r?Mn(Le):Qn(Le),Le}}function _n(b,F,Q){return vn(b,F,Q,!0)}function Jn(b,F,Q){return vn(b,F,Q,!1)}var Vt=Jn,er=_n;wo.Fragment=r,wo.jsx=Vt,wo.jsxs=er}()),wo}process.env.NODE_ENV==="production"?Da.exports=by():Da.exports=wy();var O=Da.exports;function ie(){return ie=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},ie.apply(this,arguments)}function sn(e,t=[]){let n=[];function r(o,s){const a=u.createContext(s),c=n.length;n=[...n,s];function l(f){const{scope:h,children:p,...y}=f,E=(h==null?void 0:h[e][c])||a,T=u.useMemo(()=>y,Object.values(y));return u.createElement(E.Provider,{value:T},p)}function d(f,h){const p=(h==null?void 0:h[e][c])||a,y=u.useContext(p);if(y)return y;if(s!==void 0)return s;throw new Error(`\`${f}\` must be used within \`${o}\``)}return l.displayName=o+"Provider",[l,d]}const i=()=>{const o=n.map(s=>u.createContext(s));return function(a){const c=(a==null?void 0:a[e])||o;return u.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return i.scopeName=e,[r,xy(i,...t)]}function xy(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const s=r.reduce((a,{useScope:c,scopeName:l})=>{const f=c(o)[`__scope${l}`];return{...a,...f}},{});return u.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function Ey(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Np(...e){return t=>e.forEach(n=>Ey(n,t))}function Qe(...e){return u.useCallback(Np(...e),e)}const no=u.forwardRef((e,t)=>{const{children:n,...r}=e,i=u.Children.toArray(n),o=i.find(Cy);if(o){const s=o.props.children,a=i.map(c=>c===o?u.Children.count(s)>1?u.Children.only(null):u.isValidElement(s)?s.props.children:null:c);return u.createElement(Oa,ie({},r,{ref:t}),u.isValidElement(s)?u.cloneElement(s,void 0,a):null)}return u.createElement(Oa,ie({},r,{ref:t}),n)});no.displayName="Slot";const Oa=u.forwardRef((e,t)=>{const{children:n,...r}=e;return u.isValidElement(n)?u.cloneElement(n,{..._y(r,n.props),ref:t?Np(t,n.ref):n.ref}):u.Children.count(n)>1?u.Children.only(null):null});Oa.displayName="SlotClone";const jp=({children:e})=>u.createElement(u.Fragment,null,e);function Cy(e){return u.isValidElement(e)&&e.type===jp}function _y(e,t){const n={...t};for(const r in t){const i=e[r],o=t[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...a)=>{o(...a),i(...a)}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...e,...n}}function os(e){const t=e+"CollectionProvider",[n,r]=sn(t),[i,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=p=>{const{scope:y,children:E}=p,T=u.useRef(null),S=u.useRef(new Map).current;return u.createElement(i,{scope:y,itemMap:S,collectionRef:T},E)},a=e+"CollectionSlot",c=u.forwardRef((p,y)=>{const{scope:E,children:T}=p,S=o(a,E),m=Qe(y,S.collectionRef);return u.createElement(no,{ref:m},T)}),l=e+"CollectionItemSlot",d="data-radix-collection-item",f=u.forwardRef((p,y)=>{const{scope:E,children:T,...S}=p,m=u.useRef(null),x=Qe(y,m),_=o(l,E);return u.useEffect(()=>(_.itemMap.set(m,{ref:m,...S}),()=>void _.itemMap.delete(m))),u.createElement(no,{[d]:"",ref:x},T)});function h(p){const y=o(e+"CollectionConsumer",p);return u.useCallback(()=>{const T=y.collectionRef.current;if(!T)return[];const S=Array.from(T.querySelectorAll(`[${d}]`));return Array.from(y.itemMap.values()).sort((_,$)=>S.indexOf(_.ref.current)-S.indexOf($.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:s,Slot:c,ItemSlot:f},h,r]}function De(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e==null||e(i),n===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function qt(e){const t=u.useRef(e);return u.useEffect(()=>{t.current=e}),u.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}function pn({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,i]=Ty({defaultProp:t,onChange:n}),o=e!==void 0,s=o?e:r,a=qt(n),c=u.useCallback(l=>{if(o){const f=typeof l=="function"?l(e):l;f!==e&&a(f)}else i(l)},[o,e,i,a]);return[s,c]}function Ty({defaultProp:e,onChange:t}){const n=u.useState(e),[r]=n,i=u.useRef(r),o=qt(t);return u.useEffect(()=>{i.current!==r&&(o(r),i.current=r)},[r,i,o]),n}const Sy=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],He=Sy.reduce((e,t)=>{const n=u.forwardRef((r,i)=>{const{asChild:o,...s}=r,a=o?no:t;return u.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),u.createElement(a,ie({},s,{ref:i}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Vp(e,t){e&&fn.flushSync(()=>e.dispatchEvent(t))}const Wt=globalThis!=null&&globalThis.document?u.useLayoutEffect:()=>{};function $y(e,t){return u.useReducer((n,r)=>{const i=t[n][r];return i??n},e)}const hr=e=>{const{present:t,children:n}=e,r=Py(t),i=typeof n=="function"?n({present:r.isPresent}):u.Children.only(n),o=Qe(r.ref,i.ref);return typeof n=="function"||r.isPresent?u.cloneElement(i,{ref:o}):null};hr.displayName="Presence";function Py(e){const[t,n]=u.useState(),r=u.useRef({}),i=u.useRef(e),o=u.useRef("none"),s=e?"mounted":"unmounted",[a,c]=$y(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return u.useEffect(()=>{const l=li(r.current);o.current=a==="mounted"?l:"none"},[a]),Wt(()=>{const l=r.current,d=i.current;if(d!==e){const h=o.current,p=li(l);e?c("MOUNT"):p==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(d&&h!==p?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,c]),Wt(()=>{if(t){const l=f=>{const p=li(r.current).includes(f.animationName);f.target===t&&p&&fn.flushSync(()=>c("ANIMATION_END"))},d=f=>{f.target===t&&(o.current=li(r.current))};return t.addEventListener("animationstart",d),t.addEventListener("animationcancel",l),t.addEventListener("animationend",l),()=>{t.removeEventListener("animationstart",d),t.removeEventListener("animationcancel",l),t.removeEventListener("animationend",l)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:u.useCallback(l=>{l&&(r.current=getComputedStyle(l)),n(l)},[])}}function li(e){return(e==null?void 0:e.animationName)||"none"}const Ry=he["useId".toString()]||(()=>{});let Iy=0;function Bn(e){const[t,n]=he.useState(Ry());return Wt(()=>{e||n(r=>r??String(Iy++))},[e]),e||(t?`radix-${t}`:"")}const Lp="Collapsible",[Ay,Fp]=sn(Lp),[Dy,vc]=Ay(Lp),Oy=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:o,onOpenChange:s,...a}=e,[c=!1,l]=pn({prop:r,defaultProp:i,onChange:s});return u.createElement(Dy,{scope:n,disabled:o,contentId:Bn(),open:c,onOpenToggle:u.useCallback(()=>l(d=>!d),[l])},u.createElement(He.div,ie({"data-state":gc(c),"data-disabled":o?"":void 0},a,{ref:t})))}),My="CollapsibleTrigger",ky=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,i=vc(My,n);return u.createElement(He.button,ie({type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":gc(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled},r,{ref:t,onClick:De(e.onClick,i.onOpenToggle)}))}),Bp="CollapsibleContent",Ny=u.forwardRef((e,t)=>{const{forceMount:n,...r}=e,i=vc(Bp,e.__scopeCollapsible);return u.createElement(hr,{present:n||i.open},({present:o})=>u.createElement(jy,ie({},r,{ref:t,present:o})))}),jy=u.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:i,...o}=e,s=vc(Bp,n),[a,c]=u.useState(r),l=u.useRef(null),d=Qe(t,l),f=u.useRef(0),h=f.current,p=u.useRef(0),y=p.current,E=s.open||a,T=u.useRef(E),S=u.useRef();return u.useEffect(()=>{const m=requestAnimationFrame(()=>T.current=!1);return()=>cancelAnimationFrame(m)},[]),Wt(()=>{const m=l.current;if(m){S.current=S.current||{transitionDuration:m.style.transitionDuration,animationName:m.style.animationName},m.style.transitionDuration="0s",m.style.animationName="none";const x=m.getBoundingClientRect();f.current=x.height,p.current=x.width,T.current||(m.style.transitionDuration=S.current.transitionDuration,m.style.animationName=S.current.animationName),c(r)}},[s.open,r]),u.createElement(He.div,ie({"data-state":gc(s.open),"data-disabled":s.disabled?"":void 0,id:s.contentId,hidden:!E},o,{ref:d,style:{"--radix-collapsible-content-height":h?`${h}px`:void 0,"--radix-collapsible-content-width":y?`${y}px`:void 0,...e.style}}),E&&i)});function gc(e){return e?"open":"closed"}const Vy=Oy,Ly=ky,Fy=Ny,By=u.createContext(void 0);function is(e){const t=u.useContext(By);return e||t||"ltr"}const mr="Accordion",Hy=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[yc,Wy,Uy]=os(mr),[ss,vD]=sn(mr,[Uy,Fp]),bc=Fp(),Hp=u.forwardRef((e,t)=>{const{type:n,...r}=e,i=r,o=r;return u.createElement(yc.Provider,{scope:e.__scopeAccordion},n==="multiple"?u.createElement(qy,ie({},o,{ref:t})):u.createElement(Ky,ie({},i,{ref:t})))});Hp.propTypes={type(e){const t=e.value||e.defaultValue;return e.type&&!["single","multiple"].includes(e.type)?new Error("Invalid prop `type` supplied to `Accordion`. Expected one of `single | multiple`."):e.type==="multiple"&&typeof t=="string"?new Error("Invalid prop `type` supplied to `Accordion`. Expected `single` when `defaultValue` or `value` is type `string`."):e.type==="single"&&Array.isArray(t)?new Error("Invalid prop `type` supplied to `Accordion`. Expected `multiple` when `defaultValue` or `value` is type `string[]`."):null}};const[Wp,Yy]=ss(mr),[Up,zy]=ss(mr,{collapsible:!1}),Ky=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},collapsible:o=!1,...s}=e,[a,c]=pn({prop:n,defaultProp:r,onChange:i});return u.createElement(Wp,{scope:e.__scopeAccordion,value:a?[a]:[],onItemOpen:c,onItemClose:u.useCallback(()=>o&&c(""),[o,c])},u.createElement(Up,{scope:e.__scopeAccordion,collapsible:o},u.createElement(Yp,ie({},s,{ref:t}))))}),qy=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...o}=e,[s=[],a]=pn({prop:n,defaultProp:r,onChange:i}),c=u.useCallback(d=>a((f=[])=>[...f,d]),[a]),l=u.useCallback(d=>a((f=[])=>f.filter(h=>h!==d)),[a]);return u.createElement(Wp,{scope:e.__scopeAccordion,value:s,onItemOpen:c,onItemClose:l},u.createElement(Up,{scope:e.__scopeAccordion,collapsible:!0},u.createElement(Yp,ie({},o,{ref:t}))))}),[Xy,as]=ss(mr),Yp=u.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:r,dir:i,orientation:o="vertical",...s}=e,a=u.useRef(null),c=Qe(a,t),l=Wy(n),f=is(i)==="ltr",h=De(e.onKeyDown,p=>{var y;if(!Hy.includes(p.key))return;const E=p.target,T=l().filter(j=>{var K;return!((K=j.ref.current)!==null&&K!==void 0&&K.disabled)}),S=T.findIndex(j=>j.ref.current===E),m=T.length;if(S===-1)return;p.preventDefault();let x=S;const _=0,$=m-1,M=()=>{x=S+1,x>$&&(x=_)},D=()=>{x=S-1,x<_&&(x=$)};switch(p.key){case"Home":x=_;break;case"End":x=$;break;case"ArrowRight":o==="horizontal"&&(f?M():D());break;case"ArrowDown":o==="vertical"&&M();break;case"ArrowLeft":o==="horizontal"&&(f?D():M());break;case"ArrowUp":o==="vertical"&&D();break}const N=x%m;(y=T[N].ref.current)===null||y===void 0||y.focus()});return u.createElement(Xy,{scope:n,disabled:r,direction:i,orientation:o},u.createElement(yc.Slot,{scope:n},u.createElement(He.div,ie({},s,{"data-orientation":o,ref:c,onKeyDown:r?void 0:h}))))}),Ma="AccordionItem",[Gy,wc]=ss(Ma),Zy=u.forwardRef((e,t)=>{const{__scopeAccordion:n,value:r,...i}=e,o=as(Ma,n),s=Yy(Ma,n),a=bc(n),c=Bn(),l=r&&s.value.includes(r)||!1,d=o.disabled||e.disabled;return u.createElement(Gy,{scope:n,open:l,disabled:d,triggerId:c},u.createElement(Vy,ie({"data-orientation":o.orientation,"data-state":zp(l)},a,i,{ref:t,disabled:d,open:l,onOpenChange:f=>{f?s.onItemOpen(r):s.onItemClose(r)}})))}),Qy="AccordionHeader",Jy=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,i=as(mr,n),o=wc(Qy,n);return u.createElement(He.h3,ie({"data-orientation":i.orientation,"data-state":zp(o.open),"data-disabled":o.disabled?"":void 0},r,{ref:t}))}),Lu="AccordionTrigger",e0=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,i=as(mr,n),o=wc(Lu,n),s=zy(Lu,n),a=bc(n);return u.createElement(yc.ItemSlot,{scope:n},u.createElement(Ly,ie({"aria-disabled":o.open&&!s.collapsible||void 0,"data-orientation":i.orientation,id:o.triggerId},a,r,{ref:t})))}),t0="AccordionContent",n0=u.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,i=as(mr,n),o=wc(t0,n),s=bc(n);return u.createElement(Fy,ie({role:"region","aria-labelledby":o.triggerId,"data-orientation":i.orientation},s,r,{ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}}))});function zp(e){return e?"open":"closed"}const r0=Hp,o0=Zy,i0=Jy,s0=e0,a0=n0;function Kp(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=Kp(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Re(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=Kp(e))&&(r&&(r+=" "),r+=t);return r}const c0=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(r0,{className:Re("accordion-root",t),...n,ref:r,children:e})),Gs=(e,t)=>{const n=Object.values(e).map(r=>r[t]);return n.every(r=>typeof r=="string")?n.join(" ").trim():n.reduce((r,i)=>Object.assign(r,i),{})},l0=(e,t)=>{const r=Object.keys(e).map(o=>e[o].properties).reduce((o,s)=>new Set([...Array.from(o),...Array.from(s)]),new Set),i={};return Object.keys(t).forEach(o=>{r.has(o)||(i[o]=t[o])}),i},cs=(e,t,n)=>{const i=[...Object.keys(e).map(l=>e[l](t)),...n??[]],o=Gs(i,"className"),s=Gs(i,"otherProps"),a=Gs(i,"style");return{otherProps:l0(e,s),className:o,style:a}},{backgroundAtoms:u0,borderAtoms:d0,commonAtoms:Fu,flexAtoms:Bu,positionAtoms:f0,radiiAtoms:p0,shadowAtoms:h0,sizesAtoms:m0,spaceAtoms:v0,typographyAtoms:g0}=Et.atoms,ht=u.forwardRef(({as:e,children:t,id:n,className:r,isDisabled:i,isColumn:o,...s},a)=>{const c=e||"div",l=Fu({display:o?"flex":s.display}),d=Bu({flexWrap:o?"wrap":s.flexWrap}),{className:f,otherProps:h,style:p}=cs({commonAtoms:Fu,flexAtoms:Bu,positionAtoms:f0,spaceAtoms:v0,sizesAtoms:m0,borderAtoms:d0,typographyAtoms:g0,radiiAtoms:p0,backgroundAtoms:u0,shadowAtoms:h0},s,[l,d]);return O.jsx(c,{ref:a,className:Re(f,r),disabled:i,style:p,...h,children:t})});ht.displayName="Box";ht.defaultProps={id:"base",as:"div",className:void 0,isDisabled:void 0,"data-test-id":void 0,isColumn:!1};const xc=({children:e,withShadow:t,bgColor:n,...r})=>O.jsx(ht,{boxShadow:t?"$raised":"$none",bgColor:"$white",...r,children:e});xc.displayName="Card";xc.defaultProps={withShadow:!1};var y0="ifvo3u0";const{sizesAtoms:Hu,spaceAtoms:Wu,commonAtoms:Uu,flexAtoms:b0}=Et.atoms,Ec=({children:e,isFluid:t,className:n,display:r,...i})=>{const s=Hu({width:"$full",maxW:t?"$full":"$lg"}),a=Wu({mx:"$auto",my:"$0"}),c=Uu({display:r}),{className:l,style:d}=cs({flexAtoms:b0,sizesAtoms:Hu,spaceAtoms:Wu,commonAtoms:Uu},i,[s,a,c]);return O.jsx("div",{className:Re("vds-container",!t&&y0,l,n),style:d,...i,children:e})};Ec.displayName="Container";Ec.defaultProps={display:"block",children:null,isFluid:!1,className:void 0};const{commonAtoms:Yu,spaceAtoms:w0,sizesAtoms:x0,radiiAtoms:E0,flexAtoms:C0,backgroundAtoms:_0}=Et.atoms,Lt=u.forwardRef(({as:e,children:t,id:n,className:r,...i},o)=>{const s=e||"div",a=Yu({display:"flex"}),{className:c,otherProps:l,style:d}=cs({flexAtoms:C0,commonAtoms:Yu,spaceAtoms:w0,sizesAtoms:x0,radiiAtoms:E0,backgroundAtoms:_0},i,[a]);return O.jsx(s,{"data-test-id":i["data-test-id"],ref:o,className:Re(c,r),style:d,...l,children:t})});Lt.defaultProps={id:"base",as:"div",className:void 0,"data-test-id":void 0};Lt.displayName="Flex";const{gridAtoms:T0,commonAtoms:S0,spaceAtoms:$0,sizesAtoms:P0,radiiAtoms:R0}=Et.atoms,Cc=u.forwardRef(({as:e,children:t,id:n,className:r,...i},o)=>{const s=e||"div",a=Et.atoms.commonAtoms({display:"grid"}),{className:c,otherProps:l,style:d}=cs({gridAtoms:T0,commonAtoms:S0,spaceAtoms:$0,sizesAtoms:P0,radiiAtoms:R0},i,[a]);return O.jsx(s,{"data-test-id":i["data-test-id"],ref:o,className:Re(c,r),style:d,...l,children:t})});Cc.displayName="Grid";Cc.defaultProps={id:"base",as:"div",className:void 0,"data-test-id":void 0};const I0={horizontal:"row",vertical:"column",horizontalReverse:"row-reverse",verticalReverse:"column-reverse"},A0=e=>e?I0[e]:void 0,zu={1:"wrap",0:"nowrap"},D0=e=>e?typeof e=="boolean"?zu[1]:zu[0]:void 0,Ir=u.forwardRef(({as:e="div",alignItems:t,children:n,justifyContent:r,direction:i,gap:o,wrap:s=!0,content:a,...c},l)=>{const d=A0(i),f=D0(s);return O.jsx(Lt,{ref:l,"data-test-id":c["data-test-id"],alignItems:t,display:"flex",as:e,direction:d,wrap:f,gap:o,justifyContent:r,...c,children:n})});Ir.defaultProps={as:"div",alignItems:void 0,direction:"vertical",justifyContent:void 0,gap:"4",wrap:!0,"data-test-id":void 0};Ir.displayName="Stack";function O0(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ku(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qu(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ku(Object(n),!0).forEach(function(r){O0(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ku(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var M0=(e,t,n)=>{for(var r of Object.keys(e)){var i;if(e[r]!==((i=t[r])!==null&&i!==void 0?i:n[r]))return!1}return!0},ft=e=>t=>{var n=e.defaultClassName,r=qu(qu({},e.defaultVariants),t);for(var i in r){var o,s=(o=r[i])!==null&&o!==void 0?o:e.defaultVariants[i];if(s!=null){var a=s;typeof a=="boolean"&&(a=a===!0?"true":"false");var c=e.variantClassNames[i][a];c&&(n+=" "+c)}}for(var[l,d]of e.compoundVariants)M0(l,r,e.defaultVariants)&&(n+=" "+d);return n},k0=ft({defaultClassName:"",variantClassNames:{textStyle:{heading1:"_1ccbe2w0",heading2:"_1ccbe2w1",heading3:"_1ccbe2w2",heading4:"_1ccbe2w3",heading5:"_1ccbe2w4",heading6:"_1ccbe2w5",subheading1:"_1ccbe2w6",subheading2:"_1ccbe2w7",subtitle1:"_1ccbe2w8",subtitle2:"_1ccbe2w9",body1:"_1ccbe2wa",body2:"_1ccbe2wb",caption:"_1ccbe2wc",footer:"_1ccbe2wd"},isStrikethrough:{true:"_1ccbe2we"}},defaultVariants:{},compoundVariants:[]});const Kt=u.forwardRef(({as:e="p",children:t,textStyle:n,isStrikethrough:r,className:i,...o},s)=>O.jsx(ht,{as:e,ref:s,className:Re(k0({textStyle:n,isStrikethrough:r}),i),...o,children:t}));Kt.displayName="Text";Kt.defaultProps={as:"p"};var N0="_13vyt6x7",j0="_13vyt6x5",V0="_13vyt6x6",L0="_13vyt6x2",F0="_13vyt6x3",B0="_13vyt6x4";const H0=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(a0,{className:Re(j0,t),...n,ref:r,children:O.jsx(ht,{className:V0,children:e})})),W0=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(o0,{className:Re(L0,t),...n,ref:r,children:e}));var ka={exports:{}},xo={};/**
|
|
28
28
|
* @license React
|
|
29
29
|
* react-jsx-runtime.production.min.js
|
|
30
30
|
*
|
|
@@ -40,17 +40,17 @@ Check the top-level render call using <`+Q+">.")}return F}}function Cn(y,F){{if(
|
|
|
40
40
|
*
|
|
41
41
|
* This source code is licensed under the MIT license found in the
|
|
42
42
|
* LICENSE file in the root directory of this source tree.
|
|
43
|
-
*/var Gu;function Y0(){return Gu||(Gu=1,process.env.NODE_ENV!=="production"&&function(){var e=u,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),
|
|
44
|
-
`+B+
|
|
43
|
+
*/var Gu;function Y0(){return Gu||(Gu=1,process.env.NODE_ENV!=="production"&&function(){var e=u,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),a=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),y=Symbol.iterator,E="@@iterator";function T(b){if(b===null||typeof b!="object")return null;var F=y&&b[y]||b[E];return typeof F=="function"?F:null}var S=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function m(b){{for(var F=arguments.length,Q=new Array(F>1?F-1:0),fe=1;fe<F;fe++)Q[fe-1]=arguments[fe];x("error",b,Q)}}function x(b,F,Q){{var fe=S.ReactDebugCurrentFrame,xe=fe.getStackAddendum();xe!==""&&(F+="%s",Q=Q.concat([xe]));var Se=Q.map(function(be){return String(be)});Se.unshift("Warning: "+F),Function.prototype.apply.call(console[b],console,Se)}}var _=!1,$=!1,M=!1,D=!1,N=!1,j;j=Symbol.for("react.module.reference");function K(b){return!!(typeof b=="string"||typeof b=="function"||b===r||b===o||N||b===i||b===l||b===d||D||b===p||_||$||M||typeof b=="object"&&b!==null&&(b.$$typeof===h||b.$$typeof===f||b.$$typeof===s||b.$$typeof===a||b.$$typeof===c||b.$$typeof===j||b.getModuleId!==void 0))}function V(b,F,Q){var fe=b.displayName;if(fe)return fe;var xe=F.displayName||F.name||"";return xe!==""?Q+"("+xe+")":Q}function P(b){return b.displayName||"Context"}function v(b){if(b==null)return null;if(typeof b.tag=="number"&&m("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof b=="function")return b.displayName||b.name||null;if(typeof b=="string")return b;switch(b){case r:return"Fragment";case n:return"Portal";case o:return"Profiler";case i:return"StrictMode";case l:return"Suspense";case d:return"SuspenseList"}if(typeof b=="object")switch(b.$$typeof){case a:var F=b;return P(F)+".Consumer";case s:var Q=b;return P(Q._context)+".Provider";case c:return V(b,b.render,"ForwardRef");case f:var fe=b.displayName||null;return fe!==null?fe:v(b.type)||"Memo";case h:{var xe=b,Se=xe._payload,be=xe._init;try{return v(be(Se))}catch{return null}}}return null}var C=Object.assign,I=0,k,U,G,ue,W,L,oe;function X(){}X.__reactDisabledLog=!0;function q(){{if(I===0){k=console.log,U=console.info,G=console.warn,ue=console.error,W=console.group,L=console.groupCollapsed,oe=console.groupEnd;var b={configurable:!0,enumerable:!0,value:X,writable:!0};Object.defineProperties(console,{info:b,log:b,warn:b,error:b,group:b,groupCollapsed:b,groupEnd:b})}I++}}function ne(){{if(I--,I===0){var b={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:C({},b,{value:k}),info:C({},b,{value:U}),warn:C({},b,{value:G}),error:C({},b,{value:ue}),group:C({},b,{value:W}),groupCollapsed:C({},b,{value:L}),groupEnd:C({},b,{value:oe})})}I<0&&m("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var ae=S.ReactCurrentDispatcher,B;function H(b,F,Q){{if(B===void 0)try{throw Error()}catch(xe){var fe=xe.stack.trim().match(/\n( *(at )?)/);B=fe&&fe[1]||""}return`
|
|
44
|
+
`+B+b}}var J=!1,ee;{var te=typeof WeakMap=="function"?WeakMap:Map;ee=new te}function Z(b,F){if(!b||J)return"";{var Q=ee.get(b);if(Q!==void 0)return Q}var fe;J=!0;var xe=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var Se;Se=ae.current,ae.current=null,q();try{if(F){var be=function(){throw Error()};if(Object.defineProperty(be.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(be,[])}catch(We){fe=We}Reflect.construct(b,[],be)}else{try{be.call()}catch(We){fe=We}b.call(be.prototype)}}else{try{throw Error()}catch(We){fe=We}b()}}catch(We){if(We&&fe&&typeof We.stack=="string"){for(var ye=We.stack.split(`
|
|
45
45
|
`),Ge=fe.stack.split(`
|
|
46
46
|
`),Ne=ye.length-1,Le=Ge.length-1;Ne>=1&&Le>=0&&ye[Ne]!==Ge[Le];)Le--;for(;Ne>=1&&Le>=0;Ne--,Le--)if(ye[Ne]!==Ge[Le]){if(Ne!==1||Le!==1)do if(Ne--,Le--,Le<0||ye[Ne]!==Ge[Le]){var Ue=`
|
|
47
|
-
`+ye[Ne].replace(" at new "," at ");return
|
|
47
|
+
`+ye[Ne].replace(" at new "," at ");return b.displayName&&Ue.includes("<anonymous>")&&(Ue=Ue.replace("<anonymous>",b.displayName)),typeof b=="function"&&ee.set(b,Ue),Ue}while(Ne>=1&&Le>=0);break}}}finally{J=!1,ae.current=Se,ne(),Error.prepareStackTrace=xe}var Bt=b?b.displayName||b.name:"",br=Bt?H(Bt):"";return typeof b=="function"&&ee.set(b,br),br}function ge(b,F,Q){return Z(b,!1)}function Te(b){var F=b.prototype;return!!(F&&F.isReactComponent)}function Ie(b,F,Q){if(b==null)return"";if(typeof b=="function")return Z(b,Te(b));if(typeof b=="string")return H(b);switch(b){case l:return H("Suspense");case d:return H("SuspenseList")}if(typeof b=="object")switch(b.$$typeof){case c:return ge(b.render);case f:return Ie(b.type,F,Q);case h:{var fe=b,xe=fe._payload,Se=fe._init;try{return Ie(Se(xe),F,Q)}catch{}}}return""}var Ae=Object.prototype.hasOwnProperty,$e={},Ye=S.ReactDebugCurrentFrame;function je(b){if(b){var F=b._owner,Q=Ie(b.type,b._source,F?F.type:null);Ye.setExtraStackFrame(Q)}else Ye.setExtraStackFrame(null)}function vt(b,F,Q,fe,xe){{var Se=Function.call.bind(Ae);for(var be in b)if(Se(b,be)){var ye=void 0;try{if(typeof b[be]!="function"){var Ge=Error((fe||"React class")+": "+Q+" type `"+be+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof b[be]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw Ge.name="Invariant Violation",Ge}ye=b[be](F,be,fe,Q,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(Ne){ye=Ne}ye&&!(ye instanceof Error)&&(je(xe),m("%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).",fe||"React class",Q,be,typeof ye),je(null)),ye instanceof Error&&!(ye.message in $e)&&($e[ye.message]=!0,je(xe),m("Failed %s type: %s",Q,ye.message),je(null))}}}var Xe=Array.isArray;function Rt(b){return Xe(b)}function st(b){{var F=typeof Symbol=="function"&&Symbol.toStringTag,Q=F&&b[Symbol.toStringTag]||b.constructor.name||"Object";return Q}}function Ft(b){try{return Pe(b),!1}catch{return!0}}function Pe(b){return""+b}function Ot(b){if(Ft(b))return m("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",st(b)),Pe(b)}var gt=S.ReactCurrentOwner,bn={key:!0,ref:!0,__self:!0,__source:!0},Xt,Nt,Fe;Fe={};function Mt(b){if(Ae.call(b,"ref")){var F=Object.getOwnPropertyDescriptor(b,"ref").get;if(F&&F.isReactWarning)return!1}return b.ref!==void 0}function Gt(b){if(Ae.call(b,"key")){var F=Object.getOwnPropertyDescriptor(b,"key").get;if(F&&F.isReactWarning)return!1}return b.key!==void 0}function On(b,F){if(typeof b.ref=="string"&>.current&&F&>.current.stateNode!==F){var Q=v(gt.current.type);Fe[Q]||(m('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',v(gt.current.type),b.ref),Fe[Q]=!0)}}function Zt(b,F){{var Q=function(){Xt||(Xt=!0,m("%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)",F))};Q.isReactWarning=!0,Object.defineProperty(b,"key",{get:Q,configurable:!0})}}function yr(b,F){{var Q=function(){Nt||(Nt=!0,m("%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)",F))};Q.isReactWarning=!0,Object.defineProperty(b,"ref",{get:Q,configurable:!0})}}var mn=function(b,F,Q,fe,xe,Se,be){var ye={$$typeof:t,type:b,key:F,ref:Q,props:be,_owner:Se};return ye._store={},Object.defineProperty(ye._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(ye,"_self",{configurable:!1,enumerable:!1,writable:!1,value:fe}),Object.defineProperty(ye,"_source",{configurable:!1,enumerable:!1,writable:!1,value:xe}),Object.freeze&&(Object.freeze(ye.props),Object.freeze(ye)),ye};function Br(b,F,Q,fe,xe){{var Se,be={},ye=null,Ge=null;Q!==void 0&&(Ot(Q),ye=""+Q),Gt(F)&&(Ot(F.key),ye=""+F.key),Mt(F)&&(Ge=F.ref,On(F,xe));for(Se in F)Ae.call(F,Se)&&!bn.hasOwnProperty(Se)&&(be[Se]=F[Se]);if(b&&b.defaultProps){var Ne=b.defaultProps;for(Se in Ne)be[Se]===void 0&&(be[Se]=Ne[Se])}if(ye||Ge){var Le=typeof b=="function"?b.displayName||b.name||"Unknown":b;ye&&Zt(be,Le),Ge&&yr(be,Le)}return mn(b,ye,Ge,xe,fe,gt.current,be)}}var Qt=S.ReactCurrentOwner,wn=S.ReactDebugCurrentFrame;function jt(b){if(b){var F=b._owner,Q=Ie(b.type,b._source,F?F.type:null);wn.setExtraStackFrame(Q)}else wn.setExtraStackFrame(null)}var xn;xn=!1;function En(b){return typeof b=="object"&&b!==null&&b.$$typeof===t}function Xn(){{if(Qt.current){var b=v(Qt.current.type);if(b)return`
|
|
48
48
|
|
|
49
|
-
Check the render method of \``+
|
|
49
|
+
Check the render method of \``+b+"`."}return""}}function vo(b){{if(b!==void 0){var F=b.fileName.replace(/^.*[\\\/]/,""),Q=b.lineNumber;return`
|
|
50
50
|
|
|
51
|
-
Check your code at `+F+":"+Q+"."}return""}}var Gn={};function Zn(
|
|
51
|
+
Check your code at `+F+":"+Q+"."}return""}}var Gn={};function Zn(b){{var F=Xn();if(!F){var Q=typeof b=="string"?b:b.displayName||b.name;Q&&(F=`
|
|
52
52
|
|
|
53
|
-
Check the top-level render call using <`+Q+">.")}return F}}function Cn(y,F){{if(!y._store||y._store.validated||y.key!=null)return;y._store.validated=!0;var Q=Zn(F);if(Gn[Q])return;Gn[Q]=!0;var fe="";y&&y._owner&&y._owner!==Qt.current&&(fe=" It was passed a child from "+v(y._owner.type)+"."),jt(y),m('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',Q,fe),jt(null)}}function cn(y,F){{if(typeof y!="object")return;if(Rt(y))for(var Q=0;Q<y.length;Q++){var fe=y[Q];En(fe)&&Cn(fe,F)}else if(En(y))y._store&&(y._store.validated=!0);else if(y){var xe=T(y);if(typeof xe=="function"&&xe!==y.entries)for(var Se=xe.call(y),be;!(be=Se.next()).done;)En(be.value)&&Cn(be.value,F)}}}function Qn(y){{var F=y.type;if(F==null||typeof F=="string")return;var Q;if(typeof F=="function")Q=F.propTypes;else if(typeof F=="object"&&(F.$$typeof===c||F.$$typeof===f))Q=F.propTypes;else return;if(Q){var fe=v(F);vt(Q,y.props,"prop",fe,y)}else if(F.PropTypes!==void 0&&!xn){xn=!0;var xe=v(F);m("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",xe||"Unknown")}typeof F.getDefaultProps=="function"&&!F.getDefaultProps.isReactClassApproved&&m("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Mn(y){{for(var F=Object.keys(y.props),Q=0;Q<F.length;Q++){var fe=F[Q];if(fe!=="children"&&fe!=="key"){jt(y),m("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",fe),jt(null);break}}y.ref!==null&&(jt(y),m("Invalid attribute `ref` supplied to `React.Fragment`."),jt(null))}}function vn(y,F,Q,fe,xe,Se){{var be=K(y);if(!be){var ye="";(y===void 0||typeof y=="object"&&y!==null&&Object.keys(y).length===0)&&(ye+=" 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 Ge=vo(xe);Ge?ye+=Ge:ye+=Xn();var Ne;y===null?Ne="null":Rt(y)?Ne="array":y!==void 0&&y.$$typeof===t?(Ne="<"+(v(y.type)||"Unknown")+" />",ye=" Did you accidentally export a JSX literal instead of a component?"):Ne=typeof y,m("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Ne,ye)}var Le=Br(y,F,Q,xe,Se);if(Le==null)return Le;if(be){var Ue=F.children;if(Ue!==void 0)if(fe)if(Rt(Ue)){for(var Bt=0;Bt<Ue.length;Bt++)cn(Ue[Bt],y);Object.freeze&&Object.freeze(Ue)}else m("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 cn(Ue,y)}return y===r?Mn(Le):Qn(Le),Le}}function _n(y,F,Q){return vn(y,F,Q,!0)}function Jn(y,F,Q){return vn(y,F,Q,!1)}var Vt=Jn,er=_n;ui.Fragment=r,ui.jsx=Vt,ui.jsxs=er}()),ui}process.env.NODE_ENV==="production"?ka.exports=U0():ka.exports=Y0();var mt=ka.exports;const z0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m19.02 6.96-8.62 8.9-5.28-5.27L3 12.71l7.43 7.43 10.74-11.1-2.15-2.08Z",fill:t})}),_c=z0,K0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m21.59 9.03-2.12-2.12-6.94 6.94-6.94-6.94-2.12 2.12 9.06 9.06 9.06-9.06Z",fill:t})}),Lo=K0,q0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m16 21.56 2.12-2.12-6.94-6.94 6.94-6.94L16 3.44 6.94 12.5 16 21.56Z",fill:t})}),X0=q0,G0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m3.47 15.97 2.12 2.12 6.94-6.94 6.94 6.94 2.12-2.12-9.06-9.06-9.06 9.06Z",fill:t})}),Tc=G0,Z0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m21.06 19.44-6.98-6.98 6.9-6.9-2.12-2.12-6.9 6.9-6.82-6.82-2.12 2.12 6.82 6.82-6.9 6.9 2.12 2.12 6.9-6.9 6.98 6.98 2.12-2.12Z",fill:t})}),ls=Z0,Q0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M9 5.5v-3H6v3H2v3h4v3h3v-3h13v-3H9ZM18 13.5h-3v3H2v3h13v3h3v-3h4v-3h-4v-3Z",fill:t})}),J0=Q0,eb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M21 11H3v3h18v-3Z",fill:t})}),tb=eb,nb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m22 21.67-4.86-4.86a8.474 8.474 0 0 0 1.86-5.3c0-4.69-3.81-8.5-8.5-8.5-4.69 0-8.5 3.81-8.5 8.5 0 4.69 3.81 8.5 8.5 8.5 2.01 0 3.85-.7 5.3-1.86l4.86 4.86 1.33-1.33.01-.01ZM10.5 18C6.92 18 4 15.08 4 11.5S6.92 5 10.5 5 17 7.92 17 11.5 14.08 18 10.5 18Z",fill:t})}),rb=nb,ob=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm3.29 14.71-3.31-3.31-3.27 3.27-1.41-1.41 3.27-3.27-3.23-3.23 1.41-1.41 3.23 3.23 3.27-3.27 1.41 1.41-3.27 3.27 3.31 3.31-1.41 1.41Z",fill:t})}),ib=ob,sb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm0 16c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1Zm1.37-4.24c-.22.08-.37.27-.37.47v.77h-2v-.77c0-1.06.66-1.98 1.68-2.35.78-.29 1.48-1.15 1.28-2.25-.14-.79-.81-1.46-1.6-1.6a2.003 2.003 0 0 0-2.37 1.97h-2c0-1.18.52-2.3 1.43-3.06.91-.76 2.1-1.08 3.29-.87 1.61.28 2.94 1.61 3.22 3.22.34 1.93-.74 3.81-2.57 4.48l.01-.01Z",fill:t})}),ab=sb,cb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm1 15h-2v-6h2v6Zm-1-7.88c-.62 0-1.12-.5-1.12-1.12 0-.62.5-1.12 1.12-1.12.62 0 1.12.5 1.12 1.12 0 .62-.5 1.12-1.12 1.12Z",fill:t})}),lb=cb,ub=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm-1.33 14.41-4.04-4.04 1.41-1.41 2.63 2.63 5.29-5.29 1.41 1.41-6.71 6.71.01-.01Z",fill:t})}),db=ub,fb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m12 3.5-10 18h20l-10-18Zm0 15c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1Zm-1-3v-5h2v5h-2Z",fill:t})}),pb=fb,hb=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(i0,{className:"accordion-header",children:D.jsxs(s0,{className:Re(F0,t),...n,ref:r,children:[D.jsx(ht,{className:B0,children:e}),D.jsx(Lo,{className:N0,size:24,color:Et.theme.colors.black})]})}));var mb={success:"var(--_1qe00b2v)",info:"var(--_1qe00b2y)",warning:"var(--_1qe00b211)",error:"var(--_1qe00b214)",neutral:"var(--_1qe00b2e)"},vb=ft({defaultClassName:"_7q2fqh0",variantClassNames:{colorScheme:{success:"_7q2fqh1",info:"_7q2fqh2",warning:"_7q2fqh3",error:"_7q2fqh4",neutral:"_7q2fqh5"}},defaultVariants:{colorScheme:"neutral"},compoundVariants:[]});const qp=u.forwardRef(({className:e,title:t,children:n,withClose:r,colorScheme:i,onClose:o,...s},a)=>{const c="div",d=(()=>{switch(i){case"error":return ib;case"warning":return pb;case"success":return db;default:return lb}})();return D.jsxs(c,{ref:a,className:Re(vb({colorScheme:i}),e),"data-test-id":s["data-test-id"],...s,children:[D.jsxs(Lt,{gap:"$16",children:[D.jsx(ht,{display:"flex",minW:Et.theme.space[24],children:D.jsx(d,{size:24,color:mb[i||"neutral"]})}),D.jsx(ht,{pt:"$2",children:D.jsxs(Ir,{gap:"$8",children:[t&&D.jsx(Kt,{textStyle:"body2",as:"span",fontWeight:"$bold",children:t}),D.jsx(ht,{children:n})]})})]}),r&&D.jsx(Lt,{pl:"$16",pt:"$4",children:D.jsx(ls,{"data-test-id":"VqcF6V40rj6neoaCMaHvB",onClick:o,cursor:"pointer",color:Et.theme.colors.black,size:16})})]})});qp.defaultProps={"data-test-id":void 0,title:void 0,withClose:void 0,onClose:void 0};var gb=ft({defaultClassName:"_1er7sj40",variantClassNames:{colorScheme:{primary:"_1er7sj41",disabled:"_1er7sj42",yellow:"_1er7sj43",red:"_1er7sj44",blue:"_1er7sj45",neutral:"_1er7sj46"},size:{medium:"_15r4f4d1oz _15r4f4d1il _15r4f4d15j _15r4f4d1bx",small:"_15r4f4d1op _15r4f4d1ib _15r4f4d154 _15r4f4d1bi"},isRounded:{true:"_1er7sj49",false:"_1er7sj4a"},variant:{primary:"_1er7sj4b",secondary:"_1er7sj4c"}},defaultVariants:{colorScheme:"primary",size:"medium",variant:"primary",isRounded:!1},compoundVariants:[[{colorScheme:"primary",variant:"secondary"},"_1er7sj4d"],[{colorScheme:"disabled",variant:"secondary"},"_1er7sj4e"],[{colorScheme:"yellow",variant:"secondary"},"_1er7sj4f"],[{colorScheme:"red",variant:"secondary"},"_1er7sj4g"],[{colorScheme:"blue",variant:"secondary"},"_1er7sj4h"]]});const Sc=u.forwardRef(({as:e,children:t,colorScheme:n,size:r,variant:i,isRounded:o,className:s,style:a,...c},l)=>{const d=e||"span";return D.jsx(d,{ref:l,"data-test-id":c["data-test-id"],className:Re(gb({colorScheme:n,variant:i,size:r,isRounded:o}),s),style:a,...c,children:t})});Sc.defaultProps={as:"span",colorScheme:"primary",size:"medium",children:void 0,"data-test-id":void 0};Sc.displayName="Badge";function Zu(e,[t,n]){return Math.min(n,Math.max(t,e))}function yb(e,t=globalThis==null?void 0:globalThis.document){const n=qt(e);u.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const Na="dismissableLayer.update",bb="dismissableLayer.pointerDownOutside",wb="dismissableLayer.focusOutside";let Qu;const Xp=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),us=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:a,onDismiss:c,...l}=e,d=u.useContext(Xp),[f,h]=u.useState(null),p=(n=f==null?void 0:f.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,w]=u.useState({}),E=Qe(t,N=>h(N)),T=Array.from(d.layers),[S]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),m=T.indexOf(S),x=f?T.indexOf(f):-1,_=d.layersWithOutsidePointerEventsDisabled.size>0,$=x>=m,O=Eb(N=>{const j=N.target,K=[...d.branches].some(V=>V.contains(j));!$||K||(o==null||o(N),a==null||a(N),N.defaultPrevented||c==null||c())},p),M=Cb(N=>{const j=N.target;[...d.branches].some(V=>V.contains(j))||(s==null||s(N),a==null||a(N),N.defaultPrevented||c==null||c())},p);return yb(N=>{x===d.layers.size-1&&(i==null||i(N),!N.defaultPrevented&&c&&(N.preventDefault(),c()))},p),u.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Qu=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),Ju(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=Qu)}},[f,p,r,d]),u.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),Ju())},[f,d]),u.useEffect(()=>{const N=()=>w({});return document.addEventListener(Na,N),()=>document.removeEventListener(Na,N)},[]),u.createElement(He.div,ie({},l,{ref:E,style:{pointerEvents:_?$?"auto":"none":void 0,...e.style},onFocusCapture:De(e.onFocusCapture,M.onFocusCapture),onBlurCapture:De(e.onBlurCapture,M.onBlurCapture),onPointerDownCapture:De(e.onPointerDownCapture,O.onPointerDownCapture)}))}),xb=u.forwardRef((e,t)=>{const n=u.useContext(Xp),r=u.useRef(null),i=Qe(t,r);return u.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),u.createElement(He.div,ie({},e,{ref:i}))});function Eb(e,t=globalThis==null?void 0:globalThis.document){const n=qt(e),r=u.useRef(!1),i=u.useRef(()=>{});return u.useEffect(()=>{const o=a=>{if(a.target&&!r.current){let l=function(){Gp(bb,n,c,{discrete:!0})};const c={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=l,t.addEventListener("click",i.current,{once:!0})):l()}r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Cb(e,t=globalThis==null?void 0:globalThis.document){const n=qt(e),r=u.useRef(!1);return u.useEffect(()=>{const i=o=>{o.target&&!r.current&&Gp(wb,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Ju(){const e=new CustomEvent(Na);document.dispatchEvent(e)}function Gp(e,t,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?Vp(i,o):i.dispatchEvent(o)}const _b=us,Tb=xb;let Zs=0;function Zp(){u.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:ed()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:ed()),Zs++,()=>{Zs===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),Zs--}},[])}function ed(){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 Qs="focusScope.autoFocusOnMount",Js="focusScope.autoFocusOnUnmount",td={bubbles:!1,cancelable:!0},Qp=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[a,c]=u.useState(null),l=qt(i),d=qt(o),f=u.useRef(null),h=Qe(t,E=>c(E)),p=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(r){let E=function(x){if(p.paused||!a)return;const _=x.target;a.contains(_)?f.current=_:nr(f.current,{select:!0})},T=function(x){if(p.paused||!a)return;const _=x.relatedTarget;_!==null&&(a.contains(_)||nr(f.current,{select:!0}))},S=function(x){const _=document.activeElement;for(const $ of x)$.removedNodes.length>0&&(a!=null&&a.contains(_)||nr(a))};document.addEventListener("focusin",E),document.addEventListener("focusout",T);const m=new MutationObserver(S);return a&&m.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",E),document.removeEventListener("focusout",T),m.disconnect()}}},[r,a,p.paused]),u.useEffect(()=>{if(a){rd.add(p);const E=document.activeElement;if(!a.contains(E)){const S=new CustomEvent(Qs,td);a.addEventListener(Qs,l),a.dispatchEvent(S),S.defaultPrevented||(Sb(Ab(Jp(a)),{select:!0}),document.activeElement===E&&nr(a))}return()=>{a.removeEventListener(Qs,l),setTimeout(()=>{const S=new CustomEvent(Js,td);a.addEventListener(Js,d),a.dispatchEvent(S),S.defaultPrevented||nr(E??document.body,{select:!0}),a.removeEventListener(Js,d),rd.remove(p)},0)}}},[a,l,d,p]);const w=u.useCallback(E=>{if(!n&&!r||p.paused)return;const T=E.key==="Tab"&&!E.altKey&&!E.ctrlKey&&!E.metaKey,S=document.activeElement;if(T&&S){const m=E.currentTarget,[x,_]=$b(m);x&&_?!E.shiftKey&&S===_?(E.preventDefault(),n&&nr(x,{select:!0})):E.shiftKey&&S===x&&(E.preventDefault(),n&&nr(_,{select:!0})):S===m&&E.preventDefault()}},[n,r,p.paused]);return u.createElement(He.div,ie({tabIndex:-1},s,{ref:h,onKeyDown:w}))});function Sb(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(nr(r,{select:t}),document.activeElement!==n)return}function $b(e){const t=Jp(e),n=nd(t,e),r=nd(t.reverse(),e);return[n,r]}function Jp(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function nd(e,t){for(const n of e)if(!Pb(n,{upTo:t}))return n}function Pb(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Rb(e){return e instanceof HTMLInputElement&&"select"in e}function nr(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Rb(e)&&t&&e.select()}}const rd=Ib();function Ib(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=od(e,t),e.unshift(t)},remove(t){var n;e=od(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function od(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Ab(e){return e.filter(t=>t.tagName!=="A")}const Db=["top","right","bottom","left"],cr=Math.min,tn=Math.max,ji=Math.round,di=Math.floor,lr=e=>({x:e,y:e}),Ob={left:"right",right:"left",bottom:"top",top:"bottom"},Mb={start:"end",end:"start"};function ja(e,t,n){return tn(e,cr(t,n))}function Un(e,t){return typeof e=="function"?e(t):e}function Yn(e){return e.split("-")[0]}function lo(e){return e.split("-")[1]}function $c(e){return e==="x"?"y":"x"}function Pc(e){return e==="y"?"height":"width"}function uo(e){return["top","bottom"].includes(Yn(e))?"y":"x"}function Rc(e){return $c(uo(e))}function kb(e,t,n){n===void 0&&(n=!1);const r=lo(e),i=Rc(e),o=Pc(i);let s=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=Vi(s)),[s,Vi(s)]}function Nb(e){const t=Vi(e);return[Va(e),t,Va(t)]}function Va(e){return e.replace(/start|end/g,t=>Mb[t])}function jb(e,t,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?o:s;default:return[]}}function Vb(e,t,n,r){const i=lo(e);let o=jb(Yn(e),n==="start",r);return i&&(o=o.map(s=>s+"-"+i),t&&(o=o.concat(o.map(Va)))),o}function Vi(e){return e.replace(/left|right|bottom|top/g,t=>Ob[t])}function Lb(e){return{top:0,right:0,bottom:0,left:0,...e}}function eh(e){return typeof e!="number"?Lb(e):{top:e,right:e,bottom:e,left:e}}function Li(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function id(e,t,n){let{reference:r,floating:i}=e;const o=uo(t),s=Rc(t),a=Pc(s),c=Yn(t),l=o==="y",d=r.x+r.width/2-i.width/2,f=r.y+r.height/2-i.height/2,h=r[a]/2-i[a]/2;let p;switch(c){case"top":p={x:d,y:r.y-i.height};break;case"bottom":p={x:d,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:f};break;case"left":p={x:r.x-i.width,y:f};break;default:p={x:r.x,y:r.y}}switch(lo(t)){case"start":p[s]-=h*(n&&l?-1:1);break;case"end":p[s]+=h*(n&&l?-1:1);break}return p}const Fb=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,a=o.filter(Boolean),c=await(s.isRTL==null?void 0:s.isRTL(t));let l=await s.getElementRects({reference:e,floating:t,strategy:i}),{x:d,y:f}=id(l,r,c),h=r,p={},w=0;for(let E=0;E<a.length;E++){const{name:T,fn:S}=a[E],{x:m,y:x,data:_,reset:$}=await S({x:d,y:f,initialPlacement:r,placement:h,strategy:i,middlewareData:p,rects:l,platform:s,elements:{reference:e,floating:t}});if(d=m??d,f=x??f,p={...p,[T]:{...p[T],..._}},$&&w<=50){w++,typeof $=="object"&&($.placement&&(h=$.placement),$.rects&&(l=$.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:i}):$.rects),{x:d,y:f}=id(l,h,c)),E=-1;continue}}return{x:d,y:f,placement:h,strategy:i,middlewareData:p}};async function Fo(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:s,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:h=!1,padding:p=0}=Un(t,e),w=eh(p),T=a[h?f==="floating"?"reference":"floating":f],S=Li(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(T)))==null||n?T:T.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(a.floating)),boundary:l,rootBoundary:d,strategy:c})),m=f==="floating"?{...s.floating,x:r,y:i}:s.reference,x=await(o.getOffsetParent==null?void 0:o.getOffsetParent(a.floating)),_=await(o.isElement==null?void 0:o.isElement(x))?await(o.getScale==null?void 0:o.getScale(x))||{x:1,y:1}:{x:1,y:1},$=Li(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({rect:m,offsetParent:x,strategy:c}):m);return{top:(S.top-$.top+w.top)/_.y,bottom:($.bottom-S.bottom+w.bottom)/_.y,left:(S.left-$.left+w.left)/_.x,right:($.right-S.right+w.right)/_.x}}const sd=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:s,elements:a}=t,{element:c,padding:l=0}=Un(e,t)||{};if(c==null)return{};const d=eh(l),f={x:n,y:r},h=Rc(i),p=Pc(h),w=await s.getDimensions(c),E=h==="y",T=E?"top":"left",S=E?"bottom":"right",m=E?"clientHeight":"clientWidth",x=o.reference[p]+o.reference[h]-f[h]-o.floating[p],_=f[h]-o.reference[h],$=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c));let O=$?$[m]:0;(!O||!await(s.isElement==null?void 0:s.isElement($)))&&(O=a.floating[m]||o.floating[p]);const M=x/2-_/2,N=O/2-w[p]/2-1,j=cr(d[T],N),K=cr(d[S],N),V=j,P=O-w[p]-K,v=O/2-w[p]/2+M,C=ja(V,v,P),k=lo(i)!=null&&v!=C&&o.reference[p]/2-(v<V?j:K)-w[p]/2<0?v<V?V-v:P-v:0;return{[h]:f[h]-k,data:{[h]:C,centerOffset:v-C+k}}}}),Bb=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:i,rects:o,initialPlacement:s,platform:a,elements:c}=t,{mainAxis:l=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:w=!0,...E}=Un(e,t),T=Yn(r),S=Yn(s)===s,m=await(a.isRTL==null?void 0:a.isRTL(c.floating)),x=f||(S||!w?[Vi(s)]:Nb(s));!f&&p!=="none"&&x.push(...Vb(s,w,p,m));const _=[s,...x],$=await Fo(t,E),O=[];let M=((n=i.flip)==null?void 0:n.overflows)||[];if(l&&O.push($[T]),d){const V=kb(r,o,m);O.push($[V[0]],$[V[1]])}if(M=[...M,{placement:r,overflows:O}],!O.every(V=>V<=0)){var N,j;const V=(((N=i.flip)==null?void 0:N.index)||0)+1,P=_[V];if(P)return{data:{index:V,overflows:M},reset:{placement:P}};let v=(j=M.filter(C=>C.overflows[0]<=0).sort((C,I)=>C.overflows[1]-I.overflows[1])[0])==null?void 0:j.placement;if(!v)switch(h){case"bestFit":{var K;const C=(K=M.map(I=>[I.placement,I.overflows.filter(k=>k>0).reduce((k,U)=>k+U,0)]).sort((I,k)=>I[1]-k[1])[0])==null?void 0:K[0];C&&(v=C);break}case"initialPlacement":v=s;break}if(r!==v)return{reset:{placement:v}}}return{}}}};function ad(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function cd(e){return Db.some(t=>e[t]>=0)}const Hb=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...i}=Un(e,t);switch(r){case"referenceHidden":{const o=await Fo(t,{...i,elementContext:"reference"}),s=ad(o,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:cd(s)}}}case"escaped":{const o=await Fo(t,{...i,altBoundary:!0}),s=ad(o,n.floating);return{data:{escapedOffsets:s,escaped:cd(s)}}}default:return{}}}}};async function Wb(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=Yn(n),a=lo(n),c=uo(n)==="y",l=["left","top"].includes(s)?-1:1,d=o&&c?-1:1,f=Un(t,e);let{mainAxis:h,crossAxis:p,alignmentAxis:w}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return a&&typeof w=="number"&&(p=a==="end"?w*-1:w),c?{x:p*d,y:h*l}:{x:h*l,y:p*d}}const Ub=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,i=await Wb(t,e);return{x:n+i.x,y:r+i.y,data:i}}}},Yb=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:a={fn:T=>{let{x:S,y:m}=T;return{x:S,y:m}}},...c}=Un(e,t),l={x:n,y:r},d=await Fo(t,c),f=uo(Yn(i)),h=$c(f);let p=l[h],w=l[f];if(o){const T=h==="y"?"top":"left",S=h==="y"?"bottom":"right",m=p+d[T],x=p-d[S];p=ja(m,p,x)}if(s){const T=f==="y"?"top":"left",S=f==="y"?"bottom":"right",m=w+d[T],x=w-d[S];w=ja(m,w,x)}const E=a.fn({...t,[h]:p,[f]:w});return{...E,data:{x:E.x-n,y:E.y-r}}}}},zb=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:o,middlewareData:s}=t,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=Un(e,t),d={x:n,y:r},f=uo(i),h=$c(f);let p=d[h],w=d[f];const E=Un(a,t),T=typeof E=="number"?{mainAxis:E,crossAxis:0}:{mainAxis:0,crossAxis:0,...E};if(c){const x=h==="y"?"height":"width",_=o.reference[h]-o.floating[x]+T.mainAxis,$=o.reference[h]+o.reference[x]-T.mainAxis;p<_?p=_:p>$&&(p=$)}if(l){var S,m;const x=h==="y"?"width":"height",_=["top","left"].includes(Yn(i)),$=o.reference[f]-o.floating[x]+(_&&((S=s.offset)==null?void 0:S[f])||0)+(_?0:T.crossAxis),O=o.reference[f]+o.reference[x]+(_?0:((m=s.offset)==null?void 0:m[f])||0)-(_?T.crossAxis:0);w<$?w=$:w>O&&(w=O)}return{[h]:p,[f]:w}}}},Kb=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:i,elements:o}=t,{apply:s=()=>{},...a}=Un(e,t),c=await Fo(t,a),l=Yn(n),d=lo(n),f=uo(n)==="y",{width:h,height:p}=r.floating;let w,E;l==="top"||l==="bottom"?(w=l,E=d===(await(i.isRTL==null?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(E=l,w=d==="end"?"top":"bottom");const T=p-c[w],S=h-c[E],m=!t.middlewareData.shift;let x=T,_=S;if(f){const O=h-c.left-c.right;_=d||m?cr(S,O):O}else{const O=p-c.top-c.bottom;x=d||m?cr(T,O):O}if(m&&!d){const O=tn(c.left,0),M=tn(c.right,0),N=tn(c.top,0),j=tn(c.bottom,0);f?_=h-2*(O!==0||M!==0?O+M:tn(c.left,c.right)):x=p-2*(N!==0||j!==0?N+j:tn(c.top,c.bottom))}await s({...t,availableWidth:_,availableHeight:x});const $=await i.getDimensions(o.floating);return h!==$.width||p!==$.height?{reset:{rects:!0}}:{}}}};function ur(e){return th(e)?(e.nodeName||"").toLowerCase():"#document"}function nn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Kn(e){var t;return(t=(th(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function th(e){return e instanceof Node||e instanceof nn(e).Node}function zn(e){return e instanceof Element||e instanceof nn(e).Element}function An(e){return e instanceof HTMLElement||e instanceof nn(e).HTMLElement}function ld(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof nn(e).ShadowRoot}function qo(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=hn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function qb(e){return["table","td","th"].includes(ur(e))}function Ic(e){const t=Ac(),n=hn(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function Xb(e){let t=ro(e);for(;An(t)&&!ds(t);){if(Ic(t))return t;t=ro(t)}return null}function Ac(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function ds(e){return["html","body","#document"].includes(ur(e))}function hn(e){return nn(e).getComputedStyle(e)}function fs(e){return zn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function ro(e){if(ur(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ld(e)&&e.host||Kn(e);return ld(t)?t.host:t}function nh(e){const t=ro(e);return ds(t)?e.ownerDocument?e.ownerDocument.body:e.body:An(t)&&qo(t)?t:nh(t)}function Fi(e,t){var n;t===void 0&&(t=[]);const r=nh(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=nn(r);return i?t.concat(o,o.visualViewport||[],qo(r)?r:[]):t.concat(r,Fi(r))}function rh(e){const t=hn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=An(e),o=i?e.offsetWidth:n,s=i?e.offsetHeight:r,a=ji(n)!==o||ji(r)!==s;return a&&(n=o,r=s),{width:n,height:r,$:a}}function Dc(e){return zn(e)?e:e.contextElement}function eo(e){const t=Dc(e);if(!An(t))return lr(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=rh(t);let s=(o?ji(n.width):n.width)/r,a=(o?ji(n.height):n.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}const Gb=lr(0);function oh(e){const t=nn(e);return!Ac()||!t.visualViewport?Gb:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Zb(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==nn(e)?!1:t}function Dr(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=Dc(e);let s=lr(1);t&&(r?zn(r)&&(s=eo(r)):s=eo(e));const a=Zb(o,n,r)?oh(o):lr(0);let c=(i.left+a.x)/s.x,l=(i.top+a.y)/s.y,d=i.width/s.x,f=i.height/s.y;if(o){const h=nn(o),p=r&&zn(r)?nn(r):r;let w=h.frameElement;for(;w&&r&&p!==h;){const E=eo(w),T=w.getBoundingClientRect(),S=hn(w),m=T.left+(w.clientLeft+parseFloat(S.paddingLeft))*E.x,x=T.top+(w.clientTop+parseFloat(S.paddingTop))*E.y;c*=E.x,l*=E.y,d*=E.x,f*=E.y,c+=m,l+=x,w=nn(w).frameElement}}return Li({width:d,height:f,x:c,y:l})}function Qb(e){let{rect:t,offsetParent:n,strategy:r}=e;const i=An(n),o=Kn(n);if(n===o)return t;let s={scrollLeft:0,scrollTop:0},a=lr(1);const c=lr(0);if((i||!i&&r!=="fixed")&&((ur(n)!=="body"||qo(o))&&(s=fs(n)),An(n))){const l=Dr(n);a=eo(n),c.x=l.x+n.clientLeft,c.y=l.y+n.clientTop}return{width:t.width*a.x,height:t.height*a.y,x:t.x*a.x-s.scrollLeft*a.x+c.x,y:t.y*a.y-s.scrollTop*a.y+c.y}}function Jb(e){return Array.from(e.getClientRects())}function ih(e){return Dr(Kn(e)).left+fs(e).scrollLeft}function ew(e){const t=Kn(e),n=fs(e),r=e.ownerDocument.body,i=tn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=tn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+ih(e);const a=-n.scrollTop;return hn(r).direction==="rtl"&&(s+=tn(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:a}}function tw(e,t){const n=nn(e),r=Kn(e),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,a=0,c=0;if(i){o=i.width,s=i.height;const l=Ac();(!l||l&&t==="fixed")&&(a=i.offsetLeft,c=i.offsetTop)}return{width:o,height:s,x:a,y:c}}function nw(e,t){const n=Dr(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=An(e)?eo(e):lr(1),s=e.clientWidth*o.x,a=e.clientHeight*o.y,c=i*o.x,l=r*o.y;return{width:s,height:a,x:c,y:l}}function ud(e,t,n){let r;if(t==="viewport")r=tw(e,n);else if(t==="document")r=ew(Kn(e));else if(zn(t))r=nw(t,n);else{const i=oh(e);r={...t,x:t.x-i.x,y:t.y-i.y}}return Li(r)}function sh(e,t){const n=ro(e);return n===t||!zn(n)||ds(n)?!1:hn(n).position==="fixed"||sh(n,t)}function rw(e,t){const n=t.get(e);if(n)return n;let r=Fi(e).filter(a=>zn(a)&&ur(a)!=="body"),i=null;const o=hn(e).position==="fixed";let s=o?ro(e):e;for(;zn(s)&&!ds(s);){const a=hn(s),c=Ic(s);!c&&a.position==="fixed"&&(i=null),(o?!c&&!i:!c&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||qo(s)&&!c&&sh(e,s))?r=r.filter(d=>d!==s):i=a,s=ro(s)}return t.set(e,r),r}function ow(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const s=[...n==="clippingAncestors"?rw(t,this._c):[].concat(n),r],a=s[0],c=s.reduce((l,d)=>{const f=ud(t,d,i);return l.top=tn(f.top,l.top),l.right=cr(f.right,l.right),l.bottom=cr(f.bottom,l.bottom),l.left=tn(f.left,l.left),l},ud(t,a,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function iw(e){return rh(e)}function sw(e,t,n){const r=An(t),i=Kn(t),o=n==="fixed",s=Dr(e,!0,o,t);let a={scrollLeft:0,scrollTop:0};const c=lr(0);if(r||!r&&!o)if((ur(t)!=="body"||qo(i))&&(a=fs(t)),r){const l=Dr(t,!0,o,t);c.x=l.x+t.clientLeft,c.y=l.y+t.clientTop}else i&&(c.x=ih(i));return{x:s.left+a.scrollLeft-c.x,y:s.top+a.scrollTop-c.y,width:s.width,height:s.height}}function dd(e,t){return!An(e)||hn(e).position==="fixed"?null:t?t(e):e.offsetParent}function ah(e,t){const n=nn(e);if(!An(e))return n;let r=dd(e,t);for(;r&&qb(r)&&hn(r).position==="static";)r=dd(r,t);return r&&(ur(r)==="html"||ur(r)==="body"&&hn(r).position==="static"&&!Ic(r))?n:r||Xb(e)||n}const aw=async function(e){let{reference:t,floating:n,strategy:r}=e;const i=this.getOffsetParent||ah,o=this.getDimensions;return{reference:sw(t,await i(n),r),floating:{x:0,y:0,...await o(n)}}};function cw(e){return hn(e).direction==="rtl"}const lw={convertOffsetParentRelativeRectToViewportRelativeRect:Qb,getDocumentElement:Kn,getClippingRect:ow,getOffsetParent:ah,getElementRects:aw,getClientRects:Jb,getDimensions:iw,getScale:eo,isElement:zn,isRTL:cw};function uw(e,t){let n=null,r;const i=Kn(e);function o(){clearTimeout(r),n&&n.disconnect(),n=null}function s(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),o();const{left:l,top:d,width:f,height:h}=e.getBoundingClientRect();if(a||t(),!f||!h)return;const p=di(d),w=di(i.clientWidth-(l+f)),E=di(i.clientHeight-(d+h)),T=di(l),m={rootMargin:-p+"px "+-w+"px "+-E+"px "+-T+"px",threshold:tn(0,cr(1,c))||1};let x=!0;function _($){const O=$[0].intersectionRatio;if(O!==c){if(!x)return s();O?s(!1,O):r=setTimeout(()=>{s(!1,1e-7)},100)}x=!1}try{n=new IntersectionObserver(_,{...m,root:i.ownerDocument})}catch{n=new IntersectionObserver(_,m)}n.observe(e)}return s(!0),o}function dw(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,l=Dc(e),d=i||o?[...l?Fi(l):[],...Fi(t)]:[];d.forEach(S=>{i&&S.addEventListener("scroll",n,{passive:!0}),o&&S.addEventListener("resize",n)});const f=l&&a?uw(l,n):null;let h=-1,p=null;s&&(p=new ResizeObserver(S=>{let[m]=S;m&&m.target===l&&p&&(p.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{p&&p.observe(t)})),n()}),l&&!c&&p.observe(l),p.observe(t));let w,E=c?Dr(e):null;c&&T();function T(){const S=Dr(e);E&&(S.x!==E.x||S.y!==E.y||S.width!==E.width||S.height!==E.height)&&n(),E=S,w=requestAnimationFrame(T)}return n(),()=>{d.forEach(S=>{i&&S.removeEventListener("scroll",n),o&&S.removeEventListener("resize",n)}),f&&f(),p&&p.disconnect(),p=null,c&&cancelAnimationFrame(w)}}const fw=(e,t,n)=>{const r=new Map,i={platform:lw,...n},o={...i.platform,_c:r};return Fb(e,t,{...i,platform:o})},pw=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?sd({element:r.current,padding:i}).fn(n):{}:r?sd({element:r,padding:i}).fn(n):{}}}};var Pi=typeof document<"u"?u.useLayoutEffect:u.useEffect;function Bi(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!Bi(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!Bi(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function ch(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function fd(e,t){const n=ch(e);return Math.round(t*n)/n}function pd(e){const t=he.useRef(e);return Pi(()=>{t.current=e}),t}function hw(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:c,open:l}=e,[d,f]=he.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,p]=he.useState(r);Bi(h,r)||p(r);const[w,E]=he.useState(null),[T,S]=he.useState(null),m=he.useCallback(k=>{k!=O.current&&(O.current=k,E(k))},[E]),x=he.useCallback(k=>{k!==M.current&&(M.current=k,S(k))},[S]),_=o||w,$=s||T,O=he.useRef(null),M=he.useRef(null),N=he.useRef(d),j=pd(c),K=pd(i),V=he.useCallback(()=>{if(!O.current||!M.current)return;const k={placement:t,strategy:n,middleware:h};K.current&&(k.platform=K.current),fw(O.current,M.current,k).then(U=>{const G={...U,isPositioned:!0};P.current&&!Bi(N.current,G)&&(N.current=G,gy.flushSync(()=>{f(G)}))})},[h,t,n,K]);Pi(()=>{l===!1&&N.current.isPositioned&&(N.current.isPositioned=!1,f(k=>({...k,isPositioned:!1})))},[l]);const P=he.useRef(!1);Pi(()=>(P.current=!0,()=>{P.current=!1}),[]),Pi(()=>{if(_&&(O.current=_),$&&(M.current=$),_&&$){if(j.current)return j.current(_,$,V);V()}},[_,$,V,j]);const v=he.useMemo(()=>({reference:O,floating:M,setReference:m,setFloating:x}),[m,x]),C=he.useMemo(()=>({reference:_,floating:$}),[_,$]),I=he.useMemo(()=>{const k={position:n,left:0,top:0};if(!C.floating)return k;const U=fd(C.floating,d.x),G=fd(C.floating,d.y);return a?{...k,transform:"translate("+U+"px, "+G+"px)",...ch(C.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:U,top:G}},[n,a,C.floating,d.x,d.y]);return he.useMemo(()=>({...d,update:V,refs:v,elements:C,floatingStyles:I}),[d,V,v,C,I])}const mw=u.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...o}=e;return u.createElement(He.svg,ie({},o,{ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),e.asChild?n:u.createElement("polygon",{points:"0,0 30,0 15,10"}))}),vw=mw;function ps(e){const[t,n]=u.useState(void 0);return Wt(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let s,a;if("borderBoxSize"in o){const c=o.borderBoxSize,l=Array.isArray(c)?c[0]:c;s=l.inlineSize,a=l.blockSize}else s=e.offsetWidth,a=e.offsetHeight;n({width:s,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}const lh="Popper",[uh,hs]=sn(lh),[gw,dh]=uh(lh),yw=e=>{const{__scopePopper:t,children:n}=e,[r,i]=u.useState(null);return u.createElement(gw,{scope:t,anchor:r,onAnchorChange:i},n)},bw="PopperAnchor",ww=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,o=dh(bw,n),s=u.useRef(null),a=Qe(t,s);return u.useEffect(()=>{o.onAnchorChange((r==null?void 0:r.current)||s.current)}),r?null:u.createElement(He.div,ie({},i,{ref:a}))}),fh="PopperContent",[xw,Ew]=uh(fh),Cw=u.forwardRef((e,t)=>{var n,r,i,o,s,a,c,l;const{__scopePopper:d,side:f="bottom",sideOffset:h=0,align:p="center",alignOffset:w=0,arrowPadding:E=0,collisionBoundary:T=[],collisionPadding:S=0,sticky:m="partial",hideWhenDetached:x=!1,avoidCollisions:_=!0,onPlaced:$,...O}=e,M=dh(fh,d),[N,j]=u.useState(null),K=Qe(t,Te=>j(Te)),[V,P]=u.useState(null),v=ps(V),C=(n=v==null?void 0:v.width)!==null&&n!==void 0?n:0,I=(r=v==null?void 0:v.height)!==null&&r!==void 0?r:0,k=f+(p!=="center"?"-"+p:""),U=typeof S=="number"?S:{top:0,right:0,bottom:0,left:0,...S},G=Array.isArray(T)?T:[T],ue=G.length>0,W={padding:U,boundary:G.filter($w),altBoundary:ue},{refs:L,floatingStyles:oe,placement:X,isPositioned:q,middlewareData:ne}=hw({strategy:"fixed",placement:k,whileElementsMounted:dw,elements:{reference:M.anchor},middleware:[Ub({mainAxis:h+I,alignmentAxis:w}),_&&Yb({mainAxis:!0,crossAxis:!1,limiter:m==="partial"?zb():void 0,...W}),_&&Bb({...W}),Kb({...W,apply:({elements:Te,rects:Ie,availableWidth:Ae,availableHeight:$e})=>{const{width:Ye,height:je}=Ie.reference,vt=Te.floating.style;vt.setProperty("--radix-popper-available-width",`${Ae}px`),vt.setProperty("--radix-popper-available-height",`${$e}px`),vt.setProperty("--radix-popper-anchor-width",`${Ye}px`),vt.setProperty("--radix-popper-anchor-height",`${je}px`)}}),V&&pw({element:V,padding:E}),Pw({arrowWidth:C,arrowHeight:I}),x&&Hb({strategy:"referenceHidden"})]}),[ae,B]=ph(X),H=qt($);Wt(()=>{q&&(H==null||H())},[q,H]);const J=(i=ne.arrow)===null||i===void 0?void 0:i.x,ee=(o=ne.arrow)===null||o===void 0?void 0:o.y,te=((s=ne.arrow)===null||s===void 0?void 0:s.centerOffset)!==0,[Z,ge]=u.useState();return Wt(()=>{N&&ge(window.getComputedStyle(N).zIndex)},[N]),u.createElement("div",{ref:L.setFloating,"data-radix-popper-content-wrapper":"",style:{...oe,transform:q?oe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Z,"--radix-popper-transform-origin":[(a=ne.transformOrigin)===null||a===void 0?void 0:a.x,(c=ne.transformOrigin)===null||c===void 0?void 0:c.y].join(" ")},dir:e.dir},u.createElement(xw,{scope:d,placedSide:ae,onArrowChange:P,arrowX:J,arrowY:ee,shouldHideArrow:te},u.createElement(He.div,ie({"data-side":ae,"data-align":B},O,{ref:K,style:{...O.style,animation:q?void 0:"none",opacity:(l=ne.hide)!==null&&l!==void 0&&l.referenceHidden?0:void 0}}))))}),_w="PopperArrow",Tw={top:"bottom",right:"left",bottom:"top",left:"right"},Sw=u.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,o=Ew(_w,r),s=Tw[o.placedSide];return u.createElement("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0}},u.createElement(vw,ie({},i,{ref:n,style:{...i.style,display:"block"}})))});function $w(e){return e!==null}const Pw=e=>({name:"transformOrigin",options:e,fn(t){var n,r,i,o,s;const{placement:a,rects:c,middlewareData:l}=t,f=((n=l.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,h=f?0:e.arrowWidth,p=f?0:e.arrowHeight,[w,E]=ph(a),T={start:"0%",center:"50%",end:"100%"}[E],S=((r=(i=l.arrow)===null||i===void 0?void 0:i.x)!==null&&r!==void 0?r:0)+h/2,m=((o=(s=l.arrow)===null||s===void 0?void 0:s.y)!==null&&o!==void 0?o:0)+p/2;let x="",_="";return w==="bottom"?(x=f?T:`${S}px`,_=`${-p}px`):w==="top"?(x=f?T:`${S}px`,_=`${c.floating.height+p}px`):w==="right"?(x=`${-p}px`,_=f?T:`${m}px`):w==="left"&&(x=`${c.floating.width+p}px`,_=f?T:`${m}px`),{data:{x,y:_}}}});function ph(e){const[t,n="center"]=e.split("-");return[t,n]}const hh=yw,mh=ww,vh=Cw,Rw=Sw,gh=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...i}=e;return r?fn.createPortal(u.createElement(He.div,ie({},i,{ref:t})),r):null}),Iw=gh;function ms(e){const t=u.useRef({value:e,previous:e});return u.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}const vs=u.forwardRef((e,t)=>u.createElement(He.span,ie({},e,{ref:t,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",...e.style}}))),Aw=vs;var Dw=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Wr=new WeakMap,fi=new WeakMap,pi={},ea=0,yh=function(e){return e&&(e.host||yh(e.parentNode))},Ow=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=yh(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Mw=function(e,t,n,r){var i=Ow(t,Array.isArray(e)?e:[e]);pi[n]||(pi[n]=new WeakMap);var o=pi[n],s=[],a=new Set,c=new Set(i),l=function(f){!f||a.has(f)||(a.add(f),l(f.parentNode))};i.forEach(l);var d=function(f){!f||c.has(f)||Array.prototype.forEach.call(f.children,function(h){if(a.has(h))d(h);else{var p=h.getAttribute(r),w=p!==null&&p!=="false",E=(Wr.get(h)||0)+1,T=(o.get(h)||0)+1;Wr.set(h,E),o.set(h,T),s.push(h),E===1&&w&&fi.set(h,!0),T===1&&h.setAttribute(n,"true"),w||h.setAttribute(r,"true")}})};return d(t),a.clear(),ea++,function(){s.forEach(function(f){var h=Wr.get(f)-1,p=o.get(f)-1;Wr.set(f,h),o.set(f,p),h||(fi.has(f)||f.removeAttribute(r),fi.delete(f)),p||f.removeAttribute(n)}),ea--,ea||(Wr=new WeakMap,Wr=new WeakMap,fi=new WeakMap,pi={})}},bh=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=t||Dw(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live]"))),Mw(r,i,n,"aria-hidden")):function(){return null}},dn=function(){return dn=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},dn.apply(this,arguments)};function wh(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function kw(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Ri="right-scroll-bar-position",Ii="width-before-scroll-bar",Nw="with-scroll-bars-hidden",jw="--removed-body-scroll-bar-size";function Vw(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Lw(e,t){var n=u.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}function Fw(e,t){return Lw(t||null,function(n){return e.forEach(function(r){return Vw(r,n)})})}function Bw(e){return e}function Hw(e,t){t===void 0&&(t=Bw);var n=[],r=!1,i={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(o){var s=t(o,r);return n.push(s),function(){n=n.filter(function(a){return a!==s})}},assignSyncMedium:function(o){for(r=!0;n.length;){var s=n;n=[],s.forEach(o)}n={push:function(a){return o(a)},filter:function(){return n}}},assignMedium:function(o){r=!0;var s=[];if(n.length){var a=n;n=[],a.forEach(o),s=n}var c=function(){var d=s;s=[],d.forEach(o)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(d){s.push(d),l()},filter:function(d){return s=s.filter(d),n}}}};return i}function Ww(e){e===void 0&&(e={});var t=Hw(null);return t.options=dn({async:!0,ssr:!1},e),t}var xh=function(e){var t=e.sideCar,n=wh(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return he.createElement(r,dn({},n))};xh.isSideCarExport=!0;function Uw(e,t){return e.useMedium(t),xh}var Eh=Ww(),ta=function(){},gs=he.forwardRef(function(e,t){var n=he.useRef(null),r=he.useState({onScrollCapture:ta,onWheelCapture:ta,onTouchMoveCapture:ta}),i=r[0],o=r[1],s=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,d=e.enabled,f=e.shards,h=e.sideCar,p=e.noIsolation,w=e.inert,E=e.allowPinchZoom,T=e.as,S=T===void 0?"div":T,m=wh(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),x=h,_=Fw([n,t]),$=dn(dn({},m),i);return he.createElement(he.Fragment,null,d&&he.createElement(x,{sideCar:Eh,removeScrollBar:l,shards:f,noIsolation:p,inert:w,setCallbacks:o,allowPinchZoom:!!E,lockRef:n}),s?he.cloneElement(he.Children.only(a),dn(dn({},$),{ref:_})):he.createElement(S,dn({},$,{className:c,ref:_}),a))});gs.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};gs.classNames={fullWidth:Ii,zeroRight:Ri};var hd,Yw=function(){if(hd)return hd;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function zw(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Yw();return t&&e.setAttribute("nonce",t),e}function Kw(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function qw(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Xw=function(){var e=0,t=null;return{add:function(n){e==0&&(t=zw())&&(Kw(t,n),qw(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Gw=function(){var e=Xw();return function(t,n){he.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ch=function(){var e=Gw(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},Zw={left:0,top:0,right:0,gap:0},na=function(e){return parseInt(e||"",10)||0},Qw=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[na(n),na(r),na(i)]},Jw=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Zw;var t=Qw(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])}},ex=Ch(),tx=function(e,t,n,r){var i=e.left,o=e.top,s=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
53
|
+
Check the top-level render call using <`+Q+">.")}return F}}function Cn(b,F){{if(!b._store||b._store.validated||b.key!=null)return;b._store.validated=!0;var Q=Zn(F);if(Gn[Q])return;Gn[Q]=!0;var fe="";b&&b._owner&&b._owner!==Qt.current&&(fe=" It was passed a child from "+v(b._owner.type)+"."),jt(b),m('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',Q,fe),jt(null)}}function cn(b,F){{if(typeof b!="object")return;if(Rt(b))for(var Q=0;Q<b.length;Q++){var fe=b[Q];En(fe)&&Cn(fe,F)}else if(En(b))b._store&&(b._store.validated=!0);else if(b){var xe=T(b);if(typeof xe=="function"&&xe!==b.entries)for(var Se=xe.call(b),be;!(be=Se.next()).done;)En(be.value)&&Cn(be.value,F)}}}function Qn(b){{var F=b.type;if(F==null||typeof F=="string")return;var Q;if(typeof F=="function")Q=F.propTypes;else if(typeof F=="object"&&(F.$$typeof===c||F.$$typeof===f))Q=F.propTypes;else return;if(Q){var fe=v(F);vt(Q,b.props,"prop",fe,b)}else if(F.PropTypes!==void 0&&!xn){xn=!0;var xe=v(F);m("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",xe||"Unknown")}typeof F.getDefaultProps=="function"&&!F.getDefaultProps.isReactClassApproved&&m("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Mn(b){{for(var F=Object.keys(b.props),Q=0;Q<F.length;Q++){var fe=F[Q];if(fe!=="children"&&fe!=="key"){jt(b),m("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",fe),jt(null);break}}b.ref!==null&&(jt(b),m("Invalid attribute `ref` supplied to `React.Fragment`."),jt(null))}}function vn(b,F,Q,fe,xe,Se){{var be=K(b);if(!be){var ye="";(b===void 0||typeof b=="object"&&b!==null&&Object.keys(b).length===0)&&(ye+=" 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 Ge=vo(xe);Ge?ye+=Ge:ye+=Xn();var Ne;b===null?Ne="null":Rt(b)?Ne="array":b!==void 0&&b.$$typeof===t?(Ne="<"+(v(b.type)||"Unknown")+" />",ye=" Did you accidentally export a JSX literal instead of a component?"):Ne=typeof b,m("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Ne,ye)}var Le=Br(b,F,Q,xe,Se);if(Le==null)return Le;if(be){var Ue=F.children;if(Ue!==void 0)if(fe)if(Rt(Ue)){for(var Bt=0;Bt<Ue.length;Bt++)cn(Ue[Bt],b);Object.freeze&&Object.freeze(Ue)}else m("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 cn(Ue,b)}return b===r?Mn(Le):Qn(Le),Le}}function _n(b,F,Q){return vn(b,F,Q,!0)}function Jn(b,F,Q){return vn(b,F,Q,!1)}var Vt=Jn,er=_n;ui.Fragment=r,ui.jsx=Vt,ui.jsxs=er}()),ui}process.env.NODE_ENV==="production"?ka.exports=U0():ka.exports=Y0();var mt=ka.exports;const z0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m19.02 6.96-8.62 8.9-5.28-5.27L3 12.71l7.43 7.43 10.74-11.1-2.15-2.08Z",fill:t})}),_c=z0,K0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m21.59 9.03-2.12-2.12-6.94 6.94-6.94-6.94-2.12 2.12 9.06 9.06 9.06-9.06Z",fill:t})}),Lo=K0,q0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m16 21.56 2.12-2.12-6.94-6.94 6.94-6.94L16 3.44 6.94 12.5 16 21.56Z",fill:t})}),X0=q0,G0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m3.47 15.97 2.12 2.12 6.94-6.94 6.94 6.94 2.12-2.12-9.06-9.06-9.06 9.06Z",fill:t})}),Tc=G0,Z0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m21.06 19.44-6.98-6.98 6.9-6.9-2.12-2.12-6.9 6.9-6.82-6.82-2.12 2.12 6.82 6.82-6.9 6.9 2.12 2.12 6.9-6.9 6.98 6.98 2.12-2.12Z",fill:t})}),ls=Z0,Q0=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M9 5.5v-3H6v3H2v3h4v3h3v-3h13v-3H9ZM18 13.5h-3v3H2v3h13v3h3v-3h4v-3h-4v-3Z",fill:t})}),J0=Q0,eb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M21 11H3v3h18v-3Z",fill:t})}),tb=eb,nb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,fill:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m22 21.67-4.86-4.86a8.474 8.474 0 0 0 1.86-5.3c0-4.69-3.81-8.5-8.5-8.5-4.69 0-8.5 3.81-8.5 8.5 0 4.69 3.81 8.5 8.5 8.5 2.01 0 3.85-.7 5.3-1.86l4.86 4.86 1.33-1.33.01-.01ZM10.5 18C6.92 18 4 15.08 4 11.5S6.92 5 10.5 5 17 7.92 17 11.5 14.08 18 10.5 18Z",fill:t})}),rb=nb,ob=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm3.29 14.71-3.31-3.31-3.27 3.27-1.41-1.41 3.27-3.27-3.23-3.23 1.41-1.41 3.23 3.23 3.27-3.27 1.41 1.41-3.27 3.27 3.31 3.31-1.41 1.41Z",fill:t})}),ib=ob,sb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm0 16c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1Zm1.37-4.24c-.22.08-.37.27-.37.47v.77h-2v-.77c0-1.06.66-1.98 1.68-2.35.78-.29 1.48-1.15 1.28-2.25-.14-.79-.81-1.46-1.6-1.6a2.003 2.003 0 0 0-2.37 1.97h-2c0-1.18.52-2.3 1.43-3.06.91-.76 2.1-1.08 3.29-.87 1.61.28 2.94 1.61 3.22 3.22.34 1.93-.74 3.81-2.57 4.48l.01-.01Z",fill:t})}),ab=sb,cb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm1 15h-2v-6h2v6Zm-1-7.88c-.62 0-1.12-.5-1.12-1.12 0-.62.5-1.12 1.12-1.12.62 0 1.12.5 1.12 1.12 0 .62-.5 1.12-1.12 1.12Z",fill:t})}),lb=cb,ub=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"M12 2.5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10Zm-1.33 14.41-4.04-4.04 1.41-1.41 2.63 2.63 5.29-5.29 1.41 1.41-6.71 6.71.01-.01Z",fill:t})}),db=ub,fb=({size:e=24,color:t="inherit",...n})=>mt.jsx("svg",{width:e,height:e,viewBox:"0 0 24 24",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",...n,children:mt.jsx("path",{d:"m12 3.5-10 18h20l-10-18Zm0 15c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1Zm-1-3v-5h2v5h-2Z",fill:t})}),pb=fb,hb=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(i0,{className:"accordion-header",children:O.jsxs(s0,{className:Re(F0,t),...n,ref:r,children:[O.jsx(ht,{className:B0,children:e}),O.jsx(Lo,{className:N0,size:24,color:Et.theme.colors.black})]})}));var mb={success:"var(--_1qe00b2v)",info:"var(--_1qe00b2y)",warning:"var(--_1qe00b211)",error:"var(--_1qe00b214)",neutral:"var(--_1qe00b2e)"},vb=ft({defaultClassName:"_7q2fqh0",variantClassNames:{colorScheme:{success:"_7q2fqh1",info:"_7q2fqh2",warning:"_7q2fqh3",error:"_7q2fqh4",neutral:"_7q2fqh5"}},defaultVariants:{colorScheme:"neutral"},compoundVariants:[]});const qp=u.forwardRef(({className:e,title:t,children:n,withClose:r,colorScheme:i,onClose:o,...s},a)=>{const c="div",d=(()=>{switch(i){case"error":return ib;case"warning":return pb;case"success":return db;default:return lb}})();return O.jsxs(c,{ref:a,className:Re(vb({colorScheme:i}),e),"data-test-id":s["data-test-id"],...s,children:[O.jsxs(Lt,{gap:"$16",children:[O.jsx(ht,{display:"flex",minW:Et.theme.space[24],children:O.jsx(d,{size:24,color:mb[i||"neutral"]})}),O.jsx(ht,{pt:"$2",children:O.jsxs(Ir,{gap:"$8",children:[t&&O.jsx(Kt,{textStyle:"body2",as:"span",fontWeight:"$bold",children:t}),O.jsx(ht,{children:n})]})})]}),r&&O.jsx(Lt,{pl:"$16",pt:"$4",children:O.jsx(ls,{"data-test-id":"VqcF6V40rj6neoaCMaHvB",onClick:o,cursor:"pointer",color:Et.theme.colors.black,size:16})})]})});qp.defaultProps={"data-test-id":void 0,title:void 0,withClose:void 0,onClose:void 0};var gb=ft({defaultClassName:"_1er7sj40",variantClassNames:{colorScheme:{primary:"_1er7sj41",disabled:"_1er7sj42",yellow:"_1er7sj43",red:"_1er7sj44",blue:"_1er7sj45",neutral:"_1er7sj46"},size:{medium:"_15r4f4d1oz _15r4f4d1il _15r4f4d15j _15r4f4d1bx",small:"_15r4f4d1op _15r4f4d1ib _15r4f4d154 _15r4f4d1bi"},isRounded:{true:"_1er7sj49",false:"_1er7sj4a"},variant:{primary:"_1er7sj4b",secondary:"_1er7sj4c"}},defaultVariants:{colorScheme:"primary",size:"medium",variant:"primary",isRounded:!1},compoundVariants:[[{colorScheme:"primary",variant:"secondary"},"_1er7sj4d"],[{colorScheme:"disabled",variant:"secondary"},"_1er7sj4e"],[{colorScheme:"yellow",variant:"secondary"},"_1er7sj4f"],[{colorScheme:"red",variant:"secondary"},"_1er7sj4g"],[{colorScheme:"blue",variant:"secondary"},"_1er7sj4h"]]});const Sc=u.forwardRef(({as:e,children:t,colorScheme:n,size:r,variant:i,isRounded:o,className:s,style:a,...c},l)=>{const d=e||"span";return O.jsx(d,{ref:l,"data-test-id":c["data-test-id"],className:Re(gb({colorScheme:n,variant:i,size:r,isRounded:o}),s),style:a,...c,children:t})});Sc.defaultProps={as:"span",colorScheme:"primary",size:"medium",children:void 0,"data-test-id":void 0};Sc.displayName="Badge";function Zu(e,[t,n]){return Math.min(n,Math.max(t,e))}function yb(e,t=globalThis==null?void 0:globalThis.document){const n=qt(e);u.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const Na="dismissableLayer.update",bb="dismissableLayer.pointerDownOutside",wb="dismissableLayer.focusOutside";let Qu;const Xp=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),us=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:a,onDismiss:c,...l}=e,d=u.useContext(Xp),[f,h]=u.useState(null),p=(n=f==null?void 0:f.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,y]=u.useState({}),E=Qe(t,N=>h(N)),T=Array.from(d.layers),[S]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),m=T.indexOf(S),x=f?T.indexOf(f):-1,_=d.layersWithOutsidePointerEventsDisabled.size>0,$=x>=m,M=Eb(N=>{const j=N.target,K=[...d.branches].some(V=>V.contains(j));!$||K||(o==null||o(N),a==null||a(N),N.defaultPrevented||c==null||c())},p),D=Cb(N=>{const j=N.target;[...d.branches].some(V=>V.contains(j))||(s==null||s(N),a==null||a(N),N.defaultPrevented||c==null||c())},p);return yb(N=>{x===d.layers.size-1&&(i==null||i(N),!N.defaultPrevented&&c&&(N.preventDefault(),c()))},p),u.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Qu=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),Ju(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=Qu)}},[f,p,r,d]),u.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),Ju())},[f,d]),u.useEffect(()=>{const N=()=>y({});return document.addEventListener(Na,N),()=>document.removeEventListener(Na,N)},[]),u.createElement(He.div,ie({},l,{ref:E,style:{pointerEvents:_?$?"auto":"none":void 0,...e.style},onFocusCapture:De(e.onFocusCapture,D.onFocusCapture),onBlurCapture:De(e.onBlurCapture,D.onBlurCapture),onPointerDownCapture:De(e.onPointerDownCapture,M.onPointerDownCapture)}))}),xb=u.forwardRef((e,t)=>{const n=u.useContext(Xp),r=u.useRef(null),i=Qe(t,r);return u.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),u.createElement(He.div,ie({},e,{ref:i}))});function Eb(e,t=globalThis==null?void 0:globalThis.document){const n=qt(e),r=u.useRef(!1),i=u.useRef(()=>{});return u.useEffect(()=>{const o=a=>{if(a.target&&!r.current){let l=function(){Gp(bb,n,c,{discrete:!0})};const c={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=l,t.addEventListener("click",i.current,{once:!0})):l()}r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",o),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Cb(e,t=globalThis==null?void 0:globalThis.document){const n=qt(e),r=u.useRef(!1);return u.useEffect(()=>{const i=o=>{o.target&&!r.current&&Gp(wb,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Ju(){const e=new CustomEvent(Na);document.dispatchEvent(e)}function Gp(e,t,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?Vp(i,o):i.dispatchEvent(o)}const _b=us,Tb=xb;let Zs=0;function Zp(){u.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:ed()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:ed()),Zs++,()=>{Zs===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),Zs--}},[])}function ed(){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 Qs="focusScope.autoFocusOnMount",Js="focusScope.autoFocusOnUnmount",td={bubbles:!1,cancelable:!0},Qp=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[a,c]=u.useState(null),l=qt(i),d=qt(o),f=u.useRef(null),h=Qe(t,E=>c(E)),p=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(r){let E=function(x){if(p.paused||!a)return;const _=x.target;a.contains(_)?f.current=_:nr(f.current,{select:!0})},T=function(x){if(p.paused||!a)return;const _=x.relatedTarget;_!==null&&(a.contains(_)||nr(f.current,{select:!0}))},S=function(x){const _=document.activeElement;for(const $ of x)$.removedNodes.length>0&&(a!=null&&a.contains(_)||nr(a))};document.addEventListener("focusin",E),document.addEventListener("focusout",T);const m=new MutationObserver(S);return a&&m.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",E),document.removeEventListener("focusout",T),m.disconnect()}}},[r,a,p.paused]),u.useEffect(()=>{if(a){rd.add(p);const E=document.activeElement;if(!a.contains(E)){const S=new CustomEvent(Qs,td);a.addEventListener(Qs,l),a.dispatchEvent(S),S.defaultPrevented||(Sb(Ab(Jp(a)),{select:!0}),document.activeElement===E&&nr(a))}return()=>{a.removeEventListener(Qs,l),setTimeout(()=>{const S=new CustomEvent(Js,td);a.addEventListener(Js,d),a.dispatchEvent(S),S.defaultPrevented||nr(E??document.body,{select:!0}),a.removeEventListener(Js,d),rd.remove(p)},0)}}},[a,l,d,p]);const y=u.useCallback(E=>{if(!n&&!r||p.paused)return;const T=E.key==="Tab"&&!E.altKey&&!E.ctrlKey&&!E.metaKey,S=document.activeElement;if(T&&S){const m=E.currentTarget,[x,_]=$b(m);x&&_?!E.shiftKey&&S===_?(E.preventDefault(),n&&nr(x,{select:!0})):E.shiftKey&&S===x&&(E.preventDefault(),n&&nr(_,{select:!0})):S===m&&E.preventDefault()}},[n,r,p.paused]);return u.createElement(He.div,ie({tabIndex:-1},s,{ref:h,onKeyDown:y}))});function Sb(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(nr(r,{select:t}),document.activeElement!==n)return}function $b(e){const t=Jp(e),n=nd(t,e),r=nd(t.reverse(),e);return[n,r]}function Jp(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function nd(e,t){for(const n of e)if(!Pb(n,{upTo:t}))return n}function Pb(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Rb(e){return e instanceof HTMLInputElement&&"select"in e}function nr(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Rb(e)&&t&&e.select()}}const rd=Ib();function Ib(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=od(e,t),e.unshift(t)},remove(t){var n;e=od(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function od(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Ab(e){return e.filter(t=>t.tagName!=="A")}const Db=["top","right","bottom","left"],cr=Math.min,tn=Math.max,ji=Math.round,di=Math.floor,lr=e=>({x:e,y:e}),Ob={left:"right",right:"left",bottom:"top",top:"bottom"},Mb={start:"end",end:"start"};function ja(e,t,n){return tn(e,cr(t,n))}function Un(e,t){return typeof e=="function"?e(t):e}function Yn(e){return e.split("-")[0]}function lo(e){return e.split("-")[1]}function $c(e){return e==="x"?"y":"x"}function Pc(e){return e==="y"?"height":"width"}function uo(e){return["top","bottom"].includes(Yn(e))?"y":"x"}function Rc(e){return $c(uo(e))}function kb(e,t,n){n===void 0&&(n=!1);const r=lo(e),i=Rc(e),o=Pc(i);let s=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=Vi(s)),[s,Vi(s)]}function Nb(e){const t=Vi(e);return[Va(e),t,Va(t)]}function Va(e){return e.replace(/start|end/g,t=>Mb[t])}function jb(e,t,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?i:r:t?r:i;case"left":case"right":return t?o:s;default:return[]}}function Vb(e,t,n,r){const i=lo(e);let o=jb(Yn(e),n==="start",r);return i&&(o=o.map(s=>s+"-"+i),t&&(o=o.concat(o.map(Va)))),o}function Vi(e){return e.replace(/left|right|bottom|top/g,t=>Ob[t])}function Lb(e){return{top:0,right:0,bottom:0,left:0,...e}}function eh(e){return typeof e!="number"?Lb(e):{top:e,right:e,bottom:e,left:e}}function Li(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function id(e,t,n){let{reference:r,floating:i}=e;const o=uo(t),s=Rc(t),a=Pc(s),c=Yn(t),l=o==="y",d=r.x+r.width/2-i.width/2,f=r.y+r.height/2-i.height/2,h=r[a]/2-i[a]/2;let p;switch(c){case"top":p={x:d,y:r.y-i.height};break;case"bottom":p={x:d,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:f};break;case"left":p={x:r.x-i.width,y:f};break;default:p={x:r.x,y:r.y}}switch(lo(t)){case"start":p[s]-=h*(n&&l?-1:1);break;case"end":p[s]+=h*(n&&l?-1:1);break}return p}const Fb=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,a=o.filter(Boolean),c=await(s.isRTL==null?void 0:s.isRTL(t));let l=await s.getElementRects({reference:e,floating:t,strategy:i}),{x:d,y:f}=id(l,r,c),h=r,p={},y=0;for(let E=0;E<a.length;E++){const{name:T,fn:S}=a[E],{x:m,y:x,data:_,reset:$}=await S({x:d,y:f,initialPlacement:r,placement:h,strategy:i,middlewareData:p,rects:l,platform:s,elements:{reference:e,floating:t}});if(d=m??d,f=x??f,p={...p,[T]:{...p[T],..._}},$&&y<=50){y++,typeof $=="object"&&($.placement&&(h=$.placement),$.rects&&(l=$.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:i}):$.rects),{x:d,y:f}=id(l,h,c)),E=-1;continue}}return{x:d,y:f,placement:h,strategy:i,middlewareData:p}};async function Fo(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:s,elements:a,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:h=!1,padding:p=0}=Un(t,e),y=eh(p),T=a[h?f==="floating"?"reference":"floating":f],S=Li(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(T)))==null||n?T:T.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(a.floating)),boundary:l,rootBoundary:d,strategy:c})),m=f==="floating"?{...s.floating,x:r,y:i}:s.reference,x=await(o.getOffsetParent==null?void 0:o.getOffsetParent(a.floating)),_=await(o.isElement==null?void 0:o.isElement(x))?await(o.getScale==null?void 0:o.getScale(x))||{x:1,y:1}:{x:1,y:1},$=Li(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({rect:m,offsetParent:x,strategy:c}):m);return{top:(S.top-$.top+y.top)/_.y,bottom:($.bottom-S.bottom+y.bottom)/_.y,left:(S.left-$.left+y.left)/_.x,right:($.right-S.right+y.right)/_.x}}const sd=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:s,elements:a}=t,{element:c,padding:l=0}=Un(e,t)||{};if(c==null)return{};const d=eh(l),f={x:n,y:r},h=Rc(i),p=Pc(h),y=await s.getDimensions(c),E=h==="y",T=E?"top":"left",S=E?"bottom":"right",m=E?"clientHeight":"clientWidth",x=o.reference[p]+o.reference[h]-f[h]-o.floating[p],_=f[h]-o.reference[h],$=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c));let M=$?$[m]:0;(!M||!await(s.isElement==null?void 0:s.isElement($)))&&(M=a.floating[m]||o.floating[p]);const D=x/2-_/2,N=M/2-y[p]/2-1,j=cr(d[T],N),K=cr(d[S],N),V=j,P=M-y[p]-K,v=M/2-y[p]/2+D,C=ja(V,v,P),k=lo(i)!=null&&v!=C&&o.reference[p]/2-(v<V?j:K)-y[p]/2<0?v<V?V-v:P-v:0;return{[h]:f[h]-k,data:{[h]:C,centerOffset:v-C+k}}}}),Bb=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:i,rects:o,initialPlacement:s,platform:a,elements:c}=t,{mainAxis:l=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:y=!0,...E}=Un(e,t),T=Yn(r),S=Yn(s)===s,m=await(a.isRTL==null?void 0:a.isRTL(c.floating)),x=f||(S||!y?[Vi(s)]:Nb(s));!f&&p!=="none"&&x.push(...Vb(s,y,p,m));const _=[s,...x],$=await Fo(t,E),M=[];let D=((n=i.flip)==null?void 0:n.overflows)||[];if(l&&M.push($[T]),d){const V=kb(r,o,m);M.push($[V[0]],$[V[1]])}if(D=[...D,{placement:r,overflows:M}],!M.every(V=>V<=0)){var N,j;const V=(((N=i.flip)==null?void 0:N.index)||0)+1,P=_[V];if(P)return{data:{index:V,overflows:D},reset:{placement:P}};let v=(j=D.filter(C=>C.overflows[0]<=0).sort((C,I)=>C.overflows[1]-I.overflows[1])[0])==null?void 0:j.placement;if(!v)switch(h){case"bestFit":{var K;const C=(K=D.map(I=>[I.placement,I.overflows.filter(k=>k>0).reduce((k,U)=>k+U,0)]).sort((I,k)=>I[1]-k[1])[0])==null?void 0:K[0];C&&(v=C);break}case"initialPlacement":v=s;break}if(r!==v)return{reset:{placement:v}}}return{}}}};function ad(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function cd(e){return Db.some(t=>e[t]>=0)}const Hb=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...i}=Un(e,t);switch(r){case"referenceHidden":{const o=await Fo(t,{...i,elementContext:"reference"}),s=ad(o,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:cd(s)}}}case"escaped":{const o=await Fo(t,{...i,altBoundary:!0}),s=ad(o,n.floating);return{data:{escapedOffsets:s,escaped:cd(s)}}}default:return{}}}}};async function Wb(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=Yn(n),a=lo(n),c=uo(n)==="y",l=["left","top"].includes(s)?-1:1,d=o&&c?-1:1,f=Un(t,e);let{mainAxis:h,crossAxis:p,alignmentAxis:y}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return a&&typeof y=="number"&&(p=a==="end"?y*-1:y),c?{x:p*d,y:h*l}:{x:h*l,y:p*d}}const Ub=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,i=await Wb(t,e);return{x:n+i.x,y:r+i.y,data:i}}}},Yb=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:a={fn:T=>{let{x:S,y:m}=T;return{x:S,y:m}}},...c}=Un(e,t),l={x:n,y:r},d=await Fo(t,c),f=uo(Yn(i)),h=$c(f);let p=l[h],y=l[f];if(o){const T=h==="y"?"top":"left",S=h==="y"?"bottom":"right",m=p+d[T],x=p-d[S];p=ja(m,p,x)}if(s){const T=f==="y"?"top":"left",S=f==="y"?"bottom":"right",m=y+d[T],x=y-d[S];y=ja(m,y,x)}const E=a.fn({...t,[h]:p,[f]:y});return{...E,data:{x:E.x-n,y:E.y-r}}}}},zb=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:o,middlewareData:s}=t,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=Un(e,t),d={x:n,y:r},f=uo(i),h=$c(f);let p=d[h],y=d[f];const E=Un(a,t),T=typeof E=="number"?{mainAxis:E,crossAxis:0}:{mainAxis:0,crossAxis:0,...E};if(c){const x=h==="y"?"height":"width",_=o.reference[h]-o.floating[x]+T.mainAxis,$=o.reference[h]+o.reference[x]-T.mainAxis;p<_?p=_:p>$&&(p=$)}if(l){var S,m;const x=h==="y"?"width":"height",_=["top","left"].includes(Yn(i)),$=o.reference[f]-o.floating[x]+(_&&((S=s.offset)==null?void 0:S[f])||0)+(_?0:T.crossAxis),M=o.reference[f]+o.reference[x]+(_?0:((m=s.offset)==null?void 0:m[f])||0)-(_?T.crossAxis:0);y<$?y=$:y>M&&(y=M)}return{[h]:p,[f]:y}}}},Kb=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:i,elements:o}=t,{apply:s=()=>{},...a}=Un(e,t),c=await Fo(t,a),l=Yn(n),d=lo(n),f=uo(n)==="y",{width:h,height:p}=r.floating;let y,E;l==="top"||l==="bottom"?(y=l,E=d===(await(i.isRTL==null?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(E=l,y=d==="end"?"top":"bottom");const T=p-c[y],S=h-c[E],m=!t.middlewareData.shift;let x=T,_=S;if(f){const M=h-c.left-c.right;_=d||m?cr(S,M):M}else{const M=p-c.top-c.bottom;x=d||m?cr(T,M):M}if(m&&!d){const M=tn(c.left,0),D=tn(c.right,0),N=tn(c.top,0),j=tn(c.bottom,0);f?_=h-2*(M!==0||D!==0?M+D:tn(c.left,c.right)):x=p-2*(N!==0||j!==0?N+j:tn(c.top,c.bottom))}await s({...t,availableWidth:_,availableHeight:x});const $=await i.getDimensions(o.floating);return h!==$.width||p!==$.height?{reset:{rects:!0}}:{}}}};function ur(e){return th(e)?(e.nodeName||"").toLowerCase():"#document"}function nn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Kn(e){var t;return(t=(th(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function th(e){return e instanceof Node||e instanceof nn(e).Node}function zn(e){return e instanceof Element||e instanceof nn(e).Element}function An(e){return e instanceof HTMLElement||e instanceof nn(e).HTMLElement}function ld(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof nn(e).ShadowRoot}function qo(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=hn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(i)}function qb(e){return["table","td","th"].includes(ur(e))}function Ic(e){const t=Ac(),n=hn(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function Xb(e){let t=ro(e);for(;An(t)&&!ds(t);){if(Ic(t))return t;t=ro(t)}return null}function Ac(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function ds(e){return["html","body","#document"].includes(ur(e))}function hn(e){return nn(e).getComputedStyle(e)}function fs(e){return zn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function ro(e){if(ur(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ld(e)&&e.host||Kn(e);return ld(t)?t.host:t}function nh(e){const t=ro(e);return ds(t)?e.ownerDocument?e.ownerDocument.body:e.body:An(t)&&qo(t)?t:nh(t)}function Fi(e,t){var n;t===void 0&&(t=[]);const r=nh(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=nn(r);return i?t.concat(o,o.visualViewport||[],qo(r)?r:[]):t.concat(r,Fi(r))}function rh(e){const t=hn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=An(e),o=i?e.offsetWidth:n,s=i?e.offsetHeight:r,a=ji(n)!==o||ji(r)!==s;return a&&(n=o,r=s),{width:n,height:r,$:a}}function Dc(e){return zn(e)?e:e.contextElement}function eo(e){const t=Dc(e);if(!An(t))return lr(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=rh(t);let s=(o?ji(n.width):n.width)/r,a=(o?ji(n.height):n.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}const Gb=lr(0);function oh(e){const t=nn(e);return!Ac()||!t.visualViewport?Gb:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Zb(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==nn(e)?!1:t}function Dr(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=Dc(e);let s=lr(1);t&&(r?zn(r)&&(s=eo(r)):s=eo(e));const a=Zb(o,n,r)?oh(o):lr(0);let c=(i.left+a.x)/s.x,l=(i.top+a.y)/s.y,d=i.width/s.x,f=i.height/s.y;if(o){const h=nn(o),p=r&&zn(r)?nn(r):r;let y=h.frameElement;for(;y&&r&&p!==h;){const E=eo(y),T=y.getBoundingClientRect(),S=hn(y),m=T.left+(y.clientLeft+parseFloat(S.paddingLeft))*E.x,x=T.top+(y.clientTop+parseFloat(S.paddingTop))*E.y;c*=E.x,l*=E.y,d*=E.x,f*=E.y,c+=m,l+=x,y=nn(y).frameElement}}return Li({width:d,height:f,x:c,y:l})}function Qb(e){let{rect:t,offsetParent:n,strategy:r}=e;const i=An(n),o=Kn(n);if(n===o)return t;let s={scrollLeft:0,scrollTop:0},a=lr(1);const c=lr(0);if((i||!i&&r!=="fixed")&&((ur(n)!=="body"||qo(o))&&(s=fs(n)),An(n))){const l=Dr(n);a=eo(n),c.x=l.x+n.clientLeft,c.y=l.y+n.clientTop}return{width:t.width*a.x,height:t.height*a.y,x:t.x*a.x-s.scrollLeft*a.x+c.x,y:t.y*a.y-s.scrollTop*a.y+c.y}}function Jb(e){return Array.from(e.getClientRects())}function ih(e){return Dr(Kn(e)).left+fs(e).scrollLeft}function ew(e){const t=Kn(e),n=fs(e),r=e.ownerDocument.body,i=tn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=tn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+ih(e);const a=-n.scrollTop;return hn(r).direction==="rtl"&&(s+=tn(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:a}}function tw(e,t){const n=nn(e),r=Kn(e),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,a=0,c=0;if(i){o=i.width,s=i.height;const l=Ac();(!l||l&&t==="fixed")&&(a=i.offsetLeft,c=i.offsetTop)}return{width:o,height:s,x:a,y:c}}function nw(e,t){const n=Dr(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=An(e)?eo(e):lr(1),s=e.clientWidth*o.x,a=e.clientHeight*o.y,c=i*o.x,l=r*o.y;return{width:s,height:a,x:c,y:l}}function ud(e,t,n){let r;if(t==="viewport")r=tw(e,n);else if(t==="document")r=ew(Kn(e));else if(zn(t))r=nw(t,n);else{const i=oh(e);r={...t,x:t.x-i.x,y:t.y-i.y}}return Li(r)}function sh(e,t){const n=ro(e);return n===t||!zn(n)||ds(n)?!1:hn(n).position==="fixed"||sh(n,t)}function rw(e,t){const n=t.get(e);if(n)return n;let r=Fi(e).filter(a=>zn(a)&&ur(a)!=="body"),i=null;const o=hn(e).position==="fixed";let s=o?ro(e):e;for(;zn(s)&&!ds(s);){const a=hn(s),c=Ic(s);!c&&a.position==="fixed"&&(i=null),(o?!c&&!i:!c&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||qo(s)&&!c&&sh(e,s))?r=r.filter(d=>d!==s):i=a,s=ro(s)}return t.set(e,r),r}function ow(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const s=[...n==="clippingAncestors"?rw(t,this._c):[].concat(n),r],a=s[0],c=s.reduce((l,d)=>{const f=ud(t,d,i);return l.top=tn(f.top,l.top),l.right=cr(f.right,l.right),l.bottom=cr(f.bottom,l.bottom),l.left=tn(f.left,l.left),l},ud(t,a,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function iw(e){return rh(e)}function sw(e,t,n){const r=An(t),i=Kn(t),o=n==="fixed",s=Dr(e,!0,o,t);let a={scrollLeft:0,scrollTop:0};const c=lr(0);if(r||!r&&!o)if((ur(t)!=="body"||qo(i))&&(a=fs(t)),r){const l=Dr(t,!0,o,t);c.x=l.x+t.clientLeft,c.y=l.y+t.clientTop}else i&&(c.x=ih(i));return{x:s.left+a.scrollLeft-c.x,y:s.top+a.scrollTop-c.y,width:s.width,height:s.height}}function dd(e,t){return!An(e)||hn(e).position==="fixed"?null:t?t(e):e.offsetParent}function ah(e,t){const n=nn(e);if(!An(e))return n;let r=dd(e,t);for(;r&&qb(r)&&hn(r).position==="static";)r=dd(r,t);return r&&(ur(r)==="html"||ur(r)==="body"&&hn(r).position==="static"&&!Ic(r))?n:r||Xb(e)||n}const aw=async function(e){let{reference:t,floating:n,strategy:r}=e;const i=this.getOffsetParent||ah,o=this.getDimensions;return{reference:sw(t,await i(n),r),floating:{x:0,y:0,...await o(n)}}};function cw(e){return hn(e).direction==="rtl"}const lw={convertOffsetParentRelativeRectToViewportRelativeRect:Qb,getDocumentElement:Kn,getClippingRect:ow,getOffsetParent:ah,getElementRects:aw,getClientRects:Jb,getDimensions:iw,getScale:eo,isElement:zn,isRTL:cw};function uw(e,t){let n=null,r;const i=Kn(e);function o(){clearTimeout(r),n&&n.disconnect(),n=null}function s(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),o();const{left:l,top:d,width:f,height:h}=e.getBoundingClientRect();if(a||t(),!f||!h)return;const p=di(d),y=di(i.clientWidth-(l+f)),E=di(i.clientHeight-(d+h)),T=di(l),m={rootMargin:-p+"px "+-y+"px "+-E+"px "+-T+"px",threshold:tn(0,cr(1,c))||1};let x=!0;function _($){const M=$[0].intersectionRatio;if(M!==c){if(!x)return s();M?s(!1,M):r=setTimeout(()=>{s(!1,1e-7)},100)}x=!1}try{n=new IntersectionObserver(_,{...m,root:i.ownerDocument})}catch{n=new IntersectionObserver(_,m)}n.observe(e)}return s(!0),o}function dw(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,l=Dc(e),d=i||o?[...l?Fi(l):[],...Fi(t)]:[];d.forEach(S=>{i&&S.addEventListener("scroll",n,{passive:!0}),o&&S.addEventListener("resize",n)});const f=l&&a?uw(l,n):null;let h=-1,p=null;s&&(p=new ResizeObserver(S=>{let[m]=S;m&&m.target===l&&p&&(p.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{p&&p.observe(t)})),n()}),l&&!c&&p.observe(l),p.observe(t));let y,E=c?Dr(e):null;c&&T();function T(){const S=Dr(e);E&&(S.x!==E.x||S.y!==E.y||S.width!==E.width||S.height!==E.height)&&n(),E=S,y=requestAnimationFrame(T)}return n(),()=>{d.forEach(S=>{i&&S.removeEventListener("scroll",n),o&&S.removeEventListener("resize",n)}),f&&f(),p&&p.disconnect(),p=null,c&&cancelAnimationFrame(y)}}const fw=(e,t,n)=>{const r=new Map,i={platform:lw,...n},o={...i.platform,_c:r};return Fb(e,t,{...i,platform:o})},pw=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?sd({element:r.current,padding:i}).fn(n):{}:r?sd({element:r,padding:i}).fn(n):{}}}};var Pi=typeof document<"u"?u.useLayoutEffect:u.useEffect;function Bi(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!Bi(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!Bi(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function ch(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function fd(e,t){const n=ch(e);return Math.round(t*n)/n}function pd(e){const t=he.useRef(e);return Pi(()=>{t.current=e}),t}function hw(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:c,open:l}=e,[d,f]=he.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,p]=he.useState(r);Bi(h,r)||p(r);const[y,E]=he.useState(null),[T,S]=he.useState(null),m=he.useCallback(k=>{k!=M.current&&(M.current=k,E(k))},[E]),x=he.useCallback(k=>{k!==D.current&&(D.current=k,S(k))},[S]),_=o||y,$=s||T,M=he.useRef(null),D=he.useRef(null),N=he.useRef(d),j=pd(c),K=pd(i),V=he.useCallback(()=>{if(!M.current||!D.current)return;const k={placement:t,strategy:n,middleware:h};K.current&&(k.platform=K.current),fw(M.current,D.current,k).then(U=>{const G={...U,isPositioned:!0};P.current&&!Bi(N.current,G)&&(N.current=G,gy.flushSync(()=>{f(G)}))})},[h,t,n,K]);Pi(()=>{l===!1&&N.current.isPositioned&&(N.current.isPositioned=!1,f(k=>({...k,isPositioned:!1})))},[l]);const P=he.useRef(!1);Pi(()=>(P.current=!0,()=>{P.current=!1}),[]),Pi(()=>{if(_&&(M.current=_),$&&(D.current=$),_&&$){if(j.current)return j.current(_,$,V);V()}},[_,$,V,j]);const v=he.useMemo(()=>({reference:M,floating:D,setReference:m,setFloating:x}),[m,x]),C=he.useMemo(()=>({reference:_,floating:$}),[_,$]),I=he.useMemo(()=>{const k={position:n,left:0,top:0};if(!C.floating)return k;const U=fd(C.floating,d.x),G=fd(C.floating,d.y);return a?{...k,transform:"translate("+U+"px, "+G+"px)",...ch(C.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:U,top:G}},[n,a,C.floating,d.x,d.y]);return he.useMemo(()=>({...d,update:V,refs:v,elements:C,floatingStyles:I}),[d,V,v,C,I])}const mw=u.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...o}=e;return u.createElement(He.svg,ie({},o,{ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),e.asChild?n:u.createElement("polygon",{points:"0,0 30,0 15,10"}))}),vw=mw;function ps(e){const[t,n]=u.useState(void 0);return Wt(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let s,a;if("borderBoxSize"in o){const c=o.borderBoxSize,l=Array.isArray(c)?c[0]:c;s=l.inlineSize,a=l.blockSize}else s=e.offsetWidth,a=e.offsetHeight;n({width:s,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}const lh="Popper",[uh,hs]=sn(lh),[gw,dh]=uh(lh),yw=e=>{const{__scopePopper:t,children:n}=e,[r,i]=u.useState(null);return u.createElement(gw,{scope:t,anchor:r,onAnchorChange:i},n)},bw="PopperAnchor",ww=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,o=dh(bw,n),s=u.useRef(null),a=Qe(t,s);return u.useEffect(()=>{o.onAnchorChange((r==null?void 0:r.current)||s.current)}),r?null:u.createElement(He.div,ie({},i,{ref:a}))}),fh="PopperContent",[xw,Ew]=uh(fh),Cw=u.forwardRef((e,t)=>{var n,r,i,o,s,a,c,l;const{__scopePopper:d,side:f="bottom",sideOffset:h=0,align:p="center",alignOffset:y=0,arrowPadding:E=0,collisionBoundary:T=[],collisionPadding:S=0,sticky:m="partial",hideWhenDetached:x=!1,avoidCollisions:_=!0,onPlaced:$,...M}=e,D=dh(fh,d),[N,j]=u.useState(null),K=Qe(t,Te=>j(Te)),[V,P]=u.useState(null),v=ps(V),C=(n=v==null?void 0:v.width)!==null&&n!==void 0?n:0,I=(r=v==null?void 0:v.height)!==null&&r!==void 0?r:0,k=f+(p!=="center"?"-"+p:""),U=typeof S=="number"?S:{top:0,right:0,bottom:0,left:0,...S},G=Array.isArray(T)?T:[T],ue=G.length>0,W={padding:U,boundary:G.filter($w),altBoundary:ue},{refs:L,floatingStyles:oe,placement:X,isPositioned:q,middlewareData:ne}=hw({strategy:"fixed",placement:k,whileElementsMounted:dw,elements:{reference:D.anchor},middleware:[Ub({mainAxis:h+I,alignmentAxis:y}),_&&Yb({mainAxis:!0,crossAxis:!1,limiter:m==="partial"?zb():void 0,...W}),_&&Bb({...W}),Kb({...W,apply:({elements:Te,rects:Ie,availableWidth:Ae,availableHeight:$e})=>{const{width:Ye,height:je}=Ie.reference,vt=Te.floating.style;vt.setProperty("--radix-popper-available-width",`${Ae}px`),vt.setProperty("--radix-popper-available-height",`${$e}px`),vt.setProperty("--radix-popper-anchor-width",`${Ye}px`),vt.setProperty("--radix-popper-anchor-height",`${je}px`)}}),V&&pw({element:V,padding:E}),Pw({arrowWidth:C,arrowHeight:I}),x&&Hb({strategy:"referenceHidden"})]}),[ae,B]=ph(X),H=qt($);Wt(()=>{q&&(H==null||H())},[q,H]);const J=(i=ne.arrow)===null||i===void 0?void 0:i.x,ee=(o=ne.arrow)===null||o===void 0?void 0:o.y,te=((s=ne.arrow)===null||s===void 0?void 0:s.centerOffset)!==0,[Z,ge]=u.useState();return Wt(()=>{N&&ge(window.getComputedStyle(N).zIndex)},[N]),u.createElement("div",{ref:L.setFloating,"data-radix-popper-content-wrapper":"",style:{...oe,transform:q?oe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Z,"--radix-popper-transform-origin":[(a=ne.transformOrigin)===null||a===void 0?void 0:a.x,(c=ne.transformOrigin)===null||c===void 0?void 0:c.y].join(" ")},dir:e.dir},u.createElement(xw,{scope:d,placedSide:ae,onArrowChange:P,arrowX:J,arrowY:ee,shouldHideArrow:te},u.createElement(He.div,ie({"data-side":ae,"data-align":B},M,{ref:K,style:{...M.style,animation:q?void 0:"none",opacity:(l=ne.hide)!==null&&l!==void 0&&l.referenceHidden?0:void 0}}))))}),_w="PopperArrow",Tw={top:"bottom",right:"left",bottom:"top",left:"right"},Sw=u.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,o=Ew(_w,r),s=Tw[o.placedSide];return u.createElement("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0}},u.createElement(vw,ie({},i,{ref:n,style:{...i.style,display:"block"}})))});function $w(e){return e!==null}const Pw=e=>({name:"transformOrigin",options:e,fn(t){var n,r,i,o,s;const{placement:a,rects:c,middlewareData:l}=t,f=((n=l.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,h=f?0:e.arrowWidth,p=f?0:e.arrowHeight,[y,E]=ph(a),T={start:"0%",center:"50%",end:"100%"}[E],S=((r=(i=l.arrow)===null||i===void 0?void 0:i.x)!==null&&r!==void 0?r:0)+h/2,m=((o=(s=l.arrow)===null||s===void 0?void 0:s.y)!==null&&o!==void 0?o:0)+p/2;let x="",_="";return y==="bottom"?(x=f?T:`${S}px`,_=`${-p}px`):y==="top"?(x=f?T:`${S}px`,_=`${c.floating.height+p}px`):y==="right"?(x=`${-p}px`,_=f?T:`${m}px`):y==="left"&&(x=`${c.floating.width+p}px`,_=f?T:`${m}px`),{data:{x,y:_}}}});function ph(e){const[t,n="center"]=e.split("-");return[t,n]}const hh=yw,mh=ww,vh=Cw,Rw=Sw,gh=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...i}=e;return r?fn.createPortal(u.createElement(He.div,ie({},i,{ref:t})),r):null}),Iw=gh;function ms(e){const t=u.useRef({value:e,previous:e});return u.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}const vs=u.forwardRef((e,t)=>u.createElement(He.span,ie({},e,{ref:t,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",...e.style}}))),Aw=vs;var Dw=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Wr=new WeakMap,fi=new WeakMap,pi={},ea=0,yh=function(e){return e&&(e.host||yh(e.parentNode))},Ow=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=yh(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Mw=function(e,t,n,r){var i=Ow(t,Array.isArray(e)?e:[e]);pi[n]||(pi[n]=new WeakMap);var o=pi[n],s=[],a=new Set,c=new Set(i),l=function(f){!f||a.has(f)||(a.add(f),l(f.parentNode))};i.forEach(l);var d=function(f){!f||c.has(f)||Array.prototype.forEach.call(f.children,function(h){if(a.has(h))d(h);else{var p=h.getAttribute(r),y=p!==null&&p!=="false",E=(Wr.get(h)||0)+1,T=(o.get(h)||0)+1;Wr.set(h,E),o.set(h,T),s.push(h),E===1&&y&&fi.set(h,!0),T===1&&h.setAttribute(n,"true"),y||h.setAttribute(r,"true")}})};return d(t),a.clear(),ea++,function(){s.forEach(function(f){var h=Wr.get(f)-1,p=o.get(f)-1;Wr.set(f,h),o.set(f,p),h||(fi.has(f)||f.removeAttribute(r),fi.delete(f)),p||f.removeAttribute(n)}),ea--,ea||(Wr=new WeakMap,Wr=new WeakMap,fi=new WeakMap,pi={})}},bh=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=t||Dw(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live]"))),Mw(r,i,n,"aria-hidden")):function(){return null}},dn=function(){return dn=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},dn.apply(this,arguments)};function wh(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function kw(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Ri="right-scroll-bar-position",Ii="width-before-scroll-bar",Nw="with-scroll-bars-hidden",jw="--removed-body-scroll-bar-size";function Vw(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Lw(e,t){var n=u.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}function Fw(e,t){return Lw(t||null,function(n){return e.forEach(function(r){return Vw(r,n)})})}function Bw(e){return e}function Hw(e,t){t===void 0&&(t=Bw);var n=[],r=!1,i={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(o){var s=t(o,r);return n.push(s),function(){n=n.filter(function(a){return a!==s})}},assignSyncMedium:function(o){for(r=!0;n.length;){var s=n;n=[],s.forEach(o)}n={push:function(a){return o(a)},filter:function(){return n}}},assignMedium:function(o){r=!0;var s=[];if(n.length){var a=n;n=[],a.forEach(o),s=n}var c=function(){var d=s;s=[],d.forEach(o)},l=function(){return Promise.resolve().then(c)};l(),n={push:function(d){s.push(d),l()},filter:function(d){return s=s.filter(d),n}}}};return i}function Ww(e){e===void 0&&(e={});var t=Hw(null);return t.options=dn({async:!0,ssr:!1},e),t}var xh=function(e){var t=e.sideCar,n=wh(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return he.createElement(r,dn({},n))};xh.isSideCarExport=!0;function Uw(e,t){return e.useMedium(t),xh}var Eh=Ww(),ta=function(){},gs=he.forwardRef(function(e,t){var n=he.useRef(null),r=he.useState({onScrollCapture:ta,onWheelCapture:ta,onTouchMoveCapture:ta}),i=r[0],o=r[1],s=e.forwardProps,a=e.children,c=e.className,l=e.removeScrollBar,d=e.enabled,f=e.shards,h=e.sideCar,p=e.noIsolation,y=e.inert,E=e.allowPinchZoom,T=e.as,S=T===void 0?"div":T,m=wh(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),x=h,_=Fw([n,t]),$=dn(dn({},m),i);return he.createElement(he.Fragment,null,d&&he.createElement(x,{sideCar:Eh,removeScrollBar:l,shards:f,noIsolation:p,inert:y,setCallbacks:o,allowPinchZoom:!!E,lockRef:n}),s?he.cloneElement(he.Children.only(a),dn(dn({},$),{ref:_})):he.createElement(S,dn({},$,{className:c,ref:_}),a))});gs.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};gs.classNames={fullWidth:Ii,zeroRight:Ri};var hd,Yw=function(){if(hd)return hd;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function zw(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Yw();return t&&e.setAttribute("nonce",t),e}function Kw(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function qw(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Xw=function(){var e=0,t=null;return{add:function(n){e==0&&(t=zw())&&(Kw(t,n),qw(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Gw=function(){var e=Xw();return function(t,n){he.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ch=function(){var e=Gw(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},Zw={left:0,top:0,right:0,gap:0},na=function(e){return parseInt(e||"",10)||0},Qw=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[na(n),na(r),na(i)]},Jw=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Zw;var t=Qw(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])}},ex=Ch(),tx=function(e,t,n,r){var i=e.left,o=e.top,s=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
54
54
|
.`.concat(Nw,` {
|
|
55
55
|
overflow: hidden `).concat(r,`;
|
|
56
56
|
padding-right: `).concat(a,"px ").concat(r,`;
|
|
@@ -87,29 +87,29 @@ Check the top-level render call using <`+Q+">.")}return F}}function Cn(y,F){{if(
|
|
|
87
87
|
body {
|
|
88
88
|
`).concat(jw,": ").concat(a,`px;
|
|
89
89
|
}
|
|
90
|
-
`)},nx=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r,o=he.useMemo(function(){return Jw(i)},[i]);return he.createElement(ex,{styles:tx(o,!t,i,n?"":"!important")})},La=!1;if(typeof window<"u")try{var hi=Object.defineProperty({},"passive",{get:function(){return La=!0,!0}});window.addEventListener("test",hi,hi),window.removeEventListener("test",hi,hi)}catch{La=!1}var Ur=La?{passive:!1}:!1,rx=function(e){return e.tagName==="TEXTAREA"},_h=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!rx(e)&&n[t]==="visible")},ox=function(e){return _h(e,"overflowY")},ix=function(e){return _h(e,"overflowX")},md=function(e,t){var n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=Th(e,n);if(r){var i=Sh(e,n),o=i[1],s=i[2];if(o>s)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},sx=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},ax=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},Th=function(e,t){return e==="v"?ox(t):ix(t)},Sh=function(e,t){return e==="v"?sx(t):ax(t)},cx=function(e,t){return e==="h"&&t==="rtl"?-1:1},lx=function(e,t,n,r,i){var o=cx(e,window.getComputedStyle(t).direction),s=o*r,a=n.target,c=t.contains(a),l=!1,d=s>0,f=0,h=0;do{var p=Sh(e,a),
|
|
90
|
+
`)},nx=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r,o=he.useMemo(function(){return Jw(i)},[i]);return he.createElement(ex,{styles:tx(o,!t,i,n?"":"!important")})},La=!1;if(typeof window<"u")try{var hi=Object.defineProperty({},"passive",{get:function(){return La=!0,!0}});window.addEventListener("test",hi,hi),window.removeEventListener("test",hi,hi)}catch{La=!1}var Ur=La?{passive:!1}:!1,rx=function(e){return e.tagName==="TEXTAREA"},_h=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!rx(e)&&n[t]==="visible")},ox=function(e){return _h(e,"overflowY")},ix=function(e){return _h(e,"overflowX")},md=function(e,t){var n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=Th(e,n);if(r){var i=Sh(e,n),o=i[1],s=i[2];if(o>s)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},sx=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},ax=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},Th=function(e,t){return e==="v"?ox(t):ix(t)},Sh=function(e,t){return e==="v"?sx(t):ax(t)},cx=function(e,t){return e==="h"&&t==="rtl"?-1:1},lx=function(e,t,n,r,i){var o=cx(e,window.getComputedStyle(t).direction),s=o*r,a=n.target,c=t.contains(a),l=!1,d=s>0,f=0,h=0;do{var p=Sh(e,a),y=p[0],E=p[1],T=p[2],S=E-T-o*y;(y||S)&&Th(e,a)&&(f+=S,h+=y),a=a.parentNode}while(!c&&a!==document.body||c&&(t.contains(a)||t===a));return(d&&(i&&f===0||!i&&s>f)||!d&&(i&&h===0||!i&&-s>h))&&(l=!0),l},mi=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},vd=function(e){return[e.deltaX,e.deltaY]},gd=function(e){return e&&"current"in e?e.current:e},ux=function(e,t){return e[0]===t[0]&&e[1]===t[1]},dx=function(e){return`
|
|
91
91
|
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
92
92
|
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
93
|
-
`)},fx=0,Yr=[];function px(e){var t=he.useRef([]),n=he.useRef([0,0]),r=he.useRef(),i=he.useState(fx++)[0],o=he.useState(function(){return Ch()})[0],s=he.useRef(e);he.useEffect(function(){s.current=e},[e]),he.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var E=kw([e.lockRef.current],(e.shards||[]).map(gd),!0).filter(Boolean);return E.forEach(function(T){return T.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),E.forEach(function(T){return T.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var a=he.useCallback(function(E,T){if("touches"in E&&E.touches.length===2)return!s.current.allowPinchZoom;var S=mi(E),m=n.current,x="deltaX"in E?E.deltaX:m[0]-S[0],_="deltaY"in E?E.deltaY:m[1]-S[1],$,O=E.target,M=Math.abs(x)>Math.abs(_)?"h":"v";if("touches"in E&&M==="h"&&O.type==="range")return!1;var N=md(M,O);if(!N)return!0;if(N?$=M:($=M==="v"?"h":"v",N=md(M,O)),!N)return!1;if(!r.current&&"changedTouches"in E&&(x||_)&&(r.current=$),!$)return!0;var j=r.current||$;return lx(j,T,E,j==="h"?x:_,!0)},[]),c=he.useCallback(function(E){var T=E;if(!(!Yr.length||Yr[Yr.length-1]!==o)){var S="deltaY"in T?vd(T):mi(T),m=t.current.filter(function($){return $.name===T.type&&$.target===T.target&&ux($.delta,S)})[0];if(m&&m.should){T.cancelable&&T.preventDefault();return}if(!m){var x=(s.current.shards||[]).map(gd).filter(Boolean).filter(function($){return $.contains(T.target)}),_=x.length>0?a(T,x[0]):!s.current.noIsolation;_&&T.cancelable&&T.preventDefault()}}},[]),l=he.useCallback(function(E,T,S,m){var x={name:E,delta:T,target:S,should:m};t.current.push(x),setTimeout(function(){t.current=t.current.filter(function(_){return _!==x})},1)},[]),d=he.useCallback(function(E){n.current=mi(E),r.current=void 0},[]),f=he.useCallback(function(E){l(E.type,vd(E),E.target,a(E,e.lockRef.current))},[]),h=he.useCallback(function(E){l(E.type,mi(E),E.target,a(E,e.lockRef.current))},[]);he.useEffect(function(){return Yr.push(o),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:h}),document.addEventListener("wheel",c,Ur),document.addEventListener("touchmove",c,Ur),document.addEventListener("touchstart",d,Ur),function(){Yr=Yr.filter(function(E){return E!==o}),document.removeEventListener("wheel",c,Ur),document.removeEventListener("touchmove",c,Ur),document.removeEventListener("touchstart",d,Ur)}},[]);var p=e.removeScrollBar,w=e.inert;return he.createElement(he.Fragment,null,w?he.createElement(o,{styles:dx(i)}):null,p?he.createElement(nx,{gapMode:"margin"}):null)}const hx=Uw(Eh,px);var $h=he.forwardRef(function(e,t){return he.createElement(gs,dn({},e,{ref:t,sideCar:hx}))});$h.classNames=gs.classNames;const Ph=$h,mx=[" ","Enter","ArrowUp","ArrowDown"],vx=[" ","Enter"],ys="Select",[bs,ws,gx]=os(ys),[fo,gD]=sn(ys,[gx,hs]),Oc=hs(),[yx,jr]=fo(ys),[bx,wx]=fo(ys),xx=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:o,value:s,defaultValue:a,onValueChange:c,dir:l,name:d,autoComplete:f,disabled:h,required:p}=e,w=Oc(t),[E,T]=u.useState(null),[S,m]=u.useState(null),[x,_]=u.useState(!1),$=is(l),[O=!1,M]=pn({prop:r,defaultProp:i,onChange:o}),[N,j]=pn({prop:s,defaultProp:a,onChange:c}),K=u.useRef(null),V=E?!!E.closest("form"):!0,[P,v]=u.useState(new Set),C=Array.from(P).map(I=>I.props.value).join(";");return u.createElement(hh,w,u.createElement(yx,{required:p,scope:t,trigger:E,onTriggerChange:T,valueNode:S,onValueNodeChange:m,valueNodeHasChildren:x,onValueNodeHasChildrenChange:_,contentId:Bn(),value:N,onValueChange:j,open:O,onOpenChange:M,dir:$,triggerPointerDownPosRef:K,disabled:h},u.createElement(bs.Provider,{scope:t},u.createElement(bx,{scope:e.__scopeSelect,onNativeOptionAdd:u.useCallback(I=>{v(k=>new Set(k).add(I))},[]),onNativeOptionRemove:u.useCallback(I=>{v(k=>{const U=new Set(k);return U.delete(I),U})},[])},n)),V?u.createElement(Ah,{key:C,"aria-hidden":!0,required:p,tabIndex:-1,name:d,autoComplete:f,value:N,onChange:I=>j(I.target.value),disabled:h},N===void 0?u.createElement("option",{value:""}):null,Array.from(P)):null))},Ex="SelectTrigger",Cx=u.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...i}=e,o=Oc(n),s=jr(Ex,n),a=s.disabled||r,c=Qe(t,s.onTriggerChange),l=ws(n),[d,f,h]=Dh(w=>{const E=l().filter(m=>!m.disabled),T=E.find(m=>m.value===s.value),S=Oh(E,w,T);S!==void 0&&s.onValueChange(S.value)}),p=()=>{a||(s.onOpenChange(!0),h())};return u.createElement(mh,ie({asChild:!0},o),u.createElement(He.button,ie({type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":s.value===void 0?"":void 0},i,{ref:c,onClick:De(i.onClick,w=>{w.currentTarget.focus()}),onPointerDown:De(i.onPointerDown,w=>{const E=w.target;E.hasPointerCapture(w.pointerId)&&E.releasePointerCapture(w.pointerId),w.button===0&&w.ctrlKey===!1&&(p(),s.triggerPointerDownPosRef.current={x:Math.round(w.pageX),y:Math.round(w.pageY)},w.preventDefault())}),onKeyDown:De(i.onKeyDown,w=>{const E=d.current!=="";!(w.ctrlKey||w.altKey||w.metaKey)&&w.key.length===1&&f(w.key),!(E&&w.key===" ")&&mx.includes(w.key)&&(p(),w.preventDefault())})})))}),_x="SelectValue",Tx=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,children:o,placeholder:s,...a}=e,c=jr(_x,n),{onValueNodeHasChildrenChange:l}=c,d=o!==void 0,f=Qe(t,c.onValueNodeChange);return Wt(()=>{l(d)},[l,d]),u.createElement(He.span,ie({},a,{ref:f,style:{pointerEvents:"none"}}),c.value===void 0&&s!==void 0?s:o)}),Sx=u.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...i}=e;return u.createElement(He.span,ie({"aria-hidden":!0},i,{ref:t}),r||"▼")}),oo="SelectContent",$x=u.forwardRef((e,t)=>{const n=jr(oo,e.__scopeSelect),[r,i]=u.useState();if(Wt(()=>{i(new DocumentFragment)},[]),!n.open){const o=r;return o?fn.createPortal(u.createElement(Rh,{scope:e.__scopeSelect},u.createElement(bs.Slot,{scope:e.__scopeSelect},u.createElement("div",null,e.children))),o):null}return u.createElement(Px,ie({},e,{ref:t}))}),Vn=10,[Rh,Vr]=fo(oo),Px=u.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:o,onPointerDownOutside:s,side:a,sideOffset:c,align:l,alignOffset:d,arrowPadding:f,collisionBoundary:h,collisionPadding:p,sticky:w,hideWhenDetached:E,avoidCollisions:T,...S}=e,m=jr(oo,n),[x,_]=u.useState(null),[$,O]=u.useState(null),M=Qe(t,B=>_(B)),[N,j]=u.useState(null),[K,V]=u.useState(null),P=ws(n),[v,C]=u.useState(!1),I=u.useRef(!1);u.useEffect(()=>{if(x)return bh(x)},[x]),Zp();const k=u.useCallback(B=>{const[H,...J]=P().map(Z=>Z.ref.current),[ee]=J.slice(-1),te=document.activeElement;for(const Z of B)if(Z===te||(Z==null||Z.scrollIntoView({block:"nearest"}),Z===H&&$&&($.scrollTop=0),Z===ee&&$&&($.scrollTop=$.scrollHeight),Z==null||Z.focus(),document.activeElement!==te))return},[P,$]),U=u.useCallback(()=>k([N,x]),[k,N,x]);u.useEffect(()=>{v&&U()},[v,U]);const{onOpenChange:G,triggerPointerDownPosRef:ue}=m;u.useEffect(()=>{if(x){let B={x:0,y:0};const H=ee=>{var te,Z,ge,Te;B={x:Math.abs(Math.round(ee.pageX)-((te=(Z=ue.current)===null||Z===void 0?void 0:Z.x)!==null&&te!==void 0?te:0)),y:Math.abs(Math.round(ee.pageY)-((ge=(Te=ue.current)===null||Te===void 0?void 0:Te.y)!==null&&ge!==void 0?ge:0))}},J=ee=>{B.x<=10&&B.y<=10?ee.preventDefault():x.contains(ee.target)||G(!1),document.removeEventListener("pointermove",H),ue.current=null};return ue.current!==null&&(document.addEventListener("pointermove",H),document.addEventListener("pointerup",J,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",H),document.removeEventListener("pointerup",J,{capture:!0})}}},[x,G,ue]),u.useEffect(()=>{const B=()=>G(!1);return window.addEventListener("blur",B),window.addEventListener("resize",B),()=>{window.removeEventListener("blur",B),window.removeEventListener("resize",B)}},[G]);const[W,L]=Dh(B=>{const H=P().filter(te=>!te.disabled),J=H.find(te=>te.ref.current===document.activeElement),ee=Oh(H,B,J);ee&&setTimeout(()=>ee.ref.current.focus())}),oe=u.useCallback((B,H,J)=>{const ee=!I.current&&!J;(m.value!==void 0&&m.value===H||ee)&&(j(B),ee&&(I.current=!0))},[m.value]),X=u.useCallback(()=>x==null?void 0:x.focus(),[x]),q=u.useCallback((B,H,J)=>{const ee=!I.current&&!J;(m.value!==void 0&&m.value===H||ee)&&V(B)},[m.value]),ne=r==="popper"?yd:Rx,ae=ne===yd?{side:a,sideOffset:c,align:l,alignOffset:d,arrowPadding:f,collisionBoundary:h,collisionPadding:p,sticky:w,hideWhenDetached:E,avoidCollisions:T}:{};return u.createElement(Rh,{scope:n,content:x,viewport:$,onViewportChange:O,itemRefCallback:oe,selectedItem:N,onItemLeave:X,itemTextRefCallback:q,focusSelectedItem:U,selectedItemText:K,position:r,isPositioned:v,searchRef:W},u.createElement(Ph,{as:no,allowPinchZoom:!0},u.createElement(Qp,{asChild:!0,trapped:m.open,onMountAutoFocus:B=>{B.preventDefault()},onUnmountAutoFocus:De(i,B=>{var H;(H=m.trigger)===null||H===void 0||H.focus({preventScroll:!0}),B.preventDefault()})},u.createElement(us,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:B=>B.preventDefault(),onDismiss:()=>m.onOpenChange(!1)},u.createElement(ne,ie({role:"listbox",id:m.contentId,"data-state":m.open?"open":"closed",dir:m.dir,onContextMenu:B=>B.preventDefault()},S,ae,{onPlaced:()=>C(!0),ref:M,style:{display:"flex",flexDirection:"column",outline:"none",...S.style},onKeyDown:De(S.onKeyDown,B=>{const H=B.ctrlKey||B.altKey||B.metaKey;if(B.key==="Tab"&&B.preventDefault(),!H&&B.key.length===1&&L(B.key),["ArrowUp","ArrowDown","Home","End"].includes(B.key)){let ee=P().filter(te=>!te.disabled).map(te=>te.ref.current);if(["ArrowUp","End"].includes(B.key)&&(ee=ee.slice().reverse()),["ArrowUp","ArrowDown"].includes(B.key)){const te=B.target,Z=ee.indexOf(te);ee=ee.slice(Z+1)}setTimeout(()=>k(ee)),B.preventDefault()}})}))))))}),Rx=u.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...i}=e,o=jr(oo,n),s=Vr(oo,n),[a,c]=u.useState(null),[l,d]=u.useState(null),f=Qe(t,M=>d(M)),h=ws(n),p=u.useRef(!1),w=u.useRef(!0),{viewport:E,selectedItem:T,selectedItemText:S,focusSelectedItem:m}=s,x=u.useCallback(()=>{if(o.trigger&&o.valueNode&&a&&l&&E&&T&&S){const M=o.trigger.getBoundingClientRect(),N=l.getBoundingClientRect(),j=o.valueNode.getBoundingClientRect(),K=S.getBoundingClientRect();if(o.dir!=="rtl"){const te=K.left-N.left,Z=j.left-te,ge=M.left-Z,Te=M.width+ge,Ie=Math.max(Te,N.width),Ae=window.innerWidth-Vn,$e=Zu(Z,[Vn,Ae-Ie]);a.style.minWidth=Te+"px",a.style.left=$e+"px"}else{const te=N.right-K.right,Z=window.innerWidth-j.right-te,ge=window.innerWidth-M.right-Z,Te=M.width+ge,Ie=Math.max(Te,N.width),Ae=window.innerWidth-Vn,$e=Zu(Z,[Vn,Ae-Ie]);a.style.minWidth=Te+"px",a.style.right=$e+"px"}const V=h(),P=window.innerHeight-Vn*2,v=E.scrollHeight,C=window.getComputedStyle(l),I=parseInt(C.borderTopWidth,10),k=parseInt(C.paddingTop,10),U=parseInt(C.borderBottomWidth,10),G=parseInt(C.paddingBottom,10),ue=I+k+v+G+U,W=Math.min(T.offsetHeight*5,ue),L=window.getComputedStyle(E),oe=parseInt(L.paddingTop,10),X=parseInt(L.paddingBottom,10),q=M.top+M.height/2-Vn,ne=P-q,ae=T.offsetHeight/2,B=T.offsetTop+ae,H=I+k+B,J=ue-H;if(H<=q){const te=T===V[V.length-1].ref.current;a.style.bottom="0px";const Z=l.clientHeight-E.offsetTop-E.offsetHeight,ge=Math.max(ne,ae+(te?X:0)+Z+U),Te=H+ge;a.style.height=Te+"px"}else{const te=T===V[0].ref.current;a.style.top="0px";const ge=Math.max(q,I+E.offsetTop+(te?oe:0)+ae)+J;a.style.height=ge+"px",E.scrollTop=H-q+E.offsetTop}a.style.margin=`${Vn}px 0`,a.style.minHeight=W+"px",a.style.maxHeight=P+"px",r==null||r(),requestAnimationFrame(()=>p.current=!0)}},[h,o.trigger,o.valueNode,a,l,E,T,S,o.dir,r]);Wt(()=>x(),[x]);const[_,$]=u.useState();Wt(()=>{l&&$(window.getComputedStyle(l).zIndex)},[l]);const O=u.useCallback(M=>{M&&w.current===!0&&(x(),m==null||m(),w.current=!1)},[x,m]);return u.createElement(Ix,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:p,onScrollButtonChange:O},u.createElement("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_}},u.createElement(He.div,ie({},i,{ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}}))))}),yd=u.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:i=Vn,...o}=e,s=Oc(n);return u.createElement(vh,ie({},s,o,{ref:t,align:r,collisionPadding:i,style:{boxSizing:"border-box",...o.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)"}}))}),[Ix,Mc]=fo(oo,{}),bd="SelectViewport",Ax=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=Vr(bd,n),o=Mc(bd,n),s=Qe(t,i.onViewportChange),a=u.useRef(0);return u.createElement(u.Fragment,null,u.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}"}}),u.createElement(bs.Slot,{scope:n},u.createElement(He.div,ie({"data-radix-select-viewport":"",role:"presentation"},r,{ref:s,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:De(r.onScroll,c=>{const l=c.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:f}=o;if(f!=null&&f.current&&d){const h=Math.abs(a.current-l.scrollTop);if(h>0){const p=window.innerHeight-Vn*2,w=parseFloat(d.style.minHeight),E=parseFloat(d.style.height),T=Math.max(w,E);if(T<p){const S=T+h,m=Math.min(p,S),x=S-m;d.style.height=m+"px",d.style.bottom==="0px"&&(l.scrollTop=x>0?x:0,d.style.justifyContent="flex-end")}}}a.current=l.scrollTop})}))))}),Dx="SelectGroup";fo(Dx);const Fa="SelectItem",[Ox,Mx]=fo(Fa),kx=u.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:i=!1,textValue:o,...s}=e,a=jr(Fa,n),c=Vr(Fa,n),l=a.value===r,[d,f]=u.useState(o??""),[h,p]=u.useState(!1),w=Qe(t,S=>{var m;return(m=c.itemRefCallback)===null||m===void 0?void 0:m.call(c,S,r,i)}),E=Bn(),T=()=>{i||(a.onValueChange(r),a.onOpenChange(!1))};return u.createElement(Ox,{scope:n,value:r,disabled:i,textId:E,isSelected:l,onItemTextChange:u.useCallback(S=>{f(m=>{var x;return m||((x=S==null?void 0:S.textContent)!==null&&x!==void 0?x:"").trim()})},[])},u.createElement(bs.ItemSlot,{scope:n,value:r,disabled:i,textValue:d},u.createElement(He.div,ie({role:"option","aria-labelledby":E,"data-highlighted":h?"":void 0,"aria-selected":l&&h,"data-state":l?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1},s,{ref:w,onFocus:De(s.onFocus,()=>p(!0)),onBlur:De(s.onBlur,()=>p(!1)),onPointerUp:De(s.onPointerUp,T),onPointerMove:De(s.onPointerMove,S=>{if(i){var m;(m=c.onItemLeave)===null||m===void 0||m.call(c)}else S.currentTarget.focus({preventScroll:!0})}),onPointerLeave:De(s.onPointerLeave,S=>{if(S.currentTarget===document.activeElement){var m;(m=c.onItemLeave)===null||m===void 0||m.call(c)}}),onKeyDown:De(s.onKeyDown,S=>{var m;((m=c.searchRef)===null||m===void 0?void 0:m.current)!==""&&S.key===" "||(vx.includes(S.key)&&T(),S.key===" "&&S.preventDefault())})}))))}),vi="SelectItemText",Nx=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,...o}=e,s=jr(vi,n),a=Vr(vi,n),c=Mx(vi,n),l=wx(vi,n),[d,f]=u.useState(null),h=Qe(t,S=>f(S),c.onItemTextChange,S=>{var m;return(m=a.itemTextRefCallback)===null||m===void 0?void 0:m.call(a,S,c.value,c.disabled)}),p=d==null?void 0:d.textContent,w=u.useMemo(()=>u.createElement("option",{key:c.value,value:c.value,disabled:c.disabled},p),[c.disabled,c.value,p]),{onNativeOptionAdd:E,onNativeOptionRemove:T}=l;return Wt(()=>(E(w),()=>T(w)),[E,T,w]),u.createElement(u.Fragment,null,u.createElement(He.span,ie({id:c.textId},o,{ref:h})),c.isSelected&&s.valueNode&&!s.valueNodeHasChildren?fn.createPortal(o.children,s.valueNode):null)}),wd="SelectScrollUpButton",jx=u.forwardRef((e,t)=>{const n=Vr(wd,e.__scopeSelect),r=Mc(wd,e.__scopeSelect),[i,o]=u.useState(!1),s=Qe(t,r.onScrollButtonChange);return Wt(()=>{if(n.viewport&&n.isPositioned){let c=function(){const l=a.scrollTop>0;o(l)};const a=n.viewport;return c(),a.addEventListener("scroll",c),()=>a.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?u.createElement(Ih,ie({},e,{ref:s,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}})):null}),xd="SelectScrollDownButton",Vx=u.forwardRef((e,t)=>{const n=Vr(xd,e.__scopeSelect),r=Mc(xd,e.__scopeSelect),[i,o]=u.useState(!1),s=Qe(t,r.onScrollButtonChange);return Wt(()=>{if(n.viewport&&n.isPositioned){let c=function(){const l=a.scrollHeight-a.clientHeight,d=Math.ceil(a.scrollTop)<l;o(d)};const a=n.viewport;return c(),a.addEventListener("scroll",c),()=>a.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?u.createElement(Ih,ie({},e,{ref:s,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}})):null}),Ih=u.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...i}=e,o=Vr("SelectScrollButton",n),s=u.useRef(null),a=ws(n),c=u.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return u.useEffect(()=>()=>c(),[c]),Wt(()=>{var l;const d=a().find(f=>f.ref.current===document.activeElement);d==null||(l=d.ref.current)===null||l===void 0||l.scrollIntoView({block:"nearest"})},[a]),u.createElement(He.div,ie({"aria-hidden":!0},i,{ref:t,style:{flexShrink:0,...i.style},onPointerDown:De(i.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(r,50))}),onPointerMove:De(i.onPointerMove,()=>{var l;(l=o.onItemLeave)===null||l===void 0||l.call(o),s.current===null&&(s.current=window.setInterval(r,50))}),onPointerLeave:De(i.onPointerLeave,()=>{c()})}))}),Ah=u.forwardRef((e,t)=>{const{value:n,...r}=e,i=u.useRef(null),o=Qe(t,i),s=ms(n);return u.useEffect(()=>{const a=i.current,c=window.HTMLSelectElement.prototype,d=Object.getOwnPropertyDescriptor(c,"value").set;if(s!==n&&d){const f=new Event("change",{bubbles:!0});d.call(a,n),a.dispatchEvent(f)}},[s,n]),u.createElement(vs,{asChild:!0},u.createElement("select",ie({},r,{ref:o,defaultValue:n})))});Ah.displayName="BubbleSelect";function Dh(e){const t=qt(e),n=u.useRef(""),r=u.useRef(0),i=u.useCallback(s=>{const a=n.current+s;t(a),function c(l){n.current=l,window.clearTimeout(r.current),l!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),o=u.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return u.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,o]}function Oh(e,t,n){const i=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let s=Lx(e,Math.max(o,0));i.length===1&&(s=s.filter(l=>l!==n));const c=s.find(l=>l.textValue.toLowerCase().startsWith(i.toLowerCase()));return c!==n?c:void 0}function Lx(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Fx=xx,Bx=Cx,Hx=Tx,Wx=Sx,Ux=$x,Yx=Ax,zx=kx,Kx=Nx,qx=jx,Xx=Vx;var Gx=ft({defaultClassName:"_1639370",variantClassNames:{place:{left:"_1639371",right:"_1639372"},state:{default:"_1639373",error:"_1639374",valid:"_1639375",disabled:"_1639376"}},defaultVariants:{state:"default"},compoundVariants:[]});var Zx=ft({defaultClassName:"qormpv0",variantClassNames:{isDisabled:{true:"qormpv1"}},defaultVariants:{isDisabled:!1},compoundVariants:[]});var Qx=ft({defaultClassName:"_1kg30951",variantClassNames:{state:{default:"_1kg30952",error:"_1kg30953",valid:"_1kg30954",disabled:"_1kg30955"}},defaultVariants:{state:"default"},compoundVariants:[]}),Jx="_1kg30950";var e1="ldkv8w2",t1="ldkv8w1",n1="ldkv8w0",r1="ldkv8w3";var o1="yihd6a0",i1=ft({defaultClassName:"yihd6a6",variantClassNames:{state:{default:"yihd6a7 yihd6a1",error:"yihd6a8 yihd6a2",valid:"yihd6a9 yihd6a3",disabled:"yihd6aa yihd6a4"},isTextarea:{true:"yihd6ab"}},defaultVariants:{state:"default",isTextarea:!1},compoundVariants:[[{isTextarea:!0},"yihd6a5"]]}),s1="_18kp58y0";const Ba=({formState:e,place:t,children:n})=>D.jsx("div",{className:Re(Gx({state:e,place:t})),children:D.jsx(Kt,{textStyle:"body2",children:n})});Ba.displayName="Addon";const kc=({isError:e,isDisabled:t,isValid:n})=>t?"disabled":e?"error":n?"valid":"default",po=({children:e,helperTextLeft:t,helperTextRight:n,addonRight:r,addonLeft:i,elementLeft:o,elementRight:s,errorMessage:a,isError:c,isDisabled:l,isValid:d,className:f,inputAreaClassName:h})=>{const p=!!t,w=!!n,E=!p&&w,T=p||w,S=!!i,m=!!r,x=!!o,_=!!s,$=!!a,O=kc({isError:c,isDisabled:l,isValid:d}),M=u.useCallback(()=>O==="disabled"?"$blackTypoMedium":O==="error"?"$redAccent1":O==="valid"?"$greenAccent1":"$blackTypoMedium",[O]),N=()=>c&&$?D.jsx(Kt,{textStyle:"caption",color:M(),children:a}):p&&typeof t=="string"?D.jsx(Kt,{textStyle:"caption",children:t}):p?t:null;return D.jsxs("div",{className:Re(Jx),children:[D.jsx("div",{className:Re(Qx({state:O}),f),children:D.jsxs(Lt,{justifyContent:"space-between",alignItems:"stretch",wrap:"nowrap",children:[S&&D.jsx(Ba,{formState:O,place:"left",children:i}),x&&o,D.jsx("div",{className:Re(o1,h),children:e}),_&&s,m&&D.jsx(Ba,{formState:O,place:"right",children:r})]})}),(T||$)&&D.jsxs(Lt,{justifyContent:E?"flex-end":"space-between",alignItems:"center",mt:"$6",children:[N(),w&&typeof n=="string"?D.jsx(Kt,{textStyle:"caption",children:n}):n]})]})};po.displayName="Field";po.defaultProps={helperTextLeft:void 0,helperTextRight:void 0,addonRight:void 0,addonLeft:void 0,elementRight:void 0,elementLeft:void 0,errorMessage:void 0,isError:void 0,isDisabled:void 0,isValid:void 0,className:void 0,inputAreaClassName:void 0};function zt(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function Ha(e,t){return Ha=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Ha(e,t)}function Nc(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Ha(e,t)}var Wa={exports:{}},gi={exports:{}},ot={};/** @license React v16.13.1
|
|
93
|
+
`)},fx=0,Yr=[];function px(e){var t=he.useRef([]),n=he.useRef([0,0]),r=he.useRef(),i=he.useState(fx++)[0],o=he.useState(function(){return Ch()})[0],s=he.useRef(e);he.useEffect(function(){s.current=e},[e]),he.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var E=kw([e.lockRef.current],(e.shards||[]).map(gd),!0).filter(Boolean);return E.forEach(function(T){return T.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),E.forEach(function(T){return T.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var a=he.useCallback(function(E,T){if("touches"in E&&E.touches.length===2)return!s.current.allowPinchZoom;var S=mi(E),m=n.current,x="deltaX"in E?E.deltaX:m[0]-S[0],_="deltaY"in E?E.deltaY:m[1]-S[1],$,M=E.target,D=Math.abs(x)>Math.abs(_)?"h":"v";if("touches"in E&&D==="h"&&M.type==="range")return!1;var N=md(D,M);if(!N)return!0;if(N?$=D:($=D==="v"?"h":"v",N=md(D,M)),!N)return!1;if(!r.current&&"changedTouches"in E&&(x||_)&&(r.current=$),!$)return!0;var j=r.current||$;return lx(j,T,E,j==="h"?x:_,!0)},[]),c=he.useCallback(function(E){var T=E;if(!(!Yr.length||Yr[Yr.length-1]!==o)){var S="deltaY"in T?vd(T):mi(T),m=t.current.filter(function($){return $.name===T.type&&$.target===T.target&&ux($.delta,S)})[0];if(m&&m.should){T.cancelable&&T.preventDefault();return}if(!m){var x=(s.current.shards||[]).map(gd).filter(Boolean).filter(function($){return $.contains(T.target)}),_=x.length>0?a(T,x[0]):!s.current.noIsolation;_&&T.cancelable&&T.preventDefault()}}},[]),l=he.useCallback(function(E,T,S,m){var x={name:E,delta:T,target:S,should:m};t.current.push(x),setTimeout(function(){t.current=t.current.filter(function(_){return _!==x})},1)},[]),d=he.useCallback(function(E){n.current=mi(E),r.current=void 0},[]),f=he.useCallback(function(E){l(E.type,vd(E),E.target,a(E,e.lockRef.current))},[]),h=he.useCallback(function(E){l(E.type,mi(E),E.target,a(E,e.lockRef.current))},[]);he.useEffect(function(){return Yr.push(o),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:h}),document.addEventListener("wheel",c,Ur),document.addEventListener("touchmove",c,Ur),document.addEventListener("touchstart",d,Ur),function(){Yr=Yr.filter(function(E){return E!==o}),document.removeEventListener("wheel",c,Ur),document.removeEventListener("touchmove",c,Ur),document.removeEventListener("touchstart",d,Ur)}},[]);var p=e.removeScrollBar,y=e.inert;return he.createElement(he.Fragment,null,y?he.createElement(o,{styles:dx(i)}):null,p?he.createElement(nx,{gapMode:"margin"}):null)}const hx=Uw(Eh,px);var $h=he.forwardRef(function(e,t){return he.createElement(gs,dn({},e,{ref:t,sideCar:hx}))});$h.classNames=gs.classNames;const Ph=$h,mx=[" ","Enter","ArrowUp","ArrowDown"],vx=[" ","Enter"],ys="Select",[bs,ws,gx]=os(ys),[fo,gD]=sn(ys,[gx,hs]),Oc=hs(),[yx,jr]=fo(ys),[bx,wx]=fo(ys),xx=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:o,value:s,defaultValue:a,onValueChange:c,dir:l,name:d,autoComplete:f,disabled:h,required:p}=e,y=Oc(t),[E,T]=u.useState(null),[S,m]=u.useState(null),[x,_]=u.useState(!1),$=is(l),[M=!1,D]=pn({prop:r,defaultProp:i,onChange:o}),[N,j]=pn({prop:s,defaultProp:a,onChange:c}),K=u.useRef(null),V=E?!!E.closest("form"):!0,[P,v]=u.useState(new Set),C=Array.from(P).map(I=>I.props.value).join(";");return u.createElement(hh,y,u.createElement(yx,{required:p,scope:t,trigger:E,onTriggerChange:T,valueNode:S,onValueNodeChange:m,valueNodeHasChildren:x,onValueNodeHasChildrenChange:_,contentId:Bn(),value:N,onValueChange:j,open:M,onOpenChange:D,dir:$,triggerPointerDownPosRef:K,disabled:h},u.createElement(bs.Provider,{scope:t},u.createElement(bx,{scope:e.__scopeSelect,onNativeOptionAdd:u.useCallback(I=>{v(k=>new Set(k).add(I))},[]),onNativeOptionRemove:u.useCallback(I=>{v(k=>{const U=new Set(k);return U.delete(I),U})},[])},n)),V?u.createElement(Ah,{key:C,"aria-hidden":!0,required:p,tabIndex:-1,name:d,autoComplete:f,value:N,onChange:I=>j(I.target.value),disabled:h},N===void 0?u.createElement("option",{value:""}):null,Array.from(P)):null))},Ex="SelectTrigger",Cx=u.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...i}=e,o=Oc(n),s=jr(Ex,n),a=s.disabled||r,c=Qe(t,s.onTriggerChange),l=ws(n),[d,f,h]=Dh(y=>{const E=l().filter(m=>!m.disabled),T=E.find(m=>m.value===s.value),S=Oh(E,y,T);S!==void 0&&s.onValueChange(S.value)}),p=()=>{a||(s.onOpenChange(!0),h())};return u.createElement(mh,ie({asChild:!0},o),u.createElement(He.button,ie({type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":s.value===void 0?"":void 0},i,{ref:c,onClick:De(i.onClick,y=>{y.currentTarget.focus()}),onPointerDown:De(i.onPointerDown,y=>{const E=y.target;E.hasPointerCapture(y.pointerId)&&E.releasePointerCapture(y.pointerId),y.button===0&&y.ctrlKey===!1&&(p(),s.triggerPointerDownPosRef.current={x:Math.round(y.pageX),y:Math.round(y.pageY)},y.preventDefault())}),onKeyDown:De(i.onKeyDown,y=>{const E=d.current!=="";!(y.ctrlKey||y.altKey||y.metaKey)&&y.key.length===1&&f(y.key),!(E&&y.key===" ")&&mx.includes(y.key)&&(p(),y.preventDefault())})})))}),_x="SelectValue",Tx=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,children:o,placeholder:s,...a}=e,c=jr(_x,n),{onValueNodeHasChildrenChange:l}=c,d=o!==void 0,f=Qe(t,c.onValueNodeChange);return Wt(()=>{l(d)},[l,d]),u.createElement(He.span,ie({},a,{ref:f,style:{pointerEvents:"none"}}),c.value===void 0&&s!==void 0?s:o)}),Sx=u.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...i}=e;return u.createElement(He.span,ie({"aria-hidden":!0},i,{ref:t}),r||"▼")}),oo="SelectContent",$x=u.forwardRef((e,t)=>{const n=jr(oo,e.__scopeSelect),[r,i]=u.useState();if(Wt(()=>{i(new DocumentFragment)},[]),!n.open){const o=r;return o?fn.createPortal(u.createElement(Rh,{scope:e.__scopeSelect},u.createElement(bs.Slot,{scope:e.__scopeSelect},u.createElement("div",null,e.children))),o):null}return u.createElement(Px,ie({},e,{ref:t}))}),Vn=10,[Rh,Vr]=fo(oo),Px=u.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:o,onPointerDownOutside:s,side:a,sideOffset:c,align:l,alignOffset:d,arrowPadding:f,collisionBoundary:h,collisionPadding:p,sticky:y,hideWhenDetached:E,avoidCollisions:T,...S}=e,m=jr(oo,n),[x,_]=u.useState(null),[$,M]=u.useState(null),D=Qe(t,B=>_(B)),[N,j]=u.useState(null),[K,V]=u.useState(null),P=ws(n),[v,C]=u.useState(!1),I=u.useRef(!1);u.useEffect(()=>{if(x)return bh(x)},[x]),Zp();const k=u.useCallback(B=>{const[H,...J]=P().map(Z=>Z.ref.current),[ee]=J.slice(-1),te=document.activeElement;for(const Z of B)if(Z===te||(Z==null||Z.scrollIntoView({block:"nearest"}),Z===H&&$&&($.scrollTop=0),Z===ee&&$&&($.scrollTop=$.scrollHeight),Z==null||Z.focus(),document.activeElement!==te))return},[P,$]),U=u.useCallback(()=>k([N,x]),[k,N,x]);u.useEffect(()=>{v&&U()},[v,U]);const{onOpenChange:G,triggerPointerDownPosRef:ue}=m;u.useEffect(()=>{if(x){let B={x:0,y:0};const H=ee=>{var te,Z,ge,Te;B={x:Math.abs(Math.round(ee.pageX)-((te=(Z=ue.current)===null||Z===void 0?void 0:Z.x)!==null&&te!==void 0?te:0)),y:Math.abs(Math.round(ee.pageY)-((ge=(Te=ue.current)===null||Te===void 0?void 0:Te.y)!==null&&ge!==void 0?ge:0))}},J=ee=>{B.x<=10&&B.y<=10?ee.preventDefault():x.contains(ee.target)||G(!1),document.removeEventListener("pointermove",H),ue.current=null};return ue.current!==null&&(document.addEventListener("pointermove",H),document.addEventListener("pointerup",J,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",H),document.removeEventListener("pointerup",J,{capture:!0})}}},[x,G,ue]),u.useEffect(()=>{const B=()=>G(!1);return window.addEventListener("blur",B),window.addEventListener("resize",B),()=>{window.removeEventListener("blur",B),window.removeEventListener("resize",B)}},[G]);const[W,L]=Dh(B=>{const H=P().filter(te=>!te.disabled),J=H.find(te=>te.ref.current===document.activeElement),ee=Oh(H,B,J);ee&&setTimeout(()=>ee.ref.current.focus())}),oe=u.useCallback((B,H,J)=>{const ee=!I.current&&!J;(m.value!==void 0&&m.value===H||ee)&&(j(B),ee&&(I.current=!0))},[m.value]),X=u.useCallback(()=>x==null?void 0:x.focus(),[x]),q=u.useCallback((B,H,J)=>{const ee=!I.current&&!J;(m.value!==void 0&&m.value===H||ee)&&V(B)},[m.value]),ne=r==="popper"?yd:Rx,ae=ne===yd?{side:a,sideOffset:c,align:l,alignOffset:d,arrowPadding:f,collisionBoundary:h,collisionPadding:p,sticky:y,hideWhenDetached:E,avoidCollisions:T}:{};return u.createElement(Rh,{scope:n,content:x,viewport:$,onViewportChange:M,itemRefCallback:oe,selectedItem:N,onItemLeave:X,itemTextRefCallback:q,focusSelectedItem:U,selectedItemText:K,position:r,isPositioned:v,searchRef:W},u.createElement(Ph,{as:no,allowPinchZoom:!0},u.createElement(Qp,{asChild:!0,trapped:m.open,onMountAutoFocus:B=>{B.preventDefault()},onUnmountAutoFocus:De(i,B=>{var H;(H=m.trigger)===null||H===void 0||H.focus({preventScroll:!0}),B.preventDefault()})},u.createElement(us,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:B=>B.preventDefault(),onDismiss:()=>m.onOpenChange(!1)},u.createElement(ne,ie({role:"listbox",id:m.contentId,"data-state":m.open?"open":"closed",dir:m.dir,onContextMenu:B=>B.preventDefault()},S,ae,{onPlaced:()=>C(!0),ref:D,style:{display:"flex",flexDirection:"column",outline:"none",...S.style},onKeyDown:De(S.onKeyDown,B=>{const H=B.ctrlKey||B.altKey||B.metaKey;if(B.key==="Tab"&&B.preventDefault(),!H&&B.key.length===1&&L(B.key),["ArrowUp","ArrowDown","Home","End"].includes(B.key)){let ee=P().filter(te=>!te.disabled).map(te=>te.ref.current);if(["ArrowUp","End"].includes(B.key)&&(ee=ee.slice().reverse()),["ArrowUp","ArrowDown"].includes(B.key)){const te=B.target,Z=ee.indexOf(te);ee=ee.slice(Z+1)}setTimeout(()=>k(ee)),B.preventDefault()}})}))))))}),Rx=u.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...i}=e,o=jr(oo,n),s=Vr(oo,n),[a,c]=u.useState(null),[l,d]=u.useState(null),f=Qe(t,D=>d(D)),h=ws(n),p=u.useRef(!1),y=u.useRef(!0),{viewport:E,selectedItem:T,selectedItemText:S,focusSelectedItem:m}=s,x=u.useCallback(()=>{if(o.trigger&&o.valueNode&&a&&l&&E&&T&&S){const D=o.trigger.getBoundingClientRect(),N=l.getBoundingClientRect(),j=o.valueNode.getBoundingClientRect(),K=S.getBoundingClientRect();if(o.dir!=="rtl"){const te=K.left-N.left,Z=j.left-te,ge=D.left-Z,Te=D.width+ge,Ie=Math.max(Te,N.width),Ae=window.innerWidth-Vn,$e=Zu(Z,[Vn,Ae-Ie]);a.style.minWidth=Te+"px",a.style.left=$e+"px"}else{const te=N.right-K.right,Z=window.innerWidth-j.right-te,ge=window.innerWidth-D.right-Z,Te=D.width+ge,Ie=Math.max(Te,N.width),Ae=window.innerWidth-Vn,$e=Zu(Z,[Vn,Ae-Ie]);a.style.minWidth=Te+"px",a.style.right=$e+"px"}const V=h(),P=window.innerHeight-Vn*2,v=E.scrollHeight,C=window.getComputedStyle(l),I=parseInt(C.borderTopWidth,10),k=parseInt(C.paddingTop,10),U=parseInt(C.borderBottomWidth,10),G=parseInt(C.paddingBottom,10),ue=I+k+v+G+U,W=Math.min(T.offsetHeight*5,ue),L=window.getComputedStyle(E),oe=parseInt(L.paddingTop,10),X=parseInt(L.paddingBottom,10),q=D.top+D.height/2-Vn,ne=P-q,ae=T.offsetHeight/2,B=T.offsetTop+ae,H=I+k+B,J=ue-H;if(H<=q){const te=T===V[V.length-1].ref.current;a.style.bottom="0px";const Z=l.clientHeight-E.offsetTop-E.offsetHeight,ge=Math.max(ne,ae+(te?X:0)+Z+U),Te=H+ge;a.style.height=Te+"px"}else{const te=T===V[0].ref.current;a.style.top="0px";const ge=Math.max(q,I+E.offsetTop+(te?oe:0)+ae)+J;a.style.height=ge+"px",E.scrollTop=H-q+E.offsetTop}a.style.margin=`${Vn}px 0`,a.style.minHeight=W+"px",a.style.maxHeight=P+"px",r==null||r(),requestAnimationFrame(()=>p.current=!0)}},[h,o.trigger,o.valueNode,a,l,E,T,S,o.dir,r]);Wt(()=>x(),[x]);const[_,$]=u.useState();Wt(()=>{l&&$(window.getComputedStyle(l).zIndex)},[l]);const M=u.useCallback(D=>{D&&y.current===!0&&(x(),m==null||m(),y.current=!1)},[x,m]);return u.createElement(Ix,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:p,onScrollButtonChange:M},u.createElement("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_}},u.createElement(He.div,ie({},i,{ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}}))))}),yd=u.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:i=Vn,...o}=e,s=Oc(n);return u.createElement(vh,ie({},s,o,{ref:t,align:r,collisionPadding:i,style:{boxSizing:"border-box",...o.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)"}}))}),[Ix,Mc]=fo(oo,{}),bd="SelectViewport",Ax=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,i=Vr(bd,n),o=Mc(bd,n),s=Qe(t,i.onViewportChange),a=u.useRef(0);return u.createElement(u.Fragment,null,u.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}"}}),u.createElement(bs.Slot,{scope:n},u.createElement(He.div,ie({"data-radix-select-viewport":"",role:"presentation"},r,{ref:s,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:De(r.onScroll,c=>{const l=c.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:f}=o;if(f!=null&&f.current&&d){const h=Math.abs(a.current-l.scrollTop);if(h>0){const p=window.innerHeight-Vn*2,y=parseFloat(d.style.minHeight),E=parseFloat(d.style.height),T=Math.max(y,E);if(T<p){const S=T+h,m=Math.min(p,S),x=S-m;d.style.height=m+"px",d.style.bottom==="0px"&&(l.scrollTop=x>0?x:0,d.style.justifyContent="flex-end")}}}a.current=l.scrollTop})}))))}),Dx="SelectGroup";fo(Dx);const Fa="SelectItem",[Ox,Mx]=fo(Fa),kx=u.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:i=!1,textValue:o,...s}=e,a=jr(Fa,n),c=Vr(Fa,n),l=a.value===r,[d,f]=u.useState(o??""),[h,p]=u.useState(!1),y=Qe(t,S=>{var m;return(m=c.itemRefCallback)===null||m===void 0?void 0:m.call(c,S,r,i)}),E=Bn(),T=()=>{i||(a.onValueChange(r),a.onOpenChange(!1))};return u.createElement(Ox,{scope:n,value:r,disabled:i,textId:E,isSelected:l,onItemTextChange:u.useCallback(S=>{f(m=>{var x;return m||((x=S==null?void 0:S.textContent)!==null&&x!==void 0?x:"").trim()})},[])},u.createElement(bs.ItemSlot,{scope:n,value:r,disabled:i,textValue:d},u.createElement(He.div,ie({role:"option","aria-labelledby":E,"data-highlighted":h?"":void 0,"aria-selected":l&&h,"data-state":l?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1},s,{ref:y,onFocus:De(s.onFocus,()=>p(!0)),onBlur:De(s.onBlur,()=>p(!1)),onPointerUp:De(s.onPointerUp,T),onPointerMove:De(s.onPointerMove,S=>{if(i){var m;(m=c.onItemLeave)===null||m===void 0||m.call(c)}else S.currentTarget.focus({preventScroll:!0})}),onPointerLeave:De(s.onPointerLeave,S=>{if(S.currentTarget===document.activeElement){var m;(m=c.onItemLeave)===null||m===void 0||m.call(c)}}),onKeyDown:De(s.onKeyDown,S=>{var m;((m=c.searchRef)===null||m===void 0?void 0:m.current)!==""&&S.key===" "||(vx.includes(S.key)&&T(),S.key===" "&&S.preventDefault())})}))))}),vi="SelectItemText",Nx=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:i,...o}=e,s=jr(vi,n),a=Vr(vi,n),c=Mx(vi,n),l=wx(vi,n),[d,f]=u.useState(null),h=Qe(t,S=>f(S),c.onItemTextChange,S=>{var m;return(m=a.itemTextRefCallback)===null||m===void 0?void 0:m.call(a,S,c.value,c.disabled)}),p=d==null?void 0:d.textContent,y=u.useMemo(()=>u.createElement("option",{key:c.value,value:c.value,disabled:c.disabled},p),[c.disabled,c.value,p]),{onNativeOptionAdd:E,onNativeOptionRemove:T}=l;return Wt(()=>(E(y),()=>T(y)),[E,T,y]),u.createElement(u.Fragment,null,u.createElement(He.span,ie({id:c.textId},o,{ref:h})),c.isSelected&&s.valueNode&&!s.valueNodeHasChildren?fn.createPortal(o.children,s.valueNode):null)}),wd="SelectScrollUpButton",jx=u.forwardRef((e,t)=>{const n=Vr(wd,e.__scopeSelect),r=Mc(wd,e.__scopeSelect),[i,o]=u.useState(!1),s=Qe(t,r.onScrollButtonChange);return Wt(()=>{if(n.viewport&&n.isPositioned){let c=function(){const l=a.scrollTop>0;o(l)};const a=n.viewport;return c(),a.addEventListener("scroll",c),()=>a.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?u.createElement(Ih,ie({},e,{ref:s,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop-c.offsetHeight)}})):null}),xd="SelectScrollDownButton",Vx=u.forwardRef((e,t)=>{const n=Vr(xd,e.__scopeSelect),r=Mc(xd,e.__scopeSelect),[i,o]=u.useState(!1),s=Qe(t,r.onScrollButtonChange);return Wt(()=>{if(n.viewport&&n.isPositioned){let c=function(){const l=a.scrollHeight-a.clientHeight,d=Math.ceil(a.scrollTop)<l;o(d)};const a=n.viewport;return c(),a.addEventListener("scroll",c),()=>a.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?u.createElement(Ih,ie({},e,{ref:s,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop=a.scrollTop+c.offsetHeight)}})):null}),Ih=u.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...i}=e,o=Vr("SelectScrollButton",n),s=u.useRef(null),a=ws(n),c=u.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return u.useEffect(()=>()=>c(),[c]),Wt(()=>{var l;const d=a().find(f=>f.ref.current===document.activeElement);d==null||(l=d.ref.current)===null||l===void 0||l.scrollIntoView({block:"nearest"})},[a]),u.createElement(He.div,ie({"aria-hidden":!0},i,{ref:t,style:{flexShrink:0,...i.style},onPointerDown:De(i.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(r,50))}),onPointerMove:De(i.onPointerMove,()=>{var l;(l=o.onItemLeave)===null||l===void 0||l.call(o),s.current===null&&(s.current=window.setInterval(r,50))}),onPointerLeave:De(i.onPointerLeave,()=>{c()})}))}),Ah=u.forwardRef((e,t)=>{const{value:n,...r}=e,i=u.useRef(null),o=Qe(t,i),s=ms(n);return u.useEffect(()=>{const a=i.current,c=window.HTMLSelectElement.prototype,d=Object.getOwnPropertyDescriptor(c,"value").set;if(s!==n&&d){const f=new Event("change",{bubbles:!0});d.call(a,n),a.dispatchEvent(f)}},[s,n]),u.createElement(vs,{asChild:!0},u.createElement("select",ie({},r,{ref:o,defaultValue:n})))});Ah.displayName="BubbleSelect";function Dh(e){const t=qt(e),n=u.useRef(""),r=u.useRef(0),i=u.useCallback(s=>{const a=n.current+s;t(a),function c(l){n.current=l,window.clearTimeout(r.current),l!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(a)},[t]),o=u.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return u.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,o]}function Oh(e,t,n){const i=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let s=Lx(e,Math.max(o,0));i.length===1&&(s=s.filter(l=>l!==n));const c=s.find(l=>l.textValue.toLowerCase().startsWith(i.toLowerCase()));return c!==n?c:void 0}function Lx(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Fx=xx,Bx=Cx,Hx=Tx,Wx=Sx,Ux=$x,Yx=Ax,zx=kx,Kx=Nx,qx=jx,Xx=Vx;var Gx=ft({defaultClassName:"_1639370",variantClassNames:{place:{left:"_1639371",right:"_1639372"},state:{default:"_1639373",error:"_1639374",valid:"_1639375",disabled:"_1639376"}},defaultVariants:{state:"default"},compoundVariants:[]});var Zx=ft({defaultClassName:"qormpv0",variantClassNames:{isDisabled:{true:"qormpv1"}},defaultVariants:{isDisabled:!1},compoundVariants:[]});var Qx=ft({defaultClassName:"_1kg30951",variantClassNames:{state:{default:"_1kg30952",error:"_1kg30953",valid:"_1kg30954",disabled:"_1kg30955"}},defaultVariants:{state:"default"},compoundVariants:[]}),Jx="_1kg30950";var e1="ldkv8w2",t1="ldkv8w1",n1="ldkv8w0",r1="ldkv8w3";var o1="yihd6a0",i1=ft({defaultClassName:"yihd6a6",variantClassNames:{state:{default:"yihd6a7 yihd6a1",error:"yihd6a8 yihd6a2",valid:"yihd6a9 yihd6a3",disabled:"yihd6aa yihd6a4"},isTextarea:{true:"yihd6ab"}},defaultVariants:{state:"default",isTextarea:!1},compoundVariants:[[{isTextarea:!0},"yihd6a5"]]}),s1="_18kp58y0";const Ba=({formState:e,place:t,children:n})=>O.jsx("div",{className:Re(Gx({state:e,place:t})),children:O.jsx(Kt,{textStyle:"body2",children:n})});Ba.displayName="Addon";const kc=({isError:e,isDisabled:t,isValid:n})=>t?"disabled":e?"error":n?"valid":"default",po=({children:e,helperTextLeft:t,helperTextRight:n,addonRight:r,addonLeft:i,elementLeft:o,elementRight:s,errorMessage:a,isError:c,isDisabled:l,isValid:d,className:f,inputAreaClassName:h,onClick:p})=>{const y=!!t,E=!!n,T=!y&&E,S=y||E,m=!!i,x=!!r,_=!!o,$=!!s,M=!!a,D=kc({isError:c,isDisabled:l,isValid:d}),N=u.useCallback(()=>D==="disabled"?"$blackTypoMedium":D==="error"?"$redAccent1":D==="valid"?"$greenAccent1":"$blackTypoMedium",[D]),j=()=>c&&M?O.jsx(Kt,{textStyle:"caption",color:N(),children:a}):y&&typeof t=="string"?O.jsx(Kt,{textStyle:"caption",children:t}):y?t:null;return O.jsxs("div",{"data-test-id":"CT_Field_Container",className:Re(Jx),onClick:p,children:[O.jsx("div",{className:Re(Qx({state:D}),f),children:O.jsxs(Lt,{justifyContent:"space-between",alignItems:"stretch",wrap:"nowrap",children:[m&&O.jsx(Ba,{formState:D,place:"left",children:i}),_&&o,O.jsx("div",{className:Re(o1,h),children:e}),$&&s,x&&O.jsx(Ba,{formState:D,place:"right",children:r})]})}),(S||M)&&O.jsxs(Lt,{justifyContent:T?"flex-end":"space-between",alignItems:"center",mt:"$6",children:[j(),E&&typeof n=="string"?O.jsx(Kt,{textStyle:"caption",children:n}):n]})]})};po.displayName="Field";po.defaultProps={helperTextLeft:void 0,helperTextRight:void 0,addonRight:void 0,addonLeft:void 0,elementRight:void 0,elementLeft:void 0,errorMessage:void 0,isError:void 0,isDisabled:void 0,isValid:void 0,className:void 0,inputAreaClassName:void 0,onClick:void 0};function zt(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function Ha(e,t){return Ha=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Ha(e,t)}function Nc(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Ha(e,t)}var Wa={exports:{}},gi={exports:{}},ot={};/** @license React v16.13.1
|
|
94
94
|
* react-is.production.min.js
|
|
95
95
|
*
|
|
96
96
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
97
97
|
*
|
|
98
98
|
* This source code is licensed under the MIT license found in the
|
|
99
99
|
* LICENSE file in the root directory of this source tree.
|
|
100
|
-
*/var Ed;function a1(){if(Ed)return ot;Ed=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,
|
|
100
|
+
*/var Ed;function a1(){if(Ed)return ot;Ed=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,y=e?Symbol.for("react.lazy"):60116,E=e?Symbol.for("react.block"):60121,T=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,m=e?Symbol.for("react.scope"):60119;function x($){if(typeof $=="object"&&$!==null){var M=$.$$typeof;switch(M){case t:switch($=$.type,$){case c:case l:case r:case o:case i:case f:return $;default:switch($=$&&$.$$typeof,$){case a:case d:case y:case p:case s:return $;default:return M}}case n:return M}}}function _($){return x($)===l}return ot.AsyncMode=c,ot.ConcurrentMode=l,ot.ContextConsumer=a,ot.ContextProvider=s,ot.Element=t,ot.ForwardRef=d,ot.Fragment=r,ot.Lazy=y,ot.Memo=p,ot.Portal=n,ot.Profiler=o,ot.StrictMode=i,ot.Suspense=f,ot.isAsyncMode=function($){return _($)||x($)===c},ot.isConcurrentMode=_,ot.isContextConsumer=function($){return x($)===a},ot.isContextProvider=function($){return x($)===s},ot.isElement=function($){return typeof $=="object"&&$!==null&&$.$$typeof===t},ot.isForwardRef=function($){return x($)===d},ot.isFragment=function($){return x($)===r},ot.isLazy=function($){return x($)===y},ot.isMemo=function($){return x($)===p},ot.isPortal=function($){return x($)===n},ot.isProfiler=function($){return x($)===o},ot.isStrictMode=function($){return x($)===i},ot.isSuspense=function($){return x($)===f},ot.isValidElementType=function($){return typeof $=="string"||typeof $=="function"||$===r||$===l||$===o||$===i||$===f||$===h||typeof $=="object"&&$!==null&&($.$$typeof===y||$.$$typeof===p||$.$$typeof===s||$.$$typeof===a||$.$$typeof===d||$.$$typeof===T||$.$$typeof===S||$.$$typeof===m||$.$$typeof===E)},ot.typeOf=x,ot}var it={};/** @license React v16.13.1
|
|
101
101
|
* react-is.development.js
|
|
102
102
|
*
|
|
103
103
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
104
104
|
*
|
|
105
105
|
* This source code is licensed under the MIT license found in the
|
|
106
106
|
* LICENSE file in the root directory of this source tree.
|
|
107
|
-
*/var Cd;function c1(){return Cd||(Cd=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,
|
|
107
|
+
*/var Cd;function c1(){return Cd||(Cd=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,y=e?Symbol.for("react.lazy"):60116,E=e?Symbol.for("react.block"):60121,T=e?Symbol.for("react.fundamental"):60117,S=e?Symbol.for("react.responder"):60118,m=e?Symbol.for("react.scope"):60119;function x(Z){return typeof Z=="string"||typeof Z=="function"||Z===r||Z===l||Z===o||Z===i||Z===f||Z===h||typeof Z=="object"&&Z!==null&&(Z.$$typeof===y||Z.$$typeof===p||Z.$$typeof===s||Z.$$typeof===a||Z.$$typeof===d||Z.$$typeof===T||Z.$$typeof===S||Z.$$typeof===m||Z.$$typeof===E)}function _(Z){if(typeof Z=="object"&&Z!==null){var ge=Z.$$typeof;switch(ge){case t:var Te=Z.type;switch(Te){case c:case l:case r:case o:case i:case f:return Te;default:var Ie=Te&&Te.$$typeof;switch(Ie){case a:case d:case y:case p:case s:return Ie;default:return ge}}case n:return ge}}}var $=c,M=l,D=a,N=s,j=t,K=d,V=r,P=y,v=p,C=n,I=o,k=i,U=f,G=!1;function ue(Z){return G||(G=!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.")),W(Z)||_(Z)===c}function W(Z){return _(Z)===l}function L(Z){return _(Z)===a}function oe(Z){return _(Z)===s}function X(Z){return typeof Z=="object"&&Z!==null&&Z.$$typeof===t}function q(Z){return _(Z)===d}function ne(Z){return _(Z)===r}function ae(Z){return _(Z)===y}function B(Z){return _(Z)===p}function H(Z){return _(Z)===n}function J(Z){return _(Z)===o}function ee(Z){return _(Z)===i}function te(Z){return _(Z)===f}it.AsyncMode=$,it.ConcurrentMode=M,it.ContextConsumer=D,it.ContextProvider=N,it.Element=j,it.ForwardRef=K,it.Fragment=V,it.Lazy=P,it.Memo=v,it.Portal=C,it.Profiler=I,it.StrictMode=k,it.Suspense=U,it.isAsyncMode=ue,it.isConcurrentMode=W,it.isContextConsumer=L,it.isContextProvider=oe,it.isElement=X,it.isForwardRef=q,it.isFragment=ne,it.isLazy=ae,it.isMemo=B,it.isPortal=H,it.isProfiler=J,it.isStrictMode=ee,it.isSuspense=te,it.isValidElementType=x,it.typeOf=_}()),it}var _d;function Mh(){return _d||(_d=1,process.env.NODE_ENV==="production"?gi.exports=a1():gi.exports=c1()),gi.exports}/*
|
|
108
108
|
object-assign
|
|
109
109
|
(c) Sindre Sorhus
|
|
110
110
|
@license MIT
|
|
111
|
-
*/var ra,Td;function l1(){if(Td)return ra;Td=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(o){if(o==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(o)}function i(){try{if(!Object.assign)return!1;var o=new String("abc");if(o[5]="de",Object.getOwnPropertyNames(o)[0]==="5")return!1;for(var s={},a=0;a<10;a++)s["_"+String.fromCharCode(a)]=a;var c=Object.getOwnPropertyNames(s).map(function(d){return s[d]});if(c.join("")!=="0123456789")return!1;var l={};return"abcdefghijklmnopqrst".split("").forEach(function(d){l[d]=d}),Object.keys(Object.assign({},l)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return ra=i()?Object.assign:function(o,s){for(var a,c=r(o),l,d=1;d<arguments.length;d++){a=Object(arguments[d]);for(var f in a)t.call(a,f)&&(c[f]=a[f]);if(e){l=e(a);for(var h=0;h<l.length;h++)n.call(a,l[h])&&(c[l[h]]=a[l[h]])}}return c},ra}var oa,Sd;function jc(){if(Sd)return oa;Sd=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return oa=e,oa}var ia,$d;function kh(){return $d||($d=1,ia=Function.call.bind(Object.prototype.hasOwnProperty)),ia}var sa,Pd;function u1(){if(Pd)return sa;Pd=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=jc(),n={},r=kh();e=function(o){var s="Warning: "+o;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function i(o,s,a,c,l){if(process.env.NODE_ENV!=="production"){for(var d in o)if(r(o,d)){var f;try{if(typeof o[d]!="function"){var h=Error((c||"React class")+": "+a+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}f=o[d](s,d,c,a,null,t)}catch(
|
|
112
|
-
Valid keys: `+JSON.stringify(Object.keys(W),null," "));var Z=te(B,ee,q,ne,ae+"."+ee,n);if(Z)return Z}return null}return T(L)}function C(W){switch(typeof W){case"number":case"string":case"undefined":return!0;case"boolean":return!W;case"object":if(Array.isArray(W))return W.every(C);if(W===null||a(W))return!0;var L=f(W);if(L){var oe=L.call(W),X;if(L!==W.entries){for(;!(X=oe.next()).done;)if(!C(X.value))return!1}else for(;!(X=oe.next()).done;){var q=X.value;if(q&&!C(q[1]))return!1}}else return!1;return!0;default:return!1}}function I(W,L){return W==="symbol"?!0:L?L["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&L instanceof Symbol:!1}function k(W){var L=typeof W;return Array.isArray(W)?"array":W instanceof RegExp?"object":I(L,W)?"symbol":L}function U(W){if(typeof W>"u"||W===null)return""+W;var L=k(W);if(L==="object"){if(W instanceof Date)return"date";if(W instanceof RegExp)return"regexp"}return L}function G(W){var L=U(W);switch(L){case"array":case"object":return"an "+L;case"boolean":case"date":case"regexp":return"a "+L;default:return L}}function ue(W){return!W.constructor||!W.constructor.name?h:W.constructor.name}return p.checkPropTypes=i,p.resetWarningCache=i.resetWarningCache,p.PropTypes=p,p},aa}var ca,Id;function f1(){if(Id)return ca;Id=1;var e=jc();function t(){}function n(){}return n.resetWarningCache=t,ca=function(){function r(s,a,c,l,d,f){if(f!==e){var h=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 h.name="Invariant Violation",h}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},ca}if(process.env.NODE_ENV!=="production"){var p1=Mh(),h1=!0;Wa.exports=d1()(p1.isElement,h1)}else Wa.exports=f1()();var m1=Wa.exports;const z=kp(m1);function v1(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function g1(e,t){e.classList?e.classList.add(t):v1(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Ad(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function y1(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Ad(e.className,t):e.setAttribute("class",Ad(e.className&&e.className.baseVal||"",t))}const Dd={disabled:!1};var b1=process.env.NODE_ENV!=="production"?z.oneOfType([z.number,z.shape({enter:z.number,exit:z.number,appear:z.number}).isRequired]):null,w1=process.env.NODE_ENV!=="production"?z.oneOfType([z.string,z.shape({enter:z.string,exit:z.string,active:z.string}),z.shape({enter:z.string,enterDone:z.string,enterActive:z.string,exit:z.string,exitDone:z.string,exitActive:z.string})]):null;const Nh=u.createContext(null);var jh=function(t){return t.scrollTop},So="unmounted",_r="exited",Tr="entering",Kr="entered",Ua="exiting",qn=function(e){Nc(t,e);function t(r,i){var o;o=e.call(this,r,i)||this;var s=i,a=s&&!s.isMounting?r.enter:r.appear,c;return o.appearStatus=null,r.in?a?(c=_r,o.appearStatus=Tr):c=Kr:r.unmountOnExit||r.mountOnEnter?c=So:c=_r,o.state={status:c},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var s=i.in;return s&&o.status===So?{status:_r}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(i){var o=null;if(i!==this.props){var s=this.state.status;this.props.in?s!==Tr&&s!==Kr&&(o=Tr):(s===Tr||s===Kr)&&(o=Ua)}this.updateStatus(!1,o)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var i=this.props.timeout,o,s,a;return o=s=a=i,i!=null&&typeof i!="number"&&(o=i.exit,s=i.enter,a=i.appear!==void 0?i.appear:s),{exit:o,enter:s,appear:a}},n.updateStatus=function(i,o){if(i===void 0&&(i=!1),o!==null)if(this.cancelNextCallback(),o===Tr){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:fn.findDOMNode(this);s&&jh(s)}this.performEnter(i)}else this.performExit();else this.props.unmountOnExit&&this.state.status===_r&&this.setState({status:So})},n.performEnter=function(i){var o=this,s=this.props.enter,a=this.context?this.context.isMounting:i,c=this.props.nodeRef?[a]:[fn.findDOMNode(this),a],l=c[0],d=c[1],f=this.getTimeouts(),h=a?f.appear:f.enter;if(!i&&!s||Dd.disabled){this.safeSetState({status:Kr},function(){o.props.onEntered(l)});return}this.props.onEnter(l,d),this.safeSetState({status:Tr},function(){o.props.onEntering(l,d),o.onTransitionEnd(h,function(){o.safeSetState({status:Kr},function(){o.props.onEntered(l,d)})})})},n.performExit=function(){var i=this,o=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:fn.findDOMNode(this);if(!o||Dd.disabled){this.safeSetState({status:_r},function(){i.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:Ua},function(){i.props.onExiting(a),i.onTransitionEnd(s.exit,function(){i.safeSetState({status:_r},function(){i.props.onExited(a)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(i,o){o=this.setNextCallback(o),this.setState(i,o)},n.setNextCallback=function(i){var o=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,o.nextCallback=null,i(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(i,o){this.setNextCallback(o);var s=this.props.nodeRef?this.props.nodeRef.current:fn.findDOMNode(this),a=i==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],l=c[0],d=c[1];this.props.addEndListener(l,d)}i!=null&&setTimeout(this.nextCallback,i)},n.render=function(){var i=this.state.status;if(i===So)return null;var o=this.props,s=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var a=zt(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return u.createElement(Nh.Provider,{value:null},typeof s=="function"?s(i,a):u.cloneElement(u.Children.only(s),a))},t}(u.Component);qn.contextType=Nh;qn.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:z.shape({current:typeof Element>"u"?z.any:function(e,t,n,r,i,o){var s=e[t];return z.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(e,t,n,r,i,o)}}),children:z.oneOfType([z.func.isRequired,z.element.isRequired]).isRequired,in:z.bool,mountOnEnter:z.bool,unmountOnExit:z.bool,appear:z.bool,enter:z.bool,exit:z.bool,timeout:function(t){var n=b1;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return n.apply(void 0,[t].concat(i))},addEndListener:z.func,onEnter:z.func,onEntering:z.func,onEntered:z.func,onExit:z.func,onExiting:z.func,onExited:z.func}:{};function zr(){}qn.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:zr,onEntering:zr,onEntered:zr,onExit:zr,onExiting:zr,onExited:zr};qn.UNMOUNTED=So;qn.EXITED=_r;qn.ENTERING=Tr;qn.ENTERED=Kr;qn.EXITING=Ua;const Vh=qn;var x1=function(t,n){return t&&n&&n.split(" ").forEach(function(r){return g1(t,r)})},la=function(t,n){return t&&n&&n.split(" ").forEach(function(r){return y1(t,r)})},Vc=function(e){Nc(t,e);function t(){for(var r,i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=e.call.apply(e,[this].concat(o))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(a,c){var l=r.resolveArguments(a,c),d=l[0],f=l[1];r.removeClasses(d,"exit"),r.addClass(d,f?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(a,c)},r.onEntering=function(a,c){var l=r.resolveArguments(a,c),d=l[0],f=l[1],h=f?"appear":"enter";r.addClass(d,h,"active"),r.props.onEntering&&r.props.onEntering(a,c)},r.onEntered=function(a,c){var l=r.resolveArguments(a,c),d=l[0],f=l[1],h=f?"appear":"enter";r.removeClasses(d,h),r.addClass(d,h,"done"),r.props.onEntered&&r.props.onEntered(a,c)},r.onExit=function(a){var c=r.resolveArguments(a),l=c[0];r.removeClasses(l,"appear"),r.removeClasses(l,"enter"),r.addClass(l,"exit","base"),r.props.onExit&&r.props.onExit(a)},r.onExiting=function(a){var c=r.resolveArguments(a),l=c[0];r.addClass(l,"exit","active"),r.props.onExiting&&r.props.onExiting(a)},r.onExited=function(a){var c=r.resolveArguments(a),l=c[0];r.removeClasses(l,"exit"),r.addClass(l,"exit","done"),r.props.onExited&&r.props.onExited(a)},r.resolveArguments=function(a,c){return r.props.nodeRef?[r.props.nodeRef.current,a]:[a,c]},r.getClassNames=function(a){var c=r.props.classNames,l=typeof c=="string",d=l&&c?c+"-":"",f=l?""+d+a:c[a],h=l?f+"-active":c[a+"Active"],p=l?f+"-done":c[a+"Done"];return{baseClassName:f,activeClassName:h,doneClassName:p}},r}var n=t.prototype;return n.addClass=function(i,o,s){var a=this.getClassNames(o)[s+"ClassName"],c=this.getClassNames("enter"),l=c.doneClassName;o==="appear"&&s==="done"&&l&&(a+=" "+l),s==="active"&&i&&jh(i),a&&(this.appliedClasses[o][s]=a,x1(i,a))},n.removeClasses=function(i,o){var s=this.appliedClasses[o],a=s.base,c=s.active,l=s.done;this.appliedClasses[o]={},a&&la(i,a),c&&la(i,c),l&&la(i,l)},n.render=function(){var i=this.props;i.classNames;var o=zt(i,["classNames"]);return u.createElement(Vh,ie({},o,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},t}(u.Component);Vc.defaultProps={classNames:""};Vc.propTypes=process.env.NODE_ENV!=="production"?ie({},Vh.propTypes,{classNames:w1,onEnter:z.func,onEntering:z.func,onEntered:z.func,onExit:z.func,onExiting:z.func,onExited:z.func}):{};const E1=Vc;function Od(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var yi=ft({defaultClassName:"fic97c0",variantClassNames:{animate:{in:"fic97c1",out:"fic97c2"}},defaultVariants:{},compoundVariants:[]});const C1=u.forwardRef(({isOpen:e,onClose:t},n)=>{const r=u.useRef(null),i=n||r;return D.jsx(E1,{in:e,nodeRef:i,timeout:400,unmountOnExit:!0,classNames:{enter:Re(yi({animate:"in"})),enterDone:Re(yi({animate:"in"})),exit:Re(yi({animate:"out"})),exitDone:Re(yi({animate:"out"}))},children:D.jsx("div",{ref:i,"data-test-id":"vds-BS-overlay",onClick:t})})}),Lh=e=>{u.useEffect(e,[e])},xs=({children:e,...t})=>{const[n,r]=u.useState(!1);return Lh(()=>{r(!0)}),n?D.jsx(Iw,{...t,children:e}):null};var _1="_185nehu0",T1=ft({defaultClassName:"_185nehu1 _15kd2weg j1jih7z j1jih7ak j1jih7a0",variantClassNames:{},defaultVariants:{},compoundVariants:[]});const S1=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(zx,{...n,ref:r,className:Re(_1),children:D.jsx(Kx,{children:e})})),Lc=u.forwardRef(({options:e,position:t,placeholder:n,...r},i)=>D.jsx(po,{children:D.jsxs(Fx,{...r,children:[D.jsxs(Bx,{ref:i,className:Re(T1()),"data-test-id":r["data-test-id"],children:[D.jsx(Hx,{placeholder:n}),D.jsx(Wx,{className:"SelectIcon",children:D.jsx(Lo,{})})]}),D.jsx(xs,{children:D.jsxs(Ux,{position:t,style:{overflow:"hidden",backgroundColor:"white",borderRadius:" 6px",width:"100%",boxShadow:" 0px 10px 38px -10px rgba(22, 23, 24, 0.35), 0px 10px 20px -15px rgba(22, 23, 24, 0.2)"},children:[D.jsx(qx,{"data-test-id":"CT_ScrollUp_Icon",style:{textAlign:"center",marginTop:5},children:D.jsx(Tc,{height:15,width:15})}),D.jsx(Yx,{className:"SelectViewport",children:e.map(({label:o,value:s})=>D.jsx(S1,{value:s,children:o},s))}),D.jsx(Xx,{"data-test-id":"CT_ScrollDown_Icon",style:{textAlign:"center"},children:D.jsx(Lo,{height:15,width:15})})]})})]})}));Lc.displayName="BaseSelect";Lc.defaultProps={position:"popper",placeholder:"","data-test-id":void 0};const Fc=u.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Es=u.createContext({}),Cs=u.createContext(null),_s=typeof document<"u",Ts=_s?u.useLayoutEffect:u.useEffect,Fh=u.createContext({strict:!1});function $1(e,t,n,r){const{visualElement:i}=u.useContext(Es),o=u.useContext(Fh),s=u.useContext(Cs),a=u.useContext(Fc).reducedMotion,c=u.useRef();r=r||o.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:i,props:n,presenceContext:s,blockInitialAnimation:s?s.initial===!1:!1,reducedMotionConfig:a}));const l=c.current;u.useInsertionEffect(()=>{l&&l.update(n,s)});const d=u.useRef(!!window.HandoffAppearAnimations);return Ts(()=>{l&&(l.render(),d.current&&l.animationState&&l.animationState.animateChanges())}),u.useEffect(()=>{l&&(l.updateFeatures(),!d.current&&l.animationState&&l.animationState.animateChanges(),window.HandoffAppearAnimations=void 0,d.current=!1)}),l}function Xr(e){return typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function P1(e,t,n){return u.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Xr(n)&&(n.current=r))},[t])}function Bo(e){return typeof e=="string"||Array.isArray(e)}function Ss(e){return typeof e=="object"&&typeof e.start=="function"}const Bc=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Hc=["initial",...Bc];function $s(e){return Ss(e.animate)||Hc.some(t=>Bo(e[t]))}function Bh(e){return!!($s(e)||e.variants)}function R1(e,t){if($s(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Bo(n)?n:void 0,animate:Bo(r)?r:void 0}}return e.inherit!==!1?t:{}}function I1(e){const{initial:t,animate:n}=R1(e,u.useContext(Es));return u.useMemo(()=>({initial:t,animate:n}),[Md(t),Md(n)])}function Md(e){return Array.isArray(e)?e.join(" "):e}const kd={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"]},Ho={};for(const e in kd)Ho[e]={isEnabled:t=>kd[e].some(n=>!!t[n])};function A1(e){for(const t in e)Ho[t]={...Ho[t],...e[t]}}const Wc=u.createContext({}),Hh=u.createContext({}),D1=Symbol.for("motionComponentSymbol");function O1({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:i}){e&&A1(e);function o(a,c){let l;const d={...u.useContext(Fc),...a,layoutId:M1(a)},{isStatic:f}=d,h=I1(a),p=r(a,f);if(!f&&_s){h.visualElement=$1(i,p,d,t);const w=u.useContext(Hh),E=u.useContext(Fh).strict;h.visualElement&&(l=h.visualElement.loadFeatures(d,E,e,w))}return he.createElement(Es.Provider,{value:h},l&&h.visualElement?he.createElement(l,{visualElement:h.visualElement,...d}):null,n(i,a,P1(p,h.visualElement,c),p,f,h.visualElement))}const s=u.forwardRef(o);return s[D1]=i,s}function M1({layoutId:e}){const t=u.useContext(Wc).id;return t&&e!==void 0?t+"-"+e:e}function k1(e){function t(r,i={}){return O1(e(r,i))}if(typeof Proxy>"u")return t;const n=new Map;return new Proxy(t,{get:(r,i)=>(n.has(i)||n.set(i,t(i)),n.get(i))})}const N1=["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 Uc(e){return typeof e!="string"||e.includes("-")?!1:!!(N1.indexOf(e)>-1||/[A-Z]/.test(e))}const Hi={};function j1(e){Object.assign(Hi,e)}const Xo=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Lr=new Set(Xo);function Wh(e,{layout:t,layoutId:n}){return Lr.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Hi[e]||e==="opacity")}const Ut=e=>!!(e&&e.getVelocity),V1={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},L1=Xo.length;function F1(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,i){let o="";for(let s=0;s<L1;s++){const a=Xo[s];if(e[a]!==void 0){const c=V1[a]||a;o+=`${c}(${e[a]}) `}}return t&&!e.z&&(o+="translateZ(0)"),o=o.trim(),i?o=i(e,r?"":o):n&&r&&(o="none"),o}const Uh=e=>t=>typeof t=="string"&&t.startsWith(e),Yh=Uh("--"),Ya=Uh("var(--"),B1=/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,H1=(e,t)=>t&&typeof e=="number"?t.transform(e):e,dr=(e,t,n)=>Math.min(Math.max(n,e),t),Fr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Ro={...Fr,transform:e=>dr(0,1,e)},bi={...Fr,default:1},Io=e=>Math.round(e*1e5)/1e5,Ps=/(-)?([\d]*\.?[\d])+/g,zh=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,W1=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function Go(e){return typeof e=="string"}const Zo=e=>({test:t=>Go(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),rr=Zo("deg"),Rn=Zo("%"),Me=Zo("px"),U1=Zo("vh"),Y1=Zo("vw"),Nd={...Rn,parse:e=>Rn.parse(e)/100,transform:e=>Rn.transform(e*100)},jd={...Fr,transform:Math.round},Kh={borderWidth:Me,borderTopWidth:Me,borderRightWidth:Me,borderBottomWidth:Me,borderLeftWidth:Me,borderRadius:Me,radius:Me,borderTopLeftRadius:Me,borderTopRightRadius:Me,borderBottomRightRadius:Me,borderBottomLeftRadius:Me,width:Me,maxWidth:Me,height:Me,maxHeight:Me,size:Me,top:Me,right:Me,bottom:Me,left:Me,padding:Me,paddingTop:Me,paddingRight:Me,paddingBottom:Me,paddingLeft:Me,margin:Me,marginTop:Me,marginRight:Me,marginBottom:Me,marginLeft:Me,rotate:rr,rotateX:rr,rotateY:rr,rotateZ:rr,scale:bi,scaleX:bi,scaleY:bi,scaleZ:bi,skew:rr,skewX:rr,skewY:rr,distance:Me,translateX:Me,translateY:Me,translateZ:Me,x:Me,y:Me,z:Me,perspective:Me,transformPerspective:Me,opacity:Ro,originX:Nd,originY:Nd,originZ:Me,zIndex:jd,fillOpacity:Ro,strokeOpacity:Ro,numOctaves:jd};function Yc(e,t,n,r){const{style:i,vars:o,transform:s,transformOrigin:a}=e;let c=!1,l=!1,d=!0;for(const f in t){const h=t[f];if(Yh(f)){o[f]=h;continue}const p=Kh[f],w=H1(h,p);if(Lr.has(f)){if(c=!0,s[f]=w,!d)continue;h!==(p.default||0)&&(d=!1)}else f.startsWith("origin")?(l=!0,a[f]=w):i[f]=w}if(t.transform||(c||r?i.transform=F1(e.transform,n,d,r):i.transform&&(i.transform="none")),l){const{originX:f="50%",originY:h="50%",originZ:p=0}=a;i.transformOrigin=`${f} ${h} ${p}`}}const zc=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function qh(e,t,n){for(const r in t)!Ut(t[r])&&!Wh(r,n)&&(e[r]=t[r])}function z1({transformTemplate:e},t,n){return u.useMemo(()=>{const r=zc();return Yc(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}function K1(e,t,n){const r=e.style||{},i={};return qh(i,r,e),Object.assign(i,z1(e,t,n)),e.transformValues?e.transformValues(i):i}function q1(e,t,n){const r={},i=K1(e,t,n);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=i,r}const X1=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 Wi(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||X1.has(e)}let Xh=e=>!Wi(e);function G1(e){e&&(Xh=t=>t.startsWith("on")?!Wi(t):e(t))}try{G1(require("@emotion/is-prop-valid").default)}catch{}function Z1(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(Xh(i)||n===!0&&Wi(i)||!t&&!Wi(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}function Vd(e,t,n){return typeof e=="string"?e:Me.transform(t+n*e)}function Q1(e,t,n){const r=Vd(t,e.x,e.width),i=Vd(n,e.y,e.height);return`${r} ${i}`}const J1={offset:"stroke-dashoffset",array:"stroke-dasharray"},eE={offset:"strokeDashoffset",array:"strokeDasharray"};function tE(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?J1:eE;e[o.offset]=Me.transform(-r);const s=Me.transform(t),a=Me.transform(n);e[o.array]=`${s} ${a}`}function Kc(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:o,pathLength:s,pathSpacing:a=1,pathOffset:c=0,...l},d,f,h){if(Yc(e,l,d,h),f){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:p,style:w,dimensions:E}=e;p.transform&&(E&&(w.transform=p.transform),delete p.transform),E&&(i!==void 0||o!==void 0||w.transform)&&(w.transformOrigin=Q1(E,i!==void 0?i:.5,o!==void 0?o:.5)),t!==void 0&&(p.x=t),n!==void 0&&(p.y=n),r!==void 0&&(p.scale=r),s!==void 0&&tE(p,s,a,c,!1)}const Gh=()=>({...zc(),attrs:{}}),qc=e=>typeof e=="string"&&e.toLowerCase()==="svg";function nE(e,t,n,r){const i=u.useMemo(()=>{const o=Gh();return Kc(o,t,{enableHardwareAcceleration:!1},qc(r),e.transformTemplate),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};qh(o,e.style,e),i.style={...o,...i.style}}return i}function rE(e=!1){return(n,r,i,{latestValues:o},s)=>{const c=(Uc(n)?nE:q1)(r,o,s,n),d={...Z1(r,typeof n=="string",e),...c,ref:i},{children:f}=r,h=u.useMemo(()=>Ut(f)?f.get():f,[f]);return u.createElement(n,{...d,children:h})}}const Xc=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase();function Zh(e,{style:t,vars:n},r,i){Object.assign(e.style,t,i&&i.getProjectionStyles(r));for(const o in n)e.style.setProperty(o,n[o])}const Qh=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 Jh(e,t,n,r){Zh(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(Qh.has(i)?i:Xc(i),t.attrs[i])}function Gc(e,t){const{style:n}=e,r={};for(const i in n)(Ut(n[i])||t.style&&Ut(t.style[i])||Wh(i,e))&&(r[i]=n[i]);return r}function em(e,t){const n=Gc(e,t);for(const r in e)if(Ut(e[r])||Ut(t[r])){const i=Xo.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[i]=e[r]}return n}function Zc(e,t,n,r={},i={}){return typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),t}function Rs(e){const t=u.useRef(null);return t.current===null&&(t.current=e()),t.current}const Ui=e=>Array.isArray(e),oE=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),iE=e=>Ui(e)?e[e.length-1]||0:e;function Ai(e){const t=Ut(e)?e.get():e;return oE(t)?t.toValue():t}function sE({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,i,o){const s={latestValues:aE(r,i,o,e),renderState:t()};return n&&(s.mount=a=>n(r,a,s)),s}const tm=e=>(t,n)=>{const r=u.useContext(Es),i=u.useContext(Cs),o=()=>sE(e,t,r,i);return n?o():Rs(o)};function aE(e,t,n,r){const i={},o=r(e,{});for(const h in o)i[h]=Ai(o[h]);let{initial:s,animate:a}=e;const c=$s(e),l=Bh(e);t&&l&&!c&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||s===!1;const f=d?a:s;return f&&typeof f!="boolean"&&!Ss(f)&&(Array.isArray(f)?f:[f]).forEach(p=>{const w=Zc(e,p);if(!w)return;const{transitionEnd:E,transition:T,...S}=w;for(const m in S){let x=S[m];if(Array.isArray(x)){const _=d?x.length-1:0;x=x[_]}x!==null&&(i[m]=x)}for(const m in E)i[m]=E[m]}),i}const Ct=e=>e;function cE(e){let t=[],n=[],r=0,i=!1,o=!1;const s=new WeakSet,a={schedule:(c,l=!1,d=!1)=>{const f=d&&i,h=f?t:n;return l&&s.add(c),h.indexOf(c)===-1&&(h.push(c),f&&i&&(r=t.length)),c},cancel:c=>{const l=n.indexOf(c);l!==-1&&n.splice(l,1),s.delete(c)},process:c=>{if(i){o=!0;return}if(i=!0,[t,n]=[n,t],n.length=0,r=t.length,r)for(let l=0;l<r;l++){const d=t[l];d(c),s.has(d)&&(a.schedule(d),e())}i=!1,o&&(o=!1,a.process(c))}};return a}const wi=["prepare","read","update","preRender","render","postRender"],lE=40;function uE(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=wi.reduce((f,h)=>(f[h]=cE(()=>n=!0),f),{}),s=f=>o[f].process(i),a=()=>{const f=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(f-i.timestamp,lE),1),i.timestamp=f,i.isProcessing=!0,wi.forEach(s),i.isProcessing=!1,n&&t&&(r=!1,e(a))},c=()=>{n=!0,r=!0,i.isProcessing||e(a)};return{schedule:wi.reduce((f,h)=>{const p=o[h];return f[h]=(w,E=!1,T=!1)=>(n||c(),p.schedule(w,E,T)),f},{}),cancel:f=>wi.forEach(h=>o[h].cancel(f)),state:i,steps:o}}const{schedule:dt,cancel:yn,state:Ht,steps:ua}=uE(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ct,!0),dE={useVisualState:tm({scrapeMotionValuesFromProps:em,createRenderState:Gh,onMount:(e,t,{renderState:n,latestValues:r})=>{dt.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),dt.render(()=>{Kc(n,r,{enableHardwareAcceleration:!1},qc(t.tagName),e.transformTemplate),Jh(t,n)})}})},fE={useVisualState:tm({scrapeMotionValuesFromProps:Gc,createRenderState:zc})};function pE(e,{forwardMotionProps:t=!1},n,r){return{...Uc(e)?dE:fE,preloadedFeatures:n,useRender:rE(t),createVisualElement:r,Component:e}}function Ln(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const nm=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function Is(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const hE=e=>t=>nm(t)&&e(t,Is(t));function Hn(e,t,n,r){return Ln(e,t,hE(n),r)}const mE=(e,t)=>n=>t(e(n)),sr=(...e)=>e.reduce(mE);function rm(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const Ld=rm("dragHorizontal"),Fd=rm("dragVertical");function om(e){let t=!1;if(e==="y")t=Fd();else if(e==="x")t=Ld();else{const n=Ld(),r=Fd();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function im(){const e=om(!0);return e?(e(),!1):!0}class vr{constructor(t){this.isMounted=!1,this.node=t}update(){}}function Bd(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End"),i=(o,s)=>{if(o.type==="touch"||im())return;const a=e.getProps();e.animationState&&a.whileHover&&e.animationState.setActive("whileHover",t),a[r]&&dt.update(()=>a[r](o,s))};return Hn(e.current,n,i,{passive:!e.getProps()[r]})}class vE extends vr{mount(){this.unmount=sr(Bd(this.node,!0),Bd(this.node,!1))}unmount(){}}class gE extends vr{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!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=sr(Ln(this.node.current,"focus",()=>this.onFocus()),Ln(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const sm=(e,t)=>t?e===t?!0:sm(e,t.parentElement):!1;function da(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,Is(n))}class yE extends vr{constructor(){super(...arguments),this.removeStartListeners=Ct,this.removeEndListeners=Ct,this.removeAccessibleListeners=Ct,this.startPointerPress=(t,n)=>{if(this.removeEndListeners(),this.isPressing)return;const r=this.node.getProps(),o=Hn(window,"pointerup",(a,c)=>{if(!this.checkPressEnd())return;const{onTap:l,onTapCancel:d}=this.node.getProps();dt.update(()=>{sm(this.node.current,a.target)?l&&l(a,c):d&&d(a,c)})},{passive:!(r.onTap||r.onPointerUp)}),s=Hn(window,"pointercancel",(a,c)=>this.cancelPress(a,c),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=sr(o,s),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=o=>{if(o.key!=="Enter"||this.isPressing)return;const s=a=>{a.key!=="Enter"||!this.checkPressEnd()||da("up",(c,l)=>{const{onTap:d}=this.node.getProps();d&&dt.update(()=>d(c,l))})};this.removeEndListeners(),this.removeEndListeners=Ln(this.node.current,"keyup",s),da("down",(a,c)=>{this.startPress(a,c)})},n=Ln(this.node.current,"keydown",t),r=()=>{this.isPressing&&da("cancel",(o,s)=>this.cancelPress(o,s))},i=Ln(this.node.current,"blur",r);this.removeAccessibleListeners=sr(n,i)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:i}=this.node.getProps();i&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&dt.update(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!im()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&dt.update(()=>r(t,n))}mount(){const t=this.node.getProps(),n=Hn(this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=Ln(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=sr(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const za=new WeakMap,fa=new WeakMap,bE=e=>{const t=za.get(e.target);t&&t(e)},wE=e=>{e.forEach(bE)};function xE({root:e,...t}){const n=e||document;fa.has(n)||fa.set(n,{});const r=fa.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(wE,{root:e,...t})),r[i]}function EE(e,t,n){const r=xE(t);return za.set(e,n),r.observe(e),()=>{za.delete(e),r.unobserve(e)}}const CE={some:0,all:1};class _E extends vr{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:CE[i]},a=c=>{const{isIntersecting:l}=c;if(this.isInView===l||(this.isInView=l,o&&!l&&this.hasEnteredView))return;l&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",l);const{onViewportEnter:d,onViewportLeave:f}=this.node.getProps(),h=l?d:f;h&&h(c)};return EE(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(TE(t,n))&&this.startObserver()}unmount(){}}function TE({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const SE={inView:{Feature:_E},tap:{Feature:yE},focus:{Feature:gE},hover:{Feature:vE}};function am(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 $E(e){const t={};return e.values.forEach((n,r)=>t[r]=n.get()),t}function PE(e){const t={};return e.values.forEach((n,r)=>t[r]=n.getVelocity()),t}function As(e,t,n){const r=e.getProps();return Zc(r,t,n!==void 0?n:r.custom,$E(e),PE(e))}const RE="framerAppearId",IE="data-"+Xc(RE);let Qo=Ct,rn=Ct;process.env.NODE_ENV!=="production"&&(Qo=(e,t)=>{!e&&typeof console<"u"&&console.warn(t)},rn=(e,t)=>{if(!e)throw new Error(t)});const Wn=e=>e*1e3,In=e=>e/1e3,AE={current:!1},cm=e=>Array.isArray(e)&&typeof e[0]=="number";function lm(e){return!!(!e||typeof e=="string"&&um[e]||cm(e)||Array.isArray(e)&&e.every(lm))}const $o=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,um={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:$o([0,.65,.55,1]),circOut:$o([.55,0,1,.45]),backIn:$o([.31,.01,.66,-.59]),backOut:$o([.33,1.53,.69,.99])};function dm(e){if(e)return cm(e)?$o(e):Array.isArray(e)?e.map(dm):um[e]}function DE(e,t,n,{delay:r=0,duration:i,repeat:o=0,repeatType:s="loop",ease:a,times:c}={}){const l={[t]:n};c&&(l.offset=c);const d=dm(a);return Array.isArray(d)&&(l.easing=d),e.animate(l,{delay:r,duration:i,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:o+1,direction:s==="reverse"?"alternate":"normal"})}function OE(e,{repeat:t,repeatType:n="loop"}){const r=t&&n!=="loop"&&t%2===1?0:e.length-1;return e[r]}const fm=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,ME=1e-7,kE=12;function NE(e,t,n,r,i){let o,s,a=0;do s=t+(n-t)/2,o=fm(s,r,i)-e,o>0?n=s:t=s;while(Math.abs(o)>ME&&++a<kE);return s}function Jo(e,t,n,r){if(e===t&&n===r)return Ct;const i=o=>NE(o,0,1,e,n);return o=>o===0||o===1?o:fm(i(o),t,r)}const jE=Jo(.42,0,1,1),VE=Jo(0,0,.58,1),pm=Jo(.42,0,.58,1),hm=e=>Array.isArray(e)&&typeof e[0]!="number",mm=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,vm=e=>t=>1-e(1-t),gm=e=>1-Math.sin(Math.acos(e)),Qc=vm(gm),LE=mm(Qc),ym=Jo(.33,1.53,.69,.99),Jc=vm(ym),FE=mm(Jc),BE=e=>(e*=2)<1?.5*Jc(e):.5*(2-Math.pow(2,-10*(e-1))),Hd={linear:Ct,easeIn:jE,easeInOut:pm,easeOut:VE,circIn:gm,circInOut:LE,circOut:Qc,backIn:Jc,backInOut:FE,backOut:ym,anticipate:BE},Wd=e=>{if(Array.isArray(e)){rn(e.length===4,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,i]=e;return Jo(t,n,r,i)}else if(typeof e=="string")return rn(Hd[e]!==void 0,`Invalid easing type '${e}'`),Hd[e];return e},el=(e,t)=>n=>!!(Go(n)&&W1.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),bm=(e,t,n)=>r=>{if(!Go(r))return r;const[i,o,s,a]=r.match(Ps);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},HE=e=>dr(0,255,e),pa={...Fr,transform:e=>Math.round(HE(e))},Pr={test:el("rgb","red"),parse:bm("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+pa.transform(e)+", "+pa.transform(t)+", "+pa.transform(n)+", "+Io(Ro.transform(r))+")"};function WE(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Ka={test:el("#"),parse:WE,transform:Pr.transform},Gr={test:el("hsl","hue"),parse:bm("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Rn.transform(Io(t))+", "+Rn.transform(Io(n))+", "+Io(Ro.transform(r))+")"},Yt={test:e=>Pr.test(e)||Ka.test(e)||Gr.test(e),parse:e=>Pr.test(e)?Pr.parse(e):Gr.test(e)?Gr.parse(e):Ka.parse(e),transform:e=>Go(e)?e:e.hasOwnProperty("red")?Pr.transform(e):Gr.transform(e)},yt=(e,t,n)=>-n*e+n*t+e;function ha(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function UE({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,s=0;if(!t)i=o=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,c=2*n-a;i=ha(c,a,e+1/3),o=ha(c,a,e),s=ha(c,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(s*255),alpha:r}}const ma=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},YE=[Ka,Pr,Gr],zE=e=>YE.find(t=>t.test(e));function Ud(e){const t=zE(e);rn(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`);let n=t.parse(e);return t===Gr&&(n=UE(n)),n}const wm=(e,t)=>{const n=Ud(e),r=Ud(t),i={...n};return o=>(i.red=ma(n.red,r.red,o),i.green=ma(n.green,r.green,o),i.blue=ma(n.blue,r.blue,o),i.alpha=yt(n.alpha,r.alpha,o),Pr.transform(i))};function KE(e){var t,n;return isNaN(e)&&Go(e)&&(((t=e.match(Ps))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(zh))===null||n===void 0?void 0:n.length)||0)>0}const xm={regex:B1,countKey:"Vars",token:"${v}",parse:Ct},Em={regex:zh,countKey:"Colors",token:"${c}",parse:Yt.parse},Cm={regex:Ps,countKey:"Numbers",token:"${n}",parse:Fr.parse};function va(e,{regex:t,countKey:n,token:r,parse:i}){const o=e.tokenised.match(t);o&&(e["num"+n]=o.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...o.map(i)))}function Yi(e){const t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&va(n,xm),va(n,Em),va(n,Cm),n}function _m(e){return Yi(e).values}function Tm(e){const{values:t,numColors:n,numVars:r,tokenised:i}=Yi(e),o=t.length;return s=>{let a=i;for(let c=0;c<o;c++)c<r?a=a.replace(xm.token,s[c]):c<r+n?a=a.replace(Em.token,Yt.transform(s[c])):a=a.replace(Cm.token,Io(s[c]));return a}}const qE=e=>typeof e=="number"?0:e;function XE(e){const t=_m(e);return Tm(e)(t.map(qE))}const fr={test:KE,parse:_m,createTransformer:Tm,getAnimatableNone:XE},Sm=(e,t)=>n=>`${n>0?t:e}`;function $m(e,t){return typeof e=="number"?n=>yt(e,t,n):Yt.test(e)?wm(e,t):e.startsWith("var(")?Sm(e,t):Rm(e,t)}const Pm=(e,t)=>{const n=[...e],r=n.length,i=e.map((o,s)=>$m(o,t[s]));return o=>{for(let s=0;s<r;s++)n[s]=i[s](o);return n}},GE=(e,t)=>{const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=$m(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}},Rm=(e,t)=>{const n=fr.createTransformer(t),r=Yi(e),i=Yi(t);return r.numVars===i.numVars&&r.numColors===i.numColors&&r.numNumbers>=i.numNumbers?sr(Pm(r.values,i.values),n):(Qo(!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.`),Sm(e,t))},io=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},Yd=(e,t)=>n=>yt(e,t,n);function ZE(e){return typeof e=="number"?Yd:typeof e=="string"?Yt.test(e)?wm:Rm:Array.isArray(e)?Pm:typeof e=="object"?GE:Yd}function QE(e,t,n){const r=[],i=n||ZE(e[0]),o=e.length-1;for(let s=0;s<o;s++){let a=i(e[s],e[s+1]);if(t){const c=Array.isArray(t)?t[s]||Ct:t;a=sr(c,a)}r.push(a)}return r}function tl(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const o=e.length;if(rn(o===t.length,"Both input and output ranges must be the same length"),o===1)return()=>t[0];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=QE(t,r,i),a=s.length,c=l=>{let d=0;if(a>1)for(;d<e.length-2&&!(l<e[d+1]);d++);const f=io(e[d],e[d+1],l);return s[d](f)};return n?l=>c(dr(e[0],e[o-1],l)):c}function Im(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=io(0,t,r);e.push(yt(n,1,i))}}function Am(e){const t=[0];return Im(t,e.length-1),t}function JE(e,t){return e.map(n=>n*t)}function eC(e,t){return e.map(()=>t||pm).splice(0,e.length-1)}function zi({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=hm(r)?r.map(Wd):Wd(r),o={done:!1,value:t[0]},s=JE(n&&n.length===t.length?n:Am(t),e),a=tl(s,t,{ease:Array.isArray(i)?i:eC(t,i)});return{calculatedDuration:e,next:c=>(o.value=a(c),o.done=c>=e,o)}}function Dm(e,t){return t?e*(1e3/t):0}const tC=5;function Om(e,t,n){const r=Math.max(t-tC,0);return Dm(n-e(r),t-r)}const ga=.001,nC=.01,zd=10,rC=.05,oC=1;function iC({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,o;Qo(e<=Wn(zd),"Spring duration must be 10 seconds or less");let s=1-t;s=dr(rC,oC,s),e=dr(nC,zd,In(e)),s<1?(i=l=>{const d=l*s,f=d*e,h=d-n,p=qa(l,s),w=Math.exp(-f);return ga-h/p*w},o=l=>{const f=l*s*e,h=f*n+n,p=Math.pow(s,2)*Math.pow(l,2)*e,w=Math.exp(-f),E=qa(Math.pow(l,2),s);return(-i(l)+ga>0?-1:1)*((h-p)*w)/E}):(i=l=>{const d=Math.exp(-l*e),f=(l-n)*e+1;return-ga+d*f},o=l=>{const d=Math.exp(-l*e),f=(n-l)*(e*e);return d*f});const a=5/e,c=aC(i,o,a);if(e=Wn(e),isNaN(c))return{stiffness:100,damping:10,duration:e};{const l=Math.pow(c,2)*r;return{stiffness:l,damping:s*2*Math.sqrt(r*l),duration:e}}}const sC=12;function aC(e,t,n){let r=n;for(let i=1;i<sC;i++)r=r-e(r)/t(r);return r}function qa(e,t){return e*Math.sqrt(1-t*t)}const cC=["duration","bounce"],lC=["stiffness","damping","mass"];function Kd(e,t){return t.some(n=>e[n]!==void 0)}function uC(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!Kd(e,lC)&&Kd(e,cC)){const n=iC(e);t={...t,...n,velocity:0,mass:1},t.isResolvedFromDuration=!0}return t}function nl({keyframes:e,restDelta:t,restSpeed:n,...r}){const i=e[0],o=e[e.length-1],s={done:!1,value:i},{stiffness:a,damping:c,mass:l,velocity:d,duration:f,isResolvedFromDuration:h}=uC(r),p=d?-In(d):0,w=c/(2*Math.sqrt(a*l)),E=o-i,T=In(Math.sqrt(a/l)),S=Math.abs(E)<5;n||(n=S?.01:2),t||(t=S?.005:.5);let m;if(w<1){const x=qa(T,w);m=_=>{const $=Math.exp(-w*T*_);return o-$*((p+w*T*E)/x*Math.sin(x*_)+E*Math.cos(x*_))}}else if(w===1)m=x=>o-Math.exp(-T*x)*(E+(p+T*E)*x);else{const x=T*Math.sqrt(w*w-1);m=_=>{const $=Math.exp(-w*T*_),O=Math.min(x*_,300);return o-$*((p+w*T*E)*Math.sinh(O)+x*E*Math.cosh(O))/x}}return{calculatedDuration:h&&f||null,next:x=>{const _=m(x);if(h)s.done=x>=f;else{let $=p;x!==0&&(w<1?$=Om(m,x,_):$=0);const O=Math.abs($)<=n,M=Math.abs(o-_)<=t;s.done=O&&M}return s.value=s.done?o:_,s}}}function qd({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:a,max:c,restDelta:l=.5,restSpeed:d}){const f=e[0],h={done:!1,value:f},p=N=>a!==void 0&&N<a||c!==void 0&&N>c,w=N=>a===void 0?c:c===void 0||Math.abs(a-N)<Math.abs(c-N)?a:c;let E=n*t;const T=f+E,S=s===void 0?T:s(T);S!==T&&(E=S-f);const m=N=>-E*Math.exp(-N/r),x=N=>S+m(N),_=N=>{const j=m(N),K=x(N);h.done=Math.abs(j)<=l,h.value=h.done?S:K};let $,O;const M=N=>{p(h.value)&&($=N,O=nl({keyframes:[h.value,w(h.value)],velocity:Om(x,N,h.value),damping:i,stiffness:o,restDelta:l,restSpeed:d}))};return M(0),{calculatedDuration:null,next:N=>{let j=!1;return!O&&$===void 0&&(j=!0,_(N),M(N)),$!==void 0&&N>$?O.next(N-$):(!j&&_(N),h)}}}const dC=e=>{const t=({timestamp:n})=>e(n);return{start:()=>dt.update(t,!0),stop:()=>yn(t),now:()=>Ht.isProcessing?Ht.timestamp:performance.now()}},Xa=2e4;function Ga(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<Xa;)t+=n,r=e.next(t);return t>=Xa?1/0:t}const fC={decay:qd,inertia:qd,tween:zi,keyframes:zi,spring:nl};function Ki({autoplay:e=!0,delay:t=0,driver:n=dC,keyframes:r,type:i="keyframes",repeat:o=0,repeatDelay:s=0,repeatType:a="loop",onPlay:c,onStop:l,onComplete:d,onUpdate:f,...h}){let p=1,w=!1,E,T;const S=()=>{T=new Promise(L=>{E=L})};S();let m;const x=fC[i]||zi;let _;x!==zi&&typeof r[0]!="number"&&(_=tl([0,100],r,{clamp:!1}),r=[0,100]);const $=x({...h,keyframes:r});let O;a==="mirror"&&(O=x({...h,keyframes:[...r].reverse(),velocity:-(h.velocity||0)}));let M="idle",N=null,j=null,K=null;$.calculatedDuration===null&&o&&($.calculatedDuration=Ga($));const{calculatedDuration:V}=$;let P=1/0,v=1/0;V!==null&&(P=V+s,v=P*(o+1)-s);let C=0;const I=L=>{if(j===null)return;p>0&&(j=Math.min(j,L)),p<0&&(j=Math.min(L-v/p,j)),N!==null?C=N:C=Math.round(L-j)*p;const oe=C-t*(p>=0?1:-1),X=p>=0?oe<0:oe>v;C=Math.max(oe,0),M==="finished"&&N===null&&(C=v);let q=C,ne=$;if(o){const J=C/P;let ee=Math.floor(J),te=J%1;!te&&J>=1&&(te=1),te===1&&ee--,ee=Math.min(ee,o+1);const Z=!!(ee%2);Z&&(a==="reverse"?(te=1-te,s&&(te-=s/P)):a==="mirror"&&(ne=O));let ge=dr(0,1,te);C>v&&(ge=a==="reverse"&&Z?1:0),q=ge*P}const ae=X?{done:!1,value:r[0]}:ne.next(q);_&&(ae.value=_(ae.value));let{done:B}=ae;!X&&V!==null&&(B=p>=0?C>=v:C<=0);const H=N===null&&(M==="finished"||M==="running"&&B);return f&&f(ae.value),H&&G(),ae},k=()=>{m&&m.stop(),m=void 0},U=()=>{M="idle",k(),E(),S(),j=K=null},G=()=>{M="finished",d&&d(),k(),E()},ue=()=>{if(w)return;m||(m=n(I));const L=m.now();c&&c(),N!==null?j=L-N:(!j||M==="finished")&&(j=L),M==="finished"&&S(),K=j,N=null,M="running",m.start()};e&&ue();const W={then(L,oe){return T.then(L,oe)},get time(){return In(C)},set time(L){L=Wn(L),C=L,N!==null||!m||p===0?N=L:j=m.now()-L/p},get duration(){const L=$.calculatedDuration===null?Ga($):$.calculatedDuration;return In(L)},get speed(){return p},set speed(L){L===p||!m||(p=L,W.time=In(C))},get state(){return M},play:ue,pause:()=>{M="paused",N=C},stop:()=>{w=!0,M!=="idle"&&(M="idle",l&&l(),U())},cancel:()=>{K!==null&&I(K),U()},complete:()=>{M="finished"},sample:L=>(j=0,I(L))};return W}function Mm(e){let t;return()=>(t===void 0&&(t=e()),t)}const pC=Mm(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),hC=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),xi=10,mC=2e4,vC=(e,t)=>t.type==="spring"||e==="backgroundColor"||!lm(t.ease);function gC(e,t,{onUpdate:n,onComplete:r,...i}){if(!(pC()&&hC.has(t)&&!i.repeatDelay&&i.repeatType!=="mirror"&&i.damping!==0&&i.type!=="inertia"))return!1;let s=!1,a,c;const l=()=>{c=new Promise(m=>{a=m})};l();let{keyframes:d,duration:f=300,ease:h,times:p}=i;if(vC(t,i)){const m=Ki({...i,repeat:0,delay:0});let x={done:!1,value:d[0]};const _=[];let $=0;for(;!x.done&&$<mC;)x=m.sample($),_.push(x.value),$+=xi;p=void 0,d=_,f=$-xi,h="linear"}const w=DE(e.owner.current,t,d,{...i,duration:f,ease:h,times:p}),E=()=>w.cancel(),T=()=>{dt.update(E),a(),l()};return w.onfinish=()=>{e.set(OE(d,i)),r&&r(),T()},{then(m,x){return c.then(m,x)},attachTimeline(m){return w.timeline=m,w.onfinish=null,Ct},get time(){return In(w.currentTime||0)},set time(m){w.currentTime=Wn(m)},get speed(){return w.playbackRate},set speed(m){w.playbackRate=m},get duration(){return In(f)},play:()=>{s||(w.play(),yn(E))},pause:()=>w.pause(),stop:()=>{if(s=!0,w.playState==="idle")return;const{currentTime:m}=w;if(m){const x=Ki({...i,autoplay:!1});e.setWithVelocity(x.sample(m-xi).value,x.sample(m).value,xi)}T()},complete:()=>w.finish(),cancel:T}}function yC({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const i=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:Ct,pause:Ct,stop:Ct,then:o=>(o(),Promise.resolve()),cancel:Ct,complete:Ct});return t?Ki({keyframes:[0,1],duration:0,delay:t,onComplete:i}):i()}const bC={type:"spring",stiffness:500,damping:25,restSpeed:10},wC=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),xC={type:"keyframes",duration:.8},EC={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},CC=(e,{keyframes:t})=>t.length>2?xC:Lr.has(e)?e.startsWith("scale")?wC(t[1]):bC:EC,Za=(e,t)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(fr.test(t)||t==="0")&&!t.startsWith("url(")),_C=new Set(["brightness","contrast","saturate","opacity"]);function TC(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Ps)||[];if(!r)return e;const i=n.replace(r,"");let o=_C.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const SC=/([a-z-]*)\(.*?\)/g,Qa={...fr,getAnimatableNone:e=>{const t=e.match(SC);return t?t.map(TC).join(" "):e}},$C={...Kh,color:Yt,backgroundColor:Yt,outlineColor:Yt,fill:Yt,stroke:Yt,borderColor:Yt,borderTopColor:Yt,borderRightColor:Yt,borderBottomColor:Yt,borderLeftColor:Yt,filter:Qa,WebkitFilter:Qa},rl=e=>$C[e];function km(e,t){let n=rl(e);return n!==Qa&&(n=fr),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Nm=e=>/^0[^.\s]+$/.test(e);function PC(e){if(typeof e=="number")return e===0;if(e!==null)return e==="none"||e==="0"||Nm(e)}function RC(e,t,n,r){const i=Za(t,n);let o;Array.isArray(n)?o=[...n]:o=[null,n];const s=r.from!==void 0?r.from:e.get();let a;const c=[];for(let l=0;l<o.length;l++)o[l]===null&&(o[l]=l===0?s:o[l-1]),PC(o[l])&&c.push(l),typeof o[l]=="string"&&o[l]!=="none"&&o[l]!=="0"&&(a=o[l]);if(i&&c.length&&a)for(let l=0;l<c.length;l++){const d=c[l];o[d]=km(t,a)}return o}function IC({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:s,repeatDelay:a,from:c,elapsed:l,...d}){return!!Object.keys(d).length}function jm(e,t){return e[t]||e.default||e}const ol=(e,t,n,r={})=>i=>{const o=jm(r,e)||{},s=o.delay||r.delay||0;let{elapsed:a=0}=r;a=a-Wn(s);const c=RC(t,e,n,o),l=c[0],d=c[c.length-1],f=Za(e,l),h=Za(e,d);Qo(f===h,`You are trying to animate ${e} from "${l}" to "${d}". ${l} is not an animatable value - to enable this animation set ${l} to a value animatable to ${d} via the \`style\` property.`);let p={keyframes:c,velocity:t.getVelocity(),ease:"easeOut",...o,delay:-a,onUpdate:w=>{t.set(w),o.onUpdate&&o.onUpdate(w)},onComplete:()=>{i(),o.onComplete&&o.onComplete()}};if(IC(o)||(p={...p,...CC(e,p)}),p.duration&&(p.duration=Wn(p.duration)),p.repeatDelay&&(p.repeatDelay=Wn(p.repeatDelay)),!f||!h||AE.current||o.type===!1)return yC(p);if(t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const w=gC(t,e,p);if(w)return w}return Ki(p)};function qi(e){return!!(Ut(e)&&e.add)}const Vm=e=>/^\-?\d*\.?\d+$/.test(e);function il(e,t){e.indexOf(t)===-1&&e.push(t)}function Ds(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class sl{constructor(){this.subscriptions=[]}add(t){return il(this.subscriptions,t),()=>Ds(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o<i;o++){const s=this.subscriptions[o];s&&s(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Xd=new Set;function Os(e,t,n){e||Xd.has(t)||(console.warn(t),n&&console.warn(n),Xd.add(t))}const AC=e=>!isNaN(parseFloat(e)),Ao={current:void 0};class DC{constructor(t,n={}){this.version="10.16.1",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(r,i=!0)=>{this.prev=this.current,this.current=r;const{delta:o,timestamp:s}=Ht;this.lastUpdated!==s&&(this.timeDelta=o,this.lastUpdated=s,dt.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()),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>dt.postRender(this.velocityCheck),this.velocityCheck=({timestamp:r})=>{r!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=t,this.canTrackVelocity=AC(this.current),this.owner=n.owner}onChange(t){return process.env.NODE_ENV!=="production"&&Os(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new sl);const r=this.events[t].add(n);return t==="change"?()=>{r(),dt.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=t,this.timeDelta=r}jump(t){this.updateAndNotify(t),this.prev=t,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return Ao.current&&Ao.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?Dm(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),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 Or(e,t){return new DC(e,t)}const Lm=e=>t=>t.test(e),OC={test:e=>e==="auto",parse:e=>e},Fm=[Fr,Me,Rn,rr,Y1,U1,OC],Eo=e=>Fm.find(Lm(e)),MC=[...Fm,Yt,fr],kC=e=>MC.find(Lm(e));function NC(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Or(n))}function jC(e,t){const n=As(e,t);let{transitionEnd:r={},transition:i={},...o}=n?e.makeTargetAnimatable(n,!1):{};o={...o,...r};for(const s in o){const a=iE(o[s]);NC(e,s,a)}}function VC(e,t,n){var r,i;const o=Object.keys(t).filter(a=>!e.hasValue(a)),s=o.length;if(s)for(let a=0;a<s;a++){const c=o[a],l=t[c];let d=null;Array.isArray(l)&&(d=l[0]),d===null&&(d=(i=(r=n[c])!==null&&r!==void 0?r:e.readValue(c))!==null&&i!==void 0?i:t[c]),d!=null&&(typeof d=="string"&&(Vm(d)||Nm(d))?d=parseFloat(d):!kC(d)&&fr.test(l)&&(d=km(c,l)),e.addValue(c,Or(d,{owner:e})),n[c]===void 0&&(n[c]=d),d!==null&&e.setBaseTarget(c,d))}}function LC(e,t){return t?(t[e]||t.default||t).from:void 0}function FC(e,t,n){const r={};for(const i in e){const o=LC(i,t);if(o!==void 0)r[i]=o;else{const s=n.getValue(i);s&&(r[i]=s.get())}}return r}function BC({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function al(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o=e.getDefaultTransition(),transitionEnd:s,...a}=e.makeTargetAnimatable(t);const c=e.getValue("willChange");r&&(o=r);const l=[],d=i&&e.animationState&&e.animationState.getState()[i];for(const f in a){const h=e.getValue(f),p=a[f];if(!h||p===void 0||d&&BC(d,f))continue;const w={delay:n,elapsed:0,...o};if(window.HandoffAppearAnimations&&!h.hasAnimated){const T=e.getProps()[IE];T&&(w.elapsed=window.HandoffAppearAnimations(T,f,h,dt))}h.start(ol(f,h,p,e.shouldReduceMotion&&Lr.has(f)?{type:!1}:w));const E=h.animation;qi(c)&&(c.add(f),E.then(()=>c.remove(f))),l.push(E)}return s&&Promise.all(l).then(()=>{s&&jC(e,s)}),l}function Ja(e,t,n={}){const r=As(e,t,n.custom);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(al(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:l=0,staggerChildren:d,staggerDirection:f}=i;return HC(e,t,l+c,d,f,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[c,l]=a==="beforeChildren"?[o,s]:[s,o];return c().then(()=>l())}else return Promise.all([o(),s(n.delay)])}function HC(e,t,n=0,r=0,i=1,o){const s=[],a=(e.variantChildren.size-1)*r,c=i===1?(l=0)=>l*r:(l=0)=>a-l*r;return Array.from(e.variantChildren).sort(WC).forEach((l,d)=>{l.notify("AnimationStart",t),s.push(Ja(l,t,{...o,delay:n+c(d)}).then(()=>l.notify("AnimationComplete",t)))}),Promise.all(s)}function WC(e,t){return e.sortNodePosition(t)}function UC(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>Ja(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=Ja(e,t,n);else{const i=typeof t=="function"?As(e,t,n.custom):t;r=Promise.all(al(e,i,n))}return r.then(()=>e.notify("AnimationComplete",t))}const YC=[...Bc].reverse(),zC=Bc.length;function KC(e){return t=>Promise.all(t.map(({animation:n,options:r})=>UC(e,n,r)))}function qC(e){let t=KC(e);const n=GC();let r=!0;const i=(c,l)=>{const d=As(e,l);if(d){const{transition:f,transitionEnd:h,...p}=d;c={...c,...p,...h}}return c};function o(c){t=c(e)}function s(c,l){const d=e.getProps(),f=e.getVariantContext(!0)||{},h=[],p=new Set;let w={},E=1/0;for(let S=0;S<zC;S++){const m=YC[S],x=n[m],_=d[m]!==void 0?d[m]:f[m],$=Bo(_),O=m===l?x.isActive:null;O===!1&&(E=S);let M=_===f[m]&&_!==d[m]&&$;if(M&&r&&e.manuallyAnimateOnMount&&(M=!1),x.protectedKeys={...w},!x.isActive&&O===null||!_&&!x.prevProp||Ss(_)||typeof _=="boolean")continue;const N=XC(x.prevProp,_);let j=N||m===l&&x.isActive&&!M&&$||S>E&&$;const K=Array.isArray(_)?_:[_];let V=K.reduce(i,{});O===!1&&(V={});const{prevResolvedValues:P={}}=x,v={...P,...V},C=I=>{j=!0,p.delete(I),x.needsAnimating[I]=!0};for(const I in v){const k=V[I],U=P[I];w.hasOwnProperty(I)||(k!==U?Ui(k)&&Ui(U)?!am(k,U)||N?C(I):x.protectedKeys[I]=!0:k!==void 0?C(I):p.add(I):k!==void 0&&p.has(I)?C(I):x.protectedKeys[I]=!0)}x.prevProp=_,x.prevResolvedValues=V,x.isActive&&(w={...w,...V}),r&&e.blockInitialAnimation&&(j=!1),j&&!M&&h.push(...K.map(I=>({animation:I,options:{type:m,...c}})))}if(p.size){const S={};p.forEach(m=>{const x=e.getBaseTarget(m);x!==void 0&&(S[m]=x)}),h.push({animation:S})}let T=!!h.length;return r&&d.initial===!1&&!e.manuallyAnimateOnMount&&(T=!1),r=!1,T?t(h):Promise.resolve()}function a(c,l,d){var f;if(n[c].isActive===l)return Promise.resolve();(f=e.variantChildren)===null||f===void 0||f.forEach(p=>{var w;return(w=p.animationState)===null||w===void 0?void 0:w.setActive(c,l)}),n[c].isActive=l;const h=s(d,c);for(const p in n)n[p].protectedKeys={};return h}return{animateChanges:s,setActive:a,setAnimateFunction:o,getState:()=>n}}function XC(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!am(t,e):!1}function Er(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function GC(){return{animate:Er(!0),whileInView:Er(),whileHover:Er(),whileTap:Er(),whileDrag:Er(),whileFocus:Er(),exit:Er()}}class ZC extends vr{constructor(t){super(t),t.animationState||(t.animationState=qC(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();this.unmount(),Ss(t)&&(this.unmount=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){}}let QC=0;class JC extends vr{constructor(){super(...arguments),this.id=QC++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n,custom:r}=this.node.presenceContext,{isPresent:i}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===i)return;const o=this.node.animationState.setActive("exit",!t,{custom:r??this.node.getProps().custom});n&&!t&&o.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const e_={animation:{Feature:ZC},exit:{Feature:JC}},Gd=(e,t)=>Math.abs(e-t);function t_(e,t){const n=Gd(e.x,t.x),r=Gd(e.y,t.y);return Math.sqrt(n**2+r**2)}class Bm{constructor(t,n,{transformPagePoint:r}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const l=ba(this.lastMoveEventInfo,this.history),d=this.startEvent!==null,f=t_(l.offset,{x:0,y:0})>=3;if(!d&&!f)return;const{point:h}=l,{timestamp:p}=Ht;this.history.push({...h,timestamp:p});const{onStart:w,onMove:E}=this.handlers;d||(w&&w(this.lastMoveEvent,l),this.startEvent=this.lastMoveEvent),E&&E(this.lastMoveEvent,l)},this.handlePointerMove=(l,d)=>{this.lastMoveEvent=l,this.lastMoveEventInfo=ya(d,this.transformPagePoint),dt.update(this.updatePoint,!0)},this.handlePointerUp=(l,d)=>{if(this.end(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const{onEnd:f,onSessionEnd:h}=this.handlers,p=ba(l.type==="pointercancel"?this.lastMoveEventInfo:ya(d,this.transformPagePoint),this.history);this.startEvent&&f&&f(l,p),h&&h(l,p)},!nm(t))return;this.handlers=n,this.transformPagePoint=r;const i=Is(t),o=ya(i,this.transformPagePoint),{point:s}=o,{timestamp:a}=Ht;this.history=[{...s,timestamp:a}];const{onSessionStart:c}=n;c&&c(t,ba(o,this.history)),this.removeListeners=sr(Hn(window,"pointermove",this.handlePointerMove),Hn(window,"pointerup",this.handlePointerUp),Hn(window,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),yn(this.updatePoint)}}function ya(e,t){return t?{point:t(e.point)}:e}function Zd(e,t){return{x:e.x-t.x,y:e.y-t.y}}function ba({point:e},t){return{point:e,delta:Zd(e,Hm(t)),offset:Zd(e,n_(t)),velocity:r_(t,.1)}}function n_(e){return e[0]}function Hm(e){return e[e.length-1]}function r_(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=Hm(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Wn(t)));)n--;if(!r)return{x:0,y:0};const o=In(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function on(e){return e.max-e.min}function ec(e,t=0,n=.01){return Math.abs(e-t)<=n}function Qd(e,t,n,r=.5){e.origin=r,e.originPoint=yt(t.min,t.max,e.origin),e.scale=on(n)/on(t),(ec(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=yt(n.min,n.max,e.origin)-e.originPoint,(ec(e.translate)||isNaN(e.translate))&&(e.translate=0)}function Do(e,t,n,r){Qd(e.x,t.x,n.x,r?r.originX:void 0),Qd(e.y,t.y,n.y,r?r.originY:void 0)}function Jd(e,t,n){e.min=n.min+t.min,e.max=e.min+on(t)}function o_(e,t,n){Jd(e.x,t.x,n.x),Jd(e.y,t.y,n.y)}function ef(e,t,n){e.min=t.min-n.min,e.max=e.min+on(t)}function Oo(e,t,n){ef(e.x,t.x,n.x),ef(e.y,t.y,n.y)}function i_(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?yt(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?yt(n,e,r.max):Math.min(e,n)),e}function tf(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function s_(e,{top:t,left:n,bottom:r,right:i}){return{x:tf(e.x,n,i),y:tf(e.y,t,r)}}function nf(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}}function a_(e,t){return{x:nf(e.x,t.x),y:nf(e.y,t.y)}}function c_(e,t){let n=.5;const r=on(e),i=on(t);return i>r?n=io(t.min,t.max-r,e.min):r>i&&(n=io(e.min,e.max-i,t.min)),dr(0,1,n)}function l_(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const tc=.35;function u_(e=tc){return e===!1?e=0:e===!0&&(e=tc),{x:rf(e,"left","right"),y:rf(e,"top","bottom")}}function rf(e,t,n){return{min:of(e,t),max:of(e,n)}}function of(e,t){return typeof e=="number"?e:e[t]||0}const sf=()=>({translate:0,scale:1,origin:0,originPoint:0}),Zr=()=>({x:sf(),y:sf()}),af=()=>({min:0,max:0}),At=()=>({x:af(),y:af()});function Sn(e){return[e("x"),e("y")]}function Wm({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function d_({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function f_(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}}function wa(e){return e===void 0||e===1}function nc({scale:e,scaleX:t,scaleY:n}){return!wa(e)||!wa(t)||!wa(n)}function Sr(e){return nc(e)||Um(e)||e.z||e.rotate||e.rotateX||e.rotateY}function Um(e){return cf(e.x)||cf(e.y)}function cf(e){return e&&e!=="0%"}function Xi(e,t,n){const r=e-n,i=t*r;return n+i}function lf(e,t,n,r,i){return i!==void 0&&(e=Xi(e,i,r)),Xi(e,n,r)+t}function rc(e,t=0,n=1,r,i){e.min=lf(e.min,t,n,r,i),e.max=lf(e.max,t,n,r,i)}function Ym(e,{x:t,y:n}){rc(e.x,t.translate,t.scale,t.originPoint),rc(e.y,n.translate,n.scale,n.originPoint)}function p_(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let o,s;for(let a=0;a<i;a++){o=n[a],s=o.projectionDelta;const c=o.instance;c&&c.style&&c.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Qr(e,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Ym(e,s)),r&&Sr(o.latestValues)&&Qr(e,o.latestValues))}t.x=uf(t.x),t.y=uf(t.y)}function uf(e){return Number.isInteger(e)||e>1.0000000000001||e<.999999999999?e:1}function or(e,t){e.min=e.min+t,e.max=e.max+t}function df(e,t,[n,r,i]){const o=t[i]!==void 0?t[i]:.5,s=yt(e.min,e.max,o);rc(e,t[n],t[r],s,t.scale)}const h_=["x","scaleX","originX"],m_=["y","scaleY","originY"];function Qr(e,t){df(e.x,t,h_),df(e.y,t,m_)}function zm(e,t){return Wm(f_(e.getBoundingClientRect(),t))}function v_(e,t,n){const r=zm(e,n),{scroll:i}=t;return i&&(or(r.x,i.offset.x),or(r.y,i.offset.y)),r}const g_=new WeakMap;class y_{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=At(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=c=>{this.stopAnimation(),n&&this.snapToCursor(Is(c,"page").point)},o=(c,l)=>{const{drag:d,dragPropagation:f,onDragStart:h}=this.getProps();if(d&&!f&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=om(d),!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),Sn(w=>{let E=this.getAxisMotionValue(w).get()||0;if(Rn.test(E)){const{projection:T}=this.visualElement;if(T&&T.layout){const S=T.layout.layoutBox[w];S&&(E=on(S)*(parseFloat(E)/100))}}this.originPoint[w]=E}),h&&dt.update(()=>h(c,l),!1,!0);const{animationState:p}=this.visualElement;p&&p.setActive("whileDrag",!0)},s=(c,l)=>{const{dragPropagation:d,dragDirectionLock:f,onDirectionLock:h,onDrag:p}=this.getProps();if(!d&&!this.openGlobalLock)return;const{offset:w}=l;if(f&&this.currentDirection===null){this.currentDirection=b_(w),this.currentDirection!==null&&h&&h(this.currentDirection);return}this.updateAxis("x",l.point,w),this.updateAxis("y",l.point,w),this.visualElement.render(),p&&p(c,l)},a=(c,l)=>this.stop(c,l);this.panSession=new Bm(t,{onSessionStart:i,onStart:o,onMove:s,onSessionEnd:a},{transformPagePoint:this.visualElement.getTransformPagePoint()})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=n;this.startAnimation(i);const{onDragEnd:o}=this.getProps();o&&dt.update(()=>o(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!Ei(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=i_(s,this.constraints[t],this.elastic[t])),o.set(s)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),{layout:r}=this.visualElement.projection||{},i=this.constraints;t&&Xr(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=s_(r.layoutBox,t):this.constraints=!1,this.elastic=u_(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Sn(o=>{this.getAxisMotionValue(o)&&(this.constraints[o]=l_(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Xr(t))return!1;const r=t.current;rn(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const o=v_(r,i.root,this.visualElement.getTransformPagePoint());let s=a_(i.layout.layoutBox,o);if(n){const a=n(d_(s));this.hasMutatedConstraints=!!a,a&&(s=Wm(a))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),c=this.constraints||{},l=Sn(d=>{if(!Ei(d,n,this.currentDirection))return;let f=c&&c[d]||{};s&&(f={min:0,max:0});const h=i?200:1e6,p=i?40:1e7,w={type:"inertia",velocity:r?t[d]:0,bounceStiffness:h,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...o,...f};return this.startAxisValueAnimation(d,w)});return Promise.all(l).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return r.start(ol(t,r,0,n))}stopAnimation(){Sn(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n="_drag"+t.toUpperCase(),r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Sn(n=>{const{drag:r}=this.getProps();if(!Ei(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:a}=i.layout.layoutBox[n];o.set(t[n]-yt(s,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Xr(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Sn(s=>{const a=this.getAxisMotionValue(s);if(a){const c=a.get();i[s]=c_({min:c,max:c},this.constraints[s])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Sn(s=>{if(!Ei(s,t,null))return;const a=this.getAxisMotionValue(s),{min:c,max:l}=this.constraints[s];a.set(yt(c,l,i[s]))})}addListeners(){if(!this.visualElement.current)return;g_.set(this.visualElement,this);const t=this.visualElement.current,n=Hn(t,"pointerdown",c=>{const{drag:l,dragListener:d=!0}=this.getProps();l&&d&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();Xr(c)&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,o=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),r();const s=Ln(window,"resize",()=>this.scalePositionWithinConstraints()),a=i.addEventListener("didUpdate",({delta:c,hasLayoutChanged:l})=>{this.isDragging&&l&&(Sn(d=>{const f=this.getAxisMotionValue(d);f&&(this.originPoint[d]+=c[d].translate,f.set(f.get()+c[d].translate))}),this.visualElement.render())});return()=>{s(),n(),o(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:s=tc,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:s,dragMomentum:a}}}function Ei(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function b_(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class w_ extends vr{constructor(t){super(t),this.removeGroupControls=Ct,this.removeListeners=Ct,this.controls=new y_(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ct}unmount(){this.removeGroupControls(),this.removeListeners()}}const ff=e=>(t,n)=>{e&&dt.update(()=>e(t,n))};class x_ extends vr{constructor(){super(...arguments),this.removePointerDownListener=Ct}onPointerDown(t){this.session=new Bm(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint()})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:ff(t),onStart:ff(n),onMove:r,onEnd:(o,s)=>{delete this.session,i&&dt.update(()=>i(o,s))}}}mount(){this.removePointerDownListener=Hn(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}function E_(){const e=u.useContext(Cs);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,i=u.useId();return u.useEffect(()=>r(i),[]),!t&&n?[!1,()=>n&&n(i)]:[!0]}const Di={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function pf(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Co={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(Me.test(e))e=parseFloat(e);else return e;const n=pf(e,t.target.x),r=pf(e,t.target.y);return`${n}% ${r}%`}},C_={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=fr.parse(e);if(i.length>5)return r;const o=fr.createTransformer(e),s=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,c=n.y.scale*t.y;i[0+s]/=a,i[1+s]/=c;const l=yt(a,c,.5);return typeof i[2+s]=="number"&&(i[2+s]/=l),typeof i[3+s]=="number"&&(i[3+s]/=l),o(i)}};class __ extends u.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;j1(T_),o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),Di.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,s=r.projection;return s&&(s.isPresent=o,i||t.layoutDependency!==n||n===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?s.promote():s.relegate()||dt.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),queueMicrotask(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Km(e){const[t,n]=E_(),r=u.useContext(Wc);return u.createElement(__,{...e,layoutGroup:r,switchLayoutGroup:u.useContext(Hh),isPresent:t,safeToRemove:n})}const T_={borderRadius:{...Co,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Co,borderTopRightRadius:Co,borderBottomLeftRadius:Co,borderBottomRightRadius:Co,boxShadow:C_},qm=["TopLeft","TopRight","BottomLeft","BottomRight"],S_=qm.length,hf=e=>typeof e=="string"?parseFloat(e):e,mf=e=>typeof e=="number"||Me.test(e);function $_(e,t,n,r,i,o){i?(e.opacity=yt(0,n.opacity!==void 0?n.opacity:1,P_(r)),e.opacityExit=yt(t.opacity!==void 0?t.opacity:1,0,R_(r))):o&&(e.opacity=yt(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let s=0;s<S_;s++){const a=`border${qm[s]}Radius`;let c=vf(t,a),l=vf(n,a);if(c===void 0&&l===void 0)continue;c||(c=0),l||(l=0),c===0||l===0||mf(c)===mf(l)?(e[a]=Math.max(yt(hf(c),hf(l),r),0),(Rn.test(l)||Rn.test(c))&&(e[a]+="%")):e[a]=l}(t.rotate||n.rotate)&&(e.rotate=yt(t.rotate||0,n.rotate||0,r))}function vf(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const P_=Xm(0,.5,Qc),R_=Xm(.5,.95,Ct);function Xm(e,t,n){return r=>r<e?0:r>t?1:n(io(e,t,r))}function gf(e,t){e.min=t.min,e.max=t.max}function un(e,t){gf(e.x,t.x),gf(e.y,t.y)}function yf(e,t,n,r,i){return e-=t,e=Xi(e,1/n,r),i!==void 0&&(e=Xi(e,1/i,r)),e}function I_(e,t=0,n=1,r=.5,i,o=e,s=e){if(Rn.test(t)&&(t=parseFloat(t),t=yt(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=yt(o.min,o.max,r);e===o&&(a-=t),e.min=yf(e.min,t,n,a,i),e.max=yf(e.max,t,n,a,i)}function bf(e,t,[n,r,i],o,s){I_(e,t[n],t[r],t[i],t.scale,o,s)}const A_=["x","scaleX","originX"],D_=["y","scaleY","originY"];function wf(e,t,n,r){bf(e.x,t,A_,n?n.x:void 0,r?r.x:void 0),bf(e.y,t,D_,n?n.y:void 0,r?r.y:void 0)}function xf(e){return e.translate===0&&e.scale===1}function Gm(e){return xf(e.x)&&xf(e.y)}function O_(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 Zm(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function Ef(e){return on(e.x)/on(e.y)}class M_{constructor(){this.members=[]}add(t){il(this.members,t),t.scheduleRender()}remove(t){if(Ds(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const o=this.members[i];if(o.isPresent!==!1){r=o;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function Cf(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y;if((i||o)&&(r=`translate3d(${i}px, ${o}px, 0) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:c,rotateX:l,rotateY:d}=n;c&&(r+=`rotate(${c}deg) `),l&&(r+=`rotateX(${l}deg) `),d&&(r+=`rotateY(${d}deg) `)}const s=e.x.scale*t.x,a=e.y.scale*t.y;return(s!==1||a!==1)&&(r+=`scale(${s}, ${a})`),r||"none"}const k_=(e,t)=>e.depth-t.depth;class N_{constructor(){this.children=[],this.isDirty=!1}add(t){il(this.children,t),this.isDirty=!0}remove(t){Ds(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(k_),this.isDirty=!1,this.children.forEach(t)}}function j_(e,t){const n=performance.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(yn(r),e(o-t))};return dt.read(r,!0),()=>yn(r)}function V_(e){window.MotionDebug&&window.MotionDebug.record(e)}function Qm(e){return e instanceof SVGElement&&e.tagName!=="svg"}function cl(e,t,n){const r=Ut(e)?e:Or(e);return r.start(ol("",r,t,n)),r.animation}const _f=["","X","Y","Z"],Tf=1e3;let L_=0;const $r={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function Jm({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},a=t==null?void 0:t()){this.id=L_++,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.hasTreeAnimated=!1,this.updateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{$r.totalNodes=$r.resolvedTargetDeltas=$r.recalculatedProjection=0,this.nodes.forEach(H_),this.nodes.forEach(K_),this.nodes.forEach(q_),this.nodes.forEach(W_),V_($r)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new N_)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new sl),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const c=this.eventHandlers.get(s);c&&c.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s,a=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=Qm(s),this.instance=s;const{layoutId:c,layout:l,visualElement:d}=this.options;if(d&&!d.current&&d.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),a&&(l||c)&&(this.isLayoutDirty=!0),e){let f;const h=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,f&&f(),f=j_(h,250),Di.hasAnimatedSinceResize&&(Di.hasAnimatedSinceResize=!1,this.nodes.forEach($f))})}c&&this.root.registerSharedNode(c,this),this.options.animate!==!1&&d&&(c||l)&&this.addEventListener("didUpdate",({delta:f,hasLayoutChanged:h,hasRelativeTargetChanged:p,layout:w})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const E=this.options.transition||d.getDefaultTransition()||J_,{onLayoutAnimationStart:T,onLayoutAnimationComplete:S}=d.getProps(),m=!this.targetLayout||!Zm(this.targetLayout,w)||p,x=!h&&p;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||x||h&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(f,x);const _={...jm(E,"layout"),onPlay:T,onComplete:S};(d.shouldReduceMotion||this.options.layoutRoot)&&(_.delay=0,_.type=!1),this.startAnimation(_)}else h||$f(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=w})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,yn(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(X_),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const f=this.path[d];f.shouldResetTransform=!0,f.updateScroll("snapshot"),f.options.layoutRoot&&f.willUpdate(!1)}const{layoutId:a,layout:c}=this.options;if(a===void 0&&!c)return;const l=this.getTransformTemplate();this.prevTransformTemplateValue=l?l(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Sf);return}this.isUpdating||this.nodes.forEach(Y_),this.isUpdating=!1,this.nodes.forEach(z_),this.nodes.forEach(F_),this.nodes.forEach(B_),this.clearAllSnapshots();const a=performance.now();Ht.delta=dr(0,1e3/60,a-Ht.timestamp),Ht.timestamp=a,Ht.isProcessing=!0,ua.update.process(Ht),ua.preRender.process(Ht),ua.render.process(Ht),Ht.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,queueMicrotask(()=>this.update()))}clearAllSnapshots(){this.nodes.forEach(U_),this.sharedNodes.forEach(G_)}scheduleUpdateProjection(){dt.preRender(this.updateProjection,!1,!0)}scheduleCheckAfterUnmount(){dt.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let c=0;c<this.path.length;c++)this.path[c].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutCorrected=At(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&(this.scroll={animationId:this.root.animationId,phase:s,isRoot:r(this.instance),offset:n(this.instance)})}resetTransform(){if(!i)return;const s=this.isLayoutDirty||this.shouldResetTransform,a=this.projectionDelta&&!Gm(this.projectionDelta),c=this.getTransformTemplate(),l=c?c(this.latestValues,""):void 0,d=l!==this.prevTransformTemplateValue;s&&(a||Sr(this.latestValues)||d)&&(i(this.instance,l),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let c=this.removeElementScroll(a);return s&&(c=this.removeTransform(c)),eT(c),{animationId:this.root.animationId,measuredBox:a,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return At();const a=s.measureViewportBox(),{scroll:c}=this.root;return c&&(or(a.x,c.offset.x),or(a.y,c.offset.y)),a}removeElementScroll(s){const a=At();un(a,s);for(let c=0;c<this.path.length;c++){const l=this.path[c],{scroll:d,options:f}=l;if(l!==this.root&&d&&f.layoutScroll){if(d.isRoot){un(a,s);const{scroll:h}=this.root;h&&(or(a.x,-h.offset.x),or(a.y,-h.offset.y))}or(a.x,d.offset.x),or(a.y,d.offset.y)}}return a}applyTransform(s,a=!1){const c=At();un(c,s);for(let l=0;l<this.path.length;l++){const d=this.path[l];!a&&d.options.layoutScroll&&d.scroll&&d!==d.root&&Qr(c,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),Sr(d.latestValues)&&Qr(c,d.latestValues)}return Sr(this.latestValues)&&Qr(c,this.latestValues),c}removeTransform(s){const a=At();un(a,s);for(let c=0;c<this.path.length;c++){const l=this.path[c];if(!l.instance||!Sr(l.latestValues))continue;nc(l.latestValues)&&l.updateSnapshot();const d=At(),f=l.measurePageBox();un(d,f),wf(a,l.latestValues,l.snapshot?l.snapshot.layoutBox:void 0,d)}return Sr(this.latestValues)&&wf(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}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}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Ht.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var a;const c=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=c.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=c.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=c.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==c;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||!((a=this.parent)===null||a===void 0)&&a.isProjectionDirty||this.attemptToResolveRelativeTarget))return;const{layout:f,layoutId:h}=this.options;if(!(!this.layout||!(f||h))){if(this.resolvedRelativeTargetAt=Ht.timestamp,!this.targetDelta&&!this.relativeTarget){const p=this.getClosestProjectingParent();p&&p.layout&&this.animationProgress!==1?(this.relativeParent=p,this.forceRelativeParentToResolveTarget(),this.relativeTarget=At(),this.relativeTargetOrigin=At(),Oo(this.relativeTargetOrigin,this.layout.layoutBox,p.layout.layoutBox),un(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=At(),this.targetWithTransforms=At()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),o_(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):un(this.target,this.layout.layoutBox),Ym(this.target,this.targetDelta)):un(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const p=this.getClosestProjectingParent();p&&!!p.resumingFrom==!!this.resumingFrom&&!p.options.layoutScroll&&p.target&&this.animationProgress!==1?(this.relativeParent=p,this.forceRelativeParentToResolveTarget(),this.relativeTarget=At(),this.relativeTargetOrigin=At(),Oo(this.relativeTargetOrigin,this.target,p.target),un(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}$r.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||nc(this.parent.latestValues)||Um(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;const a=this.getLead(),c=!!this.resumingFrom||this!==a;let l=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(l=!1),c&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===Ht.timestamp&&(l=!1),l)return;const{layout:d,layoutId:f}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(d||f))return;un(this.layoutCorrected,this.layout.layoutBox);const h=this.treeScale.x,p=this.treeScale.y;p_(this.layoutCorrected,this.treeScale,this.path,c),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox);const{target:w}=a;if(!w){this.projectionTransform&&(this.projectionDelta=Zr(),this.projectionTransform="none",this.scheduleRender());return}this.projectionDelta||(this.projectionDelta=Zr(),this.projectionDeltaWithTransform=Zr());const E=this.projectionTransform;Do(this.projectionDelta,this.layoutCorrected,w,this.latestValues),this.projectionTransform=Cf(this.projectionDelta,this.treeScale),(this.projectionTransform!==E||this.treeScale.x!==h||this.treeScale.y!==p)&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",w)),$r.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.scheduleRender&&this.options.scheduleRender(),s){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}setAnimationOrigin(s,a=!1){const c=this.snapshot,l=c?c.latestValues:{},d={...this.latestValues},f=Zr();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=At(),p=c?c.source:void 0,w=this.layout?this.layout.source:void 0,E=p!==w,T=this.getStack(),S=!T||T.members.length<=1,m=!!(E&&!S&&this.options.crossfade===!0&&!this.path.some(Q_));this.animationProgress=0;let x;this.mixTargetDelta=_=>{const $=_/1e3;Pf(f.x,s.x,$),Pf(f.y,s.y,$),this.setTargetDelta(f),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Oo(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Z_(this.relativeTarget,this.relativeTargetOrigin,h,$),x&&O_(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=At()),un(x,this.relativeTarget)),E&&(this.animationValues=d,$_(d,l,this.latestValues,$,m,S)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=$},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(yn(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=dt.update(()=>{Di.hasAnimatedSinceResize=!0,this.currentAnimation=cl(0,Tf,{...s,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onComplete:()=>{s.onComplete&&s.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 s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Tf),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:c,layout:l,latestValues:d}=s;if(!(!a||!c||!l)){if(this!==s&&this.layout&&l&&ev(this.options.animationType,this.layout.layoutBox,l.layoutBox)){c=this.target||At();const f=on(this.layout.layoutBox.x);c.x.min=s.target.x.min,c.x.max=c.x.min+f;const h=on(this.layout.layoutBox.y);c.y.min=s.target.y.min,c.y.max=c.y.min+h}un(a,c),Qr(a,d),Do(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new M_),this.sharedNodes.get(s).add(a);const l=a.options.initialPromotionConfig;a.promote({transition:l?l.transition:void 0,preserveFollowOpacity:l&&l.shouldPreserveFollowOpacity?l.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var s;const{layoutId:a}=this.options;return a?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;const{layoutId:a}=this.options;return a?(s=this.getStack())===null||s===void 0?void 0:s.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:c}={}){const l=this.getStack();l&&l.promote(this,c),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:c}=s;if((c.rotate||c.rotateX||c.rotateY||c.rotateZ)&&(a=!0),!a)return;const l={};for(let d=0;d<_f.length;d++){const f="rotate"+_f[d];c[f]&&(l[f]=c[f],s.setStaticValue(f,0))}s.render();for(const d in l)s.setStaticValue(d,l[d]);s.scheduleRender()}getProjectionStyles(s={}){var a,c;const l={};if(!this.instance||this.isSVG)return l;if(this.isVisible)l.visibility="";else return{visibility:"hidden"};const d=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,l.opacity="",l.pointerEvents=Ai(s.pointerEvents)||"",l.transform=d?d(this.latestValues,""):"none",l;const f=this.getLead();if(!this.projectionDelta||!this.layout||!f.target){const E={};return this.options.layoutId&&(E.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,E.pointerEvents=Ai(s.pointerEvents)||""),this.hasProjected&&!Sr(this.latestValues)&&(E.transform=d?d({},""):"none",this.hasProjected=!1),E}const h=f.animationValues||f.latestValues;this.applyTransformsToTarget(),l.transform=Cf(this.projectionDeltaWithTransform,this.treeScale,h),d&&(l.transform=d(h,l.transform));const{x:p,y:w}=this.projectionDelta;l.transformOrigin=`${p.origin*100}% ${w.origin*100}% 0`,f.animationValues?l.opacity=f===this?(c=(a=h.opacity)!==null&&a!==void 0?a:this.latestValues.opacity)!==null&&c!==void 0?c:1:this.preserveOpacity?this.latestValues.opacity:h.opacityExit:l.opacity=f===this?h.opacity!==void 0?h.opacity:"":h.opacityExit!==void 0?h.opacityExit:0;for(const E in Hi){if(h[E]===void 0)continue;const{correct:T,applyTo:S}=Hi[E],m=l.transform==="none"?h[E]:T(h[E],f);if(S){const x=S.length;for(let _=0;_<x;_++)l[S[_]]=m}else l[E]=m}return this.options.layoutId&&(l.pointerEvents=f===this?Ai(s.pointerEvents)||"":"none"),l}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var a;return(a=s.currentAnimation)===null||a===void 0?void 0:a.stop()}),this.root.nodes.forEach(Sf),this.root.sharedNodes.clear()}}}function F_(e){e.updateLayout()}function B_(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:o}=e.options,s=n.source!==e.layout.source;o==="size"?Sn(f=>{const h=s?n.measuredBox[f]:n.layoutBox[f],p=on(h);h.min=r[f].min,h.max=h.min+p}):ev(o,n.layoutBox,r)&&Sn(f=>{const h=s?n.measuredBox[f]:n.layoutBox[f],p=on(r[f]);h.max=h.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+p)});const a=Zr();Do(a,r,n.layoutBox);const c=Zr();s?Do(c,e.applyTransform(i,!0),n.measuredBox):Do(c,r,n.layoutBox);const l=!Gm(a);let d=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:h,layout:p}=f;if(h&&p){const w=At();Oo(w,n.layoutBox,h.layoutBox);const E=At();Oo(E,r,p.layoutBox),Zm(w,E)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=E,e.relativeTargetOrigin=w,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:c,layoutDelta:a,hasLayoutChanged:l,hasRelativeTargetChanged:d})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function H_(e){$r.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function W_(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function U_(e){e.clearSnapshot()}function Sf(e){e.clearMeasurements()}function Y_(e){e.isLayoutDirty=!1}function z_(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function $f(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function K_(e){e.resolveTargetDelta()}function q_(e){e.calcProjection()}function X_(e){e.resetRotation()}function G_(e){e.removeLeadSnapshot()}function Pf(e,t,n){e.translate=yt(t.translate,0,n),e.scale=yt(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Rf(e,t,n,r){e.min=yt(t.min,n.min,r),e.max=yt(t.max,n.max,r)}function Z_(e,t,n,r){Rf(e.x,t.x,n.x,r),Rf(e.y,t.y,n.y,r)}function Q_(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const J_={duration:.45,ease:[.4,0,.1,1]},If=e=>typeof navigator<"u"&&navigator.userAgent.toLowerCase().includes(e),Af=If("applewebkit/")&&!If("chrome/")?Math.round:Ct;function Df(e){e.min=Af(e.min),e.max=Af(e.max)}function eT(e){Df(e.x),Df(e.y)}function ev(e,t,n){return e==="position"||e==="preserve-aspect"&&!ec(Ef(t),Ef(n),.2)}const tT=Jm({attachResizeListener:(e,t)=>Ln(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),xa={current:void 0},tv=Jm({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!xa.current){const e=new tT({});e.mount(window),e.setOptions({layoutScroll:!0}),xa.current=e}return xa.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),nT={pan:{Feature:x_},drag:{Feature:w_,ProjectionNode:tv,MeasureLayout:Km}},rT=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function oT(e){const t=rT.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}const iT=4;function oc(e,t,n=1){rn(n<=iT,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,i]=oT(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const s=o.trim();return Vm(s)?parseFloat(s):s}else return Ya(i)?oc(i,t,n+1):i}function sT(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach(i=>{const o=i.get();if(!Ya(o))return;const s=oc(o,r);s&&i.set(s)});for(const i in t){const o=t[i];if(!Ya(o))continue;const s=oc(o,r);s&&(t[i]=s,n||(n={}),n[i]===void 0&&(n[i]=o))}return{target:t,transitionEnd:n}}const aT=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),nv=e=>aT.has(e),cT=e=>Object.keys(e).some(nv),Ci=e=>e===Fr||e===Me,Of=(e,t)=>parseFloat(e.split(", ")[t]),Mf=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/);if(i)return Of(i[1],t);{const o=r.match(/^matrix\((.+)\)$/);return o?Of(o[1],e):0}},lT=new Set(["x","y","z"]),uT=Xo.filter(e=>!lT.has(e));function dT(e){const t=[];return uT.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}const so={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:Mf(4,13),y:Mf(5,14)};so.translateX=so.x;so.translateY=so.y;const fT=(e,t,n)=>{const r=t.measureViewportBox(),i=t.current,o=getComputedStyle(i),{display:s}=o,a={};s==="none"&&t.setStaticValue("display",e.display||"block"),n.forEach(l=>{a[l]=so[l](r,o)}),t.render();const c=t.measureViewportBox();return n.forEach(l=>{const d=t.getValue(l);d&&d.jump(a[l]),e[l]=so[l](c,o)}),e},pT=(e,t,n={},r={})=>{t={...t},r={...r};const i=Object.keys(t).filter(nv);let o=[],s=!1;const a=[];if(i.forEach(c=>{const l=e.getValue(c);if(!e.hasValue(c))return;let d=n[c],f=Eo(d);const h=t[c];let p;if(Ui(h)){const w=h.length,E=h[0]===null?1:0;d=h[E],f=Eo(d);for(let T=E;T<w&&h[T]!==null;T++)p?rn(Eo(h[T])===p,"All keyframes must be of the same type"):(p=Eo(h[T]),rn(p===f||Ci(f)&&Ci(p),"Keyframes must be of the same dimension as the current value"))}else p=Eo(h);if(f!==p)if(Ci(f)&&Ci(p)){const w=l.get();typeof w=="string"&&l.set(parseFloat(w)),typeof h=="string"?t[c]=parseFloat(h):Array.isArray(h)&&p===Me&&(t[c]=h.map(parseFloat))}else f!=null&&f.transform&&(p!=null&&p.transform)&&(d===0||h===0)?d===0?l.set(p.transform(d)):t[c]=f.transform(h):(s||(o=dT(e),s=!0),a.push(c),r[c]=r[c]!==void 0?r[c]:t[c],l.jump(h))}),a.length){const c=a.indexOf("height")>=0?window.pageYOffset:null,l=fT(t,e,a);return o.length&&o.forEach(([d,f])=>{e.getValue(d).set(f)}),e.render(),_s&&c!==null&&window.scrollTo({top:c}),{target:l,transitionEnd:r}}else return{target:t,transitionEnd:r}};function hT(e,t,n,r){return cT(t)?pT(e,t,n,r):{target:t,transitionEnd:r}}const mT=(e,t,n,r)=>{const i=sT(e,t,r);return t=i.target,r=i.transitionEnd,hT(e,t,n,r)},Gi={current:null},ll={current:!1};function rv(){if(ll.current=!0,!!_s)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Gi.current=e.matches;e.addListener(t),t()}else Gi.current=!1}function vT(e,t,n){const{willChange:r}=t;for(const i in t){const o=t[i],s=n[i];if(Ut(o))e.addValue(i,o),qi(r)&&r.add(i),process.env.NODE_ENV==="development"&&Os(o.version==="10.16.1",`Attempting to mix Framer Motion versions ${o.version} with 10.16.1 may not work as expected.`);else if(Ut(s))e.addValue(i,Or(o,{owner:e})),qi(r)&&r.remove(i);else if(s!==o)if(e.hasValue(i)){const a=e.getValue(i);!a.hasAnimated&&a.set(o)}else{const a=e.getStaticValue(i);e.addValue(i,Or(a!==void 0?a:o,{owner:e}))}}for(const i in n)t[i]===void 0&&e.removeValue(i);return t}const Wo=new WeakMap,ov=Object.keys(Ho),gT=ov.length,kf=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],yT=Hc.length;class bT{constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,visualState:o},s={}){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=()=>dt.render(this.render,!1,!0);const{latestValues:a,renderState:c}=o;this.latestValues=a,this.baseTarget={...a},this.initialValues=n.initial?{...a}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=s,this.isControllingVariants=$s(n),this.isVariantNode=Bh(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:l,...d}=this.scrapeMotionValuesFromProps(n,{});for(const f in d){const h=d[f];a[f]!==void 0&&Ut(h)&&(h.set(a[f],!1),qi(l)&&l.add(f))}}scrapeMotionValuesFromProps(t,n){return{}}mount(t){this.current=t,Wo.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),ll.current||rv(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Gi.current,process.env.NODE_ENV!=="production"&&Os(this.shouldReduceMotion!==!0,"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(){Wo.delete(this.current),this.projection&&this.projection.unmount(),yn(this.notifyUpdate),yn(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features)this.features[t].unmount();this.current=null}bindToMotionValue(t,n){const r=Lr.has(t),i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&dt.update(this.notifyUpdate,!1,!0),r&&this.projection&&(this.projection.isTransformDirty=!0)}),o=n.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{i(),o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}loadFeatures({children:t,...n},r,i,o){let s,a;if(process.env.NODE_ENV!=="production"&&i&&r){const c="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";n.ignoreStrict?Qo(!1,c):rn(!1,c)}for(let c=0;c<gT;c++){const l=ov[c],{isEnabled:d,Feature:f,ProjectionNode:h,MeasureLayout:p}=Ho[l];h&&(s=h),d(n)&&(!this.features[l]&&f&&(this.features[l]=new f(this)),p&&(a=p))}if(!this.projection&&s){this.projection=new s(this.latestValues,this.parent&&this.parent.projection);const{layoutId:c,layout:l,drag:d,dragConstraints:f,layoutScroll:h,layoutRoot:p}=n;this.projection.setOptions({layoutId:c,layout:l,alwaysMeasureLayout:!!d||f&&Xr(f),visualElement:this,scheduleRender:()=>this.scheduleRender(),animationType:typeof l=="string"?l:"both",initialPromotionConfig:o,layoutScroll:h,layoutRoot:p})}return a}updateFeatures(){for(const t in this.features){const n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):At()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}makeTargetAnimatable(t,n=!0){return this.makeTargetAnimatableFromInstance(t,this.props,n)}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<kf.length;r++){const i=kf[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o=t["on"+i];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=vT(this,this.scrapeMotionValuesFromProps(t,this.prevProps),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]: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(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const r=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(r.initial=this.props.initial),r}const n={};for(let r=0;r<yT;r++){const i=Hc[r],o=this.props[i];(Bo(o)||o===!1)&&(n[i]=o)}return n}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){n!==this.values.get(t)&&(this.removeValue(t),this.bindToMotionValue(t,n)),this.values.set(t,n),this.latestValues[t]=n.get()}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Or(n,{owner:this}),this.addValue(t,r)),r}readValue(t){var n;return this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options)}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props,i=typeof r=="string"||typeof r=="object"?(n=Zc(this.props,r))===null||n===void 0?void 0:n[t]:void 0;if(r&&i!==void 0)return i;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!Ut(o)?o:this.initialValues[t]!==void 0&&i===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new sl),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class iv extends bT{sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}makeTargetAnimatableFromInstance({transition:t,transitionEnd:n,...r},{transformValues:i},o){let s=FC(r,t||{},this);if(i&&(n&&(n=i(n)),r&&(r=i(r)),s&&(s=i(s))),o){VC(this,r,s);const a=mT(this,r,s,n);n=a.transitionEnd,r=a.target}return{transition:t,transitionEnd:n,...r}}}function wT(e){return window.getComputedStyle(e)}class sv extends iv{readValueFromInstance(t,n){if(Lr.has(n)){const r=rl(n);return r&&r.default||0}else{const r=wT(t),i=(Yh(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return zm(t,n)}build(t,n,r,i){Yc(t,n,r,i.transformTemplate)}scrapeMotionValuesFromProps(t,n){return Gc(t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Ut(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}renderInstance(t,n,r,i){Zh(t,n,r,i)}}class av extends iv{constructor(){super(...arguments),this.isSVGTag=!1}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Lr.has(n)){const r=rl(n);return r&&r.default||0}return n=Qh.has(n)?n:Xc(n),t.getAttribute(n)}measureInstanceViewportBox(){return At()}scrapeMotionValuesFromProps(t,n){return em(t,n)}build(t,n,r,i){Kc(t,n,r,this.isSVGTag,i.transformTemplate)}renderInstance(t,n,r,i){Jh(t,n,r,i)}mount(t){this.isSVGTag=qc(t.tagName),super.mount(t)}}const xT=(e,t)=>Uc(e)?new av(t,{enableHardwareAcceleration:!1}):new sv(t,{enableHardwareAcceleration:!0}),ET={layout:{ProjectionNode:tv,MeasureLayout:Km}},CT={...e_,...SE,...nT,...ET},ar=k1((e,t)=>pE(e,t,CT,xT));function cv(){const e=u.useRef(!1);return Ts(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function _T(){const e=cv(),[t,n]=u.useState(0),r=u.useCallback(()=>{e.current&&n(t+1)},[t]);return[u.useCallback(()=>dt.postRender(r),[r]),t]}class TT extends he.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=this.props.sizeRef.current;r.height=n.offsetHeight||0,r.width=n.offsetWidth||0,r.top=n.offsetTop,r.left=n.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function ST({children:e,isPresent:t}){const n=u.useId(),r=u.useRef(null),i=u.useRef({width:0,height:0,top:0,left:0});return u.useInsertionEffect(()=>{const{width:o,height:s,top:a,left:c}=i.current;if(t||!r.current||!o||!s)return;r.current.dataset.motionPopId=n;const l=document.createElement("style");return document.head.appendChild(l),l.sheet&&l.sheet.insertRule(`
|
|
111
|
+
*/var ra,Td;function l1(){if(Td)return ra;Td=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(o){if(o==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(o)}function i(){try{if(!Object.assign)return!1;var o=new String("abc");if(o[5]="de",Object.getOwnPropertyNames(o)[0]==="5")return!1;for(var s={},a=0;a<10;a++)s["_"+String.fromCharCode(a)]=a;var c=Object.getOwnPropertyNames(s).map(function(d){return s[d]});if(c.join("")!=="0123456789")return!1;var l={};return"abcdefghijklmnopqrst".split("").forEach(function(d){l[d]=d}),Object.keys(Object.assign({},l)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return ra=i()?Object.assign:function(o,s){for(var a,c=r(o),l,d=1;d<arguments.length;d++){a=Object(arguments[d]);for(var f in a)t.call(a,f)&&(c[f]=a[f]);if(e){l=e(a);for(var h=0;h<l.length;h++)n.call(a,l[h])&&(c[l[h]]=a[l[h]])}}return c},ra}var oa,Sd;function jc(){if(Sd)return oa;Sd=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return oa=e,oa}var ia,$d;function kh(){return $d||($d=1,ia=Function.call.bind(Object.prototype.hasOwnProperty)),ia}var sa,Pd;function u1(){if(Pd)return sa;Pd=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=jc(),n={},r=kh();e=function(o){var s="Warning: "+o;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function i(o,s,a,c,l){if(process.env.NODE_ENV!=="production"){for(var d in o)if(r(o,d)){var f;try{if(typeof o[d]!="function"){var h=Error((c||"React class")+": "+a+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}f=o[d](s,d,c,a,null,t)}catch(y){f=y}if(f&&!(f instanceof Error)&&e((c||"React class")+": type specification of "+a+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in n)){n[f.message]=!0;var p=l?l():"";e("Failed "+a+" type: "+f.message+(p??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},sa=i,sa}var aa,Rd;function d1(){if(Rd)return aa;Rd=1;var e=Mh(),t=l1(),n=jc(),r=kh(),i=u1(),o=function(){};process.env.NODE_ENV!=="production"&&(o=function(a){var c="Warning: "+a;typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}});function s(){return null}return aa=function(a,c){var l=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function f(W){var L=W&&(l&&W[l]||W[d]);if(typeof L=="function")return L}var h="<<anonymous>>",p={array:S("array"),bigint:S("bigint"),bool:S("boolean"),func:S("function"),number:S("number"),object:S("object"),string:S("string"),symbol:S("symbol"),any:m(),arrayOf:x,element:_(),elementType:$(),instanceOf:M,node:K(),objectOf:N,oneOf:D,oneOfType:j,shape:P,exact:v};function y(W,L){return W===L?W!==0||1/W===1/L:W!==W&&L!==L}function E(W,L){this.message=W,this.data=L&&typeof L=="object"?L:{},this.stack=""}E.prototype=Error.prototype;function T(W){if(process.env.NODE_ENV!=="production")var L={},oe=0;function X(ne,ae,B,H,J,ee,te){if(H=H||h,ee=ee||B,te!==n){if(c){var Z=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 Z.name="Invariant Violation",Z}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var ge=H+":"+B;!L[ge]&&oe<3&&(o("You are manually calling a React.PropTypes validation function for the `"+ee+"` prop on `"+H+"`. 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."),L[ge]=!0,oe++)}}return ae[B]==null?ne?ae[B]===null?new E("The "+J+" `"+ee+"` is marked as required "+("in `"+H+"`, but its value is `null`.")):new E("The "+J+" `"+ee+"` is marked as required in "+("`"+H+"`, but its value is `undefined`.")):null:W(ae,B,H,J,ee)}var q=X.bind(null,!1);return q.isRequired=X.bind(null,!0),q}function S(W){function L(oe,X,q,ne,ae,B){var H=oe[X],J=k(H);if(J!==W){var ee=U(H);return new E("Invalid "+ne+" `"+ae+"` of type "+("`"+ee+"` supplied to `"+q+"`, expected ")+("`"+W+"`."),{expectedType:W})}return null}return T(L)}function m(){return T(s)}function x(W){function L(oe,X,q,ne,ae){if(typeof W!="function")return new E("Property `"+ae+"` of component `"+q+"` has invalid PropType notation inside arrayOf.");var B=oe[X];if(!Array.isArray(B)){var H=k(B);return new E("Invalid "+ne+" `"+ae+"` of type "+("`"+H+"` supplied to `"+q+"`, expected an array."))}for(var J=0;J<B.length;J++){var ee=W(B,J,q,ne,ae+"["+J+"]",n);if(ee instanceof Error)return ee}return null}return T(L)}function _(){function W(L,oe,X,q,ne){var ae=L[oe];if(!a(ae)){var B=k(ae);return new E("Invalid "+q+" `"+ne+"` of type "+("`"+B+"` supplied to `"+X+"`, expected a single ReactElement."))}return null}return T(W)}function $(){function W(L,oe,X,q,ne){var ae=L[oe];if(!e.isValidElementType(ae)){var B=k(ae);return new E("Invalid "+q+" `"+ne+"` of type "+("`"+B+"` supplied to `"+X+"`, expected a single ReactElement type."))}return null}return T(W)}function M(W){function L(oe,X,q,ne,ae){if(!(oe[X]instanceof W)){var B=W.name||h,H=ue(oe[X]);return new E("Invalid "+ne+" `"+ae+"` of type "+("`"+H+"` supplied to `"+q+"`, expected ")+("instance of `"+B+"`."))}return null}return T(L)}function D(W){if(!Array.isArray(W))return process.env.NODE_ENV!=="production"&&(arguments.length>1?o("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])."):o("Invalid argument supplied to oneOf, expected an array.")),s;function L(oe,X,q,ne,ae){for(var B=oe[X],H=0;H<W.length;H++)if(y(B,W[H]))return null;var J=JSON.stringify(W,function(te,Z){var ge=U(Z);return ge==="symbol"?String(Z):Z});return new E("Invalid "+ne+" `"+ae+"` of value `"+String(B)+"` "+("supplied to `"+q+"`, expected one of "+J+"."))}return T(L)}function N(W){function L(oe,X,q,ne,ae){if(typeof W!="function")return new E("Property `"+ae+"` of component `"+q+"` has invalid PropType notation inside objectOf.");var B=oe[X],H=k(B);if(H!=="object")return new E("Invalid "+ne+" `"+ae+"` of type "+("`"+H+"` supplied to `"+q+"`, expected an object."));for(var J in B)if(r(B,J)){var ee=W(B,J,q,ne,ae+"."+J,n);if(ee instanceof Error)return ee}return null}return T(L)}function j(W){if(!Array.isArray(W))return process.env.NODE_ENV!=="production"&&o("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var L=0;L<W.length;L++){var oe=W[L];if(typeof oe!="function")return o("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+G(oe)+" at index "+L+"."),s}function X(q,ne,ae,B,H){for(var J=[],ee=0;ee<W.length;ee++){var te=W[ee],Z=te(q,ne,ae,B,H,n);if(Z==null)return null;Z.data&&r(Z.data,"expectedType")&&J.push(Z.data.expectedType)}var ge=J.length>0?", expected one of type ["+J.join(", ")+"]":"";return new E("Invalid "+B+" `"+H+"` supplied to "+("`"+ae+"`"+ge+"."))}return T(X)}function K(){function W(L,oe,X,q,ne){return C(L[oe])?null:new E("Invalid "+q+" `"+ne+"` supplied to "+("`"+X+"`, expected a ReactNode."))}return T(W)}function V(W,L,oe,X,q){return new E((W||"React class")+": "+L+" type `"+oe+"."+X+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+q+"`.")}function P(W){function L(oe,X,q,ne,ae){var B=oe[X],H=k(B);if(H!=="object")return new E("Invalid "+ne+" `"+ae+"` of type `"+H+"` "+("supplied to `"+q+"`, expected `object`."));for(var J in W){var ee=W[J];if(typeof ee!="function")return V(q,ne,ae,J,U(ee));var te=ee(B,J,q,ne,ae+"."+J,n);if(te)return te}return null}return T(L)}function v(W){function L(oe,X,q,ne,ae){var B=oe[X],H=k(B);if(H!=="object")return new E("Invalid "+ne+" `"+ae+"` of type `"+H+"` "+("supplied to `"+q+"`, expected `object`."));var J=t({},oe[X],W);for(var ee in J){var te=W[ee];if(r(W,ee)&&typeof te!="function")return V(q,ne,ae,ee,U(te));if(!te)return new E("Invalid "+ne+" `"+ae+"` key `"+ee+"` supplied to `"+q+"`.\nBad object: "+JSON.stringify(oe[X],null," ")+`
|
|
112
|
+
Valid keys: `+JSON.stringify(Object.keys(W),null," "));var Z=te(B,ee,q,ne,ae+"."+ee,n);if(Z)return Z}return null}return T(L)}function C(W){switch(typeof W){case"number":case"string":case"undefined":return!0;case"boolean":return!W;case"object":if(Array.isArray(W))return W.every(C);if(W===null||a(W))return!0;var L=f(W);if(L){var oe=L.call(W),X;if(L!==W.entries){for(;!(X=oe.next()).done;)if(!C(X.value))return!1}else for(;!(X=oe.next()).done;){var q=X.value;if(q&&!C(q[1]))return!1}}else return!1;return!0;default:return!1}}function I(W,L){return W==="symbol"?!0:L?L["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&L instanceof Symbol:!1}function k(W){var L=typeof W;return Array.isArray(W)?"array":W instanceof RegExp?"object":I(L,W)?"symbol":L}function U(W){if(typeof W>"u"||W===null)return""+W;var L=k(W);if(L==="object"){if(W instanceof Date)return"date";if(W instanceof RegExp)return"regexp"}return L}function G(W){var L=U(W);switch(L){case"array":case"object":return"an "+L;case"boolean":case"date":case"regexp":return"a "+L;default:return L}}function ue(W){return!W.constructor||!W.constructor.name?h:W.constructor.name}return p.checkPropTypes=i,p.resetWarningCache=i.resetWarningCache,p.PropTypes=p,p},aa}var ca,Id;function f1(){if(Id)return ca;Id=1;var e=jc();function t(){}function n(){}return n.resetWarningCache=t,ca=function(){function r(s,a,c,l,d,f){if(f!==e){var h=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 h.name="Invariant Violation",h}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},ca}if(process.env.NODE_ENV!=="production"){var p1=Mh(),h1=!0;Wa.exports=d1()(p1.isElement,h1)}else Wa.exports=f1()();var m1=Wa.exports;const z=kp(m1);function v1(e,t){return e.classList?!!t&&e.classList.contains(t):(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")!==-1}function g1(e,t){e.classList?e.classList.add(t):v1(e,t)||(typeof e.className=="string"?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}function Ad(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function y1(e,t){e.classList?e.classList.remove(t):typeof e.className=="string"?e.className=Ad(e.className,t):e.setAttribute("class",Ad(e.className&&e.className.baseVal||"",t))}const Dd={disabled:!1};var b1=process.env.NODE_ENV!=="production"?z.oneOfType([z.number,z.shape({enter:z.number,exit:z.number,appear:z.number}).isRequired]):null,w1=process.env.NODE_ENV!=="production"?z.oneOfType([z.string,z.shape({enter:z.string,exit:z.string,active:z.string}),z.shape({enter:z.string,enterDone:z.string,enterActive:z.string,exit:z.string,exitDone:z.string,exitActive:z.string})]):null;const Nh=u.createContext(null);var jh=function(t){return t.scrollTop},So="unmounted",_r="exited",Tr="entering",Kr="entered",Ua="exiting",qn=function(e){Nc(t,e);function t(r,i){var o;o=e.call(this,r,i)||this;var s=i,a=s&&!s.isMounting?r.enter:r.appear,c;return o.appearStatus=null,r.in?a?(c=_r,o.appearStatus=Tr):c=Kr:r.unmountOnExit||r.mountOnEnter?c=So:c=_r,o.state={status:c},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var s=i.in;return s&&o.status===So?{status:_r}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(i){var o=null;if(i!==this.props){var s=this.state.status;this.props.in?s!==Tr&&s!==Kr&&(o=Tr):(s===Tr||s===Kr)&&(o=Ua)}this.updateStatus(!1,o)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var i=this.props.timeout,o,s,a;return o=s=a=i,i!=null&&typeof i!="number"&&(o=i.exit,s=i.enter,a=i.appear!==void 0?i.appear:s),{exit:o,enter:s,appear:a}},n.updateStatus=function(i,o){if(i===void 0&&(i=!1),o!==null)if(this.cancelNextCallback(),o===Tr){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:fn.findDOMNode(this);s&&jh(s)}this.performEnter(i)}else this.performExit();else this.props.unmountOnExit&&this.state.status===_r&&this.setState({status:So})},n.performEnter=function(i){var o=this,s=this.props.enter,a=this.context?this.context.isMounting:i,c=this.props.nodeRef?[a]:[fn.findDOMNode(this),a],l=c[0],d=c[1],f=this.getTimeouts(),h=a?f.appear:f.enter;if(!i&&!s||Dd.disabled){this.safeSetState({status:Kr},function(){o.props.onEntered(l)});return}this.props.onEnter(l,d),this.safeSetState({status:Tr},function(){o.props.onEntering(l,d),o.onTransitionEnd(h,function(){o.safeSetState({status:Kr},function(){o.props.onEntered(l,d)})})})},n.performExit=function(){var i=this,o=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:fn.findDOMNode(this);if(!o||Dd.disabled){this.safeSetState({status:_r},function(){i.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:Ua},function(){i.props.onExiting(a),i.onTransitionEnd(s.exit,function(){i.safeSetState({status:_r},function(){i.props.onExited(a)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(i,o){o=this.setNextCallback(o),this.setState(i,o)},n.setNextCallback=function(i){var o=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,o.nextCallback=null,i(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(i,o){this.setNextCallback(o);var s=this.props.nodeRef?this.props.nodeRef.current:fn.findDOMNode(this),a=i==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var c=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],l=c[0],d=c[1];this.props.addEndListener(l,d)}i!=null&&setTimeout(this.nextCallback,i)},n.render=function(){var i=this.state.status;if(i===So)return null;var o=this.props,s=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var a=zt(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return u.createElement(Nh.Provider,{value:null},typeof s=="function"?s(i,a):u.cloneElement(u.Children.only(s),a))},t}(u.Component);qn.contextType=Nh;qn.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:z.shape({current:typeof Element>"u"?z.any:function(e,t,n,r,i,o){var s=e[t];return z.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(e,t,n,r,i,o)}}),children:z.oneOfType([z.func.isRequired,z.element.isRequired]).isRequired,in:z.bool,mountOnEnter:z.bool,unmountOnExit:z.bool,appear:z.bool,enter:z.bool,exit:z.bool,timeout:function(t){var n=b1;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return n.apply(void 0,[t].concat(i))},addEndListener:z.func,onEnter:z.func,onEntering:z.func,onEntered:z.func,onExit:z.func,onExiting:z.func,onExited:z.func}:{};function zr(){}qn.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:zr,onEntering:zr,onEntered:zr,onExit:zr,onExiting:zr,onExited:zr};qn.UNMOUNTED=So;qn.EXITED=_r;qn.ENTERING=Tr;qn.ENTERED=Kr;qn.EXITING=Ua;const Vh=qn;var x1=function(t,n){return t&&n&&n.split(" ").forEach(function(r){return g1(t,r)})},la=function(t,n){return t&&n&&n.split(" ").forEach(function(r){return y1(t,r)})},Vc=function(e){Nc(t,e);function t(){for(var r,i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=e.call.apply(e,[this].concat(o))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(a,c){var l=r.resolveArguments(a,c),d=l[0],f=l[1];r.removeClasses(d,"exit"),r.addClass(d,f?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(a,c)},r.onEntering=function(a,c){var l=r.resolveArguments(a,c),d=l[0],f=l[1],h=f?"appear":"enter";r.addClass(d,h,"active"),r.props.onEntering&&r.props.onEntering(a,c)},r.onEntered=function(a,c){var l=r.resolveArguments(a,c),d=l[0],f=l[1],h=f?"appear":"enter";r.removeClasses(d,h),r.addClass(d,h,"done"),r.props.onEntered&&r.props.onEntered(a,c)},r.onExit=function(a){var c=r.resolveArguments(a),l=c[0];r.removeClasses(l,"appear"),r.removeClasses(l,"enter"),r.addClass(l,"exit","base"),r.props.onExit&&r.props.onExit(a)},r.onExiting=function(a){var c=r.resolveArguments(a),l=c[0];r.addClass(l,"exit","active"),r.props.onExiting&&r.props.onExiting(a)},r.onExited=function(a){var c=r.resolveArguments(a),l=c[0];r.removeClasses(l,"exit"),r.addClass(l,"exit","done"),r.props.onExited&&r.props.onExited(a)},r.resolveArguments=function(a,c){return r.props.nodeRef?[r.props.nodeRef.current,a]:[a,c]},r.getClassNames=function(a){var c=r.props.classNames,l=typeof c=="string",d=l&&c?c+"-":"",f=l?""+d+a:c[a],h=l?f+"-active":c[a+"Active"],p=l?f+"-done":c[a+"Done"];return{baseClassName:f,activeClassName:h,doneClassName:p}},r}var n=t.prototype;return n.addClass=function(i,o,s){var a=this.getClassNames(o)[s+"ClassName"],c=this.getClassNames("enter"),l=c.doneClassName;o==="appear"&&s==="done"&&l&&(a+=" "+l),s==="active"&&i&&jh(i),a&&(this.appliedClasses[o][s]=a,x1(i,a))},n.removeClasses=function(i,o){var s=this.appliedClasses[o],a=s.base,c=s.active,l=s.done;this.appliedClasses[o]={},a&&la(i,a),c&&la(i,c),l&&la(i,l)},n.render=function(){var i=this.props;i.classNames;var o=zt(i,["classNames"]);return u.createElement(Vh,ie({},o,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},t}(u.Component);Vc.defaultProps={classNames:""};Vc.propTypes=process.env.NODE_ENV!=="production"?ie({},Vh.propTypes,{classNames:w1,onEnter:z.func,onEntering:z.func,onEntered:z.func,onExit:z.func,onExiting:z.func,onExited:z.func}):{};const E1=Vc;function Od(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var yi=ft({defaultClassName:"fic97c0",variantClassNames:{animate:{in:"fic97c1",out:"fic97c2"}},defaultVariants:{},compoundVariants:[]});const C1=u.forwardRef(({isOpen:e,onClose:t},n)=>{const r=u.useRef(null),i=n||r;return O.jsx(E1,{in:e,nodeRef:i,timeout:400,unmountOnExit:!0,classNames:{enter:Re(yi({animate:"in"})),enterDone:Re(yi({animate:"in"})),exit:Re(yi({animate:"out"})),exitDone:Re(yi({animate:"out"}))},children:O.jsx("div",{ref:i,"data-test-id":"vds-BS-overlay",onClick:t})})}),Lh=e=>{u.useEffect(e,[e])},xs=({children:e,...t})=>{const[n,r]=u.useState(!1);return Lh(()=>{r(!0)}),n?O.jsx(Iw,{...t,children:e}):null};var _1="_185nehu0",T1=ft({defaultClassName:"_185nehu1 _15kd2weg j1jih7z j1jih7ak j1jih7a0",variantClassNames:{},defaultVariants:{},compoundVariants:[]});const S1=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(zx,{...n,ref:r,className:Re(_1),children:O.jsx(Kx,{children:e})})),Lc=u.forwardRef(({options:e,position:t,placeholder:n,...r},i)=>O.jsx(po,{children:O.jsxs(Fx,{...r,children:[O.jsxs(Bx,{ref:i,className:Re(T1()),"data-test-id":r["data-test-id"],children:[O.jsx(Hx,{placeholder:n}),O.jsx(Wx,{className:"SelectIcon",children:O.jsx(Lo,{})})]}),O.jsx(xs,{children:O.jsxs(Ux,{position:t,style:{overflow:"hidden",backgroundColor:"white",borderRadius:" 6px",width:"100%",boxShadow:" 0px 10px 38px -10px rgba(22, 23, 24, 0.35), 0px 10px 20px -15px rgba(22, 23, 24, 0.2)"},children:[O.jsx(qx,{"data-test-id":"CT_ScrollUp_Icon",style:{textAlign:"center",marginTop:5},children:O.jsx(Tc,{height:15,width:15})}),O.jsx(Yx,{className:"SelectViewport",children:e.map(({label:o,value:s})=>O.jsx(S1,{value:s,children:o},s))}),O.jsx(Xx,{"data-test-id":"CT_ScrollDown_Icon",style:{textAlign:"center"},children:O.jsx(Lo,{height:15,width:15})})]})})]})}));Lc.displayName="BaseSelect";Lc.defaultProps={position:"popper",placeholder:"","data-test-id":void 0};const Fc=u.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Es=u.createContext({}),Cs=u.createContext(null),_s=typeof document<"u",Ts=_s?u.useLayoutEffect:u.useEffect,Fh=u.createContext({strict:!1});function $1(e,t,n,r){const{visualElement:i}=u.useContext(Es),o=u.useContext(Fh),s=u.useContext(Cs),a=u.useContext(Fc).reducedMotion,c=u.useRef();r=r||o.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:i,props:n,presenceContext:s,blockInitialAnimation:s?s.initial===!1:!1,reducedMotionConfig:a}));const l=c.current;u.useInsertionEffect(()=>{l&&l.update(n,s)});const d=u.useRef(!!window.HandoffAppearAnimations);return Ts(()=>{l&&(l.render(),d.current&&l.animationState&&l.animationState.animateChanges())}),u.useEffect(()=>{l&&(l.updateFeatures(),!d.current&&l.animationState&&l.animationState.animateChanges(),window.HandoffAppearAnimations=void 0,d.current=!1)}),l}function Xr(e){return typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function P1(e,t,n){return u.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Xr(n)&&(n.current=r))},[t])}function Bo(e){return typeof e=="string"||Array.isArray(e)}function Ss(e){return typeof e=="object"&&typeof e.start=="function"}const Bc=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Hc=["initial",...Bc];function $s(e){return Ss(e.animate)||Hc.some(t=>Bo(e[t]))}function Bh(e){return!!($s(e)||e.variants)}function R1(e,t){if($s(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Bo(n)?n:void 0,animate:Bo(r)?r:void 0}}return e.inherit!==!1?t:{}}function I1(e){const{initial:t,animate:n}=R1(e,u.useContext(Es));return u.useMemo(()=>({initial:t,animate:n}),[Md(t),Md(n)])}function Md(e){return Array.isArray(e)?e.join(" "):e}const kd={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"]},Ho={};for(const e in kd)Ho[e]={isEnabled:t=>kd[e].some(n=>!!t[n])};function A1(e){for(const t in e)Ho[t]={...Ho[t],...e[t]}}const Wc=u.createContext({}),Hh=u.createContext({}),D1=Symbol.for("motionComponentSymbol");function O1({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:i}){e&&A1(e);function o(a,c){let l;const d={...u.useContext(Fc),...a,layoutId:M1(a)},{isStatic:f}=d,h=I1(a),p=r(a,f);if(!f&&_s){h.visualElement=$1(i,p,d,t);const y=u.useContext(Hh),E=u.useContext(Fh).strict;h.visualElement&&(l=h.visualElement.loadFeatures(d,E,e,y))}return he.createElement(Es.Provider,{value:h},l&&h.visualElement?he.createElement(l,{visualElement:h.visualElement,...d}):null,n(i,a,P1(p,h.visualElement,c),p,f,h.visualElement))}const s=u.forwardRef(o);return s[D1]=i,s}function M1({layoutId:e}){const t=u.useContext(Wc).id;return t&&e!==void 0?t+"-"+e:e}function k1(e){function t(r,i={}){return O1(e(r,i))}if(typeof Proxy>"u")return t;const n=new Map;return new Proxy(t,{get:(r,i)=>(n.has(i)||n.set(i,t(i)),n.get(i))})}const N1=["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 Uc(e){return typeof e!="string"||e.includes("-")?!1:!!(N1.indexOf(e)>-1||/[A-Z]/.test(e))}const Hi={};function j1(e){Object.assign(Hi,e)}const Xo=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Lr=new Set(Xo);function Wh(e,{layout:t,layoutId:n}){return Lr.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Hi[e]||e==="opacity")}const Ut=e=>!!(e&&e.getVelocity),V1={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},L1=Xo.length;function F1(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,i){let o="";for(let s=0;s<L1;s++){const a=Xo[s];if(e[a]!==void 0){const c=V1[a]||a;o+=`${c}(${e[a]}) `}}return t&&!e.z&&(o+="translateZ(0)"),o=o.trim(),i?o=i(e,r?"":o):n&&r&&(o="none"),o}const Uh=e=>t=>typeof t=="string"&&t.startsWith(e),Yh=Uh("--"),Ya=Uh("var(--"),B1=/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,H1=(e,t)=>t&&typeof e=="number"?t.transform(e):e,dr=(e,t,n)=>Math.min(Math.max(n,e),t),Fr={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Ro={...Fr,transform:e=>dr(0,1,e)},bi={...Fr,default:1},Io=e=>Math.round(e*1e5)/1e5,Ps=/(-)?([\d]*\.?[\d])+/g,zh=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,W1=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function Go(e){return typeof e=="string"}const Zo=e=>({test:t=>Go(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),rr=Zo("deg"),Rn=Zo("%"),Me=Zo("px"),U1=Zo("vh"),Y1=Zo("vw"),Nd={...Rn,parse:e=>Rn.parse(e)/100,transform:e=>Rn.transform(e*100)},jd={...Fr,transform:Math.round},Kh={borderWidth:Me,borderTopWidth:Me,borderRightWidth:Me,borderBottomWidth:Me,borderLeftWidth:Me,borderRadius:Me,radius:Me,borderTopLeftRadius:Me,borderTopRightRadius:Me,borderBottomRightRadius:Me,borderBottomLeftRadius:Me,width:Me,maxWidth:Me,height:Me,maxHeight:Me,size:Me,top:Me,right:Me,bottom:Me,left:Me,padding:Me,paddingTop:Me,paddingRight:Me,paddingBottom:Me,paddingLeft:Me,margin:Me,marginTop:Me,marginRight:Me,marginBottom:Me,marginLeft:Me,rotate:rr,rotateX:rr,rotateY:rr,rotateZ:rr,scale:bi,scaleX:bi,scaleY:bi,scaleZ:bi,skew:rr,skewX:rr,skewY:rr,distance:Me,translateX:Me,translateY:Me,translateZ:Me,x:Me,y:Me,z:Me,perspective:Me,transformPerspective:Me,opacity:Ro,originX:Nd,originY:Nd,originZ:Me,zIndex:jd,fillOpacity:Ro,strokeOpacity:Ro,numOctaves:jd};function Yc(e,t,n,r){const{style:i,vars:o,transform:s,transformOrigin:a}=e;let c=!1,l=!1,d=!0;for(const f in t){const h=t[f];if(Yh(f)){o[f]=h;continue}const p=Kh[f],y=H1(h,p);if(Lr.has(f)){if(c=!0,s[f]=y,!d)continue;h!==(p.default||0)&&(d=!1)}else f.startsWith("origin")?(l=!0,a[f]=y):i[f]=y}if(t.transform||(c||r?i.transform=F1(e.transform,n,d,r):i.transform&&(i.transform="none")),l){const{originX:f="50%",originY:h="50%",originZ:p=0}=a;i.transformOrigin=`${f} ${h} ${p}`}}const zc=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function qh(e,t,n){for(const r in t)!Ut(t[r])&&!Wh(r,n)&&(e[r]=t[r])}function z1({transformTemplate:e},t,n){return u.useMemo(()=>{const r=zc();return Yc(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}function K1(e,t,n){const r=e.style||{},i={};return qh(i,r,e),Object.assign(i,z1(e,t,n)),e.transformValues?e.transformValues(i):i}function q1(e,t,n){const r={},i=K1(e,t,n);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=i,r}const X1=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 Wi(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||X1.has(e)}let Xh=e=>!Wi(e);function G1(e){e&&(Xh=t=>t.startsWith("on")?!Wi(t):e(t))}try{G1(require("@emotion/is-prop-valid").default)}catch{}function Z1(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(Xh(i)||n===!0&&Wi(i)||!t&&!Wi(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}function Vd(e,t,n){return typeof e=="string"?e:Me.transform(t+n*e)}function Q1(e,t,n){const r=Vd(t,e.x,e.width),i=Vd(n,e.y,e.height);return`${r} ${i}`}const J1={offset:"stroke-dashoffset",array:"stroke-dasharray"},eE={offset:"strokeDashoffset",array:"strokeDasharray"};function tE(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?J1:eE;e[o.offset]=Me.transform(-r);const s=Me.transform(t),a=Me.transform(n);e[o.array]=`${s} ${a}`}function Kc(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:o,pathLength:s,pathSpacing:a=1,pathOffset:c=0,...l},d,f,h){if(Yc(e,l,d,h),f){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:p,style:y,dimensions:E}=e;p.transform&&(E&&(y.transform=p.transform),delete p.transform),E&&(i!==void 0||o!==void 0||y.transform)&&(y.transformOrigin=Q1(E,i!==void 0?i:.5,o!==void 0?o:.5)),t!==void 0&&(p.x=t),n!==void 0&&(p.y=n),r!==void 0&&(p.scale=r),s!==void 0&&tE(p,s,a,c,!1)}const Gh=()=>({...zc(),attrs:{}}),qc=e=>typeof e=="string"&&e.toLowerCase()==="svg";function nE(e,t,n,r){const i=u.useMemo(()=>{const o=Gh();return Kc(o,t,{enableHardwareAcceleration:!1},qc(r),e.transformTemplate),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};qh(o,e.style,e),i.style={...o,...i.style}}return i}function rE(e=!1){return(n,r,i,{latestValues:o},s)=>{const c=(Uc(n)?nE:q1)(r,o,s,n),d={...Z1(r,typeof n=="string",e),...c,ref:i},{children:f}=r,h=u.useMemo(()=>Ut(f)?f.get():f,[f]);return u.createElement(n,{...d,children:h})}}const Xc=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase();function Zh(e,{style:t,vars:n},r,i){Object.assign(e.style,t,i&&i.getProjectionStyles(r));for(const o in n)e.style.setProperty(o,n[o])}const Qh=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 Jh(e,t,n,r){Zh(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(Qh.has(i)?i:Xc(i),t.attrs[i])}function Gc(e,t){const{style:n}=e,r={};for(const i in n)(Ut(n[i])||t.style&&Ut(t.style[i])||Wh(i,e))&&(r[i]=n[i]);return r}function em(e,t){const n=Gc(e,t);for(const r in e)if(Ut(e[r])||Ut(t[r])){const i=Xo.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[i]=e[r]}return n}function Zc(e,t,n,r={},i={}){return typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),t}function Rs(e){const t=u.useRef(null);return t.current===null&&(t.current=e()),t.current}const Ui=e=>Array.isArray(e),oE=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),iE=e=>Ui(e)?e[e.length-1]||0:e;function Ai(e){const t=Ut(e)?e.get():e;return oE(t)?t.toValue():t}function sE({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,i,o){const s={latestValues:aE(r,i,o,e),renderState:t()};return n&&(s.mount=a=>n(r,a,s)),s}const tm=e=>(t,n)=>{const r=u.useContext(Es),i=u.useContext(Cs),o=()=>sE(e,t,r,i);return n?o():Rs(o)};function aE(e,t,n,r){const i={},o=r(e,{});for(const h in o)i[h]=Ai(o[h]);let{initial:s,animate:a}=e;const c=$s(e),l=Bh(e);t&&l&&!c&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||s===!1;const f=d?a:s;return f&&typeof f!="boolean"&&!Ss(f)&&(Array.isArray(f)?f:[f]).forEach(p=>{const y=Zc(e,p);if(!y)return;const{transitionEnd:E,transition:T,...S}=y;for(const m in S){let x=S[m];if(Array.isArray(x)){const _=d?x.length-1:0;x=x[_]}x!==null&&(i[m]=x)}for(const m in E)i[m]=E[m]}),i}const Ct=e=>e;function cE(e){let t=[],n=[],r=0,i=!1,o=!1;const s=new WeakSet,a={schedule:(c,l=!1,d=!1)=>{const f=d&&i,h=f?t:n;return l&&s.add(c),h.indexOf(c)===-1&&(h.push(c),f&&i&&(r=t.length)),c},cancel:c=>{const l=n.indexOf(c);l!==-1&&n.splice(l,1),s.delete(c)},process:c=>{if(i){o=!0;return}if(i=!0,[t,n]=[n,t],n.length=0,r=t.length,r)for(let l=0;l<r;l++){const d=t[l];d(c),s.has(d)&&(a.schedule(d),e())}i=!1,o&&(o=!1,a.process(c))}};return a}const wi=["prepare","read","update","preRender","render","postRender"],lE=40;function uE(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=wi.reduce((f,h)=>(f[h]=cE(()=>n=!0),f),{}),s=f=>o[f].process(i),a=()=>{const f=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(f-i.timestamp,lE),1),i.timestamp=f,i.isProcessing=!0,wi.forEach(s),i.isProcessing=!1,n&&t&&(r=!1,e(a))},c=()=>{n=!0,r=!0,i.isProcessing||e(a)};return{schedule:wi.reduce((f,h)=>{const p=o[h];return f[h]=(y,E=!1,T=!1)=>(n||c(),p.schedule(y,E,T)),f},{}),cancel:f=>wi.forEach(h=>o[h].cancel(f)),state:i,steps:o}}const{schedule:dt,cancel:yn,state:Ht,steps:ua}=uE(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ct,!0),dE={useVisualState:tm({scrapeMotionValuesFromProps:em,createRenderState:Gh,onMount:(e,t,{renderState:n,latestValues:r})=>{dt.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),dt.render(()=>{Kc(n,r,{enableHardwareAcceleration:!1},qc(t.tagName),e.transformTemplate),Jh(t,n)})}})},fE={useVisualState:tm({scrapeMotionValuesFromProps:Gc,createRenderState:zc})};function pE(e,{forwardMotionProps:t=!1},n,r){return{...Uc(e)?dE:fE,preloadedFeatures:n,useRender:rE(t),createVisualElement:r,Component:e}}function Ln(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const nm=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function Is(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const hE=e=>t=>nm(t)&&e(t,Is(t));function Hn(e,t,n,r){return Ln(e,t,hE(n),r)}const mE=(e,t)=>n=>t(e(n)),sr=(...e)=>e.reduce(mE);function rm(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const Ld=rm("dragHorizontal"),Fd=rm("dragVertical");function om(e){let t=!1;if(e==="y")t=Fd();else if(e==="x")t=Ld();else{const n=Ld(),r=Fd();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function im(){const e=om(!0);return e?(e(),!1):!0}class vr{constructor(t){this.isMounted=!1,this.node=t}update(){}}function Bd(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End"),i=(o,s)=>{if(o.type==="touch"||im())return;const a=e.getProps();e.animationState&&a.whileHover&&e.animationState.setActive("whileHover",t),a[r]&&dt.update(()=>a[r](o,s))};return Hn(e.current,n,i,{passive:!e.getProps()[r]})}class vE extends vr{mount(){this.unmount=sr(Bd(this.node,!0),Bd(this.node,!1))}unmount(){}}class gE extends vr{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!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=sr(Ln(this.node.current,"focus",()=>this.onFocus()),Ln(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const sm=(e,t)=>t?e===t?!0:sm(e,t.parentElement):!1;function da(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,Is(n))}class yE extends vr{constructor(){super(...arguments),this.removeStartListeners=Ct,this.removeEndListeners=Ct,this.removeAccessibleListeners=Ct,this.startPointerPress=(t,n)=>{if(this.removeEndListeners(),this.isPressing)return;const r=this.node.getProps(),o=Hn(window,"pointerup",(a,c)=>{if(!this.checkPressEnd())return;const{onTap:l,onTapCancel:d}=this.node.getProps();dt.update(()=>{sm(this.node.current,a.target)?l&&l(a,c):d&&d(a,c)})},{passive:!(r.onTap||r.onPointerUp)}),s=Hn(window,"pointercancel",(a,c)=>this.cancelPress(a,c),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=sr(o,s),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=o=>{if(o.key!=="Enter"||this.isPressing)return;const s=a=>{a.key!=="Enter"||!this.checkPressEnd()||da("up",(c,l)=>{const{onTap:d}=this.node.getProps();d&&dt.update(()=>d(c,l))})};this.removeEndListeners(),this.removeEndListeners=Ln(this.node.current,"keyup",s),da("down",(a,c)=>{this.startPress(a,c)})},n=Ln(this.node.current,"keydown",t),r=()=>{this.isPressing&&da("cancel",(o,s)=>this.cancelPress(o,s))},i=Ln(this.node.current,"blur",r);this.removeAccessibleListeners=sr(n,i)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:i}=this.node.getProps();i&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&dt.update(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!im()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&dt.update(()=>r(t,n))}mount(){const t=this.node.getProps(),n=Hn(this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=Ln(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=sr(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const za=new WeakMap,fa=new WeakMap,bE=e=>{const t=za.get(e.target);t&&t(e)},wE=e=>{e.forEach(bE)};function xE({root:e,...t}){const n=e||document;fa.has(n)||fa.set(n,{});const r=fa.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(wE,{root:e,...t})),r[i]}function EE(e,t,n){const r=xE(t);return za.set(e,n),r.observe(e),()=>{za.delete(e),r.unobserve(e)}}const CE={some:0,all:1};class _E extends vr{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:CE[i]},a=c=>{const{isIntersecting:l}=c;if(this.isInView===l||(this.isInView=l,o&&!l&&this.hasEnteredView))return;l&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",l);const{onViewportEnter:d,onViewportLeave:f}=this.node.getProps(),h=l?d:f;h&&h(c)};return EE(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(TE(t,n))&&this.startObserver()}unmount(){}}function TE({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const SE={inView:{Feature:_E},tap:{Feature:yE},focus:{Feature:gE},hover:{Feature:vE}};function am(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 $E(e){const t={};return e.values.forEach((n,r)=>t[r]=n.get()),t}function PE(e){const t={};return e.values.forEach((n,r)=>t[r]=n.getVelocity()),t}function As(e,t,n){const r=e.getProps();return Zc(r,t,n!==void 0?n:r.custom,$E(e),PE(e))}const RE="framerAppearId",IE="data-"+Xc(RE);let Qo=Ct,rn=Ct;process.env.NODE_ENV!=="production"&&(Qo=(e,t)=>{!e&&typeof console<"u"&&console.warn(t)},rn=(e,t)=>{if(!e)throw new Error(t)});const Wn=e=>e*1e3,In=e=>e/1e3,AE={current:!1},cm=e=>Array.isArray(e)&&typeof e[0]=="number";function lm(e){return!!(!e||typeof e=="string"&&um[e]||cm(e)||Array.isArray(e)&&e.every(lm))}const $o=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,um={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:$o([0,.65,.55,1]),circOut:$o([.55,0,1,.45]),backIn:$o([.31,.01,.66,-.59]),backOut:$o([.33,1.53,.69,.99])};function dm(e){if(e)return cm(e)?$o(e):Array.isArray(e)?e.map(dm):um[e]}function DE(e,t,n,{delay:r=0,duration:i,repeat:o=0,repeatType:s="loop",ease:a,times:c}={}){const l={[t]:n};c&&(l.offset=c);const d=dm(a);return Array.isArray(d)&&(l.easing=d),e.animate(l,{delay:r,duration:i,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:o+1,direction:s==="reverse"?"alternate":"normal"})}function OE(e,{repeat:t,repeatType:n="loop"}){const r=t&&n!=="loop"&&t%2===1?0:e.length-1;return e[r]}const fm=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,ME=1e-7,kE=12;function NE(e,t,n,r,i){let o,s,a=0;do s=t+(n-t)/2,o=fm(s,r,i)-e,o>0?n=s:t=s;while(Math.abs(o)>ME&&++a<kE);return s}function Jo(e,t,n,r){if(e===t&&n===r)return Ct;const i=o=>NE(o,0,1,e,n);return o=>o===0||o===1?o:fm(i(o),t,r)}const jE=Jo(.42,0,1,1),VE=Jo(0,0,.58,1),pm=Jo(.42,0,.58,1),hm=e=>Array.isArray(e)&&typeof e[0]!="number",mm=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,vm=e=>t=>1-e(1-t),gm=e=>1-Math.sin(Math.acos(e)),Qc=vm(gm),LE=mm(Qc),ym=Jo(.33,1.53,.69,.99),Jc=vm(ym),FE=mm(Jc),BE=e=>(e*=2)<1?.5*Jc(e):.5*(2-Math.pow(2,-10*(e-1))),Hd={linear:Ct,easeIn:jE,easeInOut:pm,easeOut:VE,circIn:gm,circInOut:LE,circOut:Qc,backIn:Jc,backInOut:FE,backOut:ym,anticipate:BE},Wd=e=>{if(Array.isArray(e)){rn(e.length===4,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,i]=e;return Jo(t,n,r,i)}else if(typeof e=="string")return rn(Hd[e]!==void 0,`Invalid easing type '${e}'`),Hd[e];return e},el=(e,t)=>n=>!!(Go(n)&&W1.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),bm=(e,t,n)=>r=>{if(!Go(r))return r;const[i,o,s,a]=r.match(Ps);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},HE=e=>dr(0,255,e),pa={...Fr,transform:e=>Math.round(HE(e))},Pr={test:el("rgb","red"),parse:bm("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+pa.transform(e)+", "+pa.transform(t)+", "+pa.transform(n)+", "+Io(Ro.transform(r))+")"};function WE(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Ka={test:el("#"),parse:WE,transform:Pr.transform},Gr={test:el("hsl","hue"),parse:bm("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Rn.transform(Io(t))+", "+Rn.transform(Io(n))+", "+Io(Ro.transform(r))+")"},Yt={test:e=>Pr.test(e)||Ka.test(e)||Gr.test(e),parse:e=>Pr.test(e)?Pr.parse(e):Gr.test(e)?Gr.parse(e):Ka.parse(e),transform:e=>Go(e)?e:e.hasOwnProperty("red")?Pr.transform(e):Gr.transform(e)},yt=(e,t,n)=>-n*e+n*t+e;function ha(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function UE({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,s=0;if(!t)i=o=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,c=2*n-a;i=ha(c,a,e+1/3),o=ha(c,a,e),s=ha(c,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(s*255),alpha:r}}const ma=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},YE=[Ka,Pr,Gr],zE=e=>YE.find(t=>t.test(e));function Ud(e){const t=zE(e);rn(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`);let n=t.parse(e);return t===Gr&&(n=UE(n)),n}const wm=(e,t)=>{const n=Ud(e),r=Ud(t),i={...n};return o=>(i.red=ma(n.red,r.red,o),i.green=ma(n.green,r.green,o),i.blue=ma(n.blue,r.blue,o),i.alpha=yt(n.alpha,r.alpha,o),Pr.transform(i))};function KE(e){var t,n;return isNaN(e)&&Go(e)&&(((t=e.match(Ps))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(zh))===null||n===void 0?void 0:n.length)||0)>0}const xm={regex:B1,countKey:"Vars",token:"${v}",parse:Ct},Em={regex:zh,countKey:"Colors",token:"${c}",parse:Yt.parse},Cm={regex:Ps,countKey:"Numbers",token:"${n}",parse:Fr.parse};function va(e,{regex:t,countKey:n,token:r,parse:i}){const o=e.tokenised.match(t);o&&(e["num"+n]=o.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...o.map(i)))}function Yi(e){const t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&va(n,xm),va(n,Em),va(n,Cm),n}function _m(e){return Yi(e).values}function Tm(e){const{values:t,numColors:n,numVars:r,tokenised:i}=Yi(e),o=t.length;return s=>{let a=i;for(let c=0;c<o;c++)c<r?a=a.replace(xm.token,s[c]):c<r+n?a=a.replace(Em.token,Yt.transform(s[c])):a=a.replace(Cm.token,Io(s[c]));return a}}const qE=e=>typeof e=="number"?0:e;function XE(e){const t=_m(e);return Tm(e)(t.map(qE))}const fr={test:KE,parse:_m,createTransformer:Tm,getAnimatableNone:XE},Sm=(e,t)=>n=>`${n>0?t:e}`;function $m(e,t){return typeof e=="number"?n=>yt(e,t,n):Yt.test(e)?wm(e,t):e.startsWith("var(")?Sm(e,t):Rm(e,t)}const Pm=(e,t)=>{const n=[...e],r=n.length,i=e.map((o,s)=>$m(o,t[s]));return o=>{for(let s=0;s<r;s++)n[s]=i[s](o);return n}},GE=(e,t)=>{const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=$m(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}},Rm=(e,t)=>{const n=fr.createTransformer(t),r=Yi(e),i=Yi(t);return r.numVars===i.numVars&&r.numColors===i.numColors&&r.numNumbers>=i.numNumbers?sr(Pm(r.values,i.values),n):(Qo(!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.`),Sm(e,t))},io=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},Yd=(e,t)=>n=>yt(e,t,n);function ZE(e){return typeof e=="number"?Yd:typeof e=="string"?Yt.test(e)?wm:Rm:Array.isArray(e)?Pm:typeof e=="object"?GE:Yd}function QE(e,t,n){const r=[],i=n||ZE(e[0]),o=e.length-1;for(let s=0;s<o;s++){let a=i(e[s],e[s+1]);if(t){const c=Array.isArray(t)?t[s]||Ct:t;a=sr(c,a)}r.push(a)}return r}function tl(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const o=e.length;if(rn(o===t.length,"Both input and output ranges must be the same length"),o===1)return()=>t[0];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=QE(t,r,i),a=s.length,c=l=>{let d=0;if(a>1)for(;d<e.length-2&&!(l<e[d+1]);d++);const f=io(e[d],e[d+1],l);return s[d](f)};return n?l=>c(dr(e[0],e[o-1],l)):c}function Im(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=io(0,t,r);e.push(yt(n,1,i))}}function Am(e){const t=[0];return Im(t,e.length-1),t}function JE(e,t){return e.map(n=>n*t)}function eC(e,t){return e.map(()=>t||pm).splice(0,e.length-1)}function zi({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=hm(r)?r.map(Wd):Wd(r),o={done:!1,value:t[0]},s=JE(n&&n.length===t.length?n:Am(t),e),a=tl(s,t,{ease:Array.isArray(i)?i:eC(t,i)});return{calculatedDuration:e,next:c=>(o.value=a(c),o.done=c>=e,o)}}function Dm(e,t){return t?e*(1e3/t):0}const tC=5;function Om(e,t,n){const r=Math.max(t-tC,0);return Dm(n-e(r),t-r)}const ga=.001,nC=.01,zd=10,rC=.05,oC=1;function iC({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,o;Qo(e<=Wn(zd),"Spring duration must be 10 seconds or less");let s=1-t;s=dr(rC,oC,s),e=dr(nC,zd,In(e)),s<1?(i=l=>{const d=l*s,f=d*e,h=d-n,p=qa(l,s),y=Math.exp(-f);return ga-h/p*y},o=l=>{const f=l*s*e,h=f*n+n,p=Math.pow(s,2)*Math.pow(l,2)*e,y=Math.exp(-f),E=qa(Math.pow(l,2),s);return(-i(l)+ga>0?-1:1)*((h-p)*y)/E}):(i=l=>{const d=Math.exp(-l*e),f=(l-n)*e+1;return-ga+d*f},o=l=>{const d=Math.exp(-l*e),f=(n-l)*(e*e);return d*f});const a=5/e,c=aC(i,o,a);if(e=Wn(e),isNaN(c))return{stiffness:100,damping:10,duration:e};{const l=Math.pow(c,2)*r;return{stiffness:l,damping:s*2*Math.sqrt(r*l),duration:e}}}const sC=12;function aC(e,t,n){let r=n;for(let i=1;i<sC;i++)r=r-e(r)/t(r);return r}function qa(e,t){return e*Math.sqrt(1-t*t)}const cC=["duration","bounce"],lC=["stiffness","damping","mass"];function Kd(e,t){return t.some(n=>e[n]!==void 0)}function uC(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!Kd(e,lC)&&Kd(e,cC)){const n=iC(e);t={...t,...n,velocity:0,mass:1},t.isResolvedFromDuration=!0}return t}function nl({keyframes:e,restDelta:t,restSpeed:n,...r}){const i=e[0],o=e[e.length-1],s={done:!1,value:i},{stiffness:a,damping:c,mass:l,velocity:d,duration:f,isResolvedFromDuration:h}=uC(r),p=d?-In(d):0,y=c/(2*Math.sqrt(a*l)),E=o-i,T=In(Math.sqrt(a/l)),S=Math.abs(E)<5;n||(n=S?.01:2),t||(t=S?.005:.5);let m;if(y<1){const x=qa(T,y);m=_=>{const $=Math.exp(-y*T*_);return o-$*((p+y*T*E)/x*Math.sin(x*_)+E*Math.cos(x*_))}}else if(y===1)m=x=>o-Math.exp(-T*x)*(E+(p+T*E)*x);else{const x=T*Math.sqrt(y*y-1);m=_=>{const $=Math.exp(-y*T*_),M=Math.min(x*_,300);return o-$*((p+y*T*E)*Math.sinh(M)+x*E*Math.cosh(M))/x}}return{calculatedDuration:h&&f||null,next:x=>{const _=m(x);if(h)s.done=x>=f;else{let $=p;x!==0&&(y<1?$=Om(m,x,_):$=0);const M=Math.abs($)<=n,D=Math.abs(o-_)<=t;s.done=M&&D}return s.value=s.done?o:_,s}}}function qd({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:a,max:c,restDelta:l=.5,restSpeed:d}){const f=e[0],h={done:!1,value:f},p=N=>a!==void 0&&N<a||c!==void 0&&N>c,y=N=>a===void 0?c:c===void 0||Math.abs(a-N)<Math.abs(c-N)?a:c;let E=n*t;const T=f+E,S=s===void 0?T:s(T);S!==T&&(E=S-f);const m=N=>-E*Math.exp(-N/r),x=N=>S+m(N),_=N=>{const j=m(N),K=x(N);h.done=Math.abs(j)<=l,h.value=h.done?S:K};let $,M;const D=N=>{p(h.value)&&($=N,M=nl({keyframes:[h.value,y(h.value)],velocity:Om(x,N,h.value),damping:i,stiffness:o,restDelta:l,restSpeed:d}))};return D(0),{calculatedDuration:null,next:N=>{let j=!1;return!M&&$===void 0&&(j=!0,_(N),D(N)),$!==void 0&&N>$?M.next(N-$):(!j&&_(N),h)}}}const dC=e=>{const t=({timestamp:n})=>e(n);return{start:()=>dt.update(t,!0),stop:()=>yn(t),now:()=>Ht.isProcessing?Ht.timestamp:performance.now()}},Xa=2e4;function Ga(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<Xa;)t+=n,r=e.next(t);return t>=Xa?1/0:t}const fC={decay:qd,inertia:qd,tween:zi,keyframes:zi,spring:nl};function Ki({autoplay:e=!0,delay:t=0,driver:n=dC,keyframes:r,type:i="keyframes",repeat:o=0,repeatDelay:s=0,repeatType:a="loop",onPlay:c,onStop:l,onComplete:d,onUpdate:f,...h}){let p=1,y=!1,E,T;const S=()=>{T=new Promise(L=>{E=L})};S();let m;const x=fC[i]||zi;let _;x!==zi&&typeof r[0]!="number"&&(_=tl([0,100],r,{clamp:!1}),r=[0,100]);const $=x({...h,keyframes:r});let M;a==="mirror"&&(M=x({...h,keyframes:[...r].reverse(),velocity:-(h.velocity||0)}));let D="idle",N=null,j=null,K=null;$.calculatedDuration===null&&o&&($.calculatedDuration=Ga($));const{calculatedDuration:V}=$;let P=1/0,v=1/0;V!==null&&(P=V+s,v=P*(o+1)-s);let C=0;const I=L=>{if(j===null)return;p>0&&(j=Math.min(j,L)),p<0&&(j=Math.min(L-v/p,j)),N!==null?C=N:C=Math.round(L-j)*p;const oe=C-t*(p>=0?1:-1),X=p>=0?oe<0:oe>v;C=Math.max(oe,0),D==="finished"&&N===null&&(C=v);let q=C,ne=$;if(o){const J=C/P;let ee=Math.floor(J),te=J%1;!te&&J>=1&&(te=1),te===1&&ee--,ee=Math.min(ee,o+1);const Z=!!(ee%2);Z&&(a==="reverse"?(te=1-te,s&&(te-=s/P)):a==="mirror"&&(ne=M));let ge=dr(0,1,te);C>v&&(ge=a==="reverse"&&Z?1:0),q=ge*P}const ae=X?{done:!1,value:r[0]}:ne.next(q);_&&(ae.value=_(ae.value));let{done:B}=ae;!X&&V!==null&&(B=p>=0?C>=v:C<=0);const H=N===null&&(D==="finished"||D==="running"&&B);return f&&f(ae.value),H&&G(),ae},k=()=>{m&&m.stop(),m=void 0},U=()=>{D="idle",k(),E(),S(),j=K=null},G=()=>{D="finished",d&&d(),k(),E()},ue=()=>{if(y)return;m||(m=n(I));const L=m.now();c&&c(),N!==null?j=L-N:(!j||D==="finished")&&(j=L),D==="finished"&&S(),K=j,N=null,D="running",m.start()};e&&ue();const W={then(L,oe){return T.then(L,oe)},get time(){return In(C)},set time(L){L=Wn(L),C=L,N!==null||!m||p===0?N=L:j=m.now()-L/p},get duration(){const L=$.calculatedDuration===null?Ga($):$.calculatedDuration;return In(L)},get speed(){return p},set speed(L){L===p||!m||(p=L,W.time=In(C))},get state(){return D},play:ue,pause:()=>{D="paused",N=C},stop:()=>{y=!0,D!=="idle"&&(D="idle",l&&l(),U())},cancel:()=>{K!==null&&I(K),U()},complete:()=>{D="finished"},sample:L=>(j=0,I(L))};return W}function Mm(e){let t;return()=>(t===void 0&&(t=e()),t)}const pC=Mm(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),hC=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),xi=10,mC=2e4,vC=(e,t)=>t.type==="spring"||e==="backgroundColor"||!lm(t.ease);function gC(e,t,{onUpdate:n,onComplete:r,...i}){if(!(pC()&&hC.has(t)&&!i.repeatDelay&&i.repeatType!=="mirror"&&i.damping!==0&&i.type!=="inertia"))return!1;let s=!1,a,c;const l=()=>{c=new Promise(m=>{a=m})};l();let{keyframes:d,duration:f=300,ease:h,times:p}=i;if(vC(t,i)){const m=Ki({...i,repeat:0,delay:0});let x={done:!1,value:d[0]};const _=[];let $=0;for(;!x.done&&$<mC;)x=m.sample($),_.push(x.value),$+=xi;p=void 0,d=_,f=$-xi,h="linear"}const y=DE(e.owner.current,t,d,{...i,duration:f,ease:h,times:p}),E=()=>y.cancel(),T=()=>{dt.update(E),a(),l()};return y.onfinish=()=>{e.set(OE(d,i)),r&&r(),T()},{then(m,x){return c.then(m,x)},attachTimeline(m){return y.timeline=m,y.onfinish=null,Ct},get time(){return In(y.currentTime||0)},set time(m){y.currentTime=Wn(m)},get speed(){return y.playbackRate},set speed(m){y.playbackRate=m},get duration(){return In(f)},play:()=>{s||(y.play(),yn(E))},pause:()=>y.pause(),stop:()=>{if(s=!0,y.playState==="idle")return;const{currentTime:m}=y;if(m){const x=Ki({...i,autoplay:!1});e.setWithVelocity(x.sample(m-xi).value,x.sample(m).value,xi)}T()},complete:()=>y.finish(),cancel:T}}function yC({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const i=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:Ct,pause:Ct,stop:Ct,then:o=>(o(),Promise.resolve()),cancel:Ct,complete:Ct});return t?Ki({keyframes:[0,1],duration:0,delay:t,onComplete:i}):i()}const bC={type:"spring",stiffness:500,damping:25,restSpeed:10},wC=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),xC={type:"keyframes",duration:.8},EC={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},CC=(e,{keyframes:t})=>t.length>2?xC:Lr.has(e)?e.startsWith("scale")?wC(t[1]):bC:EC,Za=(e,t)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(fr.test(t)||t==="0")&&!t.startsWith("url(")),_C=new Set(["brightness","contrast","saturate","opacity"]);function TC(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Ps)||[];if(!r)return e;const i=n.replace(r,"");let o=_C.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const SC=/([a-z-]*)\(.*?\)/g,Qa={...fr,getAnimatableNone:e=>{const t=e.match(SC);return t?t.map(TC).join(" "):e}},$C={...Kh,color:Yt,backgroundColor:Yt,outlineColor:Yt,fill:Yt,stroke:Yt,borderColor:Yt,borderTopColor:Yt,borderRightColor:Yt,borderBottomColor:Yt,borderLeftColor:Yt,filter:Qa,WebkitFilter:Qa},rl=e=>$C[e];function km(e,t){let n=rl(e);return n!==Qa&&(n=fr),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Nm=e=>/^0[^.\s]+$/.test(e);function PC(e){if(typeof e=="number")return e===0;if(e!==null)return e==="none"||e==="0"||Nm(e)}function RC(e,t,n,r){const i=Za(t,n);let o;Array.isArray(n)?o=[...n]:o=[null,n];const s=r.from!==void 0?r.from:e.get();let a;const c=[];for(let l=0;l<o.length;l++)o[l]===null&&(o[l]=l===0?s:o[l-1]),PC(o[l])&&c.push(l),typeof o[l]=="string"&&o[l]!=="none"&&o[l]!=="0"&&(a=o[l]);if(i&&c.length&&a)for(let l=0;l<c.length;l++){const d=c[l];o[d]=km(t,a)}return o}function IC({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:s,repeatDelay:a,from:c,elapsed:l,...d}){return!!Object.keys(d).length}function jm(e,t){return e[t]||e.default||e}const ol=(e,t,n,r={})=>i=>{const o=jm(r,e)||{},s=o.delay||r.delay||0;let{elapsed:a=0}=r;a=a-Wn(s);const c=RC(t,e,n,o),l=c[0],d=c[c.length-1],f=Za(e,l),h=Za(e,d);Qo(f===h,`You are trying to animate ${e} from "${l}" to "${d}". ${l} is not an animatable value - to enable this animation set ${l} to a value animatable to ${d} via the \`style\` property.`);let p={keyframes:c,velocity:t.getVelocity(),ease:"easeOut",...o,delay:-a,onUpdate:y=>{t.set(y),o.onUpdate&&o.onUpdate(y)},onComplete:()=>{i(),o.onComplete&&o.onComplete()}};if(IC(o)||(p={...p,...CC(e,p)}),p.duration&&(p.duration=Wn(p.duration)),p.repeatDelay&&(p.repeatDelay=Wn(p.repeatDelay)),!f||!h||AE.current||o.type===!1)return yC(p);if(t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const y=gC(t,e,p);if(y)return y}return Ki(p)};function qi(e){return!!(Ut(e)&&e.add)}const Vm=e=>/^\-?\d*\.?\d+$/.test(e);function il(e,t){e.indexOf(t)===-1&&e.push(t)}function Ds(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class sl{constructor(){this.subscriptions=[]}add(t){return il(this.subscriptions,t),()=>Ds(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o<i;o++){const s=this.subscriptions[o];s&&s(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Xd=new Set;function Os(e,t,n){e||Xd.has(t)||(console.warn(t),n&&console.warn(n),Xd.add(t))}const AC=e=>!isNaN(parseFloat(e)),Ao={current:void 0};class DC{constructor(t,n={}){this.version="10.16.1",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(r,i=!0)=>{this.prev=this.current,this.current=r;const{delta:o,timestamp:s}=Ht;this.lastUpdated!==s&&(this.timeDelta=o,this.lastUpdated=s,dt.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()),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>dt.postRender(this.velocityCheck),this.velocityCheck=({timestamp:r})=>{r!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=t,this.canTrackVelocity=AC(this.current),this.owner=n.owner}onChange(t){return process.env.NODE_ENV!=="production"&&Os(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new sl);const r=this.events[t].add(n);return t==="change"?()=>{r(),dt.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=t,this.timeDelta=r}jump(t){this.updateAndNotify(t),this.prev=t,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return Ao.current&&Ao.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?Dm(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),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 Or(e,t){return new DC(e,t)}const Lm=e=>t=>t.test(e),OC={test:e=>e==="auto",parse:e=>e},Fm=[Fr,Me,Rn,rr,Y1,U1,OC],Eo=e=>Fm.find(Lm(e)),MC=[...Fm,Yt,fr],kC=e=>MC.find(Lm(e));function NC(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Or(n))}function jC(e,t){const n=As(e,t);let{transitionEnd:r={},transition:i={},...o}=n?e.makeTargetAnimatable(n,!1):{};o={...o,...r};for(const s in o){const a=iE(o[s]);NC(e,s,a)}}function VC(e,t,n){var r,i;const o=Object.keys(t).filter(a=>!e.hasValue(a)),s=o.length;if(s)for(let a=0;a<s;a++){const c=o[a],l=t[c];let d=null;Array.isArray(l)&&(d=l[0]),d===null&&(d=(i=(r=n[c])!==null&&r!==void 0?r:e.readValue(c))!==null&&i!==void 0?i:t[c]),d!=null&&(typeof d=="string"&&(Vm(d)||Nm(d))?d=parseFloat(d):!kC(d)&&fr.test(l)&&(d=km(c,l)),e.addValue(c,Or(d,{owner:e})),n[c]===void 0&&(n[c]=d),d!==null&&e.setBaseTarget(c,d))}}function LC(e,t){return t?(t[e]||t.default||t).from:void 0}function FC(e,t,n){const r={};for(const i in e){const o=LC(i,t);if(o!==void 0)r[i]=o;else{const s=n.getValue(i);s&&(r[i]=s.get())}}return r}function BC({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function al(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o=e.getDefaultTransition(),transitionEnd:s,...a}=e.makeTargetAnimatable(t);const c=e.getValue("willChange");r&&(o=r);const l=[],d=i&&e.animationState&&e.animationState.getState()[i];for(const f in a){const h=e.getValue(f),p=a[f];if(!h||p===void 0||d&&BC(d,f))continue;const y={delay:n,elapsed:0,...o};if(window.HandoffAppearAnimations&&!h.hasAnimated){const T=e.getProps()[IE];T&&(y.elapsed=window.HandoffAppearAnimations(T,f,h,dt))}h.start(ol(f,h,p,e.shouldReduceMotion&&Lr.has(f)?{type:!1}:y));const E=h.animation;qi(c)&&(c.add(f),E.then(()=>c.remove(f))),l.push(E)}return s&&Promise.all(l).then(()=>{s&&jC(e,s)}),l}function Ja(e,t,n={}){const r=As(e,t,n.custom);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(al(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:l=0,staggerChildren:d,staggerDirection:f}=i;return HC(e,t,l+c,d,f,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[c,l]=a==="beforeChildren"?[o,s]:[s,o];return c().then(()=>l())}else return Promise.all([o(),s(n.delay)])}function HC(e,t,n=0,r=0,i=1,o){const s=[],a=(e.variantChildren.size-1)*r,c=i===1?(l=0)=>l*r:(l=0)=>a-l*r;return Array.from(e.variantChildren).sort(WC).forEach((l,d)=>{l.notify("AnimationStart",t),s.push(Ja(l,t,{...o,delay:n+c(d)}).then(()=>l.notify("AnimationComplete",t)))}),Promise.all(s)}function WC(e,t){return e.sortNodePosition(t)}function UC(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>Ja(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=Ja(e,t,n);else{const i=typeof t=="function"?As(e,t,n.custom):t;r=Promise.all(al(e,i,n))}return r.then(()=>e.notify("AnimationComplete",t))}const YC=[...Bc].reverse(),zC=Bc.length;function KC(e){return t=>Promise.all(t.map(({animation:n,options:r})=>UC(e,n,r)))}function qC(e){let t=KC(e);const n=GC();let r=!0;const i=(c,l)=>{const d=As(e,l);if(d){const{transition:f,transitionEnd:h,...p}=d;c={...c,...p,...h}}return c};function o(c){t=c(e)}function s(c,l){const d=e.getProps(),f=e.getVariantContext(!0)||{},h=[],p=new Set;let y={},E=1/0;for(let S=0;S<zC;S++){const m=YC[S],x=n[m],_=d[m]!==void 0?d[m]:f[m],$=Bo(_),M=m===l?x.isActive:null;M===!1&&(E=S);let D=_===f[m]&&_!==d[m]&&$;if(D&&r&&e.manuallyAnimateOnMount&&(D=!1),x.protectedKeys={...y},!x.isActive&&M===null||!_&&!x.prevProp||Ss(_)||typeof _=="boolean")continue;const N=XC(x.prevProp,_);let j=N||m===l&&x.isActive&&!D&&$||S>E&&$;const K=Array.isArray(_)?_:[_];let V=K.reduce(i,{});M===!1&&(V={});const{prevResolvedValues:P={}}=x,v={...P,...V},C=I=>{j=!0,p.delete(I),x.needsAnimating[I]=!0};for(const I in v){const k=V[I],U=P[I];y.hasOwnProperty(I)||(k!==U?Ui(k)&&Ui(U)?!am(k,U)||N?C(I):x.protectedKeys[I]=!0:k!==void 0?C(I):p.add(I):k!==void 0&&p.has(I)?C(I):x.protectedKeys[I]=!0)}x.prevProp=_,x.prevResolvedValues=V,x.isActive&&(y={...y,...V}),r&&e.blockInitialAnimation&&(j=!1),j&&!D&&h.push(...K.map(I=>({animation:I,options:{type:m,...c}})))}if(p.size){const S={};p.forEach(m=>{const x=e.getBaseTarget(m);x!==void 0&&(S[m]=x)}),h.push({animation:S})}let T=!!h.length;return r&&d.initial===!1&&!e.manuallyAnimateOnMount&&(T=!1),r=!1,T?t(h):Promise.resolve()}function a(c,l,d){var f;if(n[c].isActive===l)return Promise.resolve();(f=e.variantChildren)===null||f===void 0||f.forEach(p=>{var y;return(y=p.animationState)===null||y===void 0?void 0:y.setActive(c,l)}),n[c].isActive=l;const h=s(d,c);for(const p in n)n[p].protectedKeys={};return h}return{animateChanges:s,setActive:a,setAnimateFunction:o,getState:()=>n}}function XC(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!am(t,e):!1}function Er(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function GC(){return{animate:Er(!0),whileInView:Er(),whileHover:Er(),whileTap:Er(),whileDrag:Er(),whileFocus:Er(),exit:Er()}}class ZC extends vr{constructor(t){super(t),t.animationState||(t.animationState=qC(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();this.unmount(),Ss(t)&&(this.unmount=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){}}let QC=0;class JC extends vr{constructor(){super(...arguments),this.id=QC++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n,custom:r}=this.node.presenceContext,{isPresent:i}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===i)return;const o=this.node.animationState.setActive("exit",!t,{custom:r??this.node.getProps().custom});n&&!t&&o.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const e_={animation:{Feature:ZC},exit:{Feature:JC}},Gd=(e,t)=>Math.abs(e-t);function t_(e,t){const n=Gd(e.x,t.x),r=Gd(e.y,t.y);return Math.sqrt(n**2+r**2)}class Bm{constructor(t,n,{transformPagePoint:r}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const l=ba(this.lastMoveEventInfo,this.history),d=this.startEvent!==null,f=t_(l.offset,{x:0,y:0})>=3;if(!d&&!f)return;const{point:h}=l,{timestamp:p}=Ht;this.history.push({...h,timestamp:p});const{onStart:y,onMove:E}=this.handlers;d||(y&&y(this.lastMoveEvent,l),this.startEvent=this.lastMoveEvent),E&&E(this.lastMoveEvent,l)},this.handlePointerMove=(l,d)=>{this.lastMoveEvent=l,this.lastMoveEventInfo=ya(d,this.transformPagePoint),dt.update(this.updatePoint,!0)},this.handlePointerUp=(l,d)=>{if(this.end(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const{onEnd:f,onSessionEnd:h}=this.handlers,p=ba(l.type==="pointercancel"?this.lastMoveEventInfo:ya(d,this.transformPagePoint),this.history);this.startEvent&&f&&f(l,p),h&&h(l,p)},!nm(t))return;this.handlers=n,this.transformPagePoint=r;const i=Is(t),o=ya(i,this.transformPagePoint),{point:s}=o,{timestamp:a}=Ht;this.history=[{...s,timestamp:a}];const{onSessionStart:c}=n;c&&c(t,ba(o,this.history)),this.removeListeners=sr(Hn(window,"pointermove",this.handlePointerMove),Hn(window,"pointerup",this.handlePointerUp),Hn(window,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),yn(this.updatePoint)}}function ya(e,t){return t?{point:t(e.point)}:e}function Zd(e,t){return{x:e.x-t.x,y:e.y-t.y}}function ba({point:e},t){return{point:e,delta:Zd(e,Hm(t)),offset:Zd(e,n_(t)),velocity:r_(t,.1)}}function n_(e){return e[0]}function Hm(e){return e[e.length-1]}function r_(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=Hm(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Wn(t)));)n--;if(!r)return{x:0,y:0};const o=In(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function on(e){return e.max-e.min}function ec(e,t=0,n=.01){return Math.abs(e-t)<=n}function Qd(e,t,n,r=.5){e.origin=r,e.originPoint=yt(t.min,t.max,e.origin),e.scale=on(n)/on(t),(ec(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=yt(n.min,n.max,e.origin)-e.originPoint,(ec(e.translate)||isNaN(e.translate))&&(e.translate=0)}function Do(e,t,n,r){Qd(e.x,t.x,n.x,r?r.originX:void 0),Qd(e.y,t.y,n.y,r?r.originY:void 0)}function Jd(e,t,n){e.min=n.min+t.min,e.max=e.min+on(t)}function o_(e,t,n){Jd(e.x,t.x,n.x),Jd(e.y,t.y,n.y)}function ef(e,t,n){e.min=t.min-n.min,e.max=e.min+on(t)}function Oo(e,t,n){ef(e.x,t.x,n.x),ef(e.y,t.y,n.y)}function i_(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?yt(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?yt(n,e,r.max):Math.min(e,n)),e}function tf(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function s_(e,{top:t,left:n,bottom:r,right:i}){return{x:tf(e.x,n,i),y:tf(e.y,t,r)}}function nf(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}}function a_(e,t){return{x:nf(e.x,t.x),y:nf(e.y,t.y)}}function c_(e,t){let n=.5;const r=on(e),i=on(t);return i>r?n=io(t.min,t.max-r,e.min):r>i&&(n=io(e.min,e.max-i,t.min)),dr(0,1,n)}function l_(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const tc=.35;function u_(e=tc){return e===!1?e=0:e===!0&&(e=tc),{x:rf(e,"left","right"),y:rf(e,"top","bottom")}}function rf(e,t,n){return{min:of(e,t),max:of(e,n)}}function of(e,t){return typeof e=="number"?e:e[t]||0}const sf=()=>({translate:0,scale:1,origin:0,originPoint:0}),Zr=()=>({x:sf(),y:sf()}),af=()=>({min:0,max:0}),At=()=>({x:af(),y:af()});function Sn(e){return[e("x"),e("y")]}function Wm({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function d_({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function f_(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}}function wa(e){return e===void 0||e===1}function nc({scale:e,scaleX:t,scaleY:n}){return!wa(e)||!wa(t)||!wa(n)}function Sr(e){return nc(e)||Um(e)||e.z||e.rotate||e.rotateX||e.rotateY}function Um(e){return cf(e.x)||cf(e.y)}function cf(e){return e&&e!=="0%"}function Xi(e,t,n){const r=e-n,i=t*r;return n+i}function lf(e,t,n,r,i){return i!==void 0&&(e=Xi(e,i,r)),Xi(e,n,r)+t}function rc(e,t=0,n=1,r,i){e.min=lf(e.min,t,n,r,i),e.max=lf(e.max,t,n,r,i)}function Ym(e,{x:t,y:n}){rc(e.x,t.translate,t.scale,t.originPoint),rc(e.y,n.translate,n.scale,n.originPoint)}function p_(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let o,s;for(let a=0;a<i;a++){o=n[a],s=o.projectionDelta;const c=o.instance;c&&c.style&&c.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Qr(e,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Ym(e,s)),r&&Sr(o.latestValues)&&Qr(e,o.latestValues))}t.x=uf(t.x),t.y=uf(t.y)}function uf(e){return Number.isInteger(e)||e>1.0000000000001||e<.999999999999?e:1}function or(e,t){e.min=e.min+t,e.max=e.max+t}function df(e,t,[n,r,i]){const o=t[i]!==void 0?t[i]:.5,s=yt(e.min,e.max,o);rc(e,t[n],t[r],s,t.scale)}const h_=["x","scaleX","originX"],m_=["y","scaleY","originY"];function Qr(e,t){df(e.x,t,h_),df(e.y,t,m_)}function zm(e,t){return Wm(f_(e.getBoundingClientRect(),t))}function v_(e,t,n){const r=zm(e,n),{scroll:i}=t;return i&&(or(r.x,i.offset.x),or(r.y,i.offset.y)),r}const g_=new WeakMap;class y_{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=At(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=c=>{this.stopAnimation(),n&&this.snapToCursor(Is(c,"page").point)},o=(c,l)=>{const{drag:d,dragPropagation:f,onDragStart:h}=this.getProps();if(d&&!f&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=om(d),!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),Sn(y=>{let E=this.getAxisMotionValue(y).get()||0;if(Rn.test(E)){const{projection:T}=this.visualElement;if(T&&T.layout){const S=T.layout.layoutBox[y];S&&(E=on(S)*(parseFloat(E)/100))}}this.originPoint[y]=E}),h&&dt.update(()=>h(c,l),!1,!0);const{animationState:p}=this.visualElement;p&&p.setActive("whileDrag",!0)},s=(c,l)=>{const{dragPropagation:d,dragDirectionLock:f,onDirectionLock:h,onDrag:p}=this.getProps();if(!d&&!this.openGlobalLock)return;const{offset:y}=l;if(f&&this.currentDirection===null){this.currentDirection=b_(y),this.currentDirection!==null&&h&&h(this.currentDirection);return}this.updateAxis("x",l.point,y),this.updateAxis("y",l.point,y),this.visualElement.render(),p&&p(c,l)},a=(c,l)=>this.stop(c,l);this.panSession=new Bm(t,{onSessionStart:i,onStart:o,onMove:s,onSessionEnd:a},{transformPagePoint:this.visualElement.getTransformPagePoint()})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=n;this.startAnimation(i);const{onDragEnd:o}=this.getProps();o&&dt.update(()=>o(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!Ei(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=i_(s,this.constraints[t],this.elastic[t])),o.set(s)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),{layout:r}=this.visualElement.projection||{},i=this.constraints;t&&Xr(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=s_(r.layoutBox,t):this.constraints=!1,this.elastic=u_(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Sn(o=>{this.getAxisMotionValue(o)&&(this.constraints[o]=l_(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Xr(t))return!1;const r=t.current;rn(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const o=v_(r,i.root,this.visualElement.getTransformPagePoint());let s=a_(i.layout.layoutBox,o);if(n){const a=n(d_(s));this.hasMutatedConstraints=!!a,a&&(s=Wm(a))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),c=this.constraints||{},l=Sn(d=>{if(!Ei(d,n,this.currentDirection))return;let f=c&&c[d]||{};s&&(f={min:0,max:0});const h=i?200:1e6,p=i?40:1e7,y={type:"inertia",velocity:r?t[d]:0,bounceStiffness:h,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...o,...f};return this.startAxisValueAnimation(d,y)});return Promise.all(l).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return r.start(ol(t,r,0,n))}stopAnimation(){Sn(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){const n="_drag"+t.toUpperCase(),r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Sn(n=>{const{drag:r}=this.getProps();if(!Ei(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:a}=i.layout.layoutBox[n];o.set(t[n]-yt(s,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Xr(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Sn(s=>{const a=this.getAxisMotionValue(s);if(a){const c=a.get();i[s]=c_({min:c,max:c},this.constraints[s])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Sn(s=>{if(!Ei(s,t,null))return;const a=this.getAxisMotionValue(s),{min:c,max:l}=this.constraints[s];a.set(yt(c,l,i[s]))})}addListeners(){if(!this.visualElement.current)return;g_.set(this.visualElement,this);const t=this.visualElement.current,n=Hn(t,"pointerdown",c=>{const{drag:l,dragListener:d=!0}=this.getProps();l&&d&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();Xr(c)&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,o=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),r();const s=Ln(window,"resize",()=>this.scalePositionWithinConstraints()),a=i.addEventListener("didUpdate",({delta:c,hasLayoutChanged:l})=>{this.isDragging&&l&&(Sn(d=>{const f=this.getAxisMotionValue(d);f&&(this.originPoint[d]+=c[d].translate,f.set(f.get()+c[d].translate))}),this.visualElement.render())});return()=>{s(),n(),o(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:s=tc,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:s,dragMomentum:a}}}function Ei(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function b_(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class w_ extends vr{constructor(t){super(t),this.removeGroupControls=Ct,this.removeListeners=Ct,this.controls=new y_(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ct}unmount(){this.removeGroupControls(),this.removeListeners()}}const ff=e=>(t,n)=>{e&&dt.update(()=>e(t,n))};class x_ extends vr{constructor(){super(...arguments),this.removePointerDownListener=Ct}onPointerDown(t){this.session=new Bm(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint()})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:ff(t),onStart:ff(n),onMove:r,onEnd:(o,s)=>{delete this.session,i&&dt.update(()=>i(o,s))}}}mount(){this.removePointerDownListener=Hn(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}function E_(){const e=u.useContext(Cs);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,i=u.useId();return u.useEffect(()=>r(i),[]),!t&&n?[!1,()=>n&&n(i)]:[!0]}const Di={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function pf(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Co={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(Me.test(e))e=parseFloat(e);else return e;const n=pf(e,t.target.x),r=pf(e,t.target.y);return`${n}% ${r}%`}},C_={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=fr.parse(e);if(i.length>5)return r;const o=fr.createTransformer(e),s=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,c=n.y.scale*t.y;i[0+s]/=a,i[1+s]/=c;const l=yt(a,c,.5);return typeof i[2+s]=="number"&&(i[2+s]/=l),typeof i[3+s]=="number"&&(i[3+s]/=l),o(i)}};class __ extends u.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;j1(T_),o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),Di.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,s=r.projection;return s&&(s.isPresent=o,i||t.layoutDependency!==n||n===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?s.promote():s.relegate()||dt.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),queueMicrotask(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Km(e){const[t,n]=E_(),r=u.useContext(Wc);return u.createElement(__,{...e,layoutGroup:r,switchLayoutGroup:u.useContext(Hh),isPresent:t,safeToRemove:n})}const T_={borderRadius:{...Co,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Co,borderTopRightRadius:Co,borderBottomLeftRadius:Co,borderBottomRightRadius:Co,boxShadow:C_},qm=["TopLeft","TopRight","BottomLeft","BottomRight"],S_=qm.length,hf=e=>typeof e=="string"?parseFloat(e):e,mf=e=>typeof e=="number"||Me.test(e);function $_(e,t,n,r,i,o){i?(e.opacity=yt(0,n.opacity!==void 0?n.opacity:1,P_(r)),e.opacityExit=yt(t.opacity!==void 0?t.opacity:1,0,R_(r))):o&&(e.opacity=yt(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let s=0;s<S_;s++){const a=`border${qm[s]}Radius`;let c=vf(t,a),l=vf(n,a);if(c===void 0&&l===void 0)continue;c||(c=0),l||(l=0),c===0||l===0||mf(c)===mf(l)?(e[a]=Math.max(yt(hf(c),hf(l),r),0),(Rn.test(l)||Rn.test(c))&&(e[a]+="%")):e[a]=l}(t.rotate||n.rotate)&&(e.rotate=yt(t.rotate||0,n.rotate||0,r))}function vf(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const P_=Xm(0,.5,Qc),R_=Xm(.5,.95,Ct);function Xm(e,t,n){return r=>r<e?0:r>t?1:n(io(e,t,r))}function gf(e,t){e.min=t.min,e.max=t.max}function un(e,t){gf(e.x,t.x),gf(e.y,t.y)}function yf(e,t,n,r,i){return e-=t,e=Xi(e,1/n,r),i!==void 0&&(e=Xi(e,1/i,r)),e}function I_(e,t=0,n=1,r=.5,i,o=e,s=e){if(Rn.test(t)&&(t=parseFloat(t),t=yt(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=yt(o.min,o.max,r);e===o&&(a-=t),e.min=yf(e.min,t,n,a,i),e.max=yf(e.max,t,n,a,i)}function bf(e,t,[n,r,i],o,s){I_(e,t[n],t[r],t[i],t.scale,o,s)}const A_=["x","scaleX","originX"],D_=["y","scaleY","originY"];function wf(e,t,n,r){bf(e.x,t,A_,n?n.x:void 0,r?r.x:void 0),bf(e.y,t,D_,n?n.y:void 0,r?r.y:void 0)}function xf(e){return e.translate===0&&e.scale===1}function Gm(e){return xf(e.x)&&xf(e.y)}function O_(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 Zm(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function Ef(e){return on(e.x)/on(e.y)}class M_{constructor(){this.members=[]}add(t){il(this.members,t),t.scheduleRender()}remove(t){if(Ds(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const o=this.members[i];if(o.isPresent!==!1){r=o;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function Cf(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y;if((i||o)&&(r=`translate3d(${i}px, ${o}px, 0) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:c,rotateX:l,rotateY:d}=n;c&&(r+=`rotate(${c}deg) `),l&&(r+=`rotateX(${l}deg) `),d&&(r+=`rotateY(${d}deg) `)}const s=e.x.scale*t.x,a=e.y.scale*t.y;return(s!==1||a!==1)&&(r+=`scale(${s}, ${a})`),r||"none"}const k_=(e,t)=>e.depth-t.depth;class N_{constructor(){this.children=[],this.isDirty=!1}add(t){il(this.children,t),this.isDirty=!0}remove(t){Ds(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(k_),this.isDirty=!1,this.children.forEach(t)}}function j_(e,t){const n=performance.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(yn(r),e(o-t))};return dt.read(r,!0),()=>yn(r)}function V_(e){window.MotionDebug&&window.MotionDebug.record(e)}function Qm(e){return e instanceof SVGElement&&e.tagName!=="svg"}function cl(e,t,n){const r=Ut(e)?e:Or(e);return r.start(ol("",r,t,n)),r.animation}const _f=["","X","Y","Z"],Tf=1e3;let L_=0;const $r={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function Jm({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},a=t==null?void 0:t()){this.id=L_++,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.hasTreeAnimated=!1,this.updateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{$r.totalNodes=$r.resolvedTargetDeltas=$r.recalculatedProjection=0,this.nodes.forEach(H_),this.nodes.forEach(K_),this.nodes.forEach(q_),this.nodes.forEach(W_),V_($r)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new N_)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new sl),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const c=this.eventHandlers.get(s);c&&c.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s,a=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=Qm(s),this.instance=s;const{layoutId:c,layout:l,visualElement:d}=this.options;if(d&&!d.current&&d.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),a&&(l||c)&&(this.isLayoutDirty=!0),e){let f;const h=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,f&&f(),f=j_(h,250),Di.hasAnimatedSinceResize&&(Di.hasAnimatedSinceResize=!1,this.nodes.forEach($f))})}c&&this.root.registerSharedNode(c,this),this.options.animate!==!1&&d&&(c||l)&&this.addEventListener("didUpdate",({delta:f,hasLayoutChanged:h,hasRelativeTargetChanged:p,layout:y})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const E=this.options.transition||d.getDefaultTransition()||J_,{onLayoutAnimationStart:T,onLayoutAnimationComplete:S}=d.getProps(),m=!this.targetLayout||!Zm(this.targetLayout,y)||p,x=!h&&p;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||x||h&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(f,x);const _={...jm(E,"layout"),onPlay:T,onComplete:S};(d.shouldReduceMotion||this.options.layoutRoot)&&(_.delay=0,_.type=!1),this.startAnimation(_)}else h||$f(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=y})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,yn(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(X_),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const f=this.path[d];f.shouldResetTransform=!0,f.updateScroll("snapshot"),f.options.layoutRoot&&f.willUpdate(!1)}const{layoutId:a,layout:c}=this.options;if(a===void 0&&!c)return;const l=this.getTransformTemplate();this.prevTransformTemplateValue=l?l(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Sf);return}this.isUpdating||this.nodes.forEach(Y_),this.isUpdating=!1,this.nodes.forEach(z_),this.nodes.forEach(F_),this.nodes.forEach(B_),this.clearAllSnapshots();const a=performance.now();Ht.delta=dr(0,1e3/60,a-Ht.timestamp),Ht.timestamp=a,Ht.isProcessing=!0,ua.update.process(Ht),ua.preRender.process(Ht),ua.render.process(Ht),Ht.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,queueMicrotask(()=>this.update()))}clearAllSnapshots(){this.nodes.forEach(U_),this.sharedNodes.forEach(G_)}scheduleUpdateProjection(){dt.preRender(this.updateProjection,!1,!0)}scheduleCheckAfterUnmount(){dt.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let c=0;c<this.path.length;c++)this.path[c].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutCorrected=At(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&(this.scroll={animationId:this.root.animationId,phase:s,isRoot:r(this.instance),offset:n(this.instance)})}resetTransform(){if(!i)return;const s=this.isLayoutDirty||this.shouldResetTransform,a=this.projectionDelta&&!Gm(this.projectionDelta),c=this.getTransformTemplate(),l=c?c(this.latestValues,""):void 0,d=l!==this.prevTransformTemplateValue;s&&(a||Sr(this.latestValues)||d)&&(i(this.instance,l),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let c=this.removeElementScroll(a);return s&&(c=this.removeTransform(c)),eT(c),{animationId:this.root.animationId,measuredBox:a,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return At();const a=s.measureViewportBox(),{scroll:c}=this.root;return c&&(or(a.x,c.offset.x),or(a.y,c.offset.y)),a}removeElementScroll(s){const a=At();un(a,s);for(let c=0;c<this.path.length;c++){const l=this.path[c],{scroll:d,options:f}=l;if(l!==this.root&&d&&f.layoutScroll){if(d.isRoot){un(a,s);const{scroll:h}=this.root;h&&(or(a.x,-h.offset.x),or(a.y,-h.offset.y))}or(a.x,d.offset.x),or(a.y,d.offset.y)}}return a}applyTransform(s,a=!1){const c=At();un(c,s);for(let l=0;l<this.path.length;l++){const d=this.path[l];!a&&d.options.layoutScroll&&d.scroll&&d!==d.root&&Qr(c,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),Sr(d.latestValues)&&Qr(c,d.latestValues)}return Sr(this.latestValues)&&Qr(c,this.latestValues),c}removeTransform(s){const a=At();un(a,s);for(let c=0;c<this.path.length;c++){const l=this.path[c];if(!l.instance||!Sr(l.latestValues))continue;nc(l.latestValues)&&l.updateSnapshot();const d=At(),f=l.measurePageBox();un(d,f),wf(a,l.latestValues,l.snapshot?l.snapshot.layoutBox:void 0,d)}return Sr(this.latestValues)&&wf(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}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}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Ht.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var a;const c=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=c.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=c.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=c.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==c;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||!((a=this.parent)===null||a===void 0)&&a.isProjectionDirty||this.attemptToResolveRelativeTarget))return;const{layout:f,layoutId:h}=this.options;if(!(!this.layout||!(f||h))){if(this.resolvedRelativeTargetAt=Ht.timestamp,!this.targetDelta&&!this.relativeTarget){const p=this.getClosestProjectingParent();p&&p.layout&&this.animationProgress!==1?(this.relativeParent=p,this.forceRelativeParentToResolveTarget(),this.relativeTarget=At(),this.relativeTargetOrigin=At(),Oo(this.relativeTargetOrigin,this.layout.layoutBox,p.layout.layoutBox),un(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=At(),this.targetWithTransforms=At()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),o_(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):un(this.target,this.layout.layoutBox),Ym(this.target,this.targetDelta)):un(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const p=this.getClosestProjectingParent();p&&!!p.resumingFrom==!!this.resumingFrom&&!p.options.layoutScroll&&p.target&&this.animationProgress!==1?(this.relativeParent=p,this.forceRelativeParentToResolveTarget(),this.relativeTarget=At(),this.relativeTargetOrigin=At(),Oo(this.relativeTargetOrigin,this.target,p.target),un(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}$r.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||nc(this.parent.latestValues)||Um(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;const a=this.getLead(),c=!!this.resumingFrom||this!==a;let l=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(l=!1),c&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===Ht.timestamp&&(l=!1),l)return;const{layout:d,layoutId:f}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(d||f))return;un(this.layoutCorrected,this.layout.layoutBox);const h=this.treeScale.x,p=this.treeScale.y;p_(this.layoutCorrected,this.treeScale,this.path,c),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox);const{target:y}=a;if(!y){this.projectionTransform&&(this.projectionDelta=Zr(),this.projectionTransform="none",this.scheduleRender());return}this.projectionDelta||(this.projectionDelta=Zr(),this.projectionDeltaWithTransform=Zr());const E=this.projectionTransform;Do(this.projectionDelta,this.layoutCorrected,y,this.latestValues),this.projectionTransform=Cf(this.projectionDelta,this.treeScale),(this.projectionTransform!==E||this.treeScale.x!==h||this.treeScale.y!==p)&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",y)),$r.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.scheduleRender&&this.options.scheduleRender(),s){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}setAnimationOrigin(s,a=!1){const c=this.snapshot,l=c?c.latestValues:{},d={...this.latestValues},f=Zr();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=At(),p=c?c.source:void 0,y=this.layout?this.layout.source:void 0,E=p!==y,T=this.getStack(),S=!T||T.members.length<=1,m=!!(E&&!S&&this.options.crossfade===!0&&!this.path.some(Q_));this.animationProgress=0;let x;this.mixTargetDelta=_=>{const $=_/1e3;Pf(f.x,s.x,$),Pf(f.y,s.y,$),this.setTargetDelta(f),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Oo(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Z_(this.relativeTarget,this.relativeTargetOrigin,h,$),x&&O_(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=At()),un(x,this.relativeTarget)),E&&(this.animationValues=d,$_(d,l,this.latestValues,$,m,S)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=$},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(yn(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=dt.update(()=>{Di.hasAnimatedSinceResize=!0,this.currentAnimation=cl(0,Tf,{...s,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onComplete:()=>{s.onComplete&&s.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 s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Tf),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:c,layout:l,latestValues:d}=s;if(!(!a||!c||!l)){if(this!==s&&this.layout&&l&&ev(this.options.animationType,this.layout.layoutBox,l.layoutBox)){c=this.target||At();const f=on(this.layout.layoutBox.x);c.x.min=s.target.x.min,c.x.max=c.x.min+f;const h=on(this.layout.layoutBox.y);c.y.min=s.target.y.min,c.y.max=c.y.min+h}un(a,c),Qr(a,d),Do(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new M_),this.sharedNodes.get(s).add(a);const l=a.options.initialPromotionConfig;a.promote({transition:l?l.transition:void 0,preserveFollowOpacity:l&&l.shouldPreserveFollowOpacity?l.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var s;const{layoutId:a}=this.options;return a?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;const{layoutId:a}=this.options;return a?(s=this.getStack())===null||s===void 0?void 0:s.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:c}={}){const l=this.getStack();l&&l.promote(this,c),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:c}=s;if((c.rotate||c.rotateX||c.rotateY||c.rotateZ)&&(a=!0),!a)return;const l={};for(let d=0;d<_f.length;d++){const f="rotate"+_f[d];c[f]&&(l[f]=c[f],s.setStaticValue(f,0))}s.render();for(const d in l)s.setStaticValue(d,l[d]);s.scheduleRender()}getProjectionStyles(s={}){var a,c;const l={};if(!this.instance||this.isSVG)return l;if(this.isVisible)l.visibility="";else return{visibility:"hidden"};const d=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,l.opacity="",l.pointerEvents=Ai(s.pointerEvents)||"",l.transform=d?d(this.latestValues,""):"none",l;const f=this.getLead();if(!this.projectionDelta||!this.layout||!f.target){const E={};return this.options.layoutId&&(E.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,E.pointerEvents=Ai(s.pointerEvents)||""),this.hasProjected&&!Sr(this.latestValues)&&(E.transform=d?d({},""):"none",this.hasProjected=!1),E}const h=f.animationValues||f.latestValues;this.applyTransformsToTarget(),l.transform=Cf(this.projectionDeltaWithTransform,this.treeScale,h),d&&(l.transform=d(h,l.transform));const{x:p,y}=this.projectionDelta;l.transformOrigin=`${p.origin*100}% ${y.origin*100}% 0`,f.animationValues?l.opacity=f===this?(c=(a=h.opacity)!==null&&a!==void 0?a:this.latestValues.opacity)!==null&&c!==void 0?c:1:this.preserveOpacity?this.latestValues.opacity:h.opacityExit:l.opacity=f===this?h.opacity!==void 0?h.opacity:"":h.opacityExit!==void 0?h.opacityExit:0;for(const E in Hi){if(h[E]===void 0)continue;const{correct:T,applyTo:S}=Hi[E],m=l.transform==="none"?h[E]:T(h[E],f);if(S){const x=S.length;for(let _=0;_<x;_++)l[S[_]]=m}else l[E]=m}return this.options.layoutId&&(l.pointerEvents=f===this?Ai(s.pointerEvents)||"":"none"),l}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var a;return(a=s.currentAnimation)===null||a===void 0?void 0:a.stop()}),this.root.nodes.forEach(Sf),this.root.sharedNodes.clear()}}}function F_(e){e.updateLayout()}function B_(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:o}=e.options,s=n.source!==e.layout.source;o==="size"?Sn(f=>{const h=s?n.measuredBox[f]:n.layoutBox[f],p=on(h);h.min=r[f].min,h.max=h.min+p}):ev(o,n.layoutBox,r)&&Sn(f=>{const h=s?n.measuredBox[f]:n.layoutBox[f],p=on(r[f]);h.max=h.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+p)});const a=Zr();Do(a,r,n.layoutBox);const c=Zr();s?Do(c,e.applyTransform(i,!0),n.measuredBox):Do(c,r,n.layoutBox);const l=!Gm(a);let d=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:h,layout:p}=f;if(h&&p){const y=At();Oo(y,n.layoutBox,h.layoutBox);const E=At();Oo(E,r,p.layoutBox),Zm(y,E)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=E,e.relativeTargetOrigin=y,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:c,layoutDelta:a,hasLayoutChanged:l,hasRelativeTargetChanged:d})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function H_(e){$r.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function W_(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function U_(e){e.clearSnapshot()}function Sf(e){e.clearMeasurements()}function Y_(e){e.isLayoutDirty=!1}function z_(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function $f(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function K_(e){e.resolveTargetDelta()}function q_(e){e.calcProjection()}function X_(e){e.resetRotation()}function G_(e){e.removeLeadSnapshot()}function Pf(e,t,n){e.translate=yt(t.translate,0,n),e.scale=yt(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Rf(e,t,n,r){e.min=yt(t.min,n.min,r),e.max=yt(t.max,n.max,r)}function Z_(e,t,n,r){Rf(e.x,t.x,n.x,r),Rf(e.y,t.y,n.y,r)}function Q_(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const J_={duration:.45,ease:[.4,0,.1,1]},If=e=>typeof navigator<"u"&&navigator.userAgent.toLowerCase().includes(e),Af=If("applewebkit/")&&!If("chrome/")?Math.round:Ct;function Df(e){e.min=Af(e.min),e.max=Af(e.max)}function eT(e){Df(e.x),Df(e.y)}function ev(e,t,n){return e==="position"||e==="preserve-aspect"&&!ec(Ef(t),Ef(n),.2)}const tT=Jm({attachResizeListener:(e,t)=>Ln(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),xa={current:void 0},tv=Jm({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!xa.current){const e=new tT({});e.mount(window),e.setOptions({layoutScroll:!0}),xa.current=e}return xa.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),nT={pan:{Feature:x_},drag:{Feature:w_,ProjectionNode:tv,MeasureLayout:Km}},rT=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function oT(e){const t=rT.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}const iT=4;function oc(e,t,n=1){rn(n<=iT,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,i]=oT(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const s=o.trim();return Vm(s)?parseFloat(s):s}else return Ya(i)?oc(i,t,n+1):i}function sT(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach(i=>{const o=i.get();if(!Ya(o))return;const s=oc(o,r);s&&i.set(s)});for(const i in t){const o=t[i];if(!Ya(o))continue;const s=oc(o,r);s&&(t[i]=s,n||(n={}),n[i]===void 0&&(n[i]=o))}return{target:t,transitionEnd:n}}const aT=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),nv=e=>aT.has(e),cT=e=>Object.keys(e).some(nv),Ci=e=>e===Fr||e===Me,Of=(e,t)=>parseFloat(e.split(", ")[t]),Mf=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/);if(i)return Of(i[1],t);{const o=r.match(/^matrix\((.+)\)$/);return o?Of(o[1],e):0}},lT=new Set(["x","y","z"]),uT=Xo.filter(e=>!lT.has(e));function dT(e){const t=[];return uT.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}const so={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:Mf(4,13),y:Mf(5,14)};so.translateX=so.x;so.translateY=so.y;const fT=(e,t,n)=>{const r=t.measureViewportBox(),i=t.current,o=getComputedStyle(i),{display:s}=o,a={};s==="none"&&t.setStaticValue("display",e.display||"block"),n.forEach(l=>{a[l]=so[l](r,o)}),t.render();const c=t.measureViewportBox();return n.forEach(l=>{const d=t.getValue(l);d&&d.jump(a[l]),e[l]=so[l](c,o)}),e},pT=(e,t,n={},r={})=>{t={...t},r={...r};const i=Object.keys(t).filter(nv);let o=[],s=!1;const a=[];if(i.forEach(c=>{const l=e.getValue(c);if(!e.hasValue(c))return;let d=n[c],f=Eo(d);const h=t[c];let p;if(Ui(h)){const y=h.length,E=h[0]===null?1:0;d=h[E],f=Eo(d);for(let T=E;T<y&&h[T]!==null;T++)p?rn(Eo(h[T])===p,"All keyframes must be of the same type"):(p=Eo(h[T]),rn(p===f||Ci(f)&&Ci(p),"Keyframes must be of the same dimension as the current value"))}else p=Eo(h);if(f!==p)if(Ci(f)&&Ci(p)){const y=l.get();typeof y=="string"&&l.set(parseFloat(y)),typeof h=="string"?t[c]=parseFloat(h):Array.isArray(h)&&p===Me&&(t[c]=h.map(parseFloat))}else f!=null&&f.transform&&(p!=null&&p.transform)&&(d===0||h===0)?d===0?l.set(p.transform(d)):t[c]=f.transform(h):(s||(o=dT(e),s=!0),a.push(c),r[c]=r[c]!==void 0?r[c]:t[c],l.jump(h))}),a.length){const c=a.indexOf("height")>=0?window.pageYOffset:null,l=fT(t,e,a);return o.length&&o.forEach(([d,f])=>{e.getValue(d).set(f)}),e.render(),_s&&c!==null&&window.scrollTo({top:c}),{target:l,transitionEnd:r}}else return{target:t,transitionEnd:r}};function hT(e,t,n,r){return cT(t)?pT(e,t,n,r):{target:t,transitionEnd:r}}const mT=(e,t,n,r)=>{const i=sT(e,t,r);return t=i.target,r=i.transitionEnd,hT(e,t,n,r)},Gi={current:null},ll={current:!1};function rv(){if(ll.current=!0,!!_s)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Gi.current=e.matches;e.addListener(t),t()}else Gi.current=!1}function vT(e,t,n){const{willChange:r}=t;for(const i in t){const o=t[i],s=n[i];if(Ut(o))e.addValue(i,o),qi(r)&&r.add(i),process.env.NODE_ENV==="development"&&Os(o.version==="10.16.1",`Attempting to mix Framer Motion versions ${o.version} with 10.16.1 may not work as expected.`);else if(Ut(s))e.addValue(i,Or(o,{owner:e})),qi(r)&&r.remove(i);else if(s!==o)if(e.hasValue(i)){const a=e.getValue(i);!a.hasAnimated&&a.set(o)}else{const a=e.getStaticValue(i);e.addValue(i,Or(a!==void 0?a:o,{owner:e}))}}for(const i in n)t[i]===void 0&&e.removeValue(i);return t}const Wo=new WeakMap,ov=Object.keys(Ho),gT=ov.length,kf=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],yT=Hc.length;class bT{constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,visualState:o},s={}){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=()=>dt.render(this.render,!1,!0);const{latestValues:a,renderState:c}=o;this.latestValues=a,this.baseTarget={...a},this.initialValues=n.initial?{...a}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=s,this.isControllingVariants=$s(n),this.isVariantNode=Bh(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:l,...d}=this.scrapeMotionValuesFromProps(n,{});for(const f in d){const h=d[f];a[f]!==void 0&&Ut(h)&&(h.set(a[f],!1),qi(l)&&l.add(f))}}scrapeMotionValuesFromProps(t,n){return{}}mount(t){this.current=t,Wo.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),ll.current||rv(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Gi.current,process.env.NODE_ENV!=="production"&&Os(this.shouldReduceMotion!==!0,"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(){Wo.delete(this.current),this.projection&&this.projection.unmount(),yn(this.notifyUpdate),yn(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features)this.features[t].unmount();this.current=null}bindToMotionValue(t,n){const r=Lr.has(t),i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&dt.update(this.notifyUpdate,!1,!0),r&&this.projection&&(this.projection.isTransformDirty=!0)}),o=n.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{i(),o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}loadFeatures({children:t,...n},r,i,o){let s,a;if(process.env.NODE_ENV!=="production"&&i&&r){const c="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";n.ignoreStrict?Qo(!1,c):rn(!1,c)}for(let c=0;c<gT;c++){const l=ov[c],{isEnabled:d,Feature:f,ProjectionNode:h,MeasureLayout:p}=Ho[l];h&&(s=h),d(n)&&(!this.features[l]&&f&&(this.features[l]=new f(this)),p&&(a=p))}if(!this.projection&&s){this.projection=new s(this.latestValues,this.parent&&this.parent.projection);const{layoutId:c,layout:l,drag:d,dragConstraints:f,layoutScroll:h,layoutRoot:p}=n;this.projection.setOptions({layoutId:c,layout:l,alwaysMeasureLayout:!!d||f&&Xr(f),visualElement:this,scheduleRender:()=>this.scheduleRender(),animationType:typeof l=="string"?l:"both",initialPromotionConfig:o,layoutScroll:h,layoutRoot:p})}return a}updateFeatures(){for(const t in this.features){const n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):At()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}makeTargetAnimatable(t,n=!0){return this.makeTargetAnimatableFromInstance(t,this.props,n)}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<kf.length;r++){const i=kf[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o=t["on"+i];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=vT(this,this.scrapeMotionValuesFromProps(t,this.prevProps),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]: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(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const r=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(r.initial=this.props.initial),r}const n={};for(let r=0;r<yT;r++){const i=Hc[r],o=this.props[i];(Bo(o)||o===!1)&&(n[i]=o)}return n}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){n!==this.values.get(t)&&(this.removeValue(t),this.bindToMotionValue(t,n)),this.values.set(t,n),this.latestValues[t]=n.get()}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Or(n,{owner:this}),this.addValue(t,r)),r}readValue(t){var n;return this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options)}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props,i=typeof r=="string"||typeof r=="object"?(n=Zc(this.props,r))===null||n===void 0?void 0:n[t]:void 0;if(r&&i!==void 0)return i;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!Ut(o)?o:this.initialValues[t]!==void 0&&i===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new sl),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class iv extends bT{sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}makeTargetAnimatableFromInstance({transition:t,transitionEnd:n,...r},{transformValues:i},o){let s=FC(r,t||{},this);if(i&&(n&&(n=i(n)),r&&(r=i(r)),s&&(s=i(s))),o){VC(this,r,s);const a=mT(this,r,s,n);n=a.transitionEnd,r=a.target}return{transition:t,transitionEnd:n,...r}}}function wT(e){return window.getComputedStyle(e)}class sv extends iv{readValueFromInstance(t,n){if(Lr.has(n)){const r=rl(n);return r&&r.default||0}else{const r=wT(t),i=(Yh(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return zm(t,n)}build(t,n,r,i){Yc(t,n,r,i.transformTemplate)}scrapeMotionValuesFromProps(t,n){return Gc(t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Ut(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}renderInstance(t,n,r,i){Zh(t,n,r,i)}}class av extends iv{constructor(){super(...arguments),this.isSVGTag=!1}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Lr.has(n)){const r=rl(n);return r&&r.default||0}return n=Qh.has(n)?n:Xc(n),t.getAttribute(n)}measureInstanceViewportBox(){return At()}scrapeMotionValuesFromProps(t,n){return em(t,n)}build(t,n,r,i){Kc(t,n,r,this.isSVGTag,i.transformTemplate)}renderInstance(t,n,r,i){Jh(t,n,r,i)}mount(t){this.isSVGTag=qc(t.tagName),super.mount(t)}}const xT=(e,t)=>Uc(e)?new av(t,{enableHardwareAcceleration:!1}):new sv(t,{enableHardwareAcceleration:!0}),ET={layout:{ProjectionNode:tv,MeasureLayout:Km}},CT={...e_,...SE,...nT,...ET},ar=k1((e,t)=>pE(e,t,CT,xT));function cv(){const e=u.useRef(!1);return Ts(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function _T(){const e=cv(),[t,n]=u.useState(0),r=u.useCallback(()=>{e.current&&n(t+1)},[t]);return[u.useCallback(()=>dt.postRender(r),[r]),t]}class TT extends he.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=this.props.sizeRef.current;r.height=n.offsetHeight||0,r.width=n.offsetWidth||0,r.top=n.offsetTop,r.left=n.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function ST({children:e,isPresent:t}){const n=u.useId(),r=u.useRef(null),i=u.useRef({width:0,height:0,top:0,left:0});return u.useInsertionEffect(()=>{const{width:o,height:s,top:a,left:c}=i.current;if(t||!r.current||!o||!s)return;r.current.dataset.motionPopId=n;const l=document.createElement("style");return document.head.appendChild(l),l.sheet&&l.sheet.insertRule(`
|
|
113
113
|
[data-motion-pop-id="${n}"] {
|
|
114
114
|
position: absolute !important;
|
|
115
115
|
width: ${o}px !important;
|
|
@@ -117,7 +117,7 @@ Valid keys: `+JSON.stringify(Object.keys(W),null," "));var Z=te(B,ee,q,ne,ae+".
|
|
|
117
117
|
top: ${a}px !important;
|
|
118
118
|
left: ${c}px !important;
|
|
119
119
|
}
|
|
120
|
-
`),()=>{document.head.removeChild(l)}},[t]),he.createElement(TT,{isPresent:t,childRef:r,sizeRef:i},he.cloneElement(e,{ref:r}))}const Ea=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s})=>{const a=Rs($T),c=u.useId(),l=u.useMemo(()=>({id:c,initial:t,isPresent:n,custom:i,onExitComplete:d=>{a.set(d,!0);for(const f of a.values())if(!f)return;r&&r()},register:d=>(a.set(d,!1),()=>a.delete(d))}),o?void 0:[n]);return u.useMemo(()=>{a.forEach((d,f)=>a.set(f,!1))},[n]),he.useEffect(()=>{!n&&!a.size&&r&&r()},[n]),s==="popLayout"&&(e=he.createElement(ST,{isPresent:n},e)),he.createElement(Cs.Provider,{value:l},e)};function $T(){return new Map}function PT(e){return u.useEffect(()=>()=>e(),[])}const qr=e=>e.key||"";function RT(e,t){e.forEach(n=>{const r=qr(n);t.set(r,n)})}function IT(e){const t=[];return u.Children.forEach(e,n=>{u.isValidElement(n)&&t.push(n)}),t}const AT=({children:e,custom:t,initial:n=!0,onExitComplete:r,exitBeforeEnter:i,presenceAffectsLayout:o=!0,mode:s="sync"})=>{rn(!i,"Replace exitBeforeEnter with mode='wait'");const a=u.useContext(Wc).forceRender||_T()[0],c=cv(),l=IT(e);let d=l;const f=u.useRef(new Map).current,h=u.useRef(d),p=u.useRef(new Map).current,w=u.useRef(!0);if(Ts(()=>{w.current=!1,RT(l,p),h.current=d}),PT(()=>{w.current=!0,p.clear(),f.clear()}),w.current)return he.createElement(he.Fragment,null,d.map(m=>he.createElement(Ea,{key:qr(m),isPresent:!0,initial:n?void 0:!1,presenceAffectsLayout:o,mode:s},m)));d=[...d];const E=h.current.map(qr),T=l.map(qr),S=E.length;for(let m=0;m<S;m++){const x=E[m];T.indexOf(x)===-1&&!f.has(x)&&f.set(x,void 0)}return s==="wait"&&f.size&&(d=[]),f.forEach((m,x)=>{if(T.indexOf(x)!==-1)return;const _=p.get(x);if(!_)return;const $=E.indexOf(x);let O=m;if(!O){const M=()=>{p.delete(x),f.delete(x);const N=h.current.findIndex(j=>j.key===x);if(h.current.splice(N,1),!f.size){if(h.current=l,c.current===!1)return;a(),r&&r()}};O=he.createElement(Ea,{key:qr(_),isPresent:!1,onExitComplete:M,custom:t,presenceAffectsLayout:o,mode:s},_),f.set(x,O)}d.splice($,0,O)}),d=d.map(m=>{const x=m.key;return f.has(x)?m:he.createElement(Ea,{key:qr(m),isPresent:!0,presenceAffectsLayout:o,mode:s},m)}),process.env.NODE_ENV!=="production"&&s==="wait"&&d.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`),he.createElement(he.Fragment,null,f.size?d:d.map(m=>u.cloneElement(m)))};function ic(e){const t=Rs(()=>Or(e)),{isStatic:n}=u.useContext(Fc);if(n){const[,r]=u.useState(e);u.useEffect(()=>t.on("change",r),[])}return t}const DT=e=>typeof e=="object"&&e.mix,OT=e=>DT(e)?e.mix:void 0;function MT(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],o=e[2+n],s=e[3+n],a=tl(i,o,{mixer:OT(o[0]),...s});return t?a(r):a}function lv(e,t){const n=ic(t()),r=()=>n.set(t());return r(),Ts(()=>{const i=()=>dt.update(r,!1,!0),o=e.map(s=>s.on("change",i));return()=>{o.forEach(s=>s()),yn(r)}}),n}function kT(e){Ao.current=[],e();const t=lv(Ao.current,e);return Ao.current=void 0,t}function Zi(e,t,n,r){if(typeof e=="function")return kT(e);const i=typeof t=="function"?t:MT(t,n,r);return Array.isArray(e)?Nf(e,i):Nf([e],([o])=>i(o))}function Nf(e,t){const n=Rs(()=>[]);return lv(e,()=>{n.length=0;const r=e.length;for(let i=0;i<r;i++)n[i]=e[i].get();return t(n)})}function uv(e,t,n){var r;if(typeof e=="string"){let i=document;t&&(rn(!!t.current,"Scope provided, but no element detected."),i=t.current),n?((r=n[e])!==null&&r!==void 0||(n[e]=i.querySelectorAll(e)),e=n[e]):e=i.querySelectorAll(e)}else e instanceof Element&&(e=[e]);return Array.from(e||[])}function NT(){!ll.current&&rv();const[e]=u.useState(Gi.current);return process.env.NODE_ENV!=="production"&&Os(e!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),e}function jT(e,t){let n;const r=()=>{const{currentTime:i}=t,s=(i===null?0:i.value)/100;n!==s&&e(s),n=s};return dt.update(r,!0),()=>yn(r)}const VT=Mm(()=>window.ScrollTimeline!==void 0);class dv{constructor(t){this.animations=t.filter(Boolean)}then(t,n){return Promise.all(this.animations).then(t).catch(n)}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=n}attachTimeline(t){const n=this.animations.map(r=>{if(VT()&&r.attachTimeline)r.attachTimeline(t);else return r.pause(),jT(i=>{r.time=r.duration*i},t)});return()=>{n.forEach((r,i)=>{r&&r(),this.animations[i].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get duration(){let t=0;for(let n=0;n<this.animations.length;n++)t=Math.max(t,this.animations[n].duration);return t}runAll(t){this.animations.forEach(n=>n[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}stop(){this.runAll("stop")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}function LT(e){return typeof e=="object"&&!Array.isArray(e)}function FT(e){const t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=Qm(e)?new av(t,{enableHardwareAcceleration:!1}):new sv(t,{enableHardwareAcceleration:!0});n.mount(e),Wo.set(e,n)}function BT(e,t=100){const n=nl({keyframes:[0,t],...e}),r=Math.min(Ga(n),Xa);return{type:"keyframes",ease:i=>n.next(r*i).value/t,duration:In(r)}}function jf(e,t,n,r){var i;return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?n:(i=r.get(t))!==null&&i!==void 0?i:e}const HT=(e,t,n)=>{const r=t-e;return((n-e)%r+r)%r+e};function WT(e,t){return hm(e)?e[HT(0,e.length,t)]:e}function UT(e,t,n){for(let r=0;r<e.length;r++){const i=e[r];i.at>t&&i.at<n&&(Ds(e,i),r--)}}function YT(e,t,n,r,i,o){UT(e,i,o);for(let s=0;s<t.length;s++)e.push({value:t[s],at:yt(i,o,r[s]),easing:WT(n,s)})}function zT(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}const KT="easeInOut";function qT(e,{defaultTransition:t={},...n}={},r){const i=t.duration||.3,o=new Map,s=new Map,a={},c=new Map;let l=0,d=0,f=0;for(let h=0;h<e.length;h++){const p=e[h];if(typeof p=="string"){c.set(p,d);continue}else if(!Array.isArray(p)){c.set(p.name,jf(d,p.at,l,c));continue}let[w,E,T={}]=p;T.at!==void 0&&(d=jf(d,T.at,l,c));let S=0;const m=(x,_,$,O=0,M=0)=>{const N=XT(x),{delay:j=0,times:K=Am(N),type:V="keyframes",...P}=_;let{ease:v=t.ease||"easeOut",duration:C}=_;const I=typeof j=="function"?j(O,M):j,k=N.length;if(k<=2&&V==="spring"){let W=100;if(k===2&&QT(N)){const X=N[1]-N[0];W=Math.abs(X)}const L={...P};C!==void 0&&(L.duration=Wn(C));const oe=BT(L,W);v=oe.ease,C=oe.duration}C??(C=i);const U=d+I,G=U+C;K.length===1&&K[0]===0&&(K[1]=1);const ue=K.length-N.length;ue>0&&Im(K,ue),N.length===1&&N.unshift(null),YT($,N,v,K,U,G),S=Math.max(I+C,S),f=Math.max(G,f)};if(Ut(w)){const x=Vf(w,s);m(E,T,Lf("default",x))}else{const x=uv(w,r,a),_=x.length;for(let $=0;$<_;$++){E=E,T=T;const O=x[$],M=Vf(O,s);for(const N in E)m(E[N],GT(T,N),Lf(N,M),$,_)}l=d,d+=S}}return s.forEach((h,p)=>{for(const w in h){const E=h[w];E.sort(zT);const T=[],S=[],m=[];for(let _=0;_<E.length;_++){const{at:$,value:O,easing:M}=E[_];T.push(O),S.push(io(0,f,$)),m.push(M||"easeOut")}S[0]!==0&&(S.unshift(0),T.unshift(T[0]),m.unshift(KT)),S[S.length-1]!==1&&(S.push(1),T.push(null)),o.has(p)||o.set(p,{keyframes:{},transition:{}});const x=o.get(p);x.keyframes[w]=T,x.transition[w]={...t,duration:f,ease:m,times:S,...n}}}),o}function Vf(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function Lf(e,t){return t[e]||(t[e]=[]),t[e]}function XT(e){return Array.isArray(e)?e:[e]}function GT(e,t){return e[t]?{...e,...e[t]}:{...e}}const ZT=e=>typeof e=="number",QT=e=>e.every(ZT);function fv(e,t,n,r){const i=uv(e,r),o=i.length;rn(!!o,"No valid element provided.");const s=[];for(let a=0;a<o;a++){const c=i[a];Wo.has(c)||FT(c);const l=Wo.get(c),d={...n};typeof d.delay=="function"&&(d.delay=d.delay(a,o)),s.push(...al(l,{...t,transition:d},{}))}return new dv(s)}const JT=e=>Array.isArray(e)&&Array.isArray(e[0]);function eS(e,t,n){const r=[];return qT(e,t,n).forEach(({keyframes:o,transition:s},a)=>{let c;Ut(a)?c=cl(a,o.default,s.default):c=fv(a,o,s),r.push(c)}),new dv(r)}const tS=e=>{function t(n,r,i){let o;return JT(n)?o=eS(n,r,e):LT(r)?o=fv(n,r,i,e):o=cl(n,r,i),e&&e.animations.push(o),o}return t},Ff=tS();var nS="dyt3ib1",rS="dyt3ib2",oS="dyt3ib6",iS="dyt3ib4",sS="dyt3ib3",Bf="dyt3ib5",aS="dyt3ib7",cS="dyt3ib0";const Hf=e=>!!e.onClick||!!e.onTap,lS=he.forwardRef(({style:e={},className:t="",...n},r)=>{const i=Hf(n)?ar.button:ar.div,o=Hf(n)?"auto":"none";return D.jsx(i,{...n,ref:r,className:Re(t,nS),style:{...e,pointerEvents:o},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}})}),pv=he.createContext(void 0),Ms=()=>{const e=he.useContext(pv);if(!e)throw Error("Sheet context error");return e},hv=he.createContext(void 0);function Wf({children:e}){const t=Ms(),[n,r]=he.useState(!!t.disableDrag);function i(){t.disableDrag||r(!1)}function o(){n||r(!0)}return D.jsx(hv.Provider,{value:{disableDrag:n,setDragEnabled:i,setDragDisabled:o},children:e})}const mv=()=>{const e=he.useContext(hv);if(!e)throw Error("Sheet scroller context error");return e},Uf="90%",vv=typeof window>"u",uS={ease:"easeOut",duration:.2},dS={ease:"linear",duration:.01},fS=.6,pS=500;function Yf(e,t){let n=e[0],r=Math.abs(e[0]-t);for(let i=1;i<e.length;i+=1){const o=Math.abs(e[i]-t);o<r&&(n=e[i],r=o)}return n}function hS(e){const t=document.querySelector("body"),n=document.querySelector(`#${e}`);if(n){const i=window.innerHeight,o=(i-24)/i;t.style.backgroundColor="#000",n.style.overflow="hidden",n.style.willChange="transform",n.style.transition="transform 200ms ease-in-out, border-radius 200ms linear",n.style.transform=`translateY(calc(env(safe-area-inset-top) + ${24/2}px)) scale(${o})`,n.style.borderTopRightRadius="10px",n.style.borderTopLeftRadius="10px"}}function zf(e){const t=document.querySelector("body"),n=document.getElementById(e);function r(){n.style.removeProperty("overflow"),n.style.removeProperty("will-change"),n.style.removeProperty("transition"),t.style.removeProperty("background-color"),n.removeEventListener("transitionend",r)}n&&(n.style.removeProperty("border-top-right-radius"),n.style.removeProperty("border-top-left-radius"),n.style.removeProperty("transform"),n.addEventListener("transitionend",r))}function mS(e){for(let t=0;t<e.length;t+=1)if(e[t+1]>e[t])return!1;return!0}function Kf({snapTo:e,sheetHeight:t}){return e<0&&console.warn(`Snap point is out of bounds. Sheet height is ${t} but snap point is ${t+Math.abs(e)}.`),Math.max(Math.round(e),0)}function vS(e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n&&(n.current=t)})}}function gS(){return typeof window>"u"?!1:"ontouchstart"in window||navigator.maxTouchPoints>0}const ul=vv?he.useEffect:he.useLayoutEffect;function yS(e,t){const n=gv(e);he.useEffect(()=>{t&&!n&&e?hS(t):t&&!e&&n&&zf(t)},[e,n]),he.useEffect(()=>()=>{t&&e&&zf(t)},[e])}function bS(e,t){const n=gv(e),r=he.useRef(!1),i=he.useCallback(()=>{var o,s,a,c;r.current?((c=(a=t.current).onCloseEnd)==null||c.call(a),r.current=!1):((s=(o=t.current).onOpenEnd)==null||s.call(o),r.current=!0)},[e,n]);return he.useEffect(()=>{var o,s,a,c;!n&&e?(s=(o=t.current).onOpenStart)==null||s.call(o):!e&&n&&((c=(a=t.current).onCloseStart)==null||c.call(a))},[e,n]),{handleAnimationComplete:i}}function wS(){const[e,t]=he.useState(0);return ul(()=>{const n=()=>t(window.innerHeight);return window.addEventListener("resize",n),n(),()=>window.removeEventListener("resize",n)},[]),e}function gv(e){const t=he.useRef();return he.useEffect(()=>{t.current=e}),t.current}function qf(e){const t=he.useRef();return ul(()=>{t.current=e}),he.useCallback((...n)=>{const r=t.current;return r==null?void 0:r(...n)},[])}const xS=he.forwardRef(({children:e,style:t={},className:n="",noPadding:r,...i},o)=>{const{y:s,isOpen:a,callbacks:c,snapPoints:l,initialSnap:d=0,sheetRef:f,windowHeight:h,detent:p,animationOptions:w,reduceMotion:E}=Ms(),{handleAnimationComplete:T}=bS(a,c),S=l?l[0]-l[d]:0,m=l?l[0]:null,x=m!==null?`min(${m}px, ${Uf})`:Uf;return D.jsx(ar.div,{...i,ref:vS([f,o]),className:Re(n,rS),style:{...t,...r?{padding:0}:{padding:Et.theme.space[16],paddingTop:0},...p==="full-height"&&{height:x},...p==="content-height"&&{maxHeight:x},y:s},initial:E?!1:{y:h},animate:{y:S,transition:w},exit:{y:h,transition:w},onAnimationComplete:T,children:e})}),ES=he.forwardRef(({children:e,style:t,disableDrag:n,disableDragContent:r,className:i="",...o},s)=>{const a=Ms(),c=mv(),l=n||c.disableDrag||r?void 0:a.dragProps;return D.jsx(ar.div,{...o,ref:s,className:Re(i,oS),style:{...t},...l,children:e})});var CS="aglyib0";const ho=u.forwardRef(({as:e,children:t,className:n,style:r,isDisabled:i,...o},s)=>{const a=e||"button";return D.jsx(a,{ref:s,as:e,"data-test-id":o["data-test-id"],className:Re(CS,n),disabled:i,style:r,...o,children:D.jsx(ls,{size:16,color:i?Et.theme.colors.grey1:Et.theme.colors.black})})});ho.displayName="Button";ho.defaultProps={as:"button","data-test-id":void 0,isDisabled:void 0};const _S=u.forwardRef(({children:e,style:t,disableDrag:n,showBack:r,onBack:i,showClose:o,title:s,onClose:a,noHandleBar:c,noHeader:l,...d},f)=>{const{indicatorRotation:h,dragProps:p}=Ms(),w=n?void 0:p,E=Zi(h,S=>`translateX(2px) rotate(${S}deg)`),T=Zi(h,S=>`translateX(-2px) rotate(${-1*S}deg)`);return D.jsxs(D.Fragment,{children:[!c&&D.jsx(ar.div,{...d,ref:f,className:sS,style:{...t},...w,children:e||D.jsxs("div",{className:iS,children:[D.jsx(ar.span,{className:Bf,style:{transform:E}}),D.jsx(ar.span,{className:Bf,style:{transform:T}})]})}),!l&&D.jsxs(Lt,{alignItems:"center",justifyContent:"space-between",marginBottom:"$8",py:"$16",gap:"$16",children:[D.jsxs(Lt,{alignItems:"center",gap:"$16",children:[r&&D.jsx(X0,{cursor:"pointer",onClick:i,size:18,color:Et.theme.colors.grey1,"data-test-id":"vds-BS-back-btn"}),s&&D.jsx(Kt,{fontWeight:"$bold",textStyle:"subtitle1",m:"$0",children:s})]}),o&&D.jsx(ho,{onClick:a,"data-test-id":"vds-BS-close-btn"})]})]})}),TS=he.forwardRef(({draggableAt:e="top",children:t,style:n,className:r="",...i},o)=>{const s=mv();function a(f){const{scrollTop:h,scrollHeight:p,clientHeight:w}=f;if(!(p>w))return;const T=h<=0,S=p-h===w;e==="top"&&T||e==="bottom"&&S||e==="both"&&(T||S)?s.setDragEnabled():s.setDragDisabled()}function c(f){a(f.currentTarget)}function l(f){a(f.currentTarget)}const d=gS()?{onScroll:c,onTouchStart:l}:void 0;return D.jsx("div",{...i,ref:o,className:Re(r,aS),style:{...n},...d,children:t})}),SS=typeof document<"u"?u.useLayoutEffect:()=>{};function sc(...e){return(...t)=>{for(let n of e)typeof n=="function"&&n(...t)}}let _o=new Map,Xf=new Set;function Gf(){if(typeof window>"u")return;let e=n=>{let r=_o.get(n.target);r||(r=new Set,_o.set(n.target,r),n.target.addEventListener("transitioncancel",t)),r.add(n.propertyName)},t=n=>{let r=_o.get(n.target);if(r&&(r.delete(n.propertyName),r.size===0&&(n.target.removeEventListener("transitioncancel",t),_o.delete(n.target)),_o.size===0)){for(let i of Xf)i();Xf.clear()}};document.body.addEventListener("transitionrun",e),document.body.addEventListener("transitionend",t)}typeof document<"u"&&(document.readyState!=="loading"?Gf():document.addEventListener("DOMContentLoaded",Gf));function yv(e){for(Zf(e)&&(e=e.parentElement);e&&!Zf(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}function Zf(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function dl(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function $S(){return dl(/^Mac/i)}function PS(){return dl(/^iPhone/i)}function RS(){return dl(/^iPad/i)||$S()&&navigator.maxTouchPoints>1}function IS(){return PS()||RS()}const Ca=typeof window<"u"&&window.visualViewport,AS=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);let _i=0,_a;function DS(e={}){const{isDisabled:t}=e;SS(()=>{if(!t)return _i+=1,_i===1&&(IS()?_a=MS():_a=OS()),()=>{_i-=1,_i===0&&_a()}},[t])}function OS(){return sc(Mo(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),Mo(document.documentElement,"overflow","hidden"))}function MS(){let e,t=0;const n=f=>{e=yv(f.target),!(e===document.documentElement&&e===document.body)&&(t=f.changedTouches[0].pageY)},r=f=>{if(e===document.documentElement||e===document.body){f.preventDefault();return}const h=f.changedTouches[0].pageY,{scrollTop:p}=e,w=e.scrollHeight-e.clientHeight;w!==0&&((p<=0&&h>t||p>=w&&h<t)&&f.preventDefault(),t=h)},i=f=>{const h=f.target;Jf(h)&&h!==document.activeElement&&(f.preventDefault(),h.style.transform="translateY(-2000px)",h.focus(),requestAnimationFrame(()=>{h.style.transform=""}))},o=f=>{const h=f.target;Jf(h)&&(h.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{h.style.transform="",Ca&&(Ca.height<window.innerHeight?requestAnimationFrame(()=>{Qf(h)}):Ca.addEventListener("resize",()=>Qf(h),{once:!0}))}))},s=()=>{window.scrollTo(0,0)},a=window.pageXOffset,c=window.pageYOffset,l=sc(Mo(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),Mo(document.documentElement,"overflow","hidden"),Mo(document.body,"marginTop",`-${c}px`));window.scrollTo(0,0);const d=sc(To(document,"touchstart",n,{passive:!1,capture:!0}),To(document,"touchmove",r,{passive:!1,capture:!0}),To(document,"touchend",i,{passive:!1,capture:!0}),To(document,"focus",o,!0),To(window,"scroll",s));return()=>{l(),d(),window.scrollTo(a,c)}}function Mo(e,t,n){const r=e.style[t];return e.style[t]=n,()=>{e.style[t]=r}}function To(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}function Qf(e){const t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){const n=yv(e);if(n!==document.documentElement&&n!==document.body&&n!==e){const r=n.getBoundingClientRect().top,i=e.getBoundingClientRect().top;i>r+e.clientHeight&&(n.scrollTop+=i-r)}e=n.parentElement}}function Jf(e){return e instanceof HTMLInputElement&&!AS.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}const kS=u.forwardRef(({onOpenStart:e,onOpenEnd:t,onClose:n,onCloseStart:r,onCloseEnd:i,onSnap:o,children:s,isOpen:a,snapPoints:c,rootId:l,mountPoint:d,style:f,detent:h="content-height",initialSnap:p=0,disableDrag:w=!1,disableDragContent:E=!1,prefersReducedMotion:T=!1,tweenConfig:S=uS,showClose:m=!0,showBack:x,onBack:_,closeOnClickOutside:$=!0,noHandleBar:O,title:M,noHeader:N,"data-test-id":j,noPadding:K,...V},P)=>{const v=u.useRef(null),C=ic(0),I=wS(),k=NT(),U=!!(T||k),G={type:"tween",...U?dS:S},ue=ic(0),W=Zi(ue,H=>H>=I?-1:Et.tokens.zIndices.modal),L=Zi(ue,H=>H>=I?"hidden":"visible"),oe=u.useRef({onOpenStart:e,onOpenEnd:t,onCloseStart:r,onCloseEnd:i});ul(()=>{oe.current={onOpenStart:e,onOpenEnd:t,onCloseStart:r,onCloseEnd:i}}),c&&(c=c.map(H=>H>0&&H<=1?Math.round(H*I):H<0?I+H:H),console.assert(mS(c)||I===0,`Snap points need to be in descending order got: [${c}]`));const X=qf((H,{delta:J})=>{const ee=ue.getVelocity();ee>0&&C.set(10),ee<0&&C.set(-10),ue.set(Math.max(ue.get()+J.y,0))}),q=qf((H,{velocity:J})=>{if(J.y>pS)n();else{const te=v.current.getBoundingClientRect().height,Z=ue.get();let ge=0;if(c){const Ae=c.map($e=>te-Math.min($e,te));h==="content-height"&&!Ae.includes(0)&&Ae.unshift(0),ge=Yf(Ae,Z)}else Z/te>fS&&(ge=te);if(ge=Kf({snapTo:ge,sheetHeight:te}),Ff(ue,ge,G),c&&o){const Ae=Math.abs(Math.round(c[0]-ge)),$e=c.indexOf(Yf(c,Ae));o($e)}const Te=Math.round(te);ge>=Te&&n()}C.set(0)});u.useEffect(()=>{if(!c||!o)return;const H=a?p:c.length-1;o(H)},[a]),u.useImperativeHandle(P,()=>({y:ue,snapTo:H=>{const J=v.current;if(c&&c[H]!==void 0&&J!==null){const ee=J.getBoundingClientRect().height,te=c[H],Z=Kf({snapTo:ee-te,sheetHeight:ee});Ff(ue,Z,G),o&&o(H),Z>=ee&&n()}}})),yS(a,l),DS({isDisabled:!a});const ne=u.useMemo(()=>w?void 0:{drag:"y",dragElastic:0,dragConstraints:{top:0,bottom:0},dragMomentum:!1,dragPropagation:!1,onDrag:X,onDragEnd:q},[w]),ae={y:ue,sheetRef:v,isOpen:a,initialSnap:p,snapPoints:c,detent:h,indicatorRotation:C,callbacks:oe,dragProps:ne,windowHeight:I,animationOptions:G,reduceMotion:U,disableDrag:w},B=D.jsx(pv.Provider,{value:ae,children:D.jsx(ar.div,{...V,ref:P,className:cS,style:{zIndex:W,visibility:L,...f},children:D.jsx(AT,{children:a?D.jsx(Wf,{children:D.jsxs(Wf,{children:[D.jsxs(xS,{noPadding:K,children:[D.jsx(_S,{showBack:x,noHeader:N,onBack:_,showClose:m,title:M,onClose:n,noHandleBar:O}),D.jsx(ES,{disableDragContent:E,children:D.jsx(TS,{children:s})})]}),D.jsx(lS,{"data-test-id":"CT-BottomSheet-Overlay",onClick:()=>$?n():null})]})}):null})})});return vv?B:fn.createPortal(B,d??document.body)}),mo=({size:e,color:t="inherit",thickness:n=3,...r})=>D.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100",xmlSpace:"preserve",width:e,height:e,...r,children:D.jsx("path",{fill:t,stroke:t,strokeWidth:n,d:"M73 50c0-12.7-10.3-23-23-23S27 37.3 27 50m3.9 0c0-10.5 8.5-19.1 19.1-19.1S69.1 39.5 69.1 50",children:D.jsx("animateTransform",{attributeName:"transform",attributeType:"XML",type:"rotate",dur:"1s",from:"0 50 50",to:"360 50 50",repeatCount:"indefinite"})})});mo.displayName="Spinner";mo.defaultProps={size:24,thickness:3};const NS=({value:e,delay:t=500})=>{const[n,r]=u.useState(e);return u.useEffect(()=>{const i=setTimeout(()=>r(e),t||500);return()=>{clearTimeout(i)}},[e,t]),n},jS=NS;process.env.NODE_ENV;function Mr(e){"@babel/helpers - typeof";return Mr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mr(e)}function pr(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function an(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function Dn(e){an(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||Mr(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}var VS={};function ks(){return VS}var LS=6e4,FS=36e5,BS=1e3;function ao(e){an(1,arguments);var t=1,n=Dn(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function HS(e){an(1,arguments);var t=Dn(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=ao(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var s=ao(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=s.getTime()?n:n-1}function WS(e){an(1,arguments);var t=HS(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=ao(n);return r}var US=6048e5;function YS(e){an(1,arguments);var t=Dn(e),n=ao(t).getTime()-WS(t).getTime();return Math.round(n/US)+1}function kr(e,t){var n,r,i,o,s,a,c,l;an(1,arguments);var d=ks(),f=pr((n=(r=(i=(o=t==null?void 0:t.weekStartsOn)!==null&&o!==void 0?o:t==null||(s=t.locale)===null||s===void 0||(a=s.options)===null||a===void 0?void 0:a.weekStartsOn)!==null&&i!==void 0?i:d.weekStartsOn)!==null&&r!==void 0?r:(c=d.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&n!==void 0?n:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=Dn(e),p=h.getUTCDay(),w=(p<f?7:0)+p-f;return h.setUTCDate(h.getUTCDate()-w),h.setUTCHours(0,0,0,0),h}function bv(e,t){var n,r,i,o,s,a,c,l;an(1,arguments);var d=Dn(e),f=d.getUTCFullYear(),h=ks(),p=pr((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(s=t.locale)===null||s===void 0||(a=s.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:h.firstWeekContainsDate)!==null&&r!==void 0?r:(c=h.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var w=new Date(0);w.setUTCFullYear(f+1,0,p),w.setUTCHours(0,0,0,0);var E=kr(w,t),T=new Date(0);T.setUTCFullYear(f,0,p),T.setUTCHours(0,0,0,0);var S=kr(T,t);return d.getTime()>=E.getTime()?f+1:d.getTime()>=S.getTime()?f:f-1}function zS(e,t){var n,r,i,o,s,a,c,l;an(1,arguments);var d=ks(),f=pr((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(s=t.locale)===null||s===void 0||(a=s.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:d.firstWeekContainsDate)!==null&&r!==void 0?r:(c=d.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1),h=bv(e,t),p=new Date(0);p.setUTCFullYear(h,0,f),p.setUTCHours(0,0,0,0);var w=kr(p,t);return w}var KS=6048e5;function qS(e,t){an(1,arguments);var n=Dn(e),r=kr(n,t).getTime()-zS(n,t).getTime();return Math.round(r/KS)+1}function Ce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ac(e,t){return ac=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},ac(e,t)}function Je(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ac(e,t)}function Qi(e){return Qi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Qi(e)}function XS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function GS(e,t){if(t&&(Mr(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ce(e)}function et(e){var t=XS();return function(){var n=Qi(e),r;if(t){var i=Qi(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return GS(this,r)}}function Ke(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ZS(e,t){if(Mr(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Mr(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function wv(e){var t=ZS(e,"string");return Mr(t)==="symbol"?t:String(t)}function ep(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,wv(r.key),r)}}function qe(e,t,n){return t&&ep(e.prototype,t),n&&ep(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function we(e,t,n){return t=wv(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var QS=function(){function e(){Ke(this,e),we(this,"priority",void 0),we(this,"subPriority",0)}return qe(e,[{key:"validate",value:function(t,n){return!0}}]),e}(),JS=function(e){Je(n,e);var t=et(n);function n(r,i,o,s,a){var c;return Ke(this,n),c=t.call(this),c.value=r,c.validateValue=i,c.setValue=o,c.priority=s,a&&(c.subPriority=a),c}return qe(n,[{key:"validate",value:function(r,i){return this.validateValue(r,this.value,i)}},{key:"set",value:function(r,i,o){return this.setValue(r,i,this.value,o)}}]),n}(QS),nt=function(){function e(){Ke(this,e),we(this,"incompatibleTokens",void 0),we(this,"priority",void 0),we(this,"subPriority",void 0)}return qe(e,[{key:"run",value:function(t,n,r,i){var o=this.parse(t,n,r,i);return o?{setter:new JS(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}},{key:"validate",value:function(t,n,r){return!0}}]),e}(),e$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",140),we(Ce(r),"incompatibleTokens",["R","u","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"G":case"GG":case"GGG":return o.era(r,{width:"abbreviated"})||o.era(r,{width:"narrow"});case"GGGGG":return o.era(r,{width:"narrow"});case"GGGG":default:return o.era(r,{width:"wide"})||o.era(r,{width:"abbreviated"})||o.era(r,{width:"narrow"})}}},{key:"set",value:function(r,i,o){return i.era=o,r.setUTCFullYear(o,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),$t={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},$n={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Pt(e,t){return e&&{value:t(e.value),rest:e.rest}}function xt(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function Pn(e,t){var n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};var r=n[1]==="+"?1:-1,i=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,s=n[5]?parseInt(n[5],10):0;return{value:r*(i*FS+o*LS+s*BS),rest:t.slice(n[0].length)}}function xv(e){return xt($t.anyDigitsSigned,e)}function _t(e,t){switch(e){case 1:return xt($t.singleDigit,t);case 2:return xt($t.twoDigits,t);case 3:return xt($t.threeDigits,t);case 4:return xt($t.fourDigits,t);default:return xt(new RegExp("^\\d{1,"+e+"}"),t)}}function Ev(e,t){switch(e){case 1:return xt($t.singleDigitSigned,t);case 2:return xt($t.twoDigitsSigned,t);case 3:return xt($t.threeDigitsSigned,t);case 4:return xt($t.fourDigitsSigned,t);default:return xt(new RegExp("^-?\\d{1,"+e+"}"),t)}}function fl(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function Cv(e,t){var n=t>0,r=n?t:1-t,i;if(r<=50)i=e||100;else{var o=r+50,s=Math.floor(o/100)*100,a=e>=o%100;i=e+s-(a?100:0)}return n?i:1-i}function _v(e){return e%400===0||e%4===0&&e%100!==0}var t$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return{year:a,isTwoDigitYear:i==="yy"}};switch(i){case"y":return Pt(_t(4,r),s);case"yo":return Pt(o.ordinalNumber(r,{unit:"year"}),s);default:return Pt(_t(i.length,r),s)}}},{key:"validate",value:function(r,i){return i.isTwoDigitYear||i.year>0}},{key:"set",value:function(r,i,o){var s=r.getUTCFullYear();if(o.isTwoDigitYear){var a=Cv(o.year,s);return r.setUTCFullYear(a,0,1),r.setUTCHours(0,0,0,0),r}var c=!("era"in i)||i.era===1?o.year:1-o.year;return r.setUTCFullYear(c,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),n$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return{year:a,isTwoDigitYear:i==="YY"}};switch(i){case"Y":return Pt(_t(4,r),s);case"Yo":return Pt(o.ordinalNumber(r,{unit:"year"}),s);default:return Pt(_t(i.length,r),s)}}},{key:"validate",value:function(r,i){return i.isTwoDigitYear||i.year>0}},{key:"set",value:function(r,i,o,s){var a=bv(r,s);if(o.isTwoDigitYear){var c=Cv(o.year,a);return r.setUTCFullYear(c,0,s.firstWeekContainsDate),r.setUTCHours(0,0,0,0),kr(r,s)}var l=!("era"in i)||i.era===1?o.year:1-o.year;return r.setUTCFullYear(l,0,s.firstWeekContainsDate),r.setUTCHours(0,0,0,0),kr(r,s)}}]),n}(nt),r$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i){return Ev(i==="R"?4:i.length,r)}},{key:"set",value:function(r,i,o){var s=new Date(0);return s.setUTCFullYear(o,0,4),s.setUTCHours(0,0,0,0),ao(s)}}]),n}(nt),o$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i){return Ev(i==="u"?4:i.length,r)}},{key:"set",value:function(r,i,o){return r.setUTCFullYear(o,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),i$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",120),we(Ce(r),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"Q":case"QQ":return _t(i.length,r);case"Qo":return o.ordinalNumber(r,{unit:"quarter"});case"QQQ":return o.quarter(r,{width:"abbreviated",context:"formatting"})||o.quarter(r,{width:"narrow",context:"formatting"});case"QQQQQ":return o.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return o.quarter(r,{width:"wide",context:"formatting"})||o.quarter(r,{width:"abbreviated",context:"formatting"})||o.quarter(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=1&&i<=4}},{key:"set",value:function(r,i,o){return r.setUTCMonth((o-1)*3,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),s$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",120),we(Ce(r),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"q":case"qq":return _t(i.length,r);case"qo":return o.ordinalNumber(r,{unit:"quarter"});case"qqq":return o.quarter(r,{width:"abbreviated",context:"standalone"})||o.quarter(r,{width:"narrow",context:"standalone"});case"qqqqq":return o.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return o.quarter(r,{width:"wide",context:"standalone"})||o.quarter(r,{width:"abbreviated",context:"standalone"})||o.quarter(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,i){return i>=1&&i<=4}},{key:"set",value:function(r,i,o){return r.setUTCMonth((o-1)*3,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),a$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),we(Ce(r),"priority",110),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return a-1};switch(i){case"M":return Pt(xt($t.month,r),s);case"MM":return Pt(_t(2,r),s);case"Mo":return Pt(o.ordinalNumber(r,{unit:"month"}),s);case"MMM":return o.month(r,{width:"abbreviated",context:"formatting"})||o.month(r,{width:"narrow",context:"formatting"});case"MMMMM":return o.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return o.month(r,{width:"wide",context:"formatting"})||o.month(r,{width:"abbreviated",context:"formatting"})||o.month(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=11}},{key:"set",value:function(r,i,o){return r.setUTCMonth(o,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),c$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",110),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return a-1};switch(i){case"L":return Pt(xt($t.month,r),s);case"LL":return Pt(_t(2,r),s);case"Lo":return Pt(o.ordinalNumber(r,{unit:"month"}),s);case"LLL":return o.month(r,{width:"abbreviated",context:"standalone"})||o.month(r,{width:"narrow",context:"standalone"});case"LLLLL":return o.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return o.month(r,{width:"wide",context:"standalone"})||o.month(r,{width:"abbreviated",context:"standalone"})||o.month(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=11}},{key:"set",value:function(r,i,o){return r.setUTCMonth(o,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt);function l$(e,t,n){an(2,arguments);var r=Dn(e),i=pr(t),o=qS(r,n)-i;return r.setUTCDate(r.getUTCDate()-o*7),r}var u$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",100),we(Ce(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"w":return xt($t.week,r);case"wo":return o.ordinalNumber(r,{unit:"week"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=53}},{key:"set",value:function(r,i,o,s){return kr(l$(r,o,s),s)}}]),n}(nt);function d$(e,t){an(2,arguments);var n=Dn(e),r=pr(t),i=YS(n)-r;return n.setUTCDate(n.getUTCDate()-i*7),n}var f$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",100),we(Ce(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"I":return xt($t.week,r);case"Io":return o.ordinalNumber(r,{unit:"week"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=53}},{key:"set",value:function(r,i,o){return ao(d$(r,o))}}]),n}(nt),p$=[31,28,31,30,31,30,31,31,30,31,30,31],h$=[31,29,31,30,31,30,31,31,30,31,30,31],m$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"subPriority",1),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"d":return xt($t.date,r);case"do":return o.ordinalNumber(r,{unit:"date"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){var o=r.getUTCFullYear(),s=_v(o),a=r.getUTCMonth();return s?i>=1&&i<=h$[a]:i>=1&&i<=p$[a]}},{key:"set",value:function(r,i,o){return r.setUTCDate(o),r.setUTCHours(0,0,0,0),r}}]),n}(nt),v$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"subpriority",1),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"D":case"DD":return xt($t.dayOfYear,r);case"Do":return o.ordinalNumber(r,{unit:"date"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){var o=r.getUTCFullYear(),s=_v(o);return s?i>=1&&i<=366:i>=1&&i<=365}},{key:"set",value:function(r,i,o){return r.setUTCMonth(0,o),r.setUTCHours(0,0,0,0),r}}]),n}(nt);function pl(e,t,n){var r,i,o,s,a,c,l,d;an(2,arguments);var f=ks(),h=pr((r=(i=(o=(s=n==null?void 0:n.weekStartsOn)!==null&&s!==void 0?s:n==null||(a=n.locale)===null||a===void 0||(c=a.options)===null||c===void 0?void 0:c.weekStartsOn)!==null&&o!==void 0?o:f.weekStartsOn)!==null&&i!==void 0?i:(l=f.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&r!==void 0?r:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var p=Dn(e),w=pr(t),E=p.getUTCDay(),T=w%7,S=(T+7)%7,m=(S<h?7:0)+w-E;return p.setUTCDate(p.getUTCDate()+m),p}var g$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"E":case"EE":case"EEE":return o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"EEEEE":return o.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"EEEE":default:return o.day(r,{width:"wide",context:"formatting"})||o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=6}},{key:"set",value:function(r,i,o,s){return r=pl(r,o,s),r.setUTCHours(0,0,0,0),r}}]),n}(nt),y$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o,s){var a=function(c){var l=Math.floor((c-1)/7)*7;return(c+s.weekStartsOn+6)%7+l};switch(i){case"e":case"ee":return Pt(_t(i.length,r),a);case"eo":return Pt(o.ordinalNumber(r,{unit:"day"}),a);case"eee":return o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"eeeee":return o.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"eeee":default:return o.day(r,{width:"wide",context:"formatting"})||o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=6}},{key:"set",value:function(r,i,o,s){return r=pl(r,o,s),r.setUTCHours(0,0,0,0),r}}]),n}(nt),b$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o,s){var a=function(c){var l=Math.floor((c-1)/7)*7;return(c+s.weekStartsOn+6)%7+l};switch(i){case"c":case"cc":return Pt(_t(i.length,r),a);case"co":return Pt(o.ordinalNumber(r,{unit:"day"}),a);case"ccc":return o.day(r,{width:"abbreviated",context:"standalone"})||o.day(r,{width:"short",context:"standalone"})||o.day(r,{width:"narrow",context:"standalone"});case"ccccc":return o.day(r,{width:"narrow",context:"standalone"});case"cccccc":return o.day(r,{width:"short",context:"standalone"})||o.day(r,{width:"narrow",context:"standalone"});case"cccc":default:return o.day(r,{width:"wide",context:"standalone"})||o.day(r,{width:"abbreviated",context:"standalone"})||o.day(r,{width:"short",context:"standalone"})||o.day(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=6}},{key:"set",value:function(r,i,o,s){return r=pl(r,o,s),r.setUTCHours(0,0,0,0),r}}]),n}(nt);function w$(e,t){an(2,arguments);var n=pr(t);n%7===0&&(n=n-7);var r=1,i=Dn(e),o=i.getUTCDay(),s=n%7,a=(s+7)%7,c=(a<r?7:0)+n-o;return i.setUTCDate(i.getUTCDate()+c),i}var x$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return a===0?7:a};switch(i){case"i":case"ii":return _t(i.length,r);case"io":return o.ordinalNumber(r,{unit:"day"});case"iii":return Pt(o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"}),s);case"iiiii":return Pt(o.day(r,{width:"narrow",context:"formatting"}),s);case"iiiiii":return Pt(o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"}),s);case"iiii":default:return Pt(o.day(r,{width:"wide",context:"formatting"})||o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(r,i){return i>=1&&i<=7}},{key:"set",value:function(r,i,o){return r=w$(r,o),r.setUTCHours(0,0,0,0),r}}]),n}(nt),E$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",80),we(Ce(r),"incompatibleTokens",["b","B","H","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"a":case"aa":case"aaa":return o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaaa":return o.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return o.dayPeriod(r,{width:"wide",context:"formatting"})||o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,i,o){return r.setUTCHours(fl(o),0,0,0),r}}]),n}(nt),C$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",80),we(Ce(r),"incompatibleTokens",["a","B","H","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"b":case"bb":case"bbb":return o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbbb":return o.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return o.dayPeriod(r,{width:"wide",context:"formatting"})||o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,i,o){return r.setUTCHours(fl(o),0,0,0),r}}]),n}(nt),_$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",80),we(Ce(r),"incompatibleTokens",["a","b","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"B":case"BB":case"BBB":return o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBBB":return o.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return o.dayPeriod(r,{width:"wide",context:"formatting"})||o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,i,o){return r.setUTCHours(fl(o),0,0,0),r}}]),n}(nt),T$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["H","K","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"h":return xt($t.hour12h,r);case"ho":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=12}},{key:"set",value:function(r,i,o){var s=r.getUTCHours()>=12;return s&&o<12?r.setUTCHours(o+12,0,0,0):!s&&o===12?r.setUTCHours(0,0,0,0):r.setUTCHours(o,0,0,0),r}}]),n}(nt),S$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["a","b","h","K","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"H":return xt($t.hour23h,r);case"Ho":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=23}},{key:"set",value:function(r,i,o){return r.setUTCHours(o,0,0,0),r}}]),n}(nt),$$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["h","H","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"K":return xt($t.hour11h,r);case"Ko":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=11}},{key:"set",value:function(r,i,o){var s=r.getUTCHours()>=12;return s&&o<12?r.setUTCHours(o+12,0,0,0):r.setUTCHours(o,0,0,0),r}}]),n}(nt),P$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["a","b","h","H","K","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"k":return xt($t.hour24h,r);case"ko":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=24}},{key:"set",value:function(r,i,o){var s=o<=24?o%24:o;return r.setUTCHours(s,0,0,0),r}}]),n}(nt),R$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",60),we(Ce(r),"incompatibleTokens",["t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"m":return xt($t.minute,r);case"mo":return o.ordinalNumber(r,{unit:"minute"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=59}},{key:"set",value:function(r,i,o){return r.setUTCMinutes(o,0,0),r}}]),n}(nt),I$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",50),we(Ce(r),"incompatibleTokens",["t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"s":return xt($t.second,r);case"so":return o.ordinalNumber(r,{unit:"second"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=59}},{key:"set",value:function(r,i,o){return r.setUTCSeconds(o,0),r}}]),n}(nt),A$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",30),we(Ce(r),"incompatibleTokens",["t","T"]),r}return qe(n,[{key:"parse",value:function(r,i){var o=function(s){return Math.floor(s*Math.pow(10,-i.length+3))};return Pt(_t(i.length,r),o)}},{key:"set",value:function(r,i,o){return r.setUTCMilliseconds(o),r}}]),n}(nt),D$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",10),we(Ce(r),"incompatibleTokens",["t","T","x"]),r}return qe(n,[{key:"parse",value:function(r,i){switch(i){case"X":return Pn($n.basicOptionalMinutes,r);case"XX":return Pn($n.basic,r);case"XXXX":return Pn($n.basicOptionalSeconds,r);case"XXXXX":return Pn($n.extendedOptionalSeconds,r);case"XXX":default:return Pn($n.extended,r)}}},{key:"set",value:function(r,i,o){return i.timestampIsSet?r:new Date(r.getTime()-o)}}]),n}(nt),O$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",10),we(Ce(r),"incompatibleTokens",["t","T","X"]),r}return qe(n,[{key:"parse",value:function(r,i){switch(i){case"x":return Pn($n.basicOptionalMinutes,r);case"xx":return Pn($n.basic,r);case"xxxx":return Pn($n.basicOptionalSeconds,r);case"xxxxx":return Pn($n.extendedOptionalSeconds,r);case"xxx":default:return Pn($n.extended,r)}}},{key:"set",value:function(r,i,o){return i.timestampIsSet?r:new Date(r.getTime()-o)}}]),n}(nt),M$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",40),we(Ce(r),"incompatibleTokens","*"),r}return qe(n,[{key:"parse",value:function(r){return xv(r)}},{key:"set",value:function(r,i,o){return[new Date(o*1e3),{timestampIsSet:!0}]}}]),n}(nt),k$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",20),we(Ce(r),"incompatibleTokens","*"),r}return qe(n,[{key:"parse",value:function(r){return xv(r)}},{key:"set",value:function(r,i,o){return[new Date(o),{timestampIsSet:!0}]}}]),n}(nt);new e$,new t$,new n$,new r$,new o$,new i$,new s$,new a$,new c$,new u$,new f$,new m$,new v$,new g$,new y$,new b$,new x$,new E$,new C$,new _$,new T$,new S$,new $$,new P$,new R$,new I$,new A$,new D$,new O$,new M$,new k$;var N$=ft({defaultClassName:"_920fuu5",variantClassNames:{colorScheme:{primary:"_920fuu6",neutral:"_920fuu7",danger:"_920fuu8",warning:"_920fuu9",info:"_920fuua"},variant:{solid:"_920fuub",outline:"_920fuuc",ghost:"_920fuud"},size:{small:"_920fuue",medium:"_920fuuf",large:"_920fuug"},unstyled:{true:"_920fuuh"},isFluid:{true:"_920fuui"}},defaultVariants:{size:"medium",variant:"solid",colorScheme:"primary"},compoundVariants:[[{colorScheme:"primary",variant:"outline"},"_920fuuj"],[{colorScheme:"neutral",variant:"outline"},"_920fuuk"],[{colorScheme:"danger",variant:"outline"},"_920fuul"],[{colorScheme:"warning",variant:"outline"},"_920fuum"],[{colorScheme:"info",variant:"outline"},"_920fuun"],[{size:"small",variant:"outline"},"_920fuuo"],[{size:"large",variant:"outline"},"_920fuup"]]}),j$={primary:"var(--_1qe00b21g)",neutral:"var(--_1qe00b2c)",danger:"var(--_1qe00b214)",warning:"var(--_1qe00b211)",success:"var(--_1qe00b2v)",info:"var(--_1qe00b2y)"},V$={primary:"_920fuu0",neutral:"_920fuu1",danger:"_920fuu2",warning:"_920fuu3",info:"_920fuu4"},tp={primary:"var(--_1qe00b2a)",neutral:"var(--_1qe00b2c)",danger:"var(--_1qe00b214)",warning:"var(--_1qe00b211)",info:"var(--_1qe00b2y)",white:"var(--_1qe00b2d)"};var L$="p9dczu0";const hl=({ref:e,colorScheme:t="primary"})=>{const[n,r]=u.useState([]),i=jS({value:n,delay:1e3});return u.useEffect(()=>{if(e.current){const o=e.current,s=a=>{const c=o.getBoundingClientRect(),l=a.clientX-c.left,d=a.clientY-c.top,f=o.clientHeight,h=o.clientWidth,p=Math.max(h,f);r([...n,{top:d-p/2,left:l-p/2,height:Math.max(h,f),width:Math.max(h,f),backgroundColor:t==="primary"?Et.theme.colors.primary:j$[t]}])};return o.addEventListener("click",s),()=>{o.removeEventListener("click",s)}}return()=>!1},[e,n]),u.useEffect(()=>{i.length&&r([])},[i.length]),n==null?void 0:n.map((o,s)=>D.jsx("span",{className:L$,style:{...o}},s))},co=u.forwardRef(({as:e,children:t,className:n,colorScheme:r,size:i,isLoading:o,variant:s,style:a,isDisabled:c,isFluid:l,unstyled:d,...f},h)=>{const p=u.useRef(null),w=hl({ref:p,colorScheme:r,variant:s});u.useImperativeHandle(h,()=>p.current);const E=e||"button";return D.jsx(E,{ref:p,as:e,"data-test-id":f["data-test-id"],className:Re(N$({colorScheme:r,size:i,variant:s,isFluid:l,unstyled:d}),s==="ghost"?V$[r||"primary"]:void 0,n),disabled:c,style:a,...f,children:o?D.jsx(mo,{color:s==="outline"||s==="ghost"?tp[r||"primary"]:tp.white}):D.jsxs(D.Fragment,{children:[w,t]})})});co.displayName="Button";co.defaultProps={as:"button","data-test-id":void 0,isDisabled:void 0,isLoading:void 0,isFluid:void 0};const Tv="Checkbox",[F$,bD]=sn(Tv),[B$,H$]=F$(Tv),W$=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:o,required:s,disabled:a,value:c="on",onCheckedChange:l,...d}=e,[f,h]=u.useState(null),p=Qe(t,x=>h(x)),w=u.useRef(!1),E=f?!!f.closest("form"):!0,[T=!1,S]=pn({prop:i,defaultProp:o,onChange:l}),m=u.useRef(T);return u.useEffect(()=>{const x=f==null?void 0:f.form;if(x){const _=()=>S(m.current);return x.addEventListener("reset",_),()=>x.removeEventListener("reset",_)}},[f,S]),u.createElement(B$,{scope:n,state:T,disabled:a},u.createElement(He.button,ie({type:"button",role:"checkbox","aria-checked":Ar(T)?"mixed":T,"aria-required":s,"data-state":Sv(T),"data-disabled":a?"":void 0,disabled:a,value:c},d,{ref:p,onKeyDown:De(e.onKeyDown,x=>{x.key==="Enter"&&x.preventDefault()}),onClick:De(e.onClick,x=>{S(_=>Ar(_)?!0:!_),E&&(w.current=x.isPropagationStopped(),w.current||x.stopPropagation())})})),E&&u.createElement(z$,{control:f,bubbles:!w.current,name:r,value:c,checked:T,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))}),U$="CheckboxIndicator",Y$=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...i}=e,o=H$(U$,n);return u.createElement(hr,{present:r||Ar(o.state)||o.state===!0},u.createElement(He.span,ie({"data-state":Sv(o.state),"data-disabled":o.disabled?"":void 0},i,{ref:t,style:{pointerEvents:"none",...e.style}})))}),z$=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,o=u.useRef(null),s=ms(n),a=ps(t);return u.useEffect(()=>{const c=o.current,l=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(l,"checked").set;if(s!==n&&f){const h=new Event("click",{bubbles:r});c.indeterminate=Ar(n),f.call(c,Ar(n)?!1:n),c.dispatchEvent(h)}},[s,n,r]),u.createElement("input",ie({type:"checkbox","aria-hidden":!0,defaultChecked:Ar(n)?!1:n},i,{tabIndex:-1,ref:o,style:{...e.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ar(e){return e==="indeterminate"}function Sv(e){return Ar(e)?"indeterminate":e?"checked":"unchecked"}const K$=W$,q$=Y$;var X$="glci2q0",np="glci2q3",G$="glci2q4",rp={disabled:"glci2q1",enabled:"glci2q2"},Z$=ft({defaultClassName:"glci2q5",variantClassNames:{checked:{true:"glci2q6",false:"glci2q7",indeterminate:"glci2q8"},disabled:{true:"glci2q9"}},defaultVariants:{checked:!1,disabled:!1},compoundVariants:[[{checked:!1,disabled:!0},"glci2qa"]]});const $v=u.forwardRef(({children:e,"data-test-id":t,checked:n=!1,onCheckedChange:r,disabled:i,value:o,...s},a)=>{const c=`vds-checkbox-${u.useId()}`,[l,d]=u.useState(n);return u.useEffect(()=>{d(n)},[n]),D.jsxs("div",{className:X$,children:[D.jsx(K$,{id:c,disabled:i,"data-test-id":t,ref:a,value:l?"on":"off",checked:l,className:Z$({checked:l,disabled:i}),onCheckedChange:f=>{typeof f=="boolean"&&(r?r(f):d(f))},...s,children:D.jsxs(q$,{className:G$,children:[l==="indeterminate"&&D.jsx(tb,{color:"white",className:np}),l===!0&&D.jsx(_c,{color:"white",className:np})]})}),e&&D.jsx("label",{htmlFor:c,className:i?rp.disabled:rp.enabled,children:e})]})});$v.defaultProps={"data-test-id":"base"};const Q$=e=>u.useMemo(()=>{const n=e.every(Boolean);return e.some(Boolean)&&!n?"indeterminate":!!n},[e]);var J$=ft({defaultClassName:"_5046e70",variantClassNames:{variant:{filled:"_5046e71",outline:"_5046e72"},isActive:{true:"_5046e73"},isFluid:{true:"_5046e74"}},defaultVariants:{variant:"filled",isActive:!1},compoundVariants:[[{isActive:!0,variant:"outline"},"_5046e75"]]}),eP="_5046e76";const ml=u.forwardRef(({as:e,children:t,variant:n,isActive:r,isFilter:i,prefixIcon:o,withCloseButton:s,className:a,disabled:c,style:l,...d},f)=>{const h=e||"button";return D.jsxs(h,{ref:f,as:e,"data-test-id":d["data-test-id"],className:Re(J$({variant:n,isActive:r}),a),disabled:c,style:l,...d,children:[o&&o,i&&!o&&D.jsx(J0,{style:{marginRight:8},size:16,color:"inherit"}),t,s&&D.jsx(ho,{"data-test-id":"chips-close-button",className:eP,isDisabled:c})]})});ml.defaultProps={as:"button",children:void 0,isActive:!1,isFilter:!1,prefixIcon:void 0,withCloseButton:!1,"data-test-id":void 0};ml.displayName="Chips";const Pv="Dialog",[Rv,wD]=sn(Pv),[tP,gr]=Rv(Pv),nP=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:s=!0}=e,a=u.useRef(null),c=u.useRef(null),[l=!1,d]=pn({prop:r,defaultProp:i,onChange:o});return u.createElement(tP,{scope:t,triggerRef:a,contentRef:c,contentId:Bn(),titleId:Bn(),descriptionId:Bn(),open:l,onOpenChange:d,onOpenToggle:u.useCallback(()=>d(f=>!f),[d]),modal:s},n)},rP="DialogTrigger",oP=u.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=gr(rP,n),o=Qe(t,i.triggerRef);return u.createElement(He.button,ie({type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":vl(i.open)},r,{ref:o,onClick:De(e.onClick,i.onOpenToggle)}))}),iP="DialogPortal",[xD,Iv]=Rv(iP,{forceMount:void 0}),cc="DialogOverlay",sP=u.forwardRef((e,t)=>{const n=Iv(cc,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=gr(cc,e.__scopeDialog);return o.modal?u.createElement(hr,{present:r||o.open},u.createElement(aP,ie({},i,{ref:t}))):null}),aP=u.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=gr(cc,n);return u.createElement(Ph,{as:no,allowPinchZoom:!0,shards:[i.contentRef]},u.createElement(He.div,ie({"data-state":vl(i.open)},r,{ref:t,style:{pointerEvents:"auto",...r.style}})))}),Uo="DialogContent",cP=u.forwardRef((e,t)=>{const n=Iv(Uo,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=gr(Uo,e.__scopeDialog);return u.createElement(hr,{present:r||o.open},o.modal?u.createElement(lP,ie({},i,{ref:t})):u.createElement(uP,ie({},i,{ref:t})))}),lP=u.forwardRef((e,t)=>{const n=gr(Uo,e.__scopeDialog),r=u.useRef(null),i=Qe(t,n.contentRef,r);return u.useEffect(()=>{const o=r.current;if(o)return bh(o)},[]),u.createElement(Av,ie({},e,{ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:De(e.onCloseAutoFocus,o=>{var s;o.preventDefault(),(s=n.triggerRef.current)===null||s===void 0||s.focus()}),onPointerDownOutside:De(e.onPointerDownOutside,o=>{const s=o.detail.originalEvent,a=s.button===0&&s.ctrlKey===!0;(s.button===2||a)&&o.preventDefault()}),onFocusOutside:De(e.onFocusOutside,o=>o.preventDefault())}))}),uP=u.forwardRef((e,t)=>{const n=gr(Uo,e.__scopeDialog),r=u.useRef(!1),i=u.useRef(!1);return u.createElement(Av,ie({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var s;if((s=e.onCloseAutoFocus)===null||s===void 0||s.call(e,o),!o.defaultPrevented){var a;r.current||(a=n.triggerRef.current)===null||a===void 0||a.focus(),o.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:o=>{var s,a;(s=e.onInteractOutside)===null||s===void 0||s.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const c=o.target;((a=n.triggerRef.current)===null||a===void 0?void 0:a.contains(c))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}}))}),Av=u.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,...s}=e,a=gr(Uo,n),c=u.useRef(null),l=Qe(t,c);return Zp(),u.createElement(u.Fragment,null,u.createElement(Qp,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o},u.createElement(us,ie({role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":vl(a.open)},s,{ref:l,onDismiss:()=>a.onOpenChange(!1)}))),!1)}),dP="DialogClose",fP=u.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=gr(dP,n);return u.createElement(He.button,ie({type:"button"},r,{ref:t,onClick:De(e.onClick,()=>i.onOpenChange(!1))}))});function vl(e){return e?"open":"closed"}const pP=nP,hP=oP,mP=sP,vP=cP,gP=fP;var yP="_1jc0z8o4",bP="_1jc0z8o0",wP=ft({defaultClassName:"_1jc0z8o7",variantClassNames:{size:{full:"_1jc0z8o8",small:"_1jc0z8o9",medium:"_1jc0z8oa",large:"_1jc0z8ob"},noPadding:{true:"_1jc0z8oc"},colorScheme:{primary:"_1jc0z8od",neutral:"_1jc0z8oe",danger:"_1jc0z8of",warning:"_1jc0z8og",info:"_1jc0z8oh",white:"_1jc0z8oi"}},defaultVariants:{size:"medium",noPadding:!1,colorScheme:"white"},compoundVariants:[]}),xP="_1jc0z8o1",EP=ft({defaultClassName:"_1jc0z8o2",variantClassNames:{bold:{true:"_1jc0z8o3"}},defaultVariants:{bold:!1},compoundVariants:[]}),CP=ft({defaultClassName:"_1jc0z8o6",variantClassNames:{},defaultVariants:{},compoundVariants:[]});const _P=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(vP,{className:t,ref:r,...n,children:e})),TP=u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(mP,{className:t,ref:r,...n,children:e})),SP=({children:e,className:t,...n})=>D.jsx(xs,{className:t,...n,children:e}),$P=({children:e,...t})=>D.jsx(pP,{...t,children:e});u.forwardRef(({children:e,className:t,...n},r)=>D.jsx(hP,{className:t,...n,ref:r,children:e}));const ei=u.forwardRef(({children:e,"data-test-id":t,isOpen:n,onClose:r,size:i,destroyOnClose:o,noPadding:s,colorScheme:a,closeOnOverlayClick:c,closeIcon:l,classNameBody:d,...f},h)=>!n&&o?null:D.jsx($P,{open:n,onOpenChange:r,children:D.jsxs(SP,{children:[D.jsx(TP,{className:Re(CP())}),D.jsxs(_P,{onInteractOutside:p=>!c&&p.preventDefault(),className:Re(wP({colorScheme:a,size:i,noPadding:s}),d),...f,ref:h,children:[r&&!l&&D.jsx(gP,{asChild:!0,"aria-label":"Close",children:D.jsx(ho,{className:yP,"data-test-id":"close-modal"})}),r&&l&&l,e]})]})}));ei.displayName="Modal";ei.defaultProps={children:void 0,"data-test-id":void 0,size:"medium",onClose:void 0,destroyOnClose:!1,noPadding:!1,colorScheme:"white",closeOnOverlayClick:!0,closeIcon:void 0,classNameBody:void 0};const Ns=u.forwardRef(({as:e,children:t,"data-test-id":n,...r},i)=>{const o=e||"div";return D.jsx(o,{"data-test-id":n,as:e,ref:i,className:bP,...r,children:t})});Ns.displayName="modalBody";Ns.defaultProps={as:"div",children:void 0,"data-test-id":void 0};const js=u.forwardRef(({as:e,children:t,"data-test-id":n,...r},i)=>{const o=e||"div";return D.jsx(o,{"data-test-id":n,as:e,className:xP,ref:i,...r,children:t})});js.displayName="modalFooter";js.defaultProps={as:"div",children:void 0,"data-test-id":void 0};const ti=u.forwardRef(({as:e,bold:t,children:n,"data-test-id":r,...i},o)=>{const s=e||"div";return D.jsx(s,{"data-test-id":r,as:e,ref:o,className:EP({bold:t}),...i,children:D.jsx(Kt,{textStyle:"subtitle1",fontWeight:"$bold",paddingRight:"$16",margin:"$0",children:n})})});ti.displayName="modalHeader";ti.defaultProps={as:"div",bold:!1,children:void 0,"data-test-id":void 0};const gl=({isOpen:e,onConfirm:t,onCancel:n,message:r,title:i,confirmTestId:o,isLoading:s,confirmText:a="Confirm",cancelText:c="Cancel",closeOnOverlayClick:l,size:d,classNameBody:f})=>D.jsxs(ei,{classNameBody:f,size:d,isOpen:e,closeOnOverlayClick:l,onClose:n,closeIcon:D.jsx(ht,{display:"none"}),children:[D.jsx(ti,{children:i}),D.jsx(Ns,{children:D.jsx(Kt,{mt:"$8",mb:"$24",textStyle:"body2",children:r})}),D.jsx(js,{children:D.jsxs(Lt,{gap:"$16",justifyContent:"flex-end",children:[D.jsx(co,{"data-test-id":"CT_Close_Confirm",onClick:n,variant:"outline",children:c}),D.jsx(co,{"data-test-id":o,onClick:t,isLoading:s,children:a})]})})]});gl.defaultProps={message:void 0,cancelText:void 0,confirmText:void 0,confirmTestId:void 0,isLoading:void 0,closeOnOverlayClick:!0,size:"small",classNameBody:void 0};const yl=u.createContext({}),PP=({children:e})=>{const[t,n]=u.useState(!1),[r,i]=u.useState(void 0),o=()=>{n(!1),i(void 0)},s=()=>{o(),r!=null&&r.actionCallback(!0)},a=()=>{o(),r!=null&&r.actionCallback(!1)},c=u.useMemo(()=>({openDialog:({title:d,message:f,confirmText:h,cancelText:p,actionCallback:w,confirmTestId:E,size:T,isLoading:S,closeOnOverlayClick:m,classNameBody:x})=>{n(!0),i({title:d,message:f,confirmText:h,cancelText:p,confirmTestId:E,size:T,isLoading:S,actionCallback:w,closeOnOverlayClick:m,classNameBody:x})}}),[n,i]);return D.jsxs(yl.Provider,{value:c,children:[D.jsx(gl,{title:(r==null?void 0:r.title)??"",message:(r==null?void 0:r.message)??"",confirmText:r==null?void 0:r.confirmText,cancelText:r==null?void 0:r.cancelText,isOpen:t,confirmTestId:r==null?void 0:r.confirmTestId,isLoading:r==null?void 0:r.isLoading,onConfirm:s,onCancel:a,size:r==null?void 0:r.size,closeOnOverlayClick:r==null?void 0:r.closeOnOverlayClick}),e]})},RP=()=>{const{openDialog:e}=u.useContext(yl);return{confirm:async({...n})=>await new Promise(r=>{e({actionCallback:r,...n})})}},bl=({children:e,isDisabled:t,className:n})=>D.jsx("div",{className:Re(Zx({isDisabled:t}),n),children:e});bl.displayName="ActionIcon";bl.defaultProps={isDisabled:!1,className:void 0};const ni=u.forwardRef(({isError:e,isDisabled:t,required:n,isTextarea:r,children:i},o)=>D.jsxs("label",{ref:o,className:i1({state:kc({isError:e,isDisabled:t}),isTextarea:r}),children:[i,n&&"*"]}));ni.displayName="Label";ni.defaultProps={isTextarea:!1};const wl=u.forwardRef(({value:e,type:t,label:n,onClear:r,onBlur:i,isLoading:o,icon:s,isClearable:a=!0,required:c,containerStyles:l,...d},f)=>{const{addonLeft:h,addonRight:p,helperTextLeft:w,helperTextRight:E,isError:T,errorMessage:S,isDisabled:m,isValid:x,elementLeft:_,elementRight:$,className:O,...M}=d,N=!!s,j=u.useRef(null);u.useImperativeHandle(f,()=>j.current);const[K,V]=u.useState(!1),[P,v]=u.useState(!1),C=k=>{if(K){const U=j.current;U&&U.focus(),P&&(V(!1),v(!1))}else i==null||i(k)},I=()=>{const k=j.current;k&&k.focus(),P&&(V(!1),v(!1))};return u.useEffect(()=>{P&&V(!0)},[P]),D.jsxs(po,{addonLeft:h,addonRight:p,elementLeft:_,elementRight:$,helperTextLeft:w,helperTextRight:E,isError:T,errorMessage:S,isDisabled:m,isValid:x,className:l,inputAreaClassName:n1,children:[D.jsx("input",{ref:j,type:t,className:Re(t1,O),value:e,disabled:m,"data-test-id":d["data-test-id"],required:c,onBlur:C,...M}),D.jsx(ni,{isError:T,isDisabled:m,required:c,children:n}),D.jsx("div",{className:Re(r1),"data-test-id":"icon-input-area",onMouseEnter:()=>V(!0),onMouseLeave:()=>V(!1),onTouchStart:()=>v(!0),onClick:I,"aria-hidden":"true",children:D.jsxs(bl,{isDisabled:m,className:Re(a&&!o&&!N&&e1),children:[N&&!o&&s,a&&!o&&!N&&D.jsx(ls,{"data-test-id":`clear-input-${d["data-test-id"]}`,onClick:r}),o&&D.jsx(mo,{color:Et.theme.colors.green1})]})})]})});wl.displayName="Input";wl.defaultProps={type:"text",isLoading:!1,icon:void 0,onClear:void 0,isClearable:!0,containerStyles:void 0,"data-test-id":void 0};const xl=u.forwardRef(({value:e,label:t,rows:n=4,required:r,containerStyles:i,...o},s)=>{const{helperTextLeft:a,helperTextRight:c,isError:l,errorMessage:d,isDisabled:f,isValid:h,...p}=o;return D.jsxs(po,{helperTextLeft:a,helperTextRight:c,isError:l,errorMessage:d,isDisabled:f,isValid:h,className:i,children:[D.jsx("textarea",{ref:s,className:Re(s1),value:e,rows:n,disabled:f,"data-test-id":o["data-test-id"],required:r,...p}),D.jsx(ni,{isTextarea:!0,isError:l,isDisabled:f,required:r,children:t})]})});xl.displayName="Textarea";xl.defaultProps={containerStyles:void 0,"data-test-id":void 0};var IP=ft({defaultClassName:"_1n7m27n0",variantClassNames:{colorScheme:{primary:"_1n7m27n1",neutral:"_1n7m27n2",danger:"_1n7m27n3",warning:"_1n7m27n4",info:"_1n7m27n5"},variant:{solid:"_1n7m27n6",outline:"_1n7m27n7"},unstyled:{true:"_1n7m27n8"}},defaultVariants:{variant:"solid",colorScheme:"primary"},compoundVariants:[[{colorScheme:"primary",variant:"outline"},"_1n7m27n9"],[{colorScheme:"neutral",variant:"outline"},"_1n7m27na"],[{colorScheme:"danger",variant:"outline"},"_1n7m27nb"],[{colorScheme:"warning",variant:"outline"},"_1n7m27nc"],[{colorScheme:"info",variant:"outline"},"_1n7m27nd"]]}),op={primary:"var(--_1qe00b2a)",neutral:"var(--_1qe00b2c)",danger:"var(--_1qe00b214)",warning:"var(--_1qe00b211)",info:"var(--_1qe00b2y)",white:"var(--_1qe00b2d)"};const El=u.forwardRef(({as:e,className:t,style:n,colorScheme:r,icon:i,unstyled:o,variant:s,isDisabled:a,isLoading:c,...l},d)=>{const f=u.useRef(null),h=hl({ref:f,colorScheme:r,variant:s});u.useImperativeHandle(d,()=>f.current);const p=e||"button";return D.jsx(p,{ref:f,as:e,"data-test-id":l["data-test-id"],className:Re(IP({colorScheme:r,unstyled:o,variant:s}),t),disabled:a,style:n,...l,children:c?D.jsx(mo,{color:s==="outline"?op[r||"primary"]:op.white}):D.jsxs(D.Fragment,{children:[h,i]})})});El.displayName="Button";El.defaultProps={as:"button","data-test-id":void 0,isDisabled:void 0,isLoading:void 0};var AP=ft({defaultClassName:"",variantClassNames:{fit:{fill:"_19yf4wk0",contain:"_19yf4wk1",cover:"_19yf4wk2","scale-down":"_19yf4wk3",none:"_19yf4wk4"}},defaultVariants:{fit:"fill"},compoundVariants:[]});const DP=({width:e=140,height:t=140,viewBox:n="0 0 140 140",...r})=>D.jsx("svg",{"data-test-id":"illustration-fallback-image",width:e,height:t,viewBox:n,fill:"none",...r,children:D.jsx("path",{d:"M85.604 0H0V140H130V43.7197L85.604 0ZM119.088 129.24H10.9305V93.2855L23.0998 101.606L48.3128 71.9816L70.6656 103.991L83.7094 86.5608L106.062 92.0123L87.2618 70.7801L71.7769 89.1789L50.5353 52.3812L22.8812 79.3877L10.9305 68.1798V10.7596H80.9767V48.0594H118.96L119.07 48.167V129.24H119.088Z",fill:"#EEEEEE"})}),Cl=u.forwardRef(({as:e,src:t,fit:n,width:r,height:i,loading:o,isLoading:s,fallback:a,onLoad:c,onError:l,className:d,"data-test-id":f,...h},p)=>{const w=e||"img",E=u.useMemo(()=>`${parseInt(`${r??0}`,10)}px`,[r]),T=u.useMemo(()=>`${parseInt(`${i??0}`,10)}px`,[i]),[S,m]=u.useState(!1),[x,_]=u.useState(n),$=M=>{_("fill"),m(!0),l==null||l(M)},O=M=>{m(!1),c==null||c(M)};return s&&!S?D.jsx(ht,{bgColor:"$grey2",width:E,height:T}):S?a||D.jsx(DP,{width:E,height:T}):D.jsx(w,{"data-test-id":f,as:"img",width:E,height:T,src:t,loading:o,onLoad:O,onError:$,ref:p,className:Re(AP({fit:x})),...h})});Cl.displayName="Image";Cl.defaultProps={as:"img","data-test-id":void 0,fallback:void 0,width:void 0,height:void 0,loading:void 0,isLoading:void 0,onLoad:void 0,onError:void 0,fit:void 0};var OP=ft({defaultClassName:"_5y0pl50",variantClassNames:{textStyle:{heading1:"_5y0pl51",heading2:"_5y0pl52",heading3:"_5y0pl53",heading4:"_5y0pl54",heading5:"_5y0pl55",heading6:"_5y0pl56",subtitle1:"_5y0pl57",subtitle2:"_5y0pl58",body1:"_5y0pl59",body2:"_5y0pl5a",caption:"_5y0pl5b",footer:"_5y0pl5c"},isDisabled:{true:"_5y0pl5d"},variant:{default:"_5y0pl5e",underline:"_5y0pl5f"},isBold:{true:"_5y0pl5g"}},defaultVariants:{variant:"default",isDisabled:!1,isBold:!1,textStyle:"body1"},compoundVariants:[]});const Dv=({children:e,className:t,variant:n,textStyle:r="body2",isDisabled:i,isBold:o,...s})=>D.jsx("a",{className:Re(t,OP({isDisabled:i,variant:n,textStyle:r,isBold:o})),"data-disabled":i,...s,children:e});var MP="_1cq2k9i0";const _l=u.forwardRef(({children:e,as:t,className:n,...r},i)=>{const o=t||"ul";return D.jsx(o,{"data-test-id":r["data-test-id"],ref:i,className:Re(MP,n),...r,children:e})});_l.displayName="List";_l.defaultProps={"data-test-id":void 0,as:"ul"};var kP=ft({defaultClassName:"xw6nfa0",variantClassNames:{hasLink:{false:"xw6nfa1"}},defaultVariants:{hasLink:!1},compoundVariants:[]}),ip="xw6nfa2",NP="xw6nfa3";const Tl=u.forwardRef(({children:e,leftIcon:t,rightIcon:n,href:r,target:i,as:o,className:s,...a},c)=>{const l=o||"li",d=!!r;return D.jsx(l,{"data-test-id":a["data-test-id"],className:Re(kP({hasLink:d}),s),...a,ref:c,children:r?D.jsxs("a",{href:r,target:i,className:NP,children:[t,D.jsx("div",{className:ip,children:e}),n]}):D.jsxs(D.Fragment,{children:[t,D.jsx("div",{className:ip,children:e}),n]})})});Tl.displayName="ListItem";Tl.defaultProps={"data-test-id":void 0,leftIcon:void 0,rightIcon:void 0,href:void 0,target:"_self",as:"li"};var Ov={},Mv={exports:{}};(function(e,t){(function(r,i){e.exports=i()})(yy,()=>(()=>{var n=[,(s,a,c)=>{c.r(a),c.d(a,{default:()=>d});var l=(()=>{var f=typeof document<"u"&&document.currentScript?document.currentScript.src:void 0;return function(h={}){var p=h,w,E;p.ready=new Promise((b,g)=>{w=b,E=g});function T(){function b(ce){const se=A;R=g=0,A=new Map,se.forEach(de=>{try{de(ce)}catch(le){console.error(le)}}),this.Qa(),Y&&Y.nb()}let g=0,R=0,A=new Map,Y=null,re=null;this.requestAnimationFrame=function(ce){g||(g=requestAnimationFrame(b.bind(this)));const se=++R;return A.set(se,ce),se},this.cancelAnimationFrame=function(ce){A.delete(ce),g&&A.size==0&&(cancelAnimationFrame(g),g=0)},this.lb=function(ce){re&&(document.body.remove(re),re=null),ce||(re=document.createElement("div"),re.style.backgroundColor="black",re.style.position="fixed",re.style.right=0,re.style.top=0,re.style.color="white",re.style.padding="4px",re.innerHTML="RIVE FPS",ce=function(se){re.innerHTML="RIVE FPS "+se.toFixed(1)},document.body.appendChild(re)),Y=new function(){let se=0,de=0;this.nb=function(){var le=performance.now();de?(++se,le-=de,1e3<le&&(ce(1e3*se/le),se=de=0)):(de=le,se=0)}}},this.ib=function(){re&&(document.body.remove(re),re=null),Y=null},this.Qa=function(){}}function S(b){console.assert(!0);const g=new Map;let R=-1/0;this.push=function(A){return A=A+((1<<b)-1)>>b,g.has(A)&&clearTimeout(g.get(A)),g.set(A,setTimeout(function(){g.delete(A),g.length==0?R=-1/0:A==R&&(R=Math.max(...g.keys()),console.assert(R<A))},1e3)),R=Math.max(A,R),R<<b}}const m=new function(){function b(){if(!g){let pt=function(Tt,Ve,Be){if(Ve=ve.createShader(Ve),ve.shaderSource(Ve,Be),ve.compileShader(Ve),Be=ve.getShaderInfoLog(Ve),0<Be.length)throw Be;ve.attachShader(Tt,Ve)};var _e=document.createElement("canvas"),ke={alpha:1,depth:0,stencil:0,antialias:0,premultipliedAlpha:1,preserveDrawingBuffer:0,preferLowPowerToHighPerformance:0,failIfMajorPerformanceCaveat:0,enableExtensionsByDefault:1,explicitSwapControl:1,renderViaOffscreenBackBuffer:1};let ve=_e.getContext("webgl2",ke);if(ve)R=2;else if(ve=_e.getContext("webgl",ke))R=1;else return console.log("No WebGL support. Image mesh will not be drawn."),!1;if(A=Math.min(ve.getParameter(ve.MAX_RENDERBUFFER_SIZE),ve.getParameter(ve.MAX_TEXTURE_SIZE)),_e=ve.createProgram(),pt(_e,ve.VERTEX_SHADER,`attribute vec2 vertex;
|
|
120
|
+
`),()=>{document.head.removeChild(l)}},[t]),he.createElement(TT,{isPresent:t,childRef:r,sizeRef:i},he.cloneElement(e,{ref:r}))}const Ea=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:o,mode:s})=>{const a=Rs($T),c=u.useId(),l=u.useMemo(()=>({id:c,initial:t,isPresent:n,custom:i,onExitComplete:d=>{a.set(d,!0);for(const f of a.values())if(!f)return;r&&r()},register:d=>(a.set(d,!1),()=>a.delete(d))}),o?void 0:[n]);return u.useMemo(()=>{a.forEach((d,f)=>a.set(f,!1))},[n]),he.useEffect(()=>{!n&&!a.size&&r&&r()},[n]),s==="popLayout"&&(e=he.createElement(ST,{isPresent:n},e)),he.createElement(Cs.Provider,{value:l},e)};function $T(){return new Map}function PT(e){return u.useEffect(()=>()=>e(),[])}const qr=e=>e.key||"";function RT(e,t){e.forEach(n=>{const r=qr(n);t.set(r,n)})}function IT(e){const t=[];return u.Children.forEach(e,n=>{u.isValidElement(n)&&t.push(n)}),t}const AT=({children:e,custom:t,initial:n=!0,onExitComplete:r,exitBeforeEnter:i,presenceAffectsLayout:o=!0,mode:s="sync"})=>{rn(!i,"Replace exitBeforeEnter with mode='wait'");const a=u.useContext(Wc).forceRender||_T()[0],c=cv(),l=IT(e);let d=l;const f=u.useRef(new Map).current,h=u.useRef(d),p=u.useRef(new Map).current,y=u.useRef(!0);if(Ts(()=>{y.current=!1,RT(l,p),h.current=d}),PT(()=>{y.current=!0,p.clear(),f.clear()}),y.current)return he.createElement(he.Fragment,null,d.map(m=>he.createElement(Ea,{key:qr(m),isPresent:!0,initial:n?void 0:!1,presenceAffectsLayout:o,mode:s},m)));d=[...d];const E=h.current.map(qr),T=l.map(qr),S=E.length;for(let m=0;m<S;m++){const x=E[m];T.indexOf(x)===-1&&!f.has(x)&&f.set(x,void 0)}return s==="wait"&&f.size&&(d=[]),f.forEach((m,x)=>{if(T.indexOf(x)!==-1)return;const _=p.get(x);if(!_)return;const $=E.indexOf(x);let M=m;if(!M){const D=()=>{p.delete(x),f.delete(x);const N=h.current.findIndex(j=>j.key===x);if(h.current.splice(N,1),!f.size){if(h.current=l,c.current===!1)return;a(),r&&r()}};M=he.createElement(Ea,{key:qr(_),isPresent:!1,onExitComplete:D,custom:t,presenceAffectsLayout:o,mode:s},_),f.set(x,M)}d.splice($,0,M)}),d=d.map(m=>{const x=m.key;return f.has(x)?m:he.createElement(Ea,{key:qr(m),isPresent:!0,presenceAffectsLayout:o,mode:s},m)}),process.env.NODE_ENV!=="production"&&s==="wait"&&d.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`),he.createElement(he.Fragment,null,f.size?d:d.map(m=>u.cloneElement(m)))};function ic(e){const t=Rs(()=>Or(e)),{isStatic:n}=u.useContext(Fc);if(n){const[,r]=u.useState(e);u.useEffect(()=>t.on("change",r),[])}return t}const DT=e=>typeof e=="object"&&e.mix,OT=e=>DT(e)?e.mix:void 0;function MT(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],o=e[2+n],s=e[3+n],a=tl(i,o,{mixer:OT(o[0]),...s});return t?a(r):a}function lv(e,t){const n=ic(t()),r=()=>n.set(t());return r(),Ts(()=>{const i=()=>dt.update(r,!1,!0),o=e.map(s=>s.on("change",i));return()=>{o.forEach(s=>s()),yn(r)}}),n}function kT(e){Ao.current=[],e();const t=lv(Ao.current,e);return Ao.current=void 0,t}function Zi(e,t,n,r){if(typeof e=="function")return kT(e);const i=typeof t=="function"?t:MT(t,n,r);return Array.isArray(e)?Nf(e,i):Nf([e],([o])=>i(o))}function Nf(e,t){const n=Rs(()=>[]);return lv(e,()=>{n.length=0;const r=e.length;for(let i=0;i<r;i++)n[i]=e[i].get();return t(n)})}function uv(e,t,n){var r;if(typeof e=="string"){let i=document;t&&(rn(!!t.current,"Scope provided, but no element detected."),i=t.current),n?((r=n[e])!==null&&r!==void 0||(n[e]=i.querySelectorAll(e)),e=n[e]):e=i.querySelectorAll(e)}else e instanceof Element&&(e=[e]);return Array.from(e||[])}function NT(){!ll.current&&rv();const[e]=u.useState(Gi.current);return process.env.NODE_ENV!=="production"&&Os(e!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),e}function jT(e,t){let n;const r=()=>{const{currentTime:i}=t,s=(i===null?0:i.value)/100;n!==s&&e(s),n=s};return dt.update(r,!0),()=>yn(r)}const VT=Mm(()=>window.ScrollTimeline!==void 0);class dv{constructor(t){this.animations=t.filter(Boolean)}then(t,n){return Promise.all(this.animations).then(t).catch(n)}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=n}attachTimeline(t){const n=this.animations.map(r=>{if(VT()&&r.attachTimeline)r.attachTimeline(t);else return r.pause(),jT(i=>{r.time=r.duration*i},t)});return()=>{n.forEach((r,i)=>{r&&r(),this.animations[i].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get duration(){let t=0;for(let n=0;n<this.animations.length;n++)t=Math.max(t,this.animations[n].duration);return t}runAll(t){this.animations.forEach(n=>n[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}stop(){this.runAll("stop")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}function LT(e){return typeof e=="object"&&!Array.isArray(e)}function FT(e){const t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=Qm(e)?new av(t,{enableHardwareAcceleration:!1}):new sv(t,{enableHardwareAcceleration:!0});n.mount(e),Wo.set(e,n)}function BT(e,t=100){const n=nl({keyframes:[0,t],...e}),r=Math.min(Ga(n),Xa);return{type:"keyframes",ease:i=>n.next(r*i).value/t,duration:In(r)}}function jf(e,t,n,r){var i;return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?n:(i=r.get(t))!==null&&i!==void 0?i:e}const HT=(e,t,n)=>{const r=t-e;return((n-e)%r+r)%r+e};function WT(e,t){return hm(e)?e[HT(0,e.length,t)]:e}function UT(e,t,n){for(let r=0;r<e.length;r++){const i=e[r];i.at>t&&i.at<n&&(Ds(e,i),r--)}}function YT(e,t,n,r,i,o){UT(e,i,o);for(let s=0;s<t.length;s++)e.push({value:t[s],at:yt(i,o,r[s]),easing:WT(n,s)})}function zT(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}const KT="easeInOut";function qT(e,{defaultTransition:t={},...n}={},r){const i=t.duration||.3,o=new Map,s=new Map,a={},c=new Map;let l=0,d=0,f=0;for(let h=0;h<e.length;h++){const p=e[h];if(typeof p=="string"){c.set(p,d);continue}else if(!Array.isArray(p)){c.set(p.name,jf(d,p.at,l,c));continue}let[y,E,T={}]=p;T.at!==void 0&&(d=jf(d,T.at,l,c));let S=0;const m=(x,_,$,M=0,D=0)=>{const N=XT(x),{delay:j=0,times:K=Am(N),type:V="keyframes",...P}=_;let{ease:v=t.ease||"easeOut",duration:C}=_;const I=typeof j=="function"?j(M,D):j,k=N.length;if(k<=2&&V==="spring"){let W=100;if(k===2&&QT(N)){const X=N[1]-N[0];W=Math.abs(X)}const L={...P};C!==void 0&&(L.duration=Wn(C));const oe=BT(L,W);v=oe.ease,C=oe.duration}C??(C=i);const U=d+I,G=U+C;K.length===1&&K[0]===0&&(K[1]=1);const ue=K.length-N.length;ue>0&&Im(K,ue),N.length===1&&N.unshift(null),YT($,N,v,K,U,G),S=Math.max(I+C,S),f=Math.max(G,f)};if(Ut(y)){const x=Vf(y,s);m(E,T,Lf("default",x))}else{const x=uv(y,r,a),_=x.length;for(let $=0;$<_;$++){E=E,T=T;const M=x[$],D=Vf(M,s);for(const N in E)m(E[N],GT(T,N),Lf(N,D),$,_)}l=d,d+=S}}return s.forEach((h,p)=>{for(const y in h){const E=h[y];E.sort(zT);const T=[],S=[],m=[];for(let _=0;_<E.length;_++){const{at:$,value:M,easing:D}=E[_];T.push(M),S.push(io(0,f,$)),m.push(D||"easeOut")}S[0]!==0&&(S.unshift(0),T.unshift(T[0]),m.unshift(KT)),S[S.length-1]!==1&&(S.push(1),T.push(null)),o.has(p)||o.set(p,{keyframes:{},transition:{}});const x=o.get(p);x.keyframes[y]=T,x.transition[y]={...t,duration:f,ease:m,times:S,...n}}}),o}function Vf(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function Lf(e,t){return t[e]||(t[e]=[]),t[e]}function XT(e){return Array.isArray(e)?e:[e]}function GT(e,t){return e[t]?{...e,...e[t]}:{...e}}const ZT=e=>typeof e=="number",QT=e=>e.every(ZT);function fv(e,t,n,r){const i=uv(e,r),o=i.length;rn(!!o,"No valid element provided.");const s=[];for(let a=0;a<o;a++){const c=i[a];Wo.has(c)||FT(c);const l=Wo.get(c),d={...n};typeof d.delay=="function"&&(d.delay=d.delay(a,o)),s.push(...al(l,{...t,transition:d},{}))}return new dv(s)}const JT=e=>Array.isArray(e)&&Array.isArray(e[0]);function eS(e,t,n){const r=[];return qT(e,t,n).forEach(({keyframes:o,transition:s},a)=>{let c;Ut(a)?c=cl(a,o.default,s.default):c=fv(a,o,s),r.push(c)}),new dv(r)}const tS=e=>{function t(n,r,i){let o;return JT(n)?o=eS(n,r,e):LT(r)?o=fv(n,r,i,e):o=cl(n,r,i),e&&e.animations.push(o),o}return t},Ff=tS();var nS="dyt3ib1",rS="dyt3ib2",oS="dyt3ib6",iS="dyt3ib4",sS="dyt3ib3",Bf="dyt3ib5",aS="dyt3ib7",cS="dyt3ib0";const Hf=e=>!!e.onClick||!!e.onTap,lS=he.forwardRef(({style:e={},className:t="",...n},r)=>{const i=Hf(n)?ar.button:ar.div,o=Hf(n)?"auto":"none";return O.jsx(i,{...n,ref:r,className:Re(t,nS),style:{...e,pointerEvents:o},initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}})}),pv=he.createContext(void 0),Ms=()=>{const e=he.useContext(pv);if(!e)throw Error("Sheet context error");return e},hv=he.createContext(void 0);function Wf({children:e}){const t=Ms(),[n,r]=he.useState(!!t.disableDrag);function i(){t.disableDrag||r(!1)}function o(){n||r(!0)}return O.jsx(hv.Provider,{value:{disableDrag:n,setDragEnabled:i,setDragDisabled:o},children:e})}const mv=()=>{const e=he.useContext(hv);if(!e)throw Error("Sheet scroller context error");return e},Uf="90%",vv=typeof window>"u",uS={ease:"easeOut",duration:.2},dS={ease:"linear",duration:.01},fS=.6,pS=500;function Yf(e,t){let n=e[0],r=Math.abs(e[0]-t);for(let i=1;i<e.length;i+=1){const o=Math.abs(e[i]-t);o<r&&(n=e[i],r=o)}return n}function hS(e){const t=document.querySelector("body"),n=document.querySelector(`#${e}`);if(n){const i=window.innerHeight,o=(i-24)/i;t.style.backgroundColor="#000",n.style.overflow="hidden",n.style.willChange="transform",n.style.transition="transform 200ms ease-in-out, border-radius 200ms linear",n.style.transform=`translateY(calc(env(safe-area-inset-top) + ${24/2}px)) scale(${o})`,n.style.borderTopRightRadius="10px",n.style.borderTopLeftRadius="10px"}}function zf(e){const t=document.querySelector("body"),n=document.getElementById(e);function r(){n.style.removeProperty("overflow"),n.style.removeProperty("will-change"),n.style.removeProperty("transition"),t.style.removeProperty("background-color"),n.removeEventListener("transitionend",r)}n&&(n.style.removeProperty("border-top-right-radius"),n.style.removeProperty("border-top-left-radius"),n.style.removeProperty("transform"),n.addEventListener("transitionend",r))}function mS(e){for(let t=0;t<e.length;t+=1)if(e[t+1]>e[t])return!1;return!0}function Kf({snapTo:e,sheetHeight:t}){return e<0&&console.warn(`Snap point is out of bounds. Sheet height is ${t} but snap point is ${t+Math.abs(e)}.`),Math.max(Math.round(e),0)}function vS(e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n&&(n.current=t)})}}function gS(){return typeof window>"u"?!1:"ontouchstart"in window||navigator.maxTouchPoints>0}const ul=vv?he.useEffect:he.useLayoutEffect;function yS(e,t){const n=gv(e);he.useEffect(()=>{t&&!n&&e?hS(t):t&&!e&&n&&zf(t)},[e,n]),he.useEffect(()=>()=>{t&&e&&zf(t)},[e])}function bS(e,t){const n=gv(e),r=he.useRef(!1),i=he.useCallback(()=>{var o,s,a,c;r.current?((c=(a=t.current).onCloseEnd)==null||c.call(a),r.current=!1):((s=(o=t.current).onOpenEnd)==null||s.call(o),r.current=!0)},[e,n]);return he.useEffect(()=>{var o,s,a,c;!n&&e?(s=(o=t.current).onOpenStart)==null||s.call(o):!e&&n&&((c=(a=t.current).onCloseStart)==null||c.call(a))},[e,n]),{handleAnimationComplete:i}}function wS(){const[e,t]=he.useState(0);return ul(()=>{const n=()=>t(window.innerHeight);return window.addEventListener("resize",n),n(),()=>window.removeEventListener("resize",n)},[]),e}function gv(e){const t=he.useRef();return he.useEffect(()=>{t.current=e}),t.current}function qf(e){const t=he.useRef();return ul(()=>{t.current=e}),he.useCallback((...n)=>{const r=t.current;return r==null?void 0:r(...n)},[])}const xS=he.forwardRef(({children:e,style:t={},className:n="",noPadding:r,...i},o)=>{const{y:s,isOpen:a,callbacks:c,snapPoints:l,initialSnap:d=0,sheetRef:f,windowHeight:h,detent:p,animationOptions:y,reduceMotion:E}=Ms(),{handleAnimationComplete:T}=bS(a,c),S=l?l[0]-l[d]:0,m=l?l[0]:null,x=m!==null?`min(${m}px, ${Uf})`:Uf;return O.jsx(ar.div,{...i,ref:vS([f,o]),className:Re(n,rS),style:{...t,...r?{padding:0}:{padding:Et.theme.space[16],paddingTop:0},...p==="full-height"&&{height:x},...p==="content-height"&&{maxHeight:x},y:s},initial:E?!1:{y:h},animate:{y:S,transition:y},exit:{y:h,transition:y},onAnimationComplete:T,children:e})}),ES=he.forwardRef(({children:e,style:t,disableDrag:n,disableDragContent:r,className:i="",...o},s)=>{const a=Ms(),c=mv(),l=n||c.disableDrag||r?void 0:a.dragProps;return O.jsx(ar.div,{...o,ref:s,className:Re(i,oS),style:{...t},...l,children:e})});var CS="aglyib0";const ho=u.forwardRef(({as:e,children:t,className:n,style:r,isDisabled:i,...o},s)=>{const a=e||"button";return O.jsx(a,{ref:s,as:e,"data-test-id":o["data-test-id"],className:Re(CS,n),disabled:i,style:r,...o,children:O.jsx(ls,{size:16,color:i?Et.theme.colors.grey1:Et.theme.colors.black})})});ho.displayName="Button";ho.defaultProps={as:"button","data-test-id":void 0,isDisabled:void 0};const _S=u.forwardRef(({children:e,style:t,disableDrag:n,showBack:r,onBack:i,showClose:o,title:s,onClose:a,noHandleBar:c,noHeader:l,...d},f)=>{const{indicatorRotation:h,dragProps:p}=Ms(),y=n?void 0:p,E=Zi(h,S=>`translateX(2px) rotate(${S}deg)`),T=Zi(h,S=>`translateX(-2px) rotate(${-1*S}deg)`);return O.jsxs(O.Fragment,{children:[!c&&O.jsx(ar.div,{...d,ref:f,className:sS,style:{...t},...y,children:e||O.jsxs("div",{className:iS,children:[O.jsx(ar.span,{className:Bf,style:{transform:E}}),O.jsx(ar.span,{className:Bf,style:{transform:T}})]})}),!l&&O.jsxs(Lt,{alignItems:"center",justifyContent:"space-between",marginBottom:"$8",py:"$16",gap:"$16",children:[O.jsxs(Lt,{alignItems:"center",gap:"$16",children:[r&&O.jsx(X0,{cursor:"pointer",onClick:i,size:18,color:Et.theme.colors.grey1,"data-test-id":"vds-BS-back-btn"}),s&&O.jsx(Kt,{fontWeight:"$bold",textStyle:"subtitle1",m:"$0",children:s})]}),o&&O.jsx(ho,{onClick:a,"data-test-id":"vds-BS-close-btn"})]})]})}),TS=he.forwardRef(({draggableAt:e="top",children:t,style:n,className:r="",...i},o)=>{const s=mv();function a(f){const{scrollTop:h,scrollHeight:p,clientHeight:y}=f;if(!(p>y))return;const T=h<=0,S=p-h===y;e==="top"&&T||e==="bottom"&&S||e==="both"&&(T||S)?s.setDragEnabled():s.setDragDisabled()}function c(f){a(f.currentTarget)}function l(f){a(f.currentTarget)}const d=gS()?{onScroll:c,onTouchStart:l}:void 0;return O.jsx("div",{...i,ref:o,className:Re(r,aS),style:{...n},...d,children:t})}),SS=typeof document<"u"?u.useLayoutEffect:()=>{};function sc(...e){return(...t)=>{for(let n of e)typeof n=="function"&&n(...t)}}let _o=new Map,Xf=new Set;function Gf(){if(typeof window>"u")return;let e=n=>{let r=_o.get(n.target);r||(r=new Set,_o.set(n.target,r),n.target.addEventListener("transitioncancel",t)),r.add(n.propertyName)},t=n=>{let r=_o.get(n.target);if(r&&(r.delete(n.propertyName),r.size===0&&(n.target.removeEventListener("transitioncancel",t),_o.delete(n.target)),_o.size===0)){for(let i of Xf)i();Xf.clear()}};document.body.addEventListener("transitionrun",e),document.body.addEventListener("transitionend",t)}typeof document<"u"&&(document.readyState!=="loading"?Gf():document.addEventListener("DOMContentLoaded",Gf));function yv(e){for(Zf(e)&&(e=e.parentElement);e&&!Zf(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}function Zf(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function dl(e){var t;return typeof window<"u"&&window.navigator!=null?e.test(((t=window.navigator.userAgentData)===null||t===void 0?void 0:t.platform)||window.navigator.platform):!1}function $S(){return dl(/^Mac/i)}function PS(){return dl(/^iPhone/i)}function RS(){return dl(/^iPad/i)||$S()&&navigator.maxTouchPoints>1}function IS(){return PS()||RS()}const Ca=typeof window<"u"&&window.visualViewport,AS=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);let _i=0,_a;function DS(e={}){const{isDisabled:t}=e;SS(()=>{if(!t)return _i+=1,_i===1&&(IS()?_a=MS():_a=OS()),()=>{_i-=1,_i===0&&_a()}},[t])}function OS(){return sc(Mo(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),Mo(document.documentElement,"overflow","hidden"))}function MS(){let e,t=0;const n=f=>{e=yv(f.target),!(e===document.documentElement&&e===document.body)&&(t=f.changedTouches[0].pageY)},r=f=>{if(e===document.documentElement||e===document.body){f.preventDefault();return}const h=f.changedTouches[0].pageY,{scrollTop:p}=e,y=e.scrollHeight-e.clientHeight;y!==0&&((p<=0&&h>t||p>=y&&h<t)&&f.preventDefault(),t=h)},i=f=>{const h=f.target;Jf(h)&&h!==document.activeElement&&(f.preventDefault(),h.style.transform="translateY(-2000px)",h.focus(),requestAnimationFrame(()=>{h.style.transform=""}))},o=f=>{const h=f.target;Jf(h)&&(h.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{h.style.transform="",Ca&&(Ca.height<window.innerHeight?requestAnimationFrame(()=>{Qf(h)}):Ca.addEventListener("resize",()=>Qf(h),{once:!0}))}))},s=()=>{window.scrollTo(0,0)},a=window.pageXOffset,c=window.pageYOffset,l=sc(Mo(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`),Mo(document.documentElement,"overflow","hidden"),Mo(document.body,"marginTop",`-${c}px`));window.scrollTo(0,0);const d=sc(To(document,"touchstart",n,{passive:!1,capture:!0}),To(document,"touchmove",r,{passive:!1,capture:!0}),To(document,"touchend",i,{passive:!1,capture:!0}),To(document,"focus",o,!0),To(window,"scroll",s));return()=>{l(),d(),window.scrollTo(a,c)}}function Mo(e,t,n){const r=e.style[t];return e.style[t]=n,()=>{e.style[t]=r}}function To(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}function Qf(e){const t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){const n=yv(e);if(n!==document.documentElement&&n!==document.body&&n!==e){const r=n.getBoundingClientRect().top,i=e.getBoundingClientRect().top;i>r+e.clientHeight&&(n.scrollTop+=i-r)}e=n.parentElement}}function Jf(e){return e instanceof HTMLInputElement&&!AS.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}const kS=u.forwardRef(({onOpenStart:e,onOpenEnd:t,onClose:n,onCloseStart:r,onCloseEnd:i,onSnap:o,children:s,isOpen:a,snapPoints:c,rootId:l,mountPoint:d,style:f,detent:h="content-height",initialSnap:p=0,disableDrag:y=!1,disableDragContent:E=!1,prefersReducedMotion:T=!1,tweenConfig:S=uS,showClose:m=!0,showBack:x,onBack:_,closeOnClickOutside:$=!0,noHandleBar:M,title:D,noHeader:N,"data-test-id":j,noPadding:K,...V},P)=>{const v=u.useRef(null),C=ic(0),I=wS(),k=NT(),U=!!(T||k),G={type:"tween",...U?dS:S},ue=ic(0),W=Zi(ue,H=>H>=I?-1:Et.tokens.zIndices.modal),L=Zi(ue,H=>H>=I?"hidden":"visible"),oe=u.useRef({onOpenStart:e,onOpenEnd:t,onCloseStart:r,onCloseEnd:i});ul(()=>{oe.current={onOpenStart:e,onOpenEnd:t,onCloseStart:r,onCloseEnd:i}}),c&&(c=c.map(H=>H>0&&H<=1?Math.round(H*I):H<0?I+H:H),console.assert(mS(c)||I===0,`Snap points need to be in descending order got: [${c}]`));const X=qf((H,{delta:J})=>{const ee=ue.getVelocity();ee>0&&C.set(10),ee<0&&C.set(-10),ue.set(Math.max(ue.get()+J.y,0))}),q=qf((H,{velocity:J})=>{if(J.y>pS)n();else{const te=v.current.getBoundingClientRect().height,Z=ue.get();let ge=0;if(c){const Ae=c.map($e=>te-Math.min($e,te));h==="content-height"&&!Ae.includes(0)&&Ae.unshift(0),ge=Yf(Ae,Z)}else Z/te>fS&&(ge=te);if(ge=Kf({snapTo:ge,sheetHeight:te}),Ff(ue,ge,G),c&&o){const Ae=Math.abs(Math.round(c[0]-ge)),$e=c.indexOf(Yf(c,Ae));o($e)}const Te=Math.round(te);ge>=Te&&n()}C.set(0)});u.useEffect(()=>{if(!c||!o)return;const H=a?p:c.length-1;o(H)},[a]),u.useImperativeHandle(P,()=>({y:ue,snapTo:H=>{const J=v.current;if(c&&c[H]!==void 0&&J!==null){const ee=J.getBoundingClientRect().height,te=c[H],Z=Kf({snapTo:ee-te,sheetHeight:ee});Ff(ue,Z,G),o&&o(H),Z>=ee&&n()}}})),yS(a,l),DS({isDisabled:!a});const ne=u.useMemo(()=>y?void 0:{drag:"y",dragElastic:0,dragConstraints:{top:0,bottom:0},dragMomentum:!1,dragPropagation:!1,onDrag:X,onDragEnd:q},[y]),ae={y:ue,sheetRef:v,isOpen:a,initialSnap:p,snapPoints:c,detent:h,indicatorRotation:C,callbacks:oe,dragProps:ne,windowHeight:I,animationOptions:G,reduceMotion:U,disableDrag:y},B=O.jsx(pv.Provider,{value:ae,children:O.jsx(ar.div,{...V,ref:P,className:cS,style:{zIndex:W,visibility:L,...f},children:O.jsx(AT,{children:a?O.jsx(Wf,{children:O.jsxs(Wf,{children:[O.jsxs(xS,{noPadding:K,children:[O.jsx(_S,{showBack:x,noHeader:N,onBack:_,showClose:m,title:D,onClose:n,noHandleBar:M}),O.jsx(ES,{disableDragContent:E,children:O.jsx(TS,{children:s})})]}),O.jsx(lS,{"data-test-id":"CT-BottomSheet-Overlay",onClick:()=>$?n():null})]})}):null})})});return vv?B:fn.createPortal(B,d??document.body)}),mo=({size:e,color:t="inherit",thickness:n=3,...r})=>O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 100 100",xmlSpace:"preserve",width:e,height:e,...r,children:O.jsx("path",{fill:t,stroke:t,strokeWidth:n,d:"M73 50c0-12.7-10.3-23-23-23S27 37.3 27 50m3.9 0c0-10.5 8.5-19.1 19.1-19.1S69.1 39.5 69.1 50",children:O.jsx("animateTransform",{attributeName:"transform",attributeType:"XML",type:"rotate",dur:"1s",from:"0 50 50",to:"360 50 50",repeatCount:"indefinite"})})});mo.displayName="Spinner";mo.defaultProps={size:24,thickness:3};const NS=({value:e,delay:t=500})=>{const[n,r]=u.useState(e);return u.useEffect(()=>{const i=setTimeout(()=>r(e),t||500);return()=>{clearTimeout(i)}},[e,t]),n},jS=NS;process.env.NODE_ENV;function Mr(e){"@babel/helpers - typeof";return Mr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mr(e)}function pr(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function an(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function Dn(e){an(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||Mr(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}var VS={};function ks(){return VS}var LS=6e4,FS=36e5,BS=1e3;function ao(e){an(1,arguments);var t=1,n=Dn(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function HS(e){an(1,arguments);var t=Dn(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=ao(r),o=new Date(0);o.setUTCFullYear(n,0,4),o.setUTCHours(0,0,0,0);var s=ao(o);return t.getTime()>=i.getTime()?n+1:t.getTime()>=s.getTime()?n:n-1}function WS(e){an(1,arguments);var t=HS(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=ao(n);return r}var US=6048e5;function YS(e){an(1,arguments);var t=Dn(e),n=ao(t).getTime()-WS(t).getTime();return Math.round(n/US)+1}function kr(e,t){var n,r,i,o,s,a,c,l;an(1,arguments);var d=ks(),f=pr((n=(r=(i=(o=t==null?void 0:t.weekStartsOn)!==null&&o!==void 0?o:t==null||(s=t.locale)===null||s===void 0||(a=s.options)===null||a===void 0?void 0:a.weekStartsOn)!==null&&i!==void 0?i:d.weekStartsOn)!==null&&r!==void 0?r:(c=d.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&n!==void 0?n:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=Dn(e),p=h.getUTCDay(),y=(p<f?7:0)+p-f;return h.setUTCDate(h.getUTCDate()-y),h.setUTCHours(0,0,0,0),h}function bv(e,t){var n,r,i,o,s,a,c,l;an(1,arguments);var d=Dn(e),f=d.getUTCFullYear(),h=ks(),p=pr((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(s=t.locale)===null||s===void 0||(a=s.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:h.firstWeekContainsDate)!==null&&r!==void 0?r:(c=h.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var y=new Date(0);y.setUTCFullYear(f+1,0,p),y.setUTCHours(0,0,0,0);var E=kr(y,t),T=new Date(0);T.setUTCFullYear(f,0,p),T.setUTCHours(0,0,0,0);var S=kr(T,t);return d.getTime()>=E.getTime()?f+1:d.getTime()>=S.getTime()?f:f-1}function zS(e,t){var n,r,i,o,s,a,c,l;an(1,arguments);var d=ks(),f=pr((n=(r=(i=(o=t==null?void 0:t.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(s=t.locale)===null||s===void 0||(a=s.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:d.firstWeekContainsDate)!==null&&r!==void 0?r:(c=d.locale)===null||c===void 0||(l=c.options)===null||l===void 0?void 0:l.firstWeekContainsDate)!==null&&n!==void 0?n:1),h=bv(e,t),p=new Date(0);p.setUTCFullYear(h,0,f),p.setUTCHours(0,0,0,0);var y=kr(p,t);return y}var KS=6048e5;function qS(e,t){an(1,arguments);var n=Dn(e),r=kr(n,t).getTime()-zS(n,t).getTime();return Math.round(r/KS)+1}function Ce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ac(e,t){return ac=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},ac(e,t)}function Je(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ac(e,t)}function Qi(e){return Qi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Qi(e)}function XS(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function GS(e,t){if(t&&(Mr(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ce(e)}function et(e){var t=XS();return function(){var n=Qi(e),r;if(t){var i=Qi(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return GS(this,r)}}function Ke(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ZS(e,t){if(Mr(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Mr(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function wv(e){var t=ZS(e,"string");return Mr(t)==="symbol"?t:String(t)}function ep(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,wv(r.key),r)}}function qe(e,t,n){return t&&ep(e.prototype,t),n&&ep(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function we(e,t,n){return t=wv(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var QS=function(){function e(){Ke(this,e),we(this,"priority",void 0),we(this,"subPriority",0)}return qe(e,[{key:"validate",value:function(t,n){return!0}}]),e}(),JS=function(e){Je(n,e);var t=et(n);function n(r,i,o,s,a){var c;return Ke(this,n),c=t.call(this),c.value=r,c.validateValue=i,c.setValue=o,c.priority=s,a&&(c.subPriority=a),c}return qe(n,[{key:"validate",value:function(r,i){return this.validateValue(r,this.value,i)}},{key:"set",value:function(r,i,o){return this.setValue(r,i,this.value,o)}}]),n}(QS),nt=function(){function e(){Ke(this,e),we(this,"incompatibleTokens",void 0),we(this,"priority",void 0),we(this,"subPriority",void 0)}return qe(e,[{key:"run",value:function(t,n,r,i){var o=this.parse(t,n,r,i);return o?{setter:new JS(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}},{key:"validate",value:function(t,n,r){return!0}}]),e}(),e$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",140),we(Ce(r),"incompatibleTokens",["R","u","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"G":case"GG":case"GGG":return o.era(r,{width:"abbreviated"})||o.era(r,{width:"narrow"});case"GGGGG":return o.era(r,{width:"narrow"});case"GGGG":default:return o.era(r,{width:"wide"})||o.era(r,{width:"abbreviated"})||o.era(r,{width:"narrow"})}}},{key:"set",value:function(r,i,o){return i.era=o,r.setUTCFullYear(o,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),$t={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},$n={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Pt(e,t){return e&&{value:t(e.value),rest:e.rest}}function xt(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function Pn(e,t){var n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};var r=n[1]==="+"?1:-1,i=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,s=n[5]?parseInt(n[5],10):0;return{value:r*(i*FS+o*LS+s*BS),rest:t.slice(n[0].length)}}function xv(e){return xt($t.anyDigitsSigned,e)}function _t(e,t){switch(e){case 1:return xt($t.singleDigit,t);case 2:return xt($t.twoDigits,t);case 3:return xt($t.threeDigits,t);case 4:return xt($t.fourDigits,t);default:return xt(new RegExp("^\\d{1,"+e+"}"),t)}}function Ev(e,t){switch(e){case 1:return xt($t.singleDigitSigned,t);case 2:return xt($t.twoDigitsSigned,t);case 3:return xt($t.threeDigitsSigned,t);case 4:return xt($t.fourDigitsSigned,t);default:return xt(new RegExp("^-?\\d{1,"+e+"}"),t)}}function fl(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function Cv(e,t){var n=t>0,r=n?t:1-t,i;if(r<=50)i=e||100;else{var o=r+50,s=Math.floor(o/100)*100,a=e>=o%100;i=e+s-(a?100:0)}return n?i:1-i}function _v(e){return e%400===0||e%4===0&&e%100!==0}var t$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return{year:a,isTwoDigitYear:i==="yy"}};switch(i){case"y":return Pt(_t(4,r),s);case"yo":return Pt(o.ordinalNumber(r,{unit:"year"}),s);default:return Pt(_t(i.length,r),s)}}},{key:"validate",value:function(r,i){return i.isTwoDigitYear||i.year>0}},{key:"set",value:function(r,i,o){var s=r.getUTCFullYear();if(o.isTwoDigitYear){var a=Cv(o.year,s);return r.setUTCFullYear(a,0,1),r.setUTCHours(0,0,0,0),r}var c=!("era"in i)||i.era===1?o.year:1-o.year;return r.setUTCFullYear(c,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),n$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return{year:a,isTwoDigitYear:i==="YY"}};switch(i){case"Y":return Pt(_t(4,r),s);case"Yo":return Pt(o.ordinalNumber(r,{unit:"year"}),s);default:return Pt(_t(i.length,r),s)}}},{key:"validate",value:function(r,i){return i.isTwoDigitYear||i.year>0}},{key:"set",value:function(r,i,o,s){var a=bv(r,s);if(o.isTwoDigitYear){var c=Cv(o.year,a);return r.setUTCFullYear(c,0,s.firstWeekContainsDate),r.setUTCHours(0,0,0,0),kr(r,s)}var l=!("era"in i)||i.era===1?o.year:1-o.year;return r.setUTCFullYear(l,0,s.firstWeekContainsDate),r.setUTCHours(0,0,0,0),kr(r,s)}}]),n}(nt),r$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i){return Ev(i==="R"?4:i.length,r)}},{key:"set",value:function(r,i,o){var s=new Date(0);return s.setUTCFullYear(o,0,4),s.setUTCHours(0,0,0,0),ao(s)}}]),n}(nt),o$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",130),we(Ce(r),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i){return Ev(i==="u"?4:i.length,r)}},{key:"set",value:function(r,i,o){return r.setUTCFullYear(o,0,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),i$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",120),we(Ce(r),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"Q":case"QQ":return _t(i.length,r);case"Qo":return o.ordinalNumber(r,{unit:"quarter"});case"QQQ":return o.quarter(r,{width:"abbreviated",context:"formatting"})||o.quarter(r,{width:"narrow",context:"formatting"});case"QQQQQ":return o.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return o.quarter(r,{width:"wide",context:"formatting"})||o.quarter(r,{width:"abbreviated",context:"formatting"})||o.quarter(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=1&&i<=4}},{key:"set",value:function(r,i,o){return r.setUTCMonth((o-1)*3,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),s$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",120),we(Ce(r),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"q":case"qq":return _t(i.length,r);case"qo":return o.ordinalNumber(r,{unit:"quarter"});case"qqq":return o.quarter(r,{width:"abbreviated",context:"standalone"})||o.quarter(r,{width:"narrow",context:"standalone"});case"qqqqq":return o.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return o.quarter(r,{width:"wide",context:"standalone"})||o.quarter(r,{width:"abbreviated",context:"standalone"})||o.quarter(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,i){return i>=1&&i<=4}},{key:"set",value:function(r,i,o){return r.setUTCMonth((o-1)*3,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),a$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),we(Ce(r),"priority",110),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return a-1};switch(i){case"M":return Pt(xt($t.month,r),s);case"MM":return Pt(_t(2,r),s);case"Mo":return Pt(o.ordinalNumber(r,{unit:"month"}),s);case"MMM":return o.month(r,{width:"abbreviated",context:"formatting"})||o.month(r,{width:"narrow",context:"formatting"});case"MMMMM":return o.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return o.month(r,{width:"wide",context:"formatting"})||o.month(r,{width:"abbreviated",context:"formatting"})||o.month(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=11}},{key:"set",value:function(r,i,o){return r.setUTCMonth(o,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt),c$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",110),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return a-1};switch(i){case"L":return Pt(xt($t.month,r),s);case"LL":return Pt(_t(2,r),s);case"Lo":return Pt(o.ordinalNumber(r,{unit:"month"}),s);case"LLL":return o.month(r,{width:"abbreviated",context:"standalone"})||o.month(r,{width:"narrow",context:"standalone"});case"LLLLL":return o.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return o.month(r,{width:"wide",context:"standalone"})||o.month(r,{width:"abbreviated",context:"standalone"})||o.month(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=11}},{key:"set",value:function(r,i,o){return r.setUTCMonth(o,1),r.setUTCHours(0,0,0,0),r}}]),n}(nt);function l$(e,t,n){an(2,arguments);var r=Dn(e),i=pr(t),o=qS(r,n)-i;return r.setUTCDate(r.getUTCDate()-o*7),r}var u$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",100),we(Ce(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"w":return xt($t.week,r);case"wo":return o.ordinalNumber(r,{unit:"week"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=53}},{key:"set",value:function(r,i,o,s){return kr(l$(r,o,s),s)}}]),n}(nt);function d$(e,t){an(2,arguments);var n=Dn(e),r=pr(t),i=YS(n)-r;return n.setUTCDate(n.getUTCDate()-i*7),n}var f$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",100),we(Ce(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"I":return xt($t.week,r);case"Io":return o.ordinalNumber(r,{unit:"week"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=53}},{key:"set",value:function(r,i,o){return ao(d$(r,o))}}]),n}(nt),p$=[31,28,31,30,31,30,31,31,30,31,30,31],h$=[31,29,31,30,31,30,31,31,30,31,30,31],m$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"subPriority",1),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"d":return xt($t.date,r);case"do":return o.ordinalNumber(r,{unit:"date"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){var o=r.getUTCFullYear(),s=_v(o),a=r.getUTCMonth();return s?i>=1&&i<=h$[a]:i>=1&&i<=p$[a]}},{key:"set",value:function(r,i,o){return r.setUTCDate(o),r.setUTCHours(0,0,0,0),r}}]),n}(nt),v$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"subpriority",1),we(Ce(r),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"D":case"DD":return xt($t.dayOfYear,r);case"Do":return o.ordinalNumber(r,{unit:"date"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){var o=r.getUTCFullYear(),s=_v(o);return s?i>=1&&i<=366:i>=1&&i<=365}},{key:"set",value:function(r,i,o){return r.setUTCMonth(0,o),r.setUTCHours(0,0,0,0),r}}]),n}(nt);function pl(e,t,n){var r,i,o,s,a,c,l,d;an(2,arguments);var f=ks(),h=pr((r=(i=(o=(s=n==null?void 0:n.weekStartsOn)!==null&&s!==void 0?s:n==null||(a=n.locale)===null||a===void 0||(c=a.options)===null||c===void 0?void 0:c.weekStartsOn)!==null&&o!==void 0?o:f.weekStartsOn)!==null&&i!==void 0?i:(l=f.locale)===null||l===void 0||(d=l.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&r!==void 0?r:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var p=Dn(e),y=pr(t),E=p.getUTCDay(),T=y%7,S=(T+7)%7,m=(S<h?7:0)+y-E;return p.setUTCDate(p.getUTCDate()+m),p}var g$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["D","i","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"E":case"EE":case"EEE":return o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"EEEEE":return o.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"EEEE":default:return o.day(r,{width:"wide",context:"formatting"})||o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=6}},{key:"set",value:function(r,i,o,s){return r=pl(r,o,s),r.setUTCHours(0,0,0,0),r}}]),n}(nt),y$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o,s){var a=function(c){var l=Math.floor((c-1)/7)*7;return(c+s.weekStartsOn+6)%7+l};switch(i){case"e":case"ee":return Pt(_t(i.length,r),a);case"eo":return Pt(o.ordinalNumber(r,{unit:"day"}),a);case"eee":return o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"eeeee":return o.day(r,{width:"narrow",context:"formatting"});case"eeeeee":return o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"});case"eeee":default:return o.day(r,{width:"wide",context:"formatting"})||o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=6}},{key:"set",value:function(r,i,o,s){return r=pl(r,o,s),r.setUTCHours(0,0,0,0),r}}]),n}(nt),b$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o,s){var a=function(c){var l=Math.floor((c-1)/7)*7;return(c+s.weekStartsOn+6)%7+l};switch(i){case"c":case"cc":return Pt(_t(i.length,r),a);case"co":return Pt(o.ordinalNumber(r,{unit:"day"}),a);case"ccc":return o.day(r,{width:"abbreviated",context:"standalone"})||o.day(r,{width:"short",context:"standalone"})||o.day(r,{width:"narrow",context:"standalone"});case"ccccc":return o.day(r,{width:"narrow",context:"standalone"});case"cccccc":return o.day(r,{width:"short",context:"standalone"})||o.day(r,{width:"narrow",context:"standalone"});case"cccc":default:return o.day(r,{width:"wide",context:"standalone"})||o.day(r,{width:"abbreviated",context:"standalone"})||o.day(r,{width:"short",context:"standalone"})||o.day(r,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(r,i){return i>=0&&i<=6}},{key:"set",value:function(r,i,o,s){return r=pl(r,o,s),r.setUTCHours(0,0,0,0),r}}]),n}(nt);function w$(e,t){an(2,arguments);var n=pr(t);n%7===0&&(n=n-7);var r=1,i=Dn(e),o=i.getUTCDay(),s=n%7,a=(s+7)%7,c=(a<r?7:0)+n-o;return i.setUTCDate(i.getUTCDate()+c),i}var x$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",90),we(Ce(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){var s=function(a){return a===0?7:a};switch(i){case"i":case"ii":return _t(i.length,r);case"io":return o.ordinalNumber(r,{unit:"day"});case"iii":return Pt(o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"}),s);case"iiiii":return Pt(o.day(r,{width:"narrow",context:"formatting"}),s);case"iiiiii":return Pt(o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"}),s);case"iiii":default:return Pt(o.day(r,{width:"wide",context:"formatting"})||o.day(r,{width:"abbreviated",context:"formatting"})||o.day(r,{width:"short",context:"formatting"})||o.day(r,{width:"narrow",context:"formatting"}),s)}}},{key:"validate",value:function(r,i){return i>=1&&i<=7}},{key:"set",value:function(r,i,o){return r=w$(r,o),r.setUTCHours(0,0,0,0),r}}]),n}(nt),E$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",80),we(Ce(r),"incompatibleTokens",["b","B","H","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"a":case"aa":case"aaa":return o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaaa":return o.dayPeriod(r,{width:"narrow",context:"formatting"});case"aaaa":default:return o.dayPeriod(r,{width:"wide",context:"formatting"})||o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,i,o){return r.setUTCHours(fl(o),0,0,0),r}}]),n}(nt),C$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",80),we(Ce(r),"incompatibleTokens",["a","B","H","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"b":case"bb":case"bbb":return o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbbb":return o.dayPeriod(r,{width:"narrow",context:"formatting"});case"bbbb":default:return o.dayPeriod(r,{width:"wide",context:"formatting"})||o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,i,o){return r.setUTCHours(fl(o),0,0,0),r}}]),n}(nt),_$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",80),we(Ce(r),"incompatibleTokens",["a","b","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"B":case"BB":case"BBB":return o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBBB":return o.dayPeriod(r,{width:"narrow",context:"formatting"});case"BBBB":default:return o.dayPeriod(r,{width:"wide",context:"formatting"})||o.dayPeriod(r,{width:"abbreviated",context:"formatting"})||o.dayPeriod(r,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(r,i,o){return r.setUTCHours(fl(o),0,0,0),r}}]),n}(nt),T$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["H","K","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"h":return xt($t.hour12h,r);case"ho":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=12}},{key:"set",value:function(r,i,o){var s=r.getUTCHours()>=12;return s&&o<12?r.setUTCHours(o+12,0,0,0):!s&&o===12?r.setUTCHours(0,0,0,0):r.setUTCHours(o,0,0,0),r}}]),n}(nt),S$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["a","b","h","K","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"H":return xt($t.hour23h,r);case"Ho":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=23}},{key:"set",value:function(r,i,o){return r.setUTCHours(o,0,0,0),r}}]),n}(nt),$$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["h","H","k","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"K":return xt($t.hour11h,r);case"Ko":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=11}},{key:"set",value:function(r,i,o){var s=r.getUTCHours()>=12;return s&&o<12?r.setUTCHours(o+12,0,0,0):r.setUTCHours(o,0,0,0),r}}]),n}(nt),P$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",70),we(Ce(r),"incompatibleTokens",["a","b","h","H","K","t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"k":return xt($t.hour24h,r);case"ko":return o.ordinalNumber(r,{unit:"hour"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=1&&i<=24}},{key:"set",value:function(r,i,o){var s=o<=24?o%24:o;return r.setUTCHours(s,0,0,0),r}}]),n}(nt),R$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",60),we(Ce(r),"incompatibleTokens",["t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"m":return xt($t.minute,r);case"mo":return o.ordinalNumber(r,{unit:"minute"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=59}},{key:"set",value:function(r,i,o){return r.setUTCMinutes(o,0,0),r}}]),n}(nt),I$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",50),we(Ce(r),"incompatibleTokens",["t","T"]),r}return qe(n,[{key:"parse",value:function(r,i,o){switch(i){case"s":return xt($t.second,r);case"so":return o.ordinalNumber(r,{unit:"second"});default:return _t(i.length,r)}}},{key:"validate",value:function(r,i){return i>=0&&i<=59}},{key:"set",value:function(r,i,o){return r.setUTCSeconds(o,0),r}}]),n}(nt),A$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",30),we(Ce(r),"incompatibleTokens",["t","T"]),r}return qe(n,[{key:"parse",value:function(r,i){var o=function(s){return Math.floor(s*Math.pow(10,-i.length+3))};return Pt(_t(i.length,r),o)}},{key:"set",value:function(r,i,o){return r.setUTCMilliseconds(o),r}}]),n}(nt),D$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",10),we(Ce(r),"incompatibleTokens",["t","T","x"]),r}return qe(n,[{key:"parse",value:function(r,i){switch(i){case"X":return Pn($n.basicOptionalMinutes,r);case"XX":return Pn($n.basic,r);case"XXXX":return Pn($n.basicOptionalSeconds,r);case"XXXXX":return Pn($n.extendedOptionalSeconds,r);case"XXX":default:return Pn($n.extended,r)}}},{key:"set",value:function(r,i,o){return i.timestampIsSet?r:new Date(r.getTime()-o)}}]),n}(nt),O$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",10),we(Ce(r),"incompatibleTokens",["t","T","X"]),r}return qe(n,[{key:"parse",value:function(r,i){switch(i){case"x":return Pn($n.basicOptionalMinutes,r);case"xx":return Pn($n.basic,r);case"xxxx":return Pn($n.basicOptionalSeconds,r);case"xxxxx":return Pn($n.extendedOptionalSeconds,r);case"xxx":default:return Pn($n.extended,r)}}},{key:"set",value:function(r,i,o){return i.timestampIsSet?r:new Date(r.getTime()-o)}}]),n}(nt),M$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",40),we(Ce(r),"incompatibleTokens","*"),r}return qe(n,[{key:"parse",value:function(r){return xv(r)}},{key:"set",value:function(r,i,o){return[new Date(o*1e3),{timestampIsSet:!0}]}}]),n}(nt),k$=function(e){Je(n,e);var t=et(n);function n(){var r;Ke(this,n);for(var i=arguments.length,o=new Array(i),s=0;s<i;s++)o[s]=arguments[s];return r=t.call.apply(t,[this].concat(o)),we(Ce(r),"priority",20),we(Ce(r),"incompatibleTokens","*"),r}return qe(n,[{key:"parse",value:function(r){return xv(r)}},{key:"set",value:function(r,i,o){return[new Date(o),{timestampIsSet:!0}]}}]),n}(nt);new e$,new t$,new n$,new r$,new o$,new i$,new s$,new a$,new c$,new u$,new f$,new m$,new v$,new g$,new y$,new b$,new x$,new E$,new C$,new _$,new T$,new S$,new $$,new P$,new R$,new I$,new A$,new D$,new O$,new M$,new k$;var N$=ft({defaultClassName:"_920fuu5",variantClassNames:{colorScheme:{primary:"_920fuu6",neutral:"_920fuu7",danger:"_920fuu8",warning:"_920fuu9",info:"_920fuua"},variant:{solid:"_920fuub",outline:"_920fuuc",ghost:"_920fuud"},size:{small:"_920fuue",medium:"_920fuuf",large:"_920fuug"},unstyled:{true:"_920fuuh"},isFluid:{true:"_920fuui"}},defaultVariants:{size:"medium",variant:"solid",colorScheme:"primary"},compoundVariants:[[{colorScheme:"primary",variant:"outline"},"_920fuuj"],[{colorScheme:"neutral",variant:"outline"},"_920fuuk"],[{colorScheme:"danger",variant:"outline"},"_920fuul"],[{colorScheme:"warning",variant:"outline"},"_920fuum"],[{colorScheme:"info",variant:"outline"},"_920fuun"],[{size:"small",variant:"outline"},"_920fuuo"],[{size:"large",variant:"outline"},"_920fuup"]]}),j$={primary:"var(--_1qe00b21g)",neutral:"var(--_1qe00b2c)",danger:"var(--_1qe00b214)",warning:"var(--_1qe00b211)",success:"var(--_1qe00b2v)",info:"var(--_1qe00b2y)"},V$={primary:"_920fuu0",neutral:"_920fuu1",danger:"_920fuu2",warning:"_920fuu3",info:"_920fuu4"},tp={primary:"var(--_1qe00b2a)",neutral:"var(--_1qe00b2c)",danger:"var(--_1qe00b214)",warning:"var(--_1qe00b211)",info:"var(--_1qe00b2y)",white:"var(--_1qe00b2d)"};var L$="p9dczu0";const hl=({ref:e,colorScheme:t="primary"})=>{const[n,r]=u.useState([]),i=jS({value:n,delay:1e3});return u.useEffect(()=>{if(e.current){const o=e.current,s=a=>{const c=o.getBoundingClientRect(),l=a.clientX-c.left,d=a.clientY-c.top,f=o.clientHeight,h=o.clientWidth,p=Math.max(h,f);r([...n,{top:d-p/2,left:l-p/2,height:Math.max(h,f),width:Math.max(h,f),backgroundColor:t==="primary"?Et.theme.colors.primary:j$[t]}])};return o.addEventListener("click",s),()=>{o.removeEventListener("click",s)}}return()=>!1},[e,n]),u.useEffect(()=>{i.length&&r([])},[i.length]),n==null?void 0:n.map((o,s)=>O.jsx("span",{className:L$,style:{...o}},s))},co=u.forwardRef(({as:e,children:t,className:n,colorScheme:r,size:i,isLoading:o,variant:s,style:a,isDisabled:c,isFluid:l,unstyled:d,...f},h)=>{const p=u.useRef(null),y=hl({ref:p,colorScheme:r,variant:s});u.useImperativeHandle(h,()=>p.current);const E=e||"button";return O.jsx(E,{ref:p,as:e,"data-test-id":f["data-test-id"],className:Re(N$({colorScheme:r,size:i,variant:s,isFluid:l,unstyled:d}),s==="ghost"?V$[r||"primary"]:void 0,n),disabled:c,style:a,...f,children:o?O.jsx(mo,{color:s==="outline"||s==="ghost"?tp[r||"primary"]:tp.white}):O.jsxs(O.Fragment,{children:[y,t]})})});co.displayName="Button";co.defaultProps={as:"button","data-test-id":void 0,isDisabled:void 0,isLoading:void 0,isFluid:void 0};const Tv="Checkbox",[F$,bD]=sn(Tv),[B$,H$]=F$(Tv),W$=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:o,required:s,disabled:a,value:c="on",onCheckedChange:l,...d}=e,[f,h]=u.useState(null),p=Qe(t,x=>h(x)),y=u.useRef(!1),E=f?!!f.closest("form"):!0,[T=!1,S]=pn({prop:i,defaultProp:o,onChange:l}),m=u.useRef(T);return u.useEffect(()=>{const x=f==null?void 0:f.form;if(x){const _=()=>S(m.current);return x.addEventListener("reset",_),()=>x.removeEventListener("reset",_)}},[f,S]),u.createElement(B$,{scope:n,state:T,disabled:a},u.createElement(He.button,ie({type:"button",role:"checkbox","aria-checked":Ar(T)?"mixed":T,"aria-required":s,"data-state":Sv(T),"data-disabled":a?"":void 0,disabled:a,value:c},d,{ref:p,onKeyDown:De(e.onKeyDown,x=>{x.key==="Enter"&&x.preventDefault()}),onClick:De(e.onClick,x=>{S(_=>Ar(_)?!0:!_),E&&(y.current=x.isPropagationStopped(),y.current||x.stopPropagation())})})),E&&u.createElement(z$,{control:f,bubbles:!y.current,name:r,value:c,checked:T,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))}),U$="CheckboxIndicator",Y$=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...i}=e,o=H$(U$,n);return u.createElement(hr,{present:r||Ar(o.state)||o.state===!0},u.createElement(He.span,ie({"data-state":Sv(o.state),"data-disabled":o.disabled?"":void 0},i,{ref:t,style:{pointerEvents:"none",...e.style}})))}),z$=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,o=u.useRef(null),s=ms(n),a=ps(t);return u.useEffect(()=>{const c=o.current,l=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(l,"checked").set;if(s!==n&&f){const h=new Event("click",{bubbles:r});c.indeterminate=Ar(n),f.call(c,Ar(n)?!1:n),c.dispatchEvent(h)}},[s,n,r]),u.createElement("input",ie({type:"checkbox","aria-hidden":!0,defaultChecked:Ar(n)?!1:n},i,{tabIndex:-1,ref:o,style:{...e.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ar(e){return e==="indeterminate"}function Sv(e){return Ar(e)?"indeterminate":e?"checked":"unchecked"}const K$=W$,q$=Y$;var X$="glci2q0",np="glci2q3",G$="glci2q4",rp={disabled:"glci2q1",enabled:"glci2q2"},Z$=ft({defaultClassName:"glci2q5",variantClassNames:{checked:{true:"glci2q6",false:"glci2q7",indeterminate:"glci2q8"},disabled:{true:"glci2q9"}},defaultVariants:{checked:!1,disabled:!1},compoundVariants:[[{checked:!1,disabled:!0},"glci2qa"]]});const $v=u.forwardRef(({children:e,"data-test-id":t,checked:n=!1,onCheckedChange:r,disabled:i,value:o,...s},a)=>{const c=`vds-checkbox-${u.useId()}`,[l,d]=u.useState(n);return u.useEffect(()=>{d(n)},[n]),O.jsxs("div",{className:X$,children:[O.jsx(K$,{id:c,disabled:i,"data-test-id":t,ref:a,value:l?"on":"off",checked:l,className:Z$({checked:l,disabled:i}),onCheckedChange:f=>{typeof f=="boolean"&&(r?r(f):d(f))},...s,children:O.jsxs(q$,{className:G$,children:[l==="indeterminate"&&O.jsx(tb,{color:"white",className:np}),l===!0&&O.jsx(_c,{color:"white",className:np})]})}),e&&O.jsx("label",{htmlFor:c,className:i?rp.disabled:rp.enabled,children:e})]})});$v.defaultProps={"data-test-id":"base"};const Q$=e=>u.useMemo(()=>{const n=e.every(Boolean);return e.some(Boolean)&&!n?"indeterminate":!!n},[e]);var J$=ft({defaultClassName:"_5046e70",variantClassNames:{variant:{filled:"_5046e71",outline:"_5046e72"},isActive:{true:"_5046e73"},isFluid:{true:"_5046e74"}},defaultVariants:{variant:"filled",isActive:!1},compoundVariants:[[{isActive:!0,variant:"outline"},"_5046e75"]]}),eP="_5046e76";const ml=u.forwardRef(({as:e,children:t,variant:n,isActive:r,isFilter:i,prefixIcon:o,withCloseButton:s,className:a,disabled:c,style:l,...d},f)=>{const h=e||"button";return O.jsxs(h,{ref:f,as:e,"data-test-id":d["data-test-id"],className:Re(J$({variant:n,isActive:r}),a),disabled:c,style:l,...d,children:[o&&o,i&&!o&&O.jsx(J0,{style:{marginRight:8},size:16,color:"inherit"}),t,s&&O.jsx(ho,{"data-test-id":"chips-close-button",className:eP,isDisabled:c})]})});ml.defaultProps={as:"button",children:void 0,isActive:!1,isFilter:!1,prefixIcon:void 0,withCloseButton:!1,"data-test-id":void 0};ml.displayName="Chips";const Pv="Dialog",[Rv,wD]=sn(Pv),[tP,gr]=Rv(Pv),nP=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:s=!0}=e,a=u.useRef(null),c=u.useRef(null),[l=!1,d]=pn({prop:r,defaultProp:i,onChange:o});return u.createElement(tP,{scope:t,triggerRef:a,contentRef:c,contentId:Bn(),titleId:Bn(),descriptionId:Bn(),open:l,onOpenChange:d,onOpenToggle:u.useCallback(()=>d(f=>!f),[d]),modal:s},n)},rP="DialogTrigger",oP=u.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=gr(rP,n),o=Qe(t,i.triggerRef);return u.createElement(He.button,ie({type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":vl(i.open)},r,{ref:o,onClick:De(e.onClick,i.onOpenToggle)}))}),iP="DialogPortal",[xD,Iv]=Rv(iP,{forceMount:void 0}),cc="DialogOverlay",sP=u.forwardRef((e,t)=>{const n=Iv(cc,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=gr(cc,e.__scopeDialog);return o.modal?u.createElement(hr,{present:r||o.open},u.createElement(aP,ie({},i,{ref:t}))):null}),aP=u.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=gr(cc,n);return u.createElement(Ph,{as:no,allowPinchZoom:!0,shards:[i.contentRef]},u.createElement(He.div,ie({"data-state":vl(i.open)},r,{ref:t,style:{pointerEvents:"auto",...r.style}})))}),Uo="DialogContent",cP=u.forwardRef((e,t)=>{const n=Iv(Uo,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,o=gr(Uo,e.__scopeDialog);return u.createElement(hr,{present:r||o.open},o.modal?u.createElement(lP,ie({},i,{ref:t})):u.createElement(uP,ie({},i,{ref:t})))}),lP=u.forwardRef((e,t)=>{const n=gr(Uo,e.__scopeDialog),r=u.useRef(null),i=Qe(t,n.contentRef,r);return u.useEffect(()=>{const o=r.current;if(o)return bh(o)},[]),u.createElement(Av,ie({},e,{ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:De(e.onCloseAutoFocus,o=>{var s;o.preventDefault(),(s=n.triggerRef.current)===null||s===void 0||s.focus()}),onPointerDownOutside:De(e.onPointerDownOutside,o=>{const s=o.detail.originalEvent,a=s.button===0&&s.ctrlKey===!0;(s.button===2||a)&&o.preventDefault()}),onFocusOutside:De(e.onFocusOutside,o=>o.preventDefault())}))}),uP=u.forwardRef((e,t)=>{const n=gr(Uo,e.__scopeDialog),r=u.useRef(!1),i=u.useRef(!1);return u.createElement(Av,ie({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var s;if((s=e.onCloseAutoFocus)===null||s===void 0||s.call(e,o),!o.defaultPrevented){var a;r.current||(a=n.triggerRef.current)===null||a===void 0||a.focus(),o.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:o=>{var s,a;(s=e.onInteractOutside)===null||s===void 0||s.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const c=o.target;((a=n.triggerRef.current)===null||a===void 0?void 0:a.contains(c))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}}))}),Av=u.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,...s}=e,a=gr(Uo,n),c=u.useRef(null),l=Qe(t,c);return Zp(),u.createElement(u.Fragment,null,u.createElement(Qp,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o},u.createElement(us,ie({role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":vl(a.open)},s,{ref:l,onDismiss:()=>a.onOpenChange(!1)}))),!1)}),dP="DialogClose",fP=u.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=gr(dP,n);return u.createElement(He.button,ie({type:"button"},r,{ref:t,onClick:De(e.onClick,()=>i.onOpenChange(!1))}))});function vl(e){return e?"open":"closed"}const pP=nP,hP=oP,mP=sP,vP=cP,gP=fP;var yP="_1jc0z8o4",bP="_1jc0z8o0",wP=ft({defaultClassName:"_1jc0z8o7",variantClassNames:{size:{full:"_1jc0z8o8",small:"_1jc0z8o9",medium:"_1jc0z8oa",large:"_1jc0z8ob"},noPadding:{true:"_1jc0z8oc"},colorScheme:{primary:"_1jc0z8od",neutral:"_1jc0z8oe",danger:"_1jc0z8of",warning:"_1jc0z8og",info:"_1jc0z8oh",white:"_1jc0z8oi"}},defaultVariants:{size:"medium",noPadding:!1,colorScheme:"white"},compoundVariants:[]}),xP="_1jc0z8o1",EP=ft({defaultClassName:"_1jc0z8o2",variantClassNames:{bold:{true:"_1jc0z8o3"}},defaultVariants:{bold:!1},compoundVariants:[]}),CP=ft({defaultClassName:"_1jc0z8o6",variantClassNames:{},defaultVariants:{},compoundVariants:[]});const _P=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(vP,{className:t,ref:r,...n,children:e})),TP=u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(mP,{className:t,ref:r,...n,children:e})),SP=({children:e,className:t,...n})=>O.jsx(xs,{className:t,...n,children:e}),$P=({children:e,...t})=>O.jsx(pP,{...t,children:e});u.forwardRef(({children:e,className:t,...n},r)=>O.jsx(hP,{className:t,...n,ref:r,children:e}));const ei=u.forwardRef(({children:e,"data-test-id":t,isOpen:n,onClose:r,size:i,destroyOnClose:o,noPadding:s,colorScheme:a,closeOnOverlayClick:c,closeIcon:l,classNameBody:d,isCloseWhenEscape:f,...h},p)=>!n&&o?null:O.jsx($P,{open:n,onOpenChange:r,children:O.jsxs(SP,{children:[O.jsx(TP,{className:Re(CP())}),O.jsxs(_P,{onInteractOutside:y=>!c&&y.preventDefault(),className:Re(wP({colorScheme:a,size:i,noPadding:s}),d),...h,onEscapeKeyDown:y=>f?r==null?void 0:r():y.preventDefault(),ref:p,children:[r&&!l&&O.jsx(gP,{asChild:!0,"aria-label":"Close",children:O.jsx(ho,{className:yP,"data-test-id":"close-modal"})}),r&&l&&l,e]})]})}));ei.displayName="Modal";ei.defaultProps={children:void 0,"data-test-id":void 0,size:"medium",onClose:void 0,destroyOnClose:!1,noPadding:!1,colorScheme:"white",closeOnOverlayClick:!0,closeIcon:void 0,classNameBody:void 0,isCloseWhenEscape:!0};const Ns=u.forwardRef(({as:e,children:t,"data-test-id":n,...r},i)=>{const o=e||"div";return O.jsx(o,{"data-test-id":n,as:e,ref:i,className:bP,...r,children:t})});Ns.displayName="modalBody";Ns.defaultProps={as:"div",children:void 0,"data-test-id":void 0};const js=u.forwardRef(({as:e,children:t,"data-test-id":n,...r},i)=>{const o=e||"div";return O.jsx(o,{"data-test-id":n,as:e,className:xP,ref:i,...r,children:t})});js.displayName="modalFooter";js.defaultProps={as:"div",children:void 0,"data-test-id":void 0};const ti=u.forwardRef(({as:e,bold:t,children:n,"data-test-id":r,...i},o)=>{const s=e||"div";return O.jsx(s,{"data-test-id":r,as:e,ref:o,className:EP({bold:t}),...i,children:O.jsx(Kt,{textStyle:"subtitle1",fontWeight:"$bold",paddingRight:"$16",margin:"$0",children:n})})});ti.displayName="modalHeader";ti.defaultProps={as:"div",bold:!1,children:void 0,"data-test-id":void 0};const gl=({isOpen:e,onConfirm:t,onCancel:n,message:r,title:i,confirmTestId:o,isLoading:s,confirmText:a="Confirm",cancelText:c="Cancel",closeOnOverlayClick:l,size:d,classNameBody:f})=>O.jsxs(ei,{classNameBody:f,size:d,isOpen:e,closeOnOverlayClick:l,onClose:n,closeIcon:O.jsx(ht,{display:"none"}),children:[O.jsx(ti,{children:i}),O.jsx(Ns,{children:O.jsx(Kt,{mt:"$8",mb:"$24",textStyle:"body2",children:r})}),O.jsx(js,{children:O.jsxs(Lt,{gap:"$16",justifyContent:"flex-end",children:[O.jsx(co,{"data-test-id":"CT_Close_Confirm",onClick:n,variant:"outline",children:c}),O.jsx(co,{"data-test-id":o,onClick:t,isLoading:s,children:a})]})})]});gl.defaultProps={message:void 0,cancelText:void 0,confirmText:void 0,confirmTestId:void 0,isLoading:void 0,closeOnOverlayClick:!0,size:"small",classNameBody:void 0};const yl=u.createContext({}),PP=({children:e})=>{const[t,n]=u.useState(!1),[r,i]=u.useState(void 0),o=()=>{n(!1),i(void 0)},s=()=>{o(),r!=null&&r.actionCallback(!0)},a=()=>{o(),r!=null&&r.actionCallback(!1)},c=u.useMemo(()=>({openDialog:({title:d,message:f,confirmText:h,cancelText:p,actionCallback:y,confirmTestId:E,size:T,isLoading:S,closeOnOverlayClick:m,classNameBody:x})=>{n(!0),i({title:d,message:f,confirmText:h,cancelText:p,confirmTestId:E,size:T,isLoading:S,actionCallback:y,closeOnOverlayClick:m,classNameBody:x})}}),[n,i]);return O.jsxs(yl.Provider,{value:c,children:[O.jsx(gl,{title:(r==null?void 0:r.title)??"",message:(r==null?void 0:r.message)??"",confirmText:r==null?void 0:r.confirmText,cancelText:r==null?void 0:r.cancelText,isOpen:t,confirmTestId:r==null?void 0:r.confirmTestId,isLoading:r==null?void 0:r.isLoading,onConfirm:s,onCancel:a,size:r==null?void 0:r.size,closeOnOverlayClick:r==null?void 0:r.closeOnOverlayClick}),e]})},RP=()=>{const{openDialog:e}=u.useContext(yl);return{confirm:async({...n})=>await new Promise(r=>{e({actionCallback:r,...n})})}},bl=({children:e,isDisabled:t,className:n})=>O.jsx("div",{className:Re(Zx({isDisabled:t}),n),children:e});bl.displayName="ActionIcon";bl.defaultProps={isDisabled:!1,className:void 0};const ni=u.forwardRef(({isError:e,isDisabled:t,required:n,isTextarea:r,children:i},o)=>O.jsxs("label",{ref:o,className:i1({state:kc({isError:e,isDisabled:t}),isTextarea:r}),children:[i,n&&"*"]}));ni.displayName="Label";ni.defaultProps={isTextarea:!1};const wl=u.forwardRef(({value:e,type:t,label:n,onClear:r,onBlur:i,isLoading:o,icon:s,isClearable:a=!0,required:c,containerStyles:l,...d},f)=>{const{addonLeft:h,addonRight:p,helperTextLeft:y,helperTextRight:E,isError:T,errorMessage:S,isDisabled:m,isValid:x,elementLeft:_,elementRight:$,className:M,...D}=d,N=!!s,j=u.useRef(null);u.useImperativeHandle(f,()=>j.current);const[K,V]=u.useState(!1),[P,v]=u.useState(!1),C=k=>{if(K){const U=j.current;U&&U.focus(),P&&(V(!1),v(!1))}else i==null||i(k)},I=()=>{const k=j.current;k&&k.focus(),P&&(V(!1),v(!1))};return u.useEffect(()=>{P&&V(!0)},[P]),O.jsxs(po,{addonLeft:h,addonRight:p,elementLeft:_,elementRight:$,helperTextLeft:y,helperTextRight:E,isError:T,errorMessage:S,isDisabled:m,isValid:x,className:l,inputAreaClassName:n1,children:[O.jsx("input",{ref:j,type:t,className:Re(t1,M),value:e,disabled:m,"data-test-id":d["data-test-id"],required:c,onBlur:C,...D}),O.jsx(ni,{isError:T,isDisabled:m,required:c,children:n}),O.jsx("div",{className:Re(r1),"data-test-id":"icon-input-area",onMouseEnter:()=>V(!0),onMouseLeave:()=>V(!1),onTouchStart:()=>v(!0),onClick:I,"aria-hidden":"true",children:O.jsxs(bl,{isDisabled:m,className:Re(a&&!o&&!N&&e1),children:[N&&!o&&s,a&&!o&&!N&&O.jsx(ls,{"data-test-id":`clear-input-${d["data-test-id"]}`,onClick:r}),o&&O.jsx(mo,{color:Et.theme.colors.green1})]})})]})});wl.displayName="Input";wl.defaultProps={type:"text",isLoading:!1,icon:void 0,onClear:void 0,isClearable:!0,containerStyles:void 0,"data-test-id":void 0};const xl=u.forwardRef(({value:e,label:t,rows:n=4,required:r,containerStyles:i,...o},s)=>{const{helperTextLeft:a,helperTextRight:c,isError:l,errorMessage:d,isDisabled:f,isValid:h,...p}=o,y=u.useRef(null);u.useImperativeHandle(s,()=>y.current);const E=()=>{var T;(T=y.current)==null||T.focus()};return O.jsxs(po,{"data-test-id":"CT_Field_Container",helperTextLeft:a,helperTextRight:c,isError:l,errorMessage:d,isDisabled:f,isValid:h,className:i,onClick:E,children:[O.jsx("textarea",{ref:y,className:Re(s1),value:e,rows:n,disabled:f,"data-test-id":o["data-test-id"],required:r,...p}),O.jsx(ni,{isTextarea:!0,isError:l,isDisabled:f,required:r,children:t})]})});xl.displayName="Textarea";xl.defaultProps={containerStyles:void 0,"data-test-id":void 0};var IP=ft({defaultClassName:"_1n7m27n0",variantClassNames:{colorScheme:{primary:"_1n7m27n1",neutral:"_1n7m27n2",danger:"_1n7m27n3",warning:"_1n7m27n4",info:"_1n7m27n5"},variant:{solid:"_1n7m27n6",outline:"_1n7m27n7"},unstyled:{true:"_1n7m27n8"}},defaultVariants:{variant:"solid",colorScheme:"primary"},compoundVariants:[[{colorScheme:"primary",variant:"outline"},"_1n7m27n9"],[{colorScheme:"neutral",variant:"outline"},"_1n7m27na"],[{colorScheme:"danger",variant:"outline"},"_1n7m27nb"],[{colorScheme:"warning",variant:"outline"},"_1n7m27nc"],[{colorScheme:"info",variant:"outline"},"_1n7m27nd"]]}),op={primary:"var(--_1qe00b2a)",neutral:"var(--_1qe00b2c)",danger:"var(--_1qe00b214)",warning:"var(--_1qe00b211)",info:"var(--_1qe00b2y)",white:"var(--_1qe00b2d)"};const El=u.forwardRef(({as:e,className:t,style:n,colorScheme:r,icon:i,unstyled:o,variant:s,isDisabled:a,isLoading:c,...l},d)=>{const f=u.useRef(null),h=hl({ref:f,colorScheme:r,variant:s});u.useImperativeHandle(d,()=>f.current);const p=e||"button";return O.jsx(p,{ref:f,as:e,"data-test-id":l["data-test-id"],className:Re(IP({colorScheme:r,unstyled:o,variant:s}),t),disabled:a,style:n,...l,children:c?O.jsx(mo,{color:s==="outline"?op[r||"primary"]:op.white}):O.jsxs(O.Fragment,{children:[h,i]})})});El.displayName="Button";El.defaultProps={as:"button","data-test-id":void 0,isDisabled:void 0,isLoading:void 0};var AP=ft({defaultClassName:"",variantClassNames:{fit:{fill:"_19yf4wk0",contain:"_19yf4wk1",cover:"_19yf4wk2","scale-down":"_19yf4wk3",none:"_19yf4wk4"}},defaultVariants:{fit:"fill"},compoundVariants:[]});const DP=({width:e=140,height:t=140,viewBox:n="0 0 140 140",...r})=>O.jsx("svg",{"data-test-id":"illustration-fallback-image",width:e,height:t,viewBox:n,fill:"none",...r,children:O.jsx("path",{d:"M85.604 0H0V140H130V43.7197L85.604 0ZM119.088 129.24H10.9305V93.2855L23.0998 101.606L48.3128 71.9816L70.6656 103.991L83.7094 86.5608L106.062 92.0123L87.2618 70.7801L71.7769 89.1789L50.5353 52.3812L22.8812 79.3877L10.9305 68.1798V10.7596H80.9767V48.0594H118.96L119.07 48.167V129.24H119.088Z",fill:"#EEEEEE"})}),Cl=u.forwardRef(({as:e,src:t,fit:n,width:r,height:i,loading:o,isLoading:s,fallback:a,onLoad:c,onError:l,className:d,"data-test-id":f,...h},p)=>{const y=e||"img",E=u.useMemo(()=>`${parseInt(`${r??0}`,10)}px`,[r]),T=u.useMemo(()=>`${parseInt(`${i??0}`,10)}px`,[i]),[S,m]=u.useState(!1),[x,_]=u.useState(n),$=D=>{_("fill"),m(!0),l==null||l(D)},M=D=>{m(!1),c==null||c(D)};return s&&!S?O.jsx(ht,{bgColor:"$grey2",width:E,height:T}):S?a||O.jsx(DP,{width:E,height:T}):O.jsx(y,{"data-test-id":f,as:"img",width:E,height:T,src:t,loading:o,onLoad:M,onError:$,ref:p,className:Re(AP({fit:x})),...h})});Cl.displayName="Image";Cl.defaultProps={as:"img","data-test-id":void 0,fallback:void 0,width:void 0,height:void 0,loading:void 0,isLoading:void 0,onLoad:void 0,onError:void 0,fit:void 0};var OP=ft({defaultClassName:"_5y0pl50",variantClassNames:{textStyle:{heading1:"_5y0pl51",heading2:"_5y0pl52",heading3:"_5y0pl53",heading4:"_5y0pl54",heading5:"_5y0pl55",heading6:"_5y0pl56",subtitle1:"_5y0pl57",subtitle2:"_5y0pl58",body1:"_5y0pl59",body2:"_5y0pl5a",caption:"_5y0pl5b",footer:"_5y0pl5c"},isDisabled:{true:"_5y0pl5d"},variant:{default:"_5y0pl5e",underline:"_5y0pl5f"},isBold:{true:"_5y0pl5g"}},defaultVariants:{variant:"default",isDisabled:!1,isBold:!1,textStyle:"body1"},compoundVariants:[]});const Dv=({children:e,className:t,variant:n,textStyle:r="body2",isDisabled:i,isBold:o,...s})=>O.jsx("a",{className:Re(t,OP({isDisabled:i,variant:n,textStyle:r,isBold:o})),"data-disabled":i,...s,children:e});var MP="_1cq2k9i0";const _l=u.forwardRef(({children:e,as:t,className:n,...r},i)=>{const o=t||"ul";return O.jsx(o,{"data-test-id":r["data-test-id"],ref:i,className:Re(MP,n),...r,children:e})});_l.displayName="List";_l.defaultProps={"data-test-id":void 0,as:"ul"};var kP=ft({defaultClassName:"xw6nfa0",variantClassNames:{hasLink:{false:"xw6nfa1"}},defaultVariants:{hasLink:!1},compoundVariants:[]}),ip="xw6nfa2",NP="xw6nfa3";const Tl=u.forwardRef(({children:e,leftIcon:t,rightIcon:n,href:r,target:i,as:o,className:s,...a},c)=>{const l=o||"li",d=!!r;return O.jsx(l,{"data-test-id":a["data-test-id"],className:Re(kP({hasLink:d}),s),...a,ref:c,children:r?O.jsxs("a",{href:r,target:i,className:NP,children:[t,O.jsx("div",{className:ip,children:e}),n]}):O.jsxs(O.Fragment,{children:[t,O.jsx("div",{className:ip,children:e}),n]})})});Tl.displayName="ListItem";Tl.defaultProps={"data-test-id":void 0,leftIcon:void 0,rightIcon:void 0,href:void 0,target:"_self",as:"li"};var Ov={},Mv={exports:{}};(function(e,t){(function(r,i){e.exports=i()})(yy,()=>(()=>{var n=[,(s,a,c)=>{c.r(a),c.d(a,{default:()=>d});var l=(()=>{var f=typeof document<"u"&&document.currentScript?document.currentScript.src:void 0;return function(h={}){var p=h,y,E;p.ready=new Promise((w,g)=>{y=w,E=g});function T(){function w(ce){const se=A;R=g=0,A=new Map,se.forEach(de=>{try{de(ce)}catch(le){console.error(le)}}),this.Qa(),Y&&Y.nb()}let g=0,R=0,A=new Map,Y=null,re=null;this.requestAnimationFrame=function(ce){g||(g=requestAnimationFrame(w.bind(this)));const se=++R;return A.set(se,ce),se},this.cancelAnimationFrame=function(ce){A.delete(ce),g&&A.size==0&&(cancelAnimationFrame(g),g=0)},this.lb=function(ce){re&&(document.body.remove(re),re=null),ce||(re=document.createElement("div"),re.style.backgroundColor="black",re.style.position="fixed",re.style.right=0,re.style.top=0,re.style.color="white",re.style.padding="4px",re.innerHTML="RIVE FPS",ce=function(se){re.innerHTML="RIVE FPS "+se.toFixed(1)},document.body.appendChild(re)),Y=new function(){let se=0,de=0;this.nb=function(){var le=performance.now();de?(++se,le-=de,1e3<le&&(ce(1e3*se/le),se=de=0)):(de=le,se=0)}}},this.ib=function(){re&&(document.body.remove(re),re=null),Y=null},this.Qa=function(){}}function S(w){console.assert(!0);const g=new Map;let R=-1/0;this.push=function(A){return A=A+((1<<w)-1)>>w,g.has(A)&&clearTimeout(g.get(A)),g.set(A,setTimeout(function(){g.delete(A),g.length==0?R=-1/0:A==R&&(R=Math.max(...g.keys()),console.assert(R<A))},1e3)),R=Math.max(A,R),R<<w}}const m=new function(){function w(){if(!g){let pt=function(Tt,Ve,Be){if(Ve=ve.createShader(Ve),ve.shaderSource(Ve,Be),ve.compileShader(Ve),Be=ve.getShaderInfoLog(Ve),0<Be.length)throw Be;ve.attachShader(Tt,Ve)};var _e=document.createElement("canvas"),ke={alpha:1,depth:0,stencil:0,antialias:0,premultipliedAlpha:1,preserveDrawingBuffer:0,preferLowPowerToHighPerformance:0,failIfMajorPerformanceCaveat:0,enableExtensionsByDefault:1,explicitSwapControl:1,renderViaOffscreenBackBuffer:1};let ve=_e.getContext("webgl2",ke);if(ve)R=2;else if(ve=_e.getContext("webgl",ke))R=1;else return console.log("No WebGL support. Image mesh will not be drawn."),!1;if(A=Math.min(ve.getParameter(ve.MAX_RENDERBUFFER_SIZE),ve.getParameter(ve.MAX_TEXTURE_SIZE)),_e=ve.createProgram(),pt(_e,ve.VERTEX_SHADER,`attribute vec2 vertex;
|
|
121
121
|
attribute vec2 uv;
|
|
122
122
|
uniform vec4 mat;
|
|
123
123
|
uniform vec2 translate;
|
|
@@ -130,19 +130,19 @@ Valid keys: `+JSON.stringify(Object.keys(W),null," "));var Z=te(B,ee,q,ne,ae+".
|
|
|
130
130
|
varying vec2 st;
|
|
131
131
|
void main() {
|
|
132
132
|
gl_FragColor = texture2D(image, st);
|
|
133
|
-
}`),ve.bindAttribLocation(_e,0,"vertex"),ve.bindAttribLocation(_e,1,"uv"),ve.linkProgram(_e),ke=ve.getProgramInfoLog(_e),0<ke.trim().length)throw ke;Y=ve.getUniformLocation(_e,"mat"),re=ve.getUniformLocation(_e,"translate"),ve.useProgram(_e),ve.bindBuffer(ve.ARRAY_BUFFER,ve.createBuffer()),ve.enableVertexAttribArray(0),ve.enableVertexAttribArray(1),ve.bindBuffer(ve.ELEMENT_ARRAY_BUFFER,ve.createBuffer()),ve.uniform1i(ve.getUniformLocation(_e,"image"),0),ve.pixelStorei(ve.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0),g=ve}return!0}let g=null,R=0,A=0,Y=null,re=null,ce=0,se=0;this.wb=function(){return b(),A},this.gb=function(_e){if(!b())return null;const ke=g.createTexture();return g.bindTexture(g.TEXTURE_2D,ke),g.texImage2D(g.TEXTURE_2D,0,g.RGBA,g.RGBA,g.UNSIGNED_BYTE,_e),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_S,g.CLAMP_TO_EDGE),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_T,g.CLAMP_TO_EDGE),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MAG_FILTER,g.LINEAR),R==2?(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,g.LINEAR_MIPMAP_LINEAR),g.generateMipmap(g.TEXTURE_2D)):g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,g.LINEAR),ke};const de=new S(8),le=new S(8),me=new S(10),Ee=new S(10);this.kb=function(_e,ke,ve,pt,Tt){if(b()){var Ve=de.push(_e),Be=le.push(ke);(g.canvas.width!=Ve||g.canvas.height!=Be)&&(g.canvas.width=Ve,g.canvas.height=Be),g.viewport(0,Be-ke,_e,ke),g.disable(g.SCISSOR_TEST),g.clearColor(0,0,0,0),g.clear(g.COLOR_BUFFER_BIT),g.enable(g.SCISSOR_TEST),ve.sort((ze,tr)=>tr.Ua-ze.Ua),Ve=me.push(pt),ce!=Ve&&(g.bufferData(g.ARRAY_BUFFER,8*Ve,g.DYNAMIC_DRAW),ce=Ve),Ve=0;for(var St of ve)g.bufferSubData(g.ARRAY_BUFFER,Ve,St.Da),Ve+=4*St.Da.length;console.assert(Ve==4*pt);for(var Jt of ve)g.bufferSubData(g.ARRAY_BUFFER,Ve,Jt.Xa),Ve+=4*Jt.Xa.length;console.assert(Ve==8*pt),Ve=Ee.push(Tt),se!=Ve&&(g.bufferData(g.ELEMENT_ARRAY_BUFFER,2*Ve,g.DYNAMIC_DRAW),se=Ve),St=0;for(var jn of ve)g.bufferSubData(g.ELEMENT_ARRAY_BUFFER,St,jn.indices),St+=2*jn.indices.length;console.assert(St==2*Tt),jn=0,Jt=!0,Ve=St=0;for(const ze of ve){ze.image.za!=jn&&(g.bindTexture(g.TEXTURE_2D,ze.image.cb||null),jn=ze.image.za),ze.zb?(g.scissor(ze.Ia,Be-ze.Ja-ze.Pa,ze.Gb,ze.Pa),Jt=!0):Jt&&(g.scissor(0,Be-ke,_e,ke),Jt=!1),ve=2/_e;const tr=-2/ke;g.uniform4f(Y,ze.oa[0]*ve*ze.va,ze.oa[1]*tr*ze.wa,ze.oa[2]*ve*ze.va,ze.oa[3]*tr*ze.wa),g.uniform2f(re,ze.oa[4]*ve*ze.va+ve*(ze.Ia-ze.xb*ze.va)-1,ze.oa[5]*tr*ze.wa+tr*(ze.Ja-ze.yb*ze.wa)+1),g.vertexAttribPointer(0,2,g.FLOAT,!1,0,Ve),g.vertexAttribPointer(1,2,g.FLOAT,!1,0,Ve+4*pt),g.drawElements(g.TRIANGLES,ze.indices.length,g.UNSIGNED_SHORT,St),Ve+=4*ze.Da.length,St+=2*ze.indices.length}console.assert(Ve==4*pt),console.assert(St==2*Tt)}},this.canvas=function(){return b()&&g.canvas}};p.onRuntimeInitialized=function(){function b(pe){switch(pe){case le.srcOver:return"source-over";case le.screen:return"screen";case le.overlay:return"overlay";case le.darken:return"darken";case le.lighten:return"lighten";case le.colorDodge:return"color-dodge";case le.colorBurn:return"color-burn";case le.hardLight:return"hard-light";case le.softLight:return"soft-light";case le.difference:return"difference";case le.exclusion:return"exclusion";case le.multiply:return"multiply";case le.hue:return"hue";case le.saturation:return"saturation";case le.color:return"color";case le.luminosity:return"luminosity"}}function g(pe){return"rgba("+((16711680&pe)>>>16)+","+((65280&pe)>>>8)+","+((255&pe)>>>0)+","+((4278190080&pe)>>>24)/255+")"}function R(){0<St.length&&(m.kb(Be.drawWidth(),Be.drawHeight(),St,Jt,jn),St=[],jn=Jt=0,Be.reset(512,512));for(const pe of Ve){for(const Oe of pe.da)Oe();pe.da=[]}Ve.clear()}var A=p.RenderPaintStyle;const Y=p.RenderPath,re=p.RenderPaint,ce=p.Renderer,se=p.StrokeCap,de=p.StrokeJoin,le=p.BlendMode,me=A.fill,Ee=A.stroke,_e=p.FillRule.evenOdd;let ke=1;var ve=p.RenderImage.extend("CanvasRenderImage",{__construct:function(){this.__parent.__construct.call(this),this.za=ke,ke=ke+1&2147483647||1},decode:function(pe){let Oe=Xs;Oe.total++;var at=this,tt=new Image;tt.src=URL.createObjectURL(new Blob([pe],{type:"image/png"})),tt.onload=function(){if(at.ab=tt,at.cb=m.gb(tt),at.size(tt.width,tt.height),Oe.loaded++,Oe.loaded===Oe.total){const ct=Oe.ready;ct&&(ct(),Oe.ready=null)}}}}),pt=Y.extend("CanvasRenderPath",{__construct:function(){this.__parent.__construct.call(this),this.ia=new Path2D},rewind:function(){this.ia=new Path2D},addPath:function(pe,Oe,at,tt,ct,bt,Ze){var rt=this.ia,ln=rt.addPath;pe=pe.ia;const Dt=new DOMMatrix;Dt.a=Oe,Dt.b=at,Dt.c=tt,Dt.d=ct,Dt.e=bt,Dt.f=Ze,ln.call(rt,pe,Dt)},fillRule:function(pe){this.Ga=pe},moveTo:function(pe,Oe){this.ia.moveTo(pe,Oe)},lineTo:function(pe,Oe){this.ia.lineTo(pe,Oe)},cubicTo:function(pe,Oe,at,tt,ct,bt){this.ia.bezierCurveTo(pe,Oe,at,tt,ct,bt)},close:function(){this.ia.closePath()}}),Tt=re.extend("CanvasRenderPaint",{color:function(pe){this.Ha=g(pe)},thickness:function(pe){this.eb=pe},join:function(pe){switch(pe){case de.miter:this.ya="miter";break;case de.round:this.ya="round";break;case de.bevel:this.ya="bevel"}},cap:function(pe){switch(pe){case se.butt:this.xa="butt";break;case se.round:this.xa="round";break;case se.square:this.xa="square"}},style:function(pe){this.bb=pe},blendMode:function(pe){this.$a=b(pe)},clearGradient:function(){this.qa=null},linearGradient:function(pe,Oe,at,tt){this.qa={Va:pe,Wa:Oe,La:at,Ma:tt,Ca:[]}},radialGradient:function(pe,Oe,at,tt){this.qa={Va:pe,Wa:Oe,La:at,Ma:tt,Ca:[],ub:!0}},addStop:function(pe,Oe){this.qa.Ca.push({color:pe,stop:Oe})},completeGradient:function(){},draw:function(pe,Oe,at){let tt=this.bb;var ct=this.Ha,bt=this.qa;if(pe.globalCompositeOperation=this.$a,bt!=null){ct=bt.Va;var Ze=bt.Wa;const ln=bt.La;var rt=bt.Ma;const Dt=bt.Ca;bt.ub?(bt=ln-ct,rt-=Ze,ct=pe.createRadialGradient(ct,Ze,0,ct,Ze,Math.sqrt(bt*bt+rt*rt))):ct=pe.createLinearGradient(ct,Ze,ln,rt);for(let Tn=0,kt=Dt.length;Tn<kt;Tn++)Ze=Dt[Tn],ct.addColorStop(Ze.stop,g(Ze.color));this.Ha=ct,this.qa=null}switch(tt){case Ee:pe.strokeStyle=ct,pe.lineWidth=this.eb,pe.lineCap=this.xa,pe.lineJoin=this.ya,pe.stroke(Oe);break;case me:pe.fillStyle=ct,pe.fill(Oe,at)}}});const Ve=new Set;let Be=null,St=[],Jt=0,jn=0;var ze=p.CanvasRenderer=ce.extend("Renderer",{__construct:function(pe){this.__parent.__construct.call(this),this.ha=[1,0,0,1,0,0],this.ba=pe.getContext("2d"),this.Fa=pe,this.da=[]},save:function(){this.ha.push(...this.ha.slice(this.ha.length-6)),this.da.push(this.ba.save.bind(this.ba))},restore:function(){const pe=this.ha.length-6;if(6>pe)throw"restore() called without matching save().";this.ha.splice(pe),this.da.push(this.ba.restore.bind(this.ba))},transform:function(pe,Oe,at,tt,ct,bt){const Ze=this.ha,rt=Ze.length-6;Ze.splice(rt,6,Ze[rt]*pe+Ze[rt+2]*Oe,Ze[rt+1]*pe+Ze[rt+3]*Oe,Ze[rt]*at+Ze[rt+2]*tt,Ze[rt+1]*at+Ze[rt+3]*tt,Ze[rt]*ct+Ze[rt+2]*bt+Ze[rt+4],Ze[rt+1]*ct+Ze[rt+3]*bt+Ze[rt+5]),this.da.push(this.ba.transform.bind(this.ba,pe,Oe,at,tt,ct,bt))},rotate:function(pe){const Oe=Math.sin(pe);pe=Math.cos(pe),this.transform(pe,Oe,-Oe,pe,0,0)},_drawPath:function(pe,Oe){this.da.push(Oe.draw.bind(Oe,this.ba,pe.ia,pe.Ga===_e?"evenodd":"nonzero"))},drawImage:function(pe,...Oe){var at=this.ba;this.da.push(function(){at.drawImage(pe,...Oe)})},_drawRiveImage:function(pe,Oe,at){var tt=pe.ab;if(tt){var ct=this.ba,bt=b(Oe);this.da.push(function(){ct.globalCompositeOperation=bt,ct.globalAlpha=at,ct.drawImage(tt,0,0),ct.globalAlpha=1})}},_getMatrix:function(pe){const Oe=this.ha,at=Oe.length-6;for(let tt=0;6>tt;++tt)pe[tt]=Oe[at+tt]},_drawImageMesh:function(pe,Oe,at,tt,ct,bt,Ze,rt,ln,Dt){var Tn=this.ba.canvas.width,kt=this.ba.canvas.height;const Ou=ln-Ze,Mu=Dt-rt;Ze=Math.max(Ze,0),rt=Math.max(rt,0),ln=Math.min(ln,Tn),Dt=Math.min(Dt,kt);const go=ln-Ze,yo=Dt-rt;if(console.assert(go<=Math.min(Ou,Tn)),console.assert(yo<=Math.min(Mu,kt)),!(0>=go||0>=yo)){ln=go<Ou||yo<Mu,Tn=Dt=1;var wr=Math.ceil(go*Dt),xr=Math.ceil(yo*Tn);kt=m.wb(),wr>kt&&(Dt*=kt/wr,wr=kt),xr>kt&&(Tn*=kt/xr,xr=kt),Be||(Be=new p.DynamicRectanizer(kt),Be.reset(512,512)),kt=Be.addRect(wr,xr),0>kt&&(R(),Ve.add(this),kt=Be.addRect(wr,xr),console.assert(0<=kt));var ku=kt&65535,Nu=kt>>16;St.push({oa:this.ha.slice(this.ha.length-6),image:pe,Ia:ku,Ja:Nu,xb:Ze,yb:rt,Gb:wr,Pa:xr,va:Dt,wa:Tn,Da:new Float32Array(tt),Xa:new Float32Array(ct),indices:new Uint16Array(bt),zb:ln,Ua:pe.za<<1|(ln?1:0)}),Jt+=tt.length,jn+=bt.length;var Hr=this.ba,vy=b(Oe);this.da.push(function(){Hr.save(),Hr.resetTransform(),Hr.globalCompositeOperation=vy,Hr.globalAlpha=at,Hr.drawImage(m.canvas(),ku,Nu,wr,xr,Ze,rt,go,yo),Hr.restore()})}},_clipPath:function(pe){this.da.push(this.ba.clip.bind(this.ba,pe.ia,pe.Ga===_e?"evenodd":"nonzero"))},clear:function(){Ve.add(this),this.da.push(this.ba.clearRect.bind(this.ba,0,0,this.Fa.width,this.Fa.height))},flush:function(){},translate:function(pe,Oe){this.transform(1,0,0,1,pe,Oe)}});p.makeRenderer=function(pe){return new ze(pe)},p.renderFactory={makeRenderPaint:function(){return new Tt},makeRenderPath:function(){return new pt},makeRenderImage:function(){return new ve}};let tr=p.load,Xs=null;p.load=function(pe){return new Promise(function(Oe){let at=null;Xs={total:0,loaded:0,ready:function(){Oe(at)}},at=tr(pe),Xs.total==0&&Oe(at)})},A=new T,p.requestAnimationFrame=A.requestAnimationFrame.bind(A),p.cancelAnimationFrame=A.cancelAnimationFrame.bind(A),p.enableFPSCounter=A.lb.bind(A),p.disableFPSCounter=A.ib,A.Qa=R,p.cleanup=function(){Be&&Be.delete()}};var x=Object.assign({},p),_="./this.program",$=typeof window=="object",O=typeof importScripts=="function",M="",N,j;($||O)&&(O?M=self.location.href:typeof document<"u"&&document.currentScript&&(M=document.currentScript.src),f&&(M=f),M.indexOf("blob:")!==0?M=M.substr(0,M.replace(/[?#].*/,"").lastIndexOf("/")+1):M="",O&&(j=b=>{var g=new XMLHttpRequest;return g.open("GET",b,!1),g.responseType="arraybuffer",g.send(null),new Uint8Array(g.response)}),N=(b,g,R)=>{var A=new XMLHttpRequest;A.open("GET",b,!0),A.responseType="arraybuffer",A.onload=()=>{A.status==200||A.status==0&&A.response?g(A.response):R()},A.onerror=R,A.send(null)});var K=p.print||console.log.bind(console),V=p.printErr||console.error.bind(console);Object.assign(p,x),x=null,p.thisProgram&&(_=p.thisProgram);var P;p.wasmBinary&&(P=p.wasmBinary),p.noExitRuntime,typeof WebAssembly!="object"&&te("no native wasm support detected");var v,C=!1,I,k,U,G,ue,W,L,oe;function X(){var b=v.buffer;p.HEAP8=I=new Int8Array(b),p.HEAP16=U=new Int16Array(b),p.HEAP32=ue=new Int32Array(b),p.HEAPU8=k=new Uint8Array(b),p.HEAPU16=G=new Uint16Array(b),p.HEAPU32=W=new Uint32Array(b),p.HEAPF32=L=new Float32Array(b),p.HEAPF64=oe=new Float64Array(b)}var q,ne=[],ae=[],B=[];function H(){var b=p.preRun.shift();ne.unshift(b)}var J=0,ee=null;function te(b){throw p.onAbort&&p.onAbort(b),b="Aborted("+b+")",V(b),C=!0,b=new WebAssembly.RuntimeError(b+". Build with -sASSERTIONS for more info."),E(b),b}function Z(b){return b.startsWith("data:application/octet-stream;base64,")}var ge;if(ge="canvas_advanced.wasm",!Z(ge)){var Te=ge;ge=p.locateFile?p.locateFile(Te,M):M+Te}function Ie(b){if(b==ge&&P)return new Uint8Array(P);if(j)return j(b);throw"both async and sync fetching of the wasm failed"}function Ae(b){if(!P&&($||O)){if(typeof fetch=="function"&&!b.startsWith("file://"))return fetch(b,{credentials:"same-origin"}).then(g=>{if(!g.ok)throw"failed to load wasm binary file at '"+b+"'";return g.arrayBuffer()}).catch(()=>Ie(b));if(N)return new Promise((g,R)=>{N(b,A=>g(new Uint8Array(A)),R)})}return Promise.resolve().then(()=>Ie(b))}function $e(b,g,R){return Ae(b).then(A=>WebAssembly.instantiate(A,g)).then(A=>A).then(R,A=>{V("failed to asynchronously prepare wasm: "+A),te(A)})}function Ye(b,g){var R=ge;return P||typeof WebAssembly.instantiateStreaming!="function"||Z(R)||R.startsWith("file://")||typeof fetch!="function"?$e(R,b,g):fetch(R,{credentials:"same-origin"}).then(A=>WebAssembly.instantiateStreaming(A,b).then(g,function(Y){return V("wasm streaming compile failed: "+Y),V("falling back to ArrayBuffer instantiation"),$e(R,b,g)}))}var je=b=>{for(;0<b.length;)b.shift()(p)};function vt(b){if(b===void 0)return"_unknown";b=b.replace(/[^a-zA-Z0-9_]/g,"$");var g=b.charCodeAt(0);return 48<=g&&57>=g?`_${b}`:b}function Xe(b,g){return b=vt(b),{[b]:function(){return g.apply(this,arguments)}}[b]}function Rt(){this.ja=[void 0],this.Oa=[]}var st=new Rt,Ft=void 0;function Pe(b){throw new Ft(b)}var Ot=b=>(b||Pe("Cannot use deleted val. handle = "+b),st.get(b).value),gt=b=>{switch(b){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:return st.Ya({Ta:1,value:b})}};function bn(b){var g=Error,R=Xe(b,function(A){this.name=b,this.message=A,A=Error(A).stack,A!==void 0&&(this.stack=this.toString()+`
|
|
134
|
-
`+A.replace(/^Error(:[^\n]*)?\n/,""))});return R.prototype=Object.create(g.prototype),R.prototype.constructor=R,R.prototype.toString=function(){return this.message===void 0?this.name:`${this.name}: ${this.message}`},R}var Xt=void 0,Nt=void 0;function Fe(b){for(var g="";k[b];)g+=Nt[k[b++]];return g}var Mt=[];function Gt(){for(;Mt.length;){var b=Mt.pop();b.W.na=!1,b.delete()}}var On=void 0,Zt={};function yr(b,g){for(g===void 0&&Pe("ptr should not be undefined");b.$;)g=b.ra(g),b=b.$;return g}var mn={};function Br(b){b=Au(b);var g=Fe(b);return Nn(b),g}function Qt(b,g){var R=mn[b];return R===void 0&&Pe(g+" has unknown type "+Br(b)),R}function wn(){}var jt=!1;function xn(b){--b.count.value,b.count.value===0&&(b.ca?b.fa.ka(b.ca):b.Z.X.ka(b.Y))}function En(b,g,R){return g===R?b:R.$===void 0?null:(b=En(b,g,R.$),b===null?null:R.jb(b))}var Xn={};function vo(b,g){return g=yr(b,g),Zt[g]}var Gn=void 0;function Zn(b){throw new Gn(b)}function Cn(b,g){return g.Z&&g.Y||Zn("makeClassHandle requires ptr and ptrType"),!!g.fa!=!!g.ca&&Zn("Both smartPtrType and smartPtr must be specified"),g.count={value:1},cn(Object.create(b,{W:{value:g}}))}function cn(b){return typeof FinalizationRegistry>"u"?(cn=g=>g,b):(jt=new FinalizationRegistry(g=>{xn(g.W)}),cn=g=>{var R=g.W;return R.ca&&jt.register(g,{W:R},g),g},wn=g=>{jt.unregister(g)},cn(b))}var Qn={};function Mn(b){for(;b.length;){var g=b.pop();b.pop()(g)}}function vn(b){return this.fromWireType(ue[b>>2])}var _n={},Jn={};function Vt(b,g,R){function A(se){se=R(se),se.length!==b.length&&Zn("Mismatched type converter count");for(var de=0;de<b.length;++de)F(b[de],se[de])}b.forEach(function(se){Jn[se]=g});var Y=Array(g.length),re=[],ce=0;g.forEach((se,de)=>{mn.hasOwnProperty(se)?Y[de]=mn[se]:(re.push(se),_n.hasOwnProperty(se)||(_n[se]=[]),_n[se].push(()=>{Y[de]=mn[se],++ce,ce===re.length&&A(Y)}))}),re.length===0&&A(Y)}function er(b){switch(b){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError(`Unknown type size: ${b}`)}}function y(b,g,R={}){var A=g.name;if(b||Pe(`type "${A}" must have a positive integer typeid pointer`),mn.hasOwnProperty(b)){if(R.tb)return;Pe(`Cannot register type '${A}' twice`)}mn[b]=g,delete Jn[b],_n.hasOwnProperty(b)&&(g=_n[b],delete _n[b],g.forEach(Y=>Y()))}function F(b,g,R={}){if(!("argPackAdvance"in g))throw new TypeError("registerType registeredInstance requires argPackAdvance");y(b,g,R)}function Q(b){Pe(b.W.Z.X.name+" instance already deleted")}function fe(){}function xe(b,g,R){if(b[g].aa===void 0){var A=b[g];b[g]=function(){return b[g].aa.hasOwnProperty(arguments.length)||Pe(`Function '${R}' called with an invalid number of arguments (${arguments.length}) - expects one of (${b[g].aa})!`),b[g].aa[arguments.length].apply(this,arguments)},b[g].aa=[],b[g].aa[A.ma]=A}}function Se(b,g,R){p.hasOwnProperty(b)?((R===void 0||p[b].aa!==void 0&&p[b].aa[R]!==void 0)&&Pe(`Cannot register public name '${b}' twice`),xe(p,b,b),p.hasOwnProperty(R)&&Pe(`Cannot register multiple overloads of a function with the same number of arguments (${R})!`),p[b].aa[R]=g):(p[b]=g,R!==void 0&&(p[b].Hb=R))}function be(b,g,R,A,Y,re,ce,se){this.name=b,this.constructor=g,this.ga=R,this.ka=A,this.$=Y,this.ob=re,this.ra=ce,this.jb=se,this.Ra=[]}function ye(b,g,R){for(;g!==R;)g.ra||Pe(`Expected null or instance of ${R.name}, got an instance of ${g.name}`),b=g.ra(b),g=g.$;return b}function Ge(b,g){return g===null?(this.Aa&&Pe(`null is not a valid ${this.name}`),0):(g.W||Pe(`Cannot pass "${Ys(g)}" as a ${this.name}`),g.W.Y||Pe(`Cannot pass deleted object as a pointer of type ${this.name}`),ye(g.W.Y,g.W.Z.X,this.X))}function Ne(b,g){if(g===null){if(this.Aa&&Pe(`null is not a valid ${this.name}`),this.ua){var R=this.Ba();return b!==null&&b.push(this.ka,R),R}return 0}if(g.W||Pe(`Cannot pass "${Ys(g)}" as a ${this.name}`),g.W.Y||Pe(`Cannot pass deleted object as a pointer of type ${this.name}`),!this.ta&&g.W.Z.ta&&Pe(`Cannot convert argument of type ${g.W.fa?g.W.fa.name:g.W.Z.name} to parameter type ${this.name}`),R=ye(g.W.Y,g.W.Z.X,this.X),this.ua)switch(g.W.ca===void 0&&Pe("Passing raw pointer to smart pointer is illegal"),this.Fb){case 0:g.W.fa===this?R=g.W.ca:Pe(`Cannot convert argument of type ${g.W.fa?g.W.fa.name:g.W.Z.name} to parameter type ${this.name}`);break;case 1:R=g.W.ca;break;case 2:if(g.W.fa===this)R=g.W.ca;else{var A=g.clone();R=this.Bb(R,gt(function(){A.delete()})),b!==null&&b.push(this.ka,R)}break;default:Pe("Unsupporting sharing policy")}return R}function Le(b,g){return g===null?(this.Aa&&Pe(`null is not a valid ${this.name}`),0):(g.W||Pe(`Cannot pass "${Ys(g)}" as a ${this.name}`),g.W.Y||Pe(`Cannot pass deleted object as a pointer of type ${this.name}`),g.W.Z.ta&&Pe(`Cannot convert argument of type ${g.W.Z.name} to parameter type ${this.name}`),ye(g.W.Y,g.W.Z.X,this.X))}function Ue(b,g,R,A){this.name=b,this.X=g,this.Aa=R,this.ta=A,this.ua=!1,this.ka=this.Bb=this.Ba=this.Sa=this.Fb=this.Ab=void 0,g.$!==void 0?this.toWireType=Ne:(this.toWireType=A?Ge:Le,this.ea=null)}function Bt(b,g,R){p.hasOwnProperty(b)||Zn("Replacing nonexistant public symbol"),p[b].aa!==void 0&&R!==void 0?p[b].aa[R]=g:(p[b]=g,p[b].ma=R)}var br=(b,g)=>{var R=[];return function(){if(R.length=0,Object.assign(R,arguments),b.includes("j")){var A=p["dynCall_"+b];A=R&&R.length?A.apply(null,[g].concat(R)):A.call(null,g)}else A=q.get(g).apply(null,R);return A}};function We(b,g){b=Fe(b);var R=b.includes("j")?br(b,g):q.get(g);return typeof R!="function"&&Pe(`unknown function pointer with signature ${b}: ${g}`),R}var Cu=void 0;function kn(b,g){function R(re){Y[re]||mn[re]||(Jn[re]?Jn[re].forEach(R):(A.push(re),Y[re]=!0))}var A=[],Y={};throw g.forEach(R),new Cu(`${b}: `+A.map(Br).join([", "]))}function ri(b,g,R,A,Y){var re=g.length;2>re&&Pe("argTypes array size mismatch! Must at least get return value and 'this' types!");var ce=g[1]!==null&&R!==null,se=!1;for(R=1;R<g.length;++R)if(g[R]!==null&&g[R].ea===void 0){se=!0;break}var de=g[0].name!=="void",le=re-2,me=Array(le),Ee=[],_e=[];return function(){if(arguments.length!==le&&Pe(`function ${b} called with ${arguments.length} arguments, expected ${le} args!`),_e.length=0,Ee.length=ce?2:1,Ee[0]=Y,ce){var ke=g[1].toWireType(_e,this);Ee[1]=ke}for(var ve=0;ve<le;++ve)me[ve]=g[ve+2].toWireType(_e,arguments[ve]),Ee.push(me[ve]);if(ve=A.apply(null,Ee),se)Mn(_e);else for(var pt=ce?1:2;pt<g.length;pt++){var Tt=pt===1?ke:me[pt-2];g[pt].ea!==null&&g[pt].ea(Tt)}return ke=de?g[0].fromWireType(ve):void 0,ke}}function oi(b,g){for(var R=[],A=0;A<b;A++)R.push(W[g+4*A>>2]);return R}function _u(b,g,R){return b instanceof Object||Pe(`${R} with invalid "this": ${b}`),b instanceof g.X.constructor||Pe(`${R} incompatible with "this" of type ${b.constructor.name}`),b.W.Y||Pe(`cannot call emscripten binding method ${R} on deleted object`),ye(b.W.Y,b.W.Z.X,g.X)}function Us(b){b>=st.Ea&&--st.get(b).Ta===0&&st.Za(b)}function ny(b,g,R){switch(g){case 0:return function(A){return this.fromWireType((R?I:k)[A])};case 1:return function(A){return this.fromWireType((R?U:G)[A>>1])};case 2:return function(A){return this.fromWireType((R?ue:W)[A>>2])};default:throw new TypeError("Unknown integer type: "+b)}}function Ys(b){if(b===null)return"null";var g=typeof b;return g==="object"||g==="array"||g==="function"?b.toString():""+b}function ry(b,g){switch(g){case 2:return function(R){return this.fromWireType(L[R>>2])};case 3:return function(R){return this.fromWireType(oe[R>>3])};default:throw new TypeError("Unknown float type: "+b)}}function oy(b,g,R){switch(g){case 0:return R?function(A){return I[A]}:function(A){return k[A]};case 1:return R?function(A){return U[A>>1]}:function(A){return G[A>>1]};case 2:return R?function(A){return ue[A>>2]}:function(A){return W[A>>2]};default:throw new TypeError("Unknown integer type: "+b)}}var Tu=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0,Su=(b,g,R)=>{var A=g+R;for(R=g;b[R]&&!(R>=A);)++R;if(16<R-g&&b.buffer&&Tu)return Tu.decode(b.subarray(g,R));for(A="";g<R;){var Y=b[g++];if(Y&128){var re=b[g++]&63;if((Y&224)==192)A+=String.fromCharCode((Y&31)<<6|re);else{var ce=b[g++]&63;Y=(Y&240)==224?(Y&15)<<12|re<<6|ce:(Y&7)<<18|re<<12|ce<<6|b[g++]&63,65536>Y?A+=String.fromCharCode(Y):(Y-=65536,A+=String.fromCharCode(55296|Y>>10,56320|Y&1023))}}else A+=String.fromCharCode(Y)}return A},$u=typeof TextDecoder<"u"?new TextDecoder("utf-16le"):void 0,iy=(b,g)=>{for(var R=b>>1,A=R+g/2;!(R>=A)&&G[R];)++R;if(R<<=1,32<R-b&&$u)return $u.decode(k.subarray(b,R));for(R="",A=0;!(A>=g/2);++A){var Y=U[b+2*A>>1];if(Y==0)break;R+=String.fromCharCode(Y)}return R},sy=(b,g,R)=>{if(R===void 0&&(R=2147483647),2>R)return 0;R-=2;var A=g;R=R<2*b.length?R/2:b.length;for(var Y=0;Y<R;++Y)U[g>>1]=b.charCodeAt(Y),g+=2;return U[g>>1]=0,g-A},ay=b=>2*b.length,cy=(b,g)=>{for(var R=0,A="";!(R>=g/4);){var Y=ue[b+4*R>>2];if(Y==0)break;++R,65536<=Y?(Y-=65536,A+=String.fromCharCode(55296|Y>>10,56320|Y&1023)):A+=String.fromCharCode(Y)}return A},ly=(b,g,R)=>{if(R===void 0&&(R=2147483647),4>R)return 0;var A=g;R=A+R-4;for(var Y=0;Y<b.length;++Y){var re=b.charCodeAt(Y);if(55296<=re&&57343>=re){var ce=b.charCodeAt(++Y);re=65536+((re&1023)<<10)|ce&1023}if(ue[g>>2]=re,g+=4,g+4>R)break}return ue[g>>2]=0,g-A},uy=b=>{for(var g=0,R=0;R<b.length;++R){var A=b.charCodeAt(R);55296<=A&&57343>=A&&++R,g+=4}return g},dy={};function ii(b){var g=dy[b];return g===void 0?Fe(b):g}var si=[];function fy(b){var g=si.length;return si.push(b),g}function py(b,g){for(var R=Array(b),A=0;A<b;++A)R[A]=Qt(W[g+4*A>>2],"parameter "+A);return R}var Pu=[],zs={},Ru=()=>{if(!Ks){var b={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:(typeof navigator=="object"&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:_||"./this.program"},g;for(g in zs)zs[g]===void 0?delete b[g]:b[g]=zs[g];var R=[];for(g in b)R.push(`${g}=${b[g]}`);Ks=R}return Ks},Ks,hy=[null,[],[]];Object.assign(Rt.prototype,{get(b){return this.ja[b]},has(b){return this.ja[b]!==void 0},Ya(b){var g=this.Oa.pop()||this.ja.length;return this.ja[g]=b,g},Za(b){this.ja[b]=void 0,this.Oa.push(b)}}),Ft=p.BindingError=class extends Error{constructor(b){super(b),this.name="BindingError"}},st.ja.push({value:void 0},{value:null},{value:!0},{value:!1}),st.Ea=st.ja.length,p.count_emval_handles=function(){for(var b=0,g=st.Ea;g<st.ja.length;++g)st.ja[g]!==void 0&&++b;return b},Xt=p.PureVirtualError=bn("PureVirtualError");for(var Iu=Array(256),ai=0;256>ai;++ai)Iu[ai]=String.fromCharCode(ai);Nt=Iu,p.getInheritedInstanceCount=function(){return Object.keys(Zt).length},p.getLiveInheritedInstances=function(){var b=[],g;for(g in Zt)Zt.hasOwnProperty(g)&&b.push(Zt[g]);return b},p.flushPendingDeletes=Gt,p.setDelayFunction=function(b){On=b,Mt.length&&On&&On(Gt)},Gn=p.InternalError=class extends Error{constructor(b){super(b),this.name="InternalError"}},fe.prototype.isAliasOf=function(b){if(!(this instanceof fe&&b instanceof fe))return!1;var g=this.W.Z.X,R=this.W.Y,A=b.W.Z.X;for(b=b.W.Y;g.$;)R=g.ra(R),g=g.$;for(;A.$;)b=A.ra(b),A=A.$;return g===A&&R===b},fe.prototype.clone=function(){if(this.W.Y||Q(this),this.W.pa)return this.W.count.value+=1,this;var b=cn,g=Object,R=g.create,A=Object.getPrototypeOf(this),Y=this.W;return b=b(R.call(g,A,{W:{value:{count:Y.count,na:Y.na,pa:Y.pa,Y:Y.Y,Z:Y.Z,ca:Y.ca,fa:Y.fa}}})),b.W.count.value+=1,b.W.na=!1,b},fe.prototype.delete=function(){this.W.Y||Q(this),this.W.na&&!this.W.pa&&Pe("Object already scheduled for deletion"),wn(this),xn(this.W),this.W.pa||(this.W.ca=void 0,this.W.Y=void 0)},fe.prototype.isDeleted=function(){return!this.W.Y},fe.prototype.deleteLater=function(){return this.W.Y||Q(this),this.W.na&&!this.W.pa&&Pe("Object already scheduled for deletion"),Mt.push(this),Mt.length===1&&On&&On(Gt),this.W.na=!0,this},Ue.prototype.pb=function(b){return this.Sa&&(b=this.Sa(b)),b},Ue.prototype.Ka=function(b){this.ka&&this.ka(b)},Ue.prototype.argPackAdvance=8,Ue.prototype.readValueFromPointer=vn,Ue.prototype.deleteObject=function(b){b!==null&&b.delete()},Ue.prototype.fromWireType=function(b){function g(){return this.ua?Cn(this.X.ga,{Z:this.Ab,Y:R,fa:this,ca:b}):Cn(this.X.ga,{Z:this,Y:b})}var R=this.pb(b);if(!R)return this.Ka(b),null;var A=vo(this.X,R);if(A!==void 0)return A.W.count.value===0?(A.W.Y=R,A.W.ca=b,A.clone()):(A=A.clone(),this.Ka(b),A);if(A=this.X.ob(R),A=Xn[A],!A)return g.call(this);A=this.ta?A.fb:A.pointerType;var Y=En(R,this.X,A.X);return Y===null?g.call(this):this.ua?Cn(A.X.ga,{Z:A,Y,fa:this,ca:b}):Cn(A.X.ga,{Z:A,Y})},Cu=p.UnboundTypeError=bn("UnboundTypeError");var my={I:function(b,g,R){b=Fe(b),g=Qt(g,"wrapper"),R=Ot(R);var A=[].slice,Y=g.X,re=Y.ga,ce=Y.$.ga,se=Y.$.constructor;b=Xe(b,function(){Y.$.Ra.forEach((function(le){if(this[le]===ce[le])throw new Xt(`Pure virtual function ${le} must be implemented in JavaScript`)}).bind(this)),Object.defineProperty(this,"__parent",{value:re}),this.__construct.apply(this,A.call(arguments))}),re.__construct=function(){this===re&&Pe("Pass correct 'this' to __construct");var le=se.implement.apply(void 0,[this].concat(A.call(arguments)));wn(le);var me=le.W;le.notifyOnDestruction(),me.pa=!0,Object.defineProperties(this,{W:{value:me}}),cn(this),le=me.Y,le=yr(Y,le),Zt.hasOwnProperty(le)?Pe(`Tried to register registered instance: ${le}`):Zt[le]=this},re.__destruct=function(){this===re&&Pe("Pass correct 'this' to __destruct"),wn(this);var le=this.W.Y;le=yr(Y,le),Zt.hasOwnProperty(le)?delete Zt[le]:Pe(`Tried to unregister unregistered instance: ${le}`)},b.prototype=Object.create(re);for(var de in R)b.prototype[de]=R[de];return gt(b)},L:function(b){var g=Qn[b];delete Qn[b];var R=g.Ba,A=g.ka,Y=g.Na,re=Y.map(ce=>ce.sb).concat(Y.map(ce=>ce.Db));Vt([b],re,ce=>{var se={};return Y.forEach((de,le)=>{var me=ce[le],Ee=de.qb,_e=de.rb,ke=ce[le+Y.length],ve=de.Cb,pt=de.Eb;se[de.mb]={read:Tt=>me.fromWireType(Ee(_e,Tt)),write:(Tt,Ve)=>{var Be=[];ve(pt,Tt,ke.toWireType(Be,Ve)),Mn(Be)}}}),[{name:g.name,fromWireType:function(de){var le={},me;for(me in se)le[me]=se[me].read(de);return A(de),le},toWireType:function(de,le){for(var me in se)if(!(me in le))throw new TypeError(`Missing field: "${me}"`);var Ee=R();for(me in se)se[me].write(Ee,le[me]);return de!==null&&de.push(A,Ee),Ee},argPackAdvance:8,readValueFromPointer:vn,ea:A}]})},z:function(){},G:function(b,g,R,A,Y){var re=er(R);g=Fe(g),F(b,{name:g,fromWireType:function(ce){return!!ce},toWireType:function(ce,se){return se?A:Y},argPackAdvance:8,readValueFromPointer:function(ce){if(R===1)var se=I;else if(R===2)se=U;else if(R===4)se=ue;else throw new TypeError("Unknown boolean type size: "+g);return this.fromWireType(se[ce>>re])},ea:null})},e:function(b,g,R,A,Y,re,ce,se,de,le,me,Ee,_e){me=Fe(me),re=We(Y,re),se&&(se=We(ce,se)),le&&(le=We(de,le)),_e=We(Ee,_e);var ke=vt(me);Se(ke,function(){kn(`Cannot construct ${me} due to unbound types`,[A])}),Vt([b,g,R],A?[A]:[],function(ve){if(ve=ve[0],A)var pt=ve.X,Tt=pt.ga;else Tt=fe.prototype;ve=Xe(ke,function(){if(Object.getPrototypeOf(this)!==Ve)throw new Ft("Use 'new' to construct "+me);if(Be.la===void 0)throw new Ft(me+" has no accessible constructor");var Jt=Be.la[arguments.length];if(Jt===void 0)throw new Ft(`Tried to invoke ctor of ${me} with invalid number of parameters (${arguments.length}) - expected (${Object.keys(Be.la).toString()}) parameters instead!`);return Jt.apply(this,arguments)});var Ve=Object.create(Tt,{constructor:{value:ve}});ve.prototype=Ve;var Be=new be(me,ve,Ve,_e,pt,re,se,le);Be.$&&(Be.$.sa===void 0&&(Be.$.sa=[]),Be.$.sa.push(Be)),pt=new Ue(me,Be,!0,!1),Tt=new Ue(me+"*",Be,!1,!1);var St=new Ue(me+" const*",Be,!1,!0);return Xn[b]={pointerType:Tt,fb:St},Bt(ke,ve),[pt,Tt,St]})},k:function(b,g,R,A,Y,re,ce){var se=oi(R,A);g=Fe(g),re=We(Y,re),Vt([],[b],function(de){function le(){kn(`Cannot call ${me} due to unbound types`,se)}de=de[0];var me=`${de.name}.${g}`;g.startsWith("@@")&&(g=Symbol[g.substring(2)]);var Ee=de.X.constructor;return Ee[g]===void 0?(le.ma=R-1,Ee[g]=le):(xe(Ee,g,me),Ee[g].aa[R-1]=le),Vt([],se,function(_e){if(_e=ri(me,[_e[0],null].concat(_e.slice(1)),null,re,ce),Ee[g].aa===void 0?(_e.ma=R-1,Ee[g]=_e):Ee[g].aa[R-1]=_e,de.X.sa)for(const ke of de.X.sa)ke.constructor.hasOwnProperty(g)||(ke.constructor[g]=_e);return[]}),[]})},s:function(b,g,R,A,Y,re,ce,se){g=Fe(g),re=We(Y,re),Vt([],[b],function(de){de=de[0];var le=`${de.name}.${g}`,me={get(){kn(`Cannot access ${le} due to unbound types`,[R])},enumerable:!0,configurable:!0};return me.set=se?()=>{kn(`Cannot access ${le} due to unbound types`,[R])}:()=>{Pe(`${le} is a read-only property`)},Object.defineProperty(de.X.constructor,g,me),Vt([],[R],function(Ee){Ee=Ee[0];var _e={get(){return Ee.fromWireType(re(A))},enumerable:!0};return se&&(se=We(ce,se),_e.set=ke=>{var ve=[];se(A,Ee.toWireType(ve,ke)),Mn(ve)}),Object.defineProperty(de.X.constructor,g,_e),[]}),[]})},o:function(b,g,R,A,Y,re){var ce=oi(g,R);Y=We(A,Y),Vt([],[b],function(se){se=se[0];var de=`constructor ${se.name}`;if(se.X.la===void 0&&(se.X.la=[]),se.X.la[g-1]!==void 0)throw new Ft(`Cannot register multiple constructors with identical number of parameters (${g-1}) for class '${se.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return se.X.la[g-1]=()=>{kn(`Cannot construct ${se.name} due to unbound types`,ce)},Vt([],ce,function(le){return le.splice(1,0,null),se.X.la[g-1]=ri(de,le,null,Y,re),[]}),[]})},a:function(b,g,R,A,Y,re,ce,se){var de=oi(R,A);g=Fe(g),re=We(Y,re),Vt([],[b],function(le){function me(){kn(`Cannot call ${Ee} due to unbound types`,de)}le=le[0];var Ee=`${le.name}.${g}`;g.startsWith("@@")&&(g=Symbol[g.substring(2)]),se&&le.X.Ra.push(g);var _e=le.X.ga,ke=_e[g];return ke===void 0||ke.aa===void 0&&ke.className!==le.name&&ke.ma===R-2?(me.ma=R-2,me.className=le.name,_e[g]=me):(xe(_e,g,Ee),_e[g].aa[R-2]=me),Vt([],de,function(ve){return ve=ri(Ee,ve,le,re,ce),_e[g].aa===void 0?(ve.ma=R-2,_e[g]=ve):_e[g].aa[R-2]=ve,[]}),[]})},d:function(b,g,R,A,Y,re,ce,se,de,le){g=Fe(g),Y=We(A,Y),Vt([],[b],function(me){me=me[0];var Ee=`${me.name}.${g}`,_e={get(){kn(`Cannot access ${Ee} due to unbound types`,[R,ce])},enumerable:!0,configurable:!0};return _e.set=de?()=>{kn(`Cannot access ${Ee} due to unbound types`,[R,ce])}:()=>{Pe(Ee+" is a read-only property")},Object.defineProperty(me.X.ga,g,_e),Vt([],de?[R,ce]:[R],function(ke){var ve=ke[0],pt={get(){var Ve=_u(this,me,Ee+" getter");return ve.fromWireType(Y(re,Ve))},enumerable:!0};if(de){de=We(se,de);var Tt=ke[1];pt.set=function(Ve){var Be=_u(this,me,Ee+" setter"),St=[];de(le,Be,Tt.toWireType(St,Ve)),Mn(St)}}return Object.defineProperty(me.X.ga,g,pt),[]}),[]})},F:function(b,g){g=Fe(g),F(b,{name:g,fromWireType:function(R){var A=Ot(R);return Us(R),A},toWireType:function(R,A){return gt(A)},argPackAdvance:8,readValueFromPointer:vn,ea:null})},l:function(b,g,R,A){function Y(){}R=er(R),g=Fe(g),Y.values={},F(b,{name:g,constructor:Y,fromWireType:function(re){return this.constructor.values[re]},toWireType:function(re,ce){return ce.value},argPackAdvance:8,readValueFromPointer:ny(g,R,A),ea:null}),Se(g,Y)},c:function(b,g,R){var A=Qt(b,"enum");g=Fe(g),b=A.constructor,A=Object.create(A.constructor.prototype,{value:{value:R},constructor:{value:Xe(`${A.name}_${g}`,function(){})}}),b.values[R]=A,b[g]=A},u:function(b,g,R){R=er(R),g=Fe(g),F(b,{name:g,fromWireType:function(A){return A},toWireType:function(A,Y){return Y},argPackAdvance:8,readValueFromPointer:ry(g,R),ea:null})},q:function(b,g,R,A,Y,re){var ce=oi(g,R);b=Fe(b),Y=We(A,Y),Se(b,function(){kn(`Cannot call ${b} due to unbound types`,ce)},g-1),Vt([],ce,function(se){return Bt(b,ri(b,[se[0],null].concat(se.slice(1)),null,Y,re),g-1),[]})},j:function(b,g,R,A,Y){g=Fe(g),Y===-1&&(Y=4294967295),Y=er(R);var re=se=>se;if(A===0){var ce=32-8*R;re=se=>se<<ce>>>ce}R=g.includes("unsigned")?function(se,de){return de>>>0}:function(se,de){return de},F(b,{name:g,fromWireType:re,toWireType:R,argPackAdvance:8,readValueFromPointer:oy(g,Y,A!==0),ea:null})},g:function(b,g,R){function A(re){re>>=2;var ce=W;return new Y(ce.buffer,ce[re+1],ce[re])}var Y=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][g];R=Fe(R),F(b,{name:R,fromWireType:A,argPackAdvance:8,readValueFromPointer:A},{tb:!0})},v:function(b,g){g=Fe(g);var R=g==="std::string";F(b,{name:g,fromWireType:function(A){var Y=W[A>>2],re=A+4;if(R)for(var ce=re,se=0;se<=Y;++se){var de=re+se;if(se==Y||k[de]==0){if(ce=ce?Su(k,ce,de-ce):"",le===void 0)var le=ce;else le+=String.fromCharCode(0),le+=ce;ce=de+1}}else{for(le=Array(Y),se=0;se<Y;++se)le[se]=String.fromCharCode(k[re+se]);le=le.join("")}return Nn(A),le},toWireType:function(A,Y){Y instanceof ArrayBuffer&&(Y=new Uint8Array(Y));var re,ce=typeof Y=="string";ce||Y instanceof Uint8Array||Y instanceof Uint8ClampedArray||Y instanceof Int8Array||Pe("Cannot pass non-string to std::string");var se;if(R&&ce)for(re=se=0;re<Y.length;++re){var de=Y.charCodeAt(re);127>=de?se++:2047>=de?se+=2:55296<=de&&57343>=de?(se+=4,++re):se+=3}else se=Y.length;if(re=se,se=qs(4+re+1),de=se+4,W[se>>2]=re,R&&ce){if(ce=de,de=re+1,re=k,0<de){de=ce+de-1;for(var le=0;le<Y.length;++le){var me=Y.charCodeAt(le);if(55296<=me&&57343>=me){var Ee=Y.charCodeAt(++le);me=65536+((me&1023)<<10)|Ee&1023}if(127>=me){if(ce>=de)break;re[ce++]=me}else{if(2047>=me){if(ce+1>=de)break;re[ce++]=192|me>>6}else{if(65535>=me){if(ce+2>=de)break;re[ce++]=224|me>>12}else{if(ce+3>=de)break;re[ce++]=240|me>>18,re[ce++]=128|me>>12&63}re[ce++]=128|me>>6&63}re[ce++]=128|me&63}}re[ce]=0}}else if(ce)for(ce=0;ce<re;++ce)le=Y.charCodeAt(ce),255<le&&(Nn(de),Pe("String has UTF-16 code units that do not fit in 8 bits")),k[de+ce]=le;else for(ce=0;ce<re;++ce)k[de+ce]=Y[ce];return A!==null&&A.push(Nn,se),se},argPackAdvance:8,readValueFromPointer:vn,ea:function(A){Nn(A)}})},t:function(b,g,R){if(R=Fe(R),g===2)var A=iy,Y=sy,re=ay,ce=()=>G,se=1;else g===4&&(A=cy,Y=ly,re=uy,ce=()=>W,se=2);F(b,{name:R,fromWireType:function(de){for(var le=W[de>>2],me=ce(),Ee,_e=de+4,ke=0;ke<=le;++ke){var ve=de+4+ke*g;(ke==le||me[ve>>se]==0)&&(_e=A(_e,ve-_e),Ee===void 0?Ee=_e:(Ee+=String.fromCharCode(0),Ee+=_e),_e=ve+g)}return Nn(de),Ee},toWireType:function(de,le){typeof le!="string"&&Pe(`Cannot pass non-string to C++ string type ${R}`);var me=re(le),Ee=qs(4+me+g);return W[Ee>>2]=me>>se,Y(le,Ee+4,me+g),de!==null&&de.push(Nn,Ee),Ee},argPackAdvance:8,readValueFromPointer:vn,ea:function(de){Nn(de)}})},N:function(b,g,R,A,Y,re){Qn[b]={name:Fe(g),Ba:We(R,A),ka:We(Y,re),Na:[]}},M:function(b,g,R,A,Y,re,ce,se,de,le){Qn[b].Na.push({mb:Fe(g),sb:R,qb:We(A,Y),rb:re,Db:ce,Cb:We(se,de),Eb:le})},H:function(b,g){g=Fe(g),F(b,{vb:!0,name:g,argPackAdvance:0,fromWireType:function(){},toWireType:function(){}})},r:function(b,g,R){b=Ot(b),g=Qt(g,"emval::as");var A=[],Y=gt(A);return W[R>>2]=Y,g.toWireType(A,b)},w:function(b,g,R,A,Y){b=si[b],g=Ot(g),R=ii(R);var re=[];return W[A>>2]=gt(re),b(g,R,re,Y)},i:function(b,g,R,A){b=si[b],g=Ot(g),R=ii(R),b(g,R,null,A)},f:Us,h:function(b,g){var R=py(b,g),A=R[0];g=A.name+"_$"+R.slice(1).map(function(ce){return ce.name}).join("_")+"$";var Y=Pu[g];if(Y!==void 0)return Y;var re=Array(b-1);return Y=fy((ce,se,de,le)=>{for(var me=0,Ee=0;Ee<b-1;++Ee)re[Ee]=R[Ee+1].readValueFromPointer(le+me),me+=R[Ee+1].argPackAdvance;for(ce=ce[se].apply(ce,re),Ee=0;Ee<b-1;++Ee)R[Ee+1].hb&&R[Ee+1].hb(re[Ee]);if(!A.vb)return A.toWireType(de,ce)}),Pu[g]=Y},p:function(b){return b=ii(b),gt(p[b])},K:function(b,g){return b=Ot(b),g=Ot(g),gt(b[g])},m:function(b){4<b&&(st.get(b).Ta+=1)},J:function(b){return gt(ii(b))},n:function(b){var g=Ot(b);Mn(g),Us(b)},x:function(b,g){return b=Qt(b,"_emval_take_value"),b=b.readValueFromPointer(g),gt(b)},b:()=>{te("")},A:b=>{var g=k.length;if(b>>>=0,2147483648<b)return!1;for(var R=1;4>=R;R*=2){var A=g*(1+.2/R);A=Math.min(A,b+100663296);var Y=Math;A=Math.max(b,A);e:{Y=Y.min.call(Y,2147483648,A+(65536-A%65536)%65536)-v.buffer.byteLength+65535>>>16;try{v.grow(Y),X();var re=1;break e}catch{}re=void 0}if(re)return!0}return!1},B:(b,g)=>{var R=0;return Ru().forEach(function(A,Y){var re=g+R;for(Y=W[b+4*Y>>2]=re,re=0;re<A.length;++re)I[Y++>>0]=A.charCodeAt(re);I[Y>>0]=0,R+=A.length+1}),0},C:(b,g)=>{var R=Ru();W[b>>2]=R.length;var A=0;return R.forEach(function(Y){A+=Y.length+1}),W[g>>2]=A,0},D:()=>52,y:function(){return 70},E:(b,g,R,A)=>{for(var Y=0,re=0;re<R;re++){var ce=W[g>>2],se=W[g+4>>2];g+=8;for(var de=0;de<se;de++){var le=k[ce+de],me=hy[b];le===0||le===10?((b===1?K:V)(Su(me,0)),me.length=0):me.push(le)}Y+=se}return W[A>>2]=Y,0}};(function(){function b(R){if(R=R.exports,p.asm=R,v=p.asm.O,X(),q=p.asm.U,ae.unshift(p.asm.P),J--,p.monitorRunDependencies&&p.monitorRunDependencies(J),J==0&&ee){var A=ee;ee=null,A()}return R}var g={a:my};if(J++,p.monitorRunDependencies&&p.monitorRunDependencies(J),p.instantiateWasm)try{return p.instantiateWasm(g,b)}catch(R){V("Module.instantiateWasm callback failed with error: "+R),E(R)}return Ye(g,function(R){b(R.instance)}).catch(E),{}})();function Nn(){return(Nn=p.asm.Q).apply(null,arguments)}function qs(){return(qs=p.asm.R).apply(null,arguments)}function Au(){return(Au=p.asm.S).apply(null,arguments)}p.__embind_initialize_bindings=function(){return(p.__embind_initialize_bindings=p.asm.T).apply(null,arguments)},p.dynCall_jiji=function(){return(p.dynCall_jiji=p.asm.V).apply(null,arguments)};var ci;ee=function b(){ci||Du(),ci||(ee=b)};function Du(){function b(){if(!ci&&(ci=!0,p.calledRun=!0,!C)){if(je(ae),w(p),p.onRuntimeInitialized&&p.onRuntimeInitialized(),p.postRun)for(typeof p.postRun=="function"&&(p.postRun=[p.postRun]);p.postRun.length;){var g=p.postRun.shift();B.unshift(g)}je(B)}}if(!(0<J)){if(p.preRun)for(typeof p.preRun=="function"&&(p.preRun=[p.preRun]);p.preRun.length;)H();je(ne),0<J||(p.setStatus?(p.setStatus("Running..."),setTimeout(function(){setTimeout(function(){p.setStatus("")},1),b()},1)):b())}}if(p.preInit)for(typeof p.preInit=="function"&&(p.preInit=[p.preInit]);0<p.preInit.length;)p.preInit.pop()();return Du(),h.ready}})();const d=l},s=>{s.exports=JSON.parse(`{"name":"@rive-app/canvas","version":"1.2.4","description":"Rive's canvas based web api.","main":"rive.js","homepage":"https://rive.app","repository":{"type":"git","url":"https://github.com/rive-app/rive-wasm/tree/master/js"},"keywords":["rive","animation"],"author":"Rive","contributors":["Luigi Rosso <luigi@rive.app> (https://rive.app)","Maxwell Talbot <max@rive.app> (https://rive.app)","Arthur Vivian <arthur@rive.app> (https://rive.app)","Umberto Sonnino <umberto@rive.app> (https://rive.app)","Matthew Sullivan <matt.j.sullivan@gmail.com> (mailto:matt.j.sullivan@gmail.com)"],"license":"MIT","files":["rive.js","rive.js.map","rive.wasm","rive.d.ts","rive_advanced.mjs.d.ts"],"typings":"rive.d.ts","dependencies":{},"browser":{"fs":false,"path":false}}`)},(s,a,c)=>{c.r(a),c.d(a,{registerTouchInteractions:()=>l.registerTouchInteractions});var l=c(4)},(s,a,c)=>{c.r(a),c.d(a,{registerTouchInteractions:()=>f});var l=void 0,d=function(h){var p,w;return["touchstart","touchmove"].indexOf(h.type)>-1&&(!((p=h.touches)===null||p===void 0)&&p.length)?(h.preventDefault(),{clientX:h.touches[0].clientX,clientY:h.touches[0].clientY}):h.type==="touchend"&&(!((w=h.changedTouches)===null||w===void 0)&&w.length)?{clientX:h.changedTouches[0].clientX,clientY:h.changedTouches[0].clientY}:{clientX:h.clientX,clientY:h.clientY}},f=function(h){var p=h.canvas,w=h.artboard,E=h.stateMachines,T=E===void 0?[]:E,S=h.renderer,m=h.rive,x=h.fit,_=h.alignment;if(!p||!T.length||!S||!m||!w||typeof window>"u")return null;var $=function(M){var N=M.currentTarget.getBoundingClientRect(),j=d(M),K=j.clientX,V=j.clientY;if(!(!K&&!V)){var P=K-N.left,v=V-N.top,C=m.computeAlignment(x,_,{minX:0,minY:0,maxX:N.width,maxY:N.height},w.bounds),I=new m.Mat2D;C.invert(I);var k=new m.Vec2D(P,v),U=m.mapXY(I,k),G=U.x(),ue=U.y();switch(U.delete(),I.delete(),k.delete(),C.delete(),M.type){case"touchmove":case"mouseover":case"mouseout":case"mousemove":{for(var W=0,L=T;W<L.length;W++){var oe=L[W];oe.pointerMove(G,ue)}break}case"touchstart":case"mousedown":{for(var X=0,q=T;X<q.length;X++){var oe=q[X];oe.pointerDown(G,ue)}break}case"touchend":case"mouseup":{for(var ne=0,ae=T;ne<ae.length;ne++){var oe=ae[ne];oe.pointerUp(G,ue)}break}}}},O=$.bind(l);return p.addEventListener("mouseover",O),p.addEventListener("mouseout",O),p.addEventListener("mousemove",O),p.addEventListener("mousedown",O),p.addEventListener("mouseup",O),p.addEventListener("touchmove",O),p.addEventListener("touchstart",O),p.addEventListener("touchend",O),function(){p.removeEventListener("mouseover",O),p.removeEventListener("mouseout",O),p.removeEventListener("mousemove",O),p.removeEventListener("mousedown",O),p.removeEventListener("mouseup",O),p.removeEventListener("touchmove",O),p.removeEventListener("touchstart",O),p.removeEventListener("touchend",O)}}}],r={};function i(s){var a=r[s];if(a!==void 0)return a.exports;var c=r[s]={exports:{}};return n[s](c,c.exports,i),c.exports}i.d=(s,a)=>{for(var c in a)i.o(a,c)&&!i.o(s,c)&&Object.defineProperty(s,c,{enumerable:!0,get:a[c]})},i.o=(s,a)=>Object.prototype.hasOwnProperty.call(s,a),i.r=s=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(s,"__esModule",{value:!0})};var o={};return(()=>{i.r(o),i.d(o,{Alignment:()=>h,EventType:()=>_,Fit:()=>f,Layout:()=>p,LoopType:()=>$,Rive:()=>N,RuntimeLoader:()=>w,StateMachineInput:()=>S,StateMachineInputType:()=>T,Testing:()=>V});var s=i(1),a=i(2),c=i(3),l=function(P,v,C,I){function k(U){return U instanceof C?U:new C(function(G){G(U)})}return new(C||(C=Promise))(function(U,G){function ue(oe){try{L(I.next(oe))}catch(X){G(X)}}function W(oe){try{L(I.throw(oe))}catch(X){G(X)}}function L(oe){oe.done?U(oe.value):k(oe.value).then(ue,W)}L((I=I.apply(P,v||[])).next())})},d=function(P,v){var C={label:0,sent:function(){if(U[0]&1)throw U[1];return U[1]},trys:[],ops:[]},I,k,U,G;return G={next:ue(0),throw:ue(1),return:ue(2)},typeof Symbol=="function"&&(G[Symbol.iterator]=function(){return this}),G;function ue(L){return function(oe){return W([L,oe])}}function W(L){if(I)throw new TypeError("Generator is already executing.");for(;G&&(G=0,L[0]&&(C=0)),C;)try{if(I=1,k&&(U=L[0]&2?k.return:L[0]?k.throw||((U=k.return)&&U.call(k),0):k.next)&&!(U=U.call(k,L[1])).done)return U;switch(k=0,U&&(L=[L[0]&2,U.value]),L[0]){case 0:case 1:U=L;break;case 4:return C.label++,{value:L[1],done:!1};case 5:C.label++,k=L[1],L=[0];continue;case 7:L=C.ops.pop(),C.trys.pop();continue;default:if(U=C.trys,!(U=U.length>0&&U[U.length-1])&&(L[0]===6||L[0]===2)){C=0;continue}if(L[0]===3&&(!U||L[1]>U[0]&&L[1]<U[3])){C.label=L[1];break}if(L[0]===6&&C.label<U[1]){C.label=U[1],U=L;break}if(U&&C.label<U[2]){C.label=U[2],C.ops.push(L);break}U[2]&&C.ops.pop(),C.trys.pop();continue}L=v.call(P,C)}catch(oe){L=[6,oe],k=0}finally{I=U=0}if(L[0]&5)throw L[1];return{value:L[0]?L[1]:void 0,done:!0}}},f;(function(P){P.Cover="cover",P.Contain="contain",P.Fill="fill",P.FitWidth="fitWidth",P.FitHeight="fitHeight",P.None="none",P.ScaleDown="scaleDown"})(f||(f={}));var h;(function(P){P.Center="center",P.TopLeft="topLeft",P.TopCenter="topCenter",P.TopRight="topRight",P.CenterLeft="centerLeft",P.CenterRight="centerRight",P.BottomLeft="bottomLeft",P.BottomCenter="bottomCenter",P.BottomRight="bottomRight"})(h||(h={}));var p=function(){function P(v){var C,I,k,U,G,ue;this.fit=(C=v==null?void 0:v.fit)!==null&&C!==void 0?C:f.Contain,this.alignment=(I=v==null?void 0:v.alignment)!==null&&I!==void 0?I:h.Center,this.minX=(k=v==null?void 0:v.minX)!==null&&k!==void 0?k:0,this.minY=(U=v==null?void 0:v.minY)!==null&&U!==void 0?U:0,this.maxX=(G=v==null?void 0:v.maxX)!==null&&G!==void 0?G:0,this.maxY=(ue=v==null?void 0:v.maxY)!==null&&ue!==void 0?ue:0}return P.new=function(v){var C=v.fit,I=v.alignment,k=v.minX,U=v.minY,G=v.maxX,ue=v.maxY;return console.warn("This function is deprecated: please use `new Layout({})` instead"),new P({fit:C,alignment:I,minX:k,minY:U,maxX:G,maxY:ue})},P.prototype.copyWith=function(v){var C=v.fit,I=v.alignment,k=v.minX,U=v.minY,G=v.maxX,ue=v.maxY;return new P({fit:C??this.fit,alignment:I??this.alignment,minX:k??this.minX,minY:U??this.minY,maxX:G??this.maxX,maxY:ue??this.maxY})},P.prototype.runtimeFit=function(v){if(this.cachedRuntimeFit)return this.cachedRuntimeFit;var C;return this.fit===f.Cover?C=v.Fit.cover:this.fit===f.Contain?C=v.Fit.contain:this.fit===f.Fill?C=v.Fit.fill:this.fit===f.FitWidth?C=v.Fit.fitWidth:this.fit===f.FitHeight?C=v.Fit.fitHeight:this.fit===f.ScaleDown?C=v.Fit.scaleDown:C=v.Fit.none,this.cachedRuntimeFit=C,C},P.prototype.runtimeAlignment=function(v){if(this.cachedRuntimeAlignment)return this.cachedRuntimeAlignment;var C;return this.alignment===h.TopLeft?C=v.Alignment.topLeft:this.alignment===h.TopCenter?C=v.Alignment.topCenter:this.alignment===h.TopRight?C=v.Alignment.topRight:this.alignment===h.CenterLeft?C=v.Alignment.centerLeft:this.alignment===h.CenterRight?C=v.Alignment.centerRight:this.alignment===h.BottomLeft?C=v.Alignment.bottomLeft:this.alignment===h.BottomCenter?C=v.Alignment.bottomCenter:this.alignment===h.BottomRight?C=v.Alignment.bottomRight:C=v.Alignment.center,this.cachedRuntimeAlignment=C,C},P}(),w=function(){function P(){}return P.loadRuntime=function(){s.default({locateFile:function(){return P.wasmURL}}).then(function(v){var C;for(P.runtime=v;P.callBackQueue.length>0;)(C=P.callBackQueue.shift())===null||C===void 0||C(P.runtime)})},P.getInstance=function(v){P.isLoading||(P.isLoading=!0,P.loadRuntime()),P.runtime?v(P.runtime):P.callBackQueue.push(v)},P.awaitInstance=function(){return new Promise(function(v){return P.getInstance(function(C){return v(C)})})},P.setWasmUrl=function(v){P.wasmURL=v},P.isLoading=!1,P.callBackQueue=[],P.wasmURL="https://unpkg.com/".concat(a.name,"@").concat(a.version,"/rive.wasm"),P}(),E=function(){function P(v,C,I,k){this.animation=v,this.artboard=C,this.playing=k,this.loopCount=0,this.scrubTo=null,this.instance=new I.LinearAnimationInstance(v,C)}return Object.defineProperty(P.prototype,"name",{get:function(){return this.animation.name},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"time",{get:function(){return this.instance.time},set:function(v){this.instance.time=v},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"loopValue",{get:function(){return this.animation.loopValue},enumerable:!1,configurable:!0}),P.prototype.advance=function(v){this.scrubTo===null?this.instance.advance(v):(this.instance.time=0,this.instance.advance(this.scrubTo),this.scrubTo=null)},P.prototype.apply=function(v){this.instance.apply(v)},Object.defineProperty(P.prototype,"needsScrub",{get:function(){return this.scrubTo!==null},enumerable:!1,configurable:!0}),P.prototype.cleanup=function(){this.instance.delete()},P}(),T;(function(P){P[P.Number=56]="Number",P[P.Trigger=58]="Trigger",P[P.Boolean=59]="Boolean"})(T||(T={}));var S=function(){function P(v,C){this.type=v,this.runtimeInput=C}return Object.defineProperty(P.prototype,"name",{get:function(){return this.runtimeInput.name},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"value",{get:function(){return this.runtimeInput.value},set:function(v){this.runtimeInput.value=v},enumerable:!1,configurable:!0}),P.prototype.fire=function(){this.type===T.Trigger&&this.runtimeInput.fire()},P}(),m=function(){function P(v,C,I,k){this.stateMachine=v,this.playing=I,this.artboard=k,this.inputs=[],this.instance=new C.StateMachineInstance(v,k),this.initInputs(C)}return Object.defineProperty(P.prototype,"name",{get:function(){return this.stateMachine.name},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"statesChanged",{get:function(){for(var v=[],C=0;C<this.instance.stateChangedCount();C++)v.push(this.instance.stateChangedNameByIndex(C));return v},enumerable:!1,configurable:!0}),P.prototype.advance=function(v){this.instance.advance(v)},P.prototype.initInputs=function(v){for(var C=0;C<this.instance.inputCount();C++){var I=this.instance.input(C);this.inputs.push(this.mapRuntimeInput(I,v))}},P.prototype.mapRuntimeInput=function(v,C){if(v.type===C.SMIInput.bool)return new S(T.Boolean,v.asBool());if(v.type===C.SMIInput.number)return new S(T.Number,v.asNumber());if(v.type===C.SMIInput.trigger)return new S(T.Trigger,v.asTrigger())},P.prototype.cleanup=function(){this.instance.delete()},P}(),x=function(){function P(v,C,I,k,U){k===void 0&&(k=[]),U===void 0&&(U=[]),this.runtime=v,this.artboard=C,this.eventManager=I,this.animations=k,this.stateMachines=U}return P.prototype.add=function(v,C,I){if(I===void 0&&(I=!0),v=K(v),v.length===0)this.animations.forEach(function(ne){return ne.playing=C}),this.stateMachines.forEach(function(ne){return ne.playing=C});else for(var k=this.animations.map(function(ne){return ne.name}),U=this.stateMachines.map(function(ne){return ne.name}),G=0;G<v.length;G++){var ue=k.indexOf(v[G]),W=U.indexOf(v[G]);if(ue>=0||W>=0)ue>=0?this.animations[ue].playing=C:this.stateMachines[W].playing=C;else{var L=this.artboard.animationByName(v[G]);if(L){var oe=new E(L,this.artboard,this.runtime,C);oe.advance(0),oe.apply(1),this.animations.push(oe)}else{var X=this.artboard.stateMachineByName(v[G]);if(X){var q=new m(X,this.runtime,C,this.artboard);this.stateMachines.push(q)}}}}return I&&(C?this.eventManager.fire({type:_.Play,data:this.playing}):this.eventManager.fire({type:_.Pause,data:this.paused})),C?this.playing:this.paused},P.prototype.play=function(v){return this.add(v,!0)},P.prototype.pause=function(v){return this.add(v,!1)},P.prototype.scrub=function(v,C){var I=this.animations.filter(function(k){return v.includes(k.name)});return I.forEach(function(k){return k.scrubTo=C}),I.map(function(k){return k.name})},Object.defineProperty(P.prototype,"playing",{get:function(){return this.animations.filter(function(v){return v.playing}).map(function(v){return v.name}).concat(this.stateMachines.filter(function(v){return v.playing}).map(function(v){return v.name}))},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"paused",{get:function(){return this.animations.filter(function(v){return!v.playing}).map(function(v){return v.name}).concat(this.stateMachines.filter(function(v){return!v.playing}).map(function(v){return v.name}))},enumerable:!1,configurable:!0}),P.prototype.stop=function(v){var C=this;v=K(v);var I=[];if(v.length===0)I=this.animations.map(function(G){return G.name}).concat(this.stateMachines.map(function(G){return G.name})),this.animations.forEach(function(G){return G.cleanup()}),this.stateMachines.forEach(function(G){return G.cleanup()}),this.animations.splice(0,this.animations.length),this.stateMachines.splice(0,this.stateMachines.length);else{var k=this.animations.filter(function(G){return v.includes(G.name)});k.forEach(function(G){G.cleanup(),C.animations.splice(C.animations.indexOf(G),1)});var U=this.stateMachines.filter(function(G){return v.includes(G.name)});U.forEach(function(G){G.cleanup(),C.stateMachines.splice(C.stateMachines.indexOf(G),1)}),I=k.map(function(G){return G.name}).concat(U.map(function(G){return G.name}))}return this.eventManager.fire({type:_.Stop,data:I}),I},Object.defineProperty(P.prototype,"isPlaying",{get:function(){return this.animations.reduce(function(v,C){return v||C.playing},!1)||this.stateMachines.reduce(function(v,C){return v||C.playing},!1)},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isPaused",{get:function(){return!this.isPlaying&&(this.animations.length>0||this.stateMachines.length>0)},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isStopped",{get:function(){return this.animations.length===0&&this.stateMachines.length===0},enumerable:!1,configurable:!0}),P.prototype.atLeastOne=function(v,C){C===void 0&&(C=!0);var I;return this.animations.length===0&&this.stateMachines.length===0&&(this.artboard.animationCount()>0?this.add([I=this.artboard.animationByIndex(0).name],v,C):this.artboard.stateMachineCount()>0&&this.add([I=this.artboard.stateMachineByIndex(0).name],v,C)),I},P.prototype.handleLooping=function(){for(var v=0,C=this.animations.filter(function(k){return k.playing});v<C.length;v++){var I=C[v];I.loopValue===0&&I.loopCount?(I.loopCount=0,this.stop(I.name)):I.loopValue===1&&I.loopCount?(this.eventManager.fire({type:_.Loop,data:{animation:I.name,type:$.Loop}}),I.loopCount=0):I.loopValue===2&&I.loopCount>1&&(this.eventManager.fire({type:_.Loop,data:{animation:I.name,type:$.PingPong}}),I.loopCount=0)}},P.prototype.handleStateChanges=function(){for(var v=[],C=0,I=this.stateMachines.filter(function(U){return U.playing});C<I.length;C++){var k=I[C];v.push.apply(v,k.statesChanged)}v.length>0&&this.eventManager.fire({type:_.StateChange,data:v})},P.prototype.handleAdvancing=function(v){this.eventManager.fire({type:_.Advance,data:v})},P}(),_;(function(P){P.Load="load",P.LoadError="loaderror",P.Play="play",P.Pause="pause",P.Stop="stop",P.Loop="loop",P.Draw="draw",P.Advance="advance",P.StateChange="statechange"})(_||(_={}));var $;(function(P){P.OneShot="oneshot",P.Loop="loop",P.PingPong="pingpong"})($||($={}));var O=function(){function P(v){v===void 0&&(v=[]),this.listeners=v}return P.prototype.getListeners=function(v){return this.listeners.filter(function(C){return C.type===v})},P.prototype.add=function(v){this.listeners.includes(v)||this.listeners.push(v)},P.prototype.remove=function(v){for(var C=0;C<this.listeners.length;C++){var I=this.listeners[C];if(I.type===v.type&&I.callback===v.callback){this.listeners.splice(C,1);break}}},P.prototype.removeAll=function(v){var C=this;v?this.listeners.filter(function(I){return I.type===v}).forEach(function(I){return C.remove(I)}):this.listeners.splice(0,this.listeners.length)},P.prototype.fire=function(v){var C=this.getListeners(v.type);C.forEach(function(I){return I.callback(v)})},P}(),M=function(){function P(v){this.eventManager=v,this.queue=[]}return P.prototype.add=function(v){this.queue.push(v)},P.prototype.process=function(){for(;this.queue.length>0;){var v=this.queue.shift();v!=null&&v.action&&v.action(),v!=null&&v.event&&this.eventManager.fire(v.event)}},P}(),N=function(){function P(v){var C;this.loaded=!1,this.readyForPlaying=!1,this.artboard=null,this.eventCleanup=null,this.shouldDisableRiveListeners=!1,this.durations=[],this.frameTimes=[],this.frameCount=0,this.renderSecondTimer=0,this.canvas=v.canvas,this.src=v.src,this.buffer=v.buffer,this.layout=(C=v.layout)!==null&&C!==void 0?C:new p,this.shouldDisableRiveListeners=!!v.shouldDisableRiveListeners,this.eventManager=new O,v.onLoad&&this.on(_.Load,v.onLoad),v.onLoadError&&this.on(_.LoadError,v.onLoadError),v.onPlay&&this.on(_.Play,v.onPlay),v.onPause&&this.on(_.Pause,v.onPause),v.onStop&&this.on(_.Stop,v.onStop),v.onLoop&&this.on(_.Loop,v.onLoop),v.onStateChange&&this.on(_.StateChange,v.onStateChange),v.onAdvance&&this.on(_.Advance,v.onAdvance),v.onload&&!v.onLoad&&this.on(_.Load,v.onload),v.onloaderror&&!v.onLoadError&&this.on(_.LoadError,v.onloaderror),v.onplay&&!v.onPlay&&this.on(_.Play,v.onplay),v.onpause&&!v.onPause&&this.on(_.Pause,v.onpause),v.onstop&&!v.onStop&&this.on(_.Stop,v.onstop),v.onloop&&!v.onLoop&&this.on(_.Loop,v.onloop),v.onstatechange&&!v.onStateChange&&this.on(_.StateChange,v.onstatechange),this.taskQueue=new M(this.eventManager),this.init({src:this.src,buffer:this.buffer,autoplay:v.autoplay,animations:v.animations,stateMachines:v.stateMachines,artboard:v.artboard,useOffscreenRenderer:v.useOffscreenRenderer})}return P.new=function(v){return console.warn("This function is deprecated: please use `new Rive({})` instead"),new P(v)},P.prototype.init=function(v){var C=this,I=v.src,k=v.buffer,U=v.animations,G=v.stateMachines,ue=v.artboard,W=v.autoplay,L=W===void 0?!1:W,oe=v.useOffscreenRenderer,X=oe===void 0?!1:oe;if(this.src=I,this.buffer=k,!this.src&&!this.buffer)throw new Error(P.missingErrorMessage);var q=K(U),ne=K(G);this.loaded=!1,this.readyForPlaying=!1,w.awaitInstance().then(function(ae){C.runtime=ae,C.renderer=C.runtime.makeRenderer(C.canvas,X),C.canvas.width||C.canvas.height||C.resizeDrawingSurfaceToCanvas(),C.initData(ue,q,ne,L).then(function(){return C.setupRiveListeners()}).catch(function(B){console.error(B)})}).catch(function(ae){console.error(ae)})},P.prototype.setupRiveListeners=function(){var v=this;if(!this.shouldDisableRiveListeners){var C=(this.animator.stateMachines||[]).filter(function(I){return I.playing&&v.runtime.hasListeners(I.instance)}).map(function(I){return I.instance});this.eventCleanup=(0,c.registerTouchInteractions)({canvas:this.canvas,artboard:this.artboard,stateMachines:C,renderer:this.renderer,rive:this.runtime,fit:this._layout.runtimeFit(this.runtime),alignment:this._layout.runtimeAlignment(this.runtime)})}},P.prototype.initData=function(v,C,I,k){var U;return l(this,void 0,void 0,function(){var G,ue,W;return d(this,function(L){switch(L.label){case 0:return this.src?(G=this,[4,j(this.src)]):[3,2];case 1:G.buffer=L.sent(),L.label=2;case 2:return ue=this,[4,this.runtime.load(new Uint8Array(this.buffer))];case 3:return ue.file=L.sent(),this.file?(this.initArtboard(v,C,I,k),this.loaded=!0,this.eventManager.fire({type:_.Load,data:(U=this.src)!==null&&U!==void 0?U:"buffer"}),this.readyForPlaying=!0,this.taskQueue.process(),this.drawFrame(),[2,Promise.resolve()]):(W="Problem loading file; may be corrupt!",console.warn(W),this.eventManager.fire({type:_.LoadError,data:W}),[2,Promise.reject(W)])}})})},P.prototype.initArtboard=function(v,C,I,k){var U=v?this.file.artboardByName(v):this.file.defaultArtboard();if(!U){var G="Invalid artboard name or no default artboard";console.warn(G),this.eventManager.fire({type:_.LoadError,data:G});return}if(this.artboard=U,this.artboard.animationCount()<1){var G="Artboard has no animations";throw this.eventManager.fire({type:_.LoadError,data:G}),G}this.animator=new x(this.runtime,this.artboard,this.eventManager);var ue;C.length>0||I.length>0?(ue=C.concat(I),this.animator.add(ue,k,!1)):ue=[this.animator.atLeastOne(k,!1)],this.taskQueue.add({event:{type:k?_.Play:_.Pause,data:ue}})},P.prototype.drawFrame=function(){this.startRendering()},P.prototype.draw=function(v,C){var I=performance.now();this.frameRequestId=null,this.lastRenderTime||(this.lastRenderTime=v),this.renderSecondTimer+=v-this.lastRenderTime,this.renderSecondTimer>5e3&&(this.renderSecondTimer=0,C==null||C());var k=(v-this.lastRenderTime)/1e3;this.lastRenderTime=v;for(var U=this.animator.animations.filter(function(B){return B.playing||B.needsScrub}).sort(function(B){return B.needsScrub?-1:1}),G=0,ue=U;G<ue.length;G++){var W=ue[G];W.advance(k),W.instance.didLoop&&(W.loopCount+=1),W.apply(1)}for(var L=this.animator.stateMachines.filter(function(B){return B.playing}),oe=0,X=L;oe<X.length;oe++){var q=X[oe];q.advance(k)}this.artboard.advance(k);var ne=this.renderer;ne.clear(),ne.save(),this.alignRenderer(),this.artboard.draw(ne),ne.restore(),ne.flush(),this.animator.handleLooping(),this.animator.handleStateChanges(),this.animator.handleAdvancing(k),this.frameCount++;var ae=performance.now();for(this.frameTimes.push(ae),this.durations.push(ae-I);this.frameTimes[0]<=ae-1e3;)this.frameTimes.shift(),this.durations.shift();this.animator.isPlaying?this.startRendering():this.animator.isPaused?this.lastRenderTime=0:this.animator.isStopped&&(this.lastRenderTime=0)},P.prototype.alignRenderer=function(){var v=this,C=v.renderer,I=v.runtime,k=v._layout,U=v.artboard;C.align(k.runtimeFit(I),k.runtimeAlignment(I),{minX:k.minX,minY:k.minY,maxX:k.maxX,maxY:k.maxY},U.bounds)},Object.defineProperty(P.prototype,"fps",{get:function(){return this.durations.length},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"frameTime",{get:function(){return this.durations.length===0?0:(this.durations.reduce(function(v,C){return v+C},0)/this.durations.length).toFixed(4)},enumerable:!1,configurable:!0}),P.prototype.cleanup=function(){var v,C;this.stopRendering(),this.cleanupInstances(),(v=this.renderer)===null||v===void 0||v.delete(),this.renderer=null,(C=this.file)===null||C===void 0||C.delete(),this.file=null},P.prototype.cleanupInstances=function(){this.eventCleanup!==null&&this.eventCleanup(),this.stop(),this.artboard&&(this.artboard.delete(),this.artboard=null)},P.prototype.play=function(v,C){var I=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return I.play(v,C)}});return}this.animator.play(v),this.eventCleanup&&this.eventCleanup(),this.setupRiveListeners(),this.startRendering()},P.prototype.pause=function(v){var C=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return C.pause(v)}});return}this.eventCleanup&&this.eventCleanup(),this.animator.pause(v)},P.prototype.scrub=function(v,C){var I=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return I.scrub(v,C)}});return}this.animator.scrub(v,C||0),this.drawFrame()},P.prototype.stop=function(v){var C=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return C.stop(v)}});return}this.animator.stop(v),this.eventCleanup&&this.eventCleanup()},P.prototype.reset=function(v){var C,I=v==null?void 0:v.artboard,k=K(v==null?void 0:v.animations),U=K(v==null?void 0:v.stateMachines),G=(C=v==null?void 0:v.autoplay)!==null&&C!==void 0?C:!1;this.cleanupInstances(),this.initArtboard(I,k,U,G),this.taskQueue.process()},P.prototype.load=function(v){this.stop(),this.init(v)},Object.defineProperty(P.prototype,"layout",{get:function(){return this._layout},set:function(v){this._layout=v,(!v.maxX||!v.maxY)&&this.resizeToCanvas(),this.loaded&&!this.animator.isPlaying&&this.drawFrame()},enumerable:!1,configurable:!0}),P.prototype.resizeToCanvas=function(){this._layout=this.layout.copyWith({minX:0,minY:0,maxX:this.canvas.width,maxY:this.canvas.height})},P.prototype.resizeDrawingSurfaceToCanvas=function(){if(this.canvas instanceof HTMLCanvasElement&&window){var v=this.canvas.getBoundingClientRect(),C=v.width,I=v.height,k=window.devicePixelRatio||1;this.canvas.width=k*C,this.canvas.height=k*I,this.startRendering(),this.resizeToCanvas()}},Object.defineProperty(P.prototype,"source",{get:function(){return this.src},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"activeArtboard",{get:function(){return this.artboard?this.artboard.name:""},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"animationNames",{get:function(){if(!this.loaded)return[];for(var v=[],C=0;C<this.artboard.animationCount();C++)v.push(this.artboard.animationByIndex(C).name);return v},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"stateMachineNames",{get:function(){if(!this.loaded)return[];for(var v=[],C=0;C<this.artboard.stateMachineCount();C++)v.push(this.artboard.stateMachineByIndex(C).name);return v},enumerable:!1,configurable:!0}),P.prototype.stateMachineInputs=function(v){if(this.loaded){var C=this.animator.stateMachines.find(function(I){return I.name===v});return C==null?void 0:C.inputs}},Object.defineProperty(P.prototype,"playingStateMachineNames",{get:function(){return this.loaded?this.animator.stateMachines.filter(function(v){return v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"playingAnimationNames",{get:function(){return this.loaded?this.animator.animations.filter(function(v){return v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"pausedAnimationNames",{get:function(){return this.loaded?this.animator.animations.filter(function(v){return!v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"pausedStateMachineNames",{get:function(){return this.loaded?this.animator.stateMachines.filter(function(v){return!v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isPlaying",{get:function(){return this.animator.isPlaying},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isPaused",{get:function(){return this.animator.isPaused},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isStopped",{get:function(){return this.animator.isStopped},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"bounds",{get:function(){return this.artboard?this.artboard.bounds:void 0},enumerable:!1,configurable:!0}),P.prototype.on=function(v,C){this.eventManager.add({type:v,callback:C})},P.prototype.off=function(v,C){this.eventManager.remove({type:v,callback:C})},P.prototype.unsubscribe=function(v,C){console.warn("This function is deprecated: please use `off()` instead."),this.off(v,C)},P.prototype.removeAllRiveEventListeners=function(v){this.eventManager.removeAll(v)},P.prototype.unsubscribeAll=function(v){console.warn("This function is deprecated: please use `removeAllRiveEventListeners()` instead."),this.removeAllRiveEventListeners(v)},P.prototype.stopRendering=function(){this.loaded&&this.frameRequestId&&(this.runtime.cancelAnimationFrame?this.runtime.cancelAnimationFrame(this.frameRequestId):cancelAnimationFrame(this.frameRequestId),this.frameRequestId=null)},P.prototype.startRendering=function(){this.loaded&&this.artboard&&!this.frameRequestId&&(this.runtime.requestAnimationFrame?this.frameRequestId=this.runtime.requestAnimationFrame(this.draw.bind(this)):this.frameRequestId=requestAnimationFrame(this.draw.bind(this)))},P.prototype.enableFPSCounter=function(v){this.runtime.enableFPSCounter(v)},P.prototype.disableFPSCounter=function(){this.runtime.disableFPSCounter()},Object.defineProperty(P.prototype,"contents",{get:function(){if(this.loaded){for(var v={artboards:[]},C=0;C<this.file.artboardCount();C++){for(var I=this.file.artboardByIndex(C),k={name:I.name,animations:[],stateMachines:[]},U=0;U<I.animationCount();U++){var G=I.animationByIndex(U);k.animations.push(G.name)}for(var ue=0;ue<I.stateMachineCount();ue++){for(var W=I.stateMachineByIndex(ue),L=W.name,oe=new this.runtime.StateMachineInstance(W,I),X=[],q=0;q<oe.inputCount();q++){var ne=oe.input(q);X.push({name:ne.name,type:ne.type})}k.stateMachines.push({name:L,inputs:X})}v.artboards.push(k)}return v}},enumerable:!1,configurable:!0}),P.missingErrorMessage="Rive source file or data buffer required",P}(),j=function(P){return l(void 0,void 0,void 0,function(){var v,C,I;return d(this,function(k){switch(k.label){case 0:return v=new Request(P),[4,fetch(v)];case 1:return C=k.sent(),[4,C.arrayBuffer()];case 2:return I=k.sent(),[2,I]}})})},K=function(P){return typeof P=="string"?[P]:P instanceof Array?P:[]},V={EventManager:O,TaskQueueManager:M}})(),o})())})(Mv);var jP=Mv.exports;(function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=u,n=jP;function r(m){return m&&typeof m=="object"&&"default"in m?m:{default:m}}var i=r(t),o=function(){return o=Object.assign||function(m){for(var x,_=1,$=arguments.length;_<$;_++)for(var O in x=arguments[_])Object.prototype.hasOwnProperty.call(x,O)&&(m[O]=x[O]);return m},o.apply(this,arguments)};function s(m,x){var _={};for(var $ in m)Object.prototype.hasOwnProperty.call(m,$)&&x.indexOf($)<0&&(_[$]=m[$]);if(m!=null&&typeof Object.getOwnPropertySymbols=="function"){var O=0;for($=Object.getOwnPropertySymbols(m);O<$.length;O++)x.indexOf($[O])<0&&Object.prototype.propertyIsEnumerable.call(m,$[O])&&(_[$[O]]=m[$[O]])}return _}function a(){var m=typeof window<"u"&&typeof window.devicePixelRatio=="number"?window.devicePixelRatio:1;return Math.min(Math.max(1,m),3)}typeof SuppressedError=="function"&&SuppressedError;var c=function(){function m(){}return m.prototype.observe=function(){},m.prototype.unobserve=function(){},m.prototype.disconnect=function(){},m}(),l=globalThis.ResizeObserver||c,d=globalThis.ResizeObserver!==void 0,f=!d;function h(m,x){x===void 0&&(x=!0);var _=t.useState({width:0,height:0}),$=_[0],O=_[1];t.useEffect(function(){if(typeof window<"u"&&x){var V=function(){O({width:window.innerWidth,height:window.innerHeight})};return f&&(V(),window.addEventListener("resize",V)),function(){return window.removeEventListener("resize",V)}}},[]);var M,N,j,K=t.useRef(new l((M=function(V){d&&O({width:V[V.length-1].contentRect.width,height:V[V.length-1].contentRect.height})},N=0,j=0,function(){for(var V=this,P=[],v=0;v<arguments.length;v++)P[v]=arguments[v];clearTimeout(j),j=window.setTimeout(function(){return M.apply(V,P)},N)})));return t.useEffect(function(){var V=K.current;if(x){var P=m.current;return m.current&&d&&V.observe(m.current),function(){V.disconnect(),P&&d&&V.unobserve(P)}}V.disconnect()},[m,K]),$}var p={useDevicePixelRatio:!0,fitCanvasToArtboardHeight:!1,useOffscreenRenderer:!0,shouldResizeCanvasToContainer:!0};function w(m){return Object.assign({},p,m)}function E(m){var x=m.riveLoaded,_=x!==void 0&&x,$=m.canvasRef,O=m.containerRef,M=m.options,N=M===void 0?{}:M,j=m.onCanvasHasResized,K=m.artboardBounds,V=w(N),P=t.useState({height:0,width:0}),v=P[0],C=v.height,I=v.width,k=P[1],U=t.useState({height:0,width:0}),G=U[0],ue=G.height,W=G.width,L=U[1],oe=t.useState(!0),X=oe[0],q=oe[1],ne=V.fitCanvasToArtboardHeight,ae=V.shouldResizeCanvasToContainer,B=V.useDevicePixelRatio,H=h(O,ae),J=function(){var Te=a(),Ie=t.useState(Te),Ae=Ie[0],$e=Ie[1];return t.useEffect(function(){if(typeof window<"u"&&"matchMedia"in window){var Ye=function(){var vt=a();$e(vt)},je=window.matchMedia("screen and (resolution: ".concat(Ae,"dppx)"));return je.hasOwnProperty("addEventListener")?je.addEventListener("change",Ye):je.addListener(Ye),function(){je.hasOwnProperty("removeEventListener")?je.removeEventListener("change",Ye):je.removeListener(Ye)}}},[Ae]),Ae}(),ee=K??{},te=ee.maxX,Z=ee.maxY,ge=t.useCallback(function(){var Te,Ie,Ae,$e,Ye=(Ie=(Te=O.current)===null||Te===void 0?void 0:Te.clientWidth)!==null&&Ie!==void 0?Ie:0,je=($e=(Ae=O.current)===null||Ae===void 0?void 0:Ae.clientHeight)!==null&&$e!==void 0?$e:0;return ne&&K?{width:Ye,height:Ye*(K.maxY/K.maxX)}:{width:Ye,height:je}},[O,ne,te,Z]);t.useEffect(function(){if(ae&&O.current&&_){var Te=ge(),Ie=Te.width,Ae=Te.height,$e=!1;if($.current){var Ye=Ie!==I||Ae!==C;if(V.fitCanvasToArtboardHeight&&Ye&&(O.current.style.height=Ae+"px",$e=!0),V.useDevicePixelRatio){if(Ye||Ie*J!==W||Ae*J!==ue){var je=J*Ie,vt=J*Ae;$.current.width=je,$.current.height=vt,$.current.style.width=Ie+"px",$.current.style.height=Ae+"px",L({width:je,height:vt}),$e=!0}}else Ye&&($.current.width=Ie,$.current.height=Ae,L({width:Ie,height:Ae}),$e=!0);k({width:Ie,height:Ae})}j&&(X||$e)&&j&&j(),X&&q(!1)}},[$,O,H,J,ge,X,q,ue,W,C,I,j,ae,ne,B,_])}function T(m){var x=m.setContainerRef,_=m.setCanvasRef,$=m.className,O=$===void 0?"":$,M=m.style,N=m.children,j=s(m,["setContainerRef","setCanvasRef","className","style","children"]),K=o({width:"100%",height:"100%"},M);return i.default.createElement("div",o({ref:x,className:O},!O&&{style:K}),i.default.createElement("canvas",o({ref:_,style:{verticalAlign:"top",width:0,height:0}},j),N))}function S(m,x){x===void 0&&(x={});var _=t.useRef(null),$=t.useRef(null),O=t.useState(null),M=O[0],N=O[1],j=!!m,K=w(x),V=t.useCallback(function(){M&&(M.startRendering(),M.resizeToCanvas())},[M]);E({riveLoaded:!!M,canvasRef:_,containerRef:$,options:K,onCanvasHasResized:V,artboardBounds:M==null?void 0:M.bounds});var P=t.useCallback(function(k){if(k&&m&&j){var U=K.useOffscreenRenderer,G=new n.Rive(o(o({useOffscreenRenderer:U},m),{canvas:k}));G.on(n.EventType.Load,function(){_.current?N(G):G.cleanup()})}else k===null&&_.current&&(_.current.height=0,_.current.width=0);_.current=k},[j]),v=t.useCallback(function(k){$.current=k},[]);t.useEffect(function(){var k=new IntersectionObserver(function(U){U[0].isIntersecting?M&&M.startRendering():M&&M.stopRendering()});return _.current&&k.observe(_.current),function(){k.disconnect()}},[M]),t.useEffect(function(){return function(){M&&(M.cleanup(),N(null))}},[M]);var C=m==null?void 0:m.animations;t.useEffect(function(){M&&C&&(M.isPlaying?(M.stop(M.animationNames),M.play(C)):M.isPaused&&(M.stop(M.animationNames),M.pause(C)))},[C,M]);var I=t.useCallback(function(k){return i.default.createElement(T,o({setContainerRef:v,setCanvasRef:P},k))},[P,v]);return{canvas:_.current,container:$.current,setCanvasRef:P,setContainerRef:v,rive:M,RiveComponent:I}}e.default=function(m){var x=m.src,_=m.artboard,$=m.animations,O=m.stateMachines,M=m.layout,N=m.useOffscreenRenderer,j=N===void 0||N,K=m.shouldDisableRiveListeners,V=K!==void 0&&K,P=m.shouldResizeCanvasToContainer,v=P===void 0||P,C=m.children,I=s(m,["src","artboard","animations","stateMachines","layout","useOffscreenRenderer","shouldDisableRiveListeners","shouldResizeCanvasToContainer","children"]),k=S({src:x,artboard:_,animations:$,layout:M,stateMachines:O,autoplay:!0,shouldDisableRiveListeners:V},{useOffscreenRenderer:j,shouldResizeCanvasToContainer:v}).RiveComponent;return i.default.createElement(k,o({},I),C)},e.useResizeCanvas=E,e.useRive=S,e.useStateMachineInput=function(m,x,_,$){var O=t.useState(null),M=O[0],N=O[1];return t.useEffect(function(){function j(){if(m&&x&&_||N(null),m&&x&&_){var K=m.stateMachineInputs(x);if(K){var V=K.find(function(P){return P.name===_});$!==void 0&&V&&(V.value=$),N(V||null)}}else N(null)}j(),m&&m.on(n.EventType.Play,function(){j()})},[m]),M},Object.keys(n).forEach(function(m){m==="default"||e.hasOwnProperty(m)||Object.defineProperty(e,m,{enumerable:!0,get:function(){return n[m]}})})})(Ov);const VP=kp(Ov),Sl=({src:e="https://assets.machtwatch.net/voila/asset/riv-animation/loader.riv",width:t,height:n,style:r,...i})=>D.jsx(ht,{width:t,height:n,style:r,children:D.jsx(VP,{src:e,...i})});Sl.defaultProps={src:"https://assets.machtwatch.net/voila/asset/riv-animation/loader.riv",width:"300px",height:"300px",style:{}};const kv=({isLoading:e,className:t,width:n,height:r,onClose:i,src:o,noScroll:s="noscroll",...a})=>(u.useEffect(()=>(e?document.body.classList.add(s):document.body.classList.remove(s),()=>{document.body.classList.remove(s)}),[e,s]),e?D.jsx(ht,{className:t,"data-test-id":a["data-testid-backdrop"],onClick:i,position:"fixed",left:"$0",top:"$0",width:"$full",height:"$full",cursor:"progress",style:{backgroundColor:"rgba(0, 0, 0, 0.4)",zIndex:9999},children:D.jsx(ht,{"data-test-id":a["data-testid-loader"],position:"absolute",left:"50%",top:"50%",width:n,height:r,children:D.jsx(Sl,{src:o,width:n,height:r,style:{transform:"translate(-50%, -50%)"}})})}):null);kv.defaultProps={onClose:()=>{},className:"",src:void 0,noScroll:"noscroll","data-testid-backdrop":"full-loader-backdrop","data-testid-loader":"full-loader-loader"};var LP=ft({defaultClassName:"_1a8lrjn1 j1jih79l j1jih7ak",variantClassNames:{color:{primary:"_1a8lrjn2",white:"_1a8lrjn3"},size:{small:"_1a8lrjn4",medium:"_1a8lrjn5",large:"_1a8lrjn6"}},defaultVariants:{color:"primary",size:"medium"},compoundVariants:[]});const FP=({color:e,size:t,...n})=>D.jsx(ht,{...n,className:Re(LP({color:e,size:t}))});function BP(e){return class extends u.Component{constructor(){super(...arguments),this.getValue=()=>{const{children:n,selectedValue:r}=this.props;return r&&r.length?r:n?u.Children.map(n,i=>{const o=u.Children.toArray(i.children||i.props.children);return o&&o[0]&&o[0].props.value}):[]},this.onChange=(n,r,i)=>{const o=this.getValue().concat();o[n]=r,i&&i(o,n)},this.onValueChange=(n,r)=>{this.onChange(n,r,this.props.onValueChange)},this.onScrollChange=(n,r)=>{this.onChange(n,r,this.props.onScrollChange)}}render(){return D.jsx(e,{...this.props,getValue:this.getValue,onValueChange:this.onValueChange,onScrollChange:this.props.onScrollChange&&this.onScrollChange})}}}var HP="_1ypj0tt5",WP="_1ypj0tt4",UP="_1ypj0tt3",sp="_1ypj0tt1",YP="_1ypj0tt0",zP="_1ypj0tt2";const KP=({className:e,children:t,getValue:n,onScrollChange:r,onValueChange:i})=>{const o=n==null?void 0:n(),s=u.Children.map(t,(a,c)=>u.cloneElement(a,{selectedValue:o==null?void 0:o[c],onValueChange:(...l)=>i==null?void 0:i(c,...l),onScrollChange:(...l)=>r==null?void 0:r(c,...l)}));return D.jsx(ht,{className:Re(HP,e),children:s})},Nv=BP(KP),qP=e=>null;function XP(e){var t;const n=(r,i,o)=>{const s=Math.round(r/i);return Math.min(s,o-1)};return t=class extends u.Component{constructor(){super(...arguments),this.selectByIndex=(r,i,o)=>{r<0||r>=u.Children.count(this.props.children)||!i||o(r*i)},this.doScrollingComplete=(r,i,o)=>{const s=u.Children.toArray(this.props.children),a=n(r,i,s.length),c=s[a];c?o(c.props.value):console.warn&&console.warn("child not found",s,a)},this.select=(r,i,o)=>{const s=u.Children.toArray(this.props.children);for(let a=0,c=s.length;a<c;a+=1)if(s[a].props.value===r){this.selectByIndex(a,i,o);return}this.selectByIndex(0,i,o)}}render(){return D.jsx(e,{...this.props,doScrollingComplete:this.doScrollingComplete,computeChildIndex:n,select:this.select})}},t.Item=qP,t}const GP=e=>{const{children:t,selectedValue:n,defaultSelectedValue:r,select:i,doScrollingComplete:o,onValueChange:s,computeChildIndex:a,disabled:c,className:l}=e,d=u.useRef(null),f=u.useRef(null),h=u.useRef(null),p=u.useRef(0),w=u.useRef(0),E=u.useMemo(()=>{if(n||r)return n||r;const j=u.Children.toArray(t);return j&&j[0]&&j[0].props.value},[t,r,n]),[T,S]=u.useState(E),m=(()=>{let j=-1,K=0,V=0,P=!1,v=!1;const C=(L,oe)=>{L.transform=oe},I=(L,oe)=>{L.transition=oe},k=(L,oe,X=.3)=>{var q,ne;j!==oe&&(j=oe,I((q=f.current)==null?void 0:q.style,`cubic-bezier(0,0,0.2,1.15) ${X}s`),C((ne=f.current)==null?void 0:ne.style,`translate3d(0,${-oe}px,0)`),setTimeout(()=>{M(),f.current&&I(f.current.style,"")},+X*1e3))},U=((L=30,oe=100)=>{let X=0,q=0,ne=0;const ae={record:B=>{const H=+new Date;ne=(B-q)/(H-X),H-X>=L&&(ne=H-X<=oe?ne:0,q=B,X=H)},getVelocity:B=>(B!==q&&ae.record(B),ne)};return ae})(),G=()=>{v=!1;let L=j;const oe=(t.length-1)*p.current;let X=.3;const q=U.getVelocity(L)*4;q&&(L=q*40+L,X=Math.abs(q)*.1),L%p.current!==0&&(L=Math.round(L/p.current)*p.current),L<0?L=0:L>oe&&(L=oe),k(0,L,X<.3?.3:X),O()},ue=L=>{P||(v=!0,V=L,K=j)},W=L=>{var oe;P||!v||(j=K-L+V,U.record(j),O(),C((oe=f.current)==null?void 0:oe.style,`translate3d(0,${-j}px,0)`))};return{touchstart:L=>ue(L.touches[0].pageY),mousedown:L=>ue(L.pageY),touchmove:L=>{L.preventDefault(),W(L.touches[0].pageY)},mousemove:L=>{L.preventDefault(),W(L.pageY)},touchend:()=>G(),touchcancel:()=>G(),mouseup:()=>G(),getValue:()=>j,scrollTo:k,setDisabled:(L=!1)=>{P=L}}})(),x=u.useCallback(j=>{m.scrollTo(0,j)},[m]),_=u.useCallback(j=>{m.scrollTo(0,j,0)},[m]),$=j=>{j!==T&&("selectedValue"in e||S(j),s&&s(j))},O=()=>{const j=m.getValue();if(j>=0){const K=u.Children.toArray(t),V=a(j,p.current,K.length);if(w.current!==V){w.current=V;const P=K[V];P&&e.onScrollChange?e.onScrollChange(P.props.value):!K&&console.warn&&console.warn("child not found",t,V)}}},M=()=>{const j=m.getValue();j>=0&&o(j,p.current,$)},N=()=>{const j=`${sp} ${zP}`,K=P=>{const{className:v="",style:C,value:I}=P.props,k=T===I;return D.jsx("div",{style:{...C},"data-selected":k?"true":void 0,className:`${k?j:sp} ${v}`,children:P.props.children},I)};return u.Children?u.Children.map(t,K):[].concat(t).map(K)};return u.useEffect(()=>{var P,v,C;const j=((P=d.current)==null?void 0:P.getBoundingClientRect().height)??0,K=((v=h.current)==null?void 0:v.getBoundingClientRect().height)??0;p.current=((C=h.current)==null?void 0:C.getBoundingClientRect().height)??0;let V=Math.floor(j/K);return V%2===0&&(V-=1),V-=1,V/=2,f.current.style.padding=`${K*V}px 0`,h.current.style.top=`${K*V}px`,m.setDisabled(c),i(T,p.current,x),Object.keys(m).forEach(I=>{var k;if(I.indexOf("touch")===0||I.indexOf("mouse")===0){const U=I.indexOf("move")>=0?{passive:!1}:{passive:!0};(k=d.current)==null||k.addEventListener(I,m[I],U)}}),()=>{Object.keys(m).forEach(I=>{var k;(I.indexOf("touch")===0||I.indexOf("mouse")===0)&&((k=d.current)==null||k.removeEventListener(I,m[I]))})}},[c,m,x,i,T]),u.useEffect(()=>{"selectedValue"in e&&T!==n&&S(n),m.setDisabled(c)},[n,T,e,m,c]),u.useEffect(()=>{i(T,p.current,_)},[_,i,T]),D.jsxs("div",{className:Re(YP,l),ref:d,children:[D.jsx("div",{className:Re(UP,l),ref:h}),D.jsx("div",{className:WP,ref:f,children:N()})]})},lc=XP(GP);var It=(e=>(e.DATE="date",e.MONTH="month",e.YEAR="year",e.DATE_TIME="datetime",e.TIME="time",e))(It||{});const Ji=24*60*60*1e3,ZP={am:"AM",pm:"PM"},jv=e=>new Date(e.getFullYear(),e.getMonth()+1,0).getDate(),Ta=e=>e<10?`0${e}`:`${e}`,Cr=e=>new Date(+e),QP=(e,t)=>{e.setDate(Math.min(e.getDate(),jv(new Date(e.getFullYear(),t)))),e.setMonth(t)},ap=(e,t,n)=>{if(n){const r=e.getHours();let i=t;i=r>=12?t+12:t,i=i>=24?0:i,e.setHours(i)}else e.setHours(t)},cp=(e,t)=>{t===0?e.setTime(+e-Ji/2):e.setTime(+e+Ji/2)},lp=(e,t)=>(t&&(e===0&&(e=12),e>12&&(e-=12)),e),JP=e=>["January","February","March","April","May","June","July","August","September","October","November","December"][e],eR=e=>{const{date:t,defaultDate:n=new Date(2e3,0,1),locale:r=ZP,mode:i="date",disabled:o=!1,className:s,minuteStep:a=1,use12Hours:c=!1,minDate:l,maxDate:d,formatDay:f,formatMonth:h}=e,[p,w]=u.useState(t||n),E=u.useRef(new Date(-1)),T=u.useRef(new Date);u.useEffect(()=>{"date"in e&&w(t||n)},[t,n,e]);const S=()=>C(p||E.current),m=()=>P().getFullYear(),x=()=>v().getFullYear(),_=()=>P().getMonth(),$=()=>v().getMonth(),O=()=>P().getDate(),M=()=>v().getDate(),N=()=>P().getHours(),j=()=>v().getHours(),K=()=>P().getMinutes(),V=()=>v().getMinutes(),P=()=>l||E.current,v=()=>d||T.current,C=X=>{const q=P(),ne=v();if(i===It.DATE_TIME){if(X<q)return Cr(q);if(X>ne)return Cr(ne)}else if(i===It.DATE||i===It.YEAR||i===It.MONTH){if(+X+Ji<=q)return Cr(q);if(X>=+ne+Ji)return Cr(ne)}else if(i===It.TIME){const ae=ne.getHours(),B=ne.getMinutes(),H=q.getHours(),J=q.getMinutes(),ee=X.getHours(),te=X.getMinutes();if(ee<H||ee===H&&te<J)return Cr(q);if(ee>ae||ee===ae&&te>B)return Cr(ne)}return X},I=(X,q)=>{const ne=parseInt(X[q],10),ae=Cr(S());if(i===It.DATE_TIME||i===It.DATE||i===It.YEAR||i===It.MONTH)switch(q){case 0:ae.setDate(ne);break;case 1:QP(ae,ne);break;case 2:ae.setFullYear(ne);break;case 3:ap(ae,ne);break;case 4:ae.setMinutes(ne);break;case 5:cp(ae,ne);break}else if(i===It.TIME)switch(q){case 0:ap(ae,ne);break;case 1:ae.setMinutes(ne);break;case 2:cp(ae,ne);break}return C(ae)},k=(X,q)=>{const ne=I(X,q);"date"in e||w(ne),e.onDateChange&&e.onDateChange(ne),e.onValueChange&&e.onValueChange(X,q)},U=(X,q)=>{if(e.onScrollChange){const ne=I(X,q);e.onScrollChange(ne,X,q)}},G=()=>{const X=S(),q=X.getFullYear(),ne=X.getMonth(),ae=m(),B=x(),H=_(),J=$(),ee=O(),te=M(),Z=[];for(let Xe=ae;Xe<=B;Xe+=1)Z.push({value:`${Xe}`,label:`${Xe}`});const ge={key:"year",props:{children:Z}};if(i===It.YEAR)return[ge];const Te=[];let Ie=0,Ae=11;ae===q&&(Ie=H),B===q&&(Ae=J);for(let Xe=Ie;Xe<=Ae;Xe+=1){const Rt=h?h(Xe,X):JP(Xe);Te.push({value:`${Xe}`,label:Rt})}const $e={key:"month",props:{children:Te}};if(i===It.MONTH)return[$e,ge];const Ye=[];let je=1,vt=jv(X);ae===q&&H===ne&&(je=ee),B===q&&J===ne&&(vt=te);for(let Xe=je;Xe<=vt;Xe+=1){const Rt=f?f(Xe,X):`${Xe}`;Ye.push({value:`${Xe}`,label:Rt})}return[{key:"day",props:{children:Ye}},$e,ge]},ue=X=>{let{minHour:q=0,maxHour:ne=23,minMinute:ae=0,maxMinute:B=59}=e;const H=K(),J=V(),ee=N(),te=j(),Z=X.getHours();if(i===It.DATE_TIME){const $e=X.getFullYear(),Ye=X.getMonth(),je=X.getDate(),vt=m(),Xe=x(),Rt=_(),st=$(),Ft=O(),Pe=M();vt===$e&&Rt===Ye&&Ft===je&&(q=ee,ee===Z&&(ae=H)),Xe===$e&&st===Ye&&Pe===je&&(ne=te,te===Z&&(B=J))}else q=ee,ee===Z&&(ae=H),ne=te,te===Z&&(B=J);const ge=[];q===0&&ne===0||q!==0&&ne!==0?q=lp(q):q===0&&c&&(q=1,ge.push({value:"0",label:"12"})),ne=lp(ne);for(let $e=q;$e<=ne;$e+=1)ge.push({value:`${$e}`,label:Ta($e)});const Te=[],Ie=X.getMinutes();for(let $e=ae;$e<=B;$e+=a)Te.push({value:`${$e}`,label:Ta($e)}),Ie>$e&&Ie<$e+a&&Te.push({value:`${Ie}`,label:Ta(Ie)});return{cols:[{key:"hours",props:{children:ge}},{key:"minutes",props:{children:Te}}].concat(c?[{key:"ampm",props:{children:[{value:"0",label:r.am},{value:"1",label:r.pm}]}}]:[]),selMinute:Ie}},W=()=>{const X=S();let q=[],ne=[];if(i===It.YEAR)return{cols:G(),value:[`${X.getFullYear()}`]};if(i===It.MONTH)return{cols:G(),value:[`${X.getMonth()}`,`${X.getFullYear()}`]};if((i===It.DATE_TIME||i===It.DATE)&&(q=G(),ne=[`${X.getDate()}`,`${X.getMonth()}`,`${X.getFullYear()}`]),i===It.DATE_TIME||i===It.TIME){const ae=ue(X);q=q.concat(ae.cols);const B=X.getHours();let H=[`${B}`,`${ae.selMinute}`],J=B;c&&(J=B>12?B-12:B,H=[`${J}`,`${ae.selMinute}`,`${B>=12?1:0}`]),ne=ne.concat(H)}return{value:ne,cols:q}},{value:L,cols:oe}=W();return D.jsx(Nv,{className:s,selectedValue:L,onValueChange:k,onScrollChange:U,children:oe.map(X=>D.jsx(lc,{disabled:o,className:`picker-item-${X.key}`,children:X.props.children.map(q=>D.jsx(lc.Item,{value:q.value,children:q.label},q.value))},X.key))})};var uc={exports:{}},lt={};/** @license React v17.0.2
|
|
133
|
+
}`),ve.bindAttribLocation(_e,0,"vertex"),ve.bindAttribLocation(_e,1,"uv"),ve.linkProgram(_e),ke=ve.getProgramInfoLog(_e),0<ke.trim().length)throw ke;Y=ve.getUniformLocation(_e,"mat"),re=ve.getUniformLocation(_e,"translate"),ve.useProgram(_e),ve.bindBuffer(ve.ARRAY_BUFFER,ve.createBuffer()),ve.enableVertexAttribArray(0),ve.enableVertexAttribArray(1),ve.bindBuffer(ve.ELEMENT_ARRAY_BUFFER,ve.createBuffer()),ve.uniform1i(ve.getUniformLocation(_e,"image"),0),ve.pixelStorei(ve.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0),g=ve}return!0}let g=null,R=0,A=0,Y=null,re=null,ce=0,se=0;this.wb=function(){return w(),A},this.gb=function(_e){if(!w())return null;const ke=g.createTexture();return g.bindTexture(g.TEXTURE_2D,ke),g.texImage2D(g.TEXTURE_2D,0,g.RGBA,g.RGBA,g.UNSIGNED_BYTE,_e),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_S,g.CLAMP_TO_EDGE),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_WRAP_T,g.CLAMP_TO_EDGE),g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MAG_FILTER,g.LINEAR),R==2?(g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,g.LINEAR_MIPMAP_LINEAR),g.generateMipmap(g.TEXTURE_2D)):g.texParameteri(g.TEXTURE_2D,g.TEXTURE_MIN_FILTER,g.LINEAR),ke};const de=new S(8),le=new S(8),me=new S(10),Ee=new S(10);this.kb=function(_e,ke,ve,pt,Tt){if(w()){var Ve=de.push(_e),Be=le.push(ke);(g.canvas.width!=Ve||g.canvas.height!=Be)&&(g.canvas.width=Ve,g.canvas.height=Be),g.viewport(0,Be-ke,_e,ke),g.disable(g.SCISSOR_TEST),g.clearColor(0,0,0,0),g.clear(g.COLOR_BUFFER_BIT),g.enable(g.SCISSOR_TEST),ve.sort((ze,tr)=>tr.Ua-ze.Ua),Ve=me.push(pt),ce!=Ve&&(g.bufferData(g.ARRAY_BUFFER,8*Ve,g.DYNAMIC_DRAW),ce=Ve),Ve=0;for(var St of ve)g.bufferSubData(g.ARRAY_BUFFER,Ve,St.Da),Ve+=4*St.Da.length;console.assert(Ve==4*pt);for(var Jt of ve)g.bufferSubData(g.ARRAY_BUFFER,Ve,Jt.Xa),Ve+=4*Jt.Xa.length;console.assert(Ve==8*pt),Ve=Ee.push(Tt),se!=Ve&&(g.bufferData(g.ELEMENT_ARRAY_BUFFER,2*Ve,g.DYNAMIC_DRAW),se=Ve),St=0;for(var jn of ve)g.bufferSubData(g.ELEMENT_ARRAY_BUFFER,St,jn.indices),St+=2*jn.indices.length;console.assert(St==2*Tt),jn=0,Jt=!0,Ve=St=0;for(const ze of ve){ze.image.za!=jn&&(g.bindTexture(g.TEXTURE_2D,ze.image.cb||null),jn=ze.image.za),ze.zb?(g.scissor(ze.Ia,Be-ze.Ja-ze.Pa,ze.Gb,ze.Pa),Jt=!0):Jt&&(g.scissor(0,Be-ke,_e,ke),Jt=!1),ve=2/_e;const tr=-2/ke;g.uniform4f(Y,ze.oa[0]*ve*ze.va,ze.oa[1]*tr*ze.wa,ze.oa[2]*ve*ze.va,ze.oa[3]*tr*ze.wa),g.uniform2f(re,ze.oa[4]*ve*ze.va+ve*(ze.Ia-ze.xb*ze.va)-1,ze.oa[5]*tr*ze.wa+tr*(ze.Ja-ze.yb*ze.wa)+1),g.vertexAttribPointer(0,2,g.FLOAT,!1,0,Ve),g.vertexAttribPointer(1,2,g.FLOAT,!1,0,Ve+4*pt),g.drawElements(g.TRIANGLES,ze.indices.length,g.UNSIGNED_SHORT,St),Ve+=4*ze.Da.length,St+=2*ze.indices.length}console.assert(Ve==4*pt),console.assert(St==2*Tt)}},this.canvas=function(){return w()&&g.canvas}};p.onRuntimeInitialized=function(){function w(pe){switch(pe){case le.srcOver:return"source-over";case le.screen:return"screen";case le.overlay:return"overlay";case le.darken:return"darken";case le.lighten:return"lighten";case le.colorDodge:return"color-dodge";case le.colorBurn:return"color-burn";case le.hardLight:return"hard-light";case le.softLight:return"soft-light";case le.difference:return"difference";case le.exclusion:return"exclusion";case le.multiply:return"multiply";case le.hue:return"hue";case le.saturation:return"saturation";case le.color:return"color";case le.luminosity:return"luminosity"}}function g(pe){return"rgba("+((16711680&pe)>>>16)+","+((65280&pe)>>>8)+","+((255&pe)>>>0)+","+((4278190080&pe)>>>24)/255+")"}function R(){0<St.length&&(m.kb(Be.drawWidth(),Be.drawHeight(),St,Jt,jn),St=[],jn=Jt=0,Be.reset(512,512));for(const pe of Ve){for(const Oe of pe.da)Oe();pe.da=[]}Ve.clear()}var A=p.RenderPaintStyle;const Y=p.RenderPath,re=p.RenderPaint,ce=p.Renderer,se=p.StrokeCap,de=p.StrokeJoin,le=p.BlendMode,me=A.fill,Ee=A.stroke,_e=p.FillRule.evenOdd;let ke=1;var ve=p.RenderImage.extend("CanvasRenderImage",{__construct:function(){this.__parent.__construct.call(this),this.za=ke,ke=ke+1&2147483647||1},decode:function(pe){let Oe=Xs;Oe.total++;var at=this,tt=new Image;tt.src=URL.createObjectURL(new Blob([pe],{type:"image/png"})),tt.onload=function(){if(at.ab=tt,at.cb=m.gb(tt),at.size(tt.width,tt.height),Oe.loaded++,Oe.loaded===Oe.total){const ct=Oe.ready;ct&&(ct(),Oe.ready=null)}}}}),pt=Y.extend("CanvasRenderPath",{__construct:function(){this.__parent.__construct.call(this),this.ia=new Path2D},rewind:function(){this.ia=new Path2D},addPath:function(pe,Oe,at,tt,ct,bt,Ze){var rt=this.ia,ln=rt.addPath;pe=pe.ia;const Dt=new DOMMatrix;Dt.a=Oe,Dt.b=at,Dt.c=tt,Dt.d=ct,Dt.e=bt,Dt.f=Ze,ln.call(rt,pe,Dt)},fillRule:function(pe){this.Ga=pe},moveTo:function(pe,Oe){this.ia.moveTo(pe,Oe)},lineTo:function(pe,Oe){this.ia.lineTo(pe,Oe)},cubicTo:function(pe,Oe,at,tt,ct,bt){this.ia.bezierCurveTo(pe,Oe,at,tt,ct,bt)},close:function(){this.ia.closePath()}}),Tt=re.extend("CanvasRenderPaint",{color:function(pe){this.Ha=g(pe)},thickness:function(pe){this.eb=pe},join:function(pe){switch(pe){case de.miter:this.ya="miter";break;case de.round:this.ya="round";break;case de.bevel:this.ya="bevel"}},cap:function(pe){switch(pe){case se.butt:this.xa="butt";break;case se.round:this.xa="round";break;case se.square:this.xa="square"}},style:function(pe){this.bb=pe},blendMode:function(pe){this.$a=w(pe)},clearGradient:function(){this.qa=null},linearGradient:function(pe,Oe,at,tt){this.qa={Va:pe,Wa:Oe,La:at,Ma:tt,Ca:[]}},radialGradient:function(pe,Oe,at,tt){this.qa={Va:pe,Wa:Oe,La:at,Ma:tt,Ca:[],ub:!0}},addStop:function(pe,Oe){this.qa.Ca.push({color:pe,stop:Oe})},completeGradient:function(){},draw:function(pe,Oe,at){let tt=this.bb;var ct=this.Ha,bt=this.qa;if(pe.globalCompositeOperation=this.$a,bt!=null){ct=bt.Va;var Ze=bt.Wa;const ln=bt.La;var rt=bt.Ma;const Dt=bt.Ca;bt.ub?(bt=ln-ct,rt-=Ze,ct=pe.createRadialGradient(ct,Ze,0,ct,Ze,Math.sqrt(bt*bt+rt*rt))):ct=pe.createLinearGradient(ct,Ze,ln,rt);for(let Tn=0,kt=Dt.length;Tn<kt;Tn++)Ze=Dt[Tn],ct.addColorStop(Ze.stop,g(Ze.color));this.Ha=ct,this.qa=null}switch(tt){case Ee:pe.strokeStyle=ct,pe.lineWidth=this.eb,pe.lineCap=this.xa,pe.lineJoin=this.ya,pe.stroke(Oe);break;case me:pe.fillStyle=ct,pe.fill(Oe,at)}}});const Ve=new Set;let Be=null,St=[],Jt=0,jn=0;var ze=p.CanvasRenderer=ce.extend("Renderer",{__construct:function(pe){this.__parent.__construct.call(this),this.ha=[1,0,0,1,0,0],this.ba=pe.getContext("2d"),this.Fa=pe,this.da=[]},save:function(){this.ha.push(...this.ha.slice(this.ha.length-6)),this.da.push(this.ba.save.bind(this.ba))},restore:function(){const pe=this.ha.length-6;if(6>pe)throw"restore() called without matching save().";this.ha.splice(pe),this.da.push(this.ba.restore.bind(this.ba))},transform:function(pe,Oe,at,tt,ct,bt){const Ze=this.ha,rt=Ze.length-6;Ze.splice(rt,6,Ze[rt]*pe+Ze[rt+2]*Oe,Ze[rt+1]*pe+Ze[rt+3]*Oe,Ze[rt]*at+Ze[rt+2]*tt,Ze[rt+1]*at+Ze[rt+3]*tt,Ze[rt]*ct+Ze[rt+2]*bt+Ze[rt+4],Ze[rt+1]*ct+Ze[rt+3]*bt+Ze[rt+5]),this.da.push(this.ba.transform.bind(this.ba,pe,Oe,at,tt,ct,bt))},rotate:function(pe){const Oe=Math.sin(pe);pe=Math.cos(pe),this.transform(pe,Oe,-Oe,pe,0,0)},_drawPath:function(pe,Oe){this.da.push(Oe.draw.bind(Oe,this.ba,pe.ia,pe.Ga===_e?"evenodd":"nonzero"))},drawImage:function(pe,...Oe){var at=this.ba;this.da.push(function(){at.drawImage(pe,...Oe)})},_drawRiveImage:function(pe,Oe,at){var tt=pe.ab;if(tt){var ct=this.ba,bt=w(Oe);this.da.push(function(){ct.globalCompositeOperation=bt,ct.globalAlpha=at,ct.drawImage(tt,0,0),ct.globalAlpha=1})}},_getMatrix:function(pe){const Oe=this.ha,at=Oe.length-6;for(let tt=0;6>tt;++tt)pe[tt]=Oe[at+tt]},_drawImageMesh:function(pe,Oe,at,tt,ct,bt,Ze,rt,ln,Dt){var Tn=this.ba.canvas.width,kt=this.ba.canvas.height;const Ou=ln-Ze,Mu=Dt-rt;Ze=Math.max(Ze,0),rt=Math.max(rt,0),ln=Math.min(ln,Tn),Dt=Math.min(Dt,kt);const go=ln-Ze,yo=Dt-rt;if(console.assert(go<=Math.min(Ou,Tn)),console.assert(yo<=Math.min(Mu,kt)),!(0>=go||0>=yo)){ln=go<Ou||yo<Mu,Tn=Dt=1;var wr=Math.ceil(go*Dt),xr=Math.ceil(yo*Tn);kt=m.wb(),wr>kt&&(Dt*=kt/wr,wr=kt),xr>kt&&(Tn*=kt/xr,xr=kt),Be||(Be=new p.DynamicRectanizer(kt),Be.reset(512,512)),kt=Be.addRect(wr,xr),0>kt&&(R(),Ve.add(this),kt=Be.addRect(wr,xr),console.assert(0<=kt));var ku=kt&65535,Nu=kt>>16;St.push({oa:this.ha.slice(this.ha.length-6),image:pe,Ia:ku,Ja:Nu,xb:Ze,yb:rt,Gb:wr,Pa:xr,va:Dt,wa:Tn,Da:new Float32Array(tt),Xa:new Float32Array(ct),indices:new Uint16Array(bt),zb:ln,Ua:pe.za<<1|(ln?1:0)}),Jt+=tt.length,jn+=bt.length;var Hr=this.ba,vy=w(Oe);this.da.push(function(){Hr.save(),Hr.resetTransform(),Hr.globalCompositeOperation=vy,Hr.globalAlpha=at,Hr.drawImage(m.canvas(),ku,Nu,wr,xr,Ze,rt,go,yo),Hr.restore()})}},_clipPath:function(pe){this.da.push(this.ba.clip.bind(this.ba,pe.ia,pe.Ga===_e?"evenodd":"nonzero"))},clear:function(){Ve.add(this),this.da.push(this.ba.clearRect.bind(this.ba,0,0,this.Fa.width,this.Fa.height))},flush:function(){},translate:function(pe,Oe){this.transform(1,0,0,1,pe,Oe)}});p.makeRenderer=function(pe){return new ze(pe)},p.renderFactory={makeRenderPaint:function(){return new Tt},makeRenderPath:function(){return new pt},makeRenderImage:function(){return new ve}};let tr=p.load,Xs=null;p.load=function(pe){return new Promise(function(Oe){let at=null;Xs={total:0,loaded:0,ready:function(){Oe(at)}},at=tr(pe),Xs.total==0&&Oe(at)})},A=new T,p.requestAnimationFrame=A.requestAnimationFrame.bind(A),p.cancelAnimationFrame=A.cancelAnimationFrame.bind(A),p.enableFPSCounter=A.lb.bind(A),p.disableFPSCounter=A.ib,A.Qa=R,p.cleanup=function(){Be&&Be.delete()}};var x=Object.assign({},p),_="./this.program",$=typeof window=="object",M=typeof importScripts=="function",D="",N,j;($||M)&&(M?D=self.location.href:typeof document<"u"&&document.currentScript&&(D=document.currentScript.src),f&&(D=f),D.indexOf("blob:")!==0?D=D.substr(0,D.replace(/[?#].*/,"").lastIndexOf("/")+1):D="",M&&(j=w=>{var g=new XMLHttpRequest;return g.open("GET",w,!1),g.responseType="arraybuffer",g.send(null),new Uint8Array(g.response)}),N=(w,g,R)=>{var A=new XMLHttpRequest;A.open("GET",w,!0),A.responseType="arraybuffer",A.onload=()=>{A.status==200||A.status==0&&A.response?g(A.response):R()},A.onerror=R,A.send(null)});var K=p.print||console.log.bind(console),V=p.printErr||console.error.bind(console);Object.assign(p,x),x=null,p.thisProgram&&(_=p.thisProgram);var P;p.wasmBinary&&(P=p.wasmBinary),p.noExitRuntime,typeof WebAssembly!="object"&&te("no native wasm support detected");var v,C=!1,I,k,U,G,ue,W,L,oe;function X(){var w=v.buffer;p.HEAP8=I=new Int8Array(w),p.HEAP16=U=new Int16Array(w),p.HEAP32=ue=new Int32Array(w),p.HEAPU8=k=new Uint8Array(w),p.HEAPU16=G=new Uint16Array(w),p.HEAPU32=W=new Uint32Array(w),p.HEAPF32=L=new Float32Array(w),p.HEAPF64=oe=new Float64Array(w)}var q,ne=[],ae=[],B=[];function H(){var w=p.preRun.shift();ne.unshift(w)}var J=0,ee=null;function te(w){throw p.onAbort&&p.onAbort(w),w="Aborted("+w+")",V(w),C=!0,w=new WebAssembly.RuntimeError(w+". Build with -sASSERTIONS for more info."),E(w),w}function Z(w){return w.startsWith("data:application/octet-stream;base64,")}var ge;if(ge="canvas_advanced.wasm",!Z(ge)){var Te=ge;ge=p.locateFile?p.locateFile(Te,D):D+Te}function Ie(w){if(w==ge&&P)return new Uint8Array(P);if(j)return j(w);throw"both async and sync fetching of the wasm failed"}function Ae(w){if(!P&&($||M)){if(typeof fetch=="function"&&!w.startsWith("file://"))return fetch(w,{credentials:"same-origin"}).then(g=>{if(!g.ok)throw"failed to load wasm binary file at '"+w+"'";return g.arrayBuffer()}).catch(()=>Ie(w));if(N)return new Promise((g,R)=>{N(w,A=>g(new Uint8Array(A)),R)})}return Promise.resolve().then(()=>Ie(w))}function $e(w,g,R){return Ae(w).then(A=>WebAssembly.instantiate(A,g)).then(A=>A).then(R,A=>{V("failed to asynchronously prepare wasm: "+A),te(A)})}function Ye(w,g){var R=ge;return P||typeof WebAssembly.instantiateStreaming!="function"||Z(R)||R.startsWith("file://")||typeof fetch!="function"?$e(R,w,g):fetch(R,{credentials:"same-origin"}).then(A=>WebAssembly.instantiateStreaming(A,w).then(g,function(Y){return V("wasm streaming compile failed: "+Y),V("falling back to ArrayBuffer instantiation"),$e(R,w,g)}))}var je=w=>{for(;0<w.length;)w.shift()(p)};function vt(w){if(w===void 0)return"_unknown";w=w.replace(/[^a-zA-Z0-9_]/g,"$");var g=w.charCodeAt(0);return 48<=g&&57>=g?`_${w}`:w}function Xe(w,g){return w=vt(w),{[w]:function(){return g.apply(this,arguments)}}[w]}function Rt(){this.ja=[void 0],this.Oa=[]}var st=new Rt,Ft=void 0;function Pe(w){throw new Ft(w)}var Ot=w=>(w||Pe("Cannot use deleted val. handle = "+w),st.get(w).value),gt=w=>{switch(w){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:return st.Ya({Ta:1,value:w})}};function bn(w){var g=Error,R=Xe(w,function(A){this.name=w,this.message=A,A=Error(A).stack,A!==void 0&&(this.stack=this.toString()+`
|
|
134
|
+
`+A.replace(/^Error(:[^\n]*)?\n/,""))});return R.prototype=Object.create(g.prototype),R.prototype.constructor=R,R.prototype.toString=function(){return this.message===void 0?this.name:`${this.name}: ${this.message}`},R}var Xt=void 0,Nt=void 0;function Fe(w){for(var g="";k[w];)g+=Nt[k[w++]];return g}var Mt=[];function Gt(){for(;Mt.length;){var w=Mt.pop();w.W.na=!1,w.delete()}}var On=void 0,Zt={};function yr(w,g){for(g===void 0&&Pe("ptr should not be undefined");w.$;)g=w.ra(g),w=w.$;return g}var mn={};function Br(w){w=Au(w);var g=Fe(w);return Nn(w),g}function Qt(w,g){var R=mn[w];return R===void 0&&Pe(g+" has unknown type "+Br(w)),R}function wn(){}var jt=!1;function xn(w){--w.count.value,w.count.value===0&&(w.ca?w.fa.ka(w.ca):w.Z.X.ka(w.Y))}function En(w,g,R){return g===R?w:R.$===void 0?null:(w=En(w,g,R.$),w===null?null:R.jb(w))}var Xn={};function vo(w,g){return g=yr(w,g),Zt[g]}var Gn=void 0;function Zn(w){throw new Gn(w)}function Cn(w,g){return g.Z&&g.Y||Zn("makeClassHandle requires ptr and ptrType"),!!g.fa!=!!g.ca&&Zn("Both smartPtrType and smartPtr must be specified"),g.count={value:1},cn(Object.create(w,{W:{value:g}}))}function cn(w){return typeof FinalizationRegistry>"u"?(cn=g=>g,w):(jt=new FinalizationRegistry(g=>{xn(g.W)}),cn=g=>{var R=g.W;return R.ca&&jt.register(g,{W:R},g),g},wn=g=>{jt.unregister(g)},cn(w))}var Qn={};function Mn(w){for(;w.length;){var g=w.pop();w.pop()(g)}}function vn(w){return this.fromWireType(ue[w>>2])}var _n={},Jn={};function Vt(w,g,R){function A(se){se=R(se),se.length!==w.length&&Zn("Mismatched type converter count");for(var de=0;de<w.length;++de)F(w[de],se[de])}w.forEach(function(se){Jn[se]=g});var Y=Array(g.length),re=[],ce=0;g.forEach((se,de)=>{mn.hasOwnProperty(se)?Y[de]=mn[se]:(re.push(se),_n.hasOwnProperty(se)||(_n[se]=[]),_n[se].push(()=>{Y[de]=mn[se],++ce,ce===re.length&&A(Y)}))}),re.length===0&&A(Y)}function er(w){switch(w){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError(`Unknown type size: ${w}`)}}function b(w,g,R={}){var A=g.name;if(w||Pe(`type "${A}" must have a positive integer typeid pointer`),mn.hasOwnProperty(w)){if(R.tb)return;Pe(`Cannot register type '${A}' twice`)}mn[w]=g,delete Jn[w],_n.hasOwnProperty(w)&&(g=_n[w],delete _n[w],g.forEach(Y=>Y()))}function F(w,g,R={}){if(!("argPackAdvance"in g))throw new TypeError("registerType registeredInstance requires argPackAdvance");b(w,g,R)}function Q(w){Pe(w.W.Z.X.name+" instance already deleted")}function fe(){}function xe(w,g,R){if(w[g].aa===void 0){var A=w[g];w[g]=function(){return w[g].aa.hasOwnProperty(arguments.length)||Pe(`Function '${R}' called with an invalid number of arguments (${arguments.length}) - expects one of (${w[g].aa})!`),w[g].aa[arguments.length].apply(this,arguments)},w[g].aa=[],w[g].aa[A.ma]=A}}function Se(w,g,R){p.hasOwnProperty(w)?((R===void 0||p[w].aa!==void 0&&p[w].aa[R]!==void 0)&&Pe(`Cannot register public name '${w}' twice`),xe(p,w,w),p.hasOwnProperty(R)&&Pe(`Cannot register multiple overloads of a function with the same number of arguments (${R})!`),p[w].aa[R]=g):(p[w]=g,R!==void 0&&(p[w].Hb=R))}function be(w,g,R,A,Y,re,ce,se){this.name=w,this.constructor=g,this.ga=R,this.ka=A,this.$=Y,this.ob=re,this.ra=ce,this.jb=se,this.Ra=[]}function ye(w,g,R){for(;g!==R;)g.ra||Pe(`Expected null or instance of ${R.name}, got an instance of ${g.name}`),w=g.ra(w),g=g.$;return w}function Ge(w,g){return g===null?(this.Aa&&Pe(`null is not a valid ${this.name}`),0):(g.W||Pe(`Cannot pass "${Ys(g)}" as a ${this.name}`),g.W.Y||Pe(`Cannot pass deleted object as a pointer of type ${this.name}`),ye(g.W.Y,g.W.Z.X,this.X))}function Ne(w,g){if(g===null){if(this.Aa&&Pe(`null is not a valid ${this.name}`),this.ua){var R=this.Ba();return w!==null&&w.push(this.ka,R),R}return 0}if(g.W||Pe(`Cannot pass "${Ys(g)}" as a ${this.name}`),g.W.Y||Pe(`Cannot pass deleted object as a pointer of type ${this.name}`),!this.ta&&g.W.Z.ta&&Pe(`Cannot convert argument of type ${g.W.fa?g.W.fa.name:g.W.Z.name} to parameter type ${this.name}`),R=ye(g.W.Y,g.W.Z.X,this.X),this.ua)switch(g.W.ca===void 0&&Pe("Passing raw pointer to smart pointer is illegal"),this.Fb){case 0:g.W.fa===this?R=g.W.ca:Pe(`Cannot convert argument of type ${g.W.fa?g.W.fa.name:g.W.Z.name} to parameter type ${this.name}`);break;case 1:R=g.W.ca;break;case 2:if(g.W.fa===this)R=g.W.ca;else{var A=g.clone();R=this.Bb(R,gt(function(){A.delete()})),w!==null&&w.push(this.ka,R)}break;default:Pe("Unsupporting sharing policy")}return R}function Le(w,g){return g===null?(this.Aa&&Pe(`null is not a valid ${this.name}`),0):(g.W||Pe(`Cannot pass "${Ys(g)}" as a ${this.name}`),g.W.Y||Pe(`Cannot pass deleted object as a pointer of type ${this.name}`),g.W.Z.ta&&Pe(`Cannot convert argument of type ${g.W.Z.name} to parameter type ${this.name}`),ye(g.W.Y,g.W.Z.X,this.X))}function Ue(w,g,R,A){this.name=w,this.X=g,this.Aa=R,this.ta=A,this.ua=!1,this.ka=this.Bb=this.Ba=this.Sa=this.Fb=this.Ab=void 0,g.$!==void 0?this.toWireType=Ne:(this.toWireType=A?Ge:Le,this.ea=null)}function Bt(w,g,R){p.hasOwnProperty(w)||Zn("Replacing nonexistant public symbol"),p[w].aa!==void 0&&R!==void 0?p[w].aa[R]=g:(p[w]=g,p[w].ma=R)}var br=(w,g)=>{var R=[];return function(){if(R.length=0,Object.assign(R,arguments),w.includes("j")){var A=p["dynCall_"+w];A=R&&R.length?A.apply(null,[g].concat(R)):A.call(null,g)}else A=q.get(g).apply(null,R);return A}};function We(w,g){w=Fe(w);var R=w.includes("j")?br(w,g):q.get(g);return typeof R!="function"&&Pe(`unknown function pointer with signature ${w}: ${g}`),R}var Cu=void 0;function kn(w,g){function R(re){Y[re]||mn[re]||(Jn[re]?Jn[re].forEach(R):(A.push(re),Y[re]=!0))}var A=[],Y={};throw g.forEach(R),new Cu(`${w}: `+A.map(Br).join([", "]))}function ri(w,g,R,A,Y){var re=g.length;2>re&&Pe("argTypes array size mismatch! Must at least get return value and 'this' types!");var ce=g[1]!==null&&R!==null,se=!1;for(R=1;R<g.length;++R)if(g[R]!==null&&g[R].ea===void 0){se=!0;break}var de=g[0].name!=="void",le=re-2,me=Array(le),Ee=[],_e=[];return function(){if(arguments.length!==le&&Pe(`function ${w} called with ${arguments.length} arguments, expected ${le} args!`),_e.length=0,Ee.length=ce?2:1,Ee[0]=Y,ce){var ke=g[1].toWireType(_e,this);Ee[1]=ke}for(var ve=0;ve<le;++ve)me[ve]=g[ve+2].toWireType(_e,arguments[ve]),Ee.push(me[ve]);if(ve=A.apply(null,Ee),se)Mn(_e);else for(var pt=ce?1:2;pt<g.length;pt++){var Tt=pt===1?ke:me[pt-2];g[pt].ea!==null&&g[pt].ea(Tt)}return ke=de?g[0].fromWireType(ve):void 0,ke}}function oi(w,g){for(var R=[],A=0;A<w;A++)R.push(W[g+4*A>>2]);return R}function _u(w,g,R){return w instanceof Object||Pe(`${R} with invalid "this": ${w}`),w instanceof g.X.constructor||Pe(`${R} incompatible with "this" of type ${w.constructor.name}`),w.W.Y||Pe(`cannot call emscripten binding method ${R} on deleted object`),ye(w.W.Y,w.W.Z.X,g.X)}function Us(w){w>=st.Ea&&--st.get(w).Ta===0&&st.Za(w)}function ny(w,g,R){switch(g){case 0:return function(A){return this.fromWireType((R?I:k)[A])};case 1:return function(A){return this.fromWireType((R?U:G)[A>>1])};case 2:return function(A){return this.fromWireType((R?ue:W)[A>>2])};default:throw new TypeError("Unknown integer type: "+w)}}function Ys(w){if(w===null)return"null";var g=typeof w;return g==="object"||g==="array"||g==="function"?w.toString():""+w}function ry(w,g){switch(g){case 2:return function(R){return this.fromWireType(L[R>>2])};case 3:return function(R){return this.fromWireType(oe[R>>3])};default:throw new TypeError("Unknown float type: "+w)}}function oy(w,g,R){switch(g){case 0:return R?function(A){return I[A]}:function(A){return k[A]};case 1:return R?function(A){return U[A>>1]}:function(A){return G[A>>1]};case 2:return R?function(A){return ue[A>>2]}:function(A){return W[A>>2]};default:throw new TypeError("Unknown integer type: "+w)}}var Tu=typeof TextDecoder<"u"?new TextDecoder("utf8"):void 0,Su=(w,g,R)=>{var A=g+R;for(R=g;w[R]&&!(R>=A);)++R;if(16<R-g&&w.buffer&&Tu)return Tu.decode(w.subarray(g,R));for(A="";g<R;){var Y=w[g++];if(Y&128){var re=w[g++]&63;if((Y&224)==192)A+=String.fromCharCode((Y&31)<<6|re);else{var ce=w[g++]&63;Y=(Y&240)==224?(Y&15)<<12|re<<6|ce:(Y&7)<<18|re<<12|ce<<6|w[g++]&63,65536>Y?A+=String.fromCharCode(Y):(Y-=65536,A+=String.fromCharCode(55296|Y>>10,56320|Y&1023))}}else A+=String.fromCharCode(Y)}return A},$u=typeof TextDecoder<"u"?new TextDecoder("utf-16le"):void 0,iy=(w,g)=>{for(var R=w>>1,A=R+g/2;!(R>=A)&&G[R];)++R;if(R<<=1,32<R-w&&$u)return $u.decode(k.subarray(w,R));for(R="",A=0;!(A>=g/2);++A){var Y=U[w+2*A>>1];if(Y==0)break;R+=String.fromCharCode(Y)}return R},sy=(w,g,R)=>{if(R===void 0&&(R=2147483647),2>R)return 0;R-=2;var A=g;R=R<2*w.length?R/2:w.length;for(var Y=0;Y<R;++Y)U[g>>1]=w.charCodeAt(Y),g+=2;return U[g>>1]=0,g-A},ay=w=>2*w.length,cy=(w,g)=>{for(var R=0,A="";!(R>=g/4);){var Y=ue[w+4*R>>2];if(Y==0)break;++R,65536<=Y?(Y-=65536,A+=String.fromCharCode(55296|Y>>10,56320|Y&1023)):A+=String.fromCharCode(Y)}return A},ly=(w,g,R)=>{if(R===void 0&&(R=2147483647),4>R)return 0;var A=g;R=A+R-4;for(var Y=0;Y<w.length;++Y){var re=w.charCodeAt(Y);if(55296<=re&&57343>=re){var ce=w.charCodeAt(++Y);re=65536+((re&1023)<<10)|ce&1023}if(ue[g>>2]=re,g+=4,g+4>R)break}return ue[g>>2]=0,g-A},uy=w=>{for(var g=0,R=0;R<w.length;++R){var A=w.charCodeAt(R);55296<=A&&57343>=A&&++R,g+=4}return g},dy={};function ii(w){var g=dy[w];return g===void 0?Fe(w):g}var si=[];function fy(w){var g=si.length;return si.push(w),g}function py(w,g){for(var R=Array(w),A=0;A<w;++A)R[A]=Qt(W[g+4*A>>2],"parameter "+A);return R}var Pu=[],zs={},Ru=()=>{if(!Ks){var w={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:(typeof navigator=="object"&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:_||"./this.program"},g;for(g in zs)zs[g]===void 0?delete w[g]:w[g]=zs[g];var R=[];for(g in w)R.push(`${g}=${w[g]}`);Ks=R}return Ks},Ks,hy=[null,[],[]];Object.assign(Rt.prototype,{get(w){return this.ja[w]},has(w){return this.ja[w]!==void 0},Ya(w){var g=this.Oa.pop()||this.ja.length;return this.ja[g]=w,g},Za(w){this.ja[w]=void 0,this.Oa.push(w)}}),Ft=p.BindingError=class extends Error{constructor(w){super(w),this.name="BindingError"}},st.ja.push({value:void 0},{value:null},{value:!0},{value:!1}),st.Ea=st.ja.length,p.count_emval_handles=function(){for(var w=0,g=st.Ea;g<st.ja.length;++g)st.ja[g]!==void 0&&++w;return w},Xt=p.PureVirtualError=bn("PureVirtualError");for(var Iu=Array(256),ai=0;256>ai;++ai)Iu[ai]=String.fromCharCode(ai);Nt=Iu,p.getInheritedInstanceCount=function(){return Object.keys(Zt).length},p.getLiveInheritedInstances=function(){var w=[],g;for(g in Zt)Zt.hasOwnProperty(g)&&w.push(Zt[g]);return w},p.flushPendingDeletes=Gt,p.setDelayFunction=function(w){On=w,Mt.length&&On&&On(Gt)},Gn=p.InternalError=class extends Error{constructor(w){super(w),this.name="InternalError"}},fe.prototype.isAliasOf=function(w){if(!(this instanceof fe&&w instanceof fe))return!1;var g=this.W.Z.X,R=this.W.Y,A=w.W.Z.X;for(w=w.W.Y;g.$;)R=g.ra(R),g=g.$;for(;A.$;)w=A.ra(w),A=A.$;return g===A&&R===w},fe.prototype.clone=function(){if(this.W.Y||Q(this),this.W.pa)return this.W.count.value+=1,this;var w=cn,g=Object,R=g.create,A=Object.getPrototypeOf(this),Y=this.W;return w=w(R.call(g,A,{W:{value:{count:Y.count,na:Y.na,pa:Y.pa,Y:Y.Y,Z:Y.Z,ca:Y.ca,fa:Y.fa}}})),w.W.count.value+=1,w.W.na=!1,w},fe.prototype.delete=function(){this.W.Y||Q(this),this.W.na&&!this.W.pa&&Pe("Object already scheduled for deletion"),wn(this),xn(this.W),this.W.pa||(this.W.ca=void 0,this.W.Y=void 0)},fe.prototype.isDeleted=function(){return!this.W.Y},fe.prototype.deleteLater=function(){return this.W.Y||Q(this),this.W.na&&!this.W.pa&&Pe("Object already scheduled for deletion"),Mt.push(this),Mt.length===1&&On&&On(Gt),this.W.na=!0,this},Ue.prototype.pb=function(w){return this.Sa&&(w=this.Sa(w)),w},Ue.prototype.Ka=function(w){this.ka&&this.ka(w)},Ue.prototype.argPackAdvance=8,Ue.prototype.readValueFromPointer=vn,Ue.prototype.deleteObject=function(w){w!==null&&w.delete()},Ue.prototype.fromWireType=function(w){function g(){return this.ua?Cn(this.X.ga,{Z:this.Ab,Y:R,fa:this,ca:w}):Cn(this.X.ga,{Z:this,Y:w})}var R=this.pb(w);if(!R)return this.Ka(w),null;var A=vo(this.X,R);if(A!==void 0)return A.W.count.value===0?(A.W.Y=R,A.W.ca=w,A.clone()):(A=A.clone(),this.Ka(w),A);if(A=this.X.ob(R),A=Xn[A],!A)return g.call(this);A=this.ta?A.fb:A.pointerType;var Y=En(R,this.X,A.X);return Y===null?g.call(this):this.ua?Cn(A.X.ga,{Z:A,Y,fa:this,ca:w}):Cn(A.X.ga,{Z:A,Y})},Cu=p.UnboundTypeError=bn("UnboundTypeError");var my={I:function(w,g,R){w=Fe(w),g=Qt(g,"wrapper"),R=Ot(R);var A=[].slice,Y=g.X,re=Y.ga,ce=Y.$.ga,se=Y.$.constructor;w=Xe(w,function(){Y.$.Ra.forEach((function(le){if(this[le]===ce[le])throw new Xt(`Pure virtual function ${le} must be implemented in JavaScript`)}).bind(this)),Object.defineProperty(this,"__parent",{value:re}),this.__construct.apply(this,A.call(arguments))}),re.__construct=function(){this===re&&Pe("Pass correct 'this' to __construct");var le=se.implement.apply(void 0,[this].concat(A.call(arguments)));wn(le);var me=le.W;le.notifyOnDestruction(),me.pa=!0,Object.defineProperties(this,{W:{value:me}}),cn(this),le=me.Y,le=yr(Y,le),Zt.hasOwnProperty(le)?Pe(`Tried to register registered instance: ${le}`):Zt[le]=this},re.__destruct=function(){this===re&&Pe("Pass correct 'this' to __destruct"),wn(this);var le=this.W.Y;le=yr(Y,le),Zt.hasOwnProperty(le)?delete Zt[le]:Pe(`Tried to unregister unregistered instance: ${le}`)},w.prototype=Object.create(re);for(var de in R)w.prototype[de]=R[de];return gt(w)},L:function(w){var g=Qn[w];delete Qn[w];var R=g.Ba,A=g.ka,Y=g.Na,re=Y.map(ce=>ce.sb).concat(Y.map(ce=>ce.Db));Vt([w],re,ce=>{var se={};return Y.forEach((de,le)=>{var me=ce[le],Ee=de.qb,_e=de.rb,ke=ce[le+Y.length],ve=de.Cb,pt=de.Eb;se[de.mb]={read:Tt=>me.fromWireType(Ee(_e,Tt)),write:(Tt,Ve)=>{var Be=[];ve(pt,Tt,ke.toWireType(Be,Ve)),Mn(Be)}}}),[{name:g.name,fromWireType:function(de){var le={},me;for(me in se)le[me]=se[me].read(de);return A(de),le},toWireType:function(de,le){for(var me in se)if(!(me in le))throw new TypeError(`Missing field: "${me}"`);var Ee=R();for(me in se)se[me].write(Ee,le[me]);return de!==null&&de.push(A,Ee),Ee},argPackAdvance:8,readValueFromPointer:vn,ea:A}]})},z:function(){},G:function(w,g,R,A,Y){var re=er(R);g=Fe(g),F(w,{name:g,fromWireType:function(ce){return!!ce},toWireType:function(ce,se){return se?A:Y},argPackAdvance:8,readValueFromPointer:function(ce){if(R===1)var se=I;else if(R===2)se=U;else if(R===4)se=ue;else throw new TypeError("Unknown boolean type size: "+g);return this.fromWireType(se[ce>>re])},ea:null})},e:function(w,g,R,A,Y,re,ce,se,de,le,me,Ee,_e){me=Fe(me),re=We(Y,re),se&&(se=We(ce,se)),le&&(le=We(de,le)),_e=We(Ee,_e);var ke=vt(me);Se(ke,function(){kn(`Cannot construct ${me} due to unbound types`,[A])}),Vt([w,g,R],A?[A]:[],function(ve){if(ve=ve[0],A)var pt=ve.X,Tt=pt.ga;else Tt=fe.prototype;ve=Xe(ke,function(){if(Object.getPrototypeOf(this)!==Ve)throw new Ft("Use 'new' to construct "+me);if(Be.la===void 0)throw new Ft(me+" has no accessible constructor");var Jt=Be.la[arguments.length];if(Jt===void 0)throw new Ft(`Tried to invoke ctor of ${me} with invalid number of parameters (${arguments.length}) - expected (${Object.keys(Be.la).toString()}) parameters instead!`);return Jt.apply(this,arguments)});var Ve=Object.create(Tt,{constructor:{value:ve}});ve.prototype=Ve;var Be=new be(me,ve,Ve,_e,pt,re,se,le);Be.$&&(Be.$.sa===void 0&&(Be.$.sa=[]),Be.$.sa.push(Be)),pt=new Ue(me,Be,!0,!1),Tt=new Ue(me+"*",Be,!1,!1);var St=new Ue(me+" const*",Be,!1,!0);return Xn[w]={pointerType:Tt,fb:St},Bt(ke,ve),[pt,Tt,St]})},k:function(w,g,R,A,Y,re,ce){var se=oi(R,A);g=Fe(g),re=We(Y,re),Vt([],[w],function(de){function le(){kn(`Cannot call ${me} due to unbound types`,se)}de=de[0];var me=`${de.name}.${g}`;g.startsWith("@@")&&(g=Symbol[g.substring(2)]);var Ee=de.X.constructor;return Ee[g]===void 0?(le.ma=R-1,Ee[g]=le):(xe(Ee,g,me),Ee[g].aa[R-1]=le),Vt([],se,function(_e){if(_e=ri(me,[_e[0],null].concat(_e.slice(1)),null,re,ce),Ee[g].aa===void 0?(_e.ma=R-1,Ee[g]=_e):Ee[g].aa[R-1]=_e,de.X.sa)for(const ke of de.X.sa)ke.constructor.hasOwnProperty(g)||(ke.constructor[g]=_e);return[]}),[]})},s:function(w,g,R,A,Y,re,ce,se){g=Fe(g),re=We(Y,re),Vt([],[w],function(de){de=de[0];var le=`${de.name}.${g}`,me={get(){kn(`Cannot access ${le} due to unbound types`,[R])},enumerable:!0,configurable:!0};return me.set=se?()=>{kn(`Cannot access ${le} due to unbound types`,[R])}:()=>{Pe(`${le} is a read-only property`)},Object.defineProperty(de.X.constructor,g,me),Vt([],[R],function(Ee){Ee=Ee[0];var _e={get(){return Ee.fromWireType(re(A))},enumerable:!0};return se&&(se=We(ce,se),_e.set=ke=>{var ve=[];se(A,Ee.toWireType(ve,ke)),Mn(ve)}),Object.defineProperty(de.X.constructor,g,_e),[]}),[]})},o:function(w,g,R,A,Y,re){var ce=oi(g,R);Y=We(A,Y),Vt([],[w],function(se){se=se[0];var de=`constructor ${se.name}`;if(se.X.la===void 0&&(se.X.la=[]),se.X.la[g-1]!==void 0)throw new Ft(`Cannot register multiple constructors with identical number of parameters (${g-1}) for class '${se.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return se.X.la[g-1]=()=>{kn(`Cannot construct ${se.name} due to unbound types`,ce)},Vt([],ce,function(le){return le.splice(1,0,null),se.X.la[g-1]=ri(de,le,null,Y,re),[]}),[]})},a:function(w,g,R,A,Y,re,ce,se){var de=oi(R,A);g=Fe(g),re=We(Y,re),Vt([],[w],function(le){function me(){kn(`Cannot call ${Ee} due to unbound types`,de)}le=le[0];var Ee=`${le.name}.${g}`;g.startsWith("@@")&&(g=Symbol[g.substring(2)]),se&&le.X.Ra.push(g);var _e=le.X.ga,ke=_e[g];return ke===void 0||ke.aa===void 0&&ke.className!==le.name&&ke.ma===R-2?(me.ma=R-2,me.className=le.name,_e[g]=me):(xe(_e,g,Ee),_e[g].aa[R-2]=me),Vt([],de,function(ve){return ve=ri(Ee,ve,le,re,ce),_e[g].aa===void 0?(ve.ma=R-2,_e[g]=ve):_e[g].aa[R-2]=ve,[]}),[]})},d:function(w,g,R,A,Y,re,ce,se,de,le){g=Fe(g),Y=We(A,Y),Vt([],[w],function(me){me=me[0];var Ee=`${me.name}.${g}`,_e={get(){kn(`Cannot access ${Ee} due to unbound types`,[R,ce])},enumerable:!0,configurable:!0};return _e.set=de?()=>{kn(`Cannot access ${Ee} due to unbound types`,[R,ce])}:()=>{Pe(Ee+" is a read-only property")},Object.defineProperty(me.X.ga,g,_e),Vt([],de?[R,ce]:[R],function(ke){var ve=ke[0],pt={get(){var Ve=_u(this,me,Ee+" getter");return ve.fromWireType(Y(re,Ve))},enumerable:!0};if(de){de=We(se,de);var Tt=ke[1];pt.set=function(Ve){var Be=_u(this,me,Ee+" setter"),St=[];de(le,Be,Tt.toWireType(St,Ve)),Mn(St)}}return Object.defineProperty(me.X.ga,g,pt),[]}),[]})},F:function(w,g){g=Fe(g),F(w,{name:g,fromWireType:function(R){var A=Ot(R);return Us(R),A},toWireType:function(R,A){return gt(A)},argPackAdvance:8,readValueFromPointer:vn,ea:null})},l:function(w,g,R,A){function Y(){}R=er(R),g=Fe(g),Y.values={},F(w,{name:g,constructor:Y,fromWireType:function(re){return this.constructor.values[re]},toWireType:function(re,ce){return ce.value},argPackAdvance:8,readValueFromPointer:ny(g,R,A),ea:null}),Se(g,Y)},c:function(w,g,R){var A=Qt(w,"enum");g=Fe(g),w=A.constructor,A=Object.create(A.constructor.prototype,{value:{value:R},constructor:{value:Xe(`${A.name}_${g}`,function(){})}}),w.values[R]=A,w[g]=A},u:function(w,g,R){R=er(R),g=Fe(g),F(w,{name:g,fromWireType:function(A){return A},toWireType:function(A,Y){return Y},argPackAdvance:8,readValueFromPointer:ry(g,R),ea:null})},q:function(w,g,R,A,Y,re){var ce=oi(g,R);w=Fe(w),Y=We(A,Y),Se(w,function(){kn(`Cannot call ${w} due to unbound types`,ce)},g-1),Vt([],ce,function(se){return Bt(w,ri(w,[se[0],null].concat(se.slice(1)),null,Y,re),g-1),[]})},j:function(w,g,R,A,Y){g=Fe(g),Y===-1&&(Y=4294967295),Y=er(R);var re=se=>se;if(A===0){var ce=32-8*R;re=se=>se<<ce>>>ce}R=g.includes("unsigned")?function(se,de){return de>>>0}:function(se,de){return de},F(w,{name:g,fromWireType:re,toWireType:R,argPackAdvance:8,readValueFromPointer:oy(g,Y,A!==0),ea:null})},g:function(w,g,R){function A(re){re>>=2;var ce=W;return new Y(ce.buffer,ce[re+1],ce[re])}var Y=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][g];R=Fe(R),F(w,{name:R,fromWireType:A,argPackAdvance:8,readValueFromPointer:A},{tb:!0})},v:function(w,g){g=Fe(g);var R=g==="std::string";F(w,{name:g,fromWireType:function(A){var Y=W[A>>2],re=A+4;if(R)for(var ce=re,se=0;se<=Y;++se){var de=re+se;if(se==Y||k[de]==0){if(ce=ce?Su(k,ce,de-ce):"",le===void 0)var le=ce;else le+=String.fromCharCode(0),le+=ce;ce=de+1}}else{for(le=Array(Y),se=0;se<Y;++se)le[se]=String.fromCharCode(k[re+se]);le=le.join("")}return Nn(A),le},toWireType:function(A,Y){Y instanceof ArrayBuffer&&(Y=new Uint8Array(Y));var re,ce=typeof Y=="string";ce||Y instanceof Uint8Array||Y instanceof Uint8ClampedArray||Y instanceof Int8Array||Pe("Cannot pass non-string to std::string");var se;if(R&&ce)for(re=se=0;re<Y.length;++re){var de=Y.charCodeAt(re);127>=de?se++:2047>=de?se+=2:55296<=de&&57343>=de?(se+=4,++re):se+=3}else se=Y.length;if(re=se,se=qs(4+re+1),de=se+4,W[se>>2]=re,R&&ce){if(ce=de,de=re+1,re=k,0<de){de=ce+de-1;for(var le=0;le<Y.length;++le){var me=Y.charCodeAt(le);if(55296<=me&&57343>=me){var Ee=Y.charCodeAt(++le);me=65536+((me&1023)<<10)|Ee&1023}if(127>=me){if(ce>=de)break;re[ce++]=me}else{if(2047>=me){if(ce+1>=de)break;re[ce++]=192|me>>6}else{if(65535>=me){if(ce+2>=de)break;re[ce++]=224|me>>12}else{if(ce+3>=de)break;re[ce++]=240|me>>18,re[ce++]=128|me>>12&63}re[ce++]=128|me>>6&63}re[ce++]=128|me&63}}re[ce]=0}}else if(ce)for(ce=0;ce<re;++ce)le=Y.charCodeAt(ce),255<le&&(Nn(de),Pe("String has UTF-16 code units that do not fit in 8 bits")),k[de+ce]=le;else for(ce=0;ce<re;++ce)k[de+ce]=Y[ce];return A!==null&&A.push(Nn,se),se},argPackAdvance:8,readValueFromPointer:vn,ea:function(A){Nn(A)}})},t:function(w,g,R){if(R=Fe(R),g===2)var A=iy,Y=sy,re=ay,ce=()=>G,se=1;else g===4&&(A=cy,Y=ly,re=uy,ce=()=>W,se=2);F(w,{name:R,fromWireType:function(de){for(var le=W[de>>2],me=ce(),Ee,_e=de+4,ke=0;ke<=le;++ke){var ve=de+4+ke*g;(ke==le||me[ve>>se]==0)&&(_e=A(_e,ve-_e),Ee===void 0?Ee=_e:(Ee+=String.fromCharCode(0),Ee+=_e),_e=ve+g)}return Nn(de),Ee},toWireType:function(de,le){typeof le!="string"&&Pe(`Cannot pass non-string to C++ string type ${R}`);var me=re(le),Ee=qs(4+me+g);return W[Ee>>2]=me>>se,Y(le,Ee+4,me+g),de!==null&&de.push(Nn,Ee),Ee},argPackAdvance:8,readValueFromPointer:vn,ea:function(de){Nn(de)}})},N:function(w,g,R,A,Y,re){Qn[w]={name:Fe(g),Ba:We(R,A),ka:We(Y,re),Na:[]}},M:function(w,g,R,A,Y,re,ce,se,de,le){Qn[w].Na.push({mb:Fe(g),sb:R,qb:We(A,Y),rb:re,Db:ce,Cb:We(se,de),Eb:le})},H:function(w,g){g=Fe(g),F(w,{vb:!0,name:g,argPackAdvance:0,fromWireType:function(){},toWireType:function(){}})},r:function(w,g,R){w=Ot(w),g=Qt(g,"emval::as");var A=[],Y=gt(A);return W[R>>2]=Y,g.toWireType(A,w)},w:function(w,g,R,A,Y){w=si[w],g=Ot(g),R=ii(R);var re=[];return W[A>>2]=gt(re),w(g,R,re,Y)},i:function(w,g,R,A){w=si[w],g=Ot(g),R=ii(R),w(g,R,null,A)},f:Us,h:function(w,g){var R=py(w,g),A=R[0];g=A.name+"_$"+R.slice(1).map(function(ce){return ce.name}).join("_")+"$";var Y=Pu[g];if(Y!==void 0)return Y;var re=Array(w-1);return Y=fy((ce,se,de,le)=>{for(var me=0,Ee=0;Ee<w-1;++Ee)re[Ee]=R[Ee+1].readValueFromPointer(le+me),me+=R[Ee+1].argPackAdvance;for(ce=ce[se].apply(ce,re),Ee=0;Ee<w-1;++Ee)R[Ee+1].hb&&R[Ee+1].hb(re[Ee]);if(!A.vb)return A.toWireType(de,ce)}),Pu[g]=Y},p:function(w){return w=ii(w),gt(p[w])},K:function(w,g){return w=Ot(w),g=Ot(g),gt(w[g])},m:function(w){4<w&&(st.get(w).Ta+=1)},J:function(w){return gt(ii(w))},n:function(w){var g=Ot(w);Mn(g),Us(w)},x:function(w,g){return w=Qt(w,"_emval_take_value"),w=w.readValueFromPointer(g),gt(w)},b:()=>{te("")},A:w=>{var g=k.length;if(w>>>=0,2147483648<w)return!1;for(var R=1;4>=R;R*=2){var A=g*(1+.2/R);A=Math.min(A,w+100663296);var Y=Math;A=Math.max(w,A);e:{Y=Y.min.call(Y,2147483648,A+(65536-A%65536)%65536)-v.buffer.byteLength+65535>>>16;try{v.grow(Y),X();var re=1;break e}catch{}re=void 0}if(re)return!0}return!1},B:(w,g)=>{var R=0;return Ru().forEach(function(A,Y){var re=g+R;for(Y=W[w+4*Y>>2]=re,re=0;re<A.length;++re)I[Y++>>0]=A.charCodeAt(re);I[Y>>0]=0,R+=A.length+1}),0},C:(w,g)=>{var R=Ru();W[w>>2]=R.length;var A=0;return R.forEach(function(Y){A+=Y.length+1}),W[g>>2]=A,0},D:()=>52,y:function(){return 70},E:(w,g,R,A)=>{for(var Y=0,re=0;re<R;re++){var ce=W[g>>2],se=W[g+4>>2];g+=8;for(var de=0;de<se;de++){var le=k[ce+de],me=hy[w];le===0||le===10?((w===1?K:V)(Su(me,0)),me.length=0):me.push(le)}Y+=se}return W[A>>2]=Y,0}};(function(){function w(R){if(R=R.exports,p.asm=R,v=p.asm.O,X(),q=p.asm.U,ae.unshift(p.asm.P),J--,p.monitorRunDependencies&&p.monitorRunDependencies(J),J==0&&ee){var A=ee;ee=null,A()}return R}var g={a:my};if(J++,p.monitorRunDependencies&&p.monitorRunDependencies(J),p.instantiateWasm)try{return p.instantiateWasm(g,w)}catch(R){V("Module.instantiateWasm callback failed with error: "+R),E(R)}return Ye(g,function(R){w(R.instance)}).catch(E),{}})();function Nn(){return(Nn=p.asm.Q).apply(null,arguments)}function qs(){return(qs=p.asm.R).apply(null,arguments)}function Au(){return(Au=p.asm.S).apply(null,arguments)}p.__embind_initialize_bindings=function(){return(p.__embind_initialize_bindings=p.asm.T).apply(null,arguments)},p.dynCall_jiji=function(){return(p.dynCall_jiji=p.asm.V).apply(null,arguments)};var ci;ee=function w(){ci||Du(),ci||(ee=w)};function Du(){function w(){if(!ci&&(ci=!0,p.calledRun=!0,!C)){if(je(ae),y(p),p.onRuntimeInitialized&&p.onRuntimeInitialized(),p.postRun)for(typeof p.postRun=="function"&&(p.postRun=[p.postRun]);p.postRun.length;){var g=p.postRun.shift();B.unshift(g)}je(B)}}if(!(0<J)){if(p.preRun)for(typeof p.preRun=="function"&&(p.preRun=[p.preRun]);p.preRun.length;)H();je(ne),0<J||(p.setStatus?(p.setStatus("Running..."),setTimeout(function(){setTimeout(function(){p.setStatus("")},1),w()},1)):w())}}if(p.preInit)for(typeof p.preInit=="function"&&(p.preInit=[p.preInit]);0<p.preInit.length;)p.preInit.pop()();return Du(),h.ready}})();const d=l},s=>{s.exports=JSON.parse(`{"name":"@rive-app/canvas","version":"1.2.4","description":"Rive's canvas based web api.","main":"rive.js","homepage":"https://rive.app","repository":{"type":"git","url":"https://github.com/rive-app/rive-wasm/tree/master/js"},"keywords":["rive","animation"],"author":"Rive","contributors":["Luigi Rosso <luigi@rive.app> (https://rive.app)","Maxwell Talbot <max@rive.app> (https://rive.app)","Arthur Vivian <arthur@rive.app> (https://rive.app)","Umberto Sonnino <umberto@rive.app> (https://rive.app)","Matthew Sullivan <matt.j.sullivan@gmail.com> (mailto:matt.j.sullivan@gmail.com)"],"license":"MIT","files":["rive.js","rive.js.map","rive.wasm","rive.d.ts","rive_advanced.mjs.d.ts"],"typings":"rive.d.ts","dependencies":{},"browser":{"fs":false,"path":false}}`)},(s,a,c)=>{c.r(a),c.d(a,{registerTouchInteractions:()=>l.registerTouchInteractions});var l=c(4)},(s,a,c)=>{c.r(a),c.d(a,{registerTouchInteractions:()=>f});var l=void 0,d=function(h){var p,y;return["touchstart","touchmove"].indexOf(h.type)>-1&&(!((p=h.touches)===null||p===void 0)&&p.length)?(h.preventDefault(),{clientX:h.touches[0].clientX,clientY:h.touches[0].clientY}):h.type==="touchend"&&(!((y=h.changedTouches)===null||y===void 0)&&y.length)?{clientX:h.changedTouches[0].clientX,clientY:h.changedTouches[0].clientY}:{clientX:h.clientX,clientY:h.clientY}},f=function(h){var p=h.canvas,y=h.artboard,E=h.stateMachines,T=E===void 0?[]:E,S=h.renderer,m=h.rive,x=h.fit,_=h.alignment;if(!p||!T.length||!S||!m||!y||typeof window>"u")return null;var $=function(D){var N=D.currentTarget.getBoundingClientRect(),j=d(D),K=j.clientX,V=j.clientY;if(!(!K&&!V)){var P=K-N.left,v=V-N.top,C=m.computeAlignment(x,_,{minX:0,minY:0,maxX:N.width,maxY:N.height},y.bounds),I=new m.Mat2D;C.invert(I);var k=new m.Vec2D(P,v),U=m.mapXY(I,k),G=U.x(),ue=U.y();switch(U.delete(),I.delete(),k.delete(),C.delete(),D.type){case"touchmove":case"mouseover":case"mouseout":case"mousemove":{for(var W=0,L=T;W<L.length;W++){var oe=L[W];oe.pointerMove(G,ue)}break}case"touchstart":case"mousedown":{for(var X=0,q=T;X<q.length;X++){var oe=q[X];oe.pointerDown(G,ue)}break}case"touchend":case"mouseup":{for(var ne=0,ae=T;ne<ae.length;ne++){var oe=ae[ne];oe.pointerUp(G,ue)}break}}}},M=$.bind(l);return p.addEventListener("mouseover",M),p.addEventListener("mouseout",M),p.addEventListener("mousemove",M),p.addEventListener("mousedown",M),p.addEventListener("mouseup",M),p.addEventListener("touchmove",M),p.addEventListener("touchstart",M),p.addEventListener("touchend",M),function(){p.removeEventListener("mouseover",M),p.removeEventListener("mouseout",M),p.removeEventListener("mousemove",M),p.removeEventListener("mousedown",M),p.removeEventListener("mouseup",M),p.removeEventListener("touchmove",M),p.removeEventListener("touchstart",M),p.removeEventListener("touchend",M)}}}],r={};function i(s){var a=r[s];if(a!==void 0)return a.exports;var c=r[s]={exports:{}};return n[s](c,c.exports,i),c.exports}i.d=(s,a)=>{for(var c in a)i.o(a,c)&&!i.o(s,c)&&Object.defineProperty(s,c,{enumerable:!0,get:a[c]})},i.o=(s,a)=>Object.prototype.hasOwnProperty.call(s,a),i.r=s=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(s,"__esModule",{value:!0})};var o={};return(()=>{i.r(o),i.d(o,{Alignment:()=>h,EventType:()=>_,Fit:()=>f,Layout:()=>p,LoopType:()=>$,Rive:()=>N,RuntimeLoader:()=>y,StateMachineInput:()=>S,StateMachineInputType:()=>T,Testing:()=>V});var s=i(1),a=i(2),c=i(3),l=function(P,v,C,I){function k(U){return U instanceof C?U:new C(function(G){G(U)})}return new(C||(C=Promise))(function(U,G){function ue(oe){try{L(I.next(oe))}catch(X){G(X)}}function W(oe){try{L(I.throw(oe))}catch(X){G(X)}}function L(oe){oe.done?U(oe.value):k(oe.value).then(ue,W)}L((I=I.apply(P,v||[])).next())})},d=function(P,v){var C={label:0,sent:function(){if(U[0]&1)throw U[1];return U[1]},trys:[],ops:[]},I,k,U,G;return G={next:ue(0),throw:ue(1),return:ue(2)},typeof Symbol=="function"&&(G[Symbol.iterator]=function(){return this}),G;function ue(L){return function(oe){return W([L,oe])}}function W(L){if(I)throw new TypeError("Generator is already executing.");for(;G&&(G=0,L[0]&&(C=0)),C;)try{if(I=1,k&&(U=L[0]&2?k.return:L[0]?k.throw||((U=k.return)&&U.call(k),0):k.next)&&!(U=U.call(k,L[1])).done)return U;switch(k=0,U&&(L=[L[0]&2,U.value]),L[0]){case 0:case 1:U=L;break;case 4:return C.label++,{value:L[1],done:!1};case 5:C.label++,k=L[1],L=[0];continue;case 7:L=C.ops.pop(),C.trys.pop();continue;default:if(U=C.trys,!(U=U.length>0&&U[U.length-1])&&(L[0]===6||L[0]===2)){C=0;continue}if(L[0]===3&&(!U||L[1]>U[0]&&L[1]<U[3])){C.label=L[1];break}if(L[0]===6&&C.label<U[1]){C.label=U[1],U=L;break}if(U&&C.label<U[2]){C.label=U[2],C.ops.push(L);break}U[2]&&C.ops.pop(),C.trys.pop();continue}L=v.call(P,C)}catch(oe){L=[6,oe],k=0}finally{I=U=0}if(L[0]&5)throw L[1];return{value:L[0]?L[1]:void 0,done:!0}}},f;(function(P){P.Cover="cover",P.Contain="contain",P.Fill="fill",P.FitWidth="fitWidth",P.FitHeight="fitHeight",P.None="none",P.ScaleDown="scaleDown"})(f||(f={}));var h;(function(P){P.Center="center",P.TopLeft="topLeft",P.TopCenter="topCenter",P.TopRight="topRight",P.CenterLeft="centerLeft",P.CenterRight="centerRight",P.BottomLeft="bottomLeft",P.BottomCenter="bottomCenter",P.BottomRight="bottomRight"})(h||(h={}));var p=function(){function P(v){var C,I,k,U,G,ue;this.fit=(C=v==null?void 0:v.fit)!==null&&C!==void 0?C:f.Contain,this.alignment=(I=v==null?void 0:v.alignment)!==null&&I!==void 0?I:h.Center,this.minX=(k=v==null?void 0:v.minX)!==null&&k!==void 0?k:0,this.minY=(U=v==null?void 0:v.minY)!==null&&U!==void 0?U:0,this.maxX=(G=v==null?void 0:v.maxX)!==null&&G!==void 0?G:0,this.maxY=(ue=v==null?void 0:v.maxY)!==null&&ue!==void 0?ue:0}return P.new=function(v){var C=v.fit,I=v.alignment,k=v.minX,U=v.minY,G=v.maxX,ue=v.maxY;return console.warn("This function is deprecated: please use `new Layout({})` instead"),new P({fit:C,alignment:I,minX:k,minY:U,maxX:G,maxY:ue})},P.prototype.copyWith=function(v){var C=v.fit,I=v.alignment,k=v.minX,U=v.minY,G=v.maxX,ue=v.maxY;return new P({fit:C??this.fit,alignment:I??this.alignment,minX:k??this.minX,minY:U??this.minY,maxX:G??this.maxX,maxY:ue??this.maxY})},P.prototype.runtimeFit=function(v){if(this.cachedRuntimeFit)return this.cachedRuntimeFit;var C;return this.fit===f.Cover?C=v.Fit.cover:this.fit===f.Contain?C=v.Fit.contain:this.fit===f.Fill?C=v.Fit.fill:this.fit===f.FitWidth?C=v.Fit.fitWidth:this.fit===f.FitHeight?C=v.Fit.fitHeight:this.fit===f.ScaleDown?C=v.Fit.scaleDown:C=v.Fit.none,this.cachedRuntimeFit=C,C},P.prototype.runtimeAlignment=function(v){if(this.cachedRuntimeAlignment)return this.cachedRuntimeAlignment;var C;return this.alignment===h.TopLeft?C=v.Alignment.topLeft:this.alignment===h.TopCenter?C=v.Alignment.topCenter:this.alignment===h.TopRight?C=v.Alignment.topRight:this.alignment===h.CenterLeft?C=v.Alignment.centerLeft:this.alignment===h.CenterRight?C=v.Alignment.centerRight:this.alignment===h.BottomLeft?C=v.Alignment.bottomLeft:this.alignment===h.BottomCenter?C=v.Alignment.bottomCenter:this.alignment===h.BottomRight?C=v.Alignment.bottomRight:C=v.Alignment.center,this.cachedRuntimeAlignment=C,C},P}(),y=function(){function P(){}return P.loadRuntime=function(){s.default({locateFile:function(){return P.wasmURL}}).then(function(v){var C;for(P.runtime=v;P.callBackQueue.length>0;)(C=P.callBackQueue.shift())===null||C===void 0||C(P.runtime)})},P.getInstance=function(v){P.isLoading||(P.isLoading=!0,P.loadRuntime()),P.runtime?v(P.runtime):P.callBackQueue.push(v)},P.awaitInstance=function(){return new Promise(function(v){return P.getInstance(function(C){return v(C)})})},P.setWasmUrl=function(v){P.wasmURL=v},P.isLoading=!1,P.callBackQueue=[],P.wasmURL="https://unpkg.com/".concat(a.name,"@").concat(a.version,"/rive.wasm"),P}(),E=function(){function P(v,C,I,k){this.animation=v,this.artboard=C,this.playing=k,this.loopCount=0,this.scrubTo=null,this.instance=new I.LinearAnimationInstance(v,C)}return Object.defineProperty(P.prototype,"name",{get:function(){return this.animation.name},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"time",{get:function(){return this.instance.time},set:function(v){this.instance.time=v},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"loopValue",{get:function(){return this.animation.loopValue},enumerable:!1,configurable:!0}),P.prototype.advance=function(v){this.scrubTo===null?this.instance.advance(v):(this.instance.time=0,this.instance.advance(this.scrubTo),this.scrubTo=null)},P.prototype.apply=function(v){this.instance.apply(v)},Object.defineProperty(P.prototype,"needsScrub",{get:function(){return this.scrubTo!==null},enumerable:!1,configurable:!0}),P.prototype.cleanup=function(){this.instance.delete()},P}(),T;(function(P){P[P.Number=56]="Number",P[P.Trigger=58]="Trigger",P[P.Boolean=59]="Boolean"})(T||(T={}));var S=function(){function P(v,C){this.type=v,this.runtimeInput=C}return Object.defineProperty(P.prototype,"name",{get:function(){return this.runtimeInput.name},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"value",{get:function(){return this.runtimeInput.value},set:function(v){this.runtimeInput.value=v},enumerable:!1,configurable:!0}),P.prototype.fire=function(){this.type===T.Trigger&&this.runtimeInput.fire()},P}(),m=function(){function P(v,C,I,k){this.stateMachine=v,this.playing=I,this.artboard=k,this.inputs=[],this.instance=new C.StateMachineInstance(v,k),this.initInputs(C)}return Object.defineProperty(P.prototype,"name",{get:function(){return this.stateMachine.name},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"statesChanged",{get:function(){for(var v=[],C=0;C<this.instance.stateChangedCount();C++)v.push(this.instance.stateChangedNameByIndex(C));return v},enumerable:!1,configurable:!0}),P.prototype.advance=function(v){this.instance.advance(v)},P.prototype.initInputs=function(v){for(var C=0;C<this.instance.inputCount();C++){var I=this.instance.input(C);this.inputs.push(this.mapRuntimeInput(I,v))}},P.prototype.mapRuntimeInput=function(v,C){if(v.type===C.SMIInput.bool)return new S(T.Boolean,v.asBool());if(v.type===C.SMIInput.number)return new S(T.Number,v.asNumber());if(v.type===C.SMIInput.trigger)return new S(T.Trigger,v.asTrigger())},P.prototype.cleanup=function(){this.instance.delete()},P}(),x=function(){function P(v,C,I,k,U){k===void 0&&(k=[]),U===void 0&&(U=[]),this.runtime=v,this.artboard=C,this.eventManager=I,this.animations=k,this.stateMachines=U}return P.prototype.add=function(v,C,I){if(I===void 0&&(I=!0),v=K(v),v.length===0)this.animations.forEach(function(ne){return ne.playing=C}),this.stateMachines.forEach(function(ne){return ne.playing=C});else for(var k=this.animations.map(function(ne){return ne.name}),U=this.stateMachines.map(function(ne){return ne.name}),G=0;G<v.length;G++){var ue=k.indexOf(v[G]),W=U.indexOf(v[G]);if(ue>=0||W>=0)ue>=0?this.animations[ue].playing=C:this.stateMachines[W].playing=C;else{var L=this.artboard.animationByName(v[G]);if(L){var oe=new E(L,this.artboard,this.runtime,C);oe.advance(0),oe.apply(1),this.animations.push(oe)}else{var X=this.artboard.stateMachineByName(v[G]);if(X){var q=new m(X,this.runtime,C,this.artboard);this.stateMachines.push(q)}}}}return I&&(C?this.eventManager.fire({type:_.Play,data:this.playing}):this.eventManager.fire({type:_.Pause,data:this.paused})),C?this.playing:this.paused},P.prototype.play=function(v){return this.add(v,!0)},P.prototype.pause=function(v){return this.add(v,!1)},P.prototype.scrub=function(v,C){var I=this.animations.filter(function(k){return v.includes(k.name)});return I.forEach(function(k){return k.scrubTo=C}),I.map(function(k){return k.name})},Object.defineProperty(P.prototype,"playing",{get:function(){return this.animations.filter(function(v){return v.playing}).map(function(v){return v.name}).concat(this.stateMachines.filter(function(v){return v.playing}).map(function(v){return v.name}))},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"paused",{get:function(){return this.animations.filter(function(v){return!v.playing}).map(function(v){return v.name}).concat(this.stateMachines.filter(function(v){return!v.playing}).map(function(v){return v.name}))},enumerable:!1,configurable:!0}),P.prototype.stop=function(v){var C=this;v=K(v);var I=[];if(v.length===0)I=this.animations.map(function(G){return G.name}).concat(this.stateMachines.map(function(G){return G.name})),this.animations.forEach(function(G){return G.cleanup()}),this.stateMachines.forEach(function(G){return G.cleanup()}),this.animations.splice(0,this.animations.length),this.stateMachines.splice(0,this.stateMachines.length);else{var k=this.animations.filter(function(G){return v.includes(G.name)});k.forEach(function(G){G.cleanup(),C.animations.splice(C.animations.indexOf(G),1)});var U=this.stateMachines.filter(function(G){return v.includes(G.name)});U.forEach(function(G){G.cleanup(),C.stateMachines.splice(C.stateMachines.indexOf(G),1)}),I=k.map(function(G){return G.name}).concat(U.map(function(G){return G.name}))}return this.eventManager.fire({type:_.Stop,data:I}),I},Object.defineProperty(P.prototype,"isPlaying",{get:function(){return this.animations.reduce(function(v,C){return v||C.playing},!1)||this.stateMachines.reduce(function(v,C){return v||C.playing},!1)},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isPaused",{get:function(){return!this.isPlaying&&(this.animations.length>0||this.stateMachines.length>0)},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isStopped",{get:function(){return this.animations.length===0&&this.stateMachines.length===0},enumerable:!1,configurable:!0}),P.prototype.atLeastOne=function(v,C){C===void 0&&(C=!0);var I;return this.animations.length===0&&this.stateMachines.length===0&&(this.artboard.animationCount()>0?this.add([I=this.artboard.animationByIndex(0).name],v,C):this.artboard.stateMachineCount()>0&&this.add([I=this.artboard.stateMachineByIndex(0).name],v,C)),I},P.prototype.handleLooping=function(){for(var v=0,C=this.animations.filter(function(k){return k.playing});v<C.length;v++){var I=C[v];I.loopValue===0&&I.loopCount?(I.loopCount=0,this.stop(I.name)):I.loopValue===1&&I.loopCount?(this.eventManager.fire({type:_.Loop,data:{animation:I.name,type:$.Loop}}),I.loopCount=0):I.loopValue===2&&I.loopCount>1&&(this.eventManager.fire({type:_.Loop,data:{animation:I.name,type:$.PingPong}}),I.loopCount=0)}},P.prototype.handleStateChanges=function(){for(var v=[],C=0,I=this.stateMachines.filter(function(U){return U.playing});C<I.length;C++){var k=I[C];v.push.apply(v,k.statesChanged)}v.length>0&&this.eventManager.fire({type:_.StateChange,data:v})},P.prototype.handleAdvancing=function(v){this.eventManager.fire({type:_.Advance,data:v})},P}(),_;(function(P){P.Load="load",P.LoadError="loaderror",P.Play="play",P.Pause="pause",P.Stop="stop",P.Loop="loop",P.Draw="draw",P.Advance="advance",P.StateChange="statechange"})(_||(_={}));var $;(function(P){P.OneShot="oneshot",P.Loop="loop",P.PingPong="pingpong"})($||($={}));var M=function(){function P(v){v===void 0&&(v=[]),this.listeners=v}return P.prototype.getListeners=function(v){return this.listeners.filter(function(C){return C.type===v})},P.prototype.add=function(v){this.listeners.includes(v)||this.listeners.push(v)},P.prototype.remove=function(v){for(var C=0;C<this.listeners.length;C++){var I=this.listeners[C];if(I.type===v.type&&I.callback===v.callback){this.listeners.splice(C,1);break}}},P.prototype.removeAll=function(v){var C=this;v?this.listeners.filter(function(I){return I.type===v}).forEach(function(I){return C.remove(I)}):this.listeners.splice(0,this.listeners.length)},P.prototype.fire=function(v){var C=this.getListeners(v.type);C.forEach(function(I){return I.callback(v)})},P}(),D=function(){function P(v){this.eventManager=v,this.queue=[]}return P.prototype.add=function(v){this.queue.push(v)},P.prototype.process=function(){for(;this.queue.length>0;){var v=this.queue.shift();v!=null&&v.action&&v.action(),v!=null&&v.event&&this.eventManager.fire(v.event)}},P}(),N=function(){function P(v){var C;this.loaded=!1,this.readyForPlaying=!1,this.artboard=null,this.eventCleanup=null,this.shouldDisableRiveListeners=!1,this.durations=[],this.frameTimes=[],this.frameCount=0,this.renderSecondTimer=0,this.canvas=v.canvas,this.src=v.src,this.buffer=v.buffer,this.layout=(C=v.layout)!==null&&C!==void 0?C:new p,this.shouldDisableRiveListeners=!!v.shouldDisableRiveListeners,this.eventManager=new M,v.onLoad&&this.on(_.Load,v.onLoad),v.onLoadError&&this.on(_.LoadError,v.onLoadError),v.onPlay&&this.on(_.Play,v.onPlay),v.onPause&&this.on(_.Pause,v.onPause),v.onStop&&this.on(_.Stop,v.onStop),v.onLoop&&this.on(_.Loop,v.onLoop),v.onStateChange&&this.on(_.StateChange,v.onStateChange),v.onAdvance&&this.on(_.Advance,v.onAdvance),v.onload&&!v.onLoad&&this.on(_.Load,v.onload),v.onloaderror&&!v.onLoadError&&this.on(_.LoadError,v.onloaderror),v.onplay&&!v.onPlay&&this.on(_.Play,v.onplay),v.onpause&&!v.onPause&&this.on(_.Pause,v.onpause),v.onstop&&!v.onStop&&this.on(_.Stop,v.onstop),v.onloop&&!v.onLoop&&this.on(_.Loop,v.onloop),v.onstatechange&&!v.onStateChange&&this.on(_.StateChange,v.onstatechange),this.taskQueue=new D(this.eventManager),this.init({src:this.src,buffer:this.buffer,autoplay:v.autoplay,animations:v.animations,stateMachines:v.stateMachines,artboard:v.artboard,useOffscreenRenderer:v.useOffscreenRenderer})}return P.new=function(v){return console.warn("This function is deprecated: please use `new Rive({})` instead"),new P(v)},P.prototype.init=function(v){var C=this,I=v.src,k=v.buffer,U=v.animations,G=v.stateMachines,ue=v.artboard,W=v.autoplay,L=W===void 0?!1:W,oe=v.useOffscreenRenderer,X=oe===void 0?!1:oe;if(this.src=I,this.buffer=k,!this.src&&!this.buffer)throw new Error(P.missingErrorMessage);var q=K(U),ne=K(G);this.loaded=!1,this.readyForPlaying=!1,y.awaitInstance().then(function(ae){C.runtime=ae,C.renderer=C.runtime.makeRenderer(C.canvas,X),C.canvas.width||C.canvas.height||C.resizeDrawingSurfaceToCanvas(),C.initData(ue,q,ne,L).then(function(){return C.setupRiveListeners()}).catch(function(B){console.error(B)})}).catch(function(ae){console.error(ae)})},P.prototype.setupRiveListeners=function(){var v=this;if(!this.shouldDisableRiveListeners){var C=(this.animator.stateMachines||[]).filter(function(I){return I.playing&&v.runtime.hasListeners(I.instance)}).map(function(I){return I.instance});this.eventCleanup=(0,c.registerTouchInteractions)({canvas:this.canvas,artboard:this.artboard,stateMachines:C,renderer:this.renderer,rive:this.runtime,fit:this._layout.runtimeFit(this.runtime),alignment:this._layout.runtimeAlignment(this.runtime)})}},P.prototype.initData=function(v,C,I,k){var U;return l(this,void 0,void 0,function(){var G,ue,W;return d(this,function(L){switch(L.label){case 0:return this.src?(G=this,[4,j(this.src)]):[3,2];case 1:G.buffer=L.sent(),L.label=2;case 2:return ue=this,[4,this.runtime.load(new Uint8Array(this.buffer))];case 3:return ue.file=L.sent(),this.file?(this.initArtboard(v,C,I,k),this.loaded=!0,this.eventManager.fire({type:_.Load,data:(U=this.src)!==null&&U!==void 0?U:"buffer"}),this.readyForPlaying=!0,this.taskQueue.process(),this.drawFrame(),[2,Promise.resolve()]):(W="Problem loading file; may be corrupt!",console.warn(W),this.eventManager.fire({type:_.LoadError,data:W}),[2,Promise.reject(W)])}})})},P.prototype.initArtboard=function(v,C,I,k){var U=v?this.file.artboardByName(v):this.file.defaultArtboard();if(!U){var G="Invalid artboard name or no default artboard";console.warn(G),this.eventManager.fire({type:_.LoadError,data:G});return}if(this.artboard=U,this.artboard.animationCount()<1){var G="Artboard has no animations";throw this.eventManager.fire({type:_.LoadError,data:G}),G}this.animator=new x(this.runtime,this.artboard,this.eventManager);var ue;C.length>0||I.length>0?(ue=C.concat(I),this.animator.add(ue,k,!1)):ue=[this.animator.atLeastOne(k,!1)],this.taskQueue.add({event:{type:k?_.Play:_.Pause,data:ue}})},P.prototype.drawFrame=function(){this.startRendering()},P.prototype.draw=function(v,C){var I=performance.now();this.frameRequestId=null,this.lastRenderTime||(this.lastRenderTime=v),this.renderSecondTimer+=v-this.lastRenderTime,this.renderSecondTimer>5e3&&(this.renderSecondTimer=0,C==null||C());var k=(v-this.lastRenderTime)/1e3;this.lastRenderTime=v;for(var U=this.animator.animations.filter(function(B){return B.playing||B.needsScrub}).sort(function(B){return B.needsScrub?-1:1}),G=0,ue=U;G<ue.length;G++){var W=ue[G];W.advance(k),W.instance.didLoop&&(W.loopCount+=1),W.apply(1)}for(var L=this.animator.stateMachines.filter(function(B){return B.playing}),oe=0,X=L;oe<X.length;oe++){var q=X[oe];q.advance(k)}this.artboard.advance(k);var ne=this.renderer;ne.clear(),ne.save(),this.alignRenderer(),this.artboard.draw(ne),ne.restore(),ne.flush(),this.animator.handleLooping(),this.animator.handleStateChanges(),this.animator.handleAdvancing(k),this.frameCount++;var ae=performance.now();for(this.frameTimes.push(ae),this.durations.push(ae-I);this.frameTimes[0]<=ae-1e3;)this.frameTimes.shift(),this.durations.shift();this.animator.isPlaying?this.startRendering():this.animator.isPaused?this.lastRenderTime=0:this.animator.isStopped&&(this.lastRenderTime=0)},P.prototype.alignRenderer=function(){var v=this,C=v.renderer,I=v.runtime,k=v._layout,U=v.artboard;C.align(k.runtimeFit(I),k.runtimeAlignment(I),{minX:k.minX,minY:k.minY,maxX:k.maxX,maxY:k.maxY},U.bounds)},Object.defineProperty(P.prototype,"fps",{get:function(){return this.durations.length},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"frameTime",{get:function(){return this.durations.length===0?0:(this.durations.reduce(function(v,C){return v+C},0)/this.durations.length).toFixed(4)},enumerable:!1,configurable:!0}),P.prototype.cleanup=function(){var v,C;this.stopRendering(),this.cleanupInstances(),(v=this.renderer)===null||v===void 0||v.delete(),this.renderer=null,(C=this.file)===null||C===void 0||C.delete(),this.file=null},P.prototype.cleanupInstances=function(){this.eventCleanup!==null&&this.eventCleanup(),this.stop(),this.artboard&&(this.artboard.delete(),this.artboard=null)},P.prototype.play=function(v,C){var I=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return I.play(v,C)}});return}this.animator.play(v),this.eventCleanup&&this.eventCleanup(),this.setupRiveListeners(),this.startRendering()},P.prototype.pause=function(v){var C=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return C.pause(v)}});return}this.eventCleanup&&this.eventCleanup(),this.animator.pause(v)},P.prototype.scrub=function(v,C){var I=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return I.scrub(v,C)}});return}this.animator.scrub(v,C||0),this.drawFrame()},P.prototype.stop=function(v){var C=this;if(v=K(v),!this.readyForPlaying){this.taskQueue.add({action:function(){return C.stop(v)}});return}this.animator.stop(v),this.eventCleanup&&this.eventCleanup()},P.prototype.reset=function(v){var C,I=v==null?void 0:v.artboard,k=K(v==null?void 0:v.animations),U=K(v==null?void 0:v.stateMachines),G=(C=v==null?void 0:v.autoplay)!==null&&C!==void 0?C:!1;this.cleanupInstances(),this.initArtboard(I,k,U,G),this.taskQueue.process()},P.prototype.load=function(v){this.stop(),this.init(v)},Object.defineProperty(P.prototype,"layout",{get:function(){return this._layout},set:function(v){this._layout=v,(!v.maxX||!v.maxY)&&this.resizeToCanvas(),this.loaded&&!this.animator.isPlaying&&this.drawFrame()},enumerable:!1,configurable:!0}),P.prototype.resizeToCanvas=function(){this._layout=this.layout.copyWith({minX:0,minY:0,maxX:this.canvas.width,maxY:this.canvas.height})},P.prototype.resizeDrawingSurfaceToCanvas=function(){if(this.canvas instanceof HTMLCanvasElement&&window){var v=this.canvas.getBoundingClientRect(),C=v.width,I=v.height,k=window.devicePixelRatio||1;this.canvas.width=k*C,this.canvas.height=k*I,this.startRendering(),this.resizeToCanvas()}},Object.defineProperty(P.prototype,"source",{get:function(){return this.src},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"activeArtboard",{get:function(){return this.artboard?this.artboard.name:""},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"animationNames",{get:function(){if(!this.loaded)return[];for(var v=[],C=0;C<this.artboard.animationCount();C++)v.push(this.artboard.animationByIndex(C).name);return v},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"stateMachineNames",{get:function(){if(!this.loaded)return[];for(var v=[],C=0;C<this.artboard.stateMachineCount();C++)v.push(this.artboard.stateMachineByIndex(C).name);return v},enumerable:!1,configurable:!0}),P.prototype.stateMachineInputs=function(v){if(this.loaded){var C=this.animator.stateMachines.find(function(I){return I.name===v});return C==null?void 0:C.inputs}},Object.defineProperty(P.prototype,"playingStateMachineNames",{get:function(){return this.loaded?this.animator.stateMachines.filter(function(v){return v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"playingAnimationNames",{get:function(){return this.loaded?this.animator.animations.filter(function(v){return v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"pausedAnimationNames",{get:function(){return this.loaded?this.animator.animations.filter(function(v){return!v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"pausedStateMachineNames",{get:function(){return this.loaded?this.animator.stateMachines.filter(function(v){return!v.playing}).map(function(v){return v.name}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isPlaying",{get:function(){return this.animator.isPlaying},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isPaused",{get:function(){return this.animator.isPaused},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isStopped",{get:function(){return this.animator.isStopped},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"bounds",{get:function(){return this.artboard?this.artboard.bounds:void 0},enumerable:!1,configurable:!0}),P.prototype.on=function(v,C){this.eventManager.add({type:v,callback:C})},P.prototype.off=function(v,C){this.eventManager.remove({type:v,callback:C})},P.prototype.unsubscribe=function(v,C){console.warn("This function is deprecated: please use `off()` instead."),this.off(v,C)},P.prototype.removeAllRiveEventListeners=function(v){this.eventManager.removeAll(v)},P.prototype.unsubscribeAll=function(v){console.warn("This function is deprecated: please use `removeAllRiveEventListeners()` instead."),this.removeAllRiveEventListeners(v)},P.prototype.stopRendering=function(){this.loaded&&this.frameRequestId&&(this.runtime.cancelAnimationFrame?this.runtime.cancelAnimationFrame(this.frameRequestId):cancelAnimationFrame(this.frameRequestId),this.frameRequestId=null)},P.prototype.startRendering=function(){this.loaded&&this.artboard&&!this.frameRequestId&&(this.runtime.requestAnimationFrame?this.frameRequestId=this.runtime.requestAnimationFrame(this.draw.bind(this)):this.frameRequestId=requestAnimationFrame(this.draw.bind(this)))},P.prototype.enableFPSCounter=function(v){this.runtime.enableFPSCounter(v)},P.prototype.disableFPSCounter=function(){this.runtime.disableFPSCounter()},Object.defineProperty(P.prototype,"contents",{get:function(){if(this.loaded){for(var v={artboards:[]},C=0;C<this.file.artboardCount();C++){for(var I=this.file.artboardByIndex(C),k={name:I.name,animations:[],stateMachines:[]},U=0;U<I.animationCount();U++){var G=I.animationByIndex(U);k.animations.push(G.name)}for(var ue=0;ue<I.stateMachineCount();ue++){for(var W=I.stateMachineByIndex(ue),L=W.name,oe=new this.runtime.StateMachineInstance(W,I),X=[],q=0;q<oe.inputCount();q++){var ne=oe.input(q);X.push({name:ne.name,type:ne.type})}k.stateMachines.push({name:L,inputs:X})}v.artboards.push(k)}return v}},enumerable:!1,configurable:!0}),P.missingErrorMessage="Rive source file or data buffer required",P}(),j=function(P){return l(void 0,void 0,void 0,function(){var v,C,I;return d(this,function(k){switch(k.label){case 0:return v=new Request(P),[4,fetch(v)];case 1:return C=k.sent(),[4,C.arrayBuffer()];case 2:return I=k.sent(),[2,I]}})})},K=function(P){return typeof P=="string"?[P]:P instanceof Array?P:[]},V={EventManager:M,TaskQueueManager:D}})(),o})())})(Mv);var jP=Mv.exports;(function(e){Object.defineProperty(e,"__esModule",{value:!0});var t=u,n=jP;function r(m){return m&&typeof m=="object"&&"default"in m?m:{default:m}}var i=r(t),o=function(){return o=Object.assign||function(m){for(var x,_=1,$=arguments.length;_<$;_++)for(var M in x=arguments[_])Object.prototype.hasOwnProperty.call(x,M)&&(m[M]=x[M]);return m},o.apply(this,arguments)};function s(m,x){var _={};for(var $ in m)Object.prototype.hasOwnProperty.call(m,$)&&x.indexOf($)<0&&(_[$]=m[$]);if(m!=null&&typeof Object.getOwnPropertySymbols=="function"){var M=0;for($=Object.getOwnPropertySymbols(m);M<$.length;M++)x.indexOf($[M])<0&&Object.prototype.propertyIsEnumerable.call(m,$[M])&&(_[$[M]]=m[$[M]])}return _}function a(){var m=typeof window<"u"&&typeof window.devicePixelRatio=="number"?window.devicePixelRatio:1;return Math.min(Math.max(1,m),3)}typeof SuppressedError=="function"&&SuppressedError;var c=function(){function m(){}return m.prototype.observe=function(){},m.prototype.unobserve=function(){},m.prototype.disconnect=function(){},m}(),l=globalThis.ResizeObserver||c,d=globalThis.ResizeObserver!==void 0,f=!d;function h(m,x){x===void 0&&(x=!0);var _=t.useState({width:0,height:0}),$=_[0],M=_[1];t.useEffect(function(){if(typeof window<"u"&&x){var V=function(){M({width:window.innerWidth,height:window.innerHeight})};return f&&(V(),window.addEventListener("resize",V)),function(){return window.removeEventListener("resize",V)}}},[]);var D,N,j,K=t.useRef(new l((D=function(V){d&&M({width:V[V.length-1].contentRect.width,height:V[V.length-1].contentRect.height})},N=0,j=0,function(){for(var V=this,P=[],v=0;v<arguments.length;v++)P[v]=arguments[v];clearTimeout(j),j=window.setTimeout(function(){return D.apply(V,P)},N)})));return t.useEffect(function(){var V=K.current;if(x){var P=m.current;return m.current&&d&&V.observe(m.current),function(){V.disconnect(),P&&d&&V.unobserve(P)}}V.disconnect()},[m,K]),$}var p={useDevicePixelRatio:!0,fitCanvasToArtboardHeight:!1,useOffscreenRenderer:!0,shouldResizeCanvasToContainer:!0};function y(m){return Object.assign({},p,m)}function E(m){var x=m.riveLoaded,_=x!==void 0&&x,$=m.canvasRef,M=m.containerRef,D=m.options,N=D===void 0?{}:D,j=m.onCanvasHasResized,K=m.artboardBounds,V=y(N),P=t.useState({height:0,width:0}),v=P[0],C=v.height,I=v.width,k=P[1],U=t.useState({height:0,width:0}),G=U[0],ue=G.height,W=G.width,L=U[1],oe=t.useState(!0),X=oe[0],q=oe[1],ne=V.fitCanvasToArtboardHeight,ae=V.shouldResizeCanvasToContainer,B=V.useDevicePixelRatio,H=h(M,ae),J=function(){var Te=a(),Ie=t.useState(Te),Ae=Ie[0],$e=Ie[1];return t.useEffect(function(){if(typeof window<"u"&&"matchMedia"in window){var Ye=function(){var vt=a();$e(vt)},je=window.matchMedia("screen and (resolution: ".concat(Ae,"dppx)"));return je.hasOwnProperty("addEventListener")?je.addEventListener("change",Ye):je.addListener(Ye),function(){je.hasOwnProperty("removeEventListener")?je.removeEventListener("change",Ye):je.removeListener(Ye)}}},[Ae]),Ae}(),ee=K??{},te=ee.maxX,Z=ee.maxY,ge=t.useCallback(function(){var Te,Ie,Ae,$e,Ye=(Ie=(Te=M.current)===null||Te===void 0?void 0:Te.clientWidth)!==null&&Ie!==void 0?Ie:0,je=($e=(Ae=M.current)===null||Ae===void 0?void 0:Ae.clientHeight)!==null&&$e!==void 0?$e:0;return ne&&K?{width:Ye,height:Ye*(K.maxY/K.maxX)}:{width:Ye,height:je}},[M,ne,te,Z]);t.useEffect(function(){if(ae&&M.current&&_){var Te=ge(),Ie=Te.width,Ae=Te.height,$e=!1;if($.current){var Ye=Ie!==I||Ae!==C;if(V.fitCanvasToArtboardHeight&&Ye&&(M.current.style.height=Ae+"px",$e=!0),V.useDevicePixelRatio){if(Ye||Ie*J!==W||Ae*J!==ue){var je=J*Ie,vt=J*Ae;$.current.width=je,$.current.height=vt,$.current.style.width=Ie+"px",$.current.style.height=Ae+"px",L({width:je,height:vt}),$e=!0}}else Ye&&($.current.width=Ie,$.current.height=Ae,L({width:Ie,height:Ae}),$e=!0);k({width:Ie,height:Ae})}j&&(X||$e)&&j&&j(),X&&q(!1)}},[$,M,H,J,ge,X,q,ue,W,C,I,j,ae,ne,B,_])}function T(m){var x=m.setContainerRef,_=m.setCanvasRef,$=m.className,M=$===void 0?"":$,D=m.style,N=m.children,j=s(m,["setContainerRef","setCanvasRef","className","style","children"]),K=o({width:"100%",height:"100%"},D);return i.default.createElement("div",o({ref:x,className:M},!M&&{style:K}),i.default.createElement("canvas",o({ref:_,style:{verticalAlign:"top",width:0,height:0}},j),N))}function S(m,x){x===void 0&&(x={});var _=t.useRef(null),$=t.useRef(null),M=t.useState(null),D=M[0],N=M[1],j=!!m,K=y(x),V=t.useCallback(function(){D&&(D.startRendering(),D.resizeToCanvas())},[D]);E({riveLoaded:!!D,canvasRef:_,containerRef:$,options:K,onCanvasHasResized:V,artboardBounds:D==null?void 0:D.bounds});var P=t.useCallback(function(k){if(k&&m&&j){var U=K.useOffscreenRenderer,G=new n.Rive(o(o({useOffscreenRenderer:U},m),{canvas:k}));G.on(n.EventType.Load,function(){_.current?N(G):G.cleanup()})}else k===null&&_.current&&(_.current.height=0,_.current.width=0);_.current=k},[j]),v=t.useCallback(function(k){$.current=k},[]);t.useEffect(function(){var k=new IntersectionObserver(function(U){U[0].isIntersecting?D&&D.startRendering():D&&D.stopRendering()});return _.current&&k.observe(_.current),function(){k.disconnect()}},[D]),t.useEffect(function(){return function(){D&&(D.cleanup(),N(null))}},[D]);var C=m==null?void 0:m.animations;t.useEffect(function(){D&&C&&(D.isPlaying?(D.stop(D.animationNames),D.play(C)):D.isPaused&&(D.stop(D.animationNames),D.pause(C)))},[C,D]);var I=t.useCallback(function(k){return i.default.createElement(T,o({setContainerRef:v,setCanvasRef:P},k))},[P,v]);return{canvas:_.current,container:$.current,setCanvasRef:P,setContainerRef:v,rive:D,RiveComponent:I}}e.default=function(m){var x=m.src,_=m.artboard,$=m.animations,M=m.stateMachines,D=m.layout,N=m.useOffscreenRenderer,j=N===void 0||N,K=m.shouldDisableRiveListeners,V=K!==void 0&&K,P=m.shouldResizeCanvasToContainer,v=P===void 0||P,C=m.children,I=s(m,["src","artboard","animations","stateMachines","layout","useOffscreenRenderer","shouldDisableRiveListeners","shouldResizeCanvasToContainer","children"]),k=S({src:x,artboard:_,animations:$,layout:D,stateMachines:M,autoplay:!0,shouldDisableRiveListeners:V},{useOffscreenRenderer:j,shouldResizeCanvasToContainer:v}).RiveComponent;return i.default.createElement(k,o({},I),C)},e.useResizeCanvas=E,e.useRive=S,e.useStateMachineInput=function(m,x,_,$){var M=t.useState(null),D=M[0],N=M[1];return t.useEffect(function(){function j(){if(m&&x&&_||N(null),m&&x&&_){var K=m.stateMachineInputs(x);if(K){var V=K.find(function(P){return P.name===_});$!==void 0&&V&&(V.value=$),N(V||null)}}else N(null)}j(),m&&m.on(n.EventType.Play,function(){j()})},[m]),D},Object.keys(n).forEach(function(m){m==="default"||e.hasOwnProperty(m)||Object.defineProperty(e,m,{enumerable:!0,get:function(){return n[m]}})})})(Ov);const VP=kp(Ov),Sl=({src:e="https://assets.machtwatch.net/voila/asset/riv-animation/loader.riv",width:t,height:n,style:r,...i})=>O.jsx(ht,{width:t,height:n,style:r,children:O.jsx(VP,{src:e,...i})});Sl.defaultProps={src:"https://assets.machtwatch.net/voila/asset/riv-animation/loader.riv",width:"300px",height:"300px",style:{}};const kv=({isLoading:e,className:t,width:n,height:r,onClose:i,src:o,noScroll:s="noscroll",...a})=>(u.useEffect(()=>(e?document.body.classList.add(s):document.body.classList.remove(s),()=>{document.body.classList.remove(s)}),[e,s]),e?O.jsx(ht,{className:t,"data-test-id":a["data-testid-backdrop"],onClick:i,position:"fixed",left:"$0",top:"$0",width:"$full",height:"$full",cursor:"progress",style:{backgroundColor:"rgba(0, 0, 0, 0.4)",zIndex:9999},children:O.jsx(ht,{"data-test-id":a["data-testid-loader"],position:"absolute",left:"50%",top:"50%",width:n,height:r,children:O.jsx(Sl,{src:o,width:n,height:r,style:{transform:"translate(-50%, -50%)"}})})}):null);kv.defaultProps={onClose:()=>{},className:"",src:void 0,noScroll:"noscroll","data-testid-backdrop":"full-loader-backdrop","data-testid-loader":"full-loader-loader"};var LP=ft({defaultClassName:"_1a8lrjn1 j1jih79l j1jih7ak",variantClassNames:{color:{primary:"_1a8lrjn2",white:"_1a8lrjn3"},size:{small:"_1a8lrjn4",medium:"_1a8lrjn5",large:"_1a8lrjn6"}},defaultVariants:{color:"primary",size:"medium"},compoundVariants:[]});const FP=({color:e,size:t,...n})=>O.jsx(ht,{...n,className:Re(LP({color:e,size:t}))});function BP(e){return class extends u.Component{constructor(){super(...arguments),this.getValue=()=>{const{children:n,selectedValue:r}=this.props;return r&&r.length?r:n?u.Children.map(n,i=>{const o=u.Children.toArray(i.children||i.props.children);return o&&o[0]&&o[0].props.value}):[]},this.onChange=(n,r,i)=>{const o=this.getValue().concat();o[n]=r,i&&i(o,n)},this.onValueChange=(n,r)=>{this.onChange(n,r,this.props.onValueChange)},this.onScrollChange=(n,r)=>{this.onChange(n,r,this.props.onScrollChange)}}render(){return O.jsx(e,{...this.props,getValue:this.getValue,onValueChange:this.onValueChange,onScrollChange:this.props.onScrollChange&&this.onScrollChange})}}}var HP="_1ypj0tt5",WP="_1ypj0tt4",UP="_1ypj0tt3",sp="_1ypj0tt1",YP="_1ypj0tt0",zP="_1ypj0tt2";const KP=({className:e,children:t,getValue:n,onScrollChange:r,onValueChange:i})=>{const o=n==null?void 0:n(),s=u.Children.map(t,(a,c)=>u.cloneElement(a,{selectedValue:o==null?void 0:o[c],onValueChange:(...l)=>i==null?void 0:i(c,...l),onScrollChange:(...l)=>r==null?void 0:r(c,...l)}));return O.jsx(ht,{className:Re(HP,e),children:s})},Nv=BP(KP),qP=e=>null;function XP(e){var t;const n=(r,i,o)=>{const s=Math.round(r/i);return Math.min(s,o-1)};return t=class extends u.Component{constructor(){super(...arguments),this.selectByIndex=(r,i,o)=>{r<0||r>=u.Children.count(this.props.children)||!i||o(r*i)},this.doScrollingComplete=(r,i,o)=>{const s=u.Children.toArray(this.props.children),a=n(r,i,s.length),c=s[a];c?o(c.props.value):console.warn&&console.warn("child not found",s,a)},this.select=(r,i,o)=>{const s=u.Children.toArray(this.props.children);for(let a=0,c=s.length;a<c;a+=1)if(s[a].props.value===r){this.selectByIndex(a,i,o);return}this.selectByIndex(0,i,o)}}render(){return O.jsx(e,{...this.props,doScrollingComplete:this.doScrollingComplete,computeChildIndex:n,select:this.select})}},t.Item=qP,t}const GP=e=>{const{children:t,selectedValue:n,defaultSelectedValue:r,select:i,doScrollingComplete:o,onValueChange:s,computeChildIndex:a,disabled:c,className:l}=e,d=u.useRef(null),f=u.useRef(null),h=u.useRef(null),p=u.useRef(0),y=u.useRef(0),E=u.useMemo(()=>{if(n||r)return n||r;const j=u.Children.toArray(t);return j&&j[0]&&j[0].props.value},[t,r,n]),[T,S]=u.useState(E),m=(()=>{let j=-1,K=0,V=0,P=!1,v=!1;const C=(L,oe)=>{L.transform=oe},I=(L,oe)=>{L.transition=oe},k=(L,oe,X=.3)=>{var q,ne;j!==oe&&(j=oe,I((q=f.current)==null?void 0:q.style,`cubic-bezier(0,0,0.2,1.15) ${X}s`),C((ne=f.current)==null?void 0:ne.style,`translate3d(0,${-oe}px,0)`),setTimeout(()=>{D(),f.current&&I(f.current.style,"")},+X*1e3))},U=((L=30,oe=100)=>{let X=0,q=0,ne=0;const ae={record:B=>{const H=+new Date;ne=(B-q)/(H-X),H-X>=L&&(ne=H-X<=oe?ne:0,q=B,X=H)},getVelocity:B=>(B!==q&&ae.record(B),ne)};return ae})(),G=()=>{v=!1;let L=j;const oe=(t.length-1)*p.current;let X=.3;const q=U.getVelocity(L)*4;q&&(L=q*40+L,X=Math.abs(q)*.1),L%p.current!==0&&(L=Math.round(L/p.current)*p.current),L<0?L=0:L>oe&&(L=oe),k(0,L,X<.3?.3:X),M()},ue=L=>{P||(v=!0,V=L,K=j)},W=L=>{var oe;P||!v||(j=K-L+V,U.record(j),M(),C((oe=f.current)==null?void 0:oe.style,`translate3d(0,${-j}px,0)`))};return{touchstart:L=>ue(L.touches[0].pageY),mousedown:L=>ue(L.pageY),touchmove:L=>{L.preventDefault(),W(L.touches[0].pageY)},mousemove:L=>{L.preventDefault(),W(L.pageY)},touchend:()=>G(),touchcancel:()=>G(),mouseup:()=>G(),getValue:()=>j,scrollTo:k,setDisabled:(L=!1)=>{P=L}}})(),x=u.useCallback(j=>{m.scrollTo(0,j)},[m]),_=u.useCallback(j=>{m.scrollTo(0,j,0)},[m]),$=j=>{j!==T&&("selectedValue"in e||S(j),s&&s(j))},M=()=>{const j=m.getValue();if(j>=0){const K=u.Children.toArray(t),V=a(j,p.current,K.length);if(y.current!==V){y.current=V;const P=K[V];P&&e.onScrollChange?e.onScrollChange(P.props.value):!K&&console.warn&&console.warn("child not found",t,V)}}},D=()=>{const j=m.getValue();j>=0&&o(j,p.current,$)},N=()=>{const j=`${sp} ${zP}`,K=P=>{const{className:v="",style:C,value:I}=P.props,k=T===I;return O.jsx("div",{style:{...C},"data-selected":k?"true":void 0,className:`${k?j:sp} ${v}`,children:P.props.children},I)};return u.Children?u.Children.map(t,K):[].concat(t).map(K)};return u.useEffect(()=>{var P,v,C;const j=((P=d.current)==null?void 0:P.getBoundingClientRect().height)??0,K=((v=h.current)==null?void 0:v.getBoundingClientRect().height)??0;p.current=((C=h.current)==null?void 0:C.getBoundingClientRect().height)??0;let V=Math.floor(j/K);return V%2===0&&(V-=1),V-=1,V/=2,f.current.style.padding=`${K*V}px 0`,h.current.style.top=`${K*V}px`,m.setDisabled(c),i(T,p.current,x),Object.keys(m).forEach(I=>{var k;if(I.indexOf("touch")===0||I.indexOf("mouse")===0){const U=I.indexOf("move")>=0?{passive:!1}:{passive:!0};(k=d.current)==null||k.addEventListener(I,m[I],U)}}),()=>{Object.keys(m).forEach(I=>{var k;(I.indexOf("touch")===0||I.indexOf("mouse")===0)&&((k=d.current)==null||k.removeEventListener(I,m[I]))})}},[c,m,x,i,T]),u.useEffect(()=>{"selectedValue"in e&&T!==n&&S(n),m.setDisabled(c)},[n,T,e,m,c]),u.useEffect(()=>{i(T,p.current,_)},[_,i,T]),O.jsxs("div",{className:Re(YP,l),ref:d,children:[O.jsx("div",{className:Re(UP,l),ref:h}),O.jsx("div",{className:WP,ref:f,children:N()})]})},lc=XP(GP);var It=(e=>(e.DATE="date",e.MONTH="month",e.YEAR="year",e.DATE_TIME="datetime",e.TIME="time",e))(It||{});const Ji=24*60*60*1e3,ZP={am:"AM",pm:"PM"},jv=e=>new Date(e.getFullYear(),e.getMonth()+1,0).getDate(),Ta=e=>e<10?`0${e}`:`${e}`,Cr=e=>new Date(+e),QP=(e,t)=>{e.setDate(Math.min(e.getDate(),jv(new Date(e.getFullYear(),t)))),e.setMonth(t)},ap=(e,t,n)=>{if(n){const r=e.getHours();let i=t;i=r>=12?t+12:t,i=i>=24?0:i,e.setHours(i)}else e.setHours(t)},cp=(e,t)=>{t===0?e.setTime(+e-Ji/2):e.setTime(+e+Ji/2)},lp=(e,t)=>(t&&(e===0&&(e=12),e>12&&(e-=12)),e),JP=e=>["January","February","March","April","May","June","July","August","September","October","November","December"][e],eR=e=>{const{date:t,defaultDate:n=new Date(2e3,0,1),locale:r=ZP,mode:i="date",disabled:o=!1,className:s,minuteStep:a=1,use12Hours:c=!1,minDate:l,maxDate:d,formatDay:f,formatMonth:h}=e,[p,y]=u.useState(t||n),E=u.useRef(new Date(-1)),T=u.useRef(new Date);u.useEffect(()=>{"date"in e&&y(t||n)},[t,n,e]);const S=()=>C(p||E.current),m=()=>P().getFullYear(),x=()=>v().getFullYear(),_=()=>P().getMonth(),$=()=>v().getMonth(),M=()=>P().getDate(),D=()=>v().getDate(),N=()=>P().getHours(),j=()=>v().getHours(),K=()=>P().getMinutes(),V=()=>v().getMinutes(),P=()=>l||E.current,v=()=>d||T.current,C=X=>{const q=P(),ne=v();if(i===It.DATE_TIME){if(X<q)return Cr(q);if(X>ne)return Cr(ne)}else if(i===It.DATE||i===It.YEAR||i===It.MONTH){if(+X+Ji<=q)return Cr(q);if(X>=+ne+Ji)return Cr(ne)}else if(i===It.TIME){const ae=ne.getHours(),B=ne.getMinutes(),H=q.getHours(),J=q.getMinutes(),ee=X.getHours(),te=X.getMinutes();if(ee<H||ee===H&&te<J)return Cr(q);if(ee>ae||ee===ae&&te>B)return Cr(ne)}return X},I=(X,q)=>{const ne=parseInt(X[q],10),ae=Cr(S());if(i===It.DATE_TIME||i===It.DATE||i===It.YEAR||i===It.MONTH)switch(q){case 0:ae.setDate(ne);break;case 1:QP(ae,ne);break;case 2:ae.setFullYear(ne);break;case 3:ap(ae,ne);break;case 4:ae.setMinutes(ne);break;case 5:cp(ae,ne);break}else if(i===It.TIME)switch(q){case 0:ap(ae,ne);break;case 1:ae.setMinutes(ne);break;case 2:cp(ae,ne);break}return C(ae)},k=(X,q)=>{const ne=I(X,q);"date"in e||y(ne),e.onDateChange&&e.onDateChange(ne),e.onValueChange&&e.onValueChange(X,q)},U=(X,q)=>{if(e.onScrollChange){const ne=I(X,q);e.onScrollChange(ne,X,q)}},G=()=>{const X=S(),q=X.getFullYear(),ne=X.getMonth(),ae=m(),B=x(),H=_(),J=$(),ee=M(),te=D(),Z=[];for(let Xe=ae;Xe<=B;Xe+=1)Z.push({value:`${Xe}`,label:`${Xe}`});const ge={key:"year",props:{children:Z}};if(i===It.YEAR)return[ge];const Te=[];let Ie=0,Ae=11;ae===q&&(Ie=H),B===q&&(Ae=J);for(let Xe=Ie;Xe<=Ae;Xe+=1){const Rt=h?h(Xe,X):JP(Xe);Te.push({value:`${Xe}`,label:Rt})}const $e={key:"month",props:{children:Te}};if(i===It.MONTH)return[$e,ge];const Ye=[];let je=1,vt=jv(X);ae===q&&H===ne&&(je=ee),B===q&&J===ne&&(vt=te);for(let Xe=je;Xe<=vt;Xe+=1){const Rt=f?f(Xe,X):`${Xe}`;Ye.push({value:`${Xe}`,label:Rt})}return[{key:"day",props:{children:Ye}},$e,ge]},ue=X=>{let{minHour:q=0,maxHour:ne=23,minMinute:ae=0,maxMinute:B=59}=e;const H=K(),J=V(),ee=N(),te=j(),Z=X.getHours();if(i===It.DATE_TIME){const $e=X.getFullYear(),Ye=X.getMonth(),je=X.getDate(),vt=m(),Xe=x(),Rt=_(),st=$(),Ft=M(),Pe=D();vt===$e&&Rt===Ye&&Ft===je&&(q=ee,ee===Z&&(ae=H)),Xe===$e&&st===Ye&&Pe===je&&(ne=te,te===Z&&(B=J))}else q=ee,ee===Z&&(ae=H),ne=te,te===Z&&(B=J);const ge=[];q===0&&ne===0||q!==0&&ne!==0?q=lp(q):q===0&&c&&(q=1,ge.push({value:"0",label:"12"})),ne=lp(ne);for(let $e=q;$e<=ne;$e+=1)ge.push({value:`${$e}`,label:Ta($e)});const Te=[],Ie=X.getMinutes();for(let $e=ae;$e<=B;$e+=a)Te.push({value:`${$e}`,label:Ta($e)}),Ie>$e&&Ie<$e+a&&Te.push({value:`${Ie}`,label:Ta(Ie)});return{cols:[{key:"hours",props:{children:ge}},{key:"minutes",props:{children:Te}}].concat(c?[{key:"ampm",props:{children:[{value:"0",label:r.am},{value:"1",label:r.pm}]}}]:[]),selMinute:Ie}},W=()=>{const X=S();let q=[],ne=[];if(i===It.YEAR)return{cols:G(),value:[`${X.getFullYear()}`]};if(i===It.MONTH)return{cols:G(),value:[`${X.getMonth()}`,`${X.getFullYear()}`]};if((i===It.DATE_TIME||i===It.DATE)&&(q=G(),ne=[`${X.getDate()}`,`${X.getMonth()}`,`${X.getFullYear()}`]),i===It.DATE_TIME||i===It.TIME){const ae=ue(X);q=q.concat(ae.cols);const B=X.getHours();let H=[`${B}`,`${ae.selMinute}`],J=B;c&&(J=B>12?B-12:B,H=[`${J}`,`${ae.selMinute}`,`${B>=12?1:0}`]),ne=ne.concat(H)}return{value:ne,cols:q}},{value:L,cols:oe}=W();return O.jsx(Nv,{className:s,selectedValue:L,onValueChange:k,onScrollChange:U,children:oe.map(X=>O.jsx(lc,{disabled:o,className:`picker-item-${X.key}`,children:X.props.children.map(q=>O.jsx(lc.Item,{value:q.value,children:q.label},q.value))},X.key))})};var uc={exports:{}},lt={};/** @license React v17.0.2
|
|
135
135
|
* react-is.production.min.js
|
|
136
136
|
*
|
|
137
137
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
138
138
|
*
|
|
139
139
|
* This source code is licensed under the MIT license found in the
|
|
140
140
|
* LICENSE file in the root directory of this source tree.
|
|
141
|
-
*/var up;function tR(){if(up)return lt;up=1;var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,s=60110,a=60112,c=60113,l=60120,d=60115,f=60116,h=60121,p=60122,
|
|
141
|
+
*/var up;function tR(){if(up)return lt;up=1;var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,s=60110,a=60112,c=60113,l=60120,d=60115,f=60116,h=60121,p=60122,y=60117,E=60129,T=60131;if(typeof Symbol=="function"&&Symbol.for){var S=Symbol.for;e=S("react.element"),t=S("react.portal"),n=S("react.fragment"),r=S("react.strict_mode"),i=S("react.profiler"),o=S("react.provider"),s=S("react.context"),a=S("react.forward_ref"),c=S("react.suspense"),l=S("react.suspense_list"),d=S("react.memo"),f=S("react.lazy"),h=S("react.block"),p=S("react.server.block"),y=S("react.fundamental"),E=S("react.debug_trace_mode"),T=S("react.legacy_hidden")}function m(v){if(typeof v=="object"&&v!==null){var C=v.$$typeof;switch(C){case e:switch(v=v.type,v){case n:case i:case r:case c:case l:return v;default:switch(v=v&&v.$$typeof,v){case s:case a:case f:case d:case o:return v;default:return C}}case t:return C}}}var x=o,_=e,$=a,M=n,D=f,N=d,j=t,K=i,V=r,P=c;return lt.ContextConsumer=s,lt.ContextProvider=x,lt.Element=_,lt.ForwardRef=$,lt.Fragment=M,lt.Lazy=D,lt.Memo=N,lt.Portal=j,lt.Profiler=K,lt.StrictMode=V,lt.Suspense=P,lt.isAsyncMode=function(){return!1},lt.isConcurrentMode=function(){return!1},lt.isContextConsumer=function(v){return m(v)===s},lt.isContextProvider=function(v){return m(v)===o},lt.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===e},lt.isForwardRef=function(v){return m(v)===a},lt.isFragment=function(v){return m(v)===n},lt.isLazy=function(v){return m(v)===f},lt.isMemo=function(v){return m(v)===d},lt.isPortal=function(v){return m(v)===t},lt.isProfiler=function(v){return m(v)===i},lt.isStrictMode=function(v){return m(v)===r},lt.isSuspense=function(v){return m(v)===c},lt.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===n||v===i||v===E||v===r||v===c||v===l||v===T||typeof v=="object"&&v!==null&&(v.$$typeof===f||v.$$typeof===d||v.$$typeof===o||v.$$typeof===s||v.$$typeof===a||v.$$typeof===y||v.$$typeof===h||v[0]===p)},lt.typeOf=m,lt}var ut={};/** @license React v17.0.2
|
|
142
142
|
* react-is.development.js
|
|
143
143
|
*
|
|
144
144
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
145
145
|
*
|
|
146
146
|
* This source code is licensed under the MIT license found in the
|
|
147
147
|
* LICENSE file in the root directory of this source tree.
|
|
148
|
-
*/var dp;function nR(){return dp||(dp=1,process.env.NODE_ENV!=="production"&&function(){var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,s=60110,a=60112,c=60113,l=60120,d=60115,f=60116,h=60121,p=60122,w=60117,E=60129,T=60131;if(typeof Symbol=="function"&&Symbol.for){var S=Symbol.for;e=S("react.element"),t=S("react.portal"),n=S("react.fragment"),r=S("react.strict_mode"),i=S("react.profiler"),o=S("react.provider"),s=S("react.context"),a=S("react.forward_ref"),c=S("react.suspense"),l=S("react.suspense_list"),d=S("react.memo"),f=S("react.lazy"),h=S("react.block"),p=S("react.server.block"),w=S("react.fundamental"),S("react.scope"),S("react.opaque.id"),E=S("react.debug_trace_mode"),S("react.offscreen"),T=S("react.legacy_hidden")}var m=!1;function x(te){return!!(typeof te=="string"||typeof te=="function"||te===n||te===i||te===E||te===r||te===c||te===l||te===T||m||typeof te=="object"&&te!==null&&(te.$$typeof===f||te.$$typeof===d||te.$$typeof===o||te.$$typeof===s||te.$$typeof===a||te.$$typeof===w||te.$$typeof===h||te[0]===p))}function _(te){if(typeof te=="object"&&te!==null){var Z=te.$$typeof;switch(Z){case e:var ge=te.type;switch(ge){case n:case i:case r:case c:case l:return ge;default:var Te=ge&&ge.$$typeof;switch(Te){case s:case a:case f:case d:case o:return Te;default:return Z}}case t:return Z}}}var $=s,O=o,M=e,N=a,j=n,K=f,V=d,P=t,v=i,C=r,I=c,k=!1,U=!1;function G(te){return k||(k=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function ue(te){return U||(U=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function W(te){return _(te)===s}function L(te){return _(te)===o}function oe(te){return typeof te=="object"&&te!==null&&te.$$typeof===e}function X(te){return _(te)===a}function q(te){return _(te)===n}function ne(te){return _(te)===f}function ae(te){return _(te)===d}function B(te){return _(te)===t}function H(te){return _(te)===i}function J(te){return _(te)===r}function ee(te){return _(te)===c}ut.ContextConsumer=$,ut.ContextProvider=O,ut.Element=M,ut.ForwardRef=N,ut.Fragment=j,ut.Lazy=K,ut.Memo=V,ut.Portal=P,ut.Profiler=v,ut.StrictMode=C,ut.Suspense=I,ut.isAsyncMode=G,ut.isConcurrentMode=ue,ut.isContextConsumer=W,ut.isContextProvider=L,ut.isElement=oe,ut.isForwardRef=X,ut.isFragment=q,ut.isLazy=ne,ut.isMemo=ae,ut.isPortal=B,ut.isProfiler=H,ut.isStrictMode=J,ut.isSuspense=ee,ut.isValidElementType=x,ut.typeOf=_}()),ut}process.env.NODE_ENV==="production"?uc.exports=tR():uc.exports=nR();var fp=uc.exports;let pp=e=>typeof e=="object"&&e!=null&&e.nodeType===1,hp=(e,t)=>(!t||e!=="hidden")&&e!=="visible"&&e!=="clip",Sa=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){let n=getComputedStyle(e,null);return hp(n.overflowY,t)||hp(n.overflowX,t)||(r=>{let i=(o=>{if(!o.ownerDocument||!o.ownerDocument.defaultView)return null;try{return o.ownerDocument.defaultView.frameElement}catch{return null}})(r);return!!i&&(i.clientHeight<r.scrollHeight||i.clientWidth<r.scrollWidth)})(e)}return!1},Ti=(e,t,n,r,i,o,s,a)=>o<e&&s>t||o>e&&s<t?0:o<=e&&a<=n||s>=t&&a>=n?o-e-r:s>t&&a<n||o<e&&a>n?s-t+i:0,rR=e=>{let t=e.parentElement;return t??(e.getRootNode().host||null)};var oR=(e,t)=>{var n,r,i,o,s,a;if(typeof document>"u")return[];let{scrollMode:c,block:l,inline:d,boundary:f,skipOverflowHiddenElements:h}=t,p=typeof f=="function"?f:C=>C!==f;if(!pp(e))throw new TypeError("Invalid target");let w=document.scrollingElement||document.documentElement,E=[],T=e;for(;pp(T)&&p(T);){if(T=rR(T),T===w){E.push(T);break}T!=null&&T===document.body&&Sa(T)&&!Sa(document.documentElement)||T!=null&&Sa(T,h)&&E.push(T)}let S=(r=(n=window.visualViewport)==null?void 0:n.width)!=null?r:innerWidth,m=(o=(i=window.visualViewport)==null?void 0:i.height)!=null?o:innerHeight,x=(s=window.scrollX)!=null?s:pageXOffset,_=(a=window.scrollY)!=null?a:pageYOffset,{height:$,width:O,top:M,right:N,bottom:j,left:K}=e.getBoundingClientRect(),V=l==="start"||l==="nearest"?M:l==="end"?j:M+$/2,P=d==="center"?K+O/2:d==="end"?N:K,v=[];for(let C=0;C<E.length;C++){let I=E[C],{height:k,width:U,top:G,right:ue,bottom:W,left:L}=I.getBoundingClientRect();if(c==="if-needed"&&M>=0&&K>=0&&j<=m&&N<=S&&M>=G&&j<=W&&K>=L&&N<=ue)return v;let oe=getComputedStyle(I),X=parseInt(oe.borderLeftWidth,10),q=parseInt(oe.borderTopWidth,10),ne=parseInt(oe.borderRightWidth,10),ae=parseInt(oe.borderBottomWidth,10),B=0,H=0,J="offsetWidth"in I?I.offsetWidth-I.clientWidth-X-ne:0,ee="offsetHeight"in I?I.offsetHeight-I.clientHeight-q-ae:0,te="offsetWidth"in I?I.offsetWidth===0?0:U/I.offsetWidth:0,Z="offsetHeight"in I?I.offsetHeight===0?0:k/I.offsetHeight:0;if(w===I)B=l==="start"?V:l==="end"?V-m:l==="nearest"?Ti(_,_+m,m,q,ae,_+V,_+V+$,$):V-m/2,H=d==="start"?P:d==="center"?P-S/2:d==="end"?P-S:Ti(x,x+S,S,X,ne,x+P,x+P+O,O),B=Math.max(0,B+_),H=Math.max(0,H+x);else{B=l==="start"?V-G-q:l==="end"?V-W+ae+ee:l==="nearest"?Ti(G,W,k,q,ae+ee,V,V+$,$):V-(G+k/2)+ee/2,H=d==="start"?P-L-X:d==="center"?P-(L+U/2)+J/2:d==="end"?P-ue+ne+J:Ti(L,ue,U,X,ne+J,P,P+O,O);let{scrollLeft:ge,scrollTop:Te}=I;B=Math.max(0,Math.min(Te+B/Z,I.scrollHeight-k/Z+ee)),H=Math.max(0,Math.min(ge+H/te,I.scrollWidth-U/te+J)),V+=Te-B,P+=ge-H}v.push({el:I,top:B,left:H})}return v},iR=0;function mp(e){return typeof e=="function"?e:en}function en(){}function Vv(e,t){if(e){var n=oR(e,{boundary:t,block:"nearest",scrollMode:"if-needed"});n.forEach(function(r){var i=r.el,o=r.top,s=r.left;i.scrollTop=o,i.scrollLeft=s})}}function vp(e,t,n){var r=e===t||t instanceof n.Node&&e.contains&&e.contains(t);return r}function $l(e,t){var n;function r(){n&&clearTimeout(n)}function i(){for(var o=arguments.length,s=new Array(o),a=0;a<o;a++)s[a]=arguments[a];r(),n=setTimeout(function(){n=null,e.apply(void 0,s)},t)}return i.cancel=r,i}function wt(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){for(var i=arguments.length,o=new Array(i>1?i-1:0),s=1;s<i;s++)o[s-1]=arguments[s];return t.some(function(a){return a&&a.apply(void 0,[r].concat(o)),r.preventDownshiftDefault||r.hasOwnProperty("nativeEvent")&&r.nativeEvent.preventDownshiftDefault})}}function ir(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){t.forEach(function(i){typeof i=="function"?i(r):i&&(i.current=r)})}}function Lv(){return String(iR++)}function Fv(e){var t=e.isOpen,n=e.resultCount,r=e.previousResultCount;return t?n?n!==r?n+" result"+(n===1?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":""}function gp(e,t){return e=Array.isArray(e)?e[0]:e,!e&&t?t:e}function Bv(e){return typeof e.type=="string"}function Hv(e){return e.props}function sR(e,t){console.error('The property "'+t+'" is required in "'+e+'"')}var aR=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Si(e){e===void 0&&(e={});var t={};return aR.forEach(function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function Yo(e,t){return Object.keys(e).reduce(function(n,r){return n[r]=es(t,r)?t[r]:e[r],n},{})}function es(e,t){return e[t]!==void 0}function zo(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&t.indexOf("Arrow")!==0?"Arrow"+t:t}function cR(e){return Object.prototype.toString.call(e)==="[object Object]"}function Rr(e,t,n,r,i){if(i===void 0&&(i=!0),n===0)return-1;var o=n-1;(typeof t!="number"||t<0||t>=n)&&(t=e>0?-1:o+1);var s=t+e;s<0?s=i?o:0:s>o&&(s=i?0:o);var a=Nr(e,s,n,r,i);return a===-1?t>=n?-1:t:a}function Nr(e,t,n,r,i){var o=r(t);if(!o||!o.hasAttribute("disabled"))return t;if(e>0){for(var s=t+1;s<n;s++)if(!r(s).hasAttribute("disabled"))return s}else for(var a=t-1;a>=0;a--)if(!r(a).hasAttribute("disabled"))return a;return i?e>0?Nr(1,0,n,r,!1):Nr(-1,n-1,n,r,!1):-1}function ts(e,t,n,r){return r===void 0&&(r=!0),t.some(function(i){return i&&(vp(i,e,n)||r&&vp(i,n.document.activeElement,n))})}var Pl=en;process.env.NODE_ENV!=="production"&&(Pl=function(t,n,r){var i="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(t).forEach(function(o){n[o]!==void 0&&r[o]===void 0?console.error('downshift: A component has changed the controlled prop "'+o+'" to be uncontrolled. '+i):n[o]===void 0&&r[o]!==void 0&&console.error('downshift: A component has changed the uncontrolled prop "'+o+'" to be controlled. '+i)})});var lR=$l(function(e){Wv(e).textContent=""},500);function Rl(e,t){var n=Wv(t);e&&(n.textContent=e,lR(t))}function Wv(e){e===void 0&&(e=document);var t=e.getElementById("a11y-status-message");return t||(t=e.createElement("div"),t.setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}var Uv=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,Yv=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,zv=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Oi=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,Mi=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,Kv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,qv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,Xv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,Gv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,Zv=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,Qv=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,Jv=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,eg=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,dc=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,tg=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,ng=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,rg=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16,uR=Object.freeze({__proto__:null,unknown:Uv,mouseUp:Yv,itemMouseEnter:zv,keyDownArrowUp:Oi,keyDownArrowDown:Mi,keyDownEscape:Kv,keyDownEnter:qv,keyDownHome:Xv,keyDownEnd:Gv,clickItem:Zv,blurInput:Qv,changeInput:Jv,keyDownSpaceButton:eg,clickButton:dc,blurButton:tg,controlledPropUpdatedSelectedItem:ng,touchEnd:rg}),dR=["refKey","ref"],fR=["onClick","onPress","onKeyDown","onKeyUp","onBlur"],pR=["onKeyDown","onBlur","onChange","onInput","onChangeText"],hR=["refKey","ref"],mR=["onMouseMove","onMouseDown","onClick","onPress","index","item"],vR=function(){var e=function(t){Nc(n,t);function n(i){var o;o=t.call(this,i)||this,o.id=o.props.id||"downshift-"+Lv(),o.menuId=o.props.menuId||o.id+"-menu",o.labelId=o.props.labelId||o.id+"-label",o.inputId=o.props.inputId||o.id+"-input",o.getItemId=o.props.getItemId||function(m){return o.id+"-item-"+m},o.input=null,o.items=[],o.itemCount=null,o.previousResultCount=0,o.timeoutIds=[],o.internalSetTimeout=function(m,x){var _=setTimeout(function(){o.timeoutIds=o.timeoutIds.filter(function($){return $!==_}),m()},x);o.timeoutIds.push(_)},o.setItemCount=function(m){o.itemCount=m},o.unsetItemCount=function(){o.itemCount=null},o.setHighlightedIndex=function(m,x){m===void 0&&(m=o.props.defaultHighlightedIndex),x===void 0&&(x={}),x=Si(x),o.internalSetState(ie({highlightedIndex:m},x))},o.clearSelection=function(m){o.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:o.props.defaultHighlightedIndex,isOpen:o.props.defaultIsOpen},m)},o.selectItem=function(m,x,_){x=Si(x),o.internalSetState(ie({isOpen:o.props.defaultIsOpen,highlightedIndex:o.props.defaultHighlightedIndex,selectedItem:m,inputValue:o.props.itemToString(m)},x),_)},o.selectItemAtIndex=function(m,x,_){var $=o.items[m];$!=null&&o.selectItem($,x,_)},o.selectHighlightedItem=function(m,x){return o.selectItemAtIndex(o.getState().highlightedIndex,m,x)},o.internalSetState=function(m,x){var _,$,O={},M=typeof m=="function";return!M&&m.hasOwnProperty("inputValue")&&o.props.onInputValueChange(m.inputValue,ie({},o.getStateAndHelpers(),m)),o.setState(function(N){N=o.getState(N);var j=M?m(N):m;j=o.props.stateReducer(N,j),_=j.hasOwnProperty("selectedItem");var K={};return _&&j.selectedItem!==N.selectedItem&&($=j.selectedItem),j.type=j.type||Uv,Object.keys(j).forEach(function(V){N[V]!==j[V]&&(O[V]=j[V]),V!=="type"&&(j[V],es(o.props,V)||(K[V]=j[V]))}),M&&j.hasOwnProperty("inputValue")&&o.props.onInputValueChange(j.inputValue,ie({},o.getStateAndHelpers(),j)),K},function(){mp(x)();var N=Object.keys(O).length>1;N&&o.props.onStateChange(O,o.getStateAndHelpers()),_&&o.props.onSelect(m.selectedItem,o.getStateAndHelpers()),$!==void 0&&o.props.onChange($,o.getStateAndHelpers()),o.props.onUserAction(O,o.getStateAndHelpers())})},o.rootRef=function(m){return o._rootNode=m},o.getRootProps=function(m,x){var _,$=m===void 0?{}:m,O=$.refKey,M=O===void 0?"ref":O,N=$.ref,j=zt($,dR),K=x===void 0?{}:x,V=K.suppressRefError,P=V===void 0?!1:V;o.getRootProps.called=!0,o.getRootProps.refKey=M,o.getRootProps.suppressRefError=P;var v=o.getState(),C=v.isOpen;return ie((_={},_[M]=ir(N,o.rootRef),_.role="combobox",_["aria-expanded"]=C,_["aria-haspopup"]="listbox",_["aria-owns"]=C?o.menuId:null,_["aria-labelledby"]=o.labelId,_),j)},o.keyDownHandlers={ArrowDown:function(x){var _=this;if(x.preventDefault(),this.getState().isOpen){var $=x.shiftKey?5:1;this.moveHighlightedIndex($,{type:Mi})}else this.internalSetState({isOpen:!0,type:Mi},function(){var O=_.getItemCount();if(O>0){var M=_.getState(),N=M.highlightedIndex,j=Rr(1,N,O,function(K){return _.getItemNodeFromIndex(K)});_.setHighlightedIndex(j,{type:Mi})}})},ArrowUp:function(x){var _=this;if(x.preventDefault(),this.getState().isOpen){var $=x.shiftKey?-5:-1;this.moveHighlightedIndex($,{type:Oi})}else this.internalSetState({isOpen:!0,type:Oi},function(){var O=_.getItemCount();if(O>0){var M=_.getState(),N=M.highlightedIndex,j=Rr(-1,N,O,function(K){return _.getItemNodeFromIndex(K)});_.setHighlightedIndex(j,{type:Oi})}})},Enter:function(x){if(x.which!==229){var _=this.getState(),$=_.isOpen,O=_.highlightedIndex;if($&&O!=null){x.preventDefault();var M=this.items[O],N=this.getItemNodeFromIndex(O);if(M==null||N&&N.hasAttribute("disabled"))return;this.selectHighlightedItem({type:qv})}}},Escape:function(x){x.preventDefault(),this.reset(ie({type:Kv},!this.state.isOpen&&{selectedItem:null,inputValue:""}))}},o.buttonKeyDownHandlers=ie({},o.keyDownHandlers,{" ":function(x){x.preventDefault(),this.toggleMenu({type:eg})}}),o.inputKeyDownHandlers=ie({},o.keyDownHandlers,{Home:function(x){var _=this,$=this.getState(),O=$.isOpen;if(O){x.preventDefault();var M=this.getItemCount();if(!(M<=0||!O)){var N=Nr(1,0,M,function(j){return _.getItemNodeFromIndex(j)},!1);this.setHighlightedIndex(N,{type:Xv})}}},End:function(x){var _=this,$=this.getState(),O=$.isOpen;if(O){x.preventDefault();var M=this.getItemCount();if(!(M<=0||!O)){var N=Nr(-1,M-1,M,function(j){return _.getItemNodeFromIndex(j)},!1);this.setHighlightedIndex(N,{type:Gv})}}}}),o.getToggleButtonProps=function(m){var x=m===void 0?{}:m,_=x.onClick;x.onPress;var $=x.onKeyDown,O=x.onKeyUp,M=x.onBlur,N=zt(x,fR),j=o.getState(),K=j.isOpen,V={onClick:wt(_,o.buttonHandleClick),onKeyDown:wt($,o.buttonHandleKeyDown),onKeyUp:wt(O,o.buttonHandleKeyUp),onBlur:wt(M,o.buttonHandleBlur)},P=N.disabled?{}:V;return ie({type:"button",role:"button","aria-label":K?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},P,N)},o.buttonHandleKeyUp=function(m){m.preventDefault()},o.buttonHandleKeyDown=function(m){var x=zo(m);o.buttonKeyDownHandlers[x]&&o.buttonKeyDownHandlers[x].call(Od(o),m)},o.buttonHandleClick=function(m){m.preventDefault(),o.props.environment.document.activeElement===o.props.environment.document.body&&m.target.focus(),process.env.NODE_ENV==="test"?o.toggleMenu({type:dc}):o.internalSetTimeout(function(){return o.toggleMenu({type:dc})})},o.buttonHandleBlur=function(m){var x=m.target;o.internalSetTimeout(function(){!o.isMouseDown&&(o.props.environment.document.activeElement==null||o.props.environment.document.activeElement.id!==o.inputId)&&o.props.environment.document.activeElement!==x&&o.reset({type:tg})})},o.getLabelProps=function(m){return ie({htmlFor:o.inputId,id:o.labelId},m)},o.getInputProps=function(m){var x=m===void 0?{}:m,_=x.onKeyDown,$=x.onBlur,O=x.onChange,M=x.onInput;x.onChangeText;var N=zt(x,pR),j,K={};j="onChange";var V=o.getState(),P=V.inputValue,v=V.isOpen,C=V.highlightedIndex;if(!N.disabled){var I;K=(I={},I[j]=wt(O,M,o.inputHandleChange),I.onKeyDown=wt(_,o.inputHandleKeyDown),I.onBlur=wt($,o.inputHandleBlur),I)}return ie({"aria-autocomplete":"list","aria-activedescendant":v&&typeof C=="number"&&C>=0?o.getItemId(C):null,"aria-controls":v?o.menuId:null,"aria-labelledby":N&&N["aria-label"]?void 0:o.labelId,autoComplete:"off",value:P,id:o.inputId},K,N)},o.inputHandleKeyDown=function(m){var x=zo(m);x&&o.inputKeyDownHandlers[x]&&o.inputKeyDownHandlers[x].call(Od(o),m)},o.inputHandleChange=function(m){o.internalSetState({type:Jv,isOpen:!0,inputValue:m.target.value,highlightedIndex:o.props.defaultHighlightedIndex})},o.inputHandleBlur=function(){o.internalSetTimeout(function(){var m=o.props.environment.document&&!!o.props.environment.document.activeElement&&!!o.props.environment.document.activeElement.dataset&&o.props.environment.document.activeElement.dataset.toggle&&o._rootNode&&o._rootNode.contains(o.props.environment.document.activeElement);!o.isMouseDown&&!m&&o.reset({type:Qv})})},o.menuRef=function(m){o._menuNode=m},o.getMenuProps=function(m,x){var _,$=m===void 0?{}:m,O=$.refKey,M=O===void 0?"ref":O,N=$.ref,j=zt($,hR),K=x===void 0?{}:x,V=K.suppressRefError,P=V===void 0?!1:V;return o.getMenuProps.called=!0,o.getMenuProps.refKey=M,o.getMenuProps.suppressRefError=P,ie((_={},_[M]=ir(N,o.menuRef),_.role="listbox",_["aria-labelledby"]=j&&j["aria-label"]?null:o.labelId,_.id=o.menuId,_),j)},o.getItemProps=function(m){var x,_=m===void 0?{}:m,$=_.onMouseMove,O=_.onMouseDown,M=_.onClick;_.onPress;var N=_.index,j=_.item,K=j===void 0?process.env.NODE_ENV==="production"?void 0:sR("getItemProps","item"):j,V=zt(_,mR);N===void 0?(o.items.push(K),N=o.items.indexOf(K)):o.items[N]=K;var P="onClick",v=M,C=(x={onMouseMove:wt($,function(){N!==o.getState().highlightedIndex&&(o.setHighlightedIndex(N,{type:zv}),o.avoidScrolling=!0,o.internalSetTimeout(function(){return o.avoidScrolling=!1},250))}),onMouseDown:wt(O,function(k){k.preventDefault()})},x[P]=wt(v,function(){o.selectItemAtIndex(N,{type:Zv})}),x),I=V.disabled?{onMouseDown:C.onMouseDown}:C;return ie({id:o.getItemId(N),role:"option","aria-selected":o.getState().highlightedIndex===N},I,V)},o.clearItems=function(){o.items=[]},o.reset=function(m,x){m===void 0&&(m={}),m=Si(m),o.internalSetState(function(_){var $=_.selectedItem;return ie({isOpen:o.props.defaultIsOpen,highlightedIndex:o.props.defaultHighlightedIndex,inputValue:o.props.itemToString($)},m)},x)},o.toggleMenu=function(m,x){m===void 0&&(m={}),m=Si(m),o.internalSetState(function(_){var $=_.isOpen;return ie({isOpen:!$},$&&{highlightedIndex:o.props.defaultHighlightedIndex},m)},function(){var _=o.getState(),$=_.isOpen,O=_.highlightedIndex;$&&o.getItemCount()>0&&typeof O=="number"&&o.setHighlightedIndex(O,m),mp(x)()})},o.openMenu=function(m){o.internalSetState({isOpen:!0},m)},o.closeMenu=function(m){o.internalSetState({isOpen:!1},m)},o.updateStatus=$l(function(){var m=o.getState(),x=o.items[m.highlightedIndex],_=o.getItemCount(),$=o.props.getA11yStatusMessage(ie({itemToString:o.props.itemToString,previousResultCount:o.previousResultCount,resultCount:_,highlightedItem:x},m));o.previousResultCount=_,Rl($,o.props.environment.document)},200);var s=o.props,a=s.defaultHighlightedIndex,c=s.initialHighlightedIndex,l=c===void 0?a:c,d=s.defaultIsOpen,f=s.initialIsOpen,h=f===void 0?d:f,p=s.initialInputValue,w=p===void 0?"":p,E=s.initialSelectedItem,T=E===void 0?null:E,S=o.getState({highlightedIndex:l,isOpen:h,inputValue:w,selectedItem:T});return S.selectedItem!=null&&o.props.initialInputValue===void 0&&(S.inputValue=o.props.itemToString(S.selectedItem)),o.state=S,o}var r=n.prototype;return r.internalClearTimeouts=function(){this.timeoutIds.forEach(function(o){clearTimeout(o)}),this.timeoutIds=[]},r.getState=function(o){return o===void 0&&(o=this.state),Yo(o,this.props)},r.getItemCount=function(){var o=this.items.length;return this.itemCount!=null?o=this.itemCount:this.props.itemCount!==void 0&&(o=this.props.itemCount),o},r.getItemNodeFromIndex=function(o){return this.props.environment.document.getElementById(this.getItemId(o))},r.scrollHighlightedItemIntoView=function(){{var o=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(o,this._menuNode)}},r.moveHighlightedIndex=function(o,s){var a=this,c=this.getItemCount(),l=this.getState(),d=l.highlightedIndex;if(c>0){var f=Rr(o,d,c,function(h){return a.getItemNodeFromIndex(h)});this.setHighlightedIndex(f,s)}},r.getStateAndHelpers=function(){var o=this.getState(),s=o.highlightedIndex,a=o.inputValue,c=o.selectedItem,l=o.isOpen,d=this.props.itemToString,f=this.id,h=this.getRootProps,p=this.getToggleButtonProps,w=this.getLabelProps,E=this.getMenuProps,T=this.getInputProps,S=this.getItemProps,m=this.openMenu,x=this.closeMenu,_=this.toggleMenu,$=this.selectItem,O=this.selectItemAtIndex,M=this.selectHighlightedItem,N=this.setHighlightedIndex,j=this.clearSelection,K=this.clearItems,V=this.reset,P=this.setItemCount,v=this.unsetItemCount,C=this.internalSetState;return{getRootProps:h,getToggleButtonProps:p,getLabelProps:w,getMenuProps:E,getInputProps:T,getItemProps:S,reset:V,openMenu:m,closeMenu:x,toggleMenu:_,selectItem:$,selectItemAtIndex:O,selectHighlightedItem:M,setHighlightedIndex:N,clearSelection:j,clearItems:K,setItemCount:P,unsetItemCount:v,setState:C,itemToString:d,id:f,highlightedIndex:s,inputValue:a,isOpen:l,selectedItem:c}},r.componentDidMount=function(){var o=this;process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&yp(this._menuNode,this.getMenuProps);{var s=function(){o.isMouseDown=!0},a=function(p){o.isMouseDown=!1;var w=ts(p.target,[o._rootNode,o._menuNode],o.props.environment);!w&&o.getState().isOpen&&o.reset({type:Yv},function(){return o.props.onOuterClick(o.getStateAndHelpers())})},c=function(){o.isTouchMove=!1},l=function(){o.isTouchMove=!0},d=function(p){var w=ts(p.target,[o._rootNode,o._menuNode],o.props.environment,!1);!o.isTouchMove&&!w&&o.getState().isOpen&&o.reset({type:rg},function(){return o.props.onOuterClick(o.getStateAndHelpers())})},f=this.props.environment;f.addEventListener("mousedown",s),f.addEventListener("mouseup",a),f.addEventListener("touchstart",c),f.addEventListener("touchmove",l),f.addEventListener("touchend",d),this.cleanup=function(){o.internalClearTimeouts(),o.updateStatus.cancel(),f.removeEventListener("mousedown",s),f.removeEventListener("mouseup",a),f.removeEventListener("touchstart",c),f.removeEventListener("touchmove",l),f.removeEventListener("touchend",d)}}},r.shouldScroll=function(o,s){var a=this.props.highlightedIndex===void 0?this.getState():this.props,c=a.highlightedIndex,l=s.highlightedIndex===void 0?o:s,d=l.highlightedIndex,f=c&&this.getState().isOpen&&!o.isOpen,h=c!==d;return f||h},r.componentDidUpdate=function(o,s){process.env.NODE_ENV!=="production"&&(Pl(this.state,o,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&yp(this._menuNode,this.getMenuProps)),es(this.props,"selectedItem")&&this.props.selectedItemChanged(o.selectedItem,this.props.selectedItem)&&this.internalSetState({type:ng,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(s,o)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},r.componentWillUnmount=function(){this.cleanup()},r.render=function(){var o=gp(this.props.children,en);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var s=gp(o(this.getStateAndHelpers()));if(!s)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&gR(s,this.getRootProps),s;if(Bv(s))return u.cloneElement(s,this.getRootProps(Hv(s)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")},n}(u.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:Fv,itemToString:function(n){return n==null?"":(process.env.NODE_ENV!=="production"&&cR(n)&&!n.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",n),String(n))},onStateChange:en,onInputValueChange:en,onUserAction:en,onChange:en,onSelect:en,onOuterClick:en,selectedItemChanged:function(n,r){return n!==r},environment:typeof window>"u"?{}:window,stateReducer:function(n,r){return r},suppressRefError:!1,scrollIntoView:Vv},e.stateChangeTypes=uR,e}();process.env.NODE_ENV!=="production"&&(vR.propTypes={children:z.func,defaultHighlightedIndex:z.number,defaultIsOpen:z.bool,initialHighlightedIndex:z.number,initialSelectedItem:z.any,initialInputValue:z.string,initialIsOpen:z.bool,getA11yStatusMessage:z.func,itemToString:z.func,onChange:z.func,onSelect:z.func,onStateChange:z.func,onInputValueChange:z.func,onUserAction:z.func,onOuterClick:z.func,selectedItemChanged:z.func,stateReducer:z.func,itemCount:z.number,id:z.string,environment:z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})}),suppressRefError:z.bool,scrollIntoView:z.func,selectedItem:z.any,isOpen:z.bool,inputValue:z.string,highlightedIndex:z.number,labelId:z.string,inputId:z.string,menuId:z.string,getItemId:z.func});function yp(e,t){var n=t.refKey;e||console.error('downshift: The ref prop "'+n+'" from getMenuProps was not applied correctly on your menu element.')}function gR(e,t){var n=t.refKey,r=n!=="ref",i=!Bv(e);i&&!r&&!fp.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!i&&r&&console.error('downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "'+n+'"'),!fp.isForwardRef(e)&&!Hv(e)[n]&&console.error('downshift: You must apply the ref prop "'+n+'" from getRootProps onto your root element.')}var yR=["isInitialMount","highlightedIndex","items","environment"],og={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""};function bR(e,t,n){var r=e.props,i=e.type,o={};Object.keys(t).forEach(function(s){wR(s,e,t,n),n[s]!==t[s]&&(o[s]=n[s])}),r.onStateChange&&Object.keys(o).length&&r.onStateChange(ie({type:i},o))}function wR(e,t,n,r){var i=t.props,o=t.type,s="on"+Il(e)+"Change";i[s]&&r[e]!==void 0&&r[e]!==n[e]&&i[s](ie({type:o},r))}function xR(e,t){return t.changes}function ER(e){var t=e.selectedItem,n=e.itemToString;return t?n(t)+" has been selected.":""}var CR=$l(function(e,t){Rl(e(),t)},200),_R=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?u.useLayoutEffect:u.useEffect;function TR(e){var t=e.id,n=t===void 0?"downshift-"+Lv():t,r=e.labelId,i=e.menuId,o=e.getItemId,s=e.toggleButtonId,a=e.inputId,c=u.useRef({labelId:r||n+"-label",menuId:i||n+"-menu",getItemId:o||function(l){return n+"-item-"+l},toggleButtonId:s||n+"-toggle-button",inputId:a||n+"-input"});return c.current}function ig(e,t,n,r){var i,o;if(e===void 0){if(t===void 0)throw new Error(r);i=n[t],o=t}else o=t===void 0?n.indexOf(e):t,i=e;return[i,o]}function SR(e){return e?String(e):""}function Il(e){return""+e.slice(0,1).toUpperCase()+e.slice(1)}function Al(e){var t=u.useRef(e);return t.current=e,t}function sg(e,t,n){var r=u.useRef(),i=u.useRef(),o=u.useCallback(function(h,p){i.current=p,h=Yo(h,p.props);var w=e(h,p),E=p.props.stateReducer(h,ie({},p,{changes:w}));return E},[e]),s=u.useReducer(o,t),a=s[0],c=s[1],l=Al(n),d=u.useCallback(function(h){return c(ie({props:l.current},h))},[l]),f=i.current;return u.useEffect(function(){f&&r.current&&r.current!==a&&bR(f,Yo(r.current,f.props),a),r.current=a},[a,n,f]),[a,d]}function $R(e,t,n){var r=sg(e,t,n),i=r[0],o=r[1];return[Yo(i,n),o]}var ko={itemToString:SR,stateReducer:xR,getA11ySelectionMessage:ER,scrollIntoView:Vv,environment:typeof window>"u"?{}:window};function gn(e,t,n){n===void 0&&(n=og);var r=e["default"+Il(t)];return r!==void 0?r:n[t]}function Po(e,t,n){n===void 0&&(n=og);var r=e[t];if(r!==void 0)return r;var i=e["initial"+Il(t)];return i!==void 0?i:gn(e,t,n)}function PR(e){var t=Po(e,"selectedItem"),n=Po(e,"isOpen"),r=Po(e,"highlightedIndex"),i=Po(e,"inputValue");return{highlightedIndex:r<0&&t&&n?e.items.indexOf(t):r,isOpen:n,selectedItem:t,inputValue:i}}function No(e,t,n){var r=e.items,i=e.initialHighlightedIndex,o=e.defaultHighlightedIndex,s=t.selectedItem,a=t.highlightedIndex;return r.length===0?-1:i!==void 0&&a===i?i:o!==void 0?o:s?r.indexOf(s):n===0?-1:n<0?r.length-1:0}function RR(e,t,n,r){var i=u.useRef({isMouseDown:!1,isTouchMove:!1});return u.useEffect(function(){if((n==null?void 0:n.addEventListener)!=null){var o=function(){i.current.isMouseDown=!0},s=function(f){i.current.isMouseDown=!1,e&&!ts(f.target,t.map(function(h){return h.current}),n)&&r()},a=function(){i.current.isTouchMove=!1},c=function(){i.current.isTouchMove=!0},l=function(f){e&&!i.current.isTouchMove&&!ts(f.target,t.map(function(h){return h.current}),n,!1)&&r()};return n.addEventListener("mousedown",o),n.addEventListener("mouseup",s),n.addEventListener("touchstart",a),n.addEventListener("touchmove",c),n.addEventListener("touchend",l),function(){n.removeEventListener("mousedown",o),n.removeEventListener("mouseup",s),n.removeEventListener("touchstart",a),n.removeEventListener("touchmove",c),n.removeEventListener("touchend",l)}}},[e,n]),i}var Dl=function(){return en};process.env.NODE_ENV!=="production"&&(Dl=function(){for(var t=u.useRef(!0),n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];var o=u.useRef(r.reduce(function(a,c){return a[c]={},a},{}));u.useEffect(function(){Object.keys(o.current).forEach(function(a){var c=o.current[a];if(t.current&&!Object.keys(c).length){console.error("downshift: You forgot to call the "+a+" getter function on your component / element.");return}var l=c.suppressRefError,d=c.refKey,f=c.elementRef;(!f||!f.current)&&!l&&console.error('downshift: The ref prop "'+d+'" from '+a+" was not applied correctly on your element.")}),t.current=!1});var s=u.useCallback(function(a,c,l,d){o.current[a]={suppressRefError:c,refKey:l,elementRef:d}},[]);return s});function bp(e,t,n){var r=n.isInitialMount,i=n.highlightedIndex,o=n.items,s=n.environment,a=zt(n,yR);u.useEffect(function(){r||CR(function(){return e(ie({highlightedIndex:i,highlightedItem:o[i],resultCount:o.length},a))},s.document)},t)}function IR(e){var t=e.highlightedIndex,n=e.isOpen,r=e.itemRefs,i=e.getItemNodeFromIndex,o=e.menuElement,s=e.scrollIntoView,a=u.useRef(!0);return _R(function(){t<0||!n||!Object.keys(r.current).length||(a.current===!1?a.current=!0:s(i(t),o))},[t]),a}var Ol=en;process.env.NODE_ENV!=="production"&&(Ol=function(t){var n=t.isInitialMount,r=t.props,i=t.state,o=u.useRef(r);u.useEffect(function(){n||(Pl(i,o.current,r),o.current=r)},[i,r,n])});function wp(e,t,n){var r;n===void 0&&(n=!0);var i=((r=e.items)==null?void 0:r.length)&&t>=0;return ie({isOpen:!1,highlightedIndex:-1},i&&ie({selectedItem:e.items[t],isOpen:gn(e,"isOpen"),highlightedIndex:gn(e,"highlightedIndex")},n&&{inputValue:e.itemToString(e.items[t])}))}function AR(e,t,n){var r=t.type,i=t.props,o;switch(r){case n.ItemMouseMove:o={highlightedIndex:t.disabled?-1:t.index};break;case n.MenuMouseLeave:o={highlightedIndex:-1};break;case n.ToggleButtonClick:case n.FunctionToggleMenu:o={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:No(i,e,0)};break;case n.FunctionOpenMenu:o={isOpen:!0,highlightedIndex:No(i,e,0)};break;case n.FunctionCloseMenu:o={isOpen:!1};break;case n.FunctionSetHighlightedIndex:o={highlightedIndex:t.highlightedIndex};break;case n.FunctionSetInputValue:o={inputValue:t.inputValue};break;case n.FunctionReset:o={highlightedIndex:gn(i,"highlightedIndex"),isOpen:gn(i,"isOpen"),selectedItem:gn(i,"selectedItem"),inputValue:gn(i,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return ie({},e,o)}z.array.isRequired,z.func,z.func,z.func,z.number,z.number,z.number,z.bool,z.bool,z.bool,z.any,z.any,z.any,z.string,z.string,z.string,z.func,z.string,z.func,z.func,z.func,z.func,z.func,z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})});function DR(e){var t=e.isOpen,n=e.resultCount,r=e.previousResultCount;return t?n?n!==r?"".concat(n," result").concat(n===1?" is":"s are"," available, use up and down arrow keys to navigate. Press Enter or Space Bar keys to select."):"":"No results are available.":""}dn(dn({},ko),{getA11yStatusMessage:DR});process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;var Ml=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_down__":0,kl=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_up__":1,Nl=process.env.NODE_ENV!=="production"?"__input_keydown_escape__":2,jl=process.env.NODE_ENV!=="production"?"__input_keydown_home__":3,Vl=process.env.NODE_ENV!=="production"?"__input_keydown_end__":4,Ll=process.env.NODE_ENV!=="production"?"__input_keydown_page_up__":5,Fl=process.env.NODE_ENV!=="production"?"__input_keydown_page_down__":6,Bl=process.env.NODE_ENV!=="production"?"__input_keydown_enter__":7,Hl=process.env.NODE_ENV!=="production"?"__input_change__":8,ns=process.env.NODE_ENV!=="production"?"__input_blur__":9,Wl=process.env.NODE_ENV!=="production"?"__input_focus__":10,ag=process.env.NODE_ENV!=="production"?"__menu_mouse_leave__":11,cg=process.env.NODE_ENV!=="production"?"__item_mouse_move__":12,Ul=process.env.NODE_ENV!=="production"?"__item_click__":13,lg=process.env.NODE_ENV!=="production"?"__togglebutton_click__":14,ug=process.env.NODE_ENV!=="production"?"__function_toggle_menu__":15,dg=process.env.NODE_ENV!=="production"?"__function_open_menu__":16,fg=process.env.NODE_ENV!=="production"?"__function_close_menu__":17,pg=process.env.NODE_ENV!=="production"?"__function_set_highlighted_index__":18,Yl=process.env.NODE_ENV!=="production"?"__function_select_item__":19,hg=process.env.NODE_ENV!=="production"?"__function_set_input_value__":20,mg=process.env.NODE_ENV!=="production"?"__function_reset__":21,zl=process.env.NODE_ENV!=="production"?"__controlled_prop_updated_selected_item__":22,vg=Object.freeze({__proto__:null,InputKeyDownArrowDown:Ml,InputKeyDownArrowUp:kl,InputKeyDownEscape:Nl,InputKeyDownHome:jl,InputKeyDownEnd:Vl,InputKeyDownPageUp:Ll,InputKeyDownPageDown:Fl,InputKeyDownEnter:Bl,InputChange:Hl,InputBlur:ns,InputFocus:Wl,MenuMouseLeave:ag,ItemMouseMove:cg,ItemClick:Ul,ToggleButtonClick:lg,FunctionToggleMenu:ug,FunctionOpenMenu:dg,FunctionCloseMenu:fg,FunctionSetHighlightedIndex:pg,FunctionSelectItem:Yl,FunctionSetInputValue:hg,FunctionReset:mg,ControlledPropUpdatedSelectedItem:zl});function OR(e){var t=PR(e),n=t.selectedItem,r=t.inputValue;return r===""&&n&&e.defaultInputValue===void 0&&e.initialInputValue===void 0&&e.inputValue===void 0&&(r=e.itemToString(n)),ie({},t,{inputValue:r})}var MR={items:z.array.isRequired,itemToString:z.func,selectedItemChanged:z.func,getA11yStatusMessage:z.func,getA11ySelectionMessage:z.func,highlightedIndex:z.number,defaultHighlightedIndex:z.number,initialHighlightedIndex:z.number,isOpen:z.bool,defaultIsOpen:z.bool,initialIsOpen:z.bool,selectedItem:z.any,initialSelectedItem:z.any,defaultSelectedItem:z.any,inputValue:z.string,defaultInputValue:z.string,initialInputValue:z.string,id:z.string,labelId:z.string,menuId:z.string,getItemId:z.func,inputId:z.string,toggleButtonId:z.string,stateReducer:z.func,onSelectedItemChange:z.func,onHighlightedIndexChange:z.func,onStateChange:z.func,onIsOpenChange:z.func,onInputValueChange:z.func,environment:z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})})};function kR(e,t,n){var r=u.useRef(),i=sg(e,t,n),o=i[0],s=i[1];return u.useEffect(function(){es(n,"selectedItem")&&(n.selectedItemChanged(r.current,n.selectedItem)&&s({type:zl,inputValue:n.itemToString(n.selectedItem)}),r.current=o.selectedItem===r.current?n.selectedItem:o.selectedItem)},[o.selectedItem,n.selectedItem]),[Yo(o,n),s]}var gg=en;process.env.NODE_ENV!=="production"&&(gg=function(t,n){z.checkPropTypes(MR,t,"prop",n.name)});var NR=ie({},ko,{selectedItemChanged:function(t,n){return t!==n},getA11yStatusMessage:Fv});function jR(e,t){var n,r=t.type,i=t.props,o=t.altKey,s;switch(r){case Ul:s={isOpen:gn(i,"isOpen"),highlightedIndex:gn(i,"highlightedIndex"),selectedItem:i.items[t.index],inputValue:i.itemToString(i.items[t.index])};break;case Ml:e.isOpen?s={highlightedIndex:Rr(1,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!0)}:s={highlightedIndex:o&&e.selectedItem==null?-1:No(i,e,1,t.getItemNodeFromIndex),isOpen:i.items.length>=0};break;case kl:e.isOpen?o?s=wp(i,e.highlightedIndex):s={highlightedIndex:Rr(-1,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!0)}:s={highlightedIndex:No(i,e,-1,t.getItemNodeFromIndex),isOpen:i.items.length>=0};break;case Bl:s=wp(i,e.highlightedIndex);break;case Nl:s=ie({isOpen:!1,highlightedIndex:-1},!e.isOpen&&{selectedItem:null,inputValue:""});break;case Ll:s={highlightedIndex:Rr(-10,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!1)};break;case Fl:s={highlightedIndex:Rr(10,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!1)};break;case jl:s={highlightedIndex:Nr(1,0,i.items.length,t.getItemNodeFromIndex,!1)};break;case Vl:s={highlightedIndex:Nr(-1,i.items.length-1,i.items.length,t.getItemNodeFromIndex,!1)};break;case ns:s=ie({isOpen:!1,highlightedIndex:-1},e.highlightedIndex>=0&&((n=i.items)==null?void 0:n.length)&&t.selectItem&&{selectedItem:i.items[e.highlightedIndex],inputValue:i.itemToString(i.items[e.highlightedIndex])});break;case Hl:s={isOpen:!0,highlightedIndex:gn(i,"highlightedIndex"),inputValue:t.inputValue};break;case Wl:s={isOpen:!0,highlightedIndex:No(i,e,0)};break;case Yl:s={selectedItem:t.selectedItem,inputValue:i.itemToString(t.selectedItem)};break;case zl:s={inputValue:t.inputValue};break;default:return AR(e,t,vg)}return ie({},e,s)}var VR=["onMouseLeave","refKey","ref"],LR=["item","index","refKey","ref","onMouseMove","onMouseDown","onClick","onPress","disabled"],FR=["onClick","onPress","refKey","ref"],BR=["onKeyDown","onChange","onInput","onFocus","onBlur","onChangeText","refKey","ref"];Jr.stateChangeTypes=vg;function Jr(e){e===void 0&&(e={}),gg(e,Jr);var t=ie({},NR,e),n=t.initialIsOpen,r=t.defaultIsOpen,i=t.items,o=t.scrollIntoView,s=t.environment,a=t.getA11yStatusMessage,c=t.getA11ySelectionMessage,l=t.itemToString,d=OR(t),f=kR(jR,d,t),h=f[0],p=f[1],w=h.isOpen,E=h.highlightedIndex,T=h.selectedItem,S=h.inputValue,m=u.useRef(null),x=u.useRef({}),_=u.useRef(null),$=u.useRef(null),O=u.useRef(!0),M=TR(t),N=u.useRef(),j=Al({state:h,props:t}),K=u.useCallback(function(B){return x.current[M.getItemId(B)]},[M]);bp(a,[w,E,S,i],ie({isInitialMount:O.current,previousResultCount:N.current,items:i,environment:s,itemToString:l},h)),bp(c,[T],ie({isInitialMount:O.current,previousResultCount:N.current,items:i,environment:s,itemToString:l},h));var V=IR({menuElement:m.current,highlightedIndex:E,isOpen:w,itemRefs:x,scrollIntoView:o,getItemNodeFromIndex:K});Ol({isInitialMount:O.current,props:t,state:h}),u.useEffect(function(){var B=n||r||w;B&&_.current&&_.current.focus()},[]),u.useEffect(function(){O.current||(N.current=i.length)});var P=RR(w,[_,m,$],s,function(){p({type:ns,selectItem:!1})}),v=Dl("getInputProps","getMenuProps");u.useEffect(function(){return O.current=!1,function(){O.current=!0}},[]),u.useEffect(function(){var B;if(!w)x.current={};else if(((B=s.document)==null?void 0:B.activeElement)!==_.current){var H;_==null||(H=_.current)==null||H.focus()}},[w,s]);var C=u.useMemo(function(){return{ArrowDown:function(H){H.preventDefault(),p({type:Ml,altKey:H.altKey,getItemNodeFromIndex:K})},ArrowUp:function(H){H.preventDefault(),p({type:kl,altKey:H.altKey,getItemNodeFromIndex:K})},Home:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:jl,getItemNodeFromIndex:K}))},End:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:Vl,getItemNodeFromIndex:K}))},Escape:function(H){var J=j.current.state;(J.isOpen||J.inputValue||J.selectedItem||J.highlightedIndex>-1)&&(H.preventDefault(),p({type:Nl}))},Enter:function(H){var J=j.current.state;!J.isOpen||H.which===229||(H.preventDefault(),p({type:Bl,getItemNodeFromIndex:K}))},PageUp:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:Ll,getItemNodeFromIndex:K}))},PageDown:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:Fl,getItemNodeFromIndex:K}))}}},[p,j,K]),I=u.useCallback(function(B){return ie({id:M.labelId,htmlFor:M.inputId},B)},[M]),k=u.useCallback(function(B,H){var J,ee=B===void 0?{}:B,te=ee.onMouseLeave,Z=ee.refKey,ge=Z===void 0?"ref":Z,Te=ee.ref,Ie=zt(ee,VR),Ae=H===void 0?{}:H,$e=Ae.suppressRefError,Ye=$e===void 0?!1:$e;return v("getMenuProps",Ye,ge,m),ie((J={},J[ge]=ir(Te,function(je){m.current=je}),J.id=M.menuId,J.role="listbox",J["aria-labelledby"]=Ie&&Ie["aria-label"]?void 0:""+M.labelId,J.onMouseLeave=wt(te,function(){p({type:ag})}),J),Ie)},[p,v,M]),U=u.useCallback(function(B){var H,J,ee=B===void 0?{}:B,te=ee.item,Z=ee.index,ge=ee.refKey,Te=ge===void 0?"ref":ge,Ie=ee.ref,Ae=ee.onMouseMove,$e=ee.onMouseDown,Ye=ee.onClick;ee.onPress;var je=ee.disabled,vt=zt(ee,LR),Xe=j.current,Rt=Xe.props,st=Xe.state,Ft=ig(te,Z,Rt.items,"Pass either item or index to getItemProps!"),Pe=Ft[1],Ot="onClick",gt=Ye,bn=function(){Pe!==st.highlightedIndex&&(V.current=!1,p({type:cg,index:Pe,disabled:je}))},Xt=function(){p({type:Ul,index:Pe})},Nt=function(Mt){return Mt.preventDefault()};return ie((H={},H[Te]=ir(Ie,function(Fe){Fe&&(x.current[M.getItemId(Pe)]=Fe)}),H.disabled=je,H.role="option",H["aria-selected"]=""+(Pe===st.highlightedIndex),H.id=M.getItemId(Pe),H),!je&&(J={},J[Ot]=wt(gt,Xt),J),{onMouseMove:wt(Ae,bn),onMouseDown:wt($e,Nt)},vt)},[p,j,V,M]),G=u.useCallback(function(B){var H,J=B===void 0?{}:B,ee=J.onClick;J.onPress;var te=J.refKey,Z=te===void 0?"ref":te,ge=J.ref,Te=zt(J,FR),Ie=j.current.state,Ae=function(){p({type:lg})};return ie((H={},H[Z]=ir(ge,function($e){$.current=$e}),H["aria-controls"]=M.menuId,H["aria-expanded"]=Ie.isOpen,H.id=M.toggleButtonId,H.tabIndex=-1,H),!Te.disabled&&ie({},{onClick:wt(ee,Ae)}),Te)},[p,j,M]),ue=u.useCallback(function(B,H){var J,ee=B===void 0?{}:B,te=ee.onKeyDown,Z=ee.onChange,ge=ee.onInput,Te=ee.onFocus,Ie=ee.onBlur;ee.onChangeText;var Ae=ee.refKey,$e=Ae===void 0?"ref":Ae,Ye=ee.ref,je=zt(ee,BR),vt=H===void 0?{}:H,Xe=vt.suppressRefError,Rt=Xe===void 0?!1:Xe;v("getInputProps",Rt,$e,_);var st=j.current.state,Ft=function(Mt){var Gt=zo(Mt);Gt&&C[Gt]&&C[Gt](Mt)},Pe=function(Mt){p({type:Hl,inputValue:Mt.target.value})},Ot=function(Mt){if(st.isOpen&&!P.current.isMouseDown){var Gt=Mt.relatedTarget===null&&s.document.activeElement!==s.document.body;p({type:ns,selectItem:!Gt})}},gt=function(){st.isOpen||p({type:Wl})},bn="onChange",Xt={};if(!je.disabled){var Nt;Xt=(Nt={},Nt[bn]=wt(Z,ge,Pe),Nt.onKeyDown=wt(te,Ft),Nt.onBlur=wt(Ie,Ot),Nt.onFocus=wt(Te,gt),Nt)}return ie((J={},J[$e]=ir(Ye,function(Fe){_.current=Fe}),J["aria-activedescendant"]=st.isOpen&&st.highlightedIndex>-1?M.getItemId(st.highlightedIndex):"",J["aria-autocomplete"]="list",J["aria-controls"]=M.menuId,J["aria-expanded"]=st.isOpen,J["aria-labelledby"]=je&&je["aria-label"]?void 0:""+M.labelId,J.autoComplete="off",J.id=M.inputId,J.role="combobox",J.value=st.inputValue,J),Xt,je)},[v,j,M,C,p,P,s]),W=u.useCallback(function(){p({type:ug})},[p]),L=u.useCallback(function(){p({type:fg})},[p]),oe=u.useCallback(function(){p({type:dg})},[p]),X=u.useCallback(function(B){p({type:pg,highlightedIndex:B})},[p]),q=u.useCallback(function(B){p({type:Yl,selectedItem:B})},[p]),ne=u.useCallback(function(B){p({type:hg,inputValue:B})},[p]),ae=u.useCallback(function(){p({type:mg})},[p]);return{getItemProps:U,getLabelProps:I,getMenuProps:k,getInputProps:ue,getToggleButtonProps:G,toggleMenu:W,openMenu:oe,closeMenu:L,setHighlightedIndex:X,setInputValue:ne,selectItem:q,reset:ae,highlightedIndex:E,isOpen:w,selectedItem:T,inputValue:S}}var yg={activeIndex:-1,selectedItems:[]};function xp(e,t){return Po(e,t,yg)}function Ep(e,t){return gn(e,t,yg)}function HR(e){var t=xp(e,"activeIndex"),n=xp(e,"selectedItems");return{activeIndex:t,selectedItems:n}}function Cp(e){if(e.shiftKey||e.metaKey||e.ctrlKey||e.altKey)return!1;var t=e.target;return!(t instanceof HTMLInputElement&&t.value!==""&&(t.selectionStart!==0||t.selectionEnd!==0))}function WR(e){var t=e.removedSelectedItem,n=e.itemToString;return n(t)+" has been removed."}var UR={selectedItems:z.array,initialSelectedItems:z.array,defaultSelectedItems:z.array,itemToString:z.func,getA11yRemovalMessage:z.func,stateReducer:z.func,activeIndex:z.number,initialActiveIndex:z.number,defaultActiveIndex:z.number,onActiveIndexChange:z.func,onSelectedItemsChange:z.func,keyNavigationNext:z.string,keyNavigationPrevious:z.string,environment:z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})})},YR={itemToString:ko.itemToString,stateReducer:ko.stateReducer,environment:ko.environment,getA11yRemovalMessage:WR,keyNavigationNext:"ArrowRight",keyNavigationPrevious:"ArrowLeft"},bg=en;process.env.NODE_ENV!=="production"&&(bg=function(t,n){z.checkPropTypes(UR,t,"prop",n.name)});var Kl=process.env.NODE_ENV!=="production"?"__selected_item_click__":0,ql=process.env.NODE_ENV!=="production"?"__selected_item_keydown_delete__":1,Xl=process.env.NODE_ENV!=="production"?"__selected_item_keydown_backspace__":2,Gl=process.env.NODE_ENV!=="production"?"__selected_item_keydown_navigation_next__":3,Zl=process.env.NODE_ENV!=="production"?"__selected_item_keydown_navigation_previous__":4,Ql=process.env.NODE_ENV!=="production"?"__dropdown_keydown_navigation_previous__":5,Jl=process.env.NODE_ENV!=="production"?"__dropdown_keydown_backspace__":6,eu=process.env.NODE_ENV!=="production"?"__dropdown_click__":7,tu=process.env.NODE_ENV!=="production"?"__function_add_selected_item__":8,nu=process.env.NODE_ENV!=="production"?"__function_remove_selected_item__":9,ru=process.env.NODE_ENV!=="production"?"__function_set_selected_items__":10,ou=process.env.NODE_ENV!=="production"?"__function_set_active_index__":11,iu=process.env.NODE_ENV!=="production"?"__function_reset__":12,zR=Object.freeze({__proto__:null,SelectedItemClick:Kl,SelectedItemKeyDownDelete:ql,SelectedItemKeyDownBackspace:Xl,SelectedItemKeyDownNavigationNext:Gl,SelectedItemKeyDownNavigationPrevious:Zl,DropdownKeyDownNavigationPrevious:Ql,DropdownKeyDownBackspace:Jl,DropdownClick:eu,FunctionAddSelectedItem:tu,FunctionRemoveSelectedItem:nu,FunctionSetSelectedItems:ru,FunctionSetActiveIndex:ou,FunctionReset:iu});function KR(e,t){var n=t.type,r=t.index,i=t.props,o=t.selectedItem,s=e.activeIndex,a=e.selectedItems,c;switch(n){case Kl:c={activeIndex:r};break;case Zl:c={activeIndex:s-1<0?0:s-1};break;case Gl:c={activeIndex:s+1>=a.length?-1:s+1};break;case Xl:case ql:{if(s<0)break;var l=s;a.length===1?l=-1:s===a.length-1&&(l=a.length-2),c=ie({selectedItems:[].concat(a.slice(0,s),a.slice(s+1))},{activeIndex:l});break}case Ql:c={activeIndex:a.length-1};break;case Jl:c={selectedItems:a.slice(0,a.length-1)};break;case tu:c={selectedItems:[].concat(a,[o])};break;case eu:c={activeIndex:-1};break;case nu:{var d=s,f=a.indexOf(o);if(f<0)break;a.length===1?d=-1:f===a.length-1&&(d=a.length-2),c={selectedItems:[].concat(a.slice(0,f),a.slice(f+1)),activeIndex:d};break}case ru:{var h=t.selectedItems;c={selectedItems:h};break}case ou:{var p=t.activeIndex;c={activeIndex:p};break}case iu:c={activeIndex:Ep(i,"activeIndex"),selectedItems:Ep(i,"selectedItems")};break;default:throw new Error("Reducer called without proper action type.")}return ie({},e,c)}var qR=["refKey","ref","onClick","onKeyDown","selectedItem","index"],XR=["refKey","ref","onKeyDown","onClick","preventKeyAction"];su.stateChangeTypes=zR;function su(e){e===void 0&&(e={}),bg(e,su);var t=ie({},YR,e),n=t.getA11yRemovalMessage,r=t.itemToString,i=t.environment,o=t.keyNavigationNext,s=t.keyNavigationPrevious,a=$R(KR,HR(t),t),c=a[0],l=a[1],d=c.activeIndex,f=c.selectedItems,h=u.useRef(!0),p=u.useRef(null),w=u.useRef(f),E=u.useRef();E.current=[];var T=Al({state:c,props:t});u.useEffect(function(){if(!h.current){if(f.length<w.current.length){var V=w.current.find(function(P){return f.indexOf(P)<0});Rl(n({itemToString:r,resultCount:f.length,removedSelectedItem:V,activeIndex:d,activeSelectedItem:f[d]}),i.document)}w.current=f}},[f.length]),u.useEffect(function(){h.current||(d===-1&&p.current?p.current.focus():E.current[d]&&E.current[d].focus())},[d]),Ol({isInitialMount:h.current,props:t,state:c});var S=Dl("getDropdownProps");u.useEffect(function(){return h.current=!1,function(){h.current=!0}},[]);var m=u.useMemo(function(){var V;return V={},V[s]=function(){l({type:Zl})},V[o]=function(){l({type:Gl})},V.Delete=function(){l({type:ql})},V.Backspace=function(){l({type:Xl})},V},[l,o,s]),x=u.useMemo(function(){var V;return V={},V[s]=function(P){Cp(P)&&l({type:Ql})},V.Backspace=function(v){Cp(v)&&l({type:Jl})},V},[l,s]),_=u.useCallback(function(V){var P,v=V===void 0?{}:V,C=v.refKey,I=C===void 0?"ref":C,k=v.ref,U=v.onClick,G=v.onKeyDown,ue=v.selectedItem,W=v.index,L=zt(v,qR),oe=T.current.state,X=ig(ue,W,oe.selectedItems,"Pass either item or index to getSelectedItemProps!"),q=X[1],ne=q>-1&&q===oe.activeIndex,ae=function(){l({type:Kl,index:q})},B=function(J){var ee=zo(J);ee&&m[ee]&&m[ee](J)};return ie((P={},P[I]=ir(k,function(H){H&&E.current.push(H)}),P.tabIndex=ne?0:-1,P.onClick=wt(U,ae),P.onKeyDown=wt(G,B),P),L)},[l,T,m]),$=u.useCallback(function(V,P){var v,C=V===void 0?{}:V,I=C.refKey,k=I===void 0?"ref":I,U=C.ref,G=C.onKeyDown,ue=C.onClick,W=C.preventKeyAction,L=W===void 0?!1:W,oe=zt(C,XR),X=P===void 0?{}:P,q=X.suppressRefError,ne=q===void 0?!1:q;S("getDropdownProps",ne,k,p);var ae=function(J){var ee=zo(J);ee&&x[ee]&&x[ee](J)},B=function(){l({type:eu})};return ie((v={},v[k]=ir(U,function(H){H&&(p.current=H)}),v),!L&&{onKeyDown:wt(G,ae),onClick:wt(ue,B)},oe)},[l,x,S]),O=u.useCallback(function(V){l({type:tu,selectedItem:V})},[l]),M=u.useCallback(function(V){l({type:nu,selectedItem:V})},[l]),N=u.useCallback(function(V){l({type:ru,selectedItems:V})},[l]),j=u.useCallback(function(V){l({type:ou,activeIndex:V})},[l]),K=u.useCallback(function(){l({type:iu})},[l]);return{getSelectedItemProps:_,getDropdownProps:$,addSelectedItem:O,removeSelectedItem:M,setSelectedItems:N,setActiveIndex:j,reset:K,selectedItems:f,activeIndex:d}}var GR="jbnkvn0",_p=ft({defaultClassName:"jbnkvn7",variantClassNames:{highlighted:{true:"jbnkvn8"},selected:{true:"jbnkvn9"},multiSelected:{true:"jbnkvna"},isDisabled:{true:"jbnkvnb"}},defaultVariants:{},compoundVariants:[]}),Tp="jbnkvn6",ZR="jbnkvn1",QR=ft({defaultClassName:"jbnkvn2",variantClassNames:{isMobile:{true:"jbnkvn3",false:"jbnkvn4"}},defaultVariants:{isMobile:!0},compoundVariants:[]}),JR="jbnkvn5",Sp="jbnkvnc";const wg=u.createContext(void 0),eI=({children:e,contextValue:t})=>D.jsx(wg.Provider,{value:t,children:e}),au=()=>{const e=u.useContext(wg);if(e===void 0)throw new Error("useSelectProvider must be used within a SelectProvider");return e},xg=({children:e,renderer:t})=>{const{getMenuProps:n}=au();return t?t({children:e,defaultClassName:Tp,innerProps:n()}):D.jsx("div",{className:Tp,...n(),children:e})};xg.defaultProps={renderer:void 0};const Eg=({renderer:e,item:t,itemIndex:n})=>{const{isMulti:r,selectedItem:i,multipleSelectedItems:o,highlightedIndex:s,getItemProps:a,onClickItem:c}=au(),l=s===n,d=i===t&&!r,f=r&&o.includes(t)||!1,h=a({item:t,index:n,disabled:t.isDisabled,onClick:c});return e?e({defaultClassName:_p({highlighted:s===n,selected:i===t&&!r,multiSelected:o.includes(t),isDisabled:t.isDisabled}),innerProps:h,isMulti:r,item:t,itemIndex:n,isHighlighted:l,isSelected:d,isChecked:f}):D.jsxs("div",{className:_p({highlighted:l,selected:d,multiSelected:f,isDisabled:t.isDisabled}),...h,children:[D.jsx("span",{children:t.label}),r&&o.includes(t)&&D.jsx(_c,{size:16,color:Et.theme.colors.greenAccent1,"data-test-id":""})]},t.value)};Eg.defaultProps={renderer:void 0};const Cg=({renderer:e,...t})=>{const{formState:n,isOpen:r,getToggleButtonProps:i,isDisabled:o}=au();if(e)return e({innerProps:i(),defaultClassName:Sp,isOpen:r});const s=n==="disabled"?Et.theme.colors.black:Et.theme.colors.grey1;return D.jsx("div",{className:Sp,...i({disabled:o}),"data-disabled":o,children:r?D.jsx(Tc,{color:s,...t}):D.jsx(Lo,{color:s,...t})})};Cg.defaultProps={renderer:void 0,"data-test-id":"CT_Component_IconChev"};const to=u.forwardRef(({options:e,value:t,label:n,onChange:r,isLoading:i,components:o,required:s,containerStyles:a,isMulti:c,isReadOnly:l,isMobile:d,onClickItem:f,...h},p)=>{const{addonLeft:w,addonRight:E,helperTextLeft:T,helperTextRight:S,isError:m,errorMessage:x,isDisabled:_,isValid:$}=h,[O,M]=u.useState(e),N=kc({isError:m,isDisabled:_,isValid:$}),j=u.useRef(null),{removeSelectedItem:K,selectedItems:V,addSelectedItem:P,getDropdownProps:v}=su({initialSelectedItems:c&&t?t:[],onSelectedItemsChange(B){c&&r(B.selectedItems)}}),C=u.useMemo(()=>V.length,[V]),I=u.useCallback(B=>{let H=B;(c&&!d||l)&&(H="");const J=new RegExp(H.toLowerCase());return e.filter(ee=>J.test(ee.label.toLowerCase()))},[e]),{isOpen:k,getToggleButtonProps:U,getLabelProps:G,getMenuProps:ue,getInputProps:W,highlightedIndex:L,getItemProps:oe,selectedItem:X,openMenu:q,closeMenu:ne}=Jr({items:O,initialSelectedItem:c?void 0:t,onInputValueChange:({inputValue:B})=>{M(I(B||""))},itemToString(B){return B?B.label:""},onSelectedItemChange(B){var H;c||(r(B.selectedItem),l&&((H=j.current)==null||H.blur()),ne())},stateReducer:(B,H)=>{const{changes:J,type:ee}=H,te=O.find((Z,ge)=>ge===B.highlightedIndex);switch(ee){case Jr.stateChangeTypes.InputKeyDownEnter:case Jr.stateChangeTypes.ItemClick:if(c){let Z=C;return V.includes(te)?(Z-=1,K(te)):(Z+=1,P(te)),{...J,isOpen:!0,highlightedIndex:B.highlightedIndex,inputValue:!d&&Z>0?`${Z} items selected`:""}}return{...J,isOpen:!1,highlightedIndex:B.highlightedIndex,inputValue:J.inputValue};case Jr.stateChangeTypes.InputBlur:{let Z=J.inputValue;return c&&!d&&(C>0?Z=`${C} items selected`:Z=""),{...J,inputValue:Z}}default:return J}}});u.useImperativeHandle(p,()=>j.current);const ae={isOpen:k,formState:N,selectedItem:X,multipleSelectedItems:V,isMulti:c,isDisabled:_,totalSelected:C,highlightedIndex:L,getMenuProps:ue,getItemProps:oe,getToggleButtonProps:U,onClickItem:f};return D.jsx(eI,{contextValue:ae,children:D.jsxs(ht,{position:"relative",w:"$full",children:[D.jsxs(po,{addonLeft:w,addonRight:E,helperTextLeft:T,helperTextRight:S,isError:m,errorMessage:x,isDisabled:_,isValid:$,inputAreaClassName:GR,children:[D.jsxs("div",{className:ZR,children:[D.jsx("input",{"data-test-id":h["data-test-id"],...W(v({preventKeyAction:k,ref:j,placeholder:n,readOnly:l,disabled:_,className:QR({isMobile:d}),onClick:()=>{k||q()}}))}),d&&c&&D.jsx("div",{className:JR,children:C>0?`${C} items selected`:""}),d&&D.jsx(ni,{isSelect:!0,isError:m,isDisabled:_,required:s,...G(),children:n})]}),D.jsx(Cg,{renderer:o==null?void 0:o.Toggle})]}),k&&D.jsx(xg,{renderer:o==null?void 0:o.List,children:O.map((B,H)=>D.jsx(Eg,{renderer:o==null?void 0:o.ListItem,itemIndex:H,item:B}))})]})})});to.displayName="Select";to.defaultProps={required:!1,isLoading:!1,isMulti:void 0,isReadOnly:!1,isMobile:!1,containerStyles:void 0,components:void 0,onClickItem:void 0,"data-test-id":void 0};const _g=e=>{const t=`0${e}`;return t.substring(t.length-2,t.length)},tI=Array.from({length:31},(e,t)=>({label:_g(t+1),value:String(t+1),isDisabled:!1})),rs=["January","February","March","April","May","June","July","August","September","October","November","December"],nI=rs.map(e=>({label:e,value:e,isDisabled:!1})),rI=e=>{const t=e?new Date(e).getFullYear():new Date().getFullYear();return Array.from({length:101},(n,r)=>({label:String(t-r),value:String(t-r),isDisabled:!1}))},$a=(e,t)=>{if(t){const n=new Date(t);if(e==="date")return{label:_g(n.getDate()),value:n.getDate().toString()};if(e==="month")return{label:rs[n.getMonth()],value:rs[n.getMonth()]};if(e==="year"){const r=n.getFullYear().toString();return{label:r,value:r}}}},jo=e=>rs.findIndex(t=>t===e),$p=(e,t)=>new Date(e,jo(t)+1,0).getDate(),oI=({date:e,month:t,year:n,maxDate:r})=>{const i=r?new Date(r):new Date;return i.setHours(0,0,0,0),e&&t&&n&&e<=$p(n,t)&&i>new Date(n,jo(t),e,0,0,0,0)?!0:e&&t&&!n?jo(t)===1?e<=29:e<=$p(0,t):!e&&t&&n?n===i.getFullYear()?jo(t)<=i.getMonth():!0:e&&!t&&n?i.getMonth()===0&&n===i.getFullYear()?e<i.getDate():!0:!1},Tg=({title:e,maxDate:t,isMobile:n,defaultDate:r,onSaveDate:i,onClose:o,isOpen:s,buttonText:a,errorMessage:c,...l})=>{const[d,f]=u.useState(),[h,p]=u.useState(),[w,E]=u.useState(),T=u.useRef(null),S=()=>{f(void 0),p(void 0),E(void 0)},m=u.useMemo(()=>{if(s){if(d)return d;if(r)return $a("date",r)}},[r,d,s]),x=u.useMemo(()=>{if(s){if(h)return h;if(r)return $a("month",r)}},[r,h,s]),_=u.useMemo(()=>{if(s){if(w)return w;if(r)return $a("year",r)}},[r,w,s]),$=u.useMemo(()=>m||x||_?oI({date:m?Number(m==null?void 0:m.value):0,month:x?x.value:"",year:_?Number(_.value):0,maxDate:t}):!1,[m,x,_,t]),O=m&&x&&!_&&!$,M=m&&!x&&_&&!$,N=!m&&x&&_&&!$,j=m&&x&&_&&!$,K=()=>D.jsx(ht,{as:"button",ref:T,"data-test-id":"",position:"absolute",width:"$1",height:"$1",bottom:"$0",right:"$0",backgroundColor:"$white",border:"$none",children:D.jsx(ht,{display:"none"})}),V=()=>{T.current&&T.current.focus()};return D.jsx(ei,{...l,isOpen:s,onClose:()=>{o==null||o(),S()},children:D.jsxs(Ir,{gap:"$24",children:[D.jsxs(Ir,{gap:"$8",children:[D.jsx(ht,{height:"$40",children:D.jsx(ti,{children:e})}),D.jsxs(Ir,{children:[D.jsxs(Lt,{gap:"$12",px:"$2",mb:"$4",mt:"$8",children:[D.jsx(to,{isReadOnly:!0,name:"date",label:"Date",value:m,isMobile:n,options:tI,onClickItem:V,onChange:f,isError:O||M||j,"data-test-id":"CT_Component_SelectPicker_dateField"}),D.jsx(to,{isReadOnly:!0,name:"month",label:"Month",value:x,isMobile:n,options:nI,onClickItem:V,onChange:p,isError:N||O||j,"data-test-id":"CT_Component_SelectPicker_monthField"}),D.jsx(to,{isReadOnly:!0,name:"year",label:"Year",value:_,isMobile:n,options:rI(t),onClickItem:V,onChange:E,isError:N||M||j,"data-test-id":"CT_Component_SelectPicker_yearField"})]}),(j||N||M||O)&&D.jsx(Kt,{px:"$2",color:"$redAccent1",fontSize:"$caption",lineHeight:"$16",fontWeight:"$medium",children:c})]})]}),K(),D.jsx(co,{onClick:()=>{i(new Date(Number(_==null?void 0:_.value),jo(x==null?void 0:x.value),Number(m==null?void 0:m.value))),S()},isDisabled:!_||!x||!m||!$,"data-test-id":"CT_Component_SelectPicker_buttonSave",type:"button",children:a})]})})};Tg.defaultProps={title:"Date of birth",isMobile:!1,defaultDate:void 0,maxDate:void 0,buttonText:"Confirm",errorMessage:"Invalid date of birth"};const Pa="rovingFocusGroup.onEntryFocus",iI={bubbles:!1,cancelable:!0},cu="RovingFocusGroup",[fc,Sg,sI]=os(cu),[aI,$g]=sn(cu,[sI]),[cI,lI]=aI(cu),uI=u.forwardRef((e,t)=>u.createElement(fc.Provider,{scope:e.__scopeRovingFocusGroup},u.createElement(fc.Slot,{scope:e.__scopeRovingFocusGroup},u.createElement(dI,ie({},e,{ref:t}))))),dI=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:o,currentTabStopId:s,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:c,onEntryFocus:l,...d}=e,f=u.useRef(null),h=Qe(t,f),p=is(o),[w=null,E]=pn({prop:s,defaultProp:a,onChange:c}),[T,S]=u.useState(!1),m=qt(l),x=Sg(n),_=u.useRef(!1),[$,O]=u.useState(0);return u.useEffect(()=>{const M=f.current;if(M)return M.addEventListener(Pa,m),()=>M.removeEventListener(Pa,m)},[m]),u.createElement(cI,{scope:n,orientation:r,dir:p,loop:i,currentTabStopId:w,onItemFocus:u.useCallback(M=>E(M),[E]),onItemShiftTab:u.useCallback(()=>S(!0),[]),onFocusableItemAdd:u.useCallback(()=>O(M=>M+1),[]),onFocusableItemRemove:u.useCallback(()=>O(M=>M-1),[])},u.createElement(He.div,ie({tabIndex:T||$===0?-1:0,"data-orientation":r},d,{ref:h,style:{outline:"none",...e.style},onMouseDown:De(e.onMouseDown,()=>{_.current=!0}),onFocus:De(e.onFocus,M=>{const N=!_.current;if(M.target===M.currentTarget&&N&&!T){const j=new CustomEvent(Pa,iI);if(M.currentTarget.dispatchEvent(j),!j.defaultPrevented){const K=x().filter(I=>I.focusable),V=K.find(I=>I.active),P=K.find(I=>I.id===w),C=[V,P,...K].filter(Boolean).map(I=>I.ref.current);Pg(C)}}_.current=!1}),onBlur:De(e.onBlur,()=>S(!1))})))}),fI="RovingFocusGroupItem",pI=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:o,...s}=e,a=Bn(),c=o||a,l=lI(fI,n),d=l.currentTabStopId===c,f=Sg(n),{onFocusableItemAdd:h,onFocusableItemRemove:p}=l;return u.useEffect(()=>{if(r)return h(),()=>p()},[r,h,p]),u.createElement(fc.ItemSlot,{scope:n,id:c,focusable:r,active:i},u.createElement(He.span,ie({tabIndex:d?0:-1,"data-orientation":l.orientation},s,{ref:t,onMouseDown:De(e.onMouseDown,w=>{r?l.onItemFocus(c):w.preventDefault()}),onFocus:De(e.onFocus,()=>l.onItemFocus(c)),onKeyDown:De(e.onKeyDown,w=>{if(w.key==="Tab"&&w.shiftKey){l.onItemShiftTab();return}if(w.target!==w.currentTarget)return;const E=vI(w,l.orientation,l.dir);if(E!==void 0){w.preventDefault();let S=f().filter(m=>m.focusable).map(m=>m.ref.current);if(E==="last")S.reverse();else if(E==="prev"||E==="next"){E==="prev"&&S.reverse();const m=S.indexOf(w.currentTarget);S=l.loop?gI(S,m+1):S.slice(m+1)}setTimeout(()=>Pg(S))}})})))}),hI={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function mI(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function vI(e,t,n){const r=mI(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return hI[r]}function Pg(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function gI(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const yI=uI,bI=pI,Rg="Radio",[wI,Ig]=sn(Rg),[xI,EI]=wI(Rg),CI=u.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:i=!1,required:o,disabled:s,value:a="on",onCheck:c,...l}=e,[d,f]=u.useState(null),h=Qe(t,E=>f(E)),p=u.useRef(!1),w=d?!!d.closest("form"):!0;return u.createElement(xI,{scope:n,checked:i,disabled:s},u.createElement(He.button,ie({type:"button",role:"radio","aria-checked":i,"data-state":Ag(i),"data-disabled":s?"":void 0,disabled:s,value:a},l,{ref:h,onClick:De(e.onClick,E=>{i||c==null||c(),w&&(p.current=E.isPropagationStopped(),p.current||E.stopPropagation())})})),w&&u.createElement(SI,{control:d,bubbles:!p.current,name:r,value:a,checked:i,required:o,disabled:s,style:{transform:"translateX(-100%)"}}))}),_I="RadioIndicator",TI=u.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...i}=e,o=EI(_I,n);return u.createElement(hr,{present:r||o.checked},u.createElement(He.span,ie({"data-state":Ag(o.checked),"data-disabled":o.disabled?"":void 0},i,{ref:t})))}),SI=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,o=u.useRef(null),s=ms(n),a=ps(t);return u.useEffect(()=>{const c=o.current,l=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(l,"checked").set;if(s!==n&&f){const h=new Event("click",{bubbles:r});f.call(c,n),c.dispatchEvent(h)}},[s,n,r]),u.createElement("input",ie({type:"radio","aria-hidden":!0,defaultChecked:n},i,{tabIndex:-1,ref:o,style:{...e.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ag(e){return e?"checked":"unchecked"}const $I=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Dg="RadioGroup",[PI,CD]=sn(Dg,[$g,Ig]),Og=$g(),Mg=Ig(),[RI,II]=PI(Dg),AI=u.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:i,value:o,required:s=!1,disabled:a=!1,orientation:c,dir:l,loop:d=!0,onValueChange:f,...h}=e,p=Og(n),w=is(l),[E,T]=pn({prop:o,defaultProp:i,onChange:f});return u.createElement(RI,{scope:n,name:r,required:s,disabled:a,value:E,onValueChange:T},u.createElement(yI,ie({asChild:!0},p,{orientation:c,dir:w,loop:d}),u.createElement(He.div,ie({role:"radiogroup","aria-required":s,"aria-orientation":c,"data-disabled":a?"":void 0,dir:w},h,{ref:t}))))}),DI="RadioGroupItem",OI=u.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...i}=e,o=II(DI,n),s=o.disabled||r,a=Og(n),c=Mg(n),l=u.useRef(null),d=Qe(t,l),f=o.value===i.value,h=u.useRef(!1);return u.useEffect(()=>{const p=E=>{$I.includes(E.key)&&(h.current=!0)},w=()=>h.current=!1;return document.addEventListener("keydown",p),document.addEventListener("keyup",w),()=>{document.removeEventListener("keydown",p),document.removeEventListener("keyup",w)}},[]),u.createElement(bI,ie({asChild:!0},a,{focusable:!s,active:f}),u.createElement(CI,ie({disabled:s,required:o.required,checked:f},c,i,{name:o.name,ref:d,onCheck:()=>o.onValueChange(i.value),onKeyDown:De(p=>{p.key==="Enter"&&p.preventDefault()}),onFocus:De(i.onFocus,()=>{var p;h.current&&((p=l.current)===null||p===void 0||p.click())})})))}),MI=u.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,i=Mg(n);return u.createElement(TI,ie({},i,r,{ref:t}))}),kI=AI,NI=OI,jI=MI;var VI=ft({defaultClassName:"d6umgr4",variantClassNames:{disabled:{true:"d6umgr5"}},defaultVariants:{},compoundVariants:[]}),LI="d6umgr1",FI=ft({defaultClassName:"d6umgr2",variantClassNames:{disabled:{true:"d6umgr3"}},defaultVariants:{},compoundVariants:[]}),BI="d6umgr0";const kg=({children:e,className:t,disabled:n,...r})=>{const i=u.useId();return D.jsxs(Lt,{alignItems:"center",children:[D.jsx(NI,{...r,disabled:n,className:Re(t,BI),id:i,children:D.jsx(jI,{className:Re("radio-indicator",FI({disabled:n}))})}),e&&D.jsx("label",{className:Re("radio-label",VI({disabled:n})),htmlFor:i,children:e})]})};kg.defaultProps={children:void 0};const HI=({className:e,children:t,...n})=>D.jsx(kI,{...n,className:Re(e,LI),children:t});var WI="_846x3h0",UI="_846x3h1",YI=ft({defaultClassName:"_846x3h2",variantClassNames:{size:{small:"_846x3h3",medium:"_846x3h4",large:"_846x3h5"},isHasIcon:{true:"_846x3h6"},isDisabled:{true:"_846x3h7"}},defaultVariants:{size:"small"},compoundVariants:[]});const lu=u.forwardRef(({value:e,onClear:t,size:n,isDisabled:r,icon:i,...o},s)=>{const[a,c]=u.useState(!1),l=()=>c(!0),d=()=>c(!1),f=u.useMemo(()=>!!(i||e&&a),[a,e,i]);return D.jsxs(ht,{position:"relative",children:[D.jsx(ht,{className:Re(WI),children:D.jsx(rb,{size:24})}),D.jsx("input",{className:Re(YI({size:n,isHasIcon:f,isDisabled:r})),ref:s,value:e,"data-test-id":o["data-test-id"],onFocus:l,onBlur:d,disabled:r,...o}),f&&D.jsx(ht,{className:Re(UI),children:i&&(!a||a&&!e)?i:D.jsx(ls,{"data-test-id":"icon-close-search",onMouseDown:t,cursor:"pointer",size:24})})]})});lu.displayName="Search";lu.defaultProps={icon:void 0,isDisabled:void 0,onClear:void 0,"data-test-id":void 0};const Ng="Switch",[zI,_D]=sn(Ng),[KI,qI]=zI(Ng),XI=u.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:o,required:s,disabled:a,value:c="on",onCheckedChange:l,...d}=e,[f,h]=u.useState(null),p=Qe(t,m=>h(m)),w=u.useRef(!1),E=f?!!f.closest("form"):!0,[T=!1,S]=pn({prop:i,defaultProp:o,onChange:l});return u.createElement(KI,{scope:n,checked:T,disabled:a},u.createElement(He.button,ie({type:"button",role:"switch","aria-checked":T,"aria-required":s,"data-state":jg(T),"data-disabled":a?"":void 0,disabled:a,value:c},d,{ref:p,onClick:De(e.onClick,m=>{S(x=>!x),E&&(w.current=m.isPropagationStopped(),w.current||m.stopPropagation())})})),E&&u.createElement(QI,{control:f,bubbles:!w.current,name:r,value:c,checked:T,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))}),GI="SwitchThumb",ZI=u.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,i=qI(GI,n);return u.createElement(He.span,ie({"data-state":jg(i.checked),"data-disabled":i.disabled?"":void 0},r,{ref:t}))}),QI=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,o=u.useRef(null),s=ms(n),a=ps(t);return u.useEffect(()=>{const c=o.current,l=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(l,"checked").set;if(s!==n&&f){const h=new Event("click",{bubbles:r});f.call(c,n),c.dispatchEvent(h)}},[s,n,r]),u.createElement("input",ie({type:"checkbox","aria-hidden":!0,defaultChecked:n},i,{tabIndex:-1,ref:o,style:{...e.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function jg(e){return e?"checked":"unchecked"}const JI=XI,eA=ZI;var tA="b7c0j12",nA="b7c0j10",rA="b7c0j11";const Vg=u.forwardRef((e,t)=>D.jsx(JI,{ref:t,className:nA,...e,children:D.jsx(eA,{className:rA,children:D.jsx(_c,{className:tA,size:16})})}));Vg.displayName="Switch";const Lg=({accessor:e,sortColumn:t,sortable:n,"data-test-id":r})=>{const i=t.by===e,o=t.order==="DESC",s=t.order==="ASC";return n?D.jsxs(Lt,{flexDirection:"column","data-test-id":r,children:[D.jsx(Tc,{size:10,color:i&&o?"white":"grey"}),D.jsx(Lo,{size:10,color:i&&s?"white":"grey"})]}):null};Lg.defaultProps={sortable:!1,"data-test-id":""};var oA="_94c6vs1",iA="_94c6vs3",Pp="_94c6vs2",sA="_94c6vs0";const Fg=({data:e,columns:t})=>{const[n,r]=u.useState([]),[i,o]=u.useState([]),[s,a]=u.useState({by:"",order:""}),c=f=>{const{accessor:h}=f,p=f.sortable,w=s.by===h;return p?w&&s.order==="ASC"?a({by:h,order:"DESC"}):w&&s.order==="DESC"?a({by:"",order:""}):a({by:h,order:"ASC"}):null},l=f=>typeof f=="object"?"":f,d=u.useCallback((f,h)=>{const p=[...f];return h.order==="ASC"?p.sort((E,T)=>String(T[h.by]).localeCompare(String(E[h.by]))):h.order==="DESC"?p.sort((E,T)=>String(E[h.by]).localeCompare(String(T[h.by]))):[...f]},[]);return u.useEffect(()=>{const f=t.map(w=>({...w,sortable:w.sortable??!1}));r(f);const p=d(e,{by:s.by,order:s.order}).map(w=>f.map(E=>({accessor:E.accessor,sortable:E.sortable??!1,value:l(w[E.accessor]),...E.cellRenderer&&{CellRenderer:E.cellRenderer({origin:w,value:w[E.accessor]})}})));o(p)},[t,e,d,s.by,s.order]),{headers:n,rows:i,handleHeaderClick:c,sortColumn:s}},Bg=u.forwardRef(({columns:e,as:t,"data-test-id":n,data:r,onSort:i,...o},s)=>{const a=t||"table",{rows:c,headers:l,handleHeaderClick:d,sortColumn:f}=Fg({data:r,columns:e});return u.useEffect(()=>{i&&i(f)},[i,f]),D.jsxs(a,{ref:s,as:t,className:sA,"data-test-id":n,...o,children:[D.jsx("thead",{children:D.jsx("tr",{className:iA,children:l.map(h=>D.jsx("th",{"data-test-id":"xmAUFfaxnRueeT_zBiyhc",className:Pp,onClick:()=>d(h),children:D.jsxs(Lt,{alignItems:"center",gap:"$8",justifyContent:"center",px:"$16",children:[D.jsx(ht,{fontWeight:"$bold",color:"$whiteTypoHigh",fontSize:"$body2",lineHeight:"$20",children:h.label}),D.jsx(Lg,{accessor:h.accessor,sortable:h.sortable,sortColumn:f,"data-test-id":`table-sort-${h.label}`})]})},h.accessor))})}),D.jsx("tbody",{children:c.map((h,p)=>D.jsx("tr",{className:oA,children:h.map((w,E)=>D.jsx(ht,{as:"td","data-test-id":`table-${n}-row${p}-col${E}`,className:Pp,w:"33%",children:w.CellRenderer??w.value}))}))})]})});Bg.defaultProps={as:"table","data-test-id":"base",onSort:void 0};var aA=ft({defaultClassName:"_5wiwut0",variantClassNames:{isActive:{true:"_5wiwut1"}},defaultVariants:{isActive:!1},compoundVariants:[]});var cA=ft({defaultClassName:"_1p5zdvr0",variantClassNames:{withShadow:{true:"_1p5zdvr1"},align:{left:"_1p5zdvr2",center:"_1p5zdvr3",right:"_1p5zdvr4"}},defaultVariants:{withShadow:!1,align:"left"},compoundVariants:[]});const uu=u.createContext({index:0,setIndex:()=>null}),du=u.forwardRef(({as:e,children:t,withShadow:n,index:r,defaultIndex:i,align:o,onChange:s,...a},c)=>{const[l,d]=u.useState(i??0),f=u.useMemo(()=>u.Children.map(t,(w,E)=>u.cloneElement(w,{"data-index":E})),[t]);u.useEffect(()=>d(r??0),[r]);const h=u.useMemo(()=>({index:l,setIndex:E=>{d(E),s==null||s(E)}}),[l,s]),p=e||"ul";return D.jsx(p,{"data-test-id":a["data-test-id"],as:e,ref:c,className:Re(cA({withShadow:n,align:o})),...a,children:D.jsx(uu.Provider,{value:h,children:f})})});du.displayName="Tabs";du.defaultProps={as:"ul",defaultIndex:0,index:0,align:"left",withShadow:!1,children:void 0,onChange:()=>null,"data-test-id":void 0};const fu=u.forwardRef(({as:e,children:t,...n},r)=>{const{index:i,setIndex:o}=u.useContext(uu),s=u.useCallback(l=>{o==null||o(l)},[o]),a=n["data-index"]===i,c=e||"li";return D.jsx(c,{"data-test-id":n["data-test-id"],as:e,ref:r,onClick:()=>s(n["data-index"]||0),className:Re(aA({isActive:a})),...n,children:D.jsx(Kt,{as:"span",textStyle:"body2",children:t})})});fu.displayName="TabItem";fu.defaultProps={as:"li","data-index":void 0,"data-test-id":void 0};const Hg="ToastProvider",[pu,lA,uA]=os("Toast"),[Wg,TD]=sn("Toast",[uA]),[dA,Vs]=Wg(Hg),Ug=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:i="right",swipeThreshold:o=50,children:s}=e,[a,c]=u.useState(null),[l,d]=u.useState(0),f=u.useRef(!1),h=u.useRef(!1);return u.createElement(pu.Provider,{scope:t},u.createElement(dA,{scope:t,label:n,duration:r,swipeDirection:i,swipeThreshold:o,toastCount:l,viewport:a,onViewportChange:c,onToastAdd:u.useCallback(()=>d(p=>p+1),[]),onToastRemove:u.useCallback(()=>d(p=>p-1),[]),isFocusedToastEscapeKeyDownRef:f,isClosePausedRef:h},s))};Ug.propTypes={label(e){if(e.label&&typeof e.label=="string"&&!e.label.trim()){const t=`Invalid prop \`label\` supplied to \`${Hg}\`. Expected non-empty \`string\`.`;return new Error(t)}return null}};const fA="ToastViewport",pA=["F8"],pc="toast.viewportPause",hc="toast.viewportResume",hA=u.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=pA,label:i="Notifications ({hotkey})",...o}=e,s=Vs(fA,n),a=lA(n),c=u.useRef(null),l=u.useRef(null),d=u.useRef(null),f=u.useRef(null),h=Qe(t,f,s.onViewportChange),p=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),w=s.toastCount>0;u.useEffect(()=>{const T=S=>{var m;r.every(_=>S[_]||S.code===_)&&((m=f.current)===null||m===void 0||m.focus())};return document.addEventListener("keydown",T),()=>document.removeEventListener("keydown",T)},[r]),u.useEffect(()=>{const T=c.current,S=f.current;if(w&&T&&S){const m=()=>{if(!s.isClosePausedRef.current){const O=new CustomEvent(pc);S.dispatchEvent(O),s.isClosePausedRef.current=!0}},x=()=>{if(s.isClosePausedRef.current){const O=new CustomEvent(hc);S.dispatchEvent(O),s.isClosePausedRef.current=!1}},_=O=>{!T.contains(O.relatedTarget)&&x()},$=()=>{T.contains(document.activeElement)||x()};return T.addEventListener("focusin",m),T.addEventListener("focusout",_),T.addEventListener("pointermove",m),T.addEventListener("pointerleave",$),window.addEventListener("blur",m),window.addEventListener("focus",x),()=>{T.removeEventListener("focusin",m),T.removeEventListener("focusout",_),T.removeEventListener("pointermove",m),T.removeEventListener("pointerleave",$),window.removeEventListener("blur",m),window.removeEventListener("focus",x)}}},[w,s.isClosePausedRef]);const E=u.useCallback(({tabbingDirection:T})=>{const m=a().map(x=>{const _=x.ref.current,$=[_,...RA(_)];return T==="forwards"?$:$.reverse()});return(T==="forwards"?m.reverse():m).flat()},[a]);return u.useEffect(()=>{const T=f.current;if(T){const S=m=>{const x=m.altKey||m.ctrlKey||m.metaKey;if(m.key==="Tab"&&!x){const N=document.activeElement,j=m.shiftKey;if(m.target===T&&j){var $;($=l.current)===null||$===void 0||$.focus();return}const P=E({tabbingDirection:j?"backwards":"forwards"}),v=P.findIndex(C=>C===N);if(Ra(P.slice(v+1)))m.preventDefault();else{var O,M;j?(O=l.current)===null||O===void 0||O.focus():(M=d.current)===null||M===void 0||M.focus()}}};return T.addEventListener("keydown",S),()=>T.removeEventListener("keydown",S)}},[a,E]),u.createElement(Tb,{ref:c,role:"region","aria-label":i.replace("{hotkey}",p),tabIndex:-1,style:{pointerEvents:w?void 0:"none"}},w&&u.createElement(Rp,{ref:l,onFocusFromOutsideViewport:()=>{const T=E({tabbingDirection:"forwards"});Ra(T)}}),u.createElement(pu.Slot,{scope:n},u.createElement(He.ol,ie({tabIndex:-1},o,{ref:h}))),w&&u.createElement(Rp,{ref:d,onFocusFromOutsideViewport:()=>{const T=E({tabbingDirection:"backwards"});Ra(T)}}))}),mA="ToastFocusProxy",Rp=u.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...i}=e,o=Vs(mA,n);return u.createElement(vs,ie({"aria-hidden":!0,tabIndex:0},i,{ref:t,style:{position:"fixed"},onFocus:s=>{var a;const c=s.relatedTarget;!((a=o.viewport)!==null&&a!==void 0&&a.contains(c))&&r()}}))}),Ls="Toast",vA="toast.swipeStart",gA="toast.swipeMove",yA="toast.swipeCancel",bA="toast.swipeEnd",wA=u.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:i,onOpenChange:o,...s}=e,[a=!0,c]=pn({prop:r,defaultProp:i,onChange:o});return u.createElement(hr,{present:n||a},u.createElement(Yg,ie({open:a},s,{ref:t,onClose:()=>c(!1),onPause:qt(e.onPause),onResume:qt(e.onResume),onSwipeStart:De(e.onSwipeStart,l=>{l.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:De(e.onSwipeMove,l=>{const{x:d,y:f}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","move"),l.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${d}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${f}px`)}),onSwipeCancel:De(e.onSwipeCancel,l=>{l.currentTarget.setAttribute("data-swipe","cancel"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),l.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:De(e.onSwipeEnd,l=>{const{x:d,y:f}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","end"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),l.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${d}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${f}px`),c(!1)})})))}),[xA,EA]=Wg(Ls,{onClose(){}}),Yg=u.forwardRef((e,t)=>{const{__scopeToast:n,type:r="foreground",duration:i,open:o,onClose:s,onEscapeKeyDown:a,onPause:c,onResume:l,onSwipeStart:d,onSwipeMove:f,onSwipeCancel:h,onSwipeEnd:p,...w}=e,E=Vs(Ls,n),[T,S]=u.useState(null),m=Qe(t,C=>S(C)),x=u.useRef(null),_=u.useRef(null),$=i||E.duration,O=u.useRef(0),M=u.useRef($),N=u.useRef(0),{onToastAdd:j,onToastRemove:K}=E,V=qt(()=>{var C;(T==null?void 0:T.contains(document.activeElement))&&((C=E.viewport)===null||C===void 0||C.focus()),s()}),P=u.useCallback(C=>{!C||C===1/0||(window.clearTimeout(N.current),O.current=new Date().getTime(),N.current=window.setTimeout(V,C))},[V]);u.useEffect(()=>{const C=E.viewport;if(C){const I=()=>{P(M.current),l==null||l()},k=()=>{const U=new Date().getTime()-O.current;M.current=M.current-U,window.clearTimeout(N.current),c==null||c()};return C.addEventListener(pc,k),C.addEventListener(hc,I),()=>{C.removeEventListener(pc,k),C.removeEventListener(hc,I)}}},[E.viewport,$,c,l,P]),u.useEffect(()=>{o&&!E.isClosePausedRef.current&&P($)},[o,$,E.isClosePausedRef,P]),u.useEffect(()=>(j(),()=>K()),[j,K]);const v=u.useMemo(()=>T?Kg(T):null,[T]);return E.viewport?u.createElement(u.Fragment,null,v&&u.createElement(CA,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0},v),u.createElement(xA,{scope:n,onClose:V},fn.createPortal(u.createElement(pu.ItemSlot,{scope:n},u.createElement(_b,{asChild:!0,onEscapeKeyDown:De(a,()=>{E.isFocusedToastEscapeKeyDownRef.current||V(),E.isFocusedToastEscapeKeyDownRef.current=!1})},u.createElement(He.li,ie({role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":o?"open":"closed","data-swipe-direction":E.swipeDirection},w,{ref:m,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:De(e.onKeyDown,C=>{C.key==="Escape"&&(a==null||a(C.nativeEvent),C.nativeEvent.defaultPrevented||(E.isFocusedToastEscapeKeyDownRef.current=!0,V()))}),onPointerDown:De(e.onPointerDown,C=>{C.button===0&&(x.current={x:C.clientX,y:C.clientY})}),onPointerMove:De(e.onPointerMove,C=>{if(!x.current)return;const I=C.clientX-x.current.x,k=C.clientY-x.current.y,U=!!_.current,G=["left","right"].includes(E.swipeDirection),ue=["left","up"].includes(E.swipeDirection)?Math.min:Math.max,W=G?ue(0,I):0,L=G?0:ue(0,k),oe=C.pointerType==="touch"?10:2,X={x:W,y:L},q={originalEvent:C,delta:X};U?(_.current=X,$i(gA,f,q,{discrete:!1})):Ip(X,E.swipeDirection,oe)?(_.current=X,$i(vA,d,q,{discrete:!1}),C.target.setPointerCapture(C.pointerId)):(Math.abs(I)>oe||Math.abs(k)>oe)&&(x.current=null)}),onPointerUp:De(e.onPointerUp,C=>{const I=_.current,k=C.target;if(k.hasPointerCapture(C.pointerId)&&k.releasePointerCapture(C.pointerId),_.current=null,x.current=null,I){const U=C.currentTarget,G={originalEvent:C,delta:I};Ip(I,E.swipeDirection,E.swipeThreshold)?$i(bA,p,G,{discrete:!0}):$i(yA,h,G,{discrete:!0}),U.addEventListener("click",ue=>ue.preventDefault(),{once:!0})}})})))),E.viewport))):null});Yg.propTypes={type(e){if(e.type&&!["foreground","background"].includes(e.type)){const t=`Invalid prop \`type\` supplied to \`${Ls}\`. Expected \`foreground | background\`.`;return new Error(t)}return null}};const CA=e=>{const{__scopeToast:t,children:n,...r}=e,i=Vs(Ls,t),[o,s]=u.useState(!1),[a,c]=u.useState(!1);return $A(()=>s(!0)),u.useEffect(()=>{const l=window.setTimeout(()=>c(!0),1e3);return()=>window.clearTimeout(l)},[]),a?null:u.createElement(gh,{asChild:!0},u.createElement(vs,r,o&&u.createElement(u.Fragment,null,i.label," ",n)))},_A="ToastAction",hu=u.forwardRef((e,t)=>{const{altText:n,...r}=e;return n?u.createElement(zg,{altText:n,asChild:!0},u.createElement(SA,ie({},r,{ref:t}))):null});hu.propTypes={altText(e){return e.altText?null:new Error(`Missing prop \`altText\` expected on \`${_A}\``)}};const TA="ToastClose",SA=u.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,i=EA(TA,n);return u.createElement(zg,{asChild:!0},u.createElement(He.button,ie({type:"button"},r,{ref:t,onClick:De(e.onClick,i.onClose)})))}),zg=u.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...i}=e;return u.createElement(He.div,ie({"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0},i,{ref:t}))});function Kg(e){const t=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),PA(r)){const i=r.ariaHidden||r.hidden||r.style.display==="none",o=r.dataset.radixToastAnnounceExclude==="";if(!i)if(o){const s=r.dataset.radixToastAnnounceAlt;s&&t.push(s)}else t.push(...Kg(r))}}),t}function $i(e,t,n,{discrete:r}){const i=n.originalEvent.currentTarget,o=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?Vp(i,o):i.dispatchEvent(o)}const Ip=(e,t,n=0)=>{const r=Math.abs(e.x),i=Math.abs(e.y),o=r>i;return t==="left"||t==="right"?o&&r>n:!o&&i>n};function $A(e=()=>{}){const t=qt(e);Wt(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function PA(e){return e.nodeType===e.ELEMENT_NODE}function RA(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ra(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}const IA=Ug,qg=hA,Xg=wA,AA=hu;var DA="_10z4js28",OA=ft({defaultClassName:"_10z4js24",variantClassNames:{color:{neutral:"_10z4js25",negative:"_10z4js26"}},defaultVariants:{color:"neutral"},compoundVariants:[]}),MA="_10z4js27",kA="_10z4js29";const Gg=IA,mu=u.forwardRef(({className:e,...t},n)=>D.jsx(qg,{ref:n,className:Re(kA,e),...t}));mu.displayName=qg.displayName;const Fs=u.forwardRef(({className:e,color:t="neutral",...n},r)=>D.jsx(Xg,{ref:r,className:Re(OA({color:t}),e),...n}));Fs.displayName=Xg.displayName;Fs.defaultProps={viewPort:void 0};const vu=u.forwardRef(({className:e,...t},n)=>D.jsx(hu,{ref:n,className:Re(e),...t}));vu.displayName=AA.displayName;const NA=1,jA=1e6,Fn={ADD_TOAST:"ADD_TOAST",UPDATE_TOAST:"UPDATE_TOAST",DISMISS_TOAST:"DISMISS_TOAST",REMOVE_TOAST:"REMOVE_TOAST"};let Ia=0;function VA(){return Ia=(Ia+1)%Number.MAX_VALUE,Ia.toString()}const Aa=new Map,Ap=e=>{if(Aa.has(e))return;const t=setTimeout(()=>{Aa.delete(e),Vo({type:Fn.REMOVE_TOAST,toastId:e})},jA);Aa.set(e,t)};function Zg(e,t){switch(t.type){case Fn.ADD_TOAST:return{...e,toasts:[t.toast,...e.toasts].slice(0,NA)};case Fn.UPDATE_TOAST:return{...e,toasts:e.toasts.map(n=>n.id===t.toast.id?{...n,...t.toast}:n)};case Fn.DISMISS_TOAST:{const{toastId:n}=t;return n?Ap(n):e.toasts.forEach(r=>{Ap(r.id)}),{...e,toasts:e.toasts.map(r=>r.id===n||n===void 0?{...r,open:!1}:r)}}case Fn.REMOVE_TOAST:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(n=>n.id!==t.toastId)};default:return e}}const ki=[];let Ni={toasts:[]};function Vo(e){Ni=Zg(Ni,e),ki.forEach(t=>{t(Ni)})}function Qg({...e}){const t=VA(),n=i=>Vo({type:Fn.UPDATE_TOAST,toast:{...i,id:t}}),r=()=>Vo({type:Fn.DISMISS_TOAST,toastId:t});return Vo({type:Fn.ADD_TOAST,toast:{...e,id:t,open:!0,onOpenChange:i=>{i||r()}}}),{id:t,dismiss:r,update:n}}function Jg(){const[e,t]=u.useState(Ni);return u.useEffect(()=>(ki.push(t),()=>{const n=ki.indexOf(t);n>-1&&ki.splice(n,1)}),[e]),{...e,toast:Qg,dismiss:n=>Vo({type:Fn.DISMISS_TOAST,toastId:n})}}const gu=u.forwardRef((e,t)=>{const{toasts:n}=Jg();return D.jsx(Gg,{children:n.map(({id:r,description:i,action:o,actionText:s,actionClick:a,duration:c=3e3,type:l="foreground",color:d="neutral",viewPort:f,...h})=>D.jsxs("div",{children:[D.jsxs(Fs,{ref:t,color:d,duration:c,type:l,"data-test-id":`toast-${h["data-test-id"]??""}`,...h,children:[D.jsx(ht,{flexGrow:1,pl:"$16",py:"$18",pr:a?"$0":"$16",maxW:"$full",minW:"$0",children:D.jsx(Kt,{textStyle:"body2",fontWeight:"$reguler",textOverflow:"ellipsis",overflow:"hidden",className:MA,children:i})}),!o&&a&&s?D.jsx(vu,{altText:s,asChild:!0,children:D.jsx(Dv,{"data-test-id":`action-toast-${h["data-test-id"]??""}`,onClick:a,className:DA,children:s})}):o]},r),D.jsx(mu,{...f})]},r))})});gu.displayName="Toaster";const[Bs,SD]=sn("Tooltip",[hs]),Hs=hs(),LA="TooltipProvider",FA=700,mc="tooltip.open",[BA,yu]=Bs(LA),HA=e=>{const{__scopeTooltip:t,delayDuration:n=FA,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:o}=e,[s,a]=u.useState(!0),c=u.useRef(!1),l=u.useRef(0);return u.useEffect(()=>{const d=l.current;return()=>window.clearTimeout(d)},[]),u.createElement(BA,{scope:t,isOpenDelayed:s,delayDuration:n,onOpen:u.useCallback(()=>{window.clearTimeout(l.current),a(!1)},[]),onClose:u.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>a(!0),r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:u.useCallback(d=>{c.current=d},[]),disableHoverableContent:i},o)},bu="Tooltip",[WA,Ws]=Bs(bu),UA=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i=!1,onOpenChange:o,disableHoverableContent:s,delayDuration:a}=e,c=yu(bu,e.__scopeTooltip),l=Hs(t),[d,f]=u.useState(null),h=Bn(),p=u.useRef(0),w=s??c.disableHoverableContent,E=a??c.delayDuration,T=u.useRef(!1),[S=!1,m]=pn({prop:r,defaultProp:i,onChange:M=>{M?(c.onOpen(),document.dispatchEvent(new CustomEvent(mc))):c.onClose(),o==null||o(M)}}),x=u.useMemo(()=>S?T.current?"delayed-open":"instant-open":"closed",[S]),_=u.useCallback(()=>{window.clearTimeout(p.current),T.current=!1,m(!0)},[m]),$=u.useCallback(()=>{window.clearTimeout(p.current),m(!1)},[m]),O=u.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{T.current=!0,m(!0)},E)},[E,m]);return u.useEffect(()=>()=>window.clearTimeout(p.current),[]),u.createElement(hh,l,u.createElement(WA,{scope:t,contentId:h,open:S,stateAttribute:x,trigger:d,onTriggerChange:f,onTriggerEnter:u.useCallback(()=>{c.isOpenDelayed?O():_()},[c.isOpenDelayed,O,_]),onTriggerLeave:u.useCallback(()=>{w?$():window.clearTimeout(p.current)},[$,w]),onOpen:_,onClose:$,disableHoverableContent:w},n))},Dp="TooltipTrigger",YA=u.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Ws(Dp,n),o=yu(Dp,n),s=Hs(n),a=u.useRef(null),c=Qe(t,a,i.onTriggerChange),l=u.useRef(!1),d=u.useRef(!1),f=u.useCallback(()=>l.current=!1,[]);return u.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),u.createElement(mh,ie({asChild:!0},s),u.createElement(He.button,ie({"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute},r,{ref:c,onPointerMove:De(e.onPointerMove,h=>{h.pointerType!=="touch"&&!d.current&&!o.isPointerInTransitRef.current&&(i.onTriggerEnter(),d.current=!0)}),onPointerLeave:De(e.onPointerLeave,()=>{i.onTriggerLeave(),d.current=!1}),onPointerDown:De(e.onPointerDown,()=>{l.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:De(e.onFocus,()=>{l.current||i.onOpen()}),onBlur:De(e.onBlur,i.onClose),onClick:De(e.onClick,i.onClose)})))}),zA="TooltipPortal",[$D,KA]=Bs(zA,{forceMount:void 0}),Ko="TooltipContent",qA=u.forwardRef((e,t)=>{const n=KA(Ko,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...o}=e,s=Ws(Ko,e.__scopeTooltip);return u.createElement(hr,{present:r||s.open},s.disableHoverableContent?u.createElement(ey,ie({side:i},o,{ref:t})):u.createElement(XA,ie({side:i},o,{ref:t})))}),XA=u.forwardRef((e,t)=>{const n=Ws(Ko,e.__scopeTooltip),r=yu(Ko,e.__scopeTooltip),i=u.useRef(null),o=Qe(t,i),[s,a]=u.useState(null),{trigger:c,onClose:l}=n,d=i.current,{onPointerInTransitChange:f}=r,h=u.useCallback(()=>{a(null),f(!1)},[f]),p=u.useCallback((w,E)=>{const T=w.currentTarget,S={x:w.clientX,y:w.clientY},m=eD(S,T.getBoundingClientRect()),x=tD(S,m),_=nD(E.getBoundingClientRect()),$=oD([...x,..._]);a($),f(!0)},[f]);return u.useEffect(()=>()=>h(),[h]),u.useEffect(()=>{if(c&&d){const w=T=>p(T,d),E=T=>p(T,c);return c.addEventListener("pointerleave",w),d.addEventListener("pointerleave",E),()=>{c.removeEventListener("pointerleave",w),d.removeEventListener("pointerleave",E)}}},[c,d,p,h]),u.useEffect(()=>{if(s){const w=E=>{const T=E.target,S={x:E.clientX,y:E.clientY},m=(c==null?void 0:c.contains(T))||(d==null?void 0:d.contains(T)),x=!rD(S,s);m?h():x&&(h(),l())};return document.addEventListener("pointermove",w),()=>document.removeEventListener("pointermove",w)}},[c,d,s,l,h]),u.createElement(ey,ie({},e,{ref:o}))}),[GA,ZA]=Bs(bu,{isInside:!1}),ey=u.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:o,onPointerDownOutside:s,...a}=e,c=Ws(Ko,n),l=Hs(n),{onClose:d}=c;return u.useEffect(()=>(document.addEventListener(mc,d),()=>document.removeEventListener(mc,d)),[d]),u.useEffect(()=>{if(c.trigger){const f=h=>{const p=h.target;p!=null&&p.contains(c.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[c.trigger,d]),u.createElement(us,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:f=>f.preventDefault(),onDismiss:d},u.createElement(vh,ie({"data-state":c.stateAttribute},l,a,{ref:t,style:{...a.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)"}}),u.createElement(jp,null,r),u.createElement(GA,{scope:n,isInside:!0},u.createElement(Aw,{id:c.contentId,role:"tooltip"},i||r))))}),QA="TooltipArrow",JA=u.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Hs(n);return ZA(QA,n).isInside?null:u.createElement(Rw,ie({},i,r,{ref:t}))});function eD(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function tD(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});break}return r}function nD(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function rD(e,t){const{x:n,y:r}=e;let i=!1;for(let o=0,s=t.length-1;o<t.length;s=o++){const a=t[o].x,c=t[o].y,l=t[s].x,d=t[s].y;c>r!=d>r&&n<(l-a)*(r-c)/(d-c)+a&&(i=!i)}return i}function oD(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),iD(t)}function iD(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const o=t[t.length-1],s=t[t.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const o=n[n.length-1],s=n[n.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))n.pop();else break}n.push(i)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const sD=HA,aD=UA,cD=YA,lD=qA,uD=JA;function Op(e){var t=e.match(/^var\((.*)\)$/);return t?t[1]:e}function dD(e,t){var n=e;for(var r of t){if(!(r in n))throw new Error("Path ".concat(t.join(" -> ")," does not exist in object"));n=n[r]}return n}function ty(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r=e.constructor();for(var i in e){var o=e[i],s=[...n,i];typeof o=="string"||typeof o=="number"||o==null?r[i]=t(o,s):typeof o=="object"&&!Array.isArray(o)?r[i]=ty(o,t,s):console.warn('Skipping invalid key "'.concat(s.join("."),'". Should be a string, number, null or object. Received: "').concat(Array.isArray(o)?"Array":typeof o,'"'))}return r}function fD(e,t){var n={};if(typeof t=="object"){var r=e;ty(t,(s,a)=>{var c=dD(r,a);n[Op(c)]=String(s)})}else{var i=e;for(var o in i)n[Op(o)]=i[o]}return Object.defineProperty(n,"toString",{value:function(){return Object.keys(this).map(a=>"".concat(a,":").concat(this[a])).join(";")},writable:!1}),n}var pD="var(--_4goys34)",hD="_4goys35",mD="_4goys36";const wu=u.forwardRef(({align:e,alignOffset:t,children:n,color:r,bgColor:i,content:o,defaultOpen:s,delayDuration:a=700,disableHoverableContent:c,onOpenChange:l,open:d,position:f,positionOffset:h,withIcon:p,...w},E)=>{const T=Et.atoms.commonAtoms({color:r,bgColor:i}).className,S=Et.atoms.borderAtoms({borderColor:i}).className,x=i.replace("$","");return D.jsxs(aD,{defaultOpen:s,delayDuration:a,disableHoverableContent:c,onOpenChange:l,open:d,children:[D.jsx(cD,{asChild:!0,ref:E,children:n}),D.jsx(xs,{children:D.jsxs(lD,{align:e,alignOffset:t,side:f,sideOffset:h,...w,className:Re(mD,T,S),children:[D.jsxs(Lt,{gap:"$6",children:[p&&D.jsx(Lt,{width:"$24",children:D.jsx(ab,{size:24})}),o]}),D.jsx(uD,{className:hD,style:fD({[pD]:Et.theme.colors[x]})})]})})]})});wu.displayName="Tooltip";wu.defaultProps={align:void 0,alignOffset:void 0,defaultOpen:void 0,delayDuration:300,disableHoverableContent:!1,onOpenChange:void 0,open:void 0,position:void 0,positionOffset:void 0,withIcon:void 0,bgColor:"$blackTypoHigh",color:"$white"};const xu=({children:e})=>D.jsxs(sD,{children:[e,D.jsx(gu,{})]});xu.displayName="RadixProvider";const Eu=({children:e,withScrollStyles:t})=>D.jsx("div",{id:"voila-ui",style:{fontFamily:Et.theme.fonts.poppins},className:Re(t??Et.scrollbarStyle),children:D.jsx(xu,{children:e})});Eu.displayName="Provider";Eu.defaultProps={withScrollStyles:!1};exports.Accordion=c0;exports.AccordionContent=H0;exports.AccordionItem=W0;exports.AccordionTrigger=hb;exports.Alert=qp;exports.Badge=Sc;exports.BaseSelect=Lc;exports.BottomSheet=kS;exports.Box=ht;exports.Button=co;exports.Card=xc;exports.Checkbox=$v;exports.Chips=ml;exports.CloseButton=ho;exports.ConfirmDialogContext=yl;exports.ConfirmDialogProvider=PP;exports.Container=Ec;exports.DatePicker=eR;exports.Dialog=gl;exports.Flex=Lt;exports.FullLoader=kv;exports.Grid=Cc;exports.IconButton=El;exports.Image=Cl;exports.Input=wl;exports.Link=Dv;exports.List=_l;exports.ListItem=Tl;exports.Loader=FP;exports.LoaderAnimated=Sl;exports.Modal=ei;exports.ModalBody=Ns;exports.ModalFooter=js;exports.ModalHeader=ti;exports.MultiPicker=Nv;exports.Overlay=C1;exports.Picker=lc;exports.Portal=xs;exports.Provider=Eu;exports.Radio=kg;exports.RadioGroup=HI;exports.RadixProvider=xu;exports.Search=lu;exports.Select=to;exports.SelectPicker=Tg;exports.Spinner=mo;exports.Stack=Ir;exports.Switch=Vg;exports.TabItem=fu;exports.Table=Bg;exports.Tabs=du;exports.TabsContext=uu;exports.Text=Kt;exports.Textarea=xl;exports.Toast=Fs;exports.ToastAction=vu;exports.ToastProvider=Gg;exports.ToastViewport=mu;exports.Toaster=gu;exports.Tooltip=wu;exports.reducer=Zg;exports.toast=Qg;exports.useDialog=RP;exports.useIndeterminate=Q$;exports.useOnMount=Lh;exports.useRipple=hl;exports.useTableRenderer=Fg;exports.useToast=Jg;
|
|
148
|
+
*/var dp;function nR(){return dp||(dp=1,process.env.NODE_ENV!=="production"&&function(){var e=60103,t=60106,n=60107,r=60108,i=60114,o=60109,s=60110,a=60112,c=60113,l=60120,d=60115,f=60116,h=60121,p=60122,y=60117,E=60129,T=60131;if(typeof Symbol=="function"&&Symbol.for){var S=Symbol.for;e=S("react.element"),t=S("react.portal"),n=S("react.fragment"),r=S("react.strict_mode"),i=S("react.profiler"),o=S("react.provider"),s=S("react.context"),a=S("react.forward_ref"),c=S("react.suspense"),l=S("react.suspense_list"),d=S("react.memo"),f=S("react.lazy"),h=S("react.block"),p=S("react.server.block"),y=S("react.fundamental"),S("react.scope"),S("react.opaque.id"),E=S("react.debug_trace_mode"),S("react.offscreen"),T=S("react.legacy_hidden")}var m=!1;function x(te){return!!(typeof te=="string"||typeof te=="function"||te===n||te===i||te===E||te===r||te===c||te===l||te===T||m||typeof te=="object"&&te!==null&&(te.$$typeof===f||te.$$typeof===d||te.$$typeof===o||te.$$typeof===s||te.$$typeof===a||te.$$typeof===y||te.$$typeof===h||te[0]===p))}function _(te){if(typeof te=="object"&&te!==null){var Z=te.$$typeof;switch(Z){case e:var ge=te.type;switch(ge){case n:case i:case r:case c:case l:return ge;default:var Te=ge&&ge.$$typeof;switch(Te){case s:case a:case f:case d:case o:return Te;default:return Z}}case t:return Z}}}var $=s,M=o,D=e,N=a,j=n,K=f,V=d,P=t,v=i,C=r,I=c,k=!1,U=!1;function G(te){return k||(k=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function ue(te){return U||(U=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function W(te){return _(te)===s}function L(te){return _(te)===o}function oe(te){return typeof te=="object"&&te!==null&&te.$$typeof===e}function X(te){return _(te)===a}function q(te){return _(te)===n}function ne(te){return _(te)===f}function ae(te){return _(te)===d}function B(te){return _(te)===t}function H(te){return _(te)===i}function J(te){return _(te)===r}function ee(te){return _(te)===c}ut.ContextConsumer=$,ut.ContextProvider=M,ut.Element=D,ut.ForwardRef=N,ut.Fragment=j,ut.Lazy=K,ut.Memo=V,ut.Portal=P,ut.Profiler=v,ut.StrictMode=C,ut.Suspense=I,ut.isAsyncMode=G,ut.isConcurrentMode=ue,ut.isContextConsumer=W,ut.isContextProvider=L,ut.isElement=oe,ut.isForwardRef=X,ut.isFragment=q,ut.isLazy=ne,ut.isMemo=ae,ut.isPortal=B,ut.isProfiler=H,ut.isStrictMode=J,ut.isSuspense=ee,ut.isValidElementType=x,ut.typeOf=_}()),ut}process.env.NODE_ENV==="production"?uc.exports=tR():uc.exports=nR();var fp=uc.exports;let pp=e=>typeof e=="object"&&e!=null&&e.nodeType===1,hp=(e,t)=>(!t||e!=="hidden")&&e!=="visible"&&e!=="clip",Sa=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){let n=getComputedStyle(e,null);return hp(n.overflowY,t)||hp(n.overflowX,t)||(r=>{let i=(o=>{if(!o.ownerDocument||!o.ownerDocument.defaultView)return null;try{return o.ownerDocument.defaultView.frameElement}catch{return null}})(r);return!!i&&(i.clientHeight<r.scrollHeight||i.clientWidth<r.scrollWidth)})(e)}return!1},Ti=(e,t,n,r,i,o,s,a)=>o<e&&s>t||o>e&&s<t?0:o<=e&&a<=n||s>=t&&a>=n?o-e-r:s>t&&a<n||o<e&&a>n?s-t+i:0,rR=e=>{let t=e.parentElement;return t??(e.getRootNode().host||null)};var oR=(e,t)=>{var n,r,i,o,s,a;if(typeof document>"u")return[];let{scrollMode:c,block:l,inline:d,boundary:f,skipOverflowHiddenElements:h}=t,p=typeof f=="function"?f:C=>C!==f;if(!pp(e))throw new TypeError("Invalid target");let y=document.scrollingElement||document.documentElement,E=[],T=e;for(;pp(T)&&p(T);){if(T=rR(T),T===y){E.push(T);break}T!=null&&T===document.body&&Sa(T)&&!Sa(document.documentElement)||T!=null&&Sa(T,h)&&E.push(T)}let S=(r=(n=window.visualViewport)==null?void 0:n.width)!=null?r:innerWidth,m=(o=(i=window.visualViewport)==null?void 0:i.height)!=null?o:innerHeight,x=(s=window.scrollX)!=null?s:pageXOffset,_=(a=window.scrollY)!=null?a:pageYOffset,{height:$,width:M,top:D,right:N,bottom:j,left:K}=e.getBoundingClientRect(),V=l==="start"||l==="nearest"?D:l==="end"?j:D+$/2,P=d==="center"?K+M/2:d==="end"?N:K,v=[];for(let C=0;C<E.length;C++){let I=E[C],{height:k,width:U,top:G,right:ue,bottom:W,left:L}=I.getBoundingClientRect();if(c==="if-needed"&&D>=0&&K>=0&&j<=m&&N<=S&&D>=G&&j<=W&&K>=L&&N<=ue)return v;let oe=getComputedStyle(I),X=parseInt(oe.borderLeftWidth,10),q=parseInt(oe.borderTopWidth,10),ne=parseInt(oe.borderRightWidth,10),ae=parseInt(oe.borderBottomWidth,10),B=0,H=0,J="offsetWidth"in I?I.offsetWidth-I.clientWidth-X-ne:0,ee="offsetHeight"in I?I.offsetHeight-I.clientHeight-q-ae:0,te="offsetWidth"in I?I.offsetWidth===0?0:U/I.offsetWidth:0,Z="offsetHeight"in I?I.offsetHeight===0?0:k/I.offsetHeight:0;if(y===I)B=l==="start"?V:l==="end"?V-m:l==="nearest"?Ti(_,_+m,m,q,ae,_+V,_+V+$,$):V-m/2,H=d==="start"?P:d==="center"?P-S/2:d==="end"?P-S:Ti(x,x+S,S,X,ne,x+P,x+P+M,M),B=Math.max(0,B+_),H=Math.max(0,H+x);else{B=l==="start"?V-G-q:l==="end"?V-W+ae+ee:l==="nearest"?Ti(G,W,k,q,ae+ee,V,V+$,$):V-(G+k/2)+ee/2,H=d==="start"?P-L-X:d==="center"?P-(L+U/2)+J/2:d==="end"?P-ue+ne+J:Ti(L,ue,U,X,ne+J,P,P+M,M);let{scrollLeft:ge,scrollTop:Te}=I;B=Math.max(0,Math.min(Te+B/Z,I.scrollHeight-k/Z+ee)),H=Math.max(0,Math.min(ge+H/te,I.scrollWidth-U/te+J)),V+=Te-B,P+=ge-H}v.push({el:I,top:B,left:H})}return v},iR=0;function mp(e){return typeof e=="function"?e:en}function en(){}function Vv(e,t){if(e){var n=oR(e,{boundary:t,block:"nearest",scrollMode:"if-needed"});n.forEach(function(r){var i=r.el,o=r.top,s=r.left;i.scrollTop=o,i.scrollLeft=s})}}function vp(e,t,n){var r=e===t||t instanceof n.Node&&e.contains&&e.contains(t);return r}function $l(e,t){var n;function r(){n&&clearTimeout(n)}function i(){for(var o=arguments.length,s=new Array(o),a=0;a<o;a++)s[a]=arguments[a];r(),n=setTimeout(function(){n=null,e.apply(void 0,s)},t)}return i.cancel=r,i}function wt(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){for(var i=arguments.length,o=new Array(i>1?i-1:0),s=1;s<i;s++)o[s-1]=arguments[s];return t.some(function(a){return a&&a.apply(void 0,[r].concat(o)),r.preventDownshiftDefault||r.hasOwnProperty("nativeEvent")&&r.nativeEvent.preventDownshiftDefault})}}function ir(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){t.forEach(function(i){typeof i=="function"?i(r):i&&(i.current=r)})}}function Lv(){return String(iR++)}function Fv(e){var t=e.isOpen,n=e.resultCount,r=e.previousResultCount;return t?n?n!==r?n+" result"+(n===1?" is":"s are")+" available, use up and down arrow keys to navigate. Press Enter key to select.":"":"No results are available.":""}function gp(e,t){return e=Array.isArray(e)?e[0]:e,!e&&t?t:e}function Bv(e){return typeof e.type=="string"}function Hv(e){return e.props}function sR(e,t){console.error('The property "'+t+'" is required in "'+e+'"')}var aR=["highlightedIndex","inputValue","isOpen","selectedItem","type"];function Si(e){e===void 0&&(e={});var t={};return aR.forEach(function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}function Yo(e,t){return Object.keys(e).reduce(function(n,r){return n[r]=es(t,r)?t[r]:e[r],n},{})}function es(e,t){return e[t]!==void 0}function zo(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&t.indexOf("Arrow")!==0?"Arrow"+t:t}function cR(e){return Object.prototype.toString.call(e)==="[object Object]"}function Rr(e,t,n,r,i){if(i===void 0&&(i=!0),n===0)return-1;var o=n-1;(typeof t!="number"||t<0||t>=n)&&(t=e>0?-1:o+1);var s=t+e;s<0?s=i?o:0:s>o&&(s=i?0:o);var a=Nr(e,s,n,r,i);return a===-1?t>=n?-1:t:a}function Nr(e,t,n,r,i){var o=r(t);if(!o||!o.hasAttribute("disabled"))return t;if(e>0){for(var s=t+1;s<n;s++)if(!r(s).hasAttribute("disabled"))return s}else for(var a=t-1;a>=0;a--)if(!r(a).hasAttribute("disabled"))return a;return i?e>0?Nr(1,0,n,r,!1):Nr(-1,n-1,n,r,!1):-1}function ts(e,t,n,r){return r===void 0&&(r=!0),t.some(function(i){return i&&(vp(i,e,n)||r&&vp(i,n.document.activeElement,n))})}var Pl=en;process.env.NODE_ENV!=="production"&&(Pl=function(t,n,r){var i="This prop should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled Downshift element for the lifetime of the component. More info: https://github.com/downshift-js/downshift#control-props";Object.keys(t).forEach(function(o){n[o]!==void 0&&r[o]===void 0?console.error('downshift: A component has changed the controlled prop "'+o+'" to be uncontrolled. '+i):n[o]===void 0&&r[o]!==void 0&&console.error('downshift: A component has changed the uncontrolled prop "'+o+'" to be controlled. '+i)})});var lR=$l(function(e){Wv(e).textContent=""},500);function Rl(e,t){var n=Wv(t);e&&(n.textContent=e,lR(t))}function Wv(e){e===void 0&&(e=document);var t=e.getElementById("a11y-status-message");return t||(t=e.createElement("div"),t.setAttribute("id","a11y-status-message"),t.setAttribute("role","status"),t.setAttribute("aria-live","polite"),t.setAttribute("aria-relevant","additions text"),Object.assign(t.style,{border:"0",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0",position:"absolute",width:"1px"}),e.body.appendChild(t),t)}var Uv=process.env.NODE_ENV!=="production"?"__autocomplete_unknown__":0,Yv=process.env.NODE_ENV!=="production"?"__autocomplete_mouseup__":1,zv=process.env.NODE_ENV!=="production"?"__autocomplete_item_mouseenter__":2,Oi=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_up__":3,Mi=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_arrow_down__":4,Kv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_escape__":5,qv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_enter__":6,Xv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_home__":7,Gv=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_end__":8,Zv=process.env.NODE_ENV!=="production"?"__autocomplete_click_item__":9,Qv=process.env.NODE_ENV!=="production"?"__autocomplete_blur_input__":10,Jv=process.env.NODE_ENV!=="production"?"__autocomplete_change_input__":11,eg=process.env.NODE_ENV!=="production"?"__autocomplete_keydown_space_button__":12,dc=process.env.NODE_ENV!=="production"?"__autocomplete_click_button__":13,tg=process.env.NODE_ENV!=="production"?"__autocomplete_blur_button__":14,ng=process.env.NODE_ENV!=="production"?"__autocomplete_controlled_prop_updated_selected_item__":15,rg=process.env.NODE_ENV!=="production"?"__autocomplete_touchend__":16,uR=Object.freeze({__proto__:null,unknown:Uv,mouseUp:Yv,itemMouseEnter:zv,keyDownArrowUp:Oi,keyDownArrowDown:Mi,keyDownEscape:Kv,keyDownEnter:qv,keyDownHome:Xv,keyDownEnd:Gv,clickItem:Zv,blurInput:Qv,changeInput:Jv,keyDownSpaceButton:eg,clickButton:dc,blurButton:tg,controlledPropUpdatedSelectedItem:ng,touchEnd:rg}),dR=["refKey","ref"],fR=["onClick","onPress","onKeyDown","onKeyUp","onBlur"],pR=["onKeyDown","onBlur","onChange","onInput","onChangeText"],hR=["refKey","ref"],mR=["onMouseMove","onMouseDown","onClick","onPress","index","item"],vR=function(){var e=function(t){Nc(n,t);function n(i){var o;o=t.call(this,i)||this,o.id=o.props.id||"downshift-"+Lv(),o.menuId=o.props.menuId||o.id+"-menu",o.labelId=o.props.labelId||o.id+"-label",o.inputId=o.props.inputId||o.id+"-input",o.getItemId=o.props.getItemId||function(m){return o.id+"-item-"+m},o.input=null,o.items=[],o.itemCount=null,o.previousResultCount=0,o.timeoutIds=[],o.internalSetTimeout=function(m,x){var _=setTimeout(function(){o.timeoutIds=o.timeoutIds.filter(function($){return $!==_}),m()},x);o.timeoutIds.push(_)},o.setItemCount=function(m){o.itemCount=m},o.unsetItemCount=function(){o.itemCount=null},o.setHighlightedIndex=function(m,x){m===void 0&&(m=o.props.defaultHighlightedIndex),x===void 0&&(x={}),x=Si(x),o.internalSetState(ie({highlightedIndex:m},x))},o.clearSelection=function(m){o.internalSetState({selectedItem:null,inputValue:"",highlightedIndex:o.props.defaultHighlightedIndex,isOpen:o.props.defaultIsOpen},m)},o.selectItem=function(m,x,_){x=Si(x),o.internalSetState(ie({isOpen:o.props.defaultIsOpen,highlightedIndex:o.props.defaultHighlightedIndex,selectedItem:m,inputValue:o.props.itemToString(m)},x),_)},o.selectItemAtIndex=function(m,x,_){var $=o.items[m];$!=null&&o.selectItem($,x,_)},o.selectHighlightedItem=function(m,x){return o.selectItemAtIndex(o.getState().highlightedIndex,m,x)},o.internalSetState=function(m,x){var _,$,M={},D=typeof m=="function";return!D&&m.hasOwnProperty("inputValue")&&o.props.onInputValueChange(m.inputValue,ie({},o.getStateAndHelpers(),m)),o.setState(function(N){N=o.getState(N);var j=D?m(N):m;j=o.props.stateReducer(N,j),_=j.hasOwnProperty("selectedItem");var K={};return _&&j.selectedItem!==N.selectedItem&&($=j.selectedItem),j.type=j.type||Uv,Object.keys(j).forEach(function(V){N[V]!==j[V]&&(M[V]=j[V]),V!=="type"&&(j[V],es(o.props,V)||(K[V]=j[V]))}),D&&j.hasOwnProperty("inputValue")&&o.props.onInputValueChange(j.inputValue,ie({},o.getStateAndHelpers(),j)),K},function(){mp(x)();var N=Object.keys(M).length>1;N&&o.props.onStateChange(M,o.getStateAndHelpers()),_&&o.props.onSelect(m.selectedItem,o.getStateAndHelpers()),$!==void 0&&o.props.onChange($,o.getStateAndHelpers()),o.props.onUserAction(M,o.getStateAndHelpers())})},o.rootRef=function(m){return o._rootNode=m},o.getRootProps=function(m,x){var _,$=m===void 0?{}:m,M=$.refKey,D=M===void 0?"ref":M,N=$.ref,j=zt($,dR),K=x===void 0?{}:x,V=K.suppressRefError,P=V===void 0?!1:V;o.getRootProps.called=!0,o.getRootProps.refKey=D,o.getRootProps.suppressRefError=P;var v=o.getState(),C=v.isOpen;return ie((_={},_[D]=ir(N,o.rootRef),_.role="combobox",_["aria-expanded"]=C,_["aria-haspopup"]="listbox",_["aria-owns"]=C?o.menuId:null,_["aria-labelledby"]=o.labelId,_),j)},o.keyDownHandlers={ArrowDown:function(x){var _=this;if(x.preventDefault(),this.getState().isOpen){var $=x.shiftKey?5:1;this.moveHighlightedIndex($,{type:Mi})}else this.internalSetState({isOpen:!0,type:Mi},function(){var M=_.getItemCount();if(M>0){var D=_.getState(),N=D.highlightedIndex,j=Rr(1,N,M,function(K){return _.getItemNodeFromIndex(K)});_.setHighlightedIndex(j,{type:Mi})}})},ArrowUp:function(x){var _=this;if(x.preventDefault(),this.getState().isOpen){var $=x.shiftKey?-5:-1;this.moveHighlightedIndex($,{type:Oi})}else this.internalSetState({isOpen:!0,type:Oi},function(){var M=_.getItemCount();if(M>0){var D=_.getState(),N=D.highlightedIndex,j=Rr(-1,N,M,function(K){return _.getItemNodeFromIndex(K)});_.setHighlightedIndex(j,{type:Oi})}})},Enter:function(x){if(x.which!==229){var _=this.getState(),$=_.isOpen,M=_.highlightedIndex;if($&&M!=null){x.preventDefault();var D=this.items[M],N=this.getItemNodeFromIndex(M);if(D==null||N&&N.hasAttribute("disabled"))return;this.selectHighlightedItem({type:qv})}}},Escape:function(x){x.preventDefault(),this.reset(ie({type:Kv},!this.state.isOpen&&{selectedItem:null,inputValue:""}))}},o.buttonKeyDownHandlers=ie({},o.keyDownHandlers,{" ":function(x){x.preventDefault(),this.toggleMenu({type:eg})}}),o.inputKeyDownHandlers=ie({},o.keyDownHandlers,{Home:function(x){var _=this,$=this.getState(),M=$.isOpen;if(M){x.preventDefault();var D=this.getItemCount();if(!(D<=0||!M)){var N=Nr(1,0,D,function(j){return _.getItemNodeFromIndex(j)},!1);this.setHighlightedIndex(N,{type:Xv})}}},End:function(x){var _=this,$=this.getState(),M=$.isOpen;if(M){x.preventDefault();var D=this.getItemCount();if(!(D<=0||!M)){var N=Nr(-1,D-1,D,function(j){return _.getItemNodeFromIndex(j)},!1);this.setHighlightedIndex(N,{type:Gv})}}}}),o.getToggleButtonProps=function(m){var x=m===void 0?{}:m,_=x.onClick;x.onPress;var $=x.onKeyDown,M=x.onKeyUp,D=x.onBlur,N=zt(x,fR),j=o.getState(),K=j.isOpen,V={onClick:wt(_,o.buttonHandleClick),onKeyDown:wt($,o.buttonHandleKeyDown),onKeyUp:wt(M,o.buttonHandleKeyUp),onBlur:wt(D,o.buttonHandleBlur)},P=N.disabled?{}:V;return ie({type:"button",role:"button","aria-label":K?"close menu":"open menu","aria-haspopup":!0,"data-toggle":!0},P,N)},o.buttonHandleKeyUp=function(m){m.preventDefault()},o.buttonHandleKeyDown=function(m){var x=zo(m);o.buttonKeyDownHandlers[x]&&o.buttonKeyDownHandlers[x].call(Od(o),m)},o.buttonHandleClick=function(m){m.preventDefault(),o.props.environment.document.activeElement===o.props.environment.document.body&&m.target.focus(),process.env.NODE_ENV==="test"?o.toggleMenu({type:dc}):o.internalSetTimeout(function(){return o.toggleMenu({type:dc})})},o.buttonHandleBlur=function(m){var x=m.target;o.internalSetTimeout(function(){!o.isMouseDown&&(o.props.environment.document.activeElement==null||o.props.environment.document.activeElement.id!==o.inputId)&&o.props.environment.document.activeElement!==x&&o.reset({type:tg})})},o.getLabelProps=function(m){return ie({htmlFor:o.inputId,id:o.labelId},m)},o.getInputProps=function(m){var x=m===void 0?{}:m,_=x.onKeyDown,$=x.onBlur,M=x.onChange,D=x.onInput;x.onChangeText;var N=zt(x,pR),j,K={};j="onChange";var V=o.getState(),P=V.inputValue,v=V.isOpen,C=V.highlightedIndex;if(!N.disabled){var I;K=(I={},I[j]=wt(M,D,o.inputHandleChange),I.onKeyDown=wt(_,o.inputHandleKeyDown),I.onBlur=wt($,o.inputHandleBlur),I)}return ie({"aria-autocomplete":"list","aria-activedescendant":v&&typeof C=="number"&&C>=0?o.getItemId(C):null,"aria-controls":v?o.menuId:null,"aria-labelledby":N&&N["aria-label"]?void 0:o.labelId,autoComplete:"off",value:P,id:o.inputId},K,N)},o.inputHandleKeyDown=function(m){var x=zo(m);x&&o.inputKeyDownHandlers[x]&&o.inputKeyDownHandlers[x].call(Od(o),m)},o.inputHandleChange=function(m){o.internalSetState({type:Jv,isOpen:!0,inputValue:m.target.value,highlightedIndex:o.props.defaultHighlightedIndex})},o.inputHandleBlur=function(){o.internalSetTimeout(function(){var m=o.props.environment.document&&!!o.props.environment.document.activeElement&&!!o.props.environment.document.activeElement.dataset&&o.props.environment.document.activeElement.dataset.toggle&&o._rootNode&&o._rootNode.contains(o.props.environment.document.activeElement);!o.isMouseDown&&!m&&o.reset({type:Qv})})},o.menuRef=function(m){o._menuNode=m},o.getMenuProps=function(m,x){var _,$=m===void 0?{}:m,M=$.refKey,D=M===void 0?"ref":M,N=$.ref,j=zt($,hR),K=x===void 0?{}:x,V=K.suppressRefError,P=V===void 0?!1:V;return o.getMenuProps.called=!0,o.getMenuProps.refKey=D,o.getMenuProps.suppressRefError=P,ie((_={},_[D]=ir(N,o.menuRef),_.role="listbox",_["aria-labelledby"]=j&&j["aria-label"]?null:o.labelId,_.id=o.menuId,_),j)},o.getItemProps=function(m){var x,_=m===void 0?{}:m,$=_.onMouseMove,M=_.onMouseDown,D=_.onClick;_.onPress;var N=_.index,j=_.item,K=j===void 0?process.env.NODE_ENV==="production"?void 0:sR("getItemProps","item"):j,V=zt(_,mR);N===void 0?(o.items.push(K),N=o.items.indexOf(K)):o.items[N]=K;var P="onClick",v=D,C=(x={onMouseMove:wt($,function(){N!==o.getState().highlightedIndex&&(o.setHighlightedIndex(N,{type:zv}),o.avoidScrolling=!0,o.internalSetTimeout(function(){return o.avoidScrolling=!1},250))}),onMouseDown:wt(M,function(k){k.preventDefault()})},x[P]=wt(v,function(){o.selectItemAtIndex(N,{type:Zv})}),x),I=V.disabled?{onMouseDown:C.onMouseDown}:C;return ie({id:o.getItemId(N),role:"option","aria-selected":o.getState().highlightedIndex===N},I,V)},o.clearItems=function(){o.items=[]},o.reset=function(m,x){m===void 0&&(m={}),m=Si(m),o.internalSetState(function(_){var $=_.selectedItem;return ie({isOpen:o.props.defaultIsOpen,highlightedIndex:o.props.defaultHighlightedIndex,inputValue:o.props.itemToString($)},m)},x)},o.toggleMenu=function(m,x){m===void 0&&(m={}),m=Si(m),o.internalSetState(function(_){var $=_.isOpen;return ie({isOpen:!$},$&&{highlightedIndex:o.props.defaultHighlightedIndex},m)},function(){var _=o.getState(),$=_.isOpen,M=_.highlightedIndex;$&&o.getItemCount()>0&&typeof M=="number"&&o.setHighlightedIndex(M,m),mp(x)()})},o.openMenu=function(m){o.internalSetState({isOpen:!0},m)},o.closeMenu=function(m){o.internalSetState({isOpen:!1},m)},o.updateStatus=$l(function(){var m=o.getState(),x=o.items[m.highlightedIndex],_=o.getItemCount(),$=o.props.getA11yStatusMessage(ie({itemToString:o.props.itemToString,previousResultCount:o.previousResultCount,resultCount:_,highlightedItem:x},m));o.previousResultCount=_,Rl($,o.props.environment.document)},200);var s=o.props,a=s.defaultHighlightedIndex,c=s.initialHighlightedIndex,l=c===void 0?a:c,d=s.defaultIsOpen,f=s.initialIsOpen,h=f===void 0?d:f,p=s.initialInputValue,y=p===void 0?"":p,E=s.initialSelectedItem,T=E===void 0?null:E,S=o.getState({highlightedIndex:l,isOpen:h,inputValue:y,selectedItem:T});return S.selectedItem!=null&&o.props.initialInputValue===void 0&&(S.inputValue=o.props.itemToString(S.selectedItem)),o.state=S,o}var r=n.prototype;return r.internalClearTimeouts=function(){this.timeoutIds.forEach(function(o){clearTimeout(o)}),this.timeoutIds=[]},r.getState=function(o){return o===void 0&&(o=this.state),Yo(o,this.props)},r.getItemCount=function(){var o=this.items.length;return this.itemCount!=null?o=this.itemCount:this.props.itemCount!==void 0&&(o=this.props.itemCount),o},r.getItemNodeFromIndex=function(o){return this.props.environment.document.getElementById(this.getItemId(o))},r.scrollHighlightedItemIntoView=function(){{var o=this.getItemNodeFromIndex(this.getState().highlightedIndex);this.props.scrollIntoView(o,this._menuNode)}},r.moveHighlightedIndex=function(o,s){var a=this,c=this.getItemCount(),l=this.getState(),d=l.highlightedIndex;if(c>0){var f=Rr(o,d,c,function(h){return a.getItemNodeFromIndex(h)});this.setHighlightedIndex(f,s)}},r.getStateAndHelpers=function(){var o=this.getState(),s=o.highlightedIndex,a=o.inputValue,c=o.selectedItem,l=o.isOpen,d=this.props.itemToString,f=this.id,h=this.getRootProps,p=this.getToggleButtonProps,y=this.getLabelProps,E=this.getMenuProps,T=this.getInputProps,S=this.getItemProps,m=this.openMenu,x=this.closeMenu,_=this.toggleMenu,$=this.selectItem,M=this.selectItemAtIndex,D=this.selectHighlightedItem,N=this.setHighlightedIndex,j=this.clearSelection,K=this.clearItems,V=this.reset,P=this.setItemCount,v=this.unsetItemCount,C=this.internalSetState;return{getRootProps:h,getToggleButtonProps:p,getLabelProps:y,getMenuProps:E,getInputProps:T,getItemProps:S,reset:V,openMenu:m,closeMenu:x,toggleMenu:_,selectItem:$,selectItemAtIndex:M,selectHighlightedItem:D,setHighlightedIndex:N,clearSelection:j,clearItems:K,setItemCount:P,unsetItemCount:v,setState:C,itemToString:d,id:f,highlightedIndex:s,inputValue:a,isOpen:l,selectedItem:c}},r.componentDidMount=function(){var o=this;process.env.NODE_ENV!=="production"&&this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&yp(this._menuNode,this.getMenuProps);{var s=function(){o.isMouseDown=!0},a=function(p){o.isMouseDown=!1;var y=ts(p.target,[o._rootNode,o._menuNode],o.props.environment);!y&&o.getState().isOpen&&o.reset({type:Yv},function(){return o.props.onOuterClick(o.getStateAndHelpers())})},c=function(){o.isTouchMove=!1},l=function(){o.isTouchMove=!0},d=function(p){var y=ts(p.target,[o._rootNode,o._menuNode],o.props.environment,!1);!o.isTouchMove&&!y&&o.getState().isOpen&&o.reset({type:rg},function(){return o.props.onOuterClick(o.getStateAndHelpers())})},f=this.props.environment;f.addEventListener("mousedown",s),f.addEventListener("mouseup",a),f.addEventListener("touchstart",c),f.addEventListener("touchmove",l),f.addEventListener("touchend",d),this.cleanup=function(){o.internalClearTimeouts(),o.updateStatus.cancel(),f.removeEventListener("mousedown",s),f.removeEventListener("mouseup",a),f.removeEventListener("touchstart",c),f.removeEventListener("touchmove",l),f.removeEventListener("touchend",d)}}},r.shouldScroll=function(o,s){var a=this.props.highlightedIndex===void 0?this.getState():this.props,c=a.highlightedIndex,l=s.highlightedIndex===void 0?o:s,d=l.highlightedIndex,f=c&&this.getState().isOpen&&!o.isOpen,h=c!==d;return f||h},r.componentDidUpdate=function(o,s){process.env.NODE_ENV!=="production"&&(Pl(this.state,o,this.props),this.getMenuProps.called&&!this.getMenuProps.suppressRefError&&yp(this._menuNode,this.getMenuProps)),es(this.props,"selectedItem")&&this.props.selectedItemChanged(o.selectedItem,this.props.selectedItem)&&this.internalSetState({type:ng,inputValue:this.props.itemToString(this.props.selectedItem)}),!this.avoidScrolling&&this.shouldScroll(s,o)&&this.scrollHighlightedItemIntoView(),this.updateStatus()},r.componentWillUnmount=function(){this.cleanup()},r.render=function(){var o=gp(this.props.children,en);this.clearItems(),this.getRootProps.called=!1,this.getRootProps.refKey=void 0,this.getRootProps.suppressRefError=void 0,this.getMenuProps.called=!1,this.getMenuProps.refKey=void 0,this.getMenuProps.suppressRefError=void 0,this.getLabelProps.called=!1,this.getInputProps.called=!1;var s=gp(o(this.getStateAndHelpers()));if(!s)return null;if(this.getRootProps.called||this.props.suppressRefError)return process.env.NODE_ENV!=="production"&&!this.getRootProps.suppressRefError&&!this.props.suppressRefError&&gR(s,this.getRootProps),s;if(Bv(s))return u.cloneElement(s,this.getRootProps(Hv(s)));if(process.env.NODE_ENV!=="production")throw new Error("downshift: If you return a non-DOM element, you must apply the getRootProps function")},n}(u.Component);return e.defaultProps={defaultHighlightedIndex:null,defaultIsOpen:!1,getA11yStatusMessage:Fv,itemToString:function(n){return n==null?"":(process.env.NODE_ENV!=="production"&&cR(n)&&!n.hasOwnProperty("toString")&&console.warn("downshift: An object was passed to the default implementation of `itemToString`. You should probably provide your own `itemToString` implementation. Please refer to the `itemToString` API documentation.","The object that was passed:",n),String(n))},onStateChange:en,onInputValueChange:en,onUserAction:en,onChange:en,onSelect:en,onOuterClick:en,selectedItemChanged:function(n,r){return n!==r},environment:typeof window>"u"?{}:window,stateReducer:function(n,r){return r},suppressRefError:!1,scrollIntoView:Vv},e.stateChangeTypes=uR,e}();process.env.NODE_ENV!=="production"&&(vR.propTypes={children:z.func,defaultHighlightedIndex:z.number,defaultIsOpen:z.bool,initialHighlightedIndex:z.number,initialSelectedItem:z.any,initialInputValue:z.string,initialIsOpen:z.bool,getA11yStatusMessage:z.func,itemToString:z.func,onChange:z.func,onSelect:z.func,onStateChange:z.func,onInputValueChange:z.func,onUserAction:z.func,onOuterClick:z.func,selectedItemChanged:z.func,stateReducer:z.func,itemCount:z.number,id:z.string,environment:z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})}),suppressRefError:z.bool,scrollIntoView:z.func,selectedItem:z.any,isOpen:z.bool,inputValue:z.string,highlightedIndex:z.number,labelId:z.string,inputId:z.string,menuId:z.string,getItemId:z.func});function yp(e,t){var n=t.refKey;e||console.error('downshift: The ref prop "'+n+'" from getMenuProps was not applied correctly on your menu element.')}function gR(e,t){var n=t.refKey,r=n!=="ref",i=!Bv(e);i&&!r&&!fp.isForwardRef(e)?console.error("downshift: You returned a non-DOM element. You must specify a refKey in getRootProps"):!i&&r&&console.error('downshift: You returned a DOM element. You should not specify a refKey in getRootProps. You specified "'+n+'"'),!fp.isForwardRef(e)&&!Hv(e)[n]&&console.error('downshift: You must apply the ref prop "'+n+'" from getRootProps onto your root element.')}var yR=["isInitialMount","highlightedIndex","items","environment"],og={highlightedIndex:-1,isOpen:!1,selectedItem:null,inputValue:""};function bR(e,t,n){var r=e.props,i=e.type,o={};Object.keys(t).forEach(function(s){wR(s,e,t,n),n[s]!==t[s]&&(o[s]=n[s])}),r.onStateChange&&Object.keys(o).length&&r.onStateChange(ie({type:i},o))}function wR(e,t,n,r){var i=t.props,o=t.type,s="on"+Il(e)+"Change";i[s]&&r[e]!==void 0&&r[e]!==n[e]&&i[s](ie({type:o},r))}function xR(e,t){return t.changes}function ER(e){var t=e.selectedItem,n=e.itemToString;return t?n(t)+" has been selected.":""}var CR=$l(function(e,t){Rl(e(),t)},200),_R=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?u.useLayoutEffect:u.useEffect;function TR(e){var t=e.id,n=t===void 0?"downshift-"+Lv():t,r=e.labelId,i=e.menuId,o=e.getItemId,s=e.toggleButtonId,a=e.inputId,c=u.useRef({labelId:r||n+"-label",menuId:i||n+"-menu",getItemId:o||function(l){return n+"-item-"+l},toggleButtonId:s||n+"-toggle-button",inputId:a||n+"-input"});return c.current}function ig(e,t,n,r){var i,o;if(e===void 0){if(t===void 0)throw new Error(r);i=n[t],o=t}else o=t===void 0?n.indexOf(e):t,i=e;return[i,o]}function SR(e){return e?String(e):""}function Il(e){return""+e.slice(0,1).toUpperCase()+e.slice(1)}function Al(e){var t=u.useRef(e);return t.current=e,t}function sg(e,t,n){var r=u.useRef(),i=u.useRef(),o=u.useCallback(function(h,p){i.current=p,h=Yo(h,p.props);var y=e(h,p),E=p.props.stateReducer(h,ie({},p,{changes:y}));return E},[e]),s=u.useReducer(o,t),a=s[0],c=s[1],l=Al(n),d=u.useCallback(function(h){return c(ie({props:l.current},h))},[l]),f=i.current;return u.useEffect(function(){f&&r.current&&r.current!==a&&bR(f,Yo(r.current,f.props),a),r.current=a},[a,n,f]),[a,d]}function $R(e,t,n){var r=sg(e,t,n),i=r[0],o=r[1];return[Yo(i,n),o]}var ko={itemToString:SR,stateReducer:xR,getA11ySelectionMessage:ER,scrollIntoView:Vv,environment:typeof window>"u"?{}:window};function gn(e,t,n){n===void 0&&(n=og);var r=e["default"+Il(t)];return r!==void 0?r:n[t]}function Po(e,t,n){n===void 0&&(n=og);var r=e[t];if(r!==void 0)return r;var i=e["initial"+Il(t)];return i!==void 0?i:gn(e,t,n)}function PR(e){var t=Po(e,"selectedItem"),n=Po(e,"isOpen"),r=Po(e,"highlightedIndex"),i=Po(e,"inputValue");return{highlightedIndex:r<0&&t&&n?e.items.indexOf(t):r,isOpen:n,selectedItem:t,inputValue:i}}function No(e,t,n){var r=e.items,i=e.initialHighlightedIndex,o=e.defaultHighlightedIndex,s=t.selectedItem,a=t.highlightedIndex;return r.length===0?-1:i!==void 0&&a===i?i:o!==void 0?o:s?r.indexOf(s):n===0?-1:n<0?r.length-1:0}function RR(e,t,n,r){var i=u.useRef({isMouseDown:!1,isTouchMove:!1});return u.useEffect(function(){if((n==null?void 0:n.addEventListener)!=null){var o=function(){i.current.isMouseDown=!0},s=function(f){i.current.isMouseDown=!1,e&&!ts(f.target,t.map(function(h){return h.current}),n)&&r()},a=function(){i.current.isTouchMove=!1},c=function(){i.current.isTouchMove=!0},l=function(f){e&&!i.current.isTouchMove&&!ts(f.target,t.map(function(h){return h.current}),n,!1)&&r()};return n.addEventListener("mousedown",o),n.addEventListener("mouseup",s),n.addEventListener("touchstart",a),n.addEventListener("touchmove",c),n.addEventListener("touchend",l),function(){n.removeEventListener("mousedown",o),n.removeEventListener("mouseup",s),n.removeEventListener("touchstart",a),n.removeEventListener("touchmove",c),n.removeEventListener("touchend",l)}}},[e,n]),i}var Dl=function(){return en};process.env.NODE_ENV!=="production"&&(Dl=function(){for(var t=u.useRef(!0),n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];var o=u.useRef(r.reduce(function(a,c){return a[c]={},a},{}));u.useEffect(function(){Object.keys(o.current).forEach(function(a){var c=o.current[a];if(t.current&&!Object.keys(c).length){console.error("downshift: You forgot to call the "+a+" getter function on your component / element.");return}var l=c.suppressRefError,d=c.refKey,f=c.elementRef;(!f||!f.current)&&!l&&console.error('downshift: The ref prop "'+d+'" from '+a+" was not applied correctly on your element.")}),t.current=!1});var s=u.useCallback(function(a,c,l,d){o.current[a]={suppressRefError:c,refKey:l,elementRef:d}},[]);return s});function bp(e,t,n){var r=n.isInitialMount,i=n.highlightedIndex,o=n.items,s=n.environment,a=zt(n,yR);u.useEffect(function(){r||CR(function(){return e(ie({highlightedIndex:i,highlightedItem:o[i],resultCount:o.length},a))},s.document)},t)}function IR(e){var t=e.highlightedIndex,n=e.isOpen,r=e.itemRefs,i=e.getItemNodeFromIndex,o=e.menuElement,s=e.scrollIntoView,a=u.useRef(!0);return _R(function(){t<0||!n||!Object.keys(r.current).length||(a.current===!1?a.current=!0:s(i(t),o))},[t]),a}var Ol=en;process.env.NODE_ENV!=="production"&&(Ol=function(t){var n=t.isInitialMount,r=t.props,i=t.state,o=u.useRef(r);u.useEffect(function(){n||(Pl(i,o.current,r),o.current=r)},[i,r,n])});function wp(e,t,n){var r;n===void 0&&(n=!0);var i=((r=e.items)==null?void 0:r.length)&&t>=0;return ie({isOpen:!1,highlightedIndex:-1},i&&ie({selectedItem:e.items[t],isOpen:gn(e,"isOpen"),highlightedIndex:gn(e,"highlightedIndex")},n&&{inputValue:e.itemToString(e.items[t])}))}function AR(e,t,n){var r=t.type,i=t.props,o;switch(r){case n.ItemMouseMove:o={highlightedIndex:t.disabled?-1:t.index};break;case n.MenuMouseLeave:o={highlightedIndex:-1};break;case n.ToggleButtonClick:case n.FunctionToggleMenu:o={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:No(i,e,0)};break;case n.FunctionOpenMenu:o={isOpen:!0,highlightedIndex:No(i,e,0)};break;case n.FunctionCloseMenu:o={isOpen:!1};break;case n.FunctionSetHighlightedIndex:o={highlightedIndex:t.highlightedIndex};break;case n.FunctionSetInputValue:o={inputValue:t.inputValue};break;case n.FunctionReset:o={highlightedIndex:gn(i,"highlightedIndex"),isOpen:gn(i,"isOpen"),selectedItem:gn(i,"selectedItem"),inputValue:gn(i,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return ie({},e,o)}z.array.isRequired,z.func,z.func,z.func,z.number,z.number,z.number,z.bool,z.bool,z.bool,z.any,z.any,z.any,z.string,z.string,z.string,z.func,z.string,z.func,z.func,z.func,z.func,z.func,z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})});function DR(e){var t=e.isOpen,n=e.resultCount,r=e.previousResultCount;return t?n?n!==r?"".concat(n," result").concat(n===1?" is":"s are"," available, use up and down arrow keys to navigate. Press Enter or Space Bar keys to select."):"":"No results are available.":""}dn(dn({},ko),{getA11yStatusMessage:DR});process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;process.env.NODE_ENV;var Ml=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_down__":0,kl=process.env.NODE_ENV!=="production"?"__input_keydown_arrow_up__":1,Nl=process.env.NODE_ENV!=="production"?"__input_keydown_escape__":2,jl=process.env.NODE_ENV!=="production"?"__input_keydown_home__":3,Vl=process.env.NODE_ENV!=="production"?"__input_keydown_end__":4,Ll=process.env.NODE_ENV!=="production"?"__input_keydown_page_up__":5,Fl=process.env.NODE_ENV!=="production"?"__input_keydown_page_down__":6,Bl=process.env.NODE_ENV!=="production"?"__input_keydown_enter__":7,Hl=process.env.NODE_ENV!=="production"?"__input_change__":8,ns=process.env.NODE_ENV!=="production"?"__input_blur__":9,Wl=process.env.NODE_ENV!=="production"?"__input_focus__":10,ag=process.env.NODE_ENV!=="production"?"__menu_mouse_leave__":11,cg=process.env.NODE_ENV!=="production"?"__item_mouse_move__":12,Ul=process.env.NODE_ENV!=="production"?"__item_click__":13,lg=process.env.NODE_ENV!=="production"?"__togglebutton_click__":14,ug=process.env.NODE_ENV!=="production"?"__function_toggle_menu__":15,dg=process.env.NODE_ENV!=="production"?"__function_open_menu__":16,fg=process.env.NODE_ENV!=="production"?"__function_close_menu__":17,pg=process.env.NODE_ENV!=="production"?"__function_set_highlighted_index__":18,Yl=process.env.NODE_ENV!=="production"?"__function_select_item__":19,hg=process.env.NODE_ENV!=="production"?"__function_set_input_value__":20,mg=process.env.NODE_ENV!=="production"?"__function_reset__":21,zl=process.env.NODE_ENV!=="production"?"__controlled_prop_updated_selected_item__":22,vg=Object.freeze({__proto__:null,InputKeyDownArrowDown:Ml,InputKeyDownArrowUp:kl,InputKeyDownEscape:Nl,InputKeyDownHome:jl,InputKeyDownEnd:Vl,InputKeyDownPageUp:Ll,InputKeyDownPageDown:Fl,InputKeyDownEnter:Bl,InputChange:Hl,InputBlur:ns,InputFocus:Wl,MenuMouseLeave:ag,ItemMouseMove:cg,ItemClick:Ul,ToggleButtonClick:lg,FunctionToggleMenu:ug,FunctionOpenMenu:dg,FunctionCloseMenu:fg,FunctionSetHighlightedIndex:pg,FunctionSelectItem:Yl,FunctionSetInputValue:hg,FunctionReset:mg,ControlledPropUpdatedSelectedItem:zl});function OR(e){var t=PR(e),n=t.selectedItem,r=t.inputValue;return r===""&&n&&e.defaultInputValue===void 0&&e.initialInputValue===void 0&&e.inputValue===void 0&&(r=e.itemToString(n)),ie({},t,{inputValue:r})}var MR={items:z.array.isRequired,itemToString:z.func,selectedItemChanged:z.func,getA11yStatusMessage:z.func,getA11ySelectionMessage:z.func,highlightedIndex:z.number,defaultHighlightedIndex:z.number,initialHighlightedIndex:z.number,isOpen:z.bool,defaultIsOpen:z.bool,initialIsOpen:z.bool,selectedItem:z.any,initialSelectedItem:z.any,defaultSelectedItem:z.any,inputValue:z.string,defaultInputValue:z.string,initialInputValue:z.string,id:z.string,labelId:z.string,menuId:z.string,getItemId:z.func,inputId:z.string,toggleButtonId:z.string,stateReducer:z.func,onSelectedItemChange:z.func,onHighlightedIndexChange:z.func,onStateChange:z.func,onIsOpenChange:z.func,onInputValueChange:z.func,environment:z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})})};function kR(e,t,n){var r=u.useRef(),i=sg(e,t,n),o=i[0],s=i[1];return u.useEffect(function(){es(n,"selectedItem")&&(n.selectedItemChanged(r.current,n.selectedItem)&&s({type:zl,inputValue:n.itemToString(n.selectedItem)}),r.current=o.selectedItem===r.current?n.selectedItem:o.selectedItem)},[o.selectedItem,n.selectedItem]),[Yo(o,n),s]}var gg=en;process.env.NODE_ENV!=="production"&&(gg=function(t,n){z.checkPropTypes(MR,t,"prop",n.name)});var NR=ie({},ko,{selectedItemChanged:function(t,n){return t!==n},getA11yStatusMessage:Fv});function jR(e,t){var n,r=t.type,i=t.props,o=t.altKey,s;switch(r){case Ul:s={isOpen:gn(i,"isOpen"),highlightedIndex:gn(i,"highlightedIndex"),selectedItem:i.items[t.index],inputValue:i.itemToString(i.items[t.index])};break;case Ml:e.isOpen?s={highlightedIndex:Rr(1,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!0)}:s={highlightedIndex:o&&e.selectedItem==null?-1:No(i,e,1,t.getItemNodeFromIndex),isOpen:i.items.length>=0};break;case kl:e.isOpen?o?s=wp(i,e.highlightedIndex):s={highlightedIndex:Rr(-1,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!0)}:s={highlightedIndex:No(i,e,-1,t.getItemNodeFromIndex),isOpen:i.items.length>=0};break;case Bl:s=wp(i,e.highlightedIndex);break;case Nl:s=ie({isOpen:!1,highlightedIndex:-1},!e.isOpen&&{selectedItem:null,inputValue:""});break;case Ll:s={highlightedIndex:Rr(-10,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!1)};break;case Fl:s={highlightedIndex:Rr(10,e.highlightedIndex,i.items.length,t.getItemNodeFromIndex,!1)};break;case jl:s={highlightedIndex:Nr(1,0,i.items.length,t.getItemNodeFromIndex,!1)};break;case Vl:s={highlightedIndex:Nr(-1,i.items.length-1,i.items.length,t.getItemNodeFromIndex,!1)};break;case ns:s=ie({isOpen:!1,highlightedIndex:-1},e.highlightedIndex>=0&&((n=i.items)==null?void 0:n.length)&&t.selectItem&&{selectedItem:i.items[e.highlightedIndex],inputValue:i.itemToString(i.items[e.highlightedIndex])});break;case Hl:s={isOpen:!0,highlightedIndex:gn(i,"highlightedIndex"),inputValue:t.inputValue};break;case Wl:s={isOpen:!0,highlightedIndex:No(i,e,0)};break;case Yl:s={selectedItem:t.selectedItem,inputValue:i.itemToString(t.selectedItem)};break;case zl:s={inputValue:t.inputValue};break;default:return AR(e,t,vg)}return ie({},e,s)}var VR=["onMouseLeave","refKey","ref"],LR=["item","index","refKey","ref","onMouseMove","onMouseDown","onClick","onPress","disabled"],FR=["onClick","onPress","refKey","ref"],BR=["onKeyDown","onChange","onInput","onFocus","onBlur","onChangeText","refKey","ref"];Jr.stateChangeTypes=vg;function Jr(e){e===void 0&&(e={}),gg(e,Jr);var t=ie({},NR,e),n=t.initialIsOpen,r=t.defaultIsOpen,i=t.items,o=t.scrollIntoView,s=t.environment,a=t.getA11yStatusMessage,c=t.getA11ySelectionMessage,l=t.itemToString,d=OR(t),f=kR(jR,d,t),h=f[0],p=f[1],y=h.isOpen,E=h.highlightedIndex,T=h.selectedItem,S=h.inputValue,m=u.useRef(null),x=u.useRef({}),_=u.useRef(null),$=u.useRef(null),M=u.useRef(!0),D=TR(t),N=u.useRef(),j=Al({state:h,props:t}),K=u.useCallback(function(B){return x.current[D.getItemId(B)]},[D]);bp(a,[y,E,S,i],ie({isInitialMount:M.current,previousResultCount:N.current,items:i,environment:s,itemToString:l},h)),bp(c,[T],ie({isInitialMount:M.current,previousResultCount:N.current,items:i,environment:s,itemToString:l},h));var V=IR({menuElement:m.current,highlightedIndex:E,isOpen:y,itemRefs:x,scrollIntoView:o,getItemNodeFromIndex:K});Ol({isInitialMount:M.current,props:t,state:h}),u.useEffect(function(){var B=n||r||y;B&&_.current&&_.current.focus()},[]),u.useEffect(function(){M.current||(N.current=i.length)});var P=RR(y,[_,m,$],s,function(){p({type:ns,selectItem:!1})}),v=Dl("getInputProps","getMenuProps");u.useEffect(function(){return M.current=!1,function(){M.current=!0}},[]),u.useEffect(function(){var B;if(!y)x.current={};else if(((B=s.document)==null?void 0:B.activeElement)!==_.current){var H;_==null||(H=_.current)==null||H.focus()}},[y,s]);var C=u.useMemo(function(){return{ArrowDown:function(H){H.preventDefault(),p({type:Ml,altKey:H.altKey,getItemNodeFromIndex:K})},ArrowUp:function(H){H.preventDefault(),p({type:kl,altKey:H.altKey,getItemNodeFromIndex:K})},Home:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:jl,getItemNodeFromIndex:K}))},End:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:Vl,getItemNodeFromIndex:K}))},Escape:function(H){var J=j.current.state;(J.isOpen||J.inputValue||J.selectedItem||J.highlightedIndex>-1)&&(H.preventDefault(),p({type:Nl}))},Enter:function(H){var J=j.current.state;!J.isOpen||H.which===229||(H.preventDefault(),p({type:Bl,getItemNodeFromIndex:K}))},PageUp:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:Ll,getItemNodeFromIndex:K}))},PageDown:function(H){j.current.state.isOpen&&(H.preventDefault(),p({type:Fl,getItemNodeFromIndex:K}))}}},[p,j,K]),I=u.useCallback(function(B){return ie({id:D.labelId,htmlFor:D.inputId},B)},[D]),k=u.useCallback(function(B,H){var J,ee=B===void 0?{}:B,te=ee.onMouseLeave,Z=ee.refKey,ge=Z===void 0?"ref":Z,Te=ee.ref,Ie=zt(ee,VR),Ae=H===void 0?{}:H,$e=Ae.suppressRefError,Ye=$e===void 0?!1:$e;return v("getMenuProps",Ye,ge,m),ie((J={},J[ge]=ir(Te,function(je){m.current=je}),J.id=D.menuId,J.role="listbox",J["aria-labelledby"]=Ie&&Ie["aria-label"]?void 0:""+D.labelId,J.onMouseLeave=wt(te,function(){p({type:ag})}),J),Ie)},[p,v,D]),U=u.useCallback(function(B){var H,J,ee=B===void 0?{}:B,te=ee.item,Z=ee.index,ge=ee.refKey,Te=ge===void 0?"ref":ge,Ie=ee.ref,Ae=ee.onMouseMove,$e=ee.onMouseDown,Ye=ee.onClick;ee.onPress;var je=ee.disabled,vt=zt(ee,LR),Xe=j.current,Rt=Xe.props,st=Xe.state,Ft=ig(te,Z,Rt.items,"Pass either item or index to getItemProps!"),Pe=Ft[1],Ot="onClick",gt=Ye,bn=function(){Pe!==st.highlightedIndex&&(V.current=!1,p({type:cg,index:Pe,disabled:je}))},Xt=function(){p({type:Ul,index:Pe})},Nt=function(Mt){return Mt.preventDefault()};return ie((H={},H[Te]=ir(Ie,function(Fe){Fe&&(x.current[D.getItemId(Pe)]=Fe)}),H.disabled=je,H.role="option",H["aria-selected"]=""+(Pe===st.highlightedIndex),H.id=D.getItemId(Pe),H),!je&&(J={},J[Ot]=wt(gt,Xt),J),{onMouseMove:wt(Ae,bn),onMouseDown:wt($e,Nt)},vt)},[p,j,V,D]),G=u.useCallback(function(B){var H,J=B===void 0?{}:B,ee=J.onClick;J.onPress;var te=J.refKey,Z=te===void 0?"ref":te,ge=J.ref,Te=zt(J,FR),Ie=j.current.state,Ae=function(){p({type:lg})};return ie((H={},H[Z]=ir(ge,function($e){$.current=$e}),H["aria-controls"]=D.menuId,H["aria-expanded"]=Ie.isOpen,H.id=D.toggleButtonId,H.tabIndex=-1,H),!Te.disabled&&ie({},{onClick:wt(ee,Ae)}),Te)},[p,j,D]),ue=u.useCallback(function(B,H){var J,ee=B===void 0?{}:B,te=ee.onKeyDown,Z=ee.onChange,ge=ee.onInput,Te=ee.onFocus,Ie=ee.onBlur;ee.onChangeText;var Ae=ee.refKey,$e=Ae===void 0?"ref":Ae,Ye=ee.ref,je=zt(ee,BR),vt=H===void 0?{}:H,Xe=vt.suppressRefError,Rt=Xe===void 0?!1:Xe;v("getInputProps",Rt,$e,_);var st=j.current.state,Ft=function(Mt){var Gt=zo(Mt);Gt&&C[Gt]&&C[Gt](Mt)},Pe=function(Mt){p({type:Hl,inputValue:Mt.target.value})},Ot=function(Mt){if(st.isOpen&&!P.current.isMouseDown){var Gt=Mt.relatedTarget===null&&s.document.activeElement!==s.document.body;p({type:ns,selectItem:!Gt})}},gt=function(){st.isOpen||p({type:Wl})},bn="onChange",Xt={};if(!je.disabled){var Nt;Xt=(Nt={},Nt[bn]=wt(Z,ge,Pe),Nt.onKeyDown=wt(te,Ft),Nt.onBlur=wt(Ie,Ot),Nt.onFocus=wt(Te,gt),Nt)}return ie((J={},J[$e]=ir(Ye,function(Fe){_.current=Fe}),J["aria-activedescendant"]=st.isOpen&&st.highlightedIndex>-1?D.getItemId(st.highlightedIndex):"",J["aria-autocomplete"]="list",J["aria-controls"]=D.menuId,J["aria-expanded"]=st.isOpen,J["aria-labelledby"]=je&&je["aria-label"]?void 0:""+D.labelId,J.autoComplete="off",J.id=D.inputId,J.role="combobox",J.value=st.inputValue,J),Xt,je)},[v,j,D,C,p,P,s]),W=u.useCallback(function(){p({type:ug})},[p]),L=u.useCallback(function(){p({type:fg})},[p]),oe=u.useCallback(function(){p({type:dg})},[p]),X=u.useCallback(function(B){p({type:pg,highlightedIndex:B})},[p]),q=u.useCallback(function(B){p({type:Yl,selectedItem:B})},[p]),ne=u.useCallback(function(B){p({type:hg,inputValue:B})},[p]),ae=u.useCallback(function(){p({type:mg})},[p]);return{getItemProps:U,getLabelProps:I,getMenuProps:k,getInputProps:ue,getToggleButtonProps:G,toggleMenu:W,openMenu:oe,closeMenu:L,setHighlightedIndex:X,setInputValue:ne,selectItem:q,reset:ae,highlightedIndex:E,isOpen:y,selectedItem:T,inputValue:S}}var yg={activeIndex:-1,selectedItems:[]};function xp(e,t){return Po(e,t,yg)}function Ep(e,t){return gn(e,t,yg)}function HR(e){var t=xp(e,"activeIndex"),n=xp(e,"selectedItems");return{activeIndex:t,selectedItems:n}}function Cp(e){if(e.shiftKey||e.metaKey||e.ctrlKey||e.altKey)return!1;var t=e.target;return!(t instanceof HTMLInputElement&&t.value!==""&&(t.selectionStart!==0||t.selectionEnd!==0))}function WR(e){var t=e.removedSelectedItem,n=e.itemToString;return n(t)+" has been removed."}var UR={selectedItems:z.array,initialSelectedItems:z.array,defaultSelectedItems:z.array,itemToString:z.func,getA11yRemovalMessage:z.func,stateReducer:z.func,activeIndex:z.number,initialActiveIndex:z.number,defaultActiveIndex:z.number,onActiveIndexChange:z.func,onSelectedItemsChange:z.func,keyNavigationNext:z.string,keyNavigationPrevious:z.string,environment:z.shape({addEventListener:z.func,removeEventListener:z.func,document:z.shape({getElementById:z.func,activeElement:z.any,body:z.any})})},YR={itemToString:ko.itemToString,stateReducer:ko.stateReducer,environment:ko.environment,getA11yRemovalMessage:WR,keyNavigationNext:"ArrowRight",keyNavigationPrevious:"ArrowLeft"},bg=en;process.env.NODE_ENV!=="production"&&(bg=function(t,n){z.checkPropTypes(UR,t,"prop",n.name)});var Kl=process.env.NODE_ENV!=="production"?"__selected_item_click__":0,ql=process.env.NODE_ENV!=="production"?"__selected_item_keydown_delete__":1,Xl=process.env.NODE_ENV!=="production"?"__selected_item_keydown_backspace__":2,Gl=process.env.NODE_ENV!=="production"?"__selected_item_keydown_navigation_next__":3,Zl=process.env.NODE_ENV!=="production"?"__selected_item_keydown_navigation_previous__":4,Ql=process.env.NODE_ENV!=="production"?"__dropdown_keydown_navigation_previous__":5,Jl=process.env.NODE_ENV!=="production"?"__dropdown_keydown_backspace__":6,eu=process.env.NODE_ENV!=="production"?"__dropdown_click__":7,tu=process.env.NODE_ENV!=="production"?"__function_add_selected_item__":8,nu=process.env.NODE_ENV!=="production"?"__function_remove_selected_item__":9,ru=process.env.NODE_ENV!=="production"?"__function_set_selected_items__":10,ou=process.env.NODE_ENV!=="production"?"__function_set_active_index__":11,iu=process.env.NODE_ENV!=="production"?"__function_reset__":12,zR=Object.freeze({__proto__:null,SelectedItemClick:Kl,SelectedItemKeyDownDelete:ql,SelectedItemKeyDownBackspace:Xl,SelectedItemKeyDownNavigationNext:Gl,SelectedItemKeyDownNavigationPrevious:Zl,DropdownKeyDownNavigationPrevious:Ql,DropdownKeyDownBackspace:Jl,DropdownClick:eu,FunctionAddSelectedItem:tu,FunctionRemoveSelectedItem:nu,FunctionSetSelectedItems:ru,FunctionSetActiveIndex:ou,FunctionReset:iu});function KR(e,t){var n=t.type,r=t.index,i=t.props,o=t.selectedItem,s=e.activeIndex,a=e.selectedItems,c;switch(n){case Kl:c={activeIndex:r};break;case Zl:c={activeIndex:s-1<0?0:s-1};break;case Gl:c={activeIndex:s+1>=a.length?-1:s+1};break;case Xl:case ql:{if(s<0)break;var l=s;a.length===1?l=-1:s===a.length-1&&(l=a.length-2),c=ie({selectedItems:[].concat(a.slice(0,s),a.slice(s+1))},{activeIndex:l});break}case Ql:c={activeIndex:a.length-1};break;case Jl:c={selectedItems:a.slice(0,a.length-1)};break;case tu:c={selectedItems:[].concat(a,[o])};break;case eu:c={activeIndex:-1};break;case nu:{var d=s,f=a.indexOf(o);if(f<0)break;a.length===1?d=-1:f===a.length-1&&(d=a.length-2),c={selectedItems:[].concat(a.slice(0,f),a.slice(f+1)),activeIndex:d};break}case ru:{var h=t.selectedItems;c={selectedItems:h};break}case ou:{var p=t.activeIndex;c={activeIndex:p};break}case iu:c={activeIndex:Ep(i,"activeIndex"),selectedItems:Ep(i,"selectedItems")};break;default:throw new Error("Reducer called without proper action type.")}return ie({},e,c)}var qR=["refKey","ref","onClick","onKeyDown","selectedItem","index"],XR=["refKey","ref","onKeyDown","onClick","preventKeyAction"];su.stateChangeTypes=zR;function su(e){e===void 0&&(e={}),bg(e,su);var t=ie({},YR,e),n=t.getA11yRemovalMessage,r=t.itemToString,i=t.environment,o=t.keyNavigationNext,s=t.keyNavigationPrevious,a=$R(KR,HR(t),t),c=a[0],l=a[1],d=c.activeIndex,f=c.selectedItems,h=u.useRef(!0),p=u.useRef(null),y=u.useRef(f),E=u.useRef();E.current=[];var T=Al({state:c,props:t});u.useEffect(function(){if(!h.current){if(f.length<y.current.length){var V=y.current.find(function(P){return f.indexOf(P)<0});Rl(n({itemToString:r,resultCount:f.length,removedSelectedItem:V,activeIndex:d,activeSelectedItem:f[d]}),i.document)}y.current=f}},[f.length]),u.useEffect(function(){h.current||(d===-1&&p.current?p.current.focus():E.current[d]&&E.current[d].focus())},[d]),Ol({isInitialMount:h.current,props:t,state:c});var S=Dl("getDropdownProps");u.useEffect(function(){return h.current=!1,function(){h.current=!0}},[]);var m=u.useMemo(function(){var V;return V={},V[s]=function(){l({type:Zl})},V[o]=function(){l({type:Gl})},V.Delete=function(){l({type:ql})},V.Backspace=function(){l({type:Xl})},V},[l,o,s]),x=u.useMemo(function(){var V;return V={},V[s]=function(P){Cp(P)&&l({type:Ql})},V.Backspace=function(v){Cp(v)&&l({type:Jl})},V},[l,s]),_=u.useCallback(function(V){var P,v=V===void 0?{}:V,C=v.refKey,I=C===void 0?"ref":C,k=v.ref,U=v.onClick,G=v.onKeyDown,ue=v.selectedItem,W=v.index,L=zt(v,qR),oe=T.current.state,X=ig(ue,W,oe.selectedItems,"Pass either item or index to getSelectedItemProps!"),q=X[1],ne=q>-1&&q===oe.activeIndex,ae=function(){l({type:Kl,index:q})},B=function(J){var ee=zo(J);ee&&m[ee]&&m[ee](J)};return ie((P={},P[I]=ir(k,function(H){H&&E.current.push(H)}),P.tabIndex=ne?0:-1,P.onClick=wt(U,ae),P.onKeyDown=wt(G,B),P),L)},[l,T,m]),$=u.useCallback(function(V,P){var v,C=V===void 0?{}:V,I=C.refKey,k=I===void 0?"ref":I,U=C.ref,G=C.onKeyDown,ue=C.onClick,W=C.preventKeyAction,L=W===void 0?!1:W,oe=zt(C,XR),X=P===void 0?{}:P,q=X.suppressRefError,ne=q===void 0?!1:q;S("getDropdownProps",ne,k,p);var ae=function(J){var ee=zo(J);ee&&x[ee]&&x[ee](J)},B=function(){l({type:eu})};return ie((v={},v[k]=ir(U,function(H){H&&(p.current=H)}),v),!L&&{onKeyDown:wt(G,ae),onClick:wt(ue,B)},oe)},[l,x,S]),M=u.useCallback(function(V){l({type:tu,selectedItem:V})},[l]),D=u.useCallback(function(V){l({type:nu,selectedItem:V})},[l]),N=u.useCallback(function(V){l({type:ru,selectedItems:V})},[l]),j=u.useCallback(function(V){l({type:ou,activeIndex:V})},[l]),K=u.useCallback(function(){l({type:iu})},[l]);return{getSelectedItemProps:_,getDropdownProps:$,addSelectedItem:M,removeSelectedItem:D,setSelectedItems:N,setActiveIndex:j,reset:K,selectedItems:f,activeIndex:d}}var GR="jbnkvn0",_p=ft({defaultClassName:"jbnkvn7",variantClassNames:{highlighted:{true:"jbnkvn8"},selected:{true:"jbnkvn9"},multiSelected:{true:"jbnkvna"},isDisabled:{true:"jbnkvnb"}},defaultVariants:{},compoundVariants:[]}),Tp="jbnkvn6",ZR="jbnkvn1",QR=ft({defaultClassName:"jbnkvn2",variantClassNames:{isMobile:{true:"jbnkvn3",false:"jbnkvn4"}},defaultVariants:{isMobile:!0},compoundVariants:[]}),JR="jbnkvn5",Sp="jbnkvnc";const wg=u.createContext(void 0),eI=({children:e,contextValue:t})=>O.jsx(wg.Provider,{value:t,children:e}),au=()=>{const e=u.useContext(wg);if(e===void 0)throw new Error("useSelectProvider must be used within a SelectProvider");return e},xg=({children:e,renderer:t})=>{const{getMenuProps:n}=au();return t?t({children:e,defaultClassName:Tp,innerProps:n()}):O.jsx("div",{className:Tp,...n(),children:e})};xg.defaultProps={renderer:void 0};const Eg=({renderer:e,item:t,itemIndex:n})=>{const{isMulti:r,selectedItem:i,multipleSelectedItems:o,highlightedIndex:s,getItemProps:a,onClickItem:c}=au(),l=s===n,d=i===t&&!r,f=r&&o.includes(t)||!1,h=a({item:t,index:n,disabled:t.isDisabled,onClick:c});return e?e({defaultClassName:_p({highlighted:s===n,selected:i===t&&!r,multiSelected:o.includes(t),isDisabled:t.isDisabled}),innerProps:h,isMulti:r,item:t,itemIndex:n,isHighlighted:l,isSelected:d,isChecked:f}):O.jsxs("div",{className:_p({highlighted:l,selected:d,multiSelected:f,isDisabled:t.isDisabled}),...h,children:[O.jsx("span",{children:t.label}),r&&o.includes(t)&&O.jsx(_c,{size:16,color:Et.theme.colors.greenAccent1,"data-test-id":""})]},t.value)};Eg.defaultProps={renderer:void 0};const Cg=({renderer:e,...t})=>{const{formState:n,isOpen:r,getToggleButtonProps:i,isDisabled:o}=au();if(e)return e({innerProps:i(),defaultClassName:Sp,isOpen:r});const s=n==="disabled"?Et.theme.colors.black:Et.theme.colors.grey1;return O.jsx("div",{className:Sp,...i({disabled:o}),"data-disabled":o,children:r?O.jsx(Tc,{color:s,...t}):O.jsx(Lo,{color:s,...t})})};Cg.defaultProps={renderer:void 0,"data-test-id":"CT_Component_IconChev"};const to=u.forwardRef(({options:e,value:t,label:n,onChange:r,isLoading:i,components:o,required:s,containerStyles:a,isMulti:c,isReadOnly:l,isMobile:d,onClickItem:f,...h},p)=>{const{addonLeft:y,addonRight:E,helperTextLeft:T,helperTextRight:S,isError:m,errorMessage:x,isDisabled:_,isValid:$}=h,[M,D]=u.useState(e),N=kc({isError:m,isDisabled:_,isValid:$}),j=u.useRef(null),{removeSelectedItem:K,selectedItems:V,addSelectedItem:P,getDropdownProps:v}=su({initialSelectedItems:c&&t?t:[],onSelectedItemsChange(B){c&&r(B.selectedItems)}}),C=u.useMemo(()=>V.length,[V]),I=u.useCallback(B=>{let H=B;(c&&!d||l)&&(H="");const J=new RegExp(H.toLowerCase());return e.filter(ee=>J.test(ee.label.toLowerCase()))},[e]),{isOpen:k,getToggleButtonProps:U,getLabelProps:G,getMenuProps:ue,getInputProps:W,highlightedIndex:L,getItemProps:oe,selectedItem:X,openMenu:q,closeMenu:ne}=Jr({items:M,initialSelectedItem:c?void 0:t,onInputValueChange:({inputValue:B})=>{D(I(B||""))},itemToString(B){return B?B.label:""},onSelectedItemChange(B){var H;c||(r(B.selectedItem),l&&((H=j.current)==null||H.blur()),ne())},stateReducer:(B,H)=>{const{changes:J,type:ee}=H,te=M.find((Z,ge)=>ge===B.highlightedIndex);switch(ee){case Jr.stateChangeTypes.InputKeyDownEnter:case Jr.stateChangeTypes.ItemClick:if(c){let Z=C;return V.includes(te)?(Z-=1,K(te)):(Z+=1,P(te)),{...J,isOpen:!0,highlightedIndex:B.highlightedIndex,inputValue:!d&&Z>0?`${Z} items selected`:""}}return{...J,isOpen:!1,highlightedIndex:B.highlightedIndex,inputValue:J.inputValue};case Jr.stateChangeTypes.InputBlur:{let Z=J.inputValue;return c&&!d&&(C>0?Z=`${C} items selected`:Z=""),{...J,inputValue:Z}}default:return J}}});u.useImperativeHandle(p,()=>j.current);const ae={isOpen:k,formState:N,selectedItem:X,multipleSelectedItems:V,isMulti:c,isDisabled:_,totalSelected:C,highlightedIndex:L,getMenuProps:ue,getItemProps:oe,getToggleButtonProps:U,onClickItem:f};return O.jsx(eI,{contextValue:ae,children:O.jsxs(ht,{position:"relative",w:"$full",children:[O.jsxs(po,{addonLeft:y,addonRight:E,helperTextLeft:T,helperTextRight:S,isError:m,errorMessage:x,isDisabled:_,isValid:$,inputAreaClassName:GR,children:[O.jsxs("div",{className:ZR,children:[O.jsx("input",{"data-test-id":h["data-test-id"],...W(v({preventKeyAction:k,ref:j,placeholder:n,readOnly:l,disabled:_,className:QR({isMobile:d}),onClick:()=>{k||q()}}))}),d&&c&&O.jsx("div",{className:JR,children:C>0?`${C} items selected`:""}),d&&O.jsx(ni,{isSelect:!0,isError:m,isDisabled:_,required:s,...G(),children:n})]}),O.jsx(Cg,{renderer:o==null?void 0:o.Toggle})]}),k&&O.jsx(xg,{renderer:o==null?void 0:o.List,children:M.map((B,H)=>O.jsx(Eg,{renderer:o==null?void 0:o.ListItem,itemIndex:H,item:B}))})]})})});to.displayName="Select";to.defaultProps={required:!1,isLoading:!1,isMulti:void 0,isReadOnly:!1,isMobile:!1,containerStyles:void 0,components:void 0,onClickItem:void 0,"data-test-id":void 0};const _g=e=>{const t=`0${e}`;return t.substring(t.length-2,t.length)},tI=Array.from({length:31},(e,t)=>({label:_g(t+1),value:String(t+1),isDisabled:!1})),rs=["January","February","March","April","May","June","July","August","September","October","November","December"],nI=rs.map(e=>({label:e,value:e,isDisabled:!1})),rI=e=>{const t=e?new Date(e).getFullYear():new Date().getFullYear();return Array.from({length:101},(n,r)=>({label:String(t-r),value:String(t-r),isDisabled:!1}))},$a=(e,t)=>{if(t){const n=new Date(t);if(e==="date")return{label:_g(n.getDate()),value:n.getDate().toString()};if(e==="month")return{label:rs[n.getMonth()],value:rs[n.getMonth()]};if(e==="year"){const r=n.getFullYear().toString();return{label:r,value:r}}}},jo=e=>rs.findIndex(t=>t===e),$p=(e,t)=>new Date(e,jo(t)+1,0).getDate(),oI=({date:e,month:t,year:n,maxDate:r})=>{const i=r?new Date(r):new Date;return i.setHours(0,0,0,0),e&&t&&n&&e<=$p(n,t)&&i>new Date(n,jo(t),e,0,0,0,0)?!0:e&&t&&!n?jo(t)===1?e<=29:e<=$p(0,t):!e&&t&&n?n===i.getFullYear()?jo(t)<=i.getMonth():!0:e&&!t&&n?i.getMonth()===0&&n===i.getFullYear()?e<i.getDate():!0:!1},Tg=({title:e,maxDate:t,isMobile:n,defaultDate:r,onSaveDate:i,onClose:o,isOpen:s,buttonText:a,errorMessage:c,...l})=>{const[d,f]=u.useState(),[h,p]=u.useState(),[y,E]=u.useState(),T=u.useRef(null),S=()=>{f(void 0),p(void 0),E(void 0)},m=u.useMemo(()=>{if(s){if(d)return d;if(r)return $a("date",r)}},[r,d,s]),x=u.useMemo(()=>{if(s){if(h)return h;if(r)return $a("month",r)}},[r,h,s]),_=u.useMemo(()=>{if(s){if(y)return y;if(r)return $a("year",r)}},[r,y,s]),$=u.useMemo(()=>m||x||_?oI({date:m?Number(m==null?void 0:m.value):0,month:x?x.value:"",year:_?Number(_.value):0,maxDate:t}):!1,[m,x,_,t]),M=m&&x&&!_&&!$,D=m&&!x&&_&&!$,N=!m&&x&&_&&!$,j=m&&x&&_&&!$,K=()=>O.jsx(ht,{as:"button",ref:T,"data-test-id":"",position:"absolute",width:"$1",height:"$1",bottom:"$0",right:"$0",backgroundColor:"$white",border:"$none",children:O.jsx(ht,{display:"none"})}),V=()=>{T.current&&T.current.focus()};return O.jsx(ei,{...l,isOpen:s,onClose:()=>{o==null||o(),S()},children:O.jsxs(Ir,{gap:"$24",children:[O.jsxs(Ir,{gap:"$8",children:[O.jsx(ht,{height:"$40",children:O.jsx(ti,{children:e})}),O.jsxs(Ir,{children:[O.jsxs(Lt,{gap:"$12",px:"$2",mb:"$4",mt:"$8",children:[O.jsx(to,{isReadOnly:!0,name:"date",label:"Date",value:m,isMobile:n,options:tI,onClickItem:V,onChange:f,isError:M||D||j,"data-test-id":"CT_Component_SelectPicker_dateField"}),O.jsx(to,{isReadOnly:!0,name:"month",label:"Month",value:x,isMobile:n,options:nI,onClickItem:V,onChange:p,isError:N||M||j,"data-test-id":"CT_Component_SelectPicker_monthField"}),O.jsx(to,{isReadOnly:!0,name:"year",label:"Year",value:_,isMobile:n,options:rI(t),onClickItem:V,onChange:E,isError:N||D||j,"data-test-id":"CT_Component_SelectPicker_yearField"})]}),(j||N||D||M)&&O.jsx(Kt,{px:"$2",color:"$redAccent1",fontSize:"$caption",lineHeight:"$16",fontWeight:"$medium",children:c})]})]}),K(),O.jsx(co,{onClick:()=>{i(new Date(Number(_==null?void 0:_.value),jo(x==null?void 0:x.value),Number(m==null?void 0:m.value))),S()},isDisabled:!_||!x||!m||!$,"data-test-id":"CT_Component_SelectPicker_buttonSave",type:"button",children:a})]})})};Tg.defaultProps={title:"Date of birth",isMobile:!1,defaultDate:void 0,maxDate:void 0,buttonText:"Confirm",errorMessage:"Invalid date of birth"};const Pa="rovingFocusGroup.onEntryFocus",iI={bubbles:!1,cancelable:!0},cu="RovingFocusGroup",[fc,Sg,sI]=os(cu),[aI,$g]=sn(cu,[sI]),[cI,lI]=aI(cu),uI=u.forwardRef((e,t)=>u.createElement(fc.Provider,{scope:e.__scopeRovingFocusGroup},u.createElement(fc.Slot,{scope:e.__scopeRovingFocusGroup},u.createElement(dI,ie({},e,{ref:t}))))),dI=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:o,currentTabStopId:s,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:c,onEntryFocus:l,...d}=e,f=u.useRef(null),h=Qe(t,f),p=is(o),[y=null,E]=pn({prop:s,defaultProp:a,onChange:c}),[T,S]=u.useState(!1),m=qt(l),x=Sg(n),_=u.useRef(!1),[$,M]=u.useState(0);return u.useEffect(()=>{const D=f.current;if(D)return D.addEventListener(Pa,m),()=>D.removeEventListener(Pa,m)},[m]),u.createElement(cI,{scope:n,orientation:r,dir:p,loop:i,currentTabStopId:y,onItemFocus:u.useCallback(D=>E(D),[E]),onItemShiftTab:u.useCallback(()=>S(!0),[]),onFocusableItemAdd:u.useCallback(()=>M(D=>D+1),[]),onFocusableItemRemove:u.useCallback(()=>M(D=>D-1),[])},u.createElement(He.div,ie({tabIndex:T||$===0?-1:0,"data-orientation":r},d,{ref:h,style:{outline:"none",...e.style},onMouseDown:De(e.onMouseDown,()=>{_.current=!0}),onFocus:De(e.onFocus,D=>{const N=!_.current;if(D.target===D.currentTarget&&N&&!T){const j=new CustomEvent(Pa,iI);if(D.currentTarget.dispatchEvent(j),!j.defaultPrevented){const K=x().filter(I=>I.focusable),V=K.find(I=>I.active),P=K.find(I=>I.id===y),C=[V,P,...K].filter(Boolean).map(I=>I.ref.current);Pg(C)}}_.current=!1}),onBlur:De(e.onBlur,()=>S(!1))})))}),fI="RovingFocusGroupItem",pI=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:o,...s}=e,a=Bn(),c=o||a,l=lI(fI,n),d=l.currentTabStopId===c,f=Sg(n),{onFocusableItemAdd:h,onFocusableItemRemove:p}=l;return u.useEffect(()=>{if(r)return h(),()=>p()},[r,h,p]),u.createElement(fc.ItemSlot,{scope:n,id:c,focusable:r,active:i},u.createElement(He.span,ie({tabIndex:d?0:-1,"data-orientation":l.orientation},s,{ref:t,onMouseDown:De(e.onMouseDown,y=>{r?l.onItemFocus(c):y.preventDefault()}),onFocus:De(e.onFocus,()=>l.onItemFocus(c)),onKeyDown:De(e.onKeyDown,y=>{if(y.key==="Tab"&&y.shiftKey){l.onItemShiftTab();return}if(y.target!==y.currentTarget)return;const E=vI(y,l.orientation,l.dir);if(E!==void 0){y.preventDefault();let S=f().filter(m=>m.focusable).map(m=>m.ref.current);if(E==="last")S.reverse();else if(E==="prev"||E==="next"){E==="prev"&&S.reverse();const m=S.indexOf(y.currentTarget);S=l.loop?gI(S,m+1):S.slice(m+1)}setTimeout(()=>Pg(S))}})})))}),hI={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function mI(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function vI(e,t,n){const r=mI(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return hI[r]}function Pg(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function gI(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const yI=uI,bI=pI,Rg="Radio",[wI,Ig]=sn(Rg),[xI,EI]=wI(Rg),CI=u.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:i=!1,required:o,disabled:s,value:a="on",onCheck:c,...l}=e,[d,f]=u.useState(null),h=Qe(t,E=>f(E)),p=u.useRef(!1),y=d?!!d.closest("form"):!0;return u.createElement(xI,{scope:n,checked:i,disabled:s},u.createElement(He.button,ie({type:"button",role:"radio","aria-checked":i,"data-state":Ag(i),"data-disabled":s?"":void 0,disabled:s,value:a},l,{ref:h,onClick:De(e.onClick,E=>{i||c==null||c(),y&&(p.current=E.isPropagationStopped(),p.current||E.stopPropagation())})})),y&&u.createElement(SI,{control:d,bubbles:!p.current,name:r,value:a,checked:i,required:o,disabled:s,style:{transform:"translateX(-100%)"}}))}),_I="RadioIndicator",TI=u.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...i}=e,o=EI(_I,n);return u.createElement(hr,{present:r||o.checked},u.createElement(He.span,ie({"data-state":Ag(o.checked),"data-disabled":o.disabled?"":void 0},i,{ref:t})))}),SI=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,o=u.useRef(null),s=ms(n),a=ps(t);return u.useEffect(()=>{const c=o.current,l=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(l,"checked").set;if(s!==n&&f){const h=new Event("click",{bubbles:r});f.call(c,n),c.dispatchEvent(h)}},[s,n,r]),u.createElement("input",ie({type:"radio","aria-hidden":!0,defaultChecked:n},i,{tabIndex:-1,ref:o,style:{...e.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function Ag(e){return e?"checked":"unchecked"}const $I=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Dg="RadioGroup",[PI,CD]=sn(Dg,[$g,Ig]),Og=$g(),Mg=Ig(),[RI,II]=PI(Dg),AI=u.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:i,value:o,required:s=!1,disabled:a=!1,orientation:c,dir:l,loop:d=!0,onValueChange:f,...h}=e,p=Og(n),y=is(l),[E,T]=pn({prop:o,defaultProp:i,onChange:f});return u.createElement(RI,{scope:n,name:r,required:s,disabled:a,value:E,onValueChange:T},u.createElement(yI,ie({asChild:!0},p,{orientation:c,dir:y,loop:d}),u.createElement(He.div,ie({role:"radiogroup","aria-required":s,"aria-orientation":c,"data-disabled":a?"":void 0,dir:y},h,{ref:t}))))}),DI="RadioGroupItem",OI=u.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...i}=e,o=II(DI,n),s=o.disabled||r,a=Og(n),c=Mg(n),l=u.useRef(null),d=Qe(t,l),f=o.value===i.value,h=u.useRef(!1);return u.useEffect(()=>{const p=E=>{$I.includes(E.key)&&(h.current=!0)},y=()=>h.current=!1;return document.addEventListener("keydown",p),document.addEventListener("keyup",y),()=>{document.removeEventListener("keydown",p),document.removeEventListener("keyup",y)}},[]),u.createElement(bI,ie({asChild:!0},a,{focusable:!s,active:f}),u.createElement(CI,ie({disabled:s,required:o.required,checked:f},c,i,{name:o.name,ref:d,onCheck:()=>o.onValueChange(i.value),onKeyDown:De(p=>{p.key==="Enter"&&p.preventDefault()}),onFocus:De(i.onFocus,()=>{var p;h.current&&((p=l.current)===null||p===void 0||p.click())})})))}),MI=u.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,i=Mg(n);return u.createElement(TI,ie({},i,r,{ref:t}))}),kI=AI,NI=OI,jI=MI;var VI=ft({defaultClassName:"d6umgr4",variantClassNames:{disabled:{true:"d6umgr5"}},defaultVariants:{},compoundVariants:[]}),LI="d6umgr1",FI=ft({defaultClassName:"d6umgr2",variantClassNames:{disabled:{true:"d6umgr3"}},defaultVariants:{},compoundVariants:[]}),BI="d6umgr0";const kg=({children:e,className:t,disabled:n,...r})=>{const i=u.useId();return O.jsxs(Lt,{alignItems:"center",children:[O.jsx(NI,{...r,disabled:n,className:Re(t,BI),id:i,children:O.jsx(jI,{className:Re("radio-indicator",FI({disabled:n}))})}),e&&O.jsx("label",{className:Re("radio-label",VI({disabled:n})),htmlFor:i,children:e})]})};kg.defaultProps={children:void 0};const HI=({className:e,children:t,...n})=>O.jsx(kI,{...n,className:Re(e,LI),children:t});var WI="_846x3h0",UI="_846x3h1",YI=ft({defaultClassName:"_846x3h2",variantClassNames:{size:{small:"_846x3h3",medium:"_846x3h4",large:"_846x3h5"},isHasIcon:{true:"_846x3h6"},isDisabled:{true:"_846x3h7"}},defaultVariants:{size:"small"},compoundVariants:[]});const lu=u.forwardRef(({value:e,onClear:t,size:n,isDisabled:r,icon:i,...o},s)=>{const[a,c]=u.useState(!1),l=()=>c(!0),d=()=>c(!1),f=u.useMemo(()=>!!(i||e&&a),[a,e,i]);return O.jsxs(ht,{position:"relative",children:[O.jsx(ht,{className:Re(WI),children:O.jsx(rb,{size:24})}),O.jsx("input",{className:Re(YI({size:n,isHasIcon:f,isDisabled:r})),ref:s,value:e,"data-test-id":o["data-test-id"],onFocus:l,onBlur:d,disabled:r,...o}),f&&O.jsx(ht,{className:Re(UI),children:i&&(!a||a&&!e)?i:O.jsx(ls,{"data-test-id":"icon-close-search",onMouseDown:t,cursor:"pointer",size:24})})]})});lu.displayName="Search";lu.defaultProps={icon:void 0,isDisabled:void 0,onClear:void 0,"data-test-id":void 0};const Ng="Switch",[zI,_D]=sn(Ng),[KI,qI]=zI(Ng),XI=u.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:o,required:s,disabled:a,value:c="on",onCheckedChange:l,...d}=e,[f,h]=u.useState(null),p=Qe(t,m=>h(m)),y=u.useRef(!1),E=f?!!f.closest("form"):!0,[T=!1,S]=pn({prop:i,defaultProp:o,onChange:l});return u.createElement(KI,{scope:n,checked:T,disabled:a},u.createElement(He.button,ie({type:"button",role:"switch","aria-checked":T,"aria-required":s,"data-state":jg(T),"data-disabled":a?"":void 0,disabled:a,value:c},d,{ref:p,onClick:De(e.onClick,m=>{S(x=>!x),E&&(y.current=m.isPropagationStopped(),y.current||m.stopPropagation())})})),E&&u.createElement(QI,{control:f,bubbles:!y.current,name:r,value:c,checked:T,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))}),GI="SwitchThumb",ZI=u.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,i=qI(GI,n);return u.createElement(He.span,ie({"data-state":jg(i.checked),"data-disabled":i.disabled?"":void 0},r,{ref:t}))}),QI=e=>{const{control:t,checked:n,bubbles:r=!0,...i}=e,o=u.useRef(null),s=ms(n),a=ps(t);return u.useEffect(()=>{const c=o.current,l=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(l,"checked").set;if(s!==n&&f){const h=new Event("click",{bubbles:r});f.call(c,n),c.dispatchEvent(h)}},[s,n,r]),u.createElement("input",ie({type:"checkbox","aria-hidden":!0,defaultChecked:n},i,{tabIndex:-1,ref:o,style:{...e.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function jg(e){return e?"checked":"unchecked"}const JI=XI,eA=ZI;var tA="b7c0j12",nA="b7c0j10",rA="b7c0j11";const Vg=u.forwardRef((e,t)=>O.jsx(JI,{ref:t,className:nA,...e,children:O.jsx(eA,{className:rA,children:O.jsx(_c,{className:tA,size:16})})}));Vg.displayName="Switch";const Lg=({accessor:e,sortColumn:t,sortable:n,"data-test-id":r})=>{const i=t.by===e,o=t.order==="DESC",s=t.order==="ASC";return n?O.jsxs(Lt,{flexDirection:"column","data-test-id":r,children:[O.jsx(Tc,{size:10,color:i&&o?"white":"grey"}),O.jsx(Lo,{size:10,color:i&&s?"white":"grey"})]}):null};Lg.defaultProps={sortable:!1,"data-test-id":""};var oA="_94c6vs1",iA="_94c6vs3",Pp="_94c6vs2",sA="_94c6vs0";const Fg=({data:e,columns:t})=>{const[n,r]=u.useState([]),[i,o]=u.useState([]),[s,a]=u.useState({by:"",order:""}),c=f=>{const{accessor:h}=f,p=f.sortable,y=s.by===h;return p?y&&s.order==="ASC"?a({by:h,order:"DESC"}):y&&s.order==="DESC"?a({by:"",order:""}):a({by:h,order:"ASC"}):null},l=f=>typeof f=="object"?"":f,d=u.useCallback((f,h)=>{const p=[...f];return h.order==="ASC"?p.sort((E,T)=>String(T[h.by]).localeCompare(String(E[h.by]))):h.order==="DESC"?p.sort((E,T)=>String(E[h.by]).localeCompare(String(T[h.by]))):[...f]},[]);return u.useEffect(()=>{const f=t.map(y=>({...y,sortable:y.sortable??!1}));r(f);const p=d(e,{by:s.by,order:s.order}).map(y=>f.map(E=>({accessor:E.accessor,sortable:E.sortable??!1,value:l(y[E.accessor]),...E.cellRenderer&&{CellRenderer:E.cellRenderer({origin:y,value:y[E.accessor]})}})));o(p)},[t,e,d,s.by,s.order]),{headers:n,rows:i,handleHeaderClick:c,sortColumn:s}},Bg=u.forwardRef(({columns:e,as:t,"data-test-id":n,data:r,onSort:i,...o},s)=>{const a=t||"table",{rows:c,headers:l,handleHeaderClick:d,sortColumn:f}=Fg({data:r,columns:e});return u.useEffect(()=>{i&&i(f)},[i,f]),O.jsxs(a,{ref:s,as:t,className:sA,"data-test-id":n,...o,children:[O.jsx("thead",{children:O.jsx("tr",{className:iA,children:l.map(h=>O.jsx("th",{"data-test-id":"xmAUFfaxnRueeT_zBiyhc",className:Pp,onClick:()=>d(h),children:O.jsxs(Lt,{alignItems:"center",gap:"$8",justifyContent:"center",px:"$16",children:[O.jsx(ht,{fontWeight:"$bold",color:"$whiteTypoHigh",fontSize:"$body2",lineHeight:"$20",children:h.label}),O.jsx(Lg,{accessor:h.accessor,sortable:h.sortable,sortColumn:f,"data-test-id":`table-sort-${h.label}`})]})},h.accessor))})}),O.jsx("tbody",{children:c.map((h,p)=>O.jsx("tr",{className:oA,children:h.map((y,E)=>O.jsx(ht,{as:"td","data-test-id":`table-${n}-row${p}-col${E}`,className:Pp,w:"33%",children:y.CellRenderer??y.value}))}))})]})});Bg.defaultProps={as:"table","data-test-id":"base",onSort:void 0};var aA=ft({defaultClassName:"_5wiwut0",variantClassNames:{isActive:{true:"_5wiwut1"}},defaultVariants:{isActive:!1},compoundVariants:[]});var cA=ft({defaultClassName:"_1p5zdvr0",variantClassNames:{withShadow:{true:"_1p5zdvr1"},align:{left:"_1p5zdvr2",center:"_1p5zdvr3",right:"_1p5zdvr4"}},defaultVariants:{withShadow:!1,align:"left"},compoundVariants:[]});const uu=u.createContext({index:0,setIndex:()=>null}),du=u.forwardRef(({as:e,children:t,withShadow:n,index:r,defaultIndex:i,align:o,onChange:s,...a},c)=>{const[l,d]=u.useState(i??0),f=u.useMemo(()=>u.Children.map(t,(y,E)=>u.cloneElement(y,{"data-index":E})),[t]);u.useEffect(()=>d(r??0),[r]);const h=u.useMemo(()=>({index:l,setIndex:E=>{d(E),s==null||s(E)}}),[l,s]),p=e||"ul";return O.jsx(p,{"data-test-id":a["data-test-id"],as:e,ref:c,className:Re(cA({withShadow:n,align:o})),...a,children:O.jsx(uu.Provider,{value:h,children:f})})});du.displayName="Tabs";du.defaultProps={as:"ul",defaultIndex:0,index:0,align:"left",withShadow:!1,children:void 0,onChange:()=>null,"data-test-id":void 0};const fu=u.forwardRef(({as:e,children:t,...n},r)=>{const{index:i,setIndex:o}=u.useContext(uu),s=u.useCallback(l=>{o==null||o(l)},[o]),a=n["data-index"]===i,c=e||"li";return O.jsx(c,{"data-test-id":n["data-test-id"],as:e,ref:r,onClick:()=>s(n["data-index"]||0),className:Re(aA({isActive:a})),...n,children:O.jsx(Kt,{as:"span",textStyle:"body2",children:t})})});fu.displayName="TabItem";fu.defaultProps={as:"li","data-index":void 0,"data-test-id":void 0};const Hg="ToastProvider",[pu,lA,uA]=os("Toast"),[Wg,TD]=sn("Toast",[uA]),[dA,Vs]=Wg(Hg),Ug=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:i="right",swipeThreshold:o=50,children:s}=e,[a,c]=u.useState(null),[l,d]=u.useState(0),f=u.useRef(!1),h=u.useRef(!1);return u.createElement(pu.Provider,{scope:t},u.createElement(dA,{scope:t,label:n,duration:r,swipeDirection:i,swipeThreshold:o,toastCount:l,viewport:a,onViewportChange:c,onToastAdd:u.useCallback(()=>d(p=>p+1),[]),onToastRemove:u.useCallback(()=>d(p=>p-1),[]),isFocusedToastEscapeKeyDownRef:f,isClosePausedRef:h},s))};Ug.propTypes={label(e){if(e.label&&typeof e.label=="string"&&!e.label.trim()){const t=`Invalid prop \`label\` supplied to \`${Hg}\`. Expected non-empty \`string\`.`;return new Error(t)}return null}};const fA="ToastViewport",pA=["F8"],pc="toast.viewportPause",hc="toast.viewportResume",hA=u.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=pA,label:i="Notifications ({hotkey})",...o}=e,s=Vs(fA,n),a=lA(n),c=u.useRef(null),l=u.useRef(null),d=u.useRef(null),f=u.useRef(null),h=Qe(t,f,s.onViewportChange),p=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),y=s.toastCount>0;u.useEffect(()=>{const T=S=>{var m;r.every(_=>S[_]||S.code===_)&&((m=f.current)===null||m===void 0||m.focus())};return document.addEventListener("keydown",T),()=>document.removeEventListener("keydown",T)},[r]),u.useEffect(()=>{const T=c.current,S=f.current;if(y&&T&&S){const m=()=>{if(!s.isClosePausedRef.current){const M=new CustomEvent(pc);S.dispatchEvent(M),s.isClosePausedRef.current=!0}},x=()=>{if(s.isClosePausedRef.current){const M=new CustomEvent(hc);S.dispatchEvent(M),s.isClosePausedRef.current=!1}},_=M=>{!T.contains(M.relatedTarget)&&x()},$=()=>{T.contains(document.activeElement)||x()};return T.addEventListener("focusin",m),T.addEventListener("focusout",_),T.addEventListener("pointermove",m),T.addEventListener("pointerleave",$),window.addEventListener("blur",m),window.addEventListener("focus",x),()=>{T.removeEventListener("focusin",m),T.removeEventListener("focusout",_),T.removeEventListener("pointermove",m),T.removeEventListener("pointerleave",$),window.removeEventListener("blur",m),window.removeEventListener("focus",x)}}},[y,s.isClosePausedRef]);const E=u.useCallback(({tabbingDirection:T})=>{const m=a().map(x=>{const _=x.ref.current,$=[_,...RA(_)];return T==="forwards"?$:$.reverse()});return(T==="forwards"?m.reverse():m).flat()},[a]);return u.useEffect(()=>{const T=f.current;if(T){const S=m=>{const x=m.altKey||m.ctrlKey||m.metaKey;if(m.key==="Tab"&&!x){const N=document.activeElement,j=m.shiftKey;if(m.target===T&&j){var $;($=l.current)===null||$===void 0||$.focus();return}const P=E({tabbingDirection:j?"backwards":"forwards"}),v=P.findIndex(C=>C===N);if(Ra(P.slice(v+1)))m.preventDefault();else{var M,D;j?(M=l.current)===null||M===void 0||M.focus():(D=d.current)===null||D===void 0||D.focus()}}};return T.addEventListener("keydown",S),()=>T.removeEventListener("keydown",S)}},[a,E]),u.createElement(Tb,{ref:c,role:"region","aria-label":i.replace("{hotkey}",p),tabIndex:-1,style:{pointerEvents:y?void 0:"none"}},y&&u.createElement(Rp,{ref:l,onFocusFromOutsideViewport:()=>{const T=E({tabbingDirection:"forwards"});Ra(T)}}),u.createElement(pu.Slot,{scope:n},u.createElement(He.ol,ie({tabIndex:-1},o,{ref:h}))),y&&u.createElement(Rp,{ref:d,onFocusFromOutsideViewport:()=>{const T=E({tabbingDirection:"backwards"});Ra(T)}}))}),mA="ToastFocusProxy",Rp=u.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...i}=e,o=Vs(mA,n);return u.createElement(vs,ie({"aria-hidden":!0,tabIndex:0},i,{ref:t,style:{position:"fixed"},onFocus:s=>{var a;const c=s.relatedTarget;!((a=o.viewport)!==null&&a!==void 0&&a.contains(c))&&r()}}))}),Ls="Toast",vA="toast.swipeStart",gA="toast.swipeMove",yA="toast.swipeCancel",bA="toast.swipeEnd",wA=u.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:i,onOpenChange:o,...s}=e,[a=!0,c]=pn({prop:r,defaultProp:i,onChange:o});return u.createElement(hr,{present:n||a},u.createElement(Yg,ie({open:a},s,{ref:t,onClose:()=>c(!1),onPause:qt(e.onPause),onResume:qt(e.onResume),onSwipeStart:De(e.onSwipeStart,l=>{l.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:De(e.onSwipeMove,l=>{const{x:d,y:f}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","move"),l.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${d}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${f}px`)}),onSwipeCancel:De(e.onSwipeCancel,l=>{l.currentTarget.setAttribute("data-swipe","cancel"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),l.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:De(e.onSwipeEnd,l=>{const{x:d,y:f}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","end"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),l.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${d}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${f}px`),c(!1)})})))}),[xA,EA]=Wg(Ls,{onClose(){}}),Yg=u.forwardRef((e,t)=>{const{__scopeToast:n,type:r="foreground",duration:i,open:o,onClose:s,onEscapeKeyDown:a,onPause:c,onResume:l,onSwipeStart:d,onSwipeMove:f,onSwipeCancel:h,onSwipeEnd:p,...y}=e,E=Vs(Ls,n),[T,S]=u.useState(null),m=Qe(t,C=>S(C)),x=u.useRef(null),_=u.useRef(null),$=i||E.duration,M=u.useRef(0),D=u.useRef($),N=u.useRef(0),{onToastAdd:j,onToastRemove:K}=E,V=qt(()=>{var C;(T==null?void 0:T.contains(document.activeElement))&&((C=E.viewport)===null||C===void 0||C.focus()),s()}),P=u.useCallback(C=>{!C||C===1/0||(window.clearTimeout(N.current),M.current=new Date().getTime(),N.current=window.setTimeout(V,C))},[V]);u.useEffect(()=>{const C=E.viewport;if(C){const I=()=>{P(D.current),l==null||l()},k=()=>{const U=new Date().getTime()-M.current;D.current=D.current-U,window.clearTimeout(N.current),c==null||c()};return C.addEventListener(pc,k),C.addEventListener(hc,I),()=>{C.removeEventListener(pc,k),C.removeEventListener(hc,I)}}},[E.viewport,$,c,l,P]),u.useEffect(()=>{o&&!E.isClosePausedRef.current&&P($)},[o,$,E.isClosePausedRef,P]),u.useEffect(()=>(j(),()=>K()),[j,K]);const v=u.useMemo(()=>T?Kg(T):null,[T]);return E.viewport?u.createElement(u.Fragment,null,v&&u.createElement(CA,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0},v),u.createElement(xA,{scope:n,onClose:V},fn.createPortal(u.createElement(pu.ItemSlot,{scope:n},u.createElement(_b,{asChild:!0,onEscapeKeyDown:De(a,()=>{E.isFocusedToastEscapeKeyDownRef.current||V(),E.isFocusedToastEscapeKeyDownRef.current=!1})},u.createElement(He.li,ie({role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":o?"open":"closed","data-swipe-direction":E.swipeDirection},y,{ref:m,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:De(e.onKeyDown,C=>{C.key==="Escape"&&(a==null||a(C.nativeEvent),C.nativeEvent.defaultPrevented||(E.isFocusedToastEscapeKeyDownRef.current=!0,V()))}),onPointerDown:De(e.onPointerDown,C=>{C.button===0&&(x.current={x:C.clientX,y:C.clientY})}),onPointerMove:De(e.onPointerMove,C=>{if(!x.current)return;const I=C.clientX-x.current.x,k=C.clientY-x.current.y,U=!!_.current,G=["left","right"].includes(E.swipeDirection),ue=["left","up"].includes(E.swipeDirection)?Math.min:Math.max,W=G?ue(0,I):0,L=G?0:ue(0,k),oe=C.pointerType==="touch"?10:2,X={x:W,y:L},q={originalEvent:C,delta:X};U?(_.current=X,$i(gA,f,q,{discrete:!1})):Ip(X,E.swipeDirection,oe)?(_.current=X,$i(vA,d,q,{discrete:!1}),C.target.setPointerCapture(C.pointerId)):(Math.abs(I)>oe||Math.abs(k)>oe)&&(x.current=null)}),onPointerUp:De(e.onPointerUp,C=>{const I=_.current,k=C.target;if(k.hasPointerCapture(C.pointerId)&&k.releasePointerCapture(C.pointerId),_.current=null,x.current=null,I){const U=C.currentTarget,G={originalEvent:C,delta:I};Ip(I,E.swipeDirection,E.swipeThreshold)?$i(bA,p,G,{discrete:!0}):$i(yA,h,G,{discrete:!0}),U.addEventListener("click",ue=>ue.preventDefault(),{once:!0})}})})))),E.viewport))):null});Yg.propTypes={type(e){if(e.type&&!["foreground","background"].includes(e.type)){const t=`Invalid prop \`type\` supplied to \`${Ls}\`. Expected \`foreground | background\`.`;return new Error(t)}return null}};const CA=e=>{const{__scopeToast:t,children:n,...r}=e,i=Vs(Ls,t),[o,s]=u.useState(!1),[a,c]=u.useState(!1);return $A(()=>s(!0)),u.useEffect(()=>{const l=window.setTimeout(()=>c(!0),1e3);return()=>window.clearTimeout(l)},[]),a?null:u.createElement(gh,{asChild:!0},u.createElement(vs,r,o&&u.createElement(u.Fragment,null,i.label," ",n)))},_A="ToastAction",hu=u.forwardRef((e,t)=>{const{altText:n,...r}=e;return n?u.createElement(zg,{altText:n,asChild:!0},u.createElement(SA,ie({},r,{ref:t}))):null});hu.propTypes={altText(e){return e.altText?null:new Error(`Missing prop \`altText\` expected on \`${_A}\``)}};const TA="ToastClose",SA=u.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,i=EA(TA,n);return u.createElement(zg,{asChild:!0},u.createElement(He.button,ie({type:"button"},r,{ref:t,onClick:De(e.onClick,i.onClose)})))}),zg=u.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...i}=e;return u.createElement(He.div,ie({"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0},i,{ref:t}))});function Kg(e){const t=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),PA(r)){const i=r.ariaHidden||r.hidden||r.style.display==="none",o=r.dataset.radixToastAnnounceExclude==="";if(!i)if(o){const s=r.dataset.radixToastAnnounceAlt;s&&t.push(s)}else t.push(...Kg(r))}}),t}function $i(e,t,n,{discrete:r}){const i=n.originalEvent.currentTarget,o=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?Vp(i,o):i.dispatchEvent(o)}const Ip=(e,t,n=0)=>{const r=Math.abs(e.x),i=Math.abs(e.y),o=r>i;return t==="left"||t==="right"?o&&r>n:!o&&i>n};function $A(e=()=>{}){const t=qt(e);Wt(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function PA(e){return e.nodeType===e.ELEMENT_NODE}function RA(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ra(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}const IA=Ug,qg=hA,Xg=wA,AA=hu;var DA="_10z4js28",OA=ft({defaultClassName:"_10z4js24",variantClassNames:{color:{neutral:"_10z4js25",negative:"_10z4js26"}},defaultVariants:{color:"neutral"},compoundVariants:[]}),MA="_10z4js27",kA="_10z4js29";const Gg=IA,mu=u.forwardRef(({className:e,...t},n)=>O.jsx(qg,{ref:n,className:Re(kA,e),...t}));mu.displayName=qg.displayName;const Fs=u.forwardRef(({className:e,color:t="neutral",...n},r)=>O.jsx(Xg,{ref:r,className:Re(OA({color:t}),e),...n}));Fs.displayName=Xg.displayName;Fs.defaultProps={viewPort:void 0};const vu=u.forwardRef(({className:e,...t},n)=>O.jsx(hu,{ref:n,className:Re(e),...t}));vu.displayName=AA.displayName;const NA=1,jA=1e6,Fn={ADD_TOAST:"ADD_TOAST",UPDATE_TOAST:"UPDATE_TOAST",DISMISS_TOAST:"DISMISS_TOAST",REMOVE_TOAST:"REMOVE_TOAST"};let Ia=0;function VA(){return Ia=(Ia+1)%Number.MAX_VALUE,Ia.toString()}const Aa=new Map,Ap=e=>{if(Aa.has(e))return;const t=setTimeout(()=>{Aa.delete(e),Vo({type:Fn.REMOVE_TOAST,toastId:e})},jA);Aa.set(e,t)};function Zg(e,t){switch(t.type){case Fn.ADD_TOAST:return{...e,toasts:[t.toast,...e.toasts].slice(0,NA)};case Fn.UPDATE_TOAST:return{...e,toasts:e.toasts.map(n=>n.id===t.toast.id?{...n,...t.toast}:n)};case Fn.DISMISS_TOAST:{const{toastId:n}=t;return n?Ap(n):e.toasts.forEach(r=>{Ap(r.id)}),{...e,toasts:e.toasts.map(r=>r.id===n||n===void 0?{...r,open:!1}:r)}}case Fn.REMOVE_TOAST:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(n=>n.id!==t.toastId)};default:return e}}const ki=[];let Ni={toasts:[]};function Vo(e){Ni=Zg(Ni,e),ki.forEach(t=>{t(Ni)})}function Qg({...e}){const t=VA(),n=i=>Vo({type:Fn.UPDATE_TOAST,toast:{...i,id:t}}),r=()=>Vo({type:Fn.DISMISS_TOAST,toastId:t});return Vo({type:Fn.ADD_TOAST,toast:{...e,id:t,open:!0,onOpenChange:i=>{i||r()}}}),{id:t,dismiss:r,update:n}}function Jg(){const[e,t]=u.useState(Ni);return u.useEffect(()=>(ki.push(t),()=>{const n=ki.indexOf(t);n>-1&&ki.splice(n,1)}),[e]),{...e,toast:Qg,dismiss:n=>Vo({type:Fn.DISMISS_TOAST,toastId:n})}}const gu=u.forwardRef((e,t)=>{const{toasts:n}=Jg();return O.jsx(Gg,{children:n.map(({id:r,description:i,action:o,actionText:s,actionClick:a,duration:c=3e3,type:l="foreground",color:d="neutral",viewPort:f,...h})=>O.jsxs("div",{children:[O.jsxs(Fs,{ref:t,color:d,duration:c,type:l,"data-test-id":`toast-${h["data-test-id"]??""}`,...h,children:[O.jsx(ht,{flexGrow:1,pl:"$16",py:"$16",pr:a?"$0":"$16",maxW:"$full",minW:"$0",children:O.jsx(Kt,{textStyle:"body2",fontWeight:"$reguler",textOverflow:"ellipsis",overflow:"hidden",className:MA,children:i})}),!o&&a&&s?O.jsx(vu,{altText:s,asChild:!0,children:O.jsx(Dv,{"data-test-id":`action-toast-${h["data-test-id"]??""}`,onClick:a,className:DA,children:s})}):o]},r),O.jsx(mu,{...f})]},r))})});gu.displayName="Toaster";const[Bs,SD]=sn("Tooltip",[hs]),Hs=hs(),LA="TooltipProvider",FA=700,mc="tooltip.open",[BA,yu]=Bs(LA),HA=e=>{const{__scopeTooltip:t,delayDuration:n=FA,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:o}=e,[s,a]=u.useState(!0),c=u.useRef(!1),l=u.useRef(0);return u.useEffect(()=>{const d=l.current;return()=>window.clearTimeout(d)},[]),u.createElement(BA,{scope:t,isOpenDelayed:s,delayDuration:n,onOpen:u.useCallback(()=>{window.clearTimeout(l.current),a(!1)},[]),onClose:u.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>a(!0),r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:u.useCallback(d=>{c.current=d},[]),disableHoverableContent:i},o)},bu="Tooltip",[WA,Ws]=Bs(bu),UA=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i=!1,onOpenChange:o,disableHoverableContent:s,delayDuration:a}=e,c=yu(bu,e.__scopeTooltip),l=Hs(t),[d,f]=u.useState(null),h=Bn(),p=u.useRef(0),y=s??c.disableHoverableContent,E=a??c.delayDuration,T=u.useRef(!1),[S=!1,m]=pn({prop:r,defaultProp:i,onChange:D=>{D?(c.onOpen(),document.dispatchEvent(new CustomEvent(mc))):c.onClose(),o==null||o(D)}}),x=u.useMemo(()=>S?T.current?"delayed-open":"instant-open":"closed",[S]),_=u.useCallback(()=>{window.clearTimeout(p.current),T.current=!1,m(!0)},[m]),$=u.useCallback(()=>{window.clearTimeout(p.current),m(!1)},[m]),M=u.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{T.current=!0,m(!0)},E)},[E,m]);return u.useEffect(()=>()=>window.clearTimeout(p.current),[]),u.createElement(hh,l,u.createElement(WA,{scope:t,contentId:h,open:S,stateAttribute:x,trigger:d,onTriggerChange:f,onTriggerEnter:u.useCallback(()=>{c.isOpenDelayed?M():_()},[c.isOpenDelayed,M,_]),onTriggerLeave:u.useCallback(()=>{y?$():window.clearTimeout(p.current)},[$,y]),onOpen:_,onClose:$,disableHoverableContent:y},n))},Dp="TooltipTrigger",YA=u.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Ws(Dp,n),o=yu(Dp,n),s=Hs(n),a=u.useRef(null),c=Qe(t,a,i.onTriggerChange),l=u.useRef(!1),d=u.useRef(!1),f=u.useCallback(()=>l.current=!1,[]);return u.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),u.createElement(mh,ie({asChild:!0},s),u.createElement(He.button,ie({"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute},r,{ref:c,onPointerMove:De(e.onPointerMove,h=>{h.pointerType!=="touch"&&!d.current&&!o.isPointerInTransitRef.current&&(i.onTriggerEnter(),d.current=!0)}),onPointerLeave:De(e.onPointerLeave,()=>{i.onTriggerLeave(),d.current=!1}),onPointerDown:De(e.onPointerDown,()=>{l.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:De(e.onFocus,()=>{l.current||i.onOpen()}),onBlur:De(e.onBlur,i.onClose),onClick:De(e.onClick,i.onClose)})))}),zA="TooltipPortal",[$D,KA]=Bs(zA,{forceMount:void 0}),Ko="TooltipContent",qA=u.forwardRef((e,t)=>{const n=KA(Ko,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...o}=e,s=Ws(Ko,e.__scopeTooltip);return u.createElement(hr,{present:r||s.open},s.disableHoverableContent?u.createElement(ey,ie({side:i},o,{ref:t})):u.createElement(XA,ie({side:i},o,{ref:t})))}),XA=u.forwardRef((e,t)=>{const n=Ws(Ko,e.__scopeTooltip),r=yu(Ko,e.__scopeTooltip),i=u.useRef(null),o=Qe(t,i),[s,a]=u.useState(null),{trigger:c,onClose:l}=n,d=i.current,{onPointerInTransitChange:f}=r,h=u.useCallback(()=>{a(null),f(!1)},[f]),p=u.useCallback((y,E)=>{const T=y.currentTarget,S={x:y.clientX,y:y.clientY},m=eD(S,T.getBoundingClientRect()),x=tD(S,m),_=nD(E.getBoundingClientRect()),$=oD([...x,..._]);a($),f(!0)},[f]);return u.useEffect(()=>()=>h(),[h]),u.useEffect(()=>{if(c&&d){const y=T=>p(T,d),E=T=>p(T,c);return c.addEventListener("pointerleave",y),d.addEventListener("pointerleave",E),()=>{c.removeEventListener("pointerleave",y),d.removeEventListener("pointerleave",E)}}},[c,d,p,h]),u.useEffect(()=>{if(s){const y=E=>{const T=E.target,S={x:E.clientX,y:E.clientY},m=(c==null?void 0:c.contains(T))||(d==null?void 0:d.contains(T)),x=!rD(S,s);m?h():x&&(h(),l())};return document.addEventListener("pointermove",y),()=>document.removeEventListener("pointermove",y)}},[c,d,s,l,h]),u.createElement(ey,ie({},e,{ref:o}))}),[GA,ZA]=Bs(bu,{isInside:!1}),ey=u.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:o,onPointerDownOutside:s,...a}=e,c=Ws(Ko,n),l=Hs(n),{onClose:d}=c;return u.useEffect(()=>(document.addEventListener(mc,d),()=>document.removeEventListener(mc,d)),[d]),u.useEffect(()=>{if(c.trigger){const f=h=>{const p=h.target;p!=null&&p.contains(c.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[c.trigger,d]),u.createElement(us,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:f=>f.preventDefault(),onDismiss:d},u.createElement(vh,ie({"data-state":c.stateAttribute},l,a,{ref:t,style:{...a.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)"}}),u.createElement(jp,null,r),u.createElement(GA,{scope:n,isInside:!0},u.createElement(Aw,{id:c.contentId,role:"tooltip"},i||r))))}),QA="TooltipArrow",JA=u.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=Hs(n);return ZA(QA,n).isInside?null:u.createElement(Rw,ie({},i,r,{ref:t}))});function eD(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function tD(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});break}return r}function nD(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function rD(e,t){const{x:n,y:r}=e;let i=!1;for(let o=0,s=t.length-1;o<t.length;s=o++){const a=t[o].x,c=t[o].y,l=t[s].x,d=t[s].y;c>r!=d>r&&n<(l-a)*(r-c)/(d-c)+a&&(i=!i)}return i}function oD(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),iD(t)}function iD(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const o=t[t.length-1],s=t[t.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const o=n[n.length-1],s=n[n.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))n.pop();else break}n.push(i)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const sD=HA,aD=UA,cD=YA,lD=qA,uD=JA;function Op(e){var t=e.match(/^var\((.*)\)$/);return t?t[1]:e}function dD(e,t){var n=e;for(var r of t){if(!(r in n))throw new Error("Path ".concat(t.join(" -> ")," does not exist in object"));n=n[r]}return n}function ty(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[],r=e.constructor();for(var i in e){var o=e[i],s=[...n,i];typeof o=="string"||typeof o=="number"||o==null?r[i]=t(o,s):typeof o=="object"&&!Array.isArray(o)?r[i]=ty(o,t,s):console.warn('Skipping invalid key "'.concat(s.join("."),'". Should be a string, number, null or object. Received: "').concat(Array.isArray(o)?"Array":typeof o,'"'))}return r}function fD(e,t){var n={};if(typeof t=="object"){var r=e;ty(t,(s,a)=>{var c=dD(r,a);n[Op(c)]=String(s)})}else{var i=e;for(var o in i)n[Op(o)]=i[o]}return Object.defineProperty(n,"toString",{value:function(){return Object.keys(this).map(a=>"".concat(a,":").concat(this[a])).join(";")},writable:!1}),n}var pD="var(--_4goys34)",hD="_4goys35",mD="_4goys36";const wu=u.forwardRef(({align:e,alignOffset:t,children:n,color:r,bgColor:i,content:o,defaultOpen:s,delayDuration:a=700,disableHoverableContent:c,onOpenChange:l,open:d,position:f,positionOffset:h,withIcon:p,...y},E)=>{const T=Et.atoms.commonAtoms({color:r,bgColor:i}).className,S=Et.atoms.borderAtoms({borderColor:i}).className,x=i.replace("$","");return O.jsxs(aD,{defaultOpen:s,delayDuration:a,disableHoverableContent:c,onOpenChange:l,open:d,children:[O.jsx(cD,{asChild:!0,ref:E,children:n}),O.jsx(xs,{children:O.jsxs(lD,{align:e,alignOffset:t,side:f,sideOffset:h,...y,className:Re(mD,T,S),children:[O.jsxs(Lt,{gap:"$6",children:[p&&O.jsx(Lt,{width:"$24",children:O.jsx(ab,{size:24})}),o]}),O.jsx(uD,{className:hD,style:fD({[pD]:Et.theme.colors[x]})})]})})]})});wu.displayName="Tooltip";wu.defaultProps={align:void 0,alignOffset:void 0,defaultOpen:void 0,delayDuration:300,disableHoverableContent:!1,onOpenChange:void 0,open:void 0,position:void 0,positionOffset:void 0,withIcon:void 0,bgColor:"$blackTypoHigh",color:"$white"};const xu=({children:e})=>O.jsxs(sD,{children:[e,O.jsx(gu,{})]});xu.displayName="RadixProvider";const Eu=({children:e,withScrollStyles:t})=>O.jsx("div",{id:"voila-ui",style:{fontFamily:Et.theme.fonts.poppins},className:Re(t??Et.scrollbarStyle),children:O.jsx(xu,{children:e})});Eu.displayName="Provider";Eu.defaultProps={withScrollStyles:!1};exports.Accordion=c0;exports.AccordionContent=H0;exports.AccordionItem=W0;exports.AccordionTrigger=hb;exports.Alert=qp;exports.Badge=Sc;exports.BaseSelect=Lc;exports.BottomSheet=kS;exports.Box=ht;exports.Button=co;exports.Card=xc;exports.Checkbox=$v;exports.Chips=ml;exports.CloseButton=ho;exports.ConfirmDialogContext=yl;exports.ConfirmDialogProvider=PP;exports.Container=Ec;exports.DatePicker=eR;exports.Dialog=gl;exports.Flex=Lt;exports.FullLoader=kv;exports.Grid=Cc;exports.IconButton=El;exports.Image=Cl;exports.Input=wl;exports.Link=Dv;exports.List=_l;exports.ListItem=Tl;exports.Loader=FP;exports.LoaderAnimated=Sl;exports.Modal=ei;exports.ModalBody=Ns;exports.ModalFooter=js;exports.ModalHeader=ti;exports.MultiPicker=Nv;exports.Overlay=C1;exports.Picker=lc;exports.Portal=xs;exports.Provider=Eu;exports.Radio=kg;exports.RadioGroup=HI;exports.RadixProvider=xu;exports.Search=lu;exports.Select=to;exports.SelectPicker=Tg;exports.Spinner=mo;exports.Stack=Ir;exports.Switch=Vg;exports.TabItem=fu;exports.Table=Bg;exports.Tabs=du;exports.TabsContext=uu;exports.Text=Kt;exports.Textarea=xl;exports.Toast=Fs;exports.ToastAction=vu;exports.ToastProvider=Gg;exports.ToastViewport=mu;exports.Toaster=gu;exports.Tooltip=wu;exports.reducer=Zg;exports.toast=Qg;exports.useDialog=RP;exports.useIndeterminate=Q$;exports.useOnMount=Lh;exports.useRipple=hl;exports.useTableRenderer=Fg;exports.useToast=Jg;
|