ui-arreya-components 0.0.12 → 0.0.13
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/styles.css +3 -0
- package/dist/ui.cjs.js +237 -0
- package/dist/ui.es.js +24914 -0
- package/dist/ui.umd.js +237 -0
- package/package.json +1 -1
package/dist/ui.cjs.js
ADDED
|
@@ -0,0 +1,237 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("react"),Wa=require("react-dom");function Nb(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const d=Nb(E),ho=Nb(Wa);var qo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Yt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ho={exports:{}},jn={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react-jsx-runtime.production.min.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var Zp;function FN(){if(Zp)return jn;Zp=1;var e=E,t=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function i(s,c,l){var p,u={},m=null,b=null;l!==void 0&&(m=""+l),c.key!==void 0&&(m=""+c.key),c.ref!==void 0&&(b=c.ref);for(p in c)n.call(c,p)&&!a.hasOwnProperty(p)&&(u[p]=c[p]);if(s&&s.defaultProps)for(p in c=s.defaultProps,c)u[p]===void 0&&(u[p]=c[p]);return{$$typeof:t,type:s,key:m,ref:b,props:u,_owner:o.current}}return jn.Fragment=r,jn.jsx=i,jn.jsxs=i,jn}var Dn={};/**
|
|
10
|
+
* @license React
|
|
11
|
+
* react-jsx-runtime.development.js
|
|
12
|
+
*
|
|
13
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
14
|
+
*
|
|
15
|
+
* This source code is licensed under the MIT license found in the
|
|
16
|
+
* LICENSE file in the root directory of this source tree.
|
|
17
|
+
*/var Jp;function BN(){return Jp||(Jp=1,process.env.NODE_ENV!=="production"&&function(){var e=E,t=Symbol.for("react.element"),r=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),s=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),g=Symbol.iterator,h="@@iterator";function v(T){if(T===null||typeof T!="object")return null;var Y=g&&T[g]||T[h];return typeof Y=="function"?Y:null}var y=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function x(T){{for(var Y=arguments.length,se=new Array(Y>1?Y-1:0),he=1;he<Y;he++)se[he-1]=arguments[he];w("error",T,se)}}function w(T,Y,se){{var he=y.ReactDebugCurrentFrame,Ne=he.getStackAddendum();Ne!==""&&(Y+="%s",se=se.concat([Ne]));var je=se.map(function(Pe){return String(Pe)});je.unshift("Warning: "+Y),Function.prototype.apply.call(console[T],console,je)}}var S=!1,_=!1,R=!1,C=!1,A=!1,P;P=Symbol.for("react.module.reference");function k(T){return!!(typeof T=="string"||typeof T=="function"||T===n||T===a||A||T===o||T===l||T===p||C||T===b||S||_||R||typeof T=="object"&&T!==null&&(T.$$typeof===m||T.$$typeof===u||T.$$typeof===i||T.$$typeof===s||T.$$typeof===c||T.$$typeof===P||T.getModuleId!==void 0))}function j(T,Y,se){var he=T.displayName;if(he)return he;var Ne=Y.displayName||Y.name||"";return Ne!==""?se+"("+Ne+")":se}function L(T){return T.displayName||"Context"}function N(T){if(T==null)return null;if(typeof T.tag=="number"&&x("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof T=="function")return T.displayName||T.name||null;if(typeof T=="string")return T;switch(T){case n:return"Fragment";case r:return"Portal";case a:return"Profiler";case o:return"StrictMode";case l:return"Suspense";case p:return"SuspenseList"}if(typeof T=="object")switch(T.$$typeof){case s:var Y=T;return L(Y)+".Consumer";case i:var se=T;return L(se._context)+".Provider";case c:return j(T,T.render,"ForwardRef");case u:var he=T.displayName||null;return he!==null?he:N(T.type)||"Memo";case m:{var Ne=T,je=Ne._payload,Pe=Ne._init;try{return N(Pe(je))}catch{return null}}}return null}var D=Object.assign,$=0,O,G,H,z,oe,Z,te;function F(){}F.__reactDisabledLog=!0;function U(){{if($===0){O=console.log,G=console.info,H=console.warn,z=console.error,oe=console.group,Z=console.groupCollapsed,te=console.groupEnd;var T={configurable:!0,enumerable:!0,value:F,writable:!0};Object.defineProperties(console,{info:T,log:T,warn:T,error:T,group:T,groupCollapsed:T,groupEnd:T})}$++}}function Q(){{if($--,$===0){var T={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:D({},T,{value:O}),info:D({},T,{value:G}),warn:D({},T,{value:H}),error:D({},T,{value:z}),group:D({},T,{value:oe}),groupCollapsed:D({},T,{value:Z}),groupEnd:D({},T,{value:te})})}$<0&&x("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var K=y.ReactCurrentDispatcher,q;function W(T,Y,se){{if(q===void 0)try{throw Error()}catch(Ne){var he=Ne.stack.trim().match(/\n( *(at )?)/);q=he&&he[1]||""}return`
|
|
18
|
+
`+q+T}}var re=!1,J;{var ne=typeof WeakMap=="function"?WeakMap:Map;J=new ne}function V(T,Y){if(!T||re)return"";{var se=J.get(T);if(se!==void 0)return se}var he;re=!0;var Ne=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var je;je=K.current,K.current=null,U();try{if(Y){var Pe=function(){throw Error()};if(Object.defineProperty(Pe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Pe,[])}catch(ht){he=ht}Reflect.construct(T,[],Pe)}else{try{Pe.call()}catch(ht){he=ht}T.call(Pe.prototype)}}else{try{throw Error()}catch(ht){he=ht}T()}}catch(ht){if(ht&&he&&typeof ht.stack=="string"){for(var _e=ht.stack.split(`
|
|
19
|
+
`),pt=he.stack.split(`
|
|
20
|
+
`),Ge=_e.length-1,Ye=pt.length-1;Ge>=1&&Ye>=0&&_e[Ge]!==pt[Ye];)Ye--;for(;Ge>=1&&Ye>=0;Ge--,Ye--)if(_e[Ge]!==pt[Ye]){if(Ge!==1||Ye!==1)do if(Ge--,Ye--,Ye<0||_e[Ge]!==pt[Ye]){var _t=`
|
|
21
|
+
`+_e[Ge].replace(" at new "," at ");return T.displayName&&_t.includes("<anonymous>")&&(_t=_t.replace("<anonymous>",T.displayName)),typeof T=="function"&&J.set(T,_t),_t}while(Ge>=1&&Ye>=0);break}}}finally{re=!1,K.current=je,Q(),Error.prepareStackTrace=Ne}var Wr=T?T.displayName||T.name:"",Pr=Wr?W(Wr):"";return typeof T=="function"&&J.set(T,Pr),Pr}function ae(T,Y,se){return V(T,!1)}function I(T){var Y=T.prototype;return!!(Y&&Y.isReactComponent)}function ee(T,Y,se){if(T==null)return"";if(typeof T=="function")return V(T,I(T));if(typeof T=="string")return W(T);switch(T){case l:return W("Suspense");case p:return W("SuspenseList")}if(typeof T=="object")switch(T.$$typeof){case c:return ae(T.render);case u:return ee(T.type,Y,se);case m:{var he=T,Ne=he._payload,je=he._init;try{return ee(je(Ne),Y,se)}catch{}}}return""}var pe=Object.prototype.hasOwnProperty,me={},ge=y.ReactDebugCurrentFrame;function fe(T){if(T){var Y=T._owner,se=ee(T.type,T._source,Y?Y.type:null);ge.setExtraStackFrame(se)}else ge.setExtraStackFrame(null)}function Ee(T,Y,se,he,Ne){{var je=Function.call.bind(pe);for(var Pe in T)if(je(T,Pe)){var _e=void 0;try{if(typeof T[Pe]!="function"){var pt=Error((he||"React class")+": "+se+" type `"+Pe+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof T[Pe]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw pt.name="Invariant Violation",pt}_e=T[Pe](Y,Pe,he,se,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(Ge){_e=Ge}_e&&!(_e instanceof Error)&&(fe(Ne),x("%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).",he||"React class",se,Pe,typeof _e),fe(null)),_e instanceof Error&&!(_e.message in me)&&(me[_e.message]=!0,fe(Ne),x("Failed %s type: %s",se,_e.message),fe(null))}}}var Fe=Array.isArray;function we(T){return Fe(T)}function Oe(T){{var Y=typeof Symbol=="function"&&Symbol.toStringTag,se=Y&&T[Symbol.toStringTag]||T.constructor.name||"Object";return se}}function rt(T){try{return Ze(T),!1}catch{return!0}}function Ze(T){return""+T}function We(T){if(rt(T))return x("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Oe(T)),Ze(T)}var ot=y.ReactCurrentOwner,mt={key:!0,ref:!0,__self:!0,__source:!0},ft,Ve;function Ct(T){if(pe.call(T,"ref")){var Y=Object.getOwnPropertyDescriptor(T,"ref").get;if(Y&&Y.isReactWarning)return!1}return T.ref!==void 0}function Ke(T){if(pe.call(T,"key")){var Y=Object.getOwnPropertyDescriptor(T,"key").get;if(Y&&Y.isReactWarning)return!1}return T.key!==void 0}function Je(T,Y){typeof T.ref=="string"&&ot.current}function At(T,Y){{var se=function(){ft||(ft=!0,x("%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)",Y))};se.isReactWarning=!0,Object.defineProperty(T,"key",{get:se,configurable:!0})}}function Vt(T,Y){{var se=function(){Ve||(Ve=!0,x("%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)",Y))};se.isReactWarning=!0,Object.defineProperty(T,"ref",{get:se,configurable:!0})}}var pr=function(T,Y,se,he,Ne,je,Pe){var _e={$$typeof:t,type:T,key:Y,ref:se,props:Pe,_owner:je};return _e._store={},Object.defineProperty(_e._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(_e,"_self",{configurable:!1,enumerable:!1,writable:!1,value:he}),Object.defineProperty(_e,"_source",{configurable:!1,enumerable:!1,writable:!1,value:Ne}),Object.freeze&&(Object.freeze(_e.props),Object.freeze(_e)),_e};function Er(T,Y,se,he,Ne){{var je,Pe={},_e=null,pt=null;se!==void 0&&(We(se),_e=""+se),Ke(Y)&&(We(Y.key),_e=""+Y.key),Ct(Y)&&(pt=Y.ref,Je(Y,Ne));for(je in Y)pe.call(Y,je)&&!mt.hasOwnProperty(je)&&(Pe[je]=Y[je]);if(T&&T.defaultProps){var Ge=T.defaultProps;for(je in Ge)Pe[je]===void 0&&(Pe[je]=Ge[je])}if(_e||pt){var Ye=typeof T=="function"?T.displayName||T.name||"Unknown":T;_e&&At(Pe,Ye),pt&&Vt(Pe,Ye)}return pr(T,_e,pt,Ne,he,ot.current,Pe)}}var Mt=y.ReactCurrentOwner,ue=y.ReactDebugCurrentFrame;function be(T){if(T){var Y=T._owner,se=ee(T.type,T._source,Y?Y.type:null);ue.setExtraStackFrame(se)}else ue.setExtraStackFrame(null)}var Ce;Ce=!1;function ve(T){return typeof T=="object"&&T!==null&&T.$$typeof===t}function ie(){{if(Mt.current){var T=N(Mt.current.type);if(T)return`
|
|
22
|
+
|
|
23
|
+
Check the render method of \``+T+"`."}return""}}function Se(T){return""}var xe={};function ke(T){{var Y=ie();if(!Y){var se=typeof T=="string"?T:T.displayName||T.name;se&&(Y=`
|
|
24
|
+
|
|
25
|
+
Check the top-level render call using <`+se+">.")}return Y}}function Qe(T,Y){{if(!T._store||T._store.validated||T.key!=null)return;T._store.validated=!0;var se=ke(Y);if(xe[se])return;xe[se]=!0;var he="";T&&T._owner&&T._owner!==Mt.current&&(he=" It was passed a child from "+N(T._owner.type)+"."),be(T),x('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',se,he),be(null)}}function Ie(T,Y){{if(typeof T!="object")return;if(we(T))for(var se=0;se<T.length;se++){var he=T[se];ve(he)&&Qe(he,Y)}else if(ve(T))T._store&&(T._store.validated=!0);else if(T){var Ne=v(T);if(typeof Ne=="function"&&Ne!==T.entries)for(var je=Ne.call(T),Pe;!(Pe=je.next()).done;)ve(Pe.value)&&Qe(Pe.value,Y)}}}function Be(T){{var Y=T.type;if(Y==null||typeof Y=="string")return;var se;if(typeof Y=="function")se=Y.propTypes;else if(typeof Y=="object"&&(Y.$$typeof===c||Y.$$typeof===u))se=Y.propTypes;else return;if(se){var he=N(Y);Ee(se,T.props,"prop",he,T)}else if(Y.PropTypes!==void 0&&!Ce){Ce=!0;var Ne=N(Y);x("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",Ne||"Unknown")}typeof Y.getDefaultProps=="function"&&!Y.getDefaultProps.isReactClassApproved&&x("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function at(T){{for(var Y=Object.keys(T.props),se=0;se<Y.length;se++){var he=Y[se];if(he!=="children"&&he!=="key"){be(T),x("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",he),be(null);break}}T.ref!==null&&(be(T),x("Invalid attribute `ref` supplied to `React.Fragment`."),be(null))}}var et={};function it(T,Y,se,he,Ne,je){{var Pe=k(T);if(!Pe){var _e="";(T===void 0||typeof T=="object"&&T!==null&&Object.keys(T).length===0)&&(_e+=" 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 pt=Se();pt?_e+=pt:_e+=ie();var Ge;T===null?Ge="null":we(T)?Ge="array":T!==void 0&&T.$$typeof===t?(Ge="<"+(N(T.type)||"Unknown")+" />",_e=" Did you accidentally export a JSX literal instead of a component?"):Ge=typeof T,x("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",Ge,_e)}var Ye=Er(T,Y,se,Ne,je);if(Ye==null)return Ye;if(Pe){var _t=Y.children;if(_t!==void 0)if(he)if(we(_t)){for(var Wr=0;Wr<_t.length;Wr++)Ie(_t[Wr],T);Object.freeze&&Object.freeze(_t)}else x("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 Ie(_t,T)}if(pe.call(Y,"key")){var Pr=N(T),ht=Object.keys(Y).filter(function(LN){return LN!=="key"}),Vi=ht.length>0?"{key: someKey, "+ht.join(": ..., ")+": ...}":"{key: someKey}";if(!et[Pr+Vi]){var $N=ht.length>0?"{"+ht.join(": ..., ")+": ...}":"{}";x(`A props object containing a "key" prop is being spread into JSX:
|
|
26
|
+
let props = %s;
|
|
27
|
+
<%s {...props} />
|
|
28
|
+
React keys must be passed directly to JSX without using spread:
|
|
29
|
+
let props = %s;
|
|
30
|
+
<%s key={someKey} {...props} />`,Vi,Pr,$N,Pr),et[Pr+Vi]=!0}}return T===n?at(Ye):Be(Ye),Ye}}function zo(T,Y,se){return it(T,Y,se,!0)}function tr(T,Y,se){return it(T,Y,se,!1)}var Xp=tr,kN=zo;Dn.Fragment=n,Dn.jsx=Xp,Dn.jsxs=kN}()),Dn}var Qp;function zN(){return Qp||(Qp=1,process.env.NODE_ENV==="production"?Ho.exports=FN():Ho.exports=BN()),Ho.exports}var f=zN();function qN(e,t){const r=d.createContext(t),n=a=>{const{children:i,...s}=a,c=d.useMemo(()=>s,Object.values(s));return f.jsx(r.Provider,{value:c,children:i})};n.displayName=e+"Provider";function o(a){const i=d.useContext(r);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[n,o]}function De(e,t=[]){let r=[];function n(a,i){const s=d.createContext(i),c=r.length;r=[...r,i];const l=u=>{var y;const{scope:m,children:b,...g}=u,h=((y=m==null?void 0:m[e])==null?void 0:y[c])||s,v=d.useMemo(()=>g,Object.values(g));return f.jsx(h.Provider,{value:v,children:b})};l.displayName=a+"Provider";function p(u,m){var h;const b=((h=m==null?void 0:m[e])==null?void 0:h[c])||s,g=d.useContext(b);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${u}\` must be used within \`${a}\``)}return[l,p]}const o=()=>{const a=r.map(i=>d.createContext(i));return function(s){const c=(s==null?void 0:s[e])||a;return d.useMemo(()=>({[`__scope${e}`]:{...s,[e]:c}}),[s,c])}};return o.scopeName=e,[n,HN(o,...t)]}function HN(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const i=n.reduce((s,{useScope:c,scopeName:l})=>{const u=c(a)[`__scope${l}`];return{...s,...u}},{});return d.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return r.scopeName=t.scopeName,r}function em(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function go(...e){return t=>{let r=!1;const n=e.map(o=>{const a=em(o,t);return!r&&typeof a=="function"&&(r=!0),a});if(r)return()=>{for(let o=0;o<n.length;o++){const a=n[o];typeof a=="function"?a():em(e[o],null)}}}}function de(...e){return d.useCallback(go(...e),e)}var st=d.forwardRef((e,t)=>{const{children:r,...n}=e,o=d.Children.toArray(r),a=o.find(VN);if(a){const i=a.props.children,s=o.map(c=>c===a?d.Children.count(i)>1?d.Children.only(null):d.isValidElement(i)?i.props.children:null:c);return f.jsx(gu,{...n,ref:t,children:d.isValidElement(i)?d.cloneElement(i,void 0,s):null})}return f.jsx(gu,{...n,ref:t,children:r})});st.displayName="Slot";var gu=d.forwardRef((e,t)=>{const{children:r,...n}=e;if(d.isValidElement(r)){const o=UN(r),a=GN(n,r.props);return r.type!==d.Fragment&&(a.ref=t?go(t,o):o),d.cloneElement(r,a)}return d.Children.count(r)>1?d.Children.only(null):null});gu.displayName="SlotClone";var gd=({children:e})=>f.jsx(f.Fragment,{children:e});function VN(e){return d.isValidElement(e)&&e.type===gd}function GN(e,t){const r={...t};for(const n in t){const o=e[n],a=t[n];/^on[A-Z]/.test(n)?o&&a?r[n]=(...s)=>{a(...s),o(...s)}:o&&(r[n]=o):n==="style"?r[n]={...o,...a}:n==="className"&&(r[n]=[o,a].filter(Boolean).join(" "))}return{...e,...r}}function UN(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function cr(e){const t=e+"CollectionProvider",[r,n]=De(t),[o,a]=r(t,{collectionRef:{current:null},itemMap:new Map}),i=b=>{const{scope:g,children:h}=b,v=E.useRef(null),y=E.useRef(new Map).current;return f.jsx(o,{scope:g,itemMap:y,collectionRef:v,children:h})};i.displayName=t;const s=e+"CollectionSlot",c=E.forwardRef((b,g)=>{const{scope:h,children:v}=b,y=a(s,h),x=de(g,y.collectionRef);return f.jsx(st,{ref:x,children:v})});c.displayName=s;const l=e+"CollectionItemSlot",p="data-radix-collection-item",u=E.forwardRef((b,g)=>{const{scope:h,children:v,...y}=b,x=E.useRef(null),w=de(g,x),S=a(l,h);return E.useEffect(()=>(S.itemMap.set(x,{ref:x,...y}),()=>void S.itemMap.delete(x))),f.jsx(st,{[p]:"",ref:w,children:v})});u.displayName=l;function m(b){const g=a(e+"CollectionConsumer",b);return E.useCallback(()=>{const v=g.collectionRef.current;if(!v)return[];const y=Array.from(v.querySelectorAll(`[${p}]`));return Array.from(g.itemMap.values()).sort((S,_)=>y.indexOf(S.ref.current)-y.indexOf(_.ref.current))},[g.collectionRef,g.itemMap])}return[{Provider:i,Slot:c,ItemSlot:u},m,n]}function B(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e==null||e(o),r===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function Te(e){const t=d.useRef(e);return d.useEffect(()=>{t.current=e}),d.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function $e({prop:e,defaultProp:t,onChange:r=()=>{}}){const[n,o]=WN({defaultProp:t,onChange:r}),a=e!==void 0,i=a?e:n,s=Te(r),c=d.useCallback(l=>{if(a){const u=typeof l=="function"?l(e):l;u!==e&&s(u)}else o(l)},[a,e,o,s]);return[i,c]}function WN({defaultProp:e,onChange:t}){const r=d.useState(e),[n]=r,o=d.useRef(n),a=Te(t);return d.useEffect(()=>{o.current!==n&&(a(n),o.current=n)},[n,o,a]),r}var KN=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],X=KN.reduce((e,t)=>{const r=d.forwardRef((n,o)=>{const{asChild:a,...i}=n,s=a?st:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(s,{...i,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Xn(e,t){e&&ho.flushSync(()=>e.dispatchEvent(t))}var He=globalThis!=null&&globalThis.document?d.useLayoutEffect:()=>{};function YN(e,t){return d.useReducer((r,n)=>t[r][n]??r,e)}var Le=e=>{const{present:t,children:r}=e,n=XN(t),o=typeof r=="function"?r({present:n.isPresent}):d.Children.only(r),a=de(n.ref,ZN(o));return typeof r=="function"||n.isPresent?d.cloneElement(o,{ref:a}):null};Le.displayName="Presence";function XN(e){const[t,r]=d.useState(),n=d.useRef({}),o=d.useRef(e),a=d.useRef("none"),i=e?"mounted":"unmounted",[s,c]=YN(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return d.useEffect(()=>{const l=Vo(n.current);a.current=s==="mounted"?l:"none"},[s]),He(()=>{const l=n.current,p=o.current;if(p!==e){const m=a.current,b=Vo(l);e?c("MOUNT"):b==="none"||(l==null?void 0:l.display)==="none"?c("UNMOUNT"):c(p&&m!==b?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),He(()=>{if(t){let l;const p=t.ownerDocument.defaultView??window,u=b=>{const h=Vo(n.current).includes(b.animationName);if(b.target===t&&h&&(c("ANIMATION_END"),!o.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",l=p.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},m=b=>{b.target===t&&(a.current=Vo(n.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{p.clearTimeout(l),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:d.useCallback(l=>{l&&(n.current=getComputedStyle(l)),r(l)},[])}}function Vo(e){return(e==null?void 0:e.animationName)||"none"}function ZN(e){var n,o;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var JN=d.useId||(()=>{}),QN=0;function Ue(e){const[t,r]=d.useState(JN());return He(()=>{r(n=>n??String(QN++))},[e]),t?`radix-${t}`:""}var vd="Collapsible",[e1,Ab]=De(vd),[t1,bd]=e1(vd),Mb=d.forwardRef((e,t)=>{const{__scopeCollapsible:r,open:n,defaultOpen:o,disabled:a,onOpenChange:i,...s}=e,[c=!1,l]=$e({prop:n,defaultProp:o,onChange:i});return f.jsx(t1,{scope:r,disabled:a,contentId:Ue(),open:c,onOpenToggle:d.useCallback(()=>l(p=>!p),[l]),children:f.jsx(X.div,{"data-state":Sd(c),"data-disabled":a?"":void 0,...s,ref:t})})});Mb.displayName=vd;var Ob="CollapsibleTrigger",yd=d.forwardRef((e,t)=>{const{__scopeCollapsible:r,...n}=e,o=bd(Ob,r);return f.jsx(X.button,{type:"button","aria-controls":o.contentId,"aria-expanded":o.open||!1,"data-state":Sd(o.open),"data-disabled":o.disabled?"":void 0,disabled:o.disabled,...n,ref:t,onClick:B(e.onClick,o.onOpenToggle)})});yd.displayName=Ob;var xd="CollapsibleContent",wd=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=bd(xd,e.__scopeCollapsible);return f.jsx(Le,{present:r||o.open,children:({present:a})=>f.jsx(r1,{...n,ref:t,present:a})})});wd.displayName=xd;var r1=d.forwardRef((e,t)=>{const{__scopeCollapsible:r,present:n,children:o,...a}=e,i=bd(xd,r),[s,c]=d.useState(n),l=d.useRef(null),p=de(t,l),u=d.useRef(0),m=u.current,b=d.useRef(0),g=b.current,h=i.open||s,v=d.useRef(h),y=d.useRef(void 0);return d.useEffect(()=>{const x=requestAnimationFrame(()=>v.current=!1);return()=>cancelAnimationFrame(x)},[]),He(()=>{const x=l.current;if(x){y.current=y.current||{transitionDuration:x.style.transitionDuration,animationName:x.style.animationName},x.style.transitionDuration="0s",x.style.animationName="none";const w=x.getBoundingClientRect();u.current=w.height,b.current=w.width,v.current||(x.style.transitionDuration=y.current.transitionDuration,x.style.animationName=y.current.animationName),c(n)}},[i.open,n]),f.jsx(X.div,{"data-state":Sd(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!h,...a,ref:p,style:{"--radix-collapsible-content-height":m?`${m}px`:void 0,"--radix-collapsible-content-width":g?`${g}px`:void 0,...e.style},children:h&&o})});function Sd(e){return e?"open":"closed"}var Ib=Mb,n1=yd,o1=wd,a1=d.createContext(void 0);function Ft(e){const t=d.useContext(a1);return e||t||"ltr"}var lr="Accordion",i1=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[Cd,s1,c1]=cr(lr),[Ka,ZV]=De(lr,[c1,Ab]),_d=Ab(),jb=E.forwardRef((e,t)=>{const{type:r,...n}=e,o=n,a=n;return f.jsx(Cd.Provider,{scope:e.__scopeAccordion,children:r==="multiple"?f.jsx(f1,{...a,ref:t}):f.jsx(d1,{...o,ref:t})})});jb.displayName=lr;var[Db,l1]=Ka(lr),[kb,u1]=Ka(lr,{collapsible:!1}),d1=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},collapsible:a=!1,...i}=e,[s,c]=$e({prop:r,defaultProp:n,onChange:o});return f.jsx(Db,{scope:e.__scopeAccordion,value:s?[s]:[],onItemOpen:c,onItemClose:E.useCallback(()=>a&&c(""),[a,c]),children:f.jsx(kb,{scope:e.__scopeAccordion,collapsible:a,children:f.jsx($b,{...i,ref:t})})})}),f1=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},...a}=e,[i=[],s]=$e({prop:r,defaultProp:n,onChange:o}),c=E.useCallback(p=>s((u=[])=>[...u,p]),[s]),l=E.useCallback(p=>s((u=[])=>u.filter(m=>m!==p)),[s]);return f.jsx(Db,{scope:e.__scopeAccordion,value:i,onItemOpen:c,onItemClose:l,children:f.jsx(kb,{scope:e.__scopeAccordion,collapsible:!0,children:f.jsx($b,{...a,ref:t})})})}),[p1,Ya]=Ka(lr),$b=E.forwardRef((e,t)=>{const{__scopeAccordion:r,disabled:n,dir:o,orientation:a="vertical",...i}=e,s=E.useRef(null),c=de(s,t),l=s1(r),u=Ft(o)==="ltr",m=B(e.onKeyDown,b=>{var A;if(!i1.includes(b.key))return;const g=b.target,h=l().filter(P=>{var k;return!((k=P.ref.current)!=null&&k.disabled)}),v=h.findIndex(P=>P.ref.current===g),y=h.length;if(v===-1)return;b.preventDefault();let x=v;const w=0,S=y-1,_=()=>{x=v+1,x>S&&(x=w)},R=()=>{x=v-1,x<w&&(x=S)};switch(b.key){case"Home":x=w;break;case"End":x=S;break;case"ArrowRight":a==="horizontal"&&(u?_():R());break;case"ArrowDown":a==="vertical"&&_();break;case"ArrowLeft":a==="horizontal"&&(u?R():_());break;case"ArrowUp":a==="vertical"&&R();break}const C=x%y;(A=h[C].ref.current)==null||A.focus()});return f.jsx(p1,{scope:r,disabled:n,direction:o,orientation:a,children:f.jsx(Cd.Slot,{scope:r,children:f.jsx(X.div,{...i,"data-orientation":a,ref:c,onKeyDown:n?void 0:m})})})}),ga="AccordionItem",[m1,Rd]=Ka(ga),Lb=E.forwardRef((e,t)=>{const{__scopeAccordion:r,value:n,...o}=e,a=Ya(ga,r),i=l1(ga,r),s=_d(r),c=Ue(),l=n&&i.value.includes(n)||!1,p=a.disabled||e.disabled;return f.jsx(m1,{scope:r,open:l,disabled:p,triggerId:c,children:f.jsx(Ib,{"data-orientation":a.orientation,"data-state":Vb(l),...s,...o,ref:t,disabled:p,open:l,onOpenChange:u=>{u?i.onItemOpen(n):i.onItemClose(n)}})})});Lb.displayName=ga;var Fb="AccordionHeader",Bb=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=Ya(lr,r),a=Rd(Fb,r);return f.jsx(X.h3,{"data-orientation":o.orientation,"data-state":Vb(a.open),"data-disabled":a.disabled?"":void 0,...n,ref:t})});Bb.displayName=Fb;var vu="AccordionTrigger",zb=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=Ya(lr,r),a=Rd(vu,r),i=u1(vu,r),s=_d(r);return f.jsx(Cd.ItemSlot,{scope:r,children:f.jsx(n1,{"aria-disabled":a.open&&!i.collapsible||void 0,"data-orientation":o.orientation,id:a.triggerId,...s,...n,ref:t})})});zb.displayName=vu;var qb="AccordionContent",Hb=E.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,o=Ya(lr,r),a=Rd(qb,r),i=_d(r);return f.jsx(o1,{role:"region","aria-labelledby":a.triggerId,"data-orientation":o.orientation,...i,...n,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});Hb.displayName=qb;function Vb(e){return e?"open":"closed"}var h1=jb,g1=Lb,v1=Bb,Gb=zb,Ub=Hb;/**
|
|
31
|
+
* @license lucide-react v0.482.0 - ISC
|
|
32
|
+
*
|
|
33
|
+
* This source code is licensed under the ISC license.
|
|
34
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
35
|
+
*/const b1=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Wb=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).join(" ").trim();/**
|
|
36
|
+
* @license lucide-react v0.482.0 - ISC
|
|
37
|
+
*
|
|
38
|
+
* This source code is licensed under the ISC license.
|
|
39
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
40
|
+
*/var y1={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
|
|
41
|
+
* @license lucide-react v0.482.0 - ISC
|
|
42
|
+
*
|
|
43
|
+
* This source code is licensed under the ISC license.
|
|
44
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
45
|
+
*/const x1=E.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:o="",children:a,iconNode:i,...s},c)=>E.createElement("svg",{ref:c,...y1,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:Wb("lucide",o),...s},[...i.map(([l,p])=>E.createElement(l,p)),...Array.isArray(a)?a:[a]]));/**
|
|
46
|
+
* @license lucide-react v0.482.0 - ISC
|
|
47
|
+
*
|
|
48
|
+
* This source code is licensed under the ISC license.
|
|
49
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
50
|
+
*/const ct=(e,t)=>{const r=E.forwardRef(({className:n,...o},a)=>E.createElement(x1,{ref:a,iconNode:t,className:Wb(`lucide-${b1(e)}`,n),...o}));return r.displayName=`${e}`,r};/**
|
|
51
|
+
* @license lucide-react v0.482.0 - ISC
|
|
52
|
+
*
|
|
53
|
+
* This source code is licensed under the ISC license.
|
|
54
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
55
|
+
*/const w1=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],S1=ct("ArrowDown",w1);/**
|
|
56
|
+
* @license lucide-react v0.482.0 - ISC
|
|
57
|
+
*
|
|
58
|
+
* This source code is licensed under the ISC license.
|
|
59
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
60
|
+
*/const C1=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],_1=ct("ArrowLeft",C1);/**
|
|
61
|
+
* @license lucide-react v0.482.0 - ISC
|
|
62
|
+
*
|
|
63
|
+
* This source code is licensed under the ISC license.
|
|
64
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
65
|
+
*/const R1=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],E1=ct("ArrowRight",R1);/**
|
|
66
|
+
* @license lucide-react v0.482.0 - ISC
|
|
67
|
+
*
|
|
68
|
+
* This source code is licensed under the ISC license.
|
|
69
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
70
|
+
*/const P1=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],T1=ct("ArrowUp",P1);/**
|
|
71
|
+
* @license lucide-react v0.482.0 - ISC
|
|
72
|
+
*
|
|
73
|
+
* This source code is licensed under the ISC license.
|
|
74
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
75
|
+
*/const N1=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],vo=ct("Check",N1);/**
|
|
76
|
+
* @license lucide-react v0.482.0 - ISC
|
|
77
|
+
*
|
|
78
|
+
* This source code is licensed under the ISC license.
|
|
79
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
80
|
+
*/const A1=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Xa=ct("ChevronDown",A1);/**
|
|
81
|
+
* @license lucide-react v0.482.0 - ISC
|
|
82
|
+
*
|
|
83
|
+
* This source code is licensed under the ISC license.
|
|
84
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
85
|
+
*/const M1=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],O1=ct("ChevronLeft",M1);/**
|
|
86
|
+
* @license lucide-react v0.482.0 - ISC
|
|
87
|
+
*
|
|
88
|
+
* This source code is licensed under the ISC license.
|
|
89
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
90
|
+
*/const I1=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],Dr=ct("ChevronRight",I1);/**
|
|
91
|
+
* @license lucide-react v0.482.0 - ISC
|
|
92
|
+
*
|
|
93
|
+
* This source code is licensed under the ISC license.
|
|
94
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
95
|
+
*/const j1=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],D1=ct("ChevronUp",j1);/**
|
|
96
|
+
* @license lucide-react v0.482.0 - ISC
|
|
97
|
+
*
|
|
98
|
+
* This source code is licensed under the ISC license.
|
|
99
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
100
|
+
*/const k1=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],Za=ct("Circle",k1);/**
|
|
101
|
+
* @license lucide-react v0.482.0 - ISC
|
|
102
|
+
*
|
|
103
|
+
* This source code is licensed under the ISC license.
|
|
104
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
105
|
+
*/const $1=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],Ed=ct("Ellipsis",$1);/**
|
|
106
|
+
* @license lucide-react v0.482.0 - ISC
|
|
107
|
+
*
|
|
108
|
+
* This source code is licensed under the ISC license.
|
|
109
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
110
|
+
*/const L1=[["circle",{cx:"9",cy:"12",r:"1",key:"1vctgf"}],["circle",{cx:"9",cy:"5",r:"1",key:"hp0tcf"}],["circle",{cx:"9",cy:"19",r:"1",key:"fkjjf6"}],["circle",{cx:"15",cy:"12",r:"1",key:"1tmaij"}],["circle",{cx:"15",cy:"5",r:"1",key:"19l28e"}],["circle",{cx:"15",cy:"19",r:"1",key:"f4zoj3"}]],F1=ct("GripVertical",L1);/**
|
|
111
|
+
* @license lucide-react v0.482.0 - ISC
|
|
112
|
+
*
|
|
113
|
+
* This source code is licensed under the ISC license.
|
|
114
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
115
|
+
*/const B1=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"1d0kgt"}]],z1=ct("House",B1);/**
|
|
116
|
+
* @license lucide-react v0.482.0 - ISC
|
|
117
|
+
*
|
|
118
|
+
* This source code is licensed under the ISC license.
|
|
119
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
120
|
+
*/const q1=[["path",{d:"M5 12h14",key:"1ays0h"}]],H1=ct("Minus",q1);/**
|
|
121
|
+
* @license lucide-react v0.482.0 - ISC
|
|
122
|
+
*
|
|
123
|
+
* This source code is licensed under the ISC license.
|
|
124
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
125
|
+
*/const V1=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],G1=ct("PanelLeft",V1);/**
|
|
126
|
+
* @license lucide-react v0.482.0 - ISC
|
|
127
|
+
*
|
|
128
|
+
* This source code is licensed under the ISC license.
|
|
129
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
130
|
+
*/const U1=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Pd=ct("X",U1);function Kb(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(r=Kb(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function ar(){for(var e,t,r=0,n="",o=arguments.length;r<o;r++)(e=arguments[r])&&(t=Kb(e))&&(n&&(n+=" "),n+=t);return n}const Td="-",W1=e=>{const t=Y1(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:i=>{const s=i.split(Td);return s[0]===""&&s.length!==1&&s.shift(),Yb(s,t)||K1(i)},getConflictingClassGroupIds:(i,s)=>{const c=r[i]||[];return s&&n[i]?[...c,...n[i]]:c}}},Yb=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),o=n?Yb(e.slice(1),n):void 0;if(o)return o;if(t.validators.length===0)return;const a=e.join(Td);return(i=t.validators.find(({validator:s})=>s(a)))==null?void 0:i.classGroupId},tm=/^\[(.+)\]$/,K1=e=>{if(tm.test(e)){const t=tm.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},Y1=e=>{const{theme:t,classGroups:r}=e,n={nextPart:new Map,validators:[]};for(const o in r)bu(r[o],n,o,t);return n},bu=(e,t,r,n)=>{e.forEach(o=>{if(typeof o=="string"){const a=o===""?t:rm(t,o);a.classGroupId=r;return}if(typeof o=="function"){if(X1(o)){bu(o(n),t,r,n);return}t.validators.push({validator:o,classGroupId:r});return}Object.entries(o).forEach(([a,i])=>{bu(i,rm(t,a),r,n)})})},rm=(e,t)=>{let r=e;return t.split(Td).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},X1=e=>e.isThemeGetter,Z1=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const o=(a,i)=>{r.set(a,i),t++,t>e&&(t=0,n=r,r=new Map)};return{get(a){let i=r.get(a);if(i!==void 0)return i;if((i=n.get(a))!==void 0)return o(a,i),i},set(a,i){r.has(a)?r.set(a,i):o(a,i)}}},yu="!",xu=":",J1=xu.length,Q1=e=>{const{prefix:t,experimentalParseClassName:r}=e;let n=o=>{const a=[];let i=0,s=0,c=0,l;for(let g=0;g<o.length;g++){let h=o[g];if(i===0&&s===0){if(h===xu){a.push(o.slice(c,g)),c=g+J1;continue}if(h==="/"){l=g;continue}}h==="["?i++:h==="]"?i--:h==="("?s++:h===")"&&s--}const p=a.length===0?o:o.substring(c),u=eA(p),m=u!==p,b=l&&l>c?l-c:void 0;return{modifiers:a,hasImportantModifier:m,baseClassName:u,maybePostfixModifierPosition:b}};if(t){const o=t+xu,a=n;n=i=>i.startsWith(o)?a(i.substring(o.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:i,maybePostfixModifierPosition:void 0}}if(r){const o=n;n=a=>r({className:a,parseClassName:o})}return n},eA=e=>e.endsWith(yu)?e.substring(0,e.length-1):e.startsWith(yu)?e.substring(1):e,tA=e=>{const t=Object.fromEntries(e.orderSensitiveModifiers.map(n=>[n,!0]));return n=>{if(n.length<=1)return n;const o=[];let a=[];return n.forEach(i=>{i[0]==="["||t[i]?(o.push(...a.sort(),i),a=[]):a.push(i)}),o.push(...a.sort()),o}},rA=e=>({cache:Z1(e.cacheSize),parseClassName:Q1(e),sortModifiers:tA(e),...W1(e)}),nA=/\s+/,oA=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:o,sortModifiers:a}=t,i=[],s=e.trim().split(nA);let c="";for(let l=s.length-1;l>=0;l-=1){const p=s[l],{isExternal:u,modifiers:m,hasImportantModifier:b,baseClassName:g,maybePostfixModifierPosition:h}=r(p);if(u){c=p+(c.length>0?" "+c:c);continue}let v=!!h,y=n(v?g.substring(0,h):g);if(!y){if(!v){c=p+(c.length>0?" "+c:c);continue}if(y=n(g),!y){c=p+(c.length>0?" "+c:c);continue}v=!1}const x=a(m).join(":"),w=b?x+yu:x,S=w+y;if(i.includes(S))continue;i.push(S);const _=o(y,v);for(let R=0;R<_.length;++R){const C=_[R];i.push(w+C)}c=p+(c.length>0?" "+c:c)}return c};function aA(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=Xb(t))&&(n&&(n+=" "),n+=r);return n}const Xb=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=Xb(e[n]))&&(r&&(r+=" "),r+=t);return r};function iA(e,...t){let r,n,o,a=i;function i(c){const l=t.reduce((p,u)=>u(p),e());return r=rA(l),n=r.cache.get,o=r.cache.set,a=s,s(c)}function s(c){const l=n(c);if(l)return l;const p=oA(c,r);return o(c,p),p}return function(){return a(aA.apply(null,arguments))}}const nt=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},Zb=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Jb=/^\((?:(\w[\w-]*):)?(.+)\)$/i,sA=/^\d+\/\d+$/,cA=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,lA=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,uA=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,dA=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,fA=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Kr=e=>sA.test(e),Re=e=>!!e&&!Number.isNaN(Number(e)),Tr=e=>!!e&&Number.isInteger(Number(e)),nm=e=>e.endsWith("%")&&Re(e.slice(0,-1)),mr=e=>cA.test(e),pA=()=>!0,mA=e=>lA.test(e)&&!uA.test(e),Nd=()=>!1,hA=e=>dA.test(e),gA=e=>fA.test(e),vA=e=>!ce(e)&&!le(e),bA=e=>bn(e,ty,Nd),ce=e=>Zb.test(e),Nr=e=>bn(e,ry,mA),Gi=e=>bn(e,NA,Re),yA=e=>bn(e,Qb,Nd),xA=e=>bn(e,ey,gA),wA=e=>bn(e,Nd,hA),le=e=>Jb.test(e),Go=e=>yn(e,ry),SA=e=>yn(e,AA),CA=e=>yn(e,Qb),_A=e=>yn(e,ty),RA=e=>yn(e,ey),EA=e=>yn(e,MA,!0),bn=(e,t,r)=>{const n=Zb.exec(e);return n?n[1]?t(n[1]):r(n[2]):!1},yn=(e,t,r=!1)=>{const n=Jb.exec(e);return n?n[1]?t(n[1]):r:!1},Qb=e=>e==="position",PA=new Set(["image","url"]),ey=e=>PA.has(e),TA=new Set(["length","size","percentage"]),ty=e=>TA.has(e),ry=e=>e==="length",NA=e=>e==="number",AA=e=>e==="family-name",MA=e=>e==="shadow",OA=()=>{const e=nt("color"),t=nt("font"),r=nt("text"),n=nt("font-weight"),o=nt("tracking"),a=nt("leading"),i=nt("breakpoint"),s=nt("container"),c=nt("spacing"),l=nt("radius"),p=nt("shadow"),u=nt("inset-shadow"),m=nt("drop-shadow"),b=nt("blur"),g=nt("perspective"),h=nt("aspect"),v=nt("ease"),y=nt("animate"),x=()=>["auto","avoid","all","avoid-page","page","left","right","column"],w=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],S=()=>["auto","hidden","clip","visible","scroll"],_=()=>["auto","contain","none"],R=()=>[le,ce,c],C=()=>[Kr,"full","auto",...R()],A=()=>[Tr,"none","subgrid",le,ce],P=()=>["auto",{span:["full",Tr,le,ce]},le,ce],k=()=>[Tr,"auto",le,ce],j=()=>["auto","min","max","fr",le,ce],L=()=>["start","end","center","between","around","evenly","stretch","baseline"],N=()=>["start","end","center","stretch"],D=()=>["auto",...R()],$=()=>[Kr,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...R()],O=()=>[e,le,ce],G=()=>[nm,Nr],H=()=>["","none","full",l,le,ce],z=()=>["",Re,Go,Nr],oe=()=>["solid","dashed","dotted","double"],Z=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],te=()=>["","none",b,le,ce],F=()=>["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",le,ce],U=()=>["none",Re,le,ce],Q=()=>["none",Re,le,ce],K=()=>[Re,le,ce],q=()=>[Kr,"full",...R()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[mr],breakpoint:[mr],color:[pA],container:[mr],"drop-shadow":[mr],ease:["in","out","in-out"],font:[vA],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[mr],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[mr],shadow:[mr],spacing:["px",Re],text:[mr],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Kr,ce,le,h]}],container:["container"],columns:[{columns:[Re,ce,le,s]}],"break-after":[{"break-after":x()}],"break-before":[{"break-before":x()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...w(),ce,le]}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:_()}],"overscroll-x":[{"overscroll-x":_()}],"overscroll-y":[{"overscroll-y":_()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:C()}],"inset-x":[{"inset-x":C()}],"inset-y":[{"inset-y":C()}],start:[{start:C()}],end:[{end:C()}],top:[{top:C()}],right:[{right:C()}],bottom:[{bottom:C()}],left:[{left:C()}],visibility:["visible","invisible","collapse"],z:[{z:[Tr,"auto",le,ce]}],basis:[{basis:[Kr,"full","auto",s,...R()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Re,Kr,"auto","initial","none",ce]}],grow:[{grow:["",Re,le,ce]}],shrink:[{shrink:["",Re,le,ce]}],order:[{order:[Tr,"first","last","none",le,ce]}],"grid-cols":[{"grid-cols":A()}],"col-start-end":[{col:P()}],"col-start":[{"col-start":k()}],"col-end":[{"col-end":k()}],"grid-rows":[{"grid-rows":A()}],"row-start-end":[{row:P()}],"row-start":[{"row-start":k()}],"row-end":[{"row-end":k()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":j()}],"auto-rows":[{"auto-rows":j()}],gap:[{gap:R()}],"gap-x":[{"gap-x":R()}],"gap-y":[{"gap-y":R()}],"justify-content":[{justify:[...L(),"normal"]}],"justify-items":[{"justify-items":[...N(),"normal"]}],"justify-self":[{"justify-self":["auto",...N()]}],"align-content":[{content:["normal",...L()]}],"align-items":[{items:[...N(),"baseline"]}],"align-self":[{self:["auto",...N(),"baseline"]}],"place-content":[{"place-content":L()}],"place-items":[{"place-items":[...N(),"baseline"]}],"place-self":[{"place-self":["auto",...N()]}],p:[{p:R()}],px:[{px:R()}],py:[{py:R()}],ps:[{ps:R()}],pe:[{pe:R()}],pt:[{pt:R()}],pr:[{pr:R()}],pb:[{pb:R()}],pl:[{pl:R()}],m:[{m:D()}],mx:[{mx:D()}],my:[{my:D()}],ms:[{ms:D()}],me:[{me:D()}],mt:[{mt:D()}],mr:[{mr:D()}],mb:[{mb:D()}],ml:[{ml:D()}],"space-x":[{"space-x":R()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":R()}],"space-y-reverse":["space-y-reverse"],size:[{size:$()}],w:[{w:[s,"screen",...$()]}],"min-w":[{"min-w":[s,"screen","none",...$()]}],"max-w":[{"max-w":[s,"screen","none","prose",{screen:[i]},...$()]}],h:[{h:["screen",...$()]}],"min-h":[{"min-h":["screen","none",...$()]}],"max-h":[{"max-h":["screen",...$()]}],"font-size":[{text:["base",r,Go,Nr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[n,le,Gi]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",nm,ce]}],"font-family":[{font:[SA,ce,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,le,ce]}],"line-clamp":[{"line-clamp":[Re,"none",le,Gi]}],leading:[{leading:[a,...R()]}],"list-image":[{"list-image":["none",le,ce]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",le,ce]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:O()}],"text-color":[{text:O()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...oe(),"wavy"]}],"text-decoration-thickness":[{decoration:[Re,"from-font","auto",le,Nr]}],"text-decoration-color":[{decoration:O()}],"underline-offset":[{"underline-offset":[Re,"auto",le,ce]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:R()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",le,ce]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",le,ce]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...w(),CA,yA]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","space","round"]}]}],"bg-size":[{bg:["auto","cover","contain",_A,bA]}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Tr,le,ce],radial:["",le,ce],conic:[Tr,le,ce]},RA,xA]}],"bg-color":[{bg:O()}],"gradient-from-pos":[{from:G()}],"gradient-via-pos":[{via:G()}],"gradient-to-pos":[{to:G()}],"gradient-from":[{from:O()}],"gradient-via":[{via:O()}],"gradient-to":[{to:O()}],rounded:[{rounded:H()}],"rounded-s":[{"rounded-s":H()}],"rounded-e":[{"rounded-e":H()}],"rounded-t":[{"rounded-t":H()}],"rounded-r":[{"rounded-r":H()}],"rounded-b":[{"rounded-b":H()}],"rounded-l":[{"rounded-l":H()}],"rounded-ss":[{"rounded-ss":H()}],"rounded-se":[{"rounded-se":H()}],"rounded-ee":[{"rounded-ee":H()}],"rounded-es":[{"rounded-es":H()}],"rounded-tl":[{"rounded-tl":H()}],"rounded-tr":[{"rounded-tr":H()}],"rounded-br":[{"rounded-br":H()}],"rounded-bl":[{"rounded-bl":H()}],"border-w":[{border:z()}],"border-w-x":[{"border-x":z()}],"border-w-y":[{"border-y":z()}],"border-w-s":[{"border-s":z()}],"border-w-e":[{"border-e":z()}],"border-w-t":[{"border-t":z()}],"border-w-r":[{"border-r":z()}],"border-w-b":[{"border-b":z()}],"border-w-l":[{"border-l":z()}],"divide-x":[{"divide-x":z()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":z()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...oe(),"hidden","none"]}],"divide-style":[{divide:[...oe(),"hidden","none"]}],"border-color":[{border:O()}],"border-color-x":[{"border-x":O()}],"border-color-y":[{"border-y":O()}],"border-color-s":[{"border-s":O()}],"border-color-e":[{"border-e":O()}],"border-color-t":[{"border-t":O()}],"border-color-r":[{"border-r":O()}],"border-color-b":[{"border-b":O()}],"border-color-l":[{"border-l":O()}],"divide-color":[{divide:O()}],"outline-style":[{outline:[...oe(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Re,le,ce]}],"outline-w":[{outline:["",Re,Go,Nr]}],"outline-color":[{outline:[e]}],shadow:[{shadow:["","none",p,EA,wA]}],"shadow-color":[{shadow:O()}],"inset-shadow":[{"inset-shadow":["none",le,ce,u]}],"inset-shadow-color":[{"inset-shadow":O()}],"ring-w":[{ring:z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:O()}],"ring-offset-w":[{"ring-offset":[Re,Nr]}],"ring-offset-color":[{"ring-offset":O()}],"inset-ring-w":[{"inset-ring":z()}],"inset-ring-color":[{"inset-ring":O()}],opacity:[{opacity:[Re,le,ce]}],"mix-blend":[{"mix-blend":[...Z(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Z()}],filter:[{filter:["","none",le,ce]}],blur:[{blur:te()}],brightness:[{brightness:[Re,le,ce]}],contrast:[{contrast:[Re,le,ce]}],"drop-shadow":[{"drop-shadow":["","none",m,le,ce]}],grayscale:[{grayscale:["",Re,le,ce]}],"hue-rotate":[{"hue-rotate":[Re,le,ce]}],invert:[{invert:["",Re,le,ce]}],saturate:[{saturate:[Re,le,ce]}],sepia:[{sepia:["",Re,le,ce]}],"backdrop-filter":[{"backdrop-filter":["","none",le,ce]}],"backdrop-blur":[{"backdrop-blur":te()}],"backdrop-brightness":[{"backdrop-brightness":[Re,le,ce]}],"backdrop-contrast":[{"backdrop-contrast":[Re,le,ce]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Re,le,ce]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Re,le,ce]}],"backdrop-invert":[{"backdrop-invert":["",Re,le,ce]}],"backdrop-opacity":[{"backdrop-opacity":[Re,le,ce]}],"backdrop-saturate":[{"backdrop-saturate":[Re,le,ce]}],"backdrop-sepia":[{"backdrop-sepia":["",Re,le,ce]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":R()}],"border-spacing-x":[{"border-spacing-x":R()}],"border-spacing-y":[{"border-spacing-y":R()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",le,ce]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Re,"initial",le,ce]}],ease:[{ease:["linear","initial",v,le,ce]}],delay:[{delay:[Re,le,ce]}],animate:[{animate:["none",y,le,ce]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[g,le,ce]}],"perspective-origin":[{"perspective-origin":F()}],rotate:[{rotate:U()}],"rotate-x":[{"rotate-x":U()}],"rotate-y":[{"rotate-y":U()}],"rotate-z":[{"rotate-z":U()}],scale:[{scale:Q()}],"scale-x":[{"scale-x":Q()}],"scale-y":[{"scale-y":Q()}],"scale-z":[{"scale-z":Q()}],"scale-3d":["scale-3d"],skew:[{skew:K()}],"skew-x":[{"skew-x":K()}],"skew-y":[{"skew-y":K()}],transform:[{transform:[le,ce,"","none","gpu","cpu"]}],"transform-origin":[{origin:F()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:q()}],"translate-x":[{"translate-x":q()}],"translate-y":[{"translate-y":q()}],"translate-z":[{"translate-z":q()}],"translate-none":["translate-none"],accent:[{accent:O()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:O()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",le,ce]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":R()}],"scroll-mx":[{"scroll-mx":R()}],"scroll-my":[{"scroll-my":R()}],"scroll-ms":[{"scroll-ms":R()}],"scroll-me":[{"scroll-me":R()}],"scroll-mt":[{"scroll-mt":R()}],"scroll-mr":[{"scroll-mr":R()}],"scroll-mb":[{"scroll-mb":R()}],"scroll-ml":[{"scroll-ml":R()}],"scroll-p":[{"scroll-p":R()}],"scroll-px":[{"scroll-px":R()}],"scroll-py":[{"scroll-py":R()}],"scroll-ps":[{"scroll-ps":R()}],"scroll-pe":[{"scroll-pe":R()}],"scroll-pt":[{"scroll-pt":R()}],"scroll-pr":[{"scroll-pr":R()}],"scroll-pb":[{"scroll-pb":R()}],"scroll-pl":[{"scroll-pl":R()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",le,ce]}],fill:[{fill:["none",...O()]}],"stroke-w":[{stroke:[Re,Go,Nr,Gi]}],stroke:[{stroke:["none",...O()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["before","after","placeholder","file","marker","selection","first-line","first-letter","backdrop","*","**"]}},IA=iA(OA);function M(...e){return IA(ar(e))}const jA=h1,ny=d.forwardRef(({className:e,...t},r)=>f.jsx(g1,{ref:r,className:M("border-b",e),...t}));ny.displayName="AccordionItem";const oy=d.forwardRef(({className:e,children:t,...r},n)=>f.jsx(v1,{className:"flex",children:f.jsxs(Gb,{ref:n,className:M("flex flex-1 items-center justify-between py-4 text-sm font-medium transition-all hover:underline text-left [&[data-state=open]>svg]:rotate-180",e),...r,children:[t,f.jsx(Xa,{className:"h-4 w-4 shrink-0 text-muted-foreground transition-transform duration-200"})]})}));oy.displayName=Gb.displayName;const ay=d.forwardRef(({className:e,children:t,...r},n)=>f.jsx(Ub,{ref:n,className:"overflow-hidden text-sm data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",...r,children:f.jsx("div",{className:M("pb-4 pt-0",e),children:t})}));ay.displayName=Ub.displayName;function DA(e,t=globalThis==null?void 0:globalThis.document){const r=Te(e);d.useEffect(()=>{const n=o=>{o.key==="Escape"&&r(o)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var kA="DismissableLayer",wu="dismissableLayer.update",$A="dismissableLayer.pointerDownOutside",LA="dismissableLayer.focusOutside",om,iy=d.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),ur=d.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:i,onDismiss:s,...c}=e,l=d.useContext(iy),[p,u]=d.useState(null),m=(p==null?void 0:p.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,b]=d.useState({}),g=de(t,C=>u(C)),h=Array.from(l.layers),[v]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),y=h.indexOf(v),x=p?h.indexOf(p):-1,w=l.layersWithOutsidePointerEventsDisabled.size>0,S=x>=y,_=BA(C=>{const A=C.target,P=[...l.branches].some(k=>k.contains(A));!S||P||(o==null||o(C),i==null||i(C),C.defaultPrevented||s==null||s())},m),R=zA(C=>{const A=C.target;[...l.branches].some(k=>k.contains(A))||(a==null||a(C),i==null||i(C),C.defaultPrevented||s==null||s())},m);return DA(C=>{x===l.layers.size-1&&(n==null||n(C),!C.defaultPrevented&&s&&(C.preventDefault(),s()))},m),d.useEffect(()=>{if(p)return r&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(om=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(p)),l.layers.add(p),am(),()=>{r&&l.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=om)}},[p,m,r,l]),d.useEffect(()=>()=>{p&&(l.layers.delete(p),l.layersWithOutsidePointerEventsDisabled.delete(p),am())},[p,l]),d.useEffect(()=>{const C=()=>b({});return document.addEventListener(wu,C),()=>document.removeEventListener(wu,C)},[]),f.jsx(X.div,{...c,ref:g,style:{pointerEvents:w?S?"auto":"none":void 0,...e.style},onFocusCapture:B(e.onFocusCapture,R.onFocusCapture),onBlurCapture:B(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:B(e.onPointerDownCapture,_.onPointerDownCapture)})});ur.displayName=kA;var FA="DismissableLayerBranch",sy=d.forwardRef((e,t)=>{const r=d.useContext(iy),n=d.useRef(null),o=de(t,n);return d.useEffect(()=>{const a=n.current;if(a)return r.branches.add(a),()=>{r.branches.delete(a)}},[r.branches]),f.jsx(X.div,{...e,ref:o})});sy.displayName=FA;function BA(e,t=globalThis==null?void 0:globalThis.document){const r=Te(e),n=d.useRef(!1),o=d.useRef(()=>{});return d.useEffect(()=>{const a=s=>{if(s.target&&!n.current){let c=function(){cy($A,r,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);n.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function zA(e,t=globalThis==null?void 0:globalThis.document){const r=Te(e),n=d.useRef(!1);return d.useEffect(()=>{const o=a=>{a.target&&!n.current&&cy(LA,r,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function am(){const e=new CustomEvent(wu);document.dispatchEvent(e)}function cy(e,t,r,{discrete:n}){const o=r.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?Xn(o,a):o.dispatchEvent(a)}var qA=ur,HA=sy,Ui="focusScope.autoFocusOnMount",Wi="focusScope.autoFocusOnUnmount",im={bubbles:!1,cancelable:!0},VA="FocusScope",bo=d.forwardRef((e,t)=>{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...i}=e,[s,c]=d.useState(null),l=Te(o),p=Te(a),u=d.useRef(null),m=de(t,h=>c(h)),b=d.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;d.useEffect(()=>{if(n){let h=function(w){if(b.paused||!s)return;const S=w.target;s.contains(S)?u.current=S:hr(u.current,{select:!0})},v=function(w){if(b.paused||!s)return;const S=w.relatedTarget;S!==null&&(s.contains(S)||hr(u.current,{select:!0}))},y=function(w){if(document.activeElement===document.body)for(const _ of w)_.removedNodes.length>0&&hr(s)};document.addEventListener("focusin",h),document.addEventListener("focusout",v);const x=new MutationObserver(y);return s&&x.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",v),x.disconnect()}}},[n,s,b.paused]),d.useEffect(()=>{if(s){cm.add(b);const h=document.activeElement;if(!s.contains(h)){const y=new CustomEvent(Ui,im);s.addEventListener(Ui,l),s.dispatchEvent(y),y.defaultPrevented||(GA(XA(ly(s)),{select:!0}),document.activeElement===h&&hr(s))}return()=>{s.removeEventListener(Ui,l),setTimeout(()=>{const y=new CustomEvent(Wi,im);s.addEventListener(Wi,p),s.dispatchEvent(y),y.defaultPrevented||hr(h??document.body,{select:!0}),s.removeEventListener(Wi,p),cm.remove(b)},0)}}},[s,l,p,b]);const g=d.useCallback(h=>{if(!r&&!n||b.paused)return;const v=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,y=document.activeElement;if(v&&y){const x=h.currentTarget,[w,S]=UA(x);w&&S?!h.shiftKey&&y===S?(h.preventDefault(),r&&hr(w,{select:!0})):h.shiftKey&&y===w&&(h.preventDefault(),r&&hr(S,{select:!0})):y===x&&h.preventDefault()}},[r,n,b.paused]);return f.jsx(X.div,{tabIndex:-1,...i,ref:m,onKeyDown:g})});bo.displayName=VA;function GA(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(hr(n,{select:t}),document.activeElement!==r)return}function UA(e){const t=ly(e),r=sm(t,e),n=sm(t.reverse(),e);return[r,n]}function ly(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function sm(e,t){for(const r of e)if(!WA(r,{upTo:t}))return r}function WA(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 KA(e){return e instanceof HTMLInputElement&&"select"in e}function hr(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&KA(e)&&t&&e.select()}}var cm=YA();function YA(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=lm(e,t),e.unshift(t)},remove(t){var r;e=lm(e,t),(r=e[0])==null||r.resume()}}}function lm(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function XA(e){return e.filter(t=>t.tagName!=="A")}var ZA="Portal",zr=d.forwardRef((e,t)=>{var s;const{container:r,...n}=e,[o,a]=d.useState(!1);He(()=>a(!0),[]);const i=r||o&&((s=globalThis==null?void 0:globalThis.document)==null?void 0:s.body);return i?Wa.createPortal(f.jsx(X.div,{...n,ref:t}),i):null});zr.displayName=ZA;var Ki=0;function Ja(){d.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??um()),document.body.insertAdjacentElement("beforeend",e[1]??um()),Ki++,()=>{Ki===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Ki--}},[])}function um(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Ut=function(){return Ut=Object.assign||function(t){for(var r,n=1,o=arguments.length;n<o;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},Ut.apply(this,arguments)};function uy(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r}function JA(e,t,r){if(r||arguments.length===2)for(var n=0,o=t.length,a;n<o;n++)(a||!(n in t))&&(a||(a=Array.prototype.slice.call(t,0,n)),a[n]=t[n]);return e.concat(a||Array.prototype.slice.call(t))}var la="right-scroll-bar-position",ua="width-before-scroll-bar",QA="with-scroll-bars-hidden",eM="--removed-body-scroll-bar-size";function Yi(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function tM(e,t){var r=E.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var o=r.value;o!==n&&(r.value=n,r.callback(n,o))}}}})[0];return r.callback=t,r.facade}var rM=typeof window<"u"?d.useLayoutEffect:d.useEffect,dm=new WeakMap;function nM(e,t){var r=tM(null,function(n){return e.forEach(function(o){return Yi(o,n)})});return rM(function(){var n=dm.get(r);if(n){var o=new Set(n),a=new Set(e),i=r.current;o.forEach(function(s){a.has(s)||Yi(s,null)}),a.forEach(function(s){o.has(s)||Yi(s,i)})}dm.set(r,e)},[e]),r}function oM(e){return e}function aM(e,t){t===void 0&&(t=oM);var r=[],n=!1,o={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(a){var i=t(a,n);return r.push(i),function(){r=r.filter(function(s){return s!==i})}},assignSyncMedium:function(a){for(n=!0;r.length;){var i=r;r=[],i.forEach(a)}r={push:function(s){return a(s)},filter:function(){return r}}},assignMedium:function(a){n=!0;var i=[];if(r.length){var s=r;r=[],s.forEach(a),i=r}var c=function(){var p=i;i=[],p.forEach(a)},l=function(){return Promise.resolve().then(c)};l(),r={push:function(p){i.push(p),l()},filter:function(p){return i=i.filter(p),r}}}};return o}function iM(e){e===void 0&&(e={});var t=aM(null);return t.options=Ut({async:!0,ssr:!1},e),t}var dy=function(e){var t=e.sideCar,r=uy(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return d.createElement(n,Ut({},r))};dy.isSideCarExport=!0;function sM(e,t){return e.useMedium(t),dy}var fy=iM(),Xi=function(){},Qa=d.forwardRef(function(e,t){var r=d.useRef(null),n=d.useState({onScrollCapture:Xi,onWheelCapture:Xi,onTouchMoveCapture:Xi}),o=n[0],a=n[1],i=e.forwardProps,s=e.children,c=e.className,l=e.removeScrollBar,p=e.enabled,u=e.shards,m=e.sideCar,b=e.noIsolation,g=e.inert,h=e.allowPinchZoom,v=e.as,y=v===void 0?"div":v,x=e.gapMode,w=uy(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=m,_=nM([r,t]),R=Ut(Ut({},w),o);return d.createElement(d.Fragment,null,p&&d.createElement(S,{sideCar:fy,removeScrollBar:l,shards:u,noIsolation:b,inert:g,setCallbacks:a,allowPinchZoom:!!h,lockRef:r,gapMode:x}),i?d.cloneElement(d.Children.only(s),Ut(Ut({},R),{ref:_})):d.createElement(y,Ut({},R,{className:c,ref:_}),s))});Qa.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Qa.classNames={fullWidth:ua,zeroRight:la};var cM=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function lM(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=cM();return t&&e.setAttribute("nonce",t),e}function uM(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function dM(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var fM=function(){var e=0,t=null;return{add:function(r){e==0&&(t=lM())&&(uM(t,r),dM(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},pM=function(){var e=fM();return function(t,r){d.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},py=function(){var e=pM(),t=function(r){var n=r.styles,o=r.dynamic;return e(n,o),null};return t},mM={left:0,top:0,right:0,gap:0},Zi=function(e){return parseInt(e||"",10)||0},hM=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Zi(r),Zi(n),Zi(o)]},gM=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return mM;var t=hM(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},vM=py(),rn="data-scroll-locked",bM=function(e,t,r,n){var o=e.left,a=e.top,i=e.right,s=e.gap;return r===void 0&&(r="margin"),`
|
|
131
|
+
.`.concat(QA,` {
|
|
132
|
+
overflow: hidden `).concat(n,`;
|
|
133
|
+
padding-right: `).concat(s,"px ").concat(n,`;
|
|
134
|
+
}
|
|
135
|
+
body[`).concat(rn,`] {
|
|
136
|
+
overflow: hidden `).concat(n,`;
|
|
137
|
+
overscroll-behavior: contain;
|
|
138
|
+
`).concat([t&&"position: relative ".concat(n,";"),r==="margin"&&`
|
|
139
|
+
padding-left: `.concat(o,`px;
|
|
140
|
+
padding-top: `).concat(a,`px;
|
|
141
|
+
padding-right: `).concat(i,`px;
|
|
142
|
+
margin-left:0;
|
|
143
|
+
margin-top:0;
|
|
144
|
+
margin-right: `).concat(s,"px ").concat(n,`;
|
|
145
|
+
`),r==="padding"&&"padding-right: ".concat(s,"px ").concat(n,";")].filter(Boolean).join(""),`
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.`).concat(la,` {
|
|
149
|
+
right: `).concat(s,"px ").concat(n,`;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.`).concat(ua,` {
|
|
153
|
+
margin-right: `).concat(s,"px ").concat(n,`;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.`).concat(la," .").concat(la,` {
|
|
157
|
+
right: 0 `).concat(n,`;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.`).concat(ua," .").concat(ua,` {
|
|
161
|
+
margin-right: 0 `).concat(n,`;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
body[`).concat(rn,`] {
|
|
165
|
+
`).concat(eM,": ").concat(s,`px;
|
|
166
|
+
}
|
|
167
|
+
`)},fm=function(){var e=parseInt(document.body.getAttribute(rn)||"0",10);return isFinite(e)?e:0},yM=function(){d.useEffect(function(){return document.body.setAttribute(rn,(fm()+1).toString()),function(){var e=fm()-1;e<=0?document.body.removeAttribute(rn):document.body.setAttribute(rn,e.toString())}},[])},xM=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,o=n===void 0?"margin":n;yM();var a=d.useMemo(function(){return gM(o)},[o]);return d.createElement(vM,{styles:bM(a,!t,o,r?"":"!important")})},Su=!1;if(typeof window<"u")try{var Uo=Object.defineProperty({},"passive",{get:function(){return Su=!0,!0}});window.addEventListener("test",Uo,Uo),window.removeEventListener("test",Uo,Uo)}catch{Su=!1}var Yr=Su?{passive:!1}:!1,wM=function(e){return e.tagName==="TEXTAREA"},my=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!wM(e)&&r[t]==="visible")},SM=function(e){return my(e,"overflowY")},CM=function(e){return my(e,"overflowX")},pm=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var o=hy(e,n);if(o){var a=gy(e,n),i=a[1],s=a[2];if(i>s)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},_M=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},RM=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},hy=function(e,t){return e==="v"?SM(t):CM(t)},gy=function(e,t){return e==="v"?_M(t):RM(t)},EM=function(e,t){return e==="h"&&t==="rtl"?-1:1},PM=function(e,t,r,n,o){var a=EM(e,window.getComputedStyle(t).direction),i=a*n,s=r.target,c=t.contains(s),l=!1,p=i>0,u=0,m=0;do{var b=gy(e,s),g=b[0],h=b[1],v=b[2],y=h-v-a*g;(g||y)&&hy(e,s)&&(u+=y,m+=g),s instanceof ShadowRoot?s=s.host:s=s.parentNode}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(p&&Math.abs(u)<1||!p&&Math.abs(m)<1)&&(l=!0),l},Wo=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},mm=function(e){return[e.deltaX,e.deltaY]},hm=function(e){return e&&"current"in e?e.current:e},TM=function(e,t){return e[0]===t[0]&&e[1]===t[1]},NM=function(e){return`
|
|
168
|
+
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
169
|
+
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
170
|
+
`)},AM=0,Xr=[];function MM(e){var t=d.useRef([]),r=d.useRef([0,0]),n=d.useRef(),o=d.useState(AM++)[0],a=d.useState(py)[0],i=d.useRef(e);d.useEffect(function(){i.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var h=JA([e.lockRef.current],(e.shards||[]).map(hm),!0).filter(Boolean);return h.forEach(function(v){return v.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),h.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var s=d.useCallback(function(h,v){if("touches"in h&&h.touches.length===2||h.type==="wheel"&&h.ctrlKey)return!i.current.allowPinchZoom;var y=Wo(h),x=r.current,w="deltaX"in h?h.deltaX:x[0]-y[0],S="deltaY"in h?h.deltaY:x[1]-y[1],_,R=h.target,C=Math.abs(w)>Math.abs(S)?"h":"v";if("touches"in h&&C==="h"&&R.type==="range")return!1;var A=pm(C,R);if(!A)return!0;if(A?_=C:(_=C==="v"?"h":"v",A=pm(C,R)),!A)return!1;if(!n.current&&"changedTouches"in h&&(w||S)&&(n.current=_),!_)return!0;var P=n.current||_;return PM(P,v,h,P==="h"?w:S)},[]),c=d.useCallback(function(h){var v=h;if(!(!Xr.length||Xr[Xr.length-1]!==a)){var y="deltaY"in v?mm(v):Wo(v),x=t.current.filter(function(_){return _.name===v.type&&(_.target===v.target||v.target===_.shadowParent)&&TM(_.delta,y)})[0];if(x&&x.should){v.cancelable&&v.preventDefault();return}if(!x){var w=(i.current.shards||[]).map(hm).filter(Boolean).filter(function(_){return _.contains(v.target)}),S=w.length>0?s(v,w[0]):!i.current.noIsolation;S&&v.cancelable&&v.preventDefault()}}},[]),l=d.useCallback(function(h,v,y,x){var w={name:h,delta:v,target:y,should:x,shadowParent:OM(y)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(S){return S!==w})},1)},[]),p=d.useCallback(function(h){r.current=Wo(h),n.current=void 0},[]),u=d.useCallback(function(h){l(h.type,mm(h),h.target,s(h,e.lockRef.current))},[]),m=d.useCallback(function(h){l(h.type,Wo(h),h.target,s(h,e.lockRef.current))},[]);d.useEffect(function(){return Xr.push(a),e.setCallbacks({onScrollCapture:u,onWheelCapture:u,onTouchMoveCapture:m}),document.addEventListener("wheel",c,Yr),document.addEventListener("touchmove",c,Yr),document.addEventListener("touchstart",p,Yr),function(){Xr=Xr.filter(function(h){return h!==a}),document.removeEventListener("wheel",c,Yr),document.removeEventListener("touchmove",c,Yr),document.removeEventListener("touchstart",p,Yr)}},[]);var b=e.removeScrollBar,g=e.inert;return d.createElement(d.Fragment,null,g?d.createElement(a,{styles:NM(o)}):null,b?d.createElement(xM,{gapMode:e.gapMode}):null)}function OM(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const IM=sM(fy,MM);var yo=d.forwardRef(function(e,t){return d.createElement(Qa,Ut({},e,{ref:t,sideCar:IM}))});yo.classNames=Qa.classNames;var jM=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Zr=new WeakMap,Ko=new WeakMap,Yo={},Ji=0,vy=function(e){return e&&(e.host||vy(e.parentNode))},DM=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=vy(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},kM=function(e,t,r,n){var o=DM(t,Array.isArray(e)?e:[e]);Yo[r]||(Yo[r]=new WeakMap);var a=Yo[r],i=[],s=new Set,c=new Set(o),l=function(u){!u||s.has(u)||(s.add(u),l(u.parentNode))};o.forEach(l);var p=function(u){!u||c.has(u)||Array.prototype.forEach.call(u.children,function(m){if(s.has(m))p(m);else try{var b=m.getAttribute(n),g=b!==null&&b!=="false",h=(Zr.get(m)||0)+1,v=(a.get(m)||0)+1;Zr.set(m,h),a.set(m,v),i.push(m),h===1&&g&&Ko.set(m,!0),v===1&&m.setAttribute(r,"true"),g||m.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",m,y)}})};return p(t),s.clear(),Ji++,function(){i.forEach(function(u){var m=Zr.get(u)-1,b=a.get(u)-1;Zr.set(u,m),a.set(u,b),m||(Ko.has(u)||u.removeAttribute(n),Ko.delete(u)),b||u.removeAttribute(r)}),Ji--,Ji||(Zr=new WeakMap,Zr=new WeakMap,Ko=new WeakMap,Yo={})}},ei=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),o=jM(e);return o?(n.push.apply(n,Array.from(o.querySelectorAll("[aria-live]"))),kM(n,o,r,"aria-hidden")):function(){return null}},Ad="Dialog",[by,yy]=De(Ad),[$M,Bt]=by(Ad),xy=e=>{const{__scopeDialog:t,children:r,open:n,defaultOpen:o,onOpenChange:a,modal:i=!0}=e,s=d.useRef(null),c=d.useRef(null),[l=!1,p]=$e({prop:n,defaultProp:o,onChange:a});return f.jsx($M,{scope:t,triggerRef:s,contentRef:c,contentId:Ue(),titleId:Ue(),descriptionId:Ue(),open:l,onOpenChange:p,onOpenToggle:d.useCallback(()=>p(u=>!u),[p]),modal:i,children:r})};xy.displayName=Ad;var wy="DialogTrigger",Sy=d.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Bt(wy,r),a=de(t,o.triggerRef);return f.jsx(X.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":Id(o.open),...n,ref:a,onClick:B(e.onClick,o.onOpenToggle)})});Sy.displayName=wy;var Md="DialogPortal",[LM,Cy]=by(Md,{forceMount:void 0}),_y=e=>{const{__scopeDialog:t,forceMount:r,children:n,container:o}=e,a=Bt(Md,t);return f.jsx(LM,{scope:t,forceMount:r,children:d.Children.map(n,i=>f.jsx(Le,{present:r||a.open,children:f.jsx(zr,{asChild:!0,container:o,children:i})}))})};_y.displayName=Md;var va="DialogOverlay",Ry=d.forwardRef((e,t)=>{const r=Cy(va,e.__scopeDialog),{forceMount:n=r.forceMount,...o}=e,a=Bt(va,e.__scopeDialog);return a.modal?f.jsx(Le,{present:n||a.open,children:f.jsx(FM,{...o,ref:t})}):null});Ry.displayName=va;var FM=d.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Bt(va,r);return f.jsx(yo,{as:st,allowPinchZoom:!0,shards:[o.contentRef],children:f.jsx(X.div,{"data-state":Id(o.open),...n,ref:t,style:{pointerEvents:"auto",...n.style}})})}),kr="DialogContent",Ey=d.forwardRef((e,t)=>{const r=Cy(kr,e.__scopeDialog),{forceMount:n=r.forceMount,...o}=e,a=Bt(kr,e.__scopeDialog);return f.jsx(Le,{present:n||a.open,children:a.modal?f.jsx(BM,{...o,ref:t}):f.jsx(zM,{...o,ref:t})})});Ey.displayName=kr;var BM=d.forwardRef((e,t)=>{const r=Bt(kr,e.__scopeDialog),n=d.useRef(null),o=de(t,r.contentRef,n);return d.useEffect(()=>{const a=n.current;if(a)return ei(a)},[]),f.jsx(Py,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:B(e.onCloseAutoFocus,a=>{var i;a.preventDefault(),(i=r.triggerRef.current)==null||i.focus()}),onPointerDownOutside:B(e.onPointerDownOutside,a=>{const i=a.detail.originalEvent,s=i.button===0&&i.ctrlKey===!0;(i.button===2||s)&&a.preventDefault()}),onFocusOutside:B(e.onFocusOutside,a=>a.preventDefault())})}),zM=d.forwardRef((e,t)=>{const r=Bt(kr,e.__scopeDialog),n=d.useRef(!1),o=d.useRef(!1);return f.jsx(Py,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var i,s;(i=e.onCloseAutoFocus)==null||i.call(e,a),a.defaultPrevented||(n.current||(s=r.triggerRef.current)==null||s.focus(),a.preventDefault()),n.current=!1,o.current=!1},onInteractOutside:a=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,a),a.defaultPrevented||(n.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=a.target;((l=r.triggerRef.current)==null?void 0:l.contains(i))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),Py=d.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:o,onCloseAutoFocus:a,...i}=e,s=Bt(kr,r),c=d.useRef(null),l=de(t,c);return Ja(),f.jsxs(f.Fragment,{children:[f.jsx(bo,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:o,onUnmountAutoFocus:a,children:f.jsx(ur,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":Id(s.open),...i,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),f.jsxs(f.Fragment,{children:[f.jsx(HM,{titleId:s.titleId}),f.jsx(GM,{contentRef:c,descriptionId:s.descriptionId})]})]})}),Od="DialogTitle",Ty=d.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Bt(Od,r);return f.jsx(X.h2,{id:o.titleId,...n,ref:t})});Ty.displayName=Od;var Ny="DialogDescription",Ay=d.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Bt(Ny,r);return f.jsx(X.p,{id:o.descriptionId,...n,ref:t})});Ay.displayName=Ny;var My="DialogClose",Oy=d.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,o=Bt(My,r);return f.jsx(X.button,{type:"button",...n,ref:t,onClick:B(e.onClick,()=>o.onOpenChange(!1))})});Oy.displayName=My;function Id(e){return e?"open":"closed"}var Iy="DialogTitleWarning",[qM,jy]=qN(Iy,{contentName:kr,titleName:Od,docsSlug:"dialog"}),HM=({titleId:e})=>{const t=jy(Iy),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
171
|
+
|
|
172
|
+
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
173
|
+
|
|
174
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return d.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},VM="DialogDescriptionWarning",GM=({contentRef:e,descriptionId:t})=>{const n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${jy(VM).contentName}}.`;return d.useEffect(()=>{var a;const o=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},ti=xy,ri=Sy,ni=_y,xn=Ry,wn=Ey,Sn=Ty,Cn=Ay,qr=Oy,Dy="AlertDialog",[UM,JV]=De(Dy,[yy]),dr=yy(),ky=e=>{const{__scopeAlertDialog:t,...r}=e,n=dr(t);return f.jsx(ti,{...n,...r,modal:!0})};ky.displayName=Dy;var WM="AlertDialogTrigger",$y=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=dr(r);return f.jsx(ri,{...o,...n,ref:t})});$y.displayName=WM;var KM="AlertDialogPortal",Ly=e=>{const{__scopeAlertDialog:t,...r}=e,n=dr(t);return f.jsx(ni,{...n,...r})};Ly.displayName=KM;var YM="AlertDialogOverlay",Fy=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=dr(r);return f.jsx(xn,{...o,...n,ref:t})});Fy.displayName=YM;var nn="AlertDialogContent",[XM,ZM]=UM(nn),By=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,children:n,...o}=e,a=dr(r),i=d.useRef(null),s=de(t,i),c=d.useRef(null);return f.jsx(qM,{contentName:nn,titleName:zy,docsSlug:"alert-dialog",children:f.jsx(XM,{scope:r,cancelRef:c,children:f.jsxs(wn,{role:"alertdialog",...a,...o,ref:s,onOpenAutoFocus:B(o.onOpenAutoFocus,l=>{var p;l.preventDefault(),(p=c.current)==null||p.focus({preventScroll:!0})}),onPointerDownOutside:l=>l.preventDefault(),onInteractOutside:l=>l.preventDefault(),children:[f.jsx(gd,{children:n}),f.jsx(QM,{contentRef:i})]})})})});By.displayName=nn;var zy="AlertDialogTitle",qy=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=dr(r);return f.jsx(Sn,{...o,...n,ref:t})});qy.displayName=zy;var Hy="AlertDialogDescription",Vy=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=dr(r);return f.jsx(Cn,{...o,...n,ref:t})});Vy.displayName=Hy;var JM="AlertDialogAction",Gy=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,o=dr(r);return f.jsx(qr,{...o,...n,ref:t})});Gy.displayName=JM;var Uy="AlertDialogCancel",Wy=d.forwardRef((e,t)=>{const{__scopeAlertDialog:r,...n}=e,{cancelRef:o}=ZM(Uy,r),a=dr(r),i=de(t,o);return f.jsx(qr,{...a,...n,ref:i})});Wy.displayName=Uy;var QM=({contentRef:e})=>{const t=`\`${nn}\` requires a description for the component to be accessible for screen reader users.
|
|
175
|
+
|
|
176
|
+
You can add a description to the \`${nn}\` by passing a \`${Hy}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
|
|
177
|
+
|
|
178
|
+
Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${nn}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component.
|
|
179
|
+
|
|
180
|
+
For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return d.useEffect(()=>{var n;document.getElementById((n=e.current)==null?void 0:n.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},eO=ky,tO=$y,rO=Ly,Ky=Fy,Yy=By,Xy=Gy,Zy=Wy,Jy=qy,Qy=Vy;const gm=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,vm=ar,fr=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return vm(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:o,defaultVariants:a}=t,i=Object.keys(o).map(l=>{const p=r==null?void 0:r[l],u=a==null?void 0:a[l];if(p===null)return null;const m=gm(p)||gm(u);return o[l][m]}),s=r&&Object.entries(r).reduce((l,p)=>{let[u,m]=p;return m===void 0||(l[u]=m),l},{}),c=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((l,p)=>{let{class:u,className:m,...b}=p;return Object.entries(b).every(g=>{let[h,v]=g;return Array.isArray(v)?v.includes({...a,...s}[h]):{...a,...s}[h]===v})?[...l,u,m]:l},[]);return vm(e,i,c,r==null?void 0:r.class,r==null?void 0:r.className)},xo=fr("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),or=d.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...o},a)=>{const i=n?st:"button";return f.jsx(i,{className:M(xo({variant:t,size:r,className:e})),ref:a,...o})});or.displayName="Button";const nO=eO,oO=tO,ex=rO,jd=d.forwardRef(({className:e,...t},r)=>f.jsx(Ky,{className:M("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:r}));jd.displayName=Ky.displayName;const tx=d.forwardRef(({className:e,...t},r)=>f.jsxs(ex,{children:[f.jsx(jd,{}),f.jsx(Yy,{ref:r,className:M("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...t})]}));tx.displayName=Yy.displayName;const rx=({className:e,...t})=>f.jsx("div",{className:M("flex flex-col space-y-2 text-center sm:text-left",e),...t});rx.displayName="AlertDialogHeader";const nx=({className:e,...t})=>f.jsx("div",{className:M("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});nx.displayName="AlertDialogFooter";const ox=d.forwardRef(({className:e,...t},r)=>f.jsx(Jy,{ref:r,className:M("text-lg font-semibold",e),...t}));ox.displayName=Jy.displayName;const ax=d.forwardRef(({className:e,...t},r)=>f.jsx(Qy,{ref:r,className:M("text-sm text-muted-foreground",e),...t}));ax.displayName=Qy.displayName;const ix=d.forwardRef(({className:e,...t},r)=>f.jsx(Xy,{ref:r,className:M(xo(),e),...t}));ix.displayName=Xy.displayName;const sx=d.forwardRef(({className:e,...t},r)=>f.jsx(Zy,{ref:r,className:M(xo({variant:"outline"}),"mt-2 sm:mt-0",e),...t}));sx.displayName=Zy.displayName;const aO=fr("relative w-full rounded-lg border px-4 py-3 text-sm [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground [&>svg~*]:pl-7",{variants:{variant:{default:"bg-background text-foreground",destructive:"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}}),cx=d.forwardRef(({className:e,variant:t,...r},n)=>f.jsx("div",{ref:n,role:"alert",className:M(aO({variant:t}),e),...r}));cx.displayName="Alert";const lx=d.forwardRef(({className:e,...t},r)=>f.jsx("h5",{ref:r,className:M("mb-1 font-medium leading-none tracking-tight",e),...t}));lx.displayName="AlertTitle";const ux=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("text-sm [&_p]:leading-relaxed",e),...t}));ux.displayName="AlertDescription";var iO="AspectRatio",dx=d.forwardRef((e,t)=>{const{ratio:r=1/1,style:n,...o}=e;return f.jsx("div",{style:{position:"relative",width:"100%",paddingBottom:`${100/r}%`},"data-radix-aspect-ratio-wrapper":"",children:f.jsx(X.div,{...o,ref:t,style:{...n,position:"absolute",top:0,right:0,bottom:0,left:0}})})});dx.displayName=iO;var sO=dx;const cO=sO;var Dd="Avatar",[lO,QV]=De(Dd),[uO,fx]=lO(Dd),px=d.forwardRef((e,t)=>{const{__scopeAvatar:r,...n}=e,[o,a]=d.useState("idle");return f.jsx(uO,{scope:r,imageLoadingStatus:o,onImageLoadingStatusChange:a,children:f.jsx(X.span,{...n,ref:t})})});px.displayName=Dd;var mx="AvatarImage",hx=d.forwardRef((e,t)=>{const{__scopeAvatar:r,src:n,onLoadingStatusChange:o=()=>{},...a}=e,i=fx(mx,r),s=dO(n,a.referrerPolicy),c=Te(l=>{o(l),i.onImageLoadingStatusChange(l)});return He(()=>{s!=="idle"&&c(s)},[s,c]),s==="loaded"?f.jsx(X.img,{...a,ref:t,src:n}):null});hx.displayName=mx;var gx="AvatarFallback",vx=d.forwardRef((e,t)=>{const{__scopeAvatar:r,delayMs:n,...o}=e,a=fx(gx,r),[i,s]=d.useState(n===void 0);return d.useEffect(()=>{if(n!==void 0){const c=window.setTimeout(()=>s(!0),n);return()=>window.clearTimeout(c)}},[n]),i&&a.imageLoadingStatus!=="loaded"?f.jsx(X.span,{...o,ref:t}):null});vx.displayName=gx;function dO(e,t){const[r,n]=d.useState("idle");return He(()=>{if(!e){n("error");return}let o=!0;const a=new window.Image,i=s=>()=>{o&&n(s)};return n("loading"),a.onload=i("loaded"),a.onerror=i("error"),a.src=e,t&&(a.referrerPolicy=t),()=>{o=!1}},[e,t]),r}var bx=px,yx=hx,xx=vx;const wx=d.forwardRef(({className:e,...t},r)=>f.jsx(bx,{ref:r,className:M("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));wx.displayName=bx.displayName;const Sx=d.forwardRef(({className:e,...t},r)=>f.jsx(yx,{ref:r,className:M("aspect-square h-full w-full",e),...t}));Sx.displayName=yx.displayName;const Cx=d.forwardRef(({className:e,...t},r)=>f.jsx(xx,{ref:r,className:M("flex h-full w-full items-center justify-center rounded-full bg-muted",e),...t}));Cx.displayName=xx.displayName;const _x=fr("inline-flex items-center rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground shadow hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function fO({className:e,variant:t,...r}){return f.jsx("div",{className:M(_x({variant:t}),e),...r})}const kd=d.forwardRef(({...e},t)=>f.jsx("nav",{ref:t,"aria-label":"breadcrumb",...e}));kd.displayName="Breadcrumb";const $d=d.forwardRef(({className:e,...t},r)=>f.jsx("ol",{ref:r,className:M("flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5",e),...t}));$d.displayName="BreadcrumbList";const ba=d.forwardRef(({className:e,...t},r)=>f.jsx("li",{ref:r,className:M("inline-flex items-center gap-1.5",e),...t}));ba.displayName="BreadcrumbItem";const ya=d.forwardRef(({asChild:e,className:t,...r},n)=>{const o=e?st:"a";return f.jsx(o,{ref:n,className:M("transition-colors hover:text-foreground",t),...r})});ya.displayName="BreadcrumbLink";const Ld=d.forwardRef(({className:e,...t},r)=>f.jsx("span",{ref:r,role:"link","aria-disabled":"true","aria-current":"page",className:M("font-normal text-foreground",e),...t}));Ld.displayName="BreadcrumbPage";const xa=({children:e,className:t,...r})=>f.jsx("li",{role:"presentation","aria-hidden":"true",className:M("[&>svg]:w-3.5 [&>svg]:h-3.5",t),...r,children:e??f.jsx(Dr,{})});xa.displayName="BreadcrumbSeparator";const Rx=({className:e,...t})=>f.jsxs("span",{role:"presentation","aria-hidden":"true",className:M("flex h-9 w-9 items-center justify-center",e),...t,children:[f.jsx(Ed,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"More"})]});Rx.displayName="BreadcrumbElipssis";const oi=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("rounded-xl border bg-card text-card-foreground shadow",e),...t}));oi.displayName="Card";const ai=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("flex flex-col space-y-1.5 p-6",e),...t}));ai.displayName="CardHeader";const ii=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("font-semibold leading-none tracking-tight",e),...t}));ii.displayName="CardTitle";const si=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("text-sm text-muted-foreground",e),...t}));si.displayName="CardDescription";const ci=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("p-6 pt-0",e),...t}));ci.displayName="CardContent";const Fd=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("flex items-center p-6 pt-0",e),...t}));Fd.displayName="CardFooter";function pO(e){return Object.prototype.toString.call(e)==="[object Object]"}function bm(e){return pO(e)||Array.isArray(e)}function mO(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}function Bd(e,t){const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;const o=JSON.stringify(Object.keys(e.breakpoints||{})),a=JSON.stringify(Object.keys(t.breakpoints||{}));return o!==a?!1:r.every(i=>{const s=e[i],c=t[i];return typeof s=="function"?`${s}`==`${c}`:!bm(s)||!bm(c)?s===c:Bd(s,c)})}function ym(e){return e.concat().sort((t,r)=>t.name>r.name?1:-1).map(t=>t.options)}function hO(e,t){if(e.length!==t.length)return!1;const r=ym(e),n=ym(t);return r.every((o,a)=>{const i=n[a];return Bd(o,i)})}function zd(e){return typeof e=="number"}function Cu(e){return typeof e=="string"}function li(e){return typeof e=="boolean"}function xm(e){return Object.prototype.toString.call(e)==="[object Object]"}function qe(e){return Math.abs(e)}function qd(e){return Math.sign(e)}function Kn(e,t){return qe(e-t)}function gO(e,t){if(e===0||t===0||qe(e)<=qe(t))return 0;const r=Kn(qe(e),qe(t));return qe(r/e)}function vO(e){return Math.round(e*100)/100}function Zn(e){return Jn(e).map(Number)}function Dt(e){return e[wo(e)]}function wo(e){return Math.max(0,e.length-1)}function Hd(e,t){return t===wo(e)}function wm(e,t=0){return Array.from(Array(e),(r,n)=>t+n)}function Jn(e){return Object.keys(e)}function Ex(e,t){return[e,t].reduce((r,n)=>(Jn(n).forEach(o=>{const a=r[o],i=n[o],s=xm(a)&&xm(i);r[o]=s?Ex(a,i):i}),r),{})}function _u(e,t){return typeof t.MouseEvent<"u"&&e instanceof t.MouseEvent}function bO(e,t){const r={start:n,center:o,end:a};function n(){return 0}function o(c){return a(c)/2}function a(c){return t-c}function i(c,l){return Cu(e)?r[e](c):e(t,c,l)}return{measure:i}}function Qn(){let e=[];function t(o,a,i,s={passive:!0}){let c;if("addEventListener"in o)o.addEventListener(a,i,s),c=()=>o.removeEventListener(a,i,s);else{const l=o;l.addListener(i),c=()=>l.removeListener(i)}return e.push(c),n}function r(){e=e.filter(o=>o())}const n={add:t,clear:r};return n}function yO(e,t,r,n){const o=Qn(),a=1e3/60;let i=null,s=0,c=0;function l(){o.add(e,"visibilitychange",()=>{e.hidden&&g()})}function p(){b(),o.clear()}function u(v){if(!c)return;i||(i=v,r(),r());const y=v-i;for(i=v,s+=y;s>=a;)r(),s-=a;const x=s/a;n(x),c&&(c=t.requestAnimationFrame(u))}function m(){c||(c=t.requestAnimationFrame(u))}function b(){t.cancelAnimationFrame(c),i=null,s=0,c=0}function g(){i=null,s=0}return{init:l,destroy:p,start:m,stop:b,update:r,render:n}}function xO(e,t){const r=t==="rtl",n=e==="y",o=n?"y":"x",a=n?"x":"y",i=!n&&r?-1:1,s=p(),c=u();function l(g){const{height:h,width:v}=g;return n?h:v}function p(){return n?"top":r?"right":"left"}function u(){return n?"bottom":r?"left":"right"}function m(g){return g*i}return{scroll:o,cross:a,startEdge:s,endEdge:c,measureSize:l,direction:m}}function $r(e=0,t=0){const r=qe(e-t);function n(l){return l<e}function o(l){return l>t}function a(l){return n(l)||o(l)}function i(l){return a(l)?n(l)?e:t:l}function s(l){return r?l-r*Math.ceil((l-t)/r):l}return{length:r,max:t,min:e,constrain:i,reachedAny:a,reachedMax:o,reachedMin:n,removeOffset:s}}function Px(e,t,r){const{constrain:n}=$r(0,e),o=e+1;let a=i(t);function i(m){return r?qe((o+m)%o):n(m)}function s(){return a}function c(m){return a=i(m),u}function l(m){return p().set(s()+m)}function p(){return Px(e,s(),r)}const u={get:s,set:c,add:l,clone:p};return u}function wO(e,t,r,n,o,a,i,s,c,l,p,u,m,b,g,h,v,y,x){const{cross:w,direction:S}=e,_=["INPUT","SELECT","TEXTAREA"],R={passive:!1},C=Qn(),A=Qn(),P=$r(50,225).constrain(b.measure(20)),k={mouse:300,touch:400},j={mouse:500,touch:600},L=g?43:25;let N=!1,D=0,$=0,O=!1,G=!1,H=!1,z=!1;function oe(V){if(!x)return;function ae(ee){(li(x)||x(V,ee))&&K(ee)}const I=t;C.add(I,"dragstart",ee=>ee.preventDefault(),R).add(I,"touchmove",()=>{},R).add(I,"touchend",()=>{}).add(I,"touchstart",ae).add(I,"mousedown",ae).add(I,"touchcancel",W).add(I,"contextmenu",W).add(I,"click",re,!0)}function Z(){C.clear(),A.clear()}function te(){const V=z?r:t;A.add(V,"touchmove",q,R).add(V,"touchend",W).add(V,"mousemove",q,R).add(V,"mouseup",W)}function F(V){const ae=V.nodeName||"";return _.includes(ae)}function U(){return(g?j:k)[z?"mouse":"touch"]}function Q(V,ae){const I=u.add(qd(V)*-1),ee=p.byDistance(V,!g).distance;return g||qe(V)<P?ee:v&&ae?ee*.5:p.byIndex(I.get(),0).distance}function K(V){const ae=_u(V,n);z=ae,H=g&&ae&&!V.buttons&&N,N=Kn(o.get(),i.get())>=2,!(ae&&V.button!==0)&&(F(V.target)||(O=!0,a.pointerDown(V),l.useFriction(0).useDuration(0),o.set(i),te(),D=a.readPoint(V),$=a.readPoint(V,w),m.emit("pointerDown")))}function q(V){if(!_u(V,n)&&V.touches.length>=2)return W(V);const I=a.readPoint(V),ee=a.readPoint(V,w),pe=Kn(I,D),me=Kn(ee,$);if(!G&&!z&&(!V.cancelable||(G=pe>me,!G)))return W(V);const ge=a.pointerMove(V);pe>h&&(H=!0),l.useFriction(.3).useDuration(.75),s.start(),o.add(S(ge)),V.preventDefault()}function W(V){const I=p.byDistance(0,!1).index!==u.get(),ee=a.pointerUp(V)*U(),pe=Q(S(ee),I),me=gO(ee,pe),ge=L-10*me,fe=y+me/50;G=!1,O=!1,A.clear(),l.useDuration(ge).useFriction(fe),c.distance(pe,!g),z=!1,m.emit("pointerUp")}function re(V){H&&(V.stopPropagation(),V.preventDefault(),H=!1)}function J(){return O}return{init:oe,destroy:Z,pointerDown:J}}function SO(e,t){let n,o;function a(u){return u.timeStamp}function i(u,m){const g=`client${(m||e.scroll)==="x"?"X":"Y"}`;return(_u(u,t)?u:u.touches[0])[g]}function s(u){return n=u,o=u,i(u)}function c(u){const m=i(u)-i(o),b=a(u)-a(n)>170;return o=u,b&&(n=u),m}function l(u){if(!n||!o)return 0;const m=i(o)-i(n),b=a(u)-a(n),g=a(u)-a(o)>170,h=m/b;return b&&!g&&qe(h)>.1?h:0}return{pointerDown:s,pointerMove:c,pointerUp:l,readPoint:i}}function CO(){function e(r){const{offsetTop:n,offsetLeft:o,offsetWidth:a,offsetHeight:i}=r;return{top:n,right:o+a,bottom:n+i,left:o,width:a,height:i}}return{measure:e}}function _O(e){function t(n){return e*(n/100)}return{measure:t}}function RO(e,t,r,n,o,a,i){const s=[e].concat(n);let c,l,p=[],u=!1;function m(v){return o.measureSize(i.measure(v))}function b(v){if(!a)return;l=m(e),p=n.map(m);function y(x){for(const w of x){if(u)return;const S=w.target===e,_=n.indexOf(w.target),R=S?l:p[_],C=m(S?e:n[_]);if(qe(C-R)>=.5){v.reInit(),t.emit("resize");break}}}c=new ResizeObserver(x=>{(li(a)||a(v,x))&&y(x)}),r.requestAnimationFrame(()=>{s.forEach(x=>c.observe(x))})}function g(){u=!0,c&&c.disconnect()}return{init:b,destroy:g}}function EO(e,t,r,n,o,a){let i=0,s=0,c=o,l=a,p=e.get(),u=0;function m(){const R=n.get()-e.get(),C=!c;let A=0;return C?(i=0,r.set(n),e.set(n),A=R):(r.set(e),i+=R/c,i*=l,p+=i,e.add(i),A=p-u),s=qd(A),u=p,_}function b(){const R=n.get()-t.get();return qe(R)<.001}function g(){return c}function h(){return s}function v(){return i}function y(){return w(o)}function x(){return S(a)}function w(R){return c=R,_}function S(R){return l=R,_}const _={direction:h,duration:g,velocity:v,seek:m,settled:b,useBaseFriction:x,useBaseDuration:y,useFriction:S,useDuration:w};return _}function PO(e,t,r,n,o){const a=o.measure(10),i=o.measure(50),s=$r(.1,.99);let c=!1;function l(){return!(c||!e.reachedAny(r.get())||!e.reachedAny(t.get()))}function p(b){if(!l())return;const g=e.reachedMin(t.get())?"min":"max",h=qe(e[g]-t.get()),v=r.get()-t.get(),y=s.constrain(h/i);r.subtract(v*y),!b&&qe(v)<a&&(r.set(e.constrain(r.get())),n.useDuration(25).useBaseFriction())}function u(b){c=!b}return{shouldConstrain:l,constrain:p,toggleActive:u}}function TO(e,t,r,n,o){const a=$r(-t+e,0),i=u(),s=p(),c=m();function l(g,h){return Kn(g,h)<=1}function p(){const g=i[0],h=Dt(i),v=i.lastIndexOf(g),y=i.indexOf(h)+1;return $r(v,y)}function u(){return r.map((g,h)=>{const{min:v,max:y}=a,x=a.constrain(g),w=!h,S=Hd(r,h);return w?y:S||l(v,x)?v:l(y,x)?y:x}).map(g=>parseFloat(g.toFixed(3)))}function m(){if(t<=e+o)return[a.max];if(n==="keepSnaps")return i;const{min:g,max:h}=s;return i.slice(g,h)}return{snapsContained:c,scrollContainLimit:s}}function NO(e,t,r){const n=t[0],o=r?n-e:Dt(t);return{limit:$r(o,n)}}function AO(e,t,r,n){const a=t.min+.1,i=t.max+.1,{reachedMin:s,reachedMax:c}=$r(a,i);function l(m){return m===1?c(r.get()):m===-1?s(r.get()):!1}function p(m){if(!l(m))return;const b=e*(m*-1);n.forEach(g=>g.add(b))}return{loop:p}}function MO(e){const{max:t,length:r}=e;function n(a){const i=a-t;return r?i/-r:0}return{get:n}}function OO(e,t,r,n,o){const{startEdge:a,endEdge:i}=e,{groupSlides:s}=o,c=u().map(t.measure),l=m(),p=b();function u(){return s(n).map(h=>Dt(h)[i]-h[0][a]).map(qe)}function m(){return n.map(h=>r[a]-h[a]).map(h=>-qe(h))}function b(){return s(l).map(h=>h[0]).map((h,v)=>h+c[v])}return{snaps:l,snapsAligned:p}}function IO(e,t,r,n,o,a){const{groupSlides:i}=o,{min:s,max:c}=n,l=p();function p(){const m=i(a),b=!e||t==="keepSnaps";return r.length===1?[a]:b?m:m.slice(s,c).map((g,h,v)=>{const y=!h,x=Hd(v,h);if(y){const w=Dt(v[0])+1;return wm(w)}if(x){const w=wo(a)-Dt(v)[0]+1;return wm(w,Dt(v)[0])}return g})}return{slideRegistry:l}}function jO(e,t,r,n,o){const{reachedAny:a,removeOffset:i,constrain:s}=n;function c(g){return g.concat().sort((h,v)=>qe(h)-qe(v))[0]}function l(g){const h=e?i(g):s(g),v=t.map((x,w)=>({diff:p(x-h,0),index:w})).sort((x,w)=>qe(x.diff)-qe(w.diff)),{index:y}=v[0];return{index:y,distance:h}}function p(g,h){const v=[g,g+r,g-r];if(!e)return g;if(!h)return c(v);const y=v.filter(x=>qd(x)===h);return y.length?c(y):Dt(v)-r}function u(g,h){const v=t[g]-o.get(),y=p(v,h);return{index:g,distance:y}}function m(g,h){const v=o.get()+g,{index:y,distance:x}=l(v),w=!e&&a(v);if(!h||w)return{index:y,distance:g};const S=t[y]-x,_=g+p(S,0);return{index:y,distance:_}}return{byDistance:m,byIndex:u,shortcut:p}}function DO(e,t,r,n,o,a,i){function s(u){const m=u.distance,b=u.index!==t.get();a.add(m),m&&(n.duration()?e.start():(e.update(),e.render(1),e.update())),b&&(r.set(t.get()),t.set(u.index),i.emit("select"))}function c(u,m){const b=o.byDistance(u,m);s(b)}function l(u,m){const b=t.clone().set(u),g=o.byIndex(b.get(),m);s(g)}return{distance:c,index:l}}function kO(e,t,r,n,o,a,i,s){const c={passive:!0,capture:!0};let l=0;function p(b){if(!s)return;function g(h){if(new Date().getTime()-l>10)return;i.emit("slideFocusStart"),e.scrollLeft=0;const x=r.findIndex(w=>w.includes(h));zd(x)&&(o.useDuration(0),n.index(x,0),i.emit("slideFocus"))}a.add(document,"keydown",u,!1),t.forEach((h,v)=>{a.add(h,"focus",y=>{(li(s)||s(b,y))&&g(v)},c)})}function u(b){b.code==="Tab"&&(l=new Date().getTime())}return{init:p}}function zn(e){let t=e;function r(){return t}function n(c){t=i(c)}function o(c){t+=i(c)}function a(c){t-=i(c)}function i(c){return zd(c)?c:c.get()}return{get:r,set:n,add:o,subtract:a}}function Tx(e,t){const r=e.scroll==="x"?i:s,n=t.style;let o=null,a=!1;function i(m){return`translate3d(${m}px,0px,0px)`}function s(m){return`translate3d(0px,${m}px,0px)`}function c(m){if(a)return;const b=vO(e.direction(m));b!==o&&(n.transform=r(b),o=b)}function l(m){a=!m}function p(){a||(n.transform="",t.getAttribute("style")||t.removeAttribute("style"))}return{clear:p,to:c,toggleActive:l}}function $O(e,t,r,n,o,a,i,s,c){const p=Zn(o),u=Zn(o).reverse(),m=y().concat(x());function b(C,A){return C.reduce((P,k)=>P-o[k],A)}function g(C,A){return C.reduce((P,k)=>b(P,A)>0?P.concat([k]):P,[])}function h(C){return a.map((A,P)=>({start:A-n[P]+.5+C,end:A+t-.5+C}))}function v(C,A,P){const k=h(A);return C.map(j=>{const L=P?0:-r,N=P?r:0,D=P?"end":"start",$=k[j][D];return{index:j,loopPoint:$,slideLocation:zn(-1),translate:Tx(e,c[j]),target:()=>s.get()>$?L:N}})}function y(){const C=i[0],A=g(u,C);return v(A,r,!1)}function x(){const C=t-i[0]-1,A=g(p,C);return v(A,-r,!0)}function w(){return m.every(({index:C})=>{const A=p.filter(P=>P!==C);return b(A,t)<=.1})}function S(){m.forEach(C=>{const{target:A,translate:P,slideLocation:k}=C,j=A();j!==k.get()&&(P.to(j),k.set(j))})}function _(){m.forEach(C=>C.translate.clear())}return{canLoop:w,clear:_,loop:S,loopPoints:m}}function LO(e,t,r){let n,o=!1;function a(c){if(!r)return;function l(p){for(const u of p)if(u.type==="childList"){c.reInit(),t.emit("slidesChanged");break}}n=new MutationObserver(p=>{o||(li(r)||r(c,p))&&l(p)}),n.observe(e,{childList:!0})}function i(){n&&n.disconnect(),o=!0}return{init:a,destroy:i}}function FO(e,t,r,n){const o={};let a=null,i=null,s,c=!1;function l(){s=new IntersectionObserver(g=>{c||(g.forEach(h=>{const v=t.indexOf(h.target);o[v]=h}),a=null,i=null,r.emit("slidesInView"))},{root:e.parentElement,threshold:n}),t.forEach(g=>s.observe(g))}function p(){s&&s.disconnect(),c=!0}function u(g){return Jn(o).reduce((h,v)=>{const y=parseInt(v),{isIntersecting:x}=o[y];return(g&&x||!g&&!x)&&h.push(y),h},[])}function m(g=!0){if(g&&a)return a;if(!g&&i)return i;const h=u(g);return g&&(a=h),g||(i=h),h}return{init:l,destroy:p,get:m}}function BO(e,t,r,n,o,a){const{measureSize:i,startEdge:s,endEdge:c}=e,l=r[0]&&o,p=g(),u=h(),m=r.map(i),b=v();function g(){if(!l)return 0;const x=r[0];return qe(t[s]-x[s])}function h(){if(!l)return 0;const x=a.getComputedStyle(Dt(n));return parseFloat(x.getPropertyValue(`margin-${c}`))}function v(){return r.map((x,w,S)=>{const _=!w,R=Hd(S,w);return _?m[w]+p:R?m[w]+u:S[w+1][s]-x[s]}).map(qe)}return{slideSizes:m,slideSizesWithGaps:b,startGap:p,endGap:u}}function zO(e,t,r,n,o,a,i,s,c){const{startEdge:l,endEdge:p,direction:u}=e,m=zd(r);function b(y,x){return Zn(y).filter(w=>w%x===0).map(w=>y.slice(w,w+x))}function g(y){return y.length?Zn(y).reduce((x,w,S)=>{const _=Dt(x)||0,R=_===0,C=w===wo(y),A=o[l]-a[_][l],P=o[l]-a[w][p],k=!n&&R?u(i):0,j=!n&&C?u(s):0,L=qe(P-j-(A+k));return S&&L>t+c&&x.push(w),C&&x.push(y.length),x},[]).map((x,w,S)=>{const _=Math.max(S[w-1]||0);return y.slice(_,x)}):[]}function h(y){return m?b(y,r):g(y)}return{groupSlides:h}}function qO(e,t,r,n,o,a,i){const{align:s,axis:c,direction:l,startIndex:p,loop:u,duration:m,dragFree:b,dragThreshold:g,inViewThreshold:h,slidesToScroll:v,skipSnaps:y,containScroll:x,watchResize:w,watchSlides:S,watchDrag:_,watchFocus:R}=a,C=2,A=CO(),P=A.measure(t),k=r.map(A.measure),j=xO(c,l),L=j.measureSize(P),N=_O(L),D=bO(s,L),$=!u&&!!x,O=u||!!x,{slideSizes:G,slideSizesWithGaps:H,startGap:z,endGap:oe}=BO(j,P,k,r,O,o),Z=zO(j,L,v,u,P,k,z,oe,C),{snaps:te,snapsAligned:F}=OO(j,D,P,k,Z),U=-Dt(te)+Dt(H),{snapsContained:Q,scrollContainLimit:K}=TO(L,U,F,x,C),q=$?Q:F,{limit:W}=NO(U,q,u),re=Px(wo(q),p,u),J=re.clone(),ne=Zn(r),V=({dragHandler:Ve,scrollBody:Ct,scrollBounds:Ke,options:{loop:Je}})=>{Je||Ke.constrain(Ve.pointerDown()),Ct.seek()},ae=({scrollBody:Ve,translate:Ct,location:Ke,offsetLocation:Je,previousLocation:At,scrollLooper:Vt,slideLooper:pr,dragHandler:Er,animation:Mt,eventHandler:ue,scrollBounds:be,options:{loop:Ce}},ve)=>{const ie=Ve.settled(),Se=!be.shouldConstrain(),xe=Ce?ie:ie&&Se;xe&&!Er.pointerDown()&&(Mt.stop(),ue.emit("settle")),xe||ue.emit("scroll");const ke=Ke.get()*ve+At.get()*(1-ve);Je.set(ke),Ce&&(Vt.loop(Ve.direction()),pr.loop()),Ct.to(Je.get())},I=yO(n,o,()=>V(ft),Ve=>ae(ft,Ve)),ee=.68,pe=q[re.get()],me=zn(pe),ge=zn(pe),fe=zn(pe),Ee=zn(pe),Fe=EO(me,fe,ge,Ee,m,ee),we=jO(u,q,U,W,Ee),Oe=DO(I,re,J,Fe,we,Ee,i),rt=MO(W),Ze=Qn(),We=FO(t,r,i,h),{slideRegistry:ot}=IO($,x,q,K,Z,ne),mt=kO(e,r,ot,Oe,Fe,Ze,i,R),ft={ownerDocument:n,ownerWindow:o,eventHandler:i,containerRect:P,slideRects:k,animation:I,axis:j,dragHandler:wO(j,e,n,o,Ee,SO(j,o),me,I,Oe,Fe,we,re,i,N,b,g,y,ee,_),eventStore:Ze,percentOfView:N,index:re,indexPrevious:J,limit:W,location:me,offsetLocation:fe,previousLocation:ge,options:a,resizeHandler:RO(t,i,o,r,j,w,A),scrollBody:Fe,scrollBounds:PO(W,fe,Ee,Fe,N),scrollLooper:AO(U,W,fe,[me,fe,ge,Ee]),scrollProgress:rt,scrollSnapList:q.map(rt.get),scrollSnaps:q,scrollTarget:we,scrollTo:Oe,slideLooper:$O(j,L,U,G,H,te,q,fe,r),slideFocus:mt,slidesHandler:LO(t,i,S),slidesInView:We,slideIndexes:ne,slideRegistry:ot,slidesToScroll:Z,target:Ee,translate:Tx(j,t)};return ft}function HO(){let e={},t;function r(l){t=l}function n(l){return e[l]||[]}function o(l){return n(l).forEach(p=>p(t,l)),c}function a(l,p){return e[l]=n(l).concat([p]),c}function i(l,p){return e[l]=n(l).filter(u=>u!==p),c}function s(){e={}}const c={init:r,emit:o,off:i,on:a,clear:s};return c}const VO={align:"center",axis:"x",container:null,slides:null,containScroll:"trimSnaps",direction:"ltr",slidesToScroll:1,inViewThreshold:0,breakpoints:{},dragFree:!1,dragThreshold:10,loop:!1,skipSnaps:!1,duration:25,startIndex:0,active:!0,watchDrag:!0,watchResize:!0,watchSlides:!0,watchFocus:!0};function GO(e){function t(a,i){return Ex(a,i||{})}function r(a){const i=a.breakpoints||{},s=Jn(i).filter(c=>e.matchMedia(c).matches).map(c=>i[c]).reduce((c,l)=>t(c,l),{});return t(a,s)}function n(a){return a.map(i=>Jn(i.breakpoints||{})).reduce((i,s)=>i.concat(s),[]).map(e.matchMedia)}return{mergeOptions:t,optionsAtMedia:r,optionsMediaQueries:n}}function UO(e){let t=[];function r(a,i){return t=i.filter(({options:s})=>e.optionsAtMedia(s).active!==!1),t.forEach(s=>s.init(a,e)),i.reduce((s,c)=>Object.assign(s,{[c.name]:c}),{})}function n(){t=t.filter(a=>a.destroy())}return{init:r,destroy:n}}function wa(e,t,r){const n=e.ownerDocument,o=n.defaultView,a=GO(o),i=UO(a),s=Qn(),c=HO(),{mergeOptions:l,optionsAtMedia:p,optionsMediaQueries:u}=a,{on:m,off:b,emit:g}=c,h=j;let v=!1,y,x=l(VO,wa.globalOptions),w=l(x),S=[],_,R,C;function A(){const{container:ne,slides:V}=w;R=(Cu(ne)?e.querySelector(ne):ne)||e.children[0];const I=Cu(V)?R.querySelectorAll(V):V;C=[].slice.call(I||R.children)}function P(ne){const V=qO(e,R,C,n,o,ne,c);if(ne.loop&&!V.slideLooper.canLoop()){const ae=Object.assign({},ne,{loop:!1});return P(ae)}return V}function k(ne,V){v||(x=l(x,ne),w=p(x),S=V||S,A(),y=P(w),u([x,...S.map(({options:ae})=>ae)]).forEach(ae=>s.add(ae,"change",j)),w.active&&(y.translate.to(y.location.get()),y.animation.init(),y.slidesInView.init(),y.slideFocus.init(J),y.eventHandler.init(J),y.resizeHandler.init(J),y.slidesHandler.init(J),y.options.loop&&y.slideLooper.loop(),R.offsetParent&&C.length&&y.dragHandler.init(J),_=i.init(J,S)))}function j(ne,V){const ae=Z();L(),k(l({startIndex:ae},ne),V),c.emit("reInit")}function L(){y.dragHandler.destroy(),y.eventStore.clear(),y.translate.clear(),y.slideLooper.clear(),y.resizeHandler.destroy(),y.slidesHandler.destroy(),y.slidesInView.destroy(),y.animation.destroy(),i.destroy(),s.clear()}function N(){v||(v=!0,s.clear(),L(),c.emit("destroy"),c.clear())}function D(ne,V,ae){!w.active||v||(y.scrollBody.useBaseFriction().useDuration(V===!0?0:w.duration),y.scrollTo.index(ne,ae||0))}function $(ne){const V=y.index.add(1).get();D(V,ne,-1)}function O(ne){const V=y.index.add(-1).get();D(V,ne,1)}function G(){return y.index.add(1).get()!==Z()}function H(){return y.index.add(-1).get()!==Z()}function z(){return y.scrollSnapList}function oe(){return y.scrollProgress.get(y.location.get())}function Z(){return y.index.get()}function te(){return y.indexPrevious.get()}function F(){return y.slidesInView.get()}function U(){return y.slidesInView.get(!1)}function Q(){return _}function K(){return y}function q(){return e}function W(){return R}function re(){return C}const J={canScrollNext:G,canScrollPrev:H,containerNode:W,internalEngine:K,destroy:N,off:b,on:m,emit:g,plugins:Q,previousScrollSnap:te,reInit:h,rootNode:q,scrollNext:$,scrollPrev:O,scrollProgress:oe,scrollSnapList:z,scrollTo:D,selectedScrollSnap:Z,slideNodes:re,slidesInView:F,slidesNotInView:U};return k(t,r),setTimeout(()=>c.emit("init"),0),J}wa.globalOptions=void 0;function Vd(e={},t=[]){const r=E.useRef(e),n=E.useRef(t),[o,a]=E.useState(),[i,s]=E.useState(),c=E.useCallback(()=>{o&&o.reInit(r.current,n.current)},[o]);return E.useEffect(()=>{Bd(r.current,e)||(r.current=e,c())},[e,c]),E.useEffect(()=>{hO(n.current,t)||(n.current=t,c())},[t,c]),E.useEffect(()=>{if(mO()&&i){wa.globalOptions=Vd.globalOptions;const l=wa(i,r.current,n.current);return a(l),()=>l.destroy()}else a(void 0)},[i,a]),[s,o]}Vd.globalOptions=void 0;const Nx=d.createContext(null);function ui(){const e=d.useContext(Nx);if(!e)throw new Error("useCarousel must be used within a <Carousel />");return e}const Ax=d.forwardRef(({orientation:e="horizontal",opts:t,setApi:r,plugins:n,className:o,children:a,...i},s)=>{const[c,l]=Vd({...t,axis:e==="horizontal"?"x":"y"},n),[p,u]=d.useState(!1),[m,b]=d.useState(!1),g=d.useCallback(x=>{x&&(u(x.canScrollPrev()),b(x.canScrollNext()))},[]),h=d.useCallback(()=>{l==null||l.scrollPrev()},[l]),v=d.useCallback(()=>{l==null||l.scrollNext()},[l]),y=d.useCallback(x=>{x.key==="ArrowLeft"?(x.preventDefault(),h()):x.key==="ArrowRight"&&(x.preventDefault(),v())},[h,v]);return d.useEffect(()=>{!l||!r||r(l)},[l,r]),d.useEffect(()=>{if(l)return g(l),l.on("reInit",g),l.on("select",g),()=>{l==null||l.off("select",g)}},[l,g]),f.jsx(Nx.Provider,{value:{carouselRef:c,api:l,opts:t,orientation:e||((t==null?void 0:t.axis)==="y"?"vertical":"horizontal"),scrollPrev:h,scrollNext:v,canScrollPrev:p,canScrollNext:m},children:f.jsx("div",{ref:s,onKeyDownCapture:y,className:M("relative",o),role:"region","aria-roledescription":"carousel",...i,children:a})})});Ax.displayName="Carousel";const Mx=d.forwardRef(({className:e,...t},r)=>{const{carouselRef:n,orientation:o}=ui();return f.jsx("div",{ref:n,className:"overflow-hidden",children:f.jsx("div",{ref:r,className:M("flex",o==="horizontal"?"-ml-4":"-mt-4 flex-col",e),...t})})});Mx.displayName="CarouselContent";const Ox=d.forwardRef(({className:e,...t},r)=>{const{orientation:n}=ui();return f.jsx("div",{ref:r,role:"group","aria-roledescription":"slide",className:M("min-w-0 shrink-0 grow-0 basis-full",n==="horizontal"?"pl-4":"pt-4",e),...t})});Ox.displayName="CarouselItem";const Ix=d.forwardRef(({className:e,variant:t="outline",size:r="icon",...n},o)=>{const{orientation:a,scrollPrev:i,canScrollPrev:s}=ui();return f.jsxs(or,{ref:o,variant:t,size:r,className:M("absolute h-8 w-8 rounded-full",a==="horizontal"?"-left-12 top-1/2 -translate-y-1/2":"-top-12 left-1/2 -translate-x-1/2 rotate-90",e),disabled:!s,onClick:i,...n,children:[f.jsx(_1,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Previous slide"})]})});Ix.displayName="CarouselPrevious";const jx=d.forwardRef(({className:e,variant:t="outline",size:r="icon",...n},o)=>{const{orientation:a,scrollNext:i,canScrollNext:s}=ui();return f.jsxs(or,{ref:o,variant:t,size:r,className:M("absolute h-8 w-8 rounded-full",a==="horizontal"?"-right-12 top-1/2 -translate-y-1/2":"-bottom-12 left-1/2 -translate-x-1/2 rotate-90",e),disabled:!s,onClick:i,...n,children:[f.jsx(E1,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Next slide"})]})});jx.displayName="CarouselNext";var Qi,Sm;function zt(){if(Sm)return Qi;Sm=1;var e=Array.isArray;return Qi=e,Qi}var es,Cm;function Dx(){if(Cm)return es;Cm=1;var e=typeof qo=="object"&&qo&&qo.Object===Object&&qo;return es=e,es}var ts,_m;function Xt(){if(_m)return ts;_m=1;var e=Dx(),t=typeof self=="object"&&self&&self.Object===Object&&self,r=e||t||Function("return this")();return ts=r,ts}var rs,Rm;function So(){if(Rm)return rs;Rm=1;var e=Xt(),t=e.Symbol;return rs=t,rs}var ns,Em;function WO(){if(Em)return ns;Em=1;var e=So(),t=Object.prototype,r=t.hasOwnProperty,n=t.toString,o=e?e.toStringTag:void 0;function a(i){var s=r.call(i,o),c=i[o];try{i[o]=void 0;var l=!0}catch{}var p=n.call(i);return l&&(s?i[o]=c:delete i[o]),p}return ns=a,ns}var os,Pm;function KO(){if(Pm)return os;Pm=1;var e=Object.prototype,t=e.toString;function r(n){return t.call(n)}return os=r,os}var as,Tm;function Hr(){if(Tm)return as;Tm=1;var e=So(),t=WO(),r=KO(),n="[object Null]",o="[object Undefined]",a=e?e.toStringTag:void 0;function i(s){return s==null?s===void 0?o:n:a&&a in Object(s)?t(s):r(s)}return as=i,as}var is,Nm;function Vr(){if(Nm)return is;Nm=1;function e(t){return t!=null&&typeof t=="object"}return is=e,is}var ss,Am;function Co(){if(Am)return ss;Am=1;var e=Hr(),t=Vr(),r="[object Symbol]";function n(o){return typeof o=="symbol"||t(o)&&e(o)==r}return ss=n,ss}var cs,Mm;function Gd(){if(Mm)return cs;Mm=1;var e=zt(),t=Co(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,n=/^\w*$/;function o(a,i){if(e(a))return!1;var s=typeof a;return s=="number"||s=="symbol"||s=="boolean"||a==null||t(a)?!0:n.test(a)||!r.test(a)||i!=null&&a in Object(i)}return cs=o,cs}var ls,Om;function wr(){if(Om)return ls;Om=1;function e(t){var r=typeof t;return t!=null&&(r=="object"||r=="function")}return ls=e,ls}var us,Im;function Ud(){if(Im)return us;Im=1;var e=Hr(),t=wr(),r="[object AsyncFunction]",n="[object Function]",o="[object GeneratorFunction]",a="[object Proxy]";function i(s){if(!t(s))return!1;var c=e(s);return c==n||c==o||c==r||c==a}return us=i,us}var ds,jm;function YO(){if(jm)return ds;jm=1;var e=Xt(),t=e["__core-js_shared__"];return ds=t,ds}var fs,Dm;function XO(){if(Dm)return fs;Dm=1;var e=YO(),t=function(){var n=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""}();function r(n){return!!t&&t in n}return fs=r,fs}var ps,km;function kx(){if(km)return ps;km=1;var e=Function.prototype,t=e.toString;function r(n){if(n!=null){try{return t.call(n)}catch{}try{return n+""}catch{}}return""}return ps=r,ps}var ms,$m;function ZO(){if($m)return ms;$m=1;var e=Ud(),t=XO(),r=wr(),n=kx(),o=/[\\^$.*+?()[\]{}|]/g,a=/^\[object .+?Constructor\]$/,i=Function.prototype,s=Object.prototype,c=i.toString,l=s.hasOwnProperty,p=RegExp("^"+c.call(l).replace(o,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function u(m){if(!r(m)||t(m))return!1;var b=e(m)?p:a;return b.test(n(m))}return ms=u,ms}var hs,Lm;function JO(){if(Lm)return hs;Lm=1;function e(t,r){return t==null?void 0:t[r]}return hs=e,hs}var gs,Fm;function Gr(){if(Fm)return gs;Fm=1;var e=ZO(),t=JO();function r(n,o){var a=t(n,o);return e(a)?a:void 0}return gs=r,gs}var vs,Bm;function di(){if(Bm)return vs;Bm=1;var e=Gr(),t=e(Object,"create");return vs=t,vs}var bs,zm;function QO(){if(zm)return bs;zm=1;var e=di();function t(){this.__data__=e?e(null):{},this.size=0}return bs=t,bs}var ys,qm;function eI(){if(qm)return ys;qm=1;function e(t){var r=this.has(t)&&delete this.__data__[t];return this.size-=r?1:0,r}return ys=e,ys}var xs,Hm;function tI(){if(Hm)return xs;Hm=1;var e=di(),t="__lodash_hash_undefined__",r=Object.prototype,n=r.hasOwnProperty;function o(a){var i=this.__data__;if(e){var s=i[a];return s===t?void 0:s}return n.call(i,a)?i[a]:void 0}return xs=o,xs}var ws,Vm;function rI(){if(Vm)return ws;Vm=1;var e=di(),t=Object.prototype,r=t.hasOwnProperty;function n(o){var a=this.__data__;return e?a[o]!==void 0:r.call(a,o)}return ws=n,ws}var Ss,Gm;function nI(){if(Gm)return Ss;Gm=1;var e=di(),t="__lodash_hash_undefined__";function r(n,o){var a=this.__data__;return this.size+=this.has(n)?0:1,a[n]=e&&o===void 0?t:o,this}return Ss=r,Ss}var Cs,Um;function oI(){if(Um)return Cs;Um=1;var e=QO(),t=eI(),r=tI(),n=rI(),o=nI();function a(i){var s=-1,c=i==null?0:i.length;for(this.clear();++s<c;){var l=i[s];this.set(l[0],l[1])}}return a.prototype.clear=e,a.prototype.delete=t,a.prototype.get=r,a.prototype.has=n,a.prototype.set=o,Cs=a,Cs}var _s,Wm;function aI(){if(Wm)return _s;Wm=1;function e(){this.__data__=[],this.size=0}return _s=e,_s}var Rs,Km;function Wd(){if(Km)return Rs;Km=1;function e(t,r){return t===r||t!==t&&r!==r}return Rs=e,Rs}var Es,Ym;function fi(){if(Ym)return Es;Ym=1;var e=Wd();function t(r,n){for(var o=r.length;o--;)if(e(r[o][0],n))return o;return-1}return Es=t,Es}var Ps,Xm;function iI(){if(Xm)return Ps;Xm=1;var e=fi(),t=Array.prototype,r=t.splice;function n(o){var a=this.__data__,i=e(a,o);if(i<0)return!1;var s=a.length-1;return i==s?a.pop():r.call(a,i,1),--this.size,!0}return Ps=n,Ps}var Ts,Zm;function sI(){if(Zm)return Ts;Zm=1;var e=fi();function t(r){var n=this.__data__,o=e(n,r);return o<0?void 0:n[o][1]}return Ts=t,Ts}var Ns,Jm;function cI(){if(Jm)return Ns;Jm=1;var e=fi();function t(r){return e(this.__data__,r)>-1}return Ns=t,Ns}var As,Qm;function lI(){if(Qm)return As;Qm=1;var e=fi();function t(r,n){var o=this.__data__,a=e(o,r);return a<0?(++this.size,o.push([r,n])):o[a][1]=n,this}return As=t,As}var Ms,eh;function pi(){if(eh)return Ms;eh=1;var e=aI(),t=iI(),r=sI(),n=cI(),o=lI();function a(i){var s=-1,c=i==null?0:i.length;for(this.clear();++s<c;){var l=i[s];this.set(l[0],l[1])}}return a.prototype.clear=e,a.prototype.delete=t,a.prototype.get=r,a.prototype.has=n,a.prototype.set=o,Ms=a,Ms}var Os,th;function Kd(){if(th)return Os;th=1;var e=Gr(),t=Xt(),r=e(t,"Map");return Os=r,Os}var Is,rh;function uI(){if(rh)return Is;rh=1;var e=oI(),t=pi(),r=Kd();function n(){this.size=0,this.__data__={hash:new e,map:new(r||t),string:new e}}return Is=n,Is}var js,nh;function dI(){if(nh)return js;nh=1;function e(t){var r=typeof t;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?t!=="__proto__":t===null}return js=e,js}var Ds,oh;function mi(){if(oh)return Ds;oh=1;var e=dI();function t(r,n){var o=r.__data__;return e(n)?o[typeof n=="string"?"string":"hash"]:o.map}return Ds=t,Ds}var ks,ah;function fI(){if(ah)return ks;ah=1;var e=mi();function t(r){var n=e(this,r).delete(r);return this.size-=n?1:0,n}return ks=t,ks}var $s,ih;function pI(){if(ih)return $s;ih=1;var e=mi();function t(r){return e(this,r).get(r)}return $s=t,$s}var Ls,sh;function mI(){if(sh)return Ls;sh=1;var e=mi();function t(r){return e(this,r).has(r)}return Ls=t,Ls}var Fs,ch;function hI(){if(ch)return Fs;ch=1;var e=mi();function t(r,n){var o=e(this,r),a=o.size;return o.set(r,n),this.size+=o.size==a?0:1,this}return Fs=t,Fs}var Bs,lh;function Yd(){if(lh)return Bs;lh=1;var e=uI(),t=fI(),r=pI(),n=mI(),o=hI();function a(i){var s=-1,c=i==null?0:i.length;for(this.clear();++s<c;){var l=i[s];this.set(l[0],l[1])}}return a.prototype.clear=e,a.prototype.delete=t,a.prototype.get=r,a.prototype.has=n,a.prototype.set=o,Bs=a,Bs}var zs,uh;function gI(){if(uh)return zs;uh=1;var e=Yd(),t="Expected a function";function r(n,o){if(typeof n!="function"||o!=null&&typeof o!="function")throw new TypeError(t);var a=function(){var i=arguments,s=o?o.apply(this,i):i[0],c=a.cache;if(c.has(s))return c.get(s);var l=n.apply(this,i);return a.cache=c.set(s,l)||c,l};return a.cache=new(r.Cache||e),a}return r.Cache=e,zs=r,zs}var qs,dh;function vI(){if(dh)return qs;dh=1;var e=gI(),t=500;function r(n){var o=e(n,function(i){return a.size===t&&a.clear(),i}),a=o.cache;return o}return qs=r,qs}var Hs,fh;function bI(){if(fh)return Hs;fh=1;var e=vI(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,n=e(function(o){var a=[];return o.charCodeAt(0)===46&&a.push(""),o.replace(t,function(i,s,c,l){a.push(c?l.replace(r,"$1"):s||i)}),a});return Hs=n,Hs}var Vs,ph;function $x(){if(ph)return Vs;ph=1;function e(t,r){for(var n=-1,o=t==null?0:t.length,a=Array(o);++n<o;)a[n]=r(t[n],n,t);return a}return Vs=e,Vs}var Gs,mh;function yI(){if(mh)return Gs;mh=1;var e=So(),t=$x(),r=zt(),n=Co(),o=e?e.prototype:void 0,a=o?o.toString:void 0;function i(s){if(typeof s=="string")return s;if(r(s))return t(s,i)+"";if(n(s))return a?a.call(s):"";var c=s+"";return c=="0"&&1/s==-1/0?"-0":c}return Gs=i,Gs}var Us,hh;function Lx(){if(hh)return Us;hh=1;var e=yI();function t(r){return r==null?"":e(r)}return Us=t,Us}var Ws,gh;function Fx(){if(gh)return Ws;gh=1;var e=zt(),t=Gd(),r=bI(),n=Lx();function o(a,i){return e(a)?a:t(a,i)?[a]:r(n(a))}return Ws=o,Ws}var Ks,vh;function hi(){if(vh)return Ks;vh=1;var e=Co();function t(r){if(typeof r=="string"||e(r))return r;var n=r+"";return n=="0"&&1/r==-1/0?"-0":n}return Ks=t,Ks}var Ys,bh;function Xd(){if(bh)return Ys;bh=1;var e=Fx(),t=hi();function r(n,o){o=e(o,n);for(var a=0,i=o.length;n!=null&&a<i;)n=n[t(o[a++])];return a&&a==i?n:void 0}return Ys=r,Ys}var Xs,yh;function Bx(){if(yh)return Xs;yh=1;var e=Xd();function t(r,n,o){var a=r==null?void 0:e(r,n);return a===void 0?o:a}return Xs=t,Xs}Bx();var Zs,xh;function xI(){if(xh)return Zs;xh=1;function e(t){return t==null}return Zs=e,Zs}var wI=xI();const SI=Yt(wI);var Js,wh;function CI(){if(wh)return Js;wh=1;var e=Hr(),t=zt(),r=Vr(),n="[object String]";function o(a){return typeof a=="string"||!t(a)&&r(a)&&e(a)==n}return Js=o,Js}var _I=CI();const zx=Yt(_I);var RI=Ud();const Sa=Yt(RI);var EI=wr();const qx=Yt(EI);var Xo={exports:{}},Ae={};/**
|
|
181
|
+
* @license React
|
|
182
|
+
* react-is.production.min.js
|
|
183
|
+
*
|
|
184
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
185
|
+
*
|
|
186
|
+
* This source code is licensed under the MIT license found in the
|
|
187
|
+
* LICENSE file in the root directory of this source tree.
|
|
188
|
+
*/var Sh;function PI(){if(Sh)return Ae;Sh=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),i=Symbol.for("react.context"),s=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),g;g=Symbol.for("react.module.reference");function h(v){if(typeof v=="object"&&v!==null){var y=v.$$typeof;switch(y){case e:switch(v=v.type,v){case r:case o:case n:case l:case p:return v;default:switch(v=v&&v.$$typeof,v){case s:case i:case c:case m:case u:case a:return v;default:return y}}case t:return y}}}return Ae.ContextConsumer=i,Ae.ContextProvider=a,Ae.Element=e,Ae.ForwardRef=c,Ae.Fragment=r,Ae.Lazy=m,Ae.Memo=u,Ae.Portal=t,Ae.Profiler=o,Ae.StrictMode=n,Ae.Suspense=l,Ae.SuspenseList=p,Ae.isAsyncMode=function(){return!1},Ae.isConcurrentMode=function(){return!1},Ae.isContextConsumer=function(v){return h(v)===i},Ae.isContextProvider=function(v){return h(v)===a},Ae.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===e},Ae.isForwardRef=function(v){return h(v)===c},Ae.isFragment=function(v){return h(v)===r},Ae.isLazy=function(v){return h(v)===m},Ae.isMemo=function(v){return h(v)===u},Ae.isPortal=function(v){return h(v)===t},Ae.isProfiler=function(v){return h(v)===o},Ae.isStrictMode=function(v){return h(v)===n},Ae.isSuspense=function(v){return h(v)===l},Ae.isSuspenseList=function(v){return h(v)===p},Ae.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===r||v===o||v===n||v===l||v===p||v===b||typeof v=="object"&&v!==null&&(v.$$typeof===m||v.$$typeof===u||v.$$typeof===a||v.$$typeof===i||v.$$typeof===c||v.$$typeof===g||v.getModuleId!==void 0)},Ae.typeOf=h,Ae}var Me={};/**
|
|
189
|
+
* @license React
|
|
190
|
+
* react-is.development.js
|
|
191
|
+
*
|
|
192
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
193
|
+
*
|
|
194
|
+
* This source code is licensed under the MIT license found in the
|
|
195
|
+
* LICENSE file in the root directory of this source tree.
|
|
196
|
+
*/var Ch;function TI(){return Ch||(Ch=1,process.env.NODE_ENV!=="production"&&function(){var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),i=Symbol.for("react.context"),s=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),g=!1,h=!1,v=!1,y=!1,x=!1,w;w=Symbol.for("react.module.reference");function S(I){return!!(typeof I=="string"||typeof I=="function"||I===r||I===o||x||I===n||I===l||I===p||y||I===b||g||h||v||typeof I=="object"&&I!==null&&(I.$$typeof===m||I.$$typeof===u||I.$$typeof===a||I.$$typeof===i||I.$$typeof===c||I.$$typeof===w||I.getModuleId!==void 0))}function _(I){if(typeof I=="object"&&I!==null){var ee=I.$$typeof;switch(ee){case e:var pe=I.type;switch(pe){case r:case o:case n:case l:case p:return pe;default:var me=pe&&pe.$$typeof;switch(me){case s:case i:case c:case m:case u:case a:return me;default:return ee}}case t:return ee}}}var R=i,C=a,A=e,P=c,k=r,j=m,L=u,N=t,D=o,$=n,O=l,G=p,H=!1,z=!1;function oe(I){return H||(H=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1}function Z(I){return z||(z=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1}function te(I){return _(I)===i}function F(I){return _(I)===a}function U(I){return typeof I=="object"&&I!==null&&I.$$typeof===e}function Q(I){return _(I)===c}function K(I){return _(I)===r}function q(I){return _(I)===m}function W(I){return _(I)===u}function re(I){return _(I)===t}function J(I){return _(I)===o}function ne(I){return _(I)===n}function V(I){return _(I)===l}function ae(I){return _(I)===p}Me.ContextConsumer=R,Me.ContextProvider=C,Me.Element=A,Me.ForwardRef=P,Me.Fragment=k,Me.Lazy=j,Me.Memo=L,Me.Portal=N,Me.Profiler=D,Me.StrictMode=$,Me.Suspense=O,Me.SuspenseList=G,Me.isAsyncMode=oe,Me.isConcurrentMode=Z,Me.isContextConsumer=te,Me.isContextProvider=F,Me.isElement=U,Me.isForwardRef=Q,Me.isFragment=K,Me.isLazy=q,Me.isMemo=W,Me.isPortal=re,Me.isProfiler=J,Me.isStrictMode=ne,Me.isSuspense=V,Me.isSuspenseList=ae,Me.isValidElementType=S,Me.typeOf=_}()),Me}var _h;function NI(){return _h||(_h=1,process.env.NODE_ENV==="production"?Xo.exports=PI():Xo.exports=TI()),Xo.exports}NI();var Qs,Rh;function Hx(){if(Rh)return Qs;Rh=1;var e=Hr(),t=Vr(),r="[object Number]";function n(o){return typeof o=="number"||t(o)&&e(o)==r}return Qs=n,Qs}var ec,Eh;function AI(){if(Eh)return ec;Eh=1;var e=Hx();function t(r){return e(r)&&r!=+r}return ec=t,ec}var MI=AI();const OI=Yt(MI);var II=Hx();const jI=Yt(II);var Zo=function(t){return zx(t)&&t.indexOf("%")===t.length-1},jt=function(t){return jI(t)&&!OI(t)},Ca=function(t){return jt(t)||zx(t)};function Ru(e){"@babel/helpers - typeof";return Ru=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},Ru(e)}var DI=["viewBox","children"],kI=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],Ph=["points","pathLength"],tc={svg:DI,polygon:Ph,polyline:Ph},Vx=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"],$I=function(t,r,n){return function(o){return t(r,n,o),null}},LI=function(t,r,n){if(!qx(t)||Ru(t)!=="object")return null;var o=null;return Object.keys(t).forEach(function(a){var i=t[a];Vx.includes(a)&&typeof i=="function"&&(o||(o={}),o[a]=$I(i,r,n))}),o},FI=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},BI=function(t,r,n,o){var a,i=(a=tc==null?void 0:tc[o])!==null&&a!==void 0?a:[];return!Sa(t)&&(o&&i.includes(r)||kI.includes(r))||Vx.includes(r)},Gx=function(t,r,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var o=t;if(E.isValidElement(t)&&(o=t.props),!qx(o))return null;var a={};return Object.keys(o).forEach(function(i){var s;BI((s=o)===null||s===void 0?void 0:s[i],i,r,n)&&(a[i]=o[i])}),a},zI=["children","width","height","viewBox","className","style","title","desc"];function Eu(){return Eu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Eu.apply(this,arguments)}function qI(e,t){if(e==null)return{};var r=HI(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function HI(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function VI(e){var t=e.children,r=e.width,n=e.height,o=e.viewBox,a=e.className,i=e.style,s=e.title,c=e.desc,l=qI(e,zI),p=o||{width:r,height:n,x:0,y:0},u=ar("recharts-surface",a);return E.createElement("svg",Eu({},Gx(l,!0,"svg"),{className:u,width:r,height:n,style:i,viewBox:"".concat(p.x," ").concat(p.y," ").concat(p.width," ").concat(p.height)}),E.createElement("title",null,s),E.createElement("desc",null,c),t)}var GI=process.env.NODE_ENV!=="production",da=function(t,r){for(var n=arguments.length,o=new Array(n>2?n-2:0),a=2;a<n;a++)o[a-2]=arguments[a];if(GI&&typeof console<"u"&&console.warn&&(r===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(r===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var i=0;console.warn(r.replace(/%s/g,function(){return o[i++]}))}},rc,Th;function UI(){if(Th)return rc;Th=1;function e(t,r,n){var o=-1,a=t.length;r<0&&(r=-r>a?0:a+r),n=n>a?a:n,n<0&&(n+=a),a=r>n?0:n-r>>>0,r>>>=0;for(var i=Array(a);++o<a;)i[o]=t[o+r];return i}return rc=e,rc}var nc,Nh;function WI(){if(Nh)return nc;Nh=1;var e=UI();function t(r,n,o){var a=r.length;return o=o===void 0?a:o,!n&&o>=a?r:e(r,n,o)}return nc=t,nc}var oc,Ah;function Ux(){if(Ah)return oc;Ah=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",o=t+r+n,a="\\ufe0e\\ufe0f",i="\\u200d",s=RegExp("["+i+e+o+a+"]");function c(l){return s.test(l)}return oc=c,oc}var ac,Mh;function KI(){if(Mh)return ac;Mh=1;function e(t){return t.split("")}return ac=e,ac}var ic,Oh;function YI(){if(Oh)return ic;Oh=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",o=t+r+n,a="\\ufe0e\\ufe0f",i="["+e+"]",s="["+o+"]",c="\\ud83c[\\udffb-\\udfff]",l="(?:"+s+"|"+c+")",p="[^"+e+"]",u="(?:\\ud83c[\\udde6-\\uddff]){2}",m="[\\ud800-\\udbff][\\udc00-\\udfff]",b="\\u200d",g=l+"?",h="["+a+"]?",v="(?:"+b+"(?:"+[p,u,m].join("|")+")"+h+g+")*",y=h+g+v,x="(?:"+[p+s+"?",s,u,m,i].join("|")+")",w=RegExp(c+"(?="+c+")|"+x+y,"g");function S(_){return _.match(w)||[]}return ic=S,ic}var sc,Ih;function XI(){if(Ih)return sc;Ih=1;var e=KI(),t=Ux(),r=YI();function n(o){return t(o)?r(o):e(o)}return sc=n,sc}var cc,jh;function ZI(){if(jh)return cc;jh=1;var e=WI(),t=Ux(),r=XI(),n=Lx();function o(a){return function(i){i=n(i);var s=t(i)?r(i):void 0,c=s?s[0]:i.charAt(0),l=s?e(s,1).join(""):i.slice(1);return c[a]()+l}}return cc=o,cc}var lc,Dh;function JI(){if(Dh)return lc;Dh=1;var e=ZI(),t=e("toUpperCase");return lc=t,lc}var QI=JI();const Wx=Yt(QI);function Jo(e){return function(){return e}}const Kx=Math.cos,_a=Math.sin,qt=Math.sqrt,Ra=Math.PI,gi=2*Ra,Pu=Math.PI,Tu=2*Pu,Mr=1e-6,ej=Tu-Mr;function Yx(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function tj(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Yx;const r=10**t;return function(n){this._+=n[0];for(let o=1,a=n.length;o<a;++o)this._+=Math.round(arguments[o]*r)/r+n[o]}}class rj{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Yx:tj(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,n,o){this._append`Q${+t},${+r},${this._x1=+n},${this._y1=+o}`}bezierCurveTo(t,r,n,o,a,i){this._append`C${+t},${+r},${+n},${+o},${this._x1=+a},${this._y1=+i}`}arcTo(t,r,n,o,a){if(t=+t,r=+r,n=+n,o=+o,a=+a,a<0)throw new Error(`negative radius: ${a}`);let i=this._x1,s=this._y1,c=n-t,l=o-r,p=i-t,u=s-r,m=p*p+u*u;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(m>Mr)if(!(Math.abs(u*c-l*p)>Mr)||!a)this._append`L${this._x1=t},${this._y1=r}`;else{let b=n-i,g=o-s,h=c*c+l*l,v=b*b+g*g,y=Math.sqrt(h),x=Math.sqrt(m),w=a*Math.tan((Pu-Math.acos((h+m-v)/(2*y*x)))/2),S=w/x,_=w/y;Math.abs(S-1)>Mr&&this._append`L${t+S*p},${r+S*u}`,this._append`A${a},${a},0,0,${+(u*b>p*g)},${this._x1=t+_*c},${this._y1=r+_*l}`}}arc(t,r,n,o,a,i){if(t=+t,r=+r,n=+n,i=!!i,n<0)throw new Error(`negative radius: ${n}`);let s=n*Math.cos(o),c=n*Math.sin(o),l=t+s,p=r+c,u=1^i,m=i?o-a:a-o;this._x1===null?this._append`M${l},${p}`:(Math.abs(this._x1-l)>Mr||Math.abs(this._y1-p)>Mr)&&this._append`L${l},${p}`,n&&(m<0&&(m=m%Tu+Tu),m>ej?this._append`A${n},${n},0,1,${u},${t-s},${r-c}A${n},${n},0,1,${u},${this._x1=l},${this._y1=p}`:m>Mr&&this._append`A${n},${n},0,${+(m>=Pu)},${u},${this._x1=t+n*Math.cos(a)},${this._y1=r+n*Math.sin(a)}`)}rect(t,r,n,o){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+o}h${-n}Z`}toString(){return this._}}function nj(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new rj(t)}const Zd={draw(e,t){const r=qt(t/Ra);e.moveTo(r,0),e.arc(0,0,r,0,gi)}},oj={draw(e,t){const r=qt(t/5)/2;e.moveTo(-3*r,-r),e.lineTo(-r,-r),e.lineTo(-r,-3*r),e.lineTo(r,-3*r),e.lineTo(r,-r),e.lineTo(3*r,-r),e.lineTo(3*r,r),e.lineTo(r,r),e.lineTo(r,3*r),e.lineTo(-r,3*r),e.lineTo(-r,r),e.lineTo(-3*r,r),e.closePath()}},Xx=qt(1/3),aj=Xx*2,ij={draw(e,t){const r=qt(t/aj),n=r*Xx;e.moveTo(0,-r),e.lineTo(n,0),e.lineTo(0,r),e.lineTo(-n,0),e.closePath()}},sj={draw(e,t){const r=qt(t),n=-r/2;e.rect(n,n,r,r)}},cj=.8908130915292852,Zx=_a(Ra/10)/_a(7*Ra/10),lj=_a(gi/10)*Zx,uj=-Kx(gi/10)*Zx,dj={draw(e,t){const r=qt(t*cj),n=lj*r,o=uj*r;e.moveTo(0,-r),e.lineTo(n,o);for(let a=1;a<5;++a){const i=gi*a/5,s=Kx(i),c=_a(i);e.lineTo(c*r,-s*r),e.lineTo(s*n-c*o,c*n+s*o)}e.closePath()}},uc=qt(3),fj={draw(e,t){const r=-qt(t/(uc*3));e.moveTo(0,r*2),e.lineTo(-uc*r,-r),e.lineTo(uc*r,-r),e.closePath()}},Rt=-.5,Et=qt(3)/2,Nu=1/qt(12),pj=(Nu/2+1)*3,mj={draw(e,t){const r=qt(t/pj),n=r/2,o=r*Nu,a=n,i=r*Nu+r,s=-a,c=i;e.moveTo(n,o),e.lineTo(a,i),e.lineTo(s,c),e.lineTo(Rt*n-Et*o,Et*n+Rt*o),e.lineTo(Rt*a-Et*i,Et*a+Rt*i),e.lineTo(Rt*s-Et*c,Et*s+Rt*c),e.lineTo(Rt*n+Et*o,Rt*o-Et*n),e.lineTo(Rt*a+Et*i,Rt*i-Et*a),e.lineTo(Rt*s+Et*c,Rt*c-Et*s),e.closePath()}};function hj(e,t){let r=null,n=nj(o);e=typeof e=="function"?e:Jo(e||Zd),t=typeof t=="function"?t:Jo(t===void 0?64:+t);function o(){let a;if(r||(r=a=n()),e.apply(this,arguments).draw(r,+t.apply(this,arguments)),a)return r=null,a+""||null}return o.type=function(a){return arguments.length?(e=typeof a=="function"?a:Jo(a),o):e},o.size=function(a){return arguments.length?(t=typeof a=="function"?a:Jo(+a),o):t},o.context=function(a){return arguments.length?(r=a??null,o):r},o}function eo(e){"@babel/helpers - typeof";return eo=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},eo(e)}var gj=["type","size","sizeType"];function Au(){return Au=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Au.apply(this,arguments)}function kh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function $h(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?kh(Object(r),!0).forEach(function(n){vj(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function vj(e,t,r){return t=bj(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function bj(e){var t=yj(e,"string");return eo(t)=="symbol"?t:t+""}function yj(e,t){if(eo(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(eo(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function xj(e,t){if(e==null)return{};var r=wj(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function wj(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var Jx={symbolCircle:Zd,symbolCross:oj,symbolDiamond:ij,symbolSquare:sj,symbolStar:dj,symbolTriangle:fj,symbolWye:mj},Sj=Math.PI/180,Cj=function(t){var r="symbol".concat(Wx(t));return Jx[r]||Zd},_j=function(t,r,n){if(r==="area")return t;switch(n){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var o=18*Sj;return 1.25*t*t*(Math.tan(o)-Math.tan(o*2)*Math.pow(Math.tan(o),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},Rj=function(t,r){Jx["symbol".concat(Wx(t))]=r},Qx=function(t){var r=t.type,n=r===void 0?"circle":r,o=t.size,a=o===void 0?64:o,i=t.sizeType,s=i===void 0?"area":i,c=xj(t,gj),l=$h($h({},c),{},{type:n,size:a,sizeType:s}),p=function(){var v=Cj(n),y=hj().type(v).size(_j(a,s,n));return y()},u=l.className,m=l.cx,b=l.cy,g=Gx(l,!0);return m===+m&&b===+b&&a===+a?E.createElement("path",Au({},g,{className:ar("recharts-symbols",u),transform:"translate(".concat(m,", ").concat(b,")"),d:p()})):null};Qx.registerSymbol=Rj;function cn(e){"@babel/helpers - typeof";return cn=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},cn(e)}function Mu(){return Mu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Mu.apply(this,arguments)}function Lh(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Ej(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Lh(Object(r),!0).forEach(function(n){to(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Lh(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Pj(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Tj(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,tw(n.key),n)}}function Nj(e,t,r){return t&&Tj(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Aj(e,t,r){return t=Ea(t),Mj(e,ew()?Reflect.construct(t,r||[],Ea(e).constructor):t.apply(e,r))}function Mj(e,t){if(t&&(cn(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Oj(e)}function Oj(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ew(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ew=function(){return!!e})()}function Ea(e){return Ea=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ea(e)}function Ij(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&&Ou(e,t)}function Ou(e,t){return Ou=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},Ou(e,t)}function to(e,t,r){return t=tw(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tw(e){var t=jj(e,"string");return cn(t)=="symbol"?t:t+""}function jj(e,t){if(cn(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(cn(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Ot=32,Jd=function(e){function t(){return Pj(this,t),Aj(this,t,arguments)}return Ij(t,e),Nj(t,[{key:"renderIcon",value:function(n){var o=this.props.inactiveColor,a=Ot/2,i=Ot/6,s=Ot/3,c=n.inactive?o:n.color;if(n.type==="plainline")return E.createElement("line",{strokeWidth:4,fill:"none",stroke:c,strokeDasharray:n.payload.strokeDasharray,x1:0,y1:a,x2:Ot,y2:a,className:"recharts-legend-icon"});if(n.type==="line")return E.createElement("path",{strokeWidth:4,fill:"none",stroke:c,d:"M0,".concat(a,"h").concat(s,`
|
|
197
|
+
A`).concat(i,",").concat(i,",0,1,1,").concat(2*s,",").concat(a,`
|
|
198
|
+
H`).concat(Ot,"M").concat(2*s,",").concat(a,`
|
|
199
|
+
A`).concat(i,",").concat(i,",0,1,1,").concat(s,",").concat(a),className:"recharts-legend-icon"});if(n.type==="rect")return E.createElement("path",{stroke:"none",fill:c,d:"M0,".concat(Ot/8,"h").concat(Ot,"v").concat(Ot*3/4,"h").concat(-32,"z"),className:"recharts-legend-icon"});if(E.isValidElement(n.legendIcon)){var l=Ej({},n);return delete l.legendIcon,E.cloneElement(n.legendIcon,l)}return E.createElement(Qx,{fill:c,cx:a,cy:a,size:Ot,sizeType:"diameter",type:n.type})}},{key:"renderItems",value:function(){var n=this,o=this.props,a=o.payload,i=o.iconSize,s=o.layout,c=o.formatter,l=o.inactiveColor,p={x:0,y:0,width:Ot,height:Ot},u={display:s==="horizontal"?"inline-block":"block",marginRight:10},m={display:"inline-block",verticalAlign:"middle",marginRight:4};return a.map(function(b,g){var h=b.formatter||c,v=ar(to(to({"recharts-legend-item":!0},"legend-item-".concat(g),!0),"inactive",b.inactive));if(b.type==="none")return null;var y=Sa(b.value)?null:b.value;da(!Sa(b.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var x=b.inactive?l:b.color;return E.createElement("li",Mu({className:v,style:u,key:"legend-item-".concat(g)},LI(n.props,b,g)),E.createElement(VI,{width:i,height:i,viewBox:p,style:m},n.renderIcon(b)),E.createElement("span",{className:"recharts-legend-item-text",style:{color:x}},h?h(y,b,g):y))})}},{key:"render",value:function(){var n=this.props,o=n.payload,a=n.layout,i=n.align;if(!o||!o.length)return null;var s={padding:0,margin:0,textAlign:a==="horizontal"?i:"left"};return E.createElement("ul",{className:"recharts-default-legend",style:s},this.renderItems())}}])}(E.PureComponent);to(Jd,"displayName","Legend");to(Jd,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var dc,Fh;function Dj(){if(Fh)return dc;Fh=1;var e=pi();function t(){this.__data__=new e,this.size=0}return dc=t,dc}var fc,Bh;function kj(){if(Bh)return fc;Bh=1;function e(t){var r=this.__data__,n=r.delete(t);return this.size=r.size,n}return fc=e,fc}var pc,zh;function $j(){if(zh)return pc;zh=1;function e(t){return this.__data__.get(t)}return pc=e,pc}var mc,qh;function Lj(){if(qh)return mc;qh=1;function e(t){return this.__data__.has(t)}return mc=e,mc}var hc,Hh;function Fj(){if(Hh)return hc;Hh=1;var e=pi(),t=Kd(),r=Yd(),n=200;function o(a,i){var s=this.__data__;if(s instanceof e){var c=s.__data__;if(!t||c.length<n-1)return c.push([a,i]),this.size=++s.size,this;s=this.__data__=new r(c)}return s.set(a,i),this.size=s.size,this}return hc=o,hc}var gc,Vh;function rw(){if(Vh)return gc;Vh=1;var e=pi(),t=Dj(),r=kj(),n=$j(),o=Lj(),a=Fj();function i(s){var c=this.__data__=new e(s);this.size=c.size}return i.prototype.clear=t,i.prototype.delete=r,i.prototype.get=n,i.prototype.has=o,i.prototype.set=a,gc=i,gc}var vc,Gh;function Bj(){if(Gh)return vc;Gh=1;var e="__lodash_hash_undefined__";function t(r){return this.__data__.set(r,e),this}return vc=t,vc}var bc,Uh;function zj(){if(Uh)return bc;Uh=1;function e(t){return this.__data__.has(t)}return bc=e,bc}var yc,Wh;function nw(){if(Wh)return yc;Wh=1;var e=Yd(),t=Bj(),r=zj();function n(o){var a=-1,i=o==null?0:o.length;for(this.__data__=new e;++a<i;)this.add(o[a])}return n.prototype.add=n.prototype.push=t,n.prototype.has=r,yc=n,yc}var xc,Kh;function qj(){if(Kh)return xc;Kh=1;function e(t,r){for(var n=-1,o=t==null?0:t.length;++n<o;)if(r(t[n],n,t))return!0;return!1}return xc=e,xc}var wc,Yh;function ow(){if(Yh)return wc;Yh=1;function e(t,r){return t.has(r)}return wc=e,wc}var Sc,Xh;function aw(){if(Xh)return Sc;Xh=1;var e=nw(),t=qj(),r=ow(),n=1,o=2;function a(i,s,c,l,p,u){var m=c&n,b=i.length,g=s.length;if(b!=g&&!(m&&g>b))return!1;var h=u.get(i),v=u.get(s);if(h&&v)return h==s&&v==i;var y=-1,x=!0,w=c&o?new e:void 0;for(u.set(i,s),u.set(s,i);++y<b;){var S=i[y],_=s[y];if(l)var R=m?l(_,S,y,s,i,u):l(S,_,y,i,s,u);if(R!==void 0){if(R)continue;x=!1;break}if(w){if(!t(s,function(C,A){if(!r(w,A)&&(S===C||p(S,C,c,l,u)))return w.push(A)})){x=!1;break}}else if(!(S===_||p(S,_,c,l,u))){x=!1;break}}return u.delete(i),u.delete(s),x}return Sc=a,Sc}var Cc,Zh;function Hj(){if(Zh)return Cc;Zh=1;var e=Xt(),t=e.Uint8Array;return Cc=t,Cc}var _c,Jh;function Vj(){if(Jh)return _c;Jh=1;function e(t){var r=-1,n=Array(t.size);return t.forEach(function(o,a){n[++r]=[a,o]}),n}return _c=e,_c}var Rc,Qh;function Qd(){if(Qh)return Rc;Qh=1;function e(t){var r=-1,n=Array(t.size);return t.forEach(function(o){n[++r]=o}),n}return Rc=e,Rc}var Ec,eg;function Gj(){if(eg)return Ec;eg=1;var e=So(),t=Hj(),r=Wd(),n=aw(),o=Vj(),a=Qd(),i=1,s=2,c="[object Boolean]",l="[object Date]",p="[object Error]",u="[object Map]",m="[object Number]",b="[object RegExp]",g="[object Set]",h="[object String]",v="[object Symbol]",y="[object ArrayBuffer]",x="[object DataView]",w=e?e.prototype:void 0,S=w?w.valueOf:void 0;function _(R,C,A,P,k,j,L){switch(A){case x:if(R.byteLength!=C.byteLength||R.byteOffset!=C.byteOffset)return!1;R=R.buffer,C=C.buffer;case y:return!(R.byteLength!=C.byteLength||!j(new t(R),new t(C)));case c:case l:case m:return r(+R,+C);case p:return R.name==C.name&&R.message==C.message;case b:case h:return R==C+"";case u:var N=o;case g:var D=P&i;if(N||(N=a),R.size!=C.size&&!D)return!1;var $=L.get(R);if($)return $==C;P|=s,L.set(R,C);var O=n(N(R),N(C),P,k,j,L);return L.delete(R),O;case v:if(S)return S.call(R)==S.call(C)}return!1}return Ec=_,Ec}var Pc,tg;function iw(){if(tg)return Pc;tg=1;function e(t,r){for(var n=-1,o=r.length,a=t.length;++n<o;)t[a+n]=r[n];return t}return Pc=e,Pc}var Tc,rg;function Uj(){if(rg)return Tc;rg=1;var e=iw(),t=zt();function r(n,o,a){var i=o(n);return t(n)?i:e(i,a(n))}return Tc=r,Tc}var Nc,ng;function Wj(){if(ng)return Nc;ng=1;function e(t,r){for(var n=-1,o=t==null?0:t.length,a=0,i=[];++n<o;){var s=t[n];r(s,n,t)&&(i[a++]=s)}return i}return Nc=e,Nc}var Ac,og;function Kj(){if(og)return Ac;og=1;function e(){return[]}return Ac=e,Ac}var Mc,ag;function Yj(){if(ag)return Mc;ag=1;var e=Wj(),t=Kj(),r=Object.prototype,n=r.propertyIsEnumerable,o=Object.getOwnPropertySymbols,a=o?function(i){return i==null?[]:(i=Object(i),e(o(i),function(s){return n.call(i,s)}))}:t;return Mc=a,Mc}var Oc,ig;function Xj(){if(ig)return Oc;ig=1;function e(t,r){for(var n=-1,o=Array(t);++n<t;)o[n]=r(n);return o}return Oc=e,Oc}var Ic,sg;function Zj(){if(sg)return Ic;sg=1;var e=Hr(),t=Vr(),r="[object Arguments]";function n(o){return t(o)&&e(o)==r}return Ic=n,Ic}var jc,cg;function ef(){if(cg)return jc;cg=1;var e=Zj(),t=Vr(),r=Object.prototype,n=r.hasOwnProperty,o=r.propertyIsEnumerable,a=e(function(){return arguments}())?e:function(i){return t(i)&&n.call(i,"callee")&&!o.call(i,"callee")};return jc=a,jc}var qn={exports:{}},Dc,lg;function Jj(){if(lg)return Dc;lg=1;function e(){return!1}return Dc=e,Dc}qn.exports;var ug;function sw(){return ug||(ug=1,function(e,t){var r=Xt(),n=Jj(),o=t&&!t.nodeType&&t,a=o&&!0&&e&&!e.nodeType&&e,i=a&&a.exports===o,s=i?r.Buffer:void 0,c=s?s.isBuffer:void 0,l=c||n;e.exports=l}(qn,qn.exports)),qn.exports}var kc,dg;function tf(){if(dg)return kc;dg=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function r(n,o){var a=typeof n;return o=o??e,!!o&&(a=="number"||a!="symbol"&&t.test(n))&&n>-1&&n%1==0&&n<o}return kc=r,kc}var $c,fg;function rf(){if(fg)return $c;fg=1;var e=9007199254740991;function t(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=e}return $c=t,$c}var Lc,pg;function Qj(){if(pg)return Lc;pg=1;var e=Hr(),t=rf(),r=Vr(),n="[object Arguments]",o="[object Array]",a="[object Boolean]",i="[object Date]",s="[object Error]",c="[object Function]",l="[object Map]",p="[object Number]",u="[object Object]",m="[object RegExp]",b="[object Set]",g="[object String]",h="[object WeakMap]",v="[object ArrayBuffer]",y="[object DataView]",x="[object Float32Array]",w="[object Float64Array]",S="[object Int8Array]",_="[object Int16Array]",R="[object Int32Array]",C="[object Uint8Array]",A="[object Uint8ClampedArray]",P="[object Uint16Array]",k="[object Uint32Array]",j={};j[x]=j[w]=j[S]=j[_]=j[R]=j[C]=j[A]=j[P]=j[k]=!0,j[n]=j[o]=j[v]=j[a]=j[y]=j[i]=j[s]=j[c]=j[l]=j[p]=j[u]=j[m]=j[b]=j[g]=j[h]=!1;function L(N){return r(N)&&t(N.length)&&!!j[e(N)]}return Lc=L,Lc}var Fc,mg;function cw(){if(mg)return Fc;mg=1;function e(t){return function(r){return t(r)}}return Fc=e,Fc}var Hn={exports:{}};Hn.exports;var hg;function eD(){return hg||(hg=1,function(e,t){var r=Dx(),n=t&&!t.nodeType&&t,o=n&&!0&&e&&!e.nodeType&&e,a=o&&o.exports===n,i=a&&r.process,s=function(){try{var c=o&&o.require&&o.require("util").types;return c||i&&i.binding&&i.binding("util")}catch{}}();e.exports=s}(Hn,Hn.exports)),Hn.exports}var Bc,gg;function lw(){if(gg)return Bc;gg=1;var e=Qj(),t=cw(),r=eD(),n=r&&r.isTypedArray,o=n?t(n):e;return Bc=o,Bc}var zc,vg;function tD(){if(vg)return zc;vg=1;var e=Xj(),t=ef(),r=zt(),n=sw(),o=tf(),a=lw(),i=Object.prototype,s=i.hasOwnProperty;function c(l,p){var u=r(l),m=!u&&t(l),b=!u&&!m&&n(l),g=!u&&!m&&!b&&a(l),h=u||m||b||g,v=h?e(l.length,String):[],y=v.length;for(var x in l)(p||s.call(l,x))&&!(h&&(x=="length"||b&&(x=="offset"||x=="parent")||g&&(x=="buffer"||x=="byteLength"||x=="byteOffset")||o(x,y)))&&v.push(x);return v}return zc=c,zc}var qc,bg;function rD(){if(bg)return qc;bg=1;var e=Object.prototype;function t(r){var n=r&&r.constructor,o=typeof n=="function"&&n.prototype||e;return r===o}return qc=t,qc}var Hc,yg;function nD(){if(yg)return Hc;yg=1;function e(t,r){return function(n){return t(r(n))}}return Hc=e,Hc}var Vc,xg;function oD(){if(xg)return Vc;xg=1;var e=nD(),t=e(Object.keys,Object);return Vc=t,Vc}var Gc,wg;function aD(){if(wg)return Gc;wg=1;var e=rD(),t=oD(),r=Object.prototype,n=r.hasOwnProperty;function o(a){if(!e(a))return t(a);var i=[];for(var s in Object(a))n.call(a,s)&&s!="constructor"&&i.push(s);return i}return Gc=o,Gc}var Uc,Sg;function vi(){if(Sg)return Uc;Sg=1;var e=Ud(),t=rf();function r(n){return n!=null&&t(n.length)&&!e(n)}return Uc=r,Uc}var Wc,Cg;function nf(){if(Cg)return Wc;Cg=1;var e=tD(),t=aD(),r=vi();function n(o){return r(o)?e(o):t(o)}return Wc=n,Wc}var Kc,_g;function iD(){if(_g)return Kc;_g=1;var e=Uj(),t=Yj(),r=nf();function n(o){return e(o,r,t)}return Kc=n,Kc}var Yc,Rg;function sD(){if(Rg)return Yc;Rg=1;var e=iD(),t=1,r=Object.prototype,n=r.hasOwnProperty;function o(a,i,s,c,l,p){var u=s&t,m=e(a),b=m.length,g=e(i),h=g.length;if(b!=h&&!u)return!1;for(var v=b;v--;){var y=m[v];if(!(u?y in i:n.call(i,y)))return!1}var x=p.get(a),w=p.get(i);if(x&&w)return x==i&&w==a;var S=!0;p.set(a,i),p.set(i,a);for(var _=u;++v<b;){y=m[v];var R=a[y],C=i[y];if(c)var A=u?c(C,R,y,i,a,p):c(R,C,y,a,i,p);if(!(A===void 0?R===C||l(R,C,s,c,p):A)){S=!1;break}_||(_=y=="constructor")}if(S&&!_){var P=a.constructor,k=i.constructor;P!=k&&"constructor"in a&&"constructor"in i&&!(typeof P=="function"&&P instanceof P&&typeof k=="function"&&k instanceof k)&&(S=!1)}return p.delete(a),p.delete(i),S}return Yc=o,Yc}var Xc,Eg;function cD(){if(Eg)return Xc;Eg=1;var e=Gr(),t=Xt(),r=e(t,"DataView");return Xc=r,Xc}var Zc,Pg;function lD(){if(Pg)return Zc;Pg=1;var e=Gr(),t=Xt(),r=e(t,"Promise");return Zc=r,Zc}var Jc,Tg;function uw(){if(Tg)return Jc;Tg=1;var e=Gr(),t=Xt(),r=e(t,"Set");return Jc=r,Jc}var Qc,Ng;function uD(){if(Ng)return Qc;Ng=1;var e=Gr(),t=Xt(),r=e(t,"WeakMap");return Qc=r,Qc}var el,Ag;function dD(){if(Ag)return el;Ag=1;var e=cD(),t=Kd(),r=lD(),n=uw(),o=uD(),a=Hr(),i=kx(),s="[object Map]",c="[object Object]",l="[object Promise]",p="[object Set]",u="[object WeakMap]",m="[object DataView]",b=i(e),g=i(t),h=i(r),v=i(n),y=i(o),x=a;return(e&&x(new e(new ArrayBuffer(1)))!=m||t&&x(new t)!=s||r&&x(r.resolve())!=l||n&&x(new n)!=p||o&&x(new o)!=u)&&(x=function(w){var S=a(w),_=S==c?w.constructor:void 0,R=_?i(_):"";if(R)switch(R){case b:return m;case g:return s;case h:return l;case v:return p;case y:return u}return S}),el=x,el}var tl,Mg;function fD(){if(Mg)return tl;Mg=1;var e=rw(),t=aw(),r=Gj(),n=sD(),o=dD(),a=zt(),i=sw(),s=lw(),c=1,l="[object Arguments]",p="[object Array]",u="[object Object]",m=Object.prototype,b=m.hasOwnProperty;function g(h,v,y,x,w,S){var _=a(h),R=a(v),C=_?p:o(h),A=R?p:o(v);C=C==l?u:C,A=A==l?u:A;var P=C==u,k=A==u,j=C==A;if(j&&i(h)){if(!i(v))return!1;_=!0,P=!1}if(j&&!P)return S||(S=new e),_||s(h)?t(h,v,y,x,w,S):r(h,v,C,y,x,w,S);if(!(y&c)){var L=P&&b.call(h,"__wrapped__"),N=k&&b.call(v,"__wrapped__");if(L||N){var D=L?h.value():h,$=N?v.value():v;return S||(S=new e),w(D,$,y,x,S)}}return j?(S||(S=new e),n(h,v,y,x,w,S)):!1}return tl=g,tl}var rl,Og;function dw(){if(Og)return rl;Og=1;var e=fD(),t=Vr();function r(n,o,a,i,s){return n===o?!0:n==null||o==null||!t(n)&&!t(o)?n!==n&&o!==o:e(n,o,a,i,r,s)}return rl=r,rl}var nl,Ig;function pD(){if(Ig)return nl;Ig=1;var e=rw(),t=dw(),r=1,n=2;function o(a,i,s,c){var l=s.length,p=l,u=!c;if(a==null)return!p;for(a=Object(a);l--;){var m=s[l];if(u&&m[2]?m[1]!==a[m[0]]:!(m[0]in a))return!1}for(;++l<p;){m=s[l];var b=m[0],g=a[b],h=m[1];if(u&&m[2]){if(g===void 0&&!(b in a))return!1}else{var v=new e;if(c)var y=c(g,h,b,a,i,v);if(!(y===void 0?t(h,g,r|n,c,v):y))return!1}}return!0}return nl=o,nl}var ol,jg;function fw(){if(jg)return ol;jg=1;var e=wr();function t(r){return r===r&&!e(r)}return ol=t,ol}var al,Dg;function mD(){if(Dg)return al;Dg=1;var e=fw(),t=nf();function r(n){for(var o=t(n),a=o.length;a--;){var i=o[a],s=n[i];o[a]=[i,s,e(s)]}return o}return al=r,al}var il,kg;function pw(){if(kg)return il;kg=1;function e(t,r){return function(n){return n==null?!1:n[t]===r&&(r!==void 0||t in Object(n))}}return il=e,il}var sl,$g;function hD(){if($g)return sl;$g=1;var e=pD(),t=mD(),r=pw();function n(o){var a=t(o);return a.length==1&&a[0][2]?r(a[0][0],a[0][1]):function(i){return i===o||e(i,o,a)}}return sl=n,sl}var cl,Lg;function gD(){if(Lg)return cl;Lg=1;function e(t,r){return t!=null&&r in Object(t)}return cl=e,cl}var ll,Fg;function vD(){if(Fg)return ll;Fg=1;var e=Fx(),t=ef(),r=zt(),n=tf(),o=rf(),a=hi();function i(s,c,l){c=e(c,s);for(var p=-1,u=c.length,m=!1;++p<u;){var b=a(c[p]);if(!(m=s!=null&&l(s,b)))break;s=s[b]}return m||++p!=u?m:(u=s==null?0:s.length,!!u&&o(u)&&n(b,u)&&(r(s)||t(s)))}return ll=i,ll}var ul,Bg;function bD(){if(Bg)return ul;Bg=1;var e=gD(),t=vD();function r(n,o){return n!=null&&t(n,o,e)}return ul=r,ul}var dl,zg;function yD(){if(zg)return dl;zg=1;var e=dw(),t=Bx(),r=bD(),n=Gd(),o=fw(),a=pw(),i=hi(),s=1,c=2;function l(p,u){return n(p)&&o(u)?a(i(p),u):function(m){var b=t(m,p);return b===void 0&&b===u?r(m,p):e(u,b,s|c)}}return dl=l,dl}var fl,qg;function bi(){if(qg)return fl;qg=1;function e(t){return t}return fl=e,fl}var pl,Hg;function xD(){if(Hg)return pl;Hg=1;function e(t){return function(r){return r==null?void 0:r[t]}}return pl=e,pl}var ml,Vg;function wD(){if(Vg)return ml;Vg=1;var e=Xd();function t(r){return function(n){return e(n,r)}}return ml=t,ml}var hl,Gg;function SD(){if(Gg)return hl;Gg=1;var e=xD(),t=wD(),r=Gd(),n=hi();function o(a){return r(a)?e(n(a)):t(a)}return hl=o,hl}var gl,Ug;function mw(){if(Ug)return gl;Ug=1;var e=hD(),t=yD(),r=bi(),n=zt(),o=SD();function a(i){return typeof i=="function"?i:i==null?r:typeof i=="object"?n(i)?t(i[0],i[1]):e(i):o(i)}return gl=a,gl}var vl,Wg;function CD(){if(Wg)return vl;Wg=1;function e(t,r,n,o){for(var a=t.length,i=n+(o?1:-1);o?i--:++i<a;)if(r(t[i],i,t))return i;return-1}return vl=e,vl}var bl,Kg;function _D(){if(Kg)return bl;Kg=1;function e(t){return t!==t}return bl=e,bl}var yl,Yg;function RD(){if(Yg)return yl;Yg=1;function e(t,r,n){for(var o=n-1,a=t.length;++o<a;)if(t[o]===r)return o;return-1}return yl=e,yl}var xl,Xg;function ED(){if(Xg)return xl;Xg=1;var e=CD(),t=_D(),r=RD();function n(o,a,i){return a===a?r(o,a,i):e(o,t,i)}return xl=n,xl}var wl,Zg;function PD(){if(Zg)return wl;Zg=1;var e=ED();function t(r,n){var o=r==null?0:r.length;return!!o&&e(r,n,0)>-1}return wl=t,wl}var Sl,Jg;function TD(){if(Jg)return Sl;Jg=1;function e(t,r,n){for(var o=-1,a=t==null?0:t.length;++o<a;)if(n(r,t[o]))return!0;return!1}return Sl=e,Sl}var Cl,Qg;function ND(){if(Qg)return Cl;Qg=1;function e(){}return Cl=e,Cl}var _l,ev;function AD(){if(ev)return _l;ev=1;var e=uw(),t=ND(),r=Qd(),n=1/0,o=e&&1/r(new e([,-0]))[1]==n?function(a){return new e(a)}:t;return _l=o,_l}var Rl,tv;function MD(){if(tv)return Rl;tv=1;var e=nw(),t=PD(),r=TD(),n=ow(),o=AD(),a=Qd(),i=200;function s(c,l,p){var u=-1,m=t,b=c.length,g=!0,h=[],v=h;if(p)g=!1,m=r;else if(b>=i){var y=l?null:o(c);if(y)return a(y);g=!1,m=n,v=new e}else v=l?[]:h;e:for(;++u<b;){var x=c[u],w=l?l(x):x;if(x=p||x!==0?x:0,g&&w===w){for(var S=v.length;S--;)if(v[S]===w)continue e;l&&v.push(w),h.push(x)}else m(v,w,p)||(v!==h&&v.push(w),h.push(x))}return h}return Rl=s,Rl}var El,rv;function OD(){if(rv)return El;rv=1;var e=mw(),t=MD();function r(n,o){return n&&n.length?t(n,e(o,2)):[]}return El=r,El}var ID=OD();const nv=Yt(ID);function hw(e,t,r){return t===!0?nv(e,r):Sa(t)?nv(e,t):e}function ln(e){"@babel/helpers - typeof";return ln=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},ln(e)}var jD=["ref"];function ov(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function rr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ov(Object(r),!0).forEach(function(n){yi(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ov(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function DD(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function av(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,vw(n.key),n)}}function kD(e,t,r){return t&&av(e.prototype,t),r&&av(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function $D(e,t,r){return t=Pa(t),LD(e,gw()?Reflect.construct(t,r||[],Pa(e).constructor):t.apply(e,r))}function LD(e,t){if(t&&(ln(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return FD(e)}function FD(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gw(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(gw=function(){return!!e})()}function Pa(e){return Pa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Pa(e)}function BD(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&&Iu(e,t)}function Iu(e,t){return Iu=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},Iu(e,t)}function yi(e,t,r){return t=vw(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function vw(e){var t=zD(e,"string");return ln(t)=="symbol"?t:t+""}function zD(e,t){if(ln(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ln(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function qD(e,t){if(e==null)return{};var r=HD(e,t),n,o;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function HD(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function VD(e){return e.value}function GD(e,t){if(E.isValidElement(e))return E.cloneElement(e,t);if(typeof e=="function")return E.createElement(e,t);t.ref;var r=qD(t,jD);return E.createElement(Jd,r)}var iv=1,of=function(e){function t(){var r;DD(this,t);for(var n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];return r=$D(this,t,[].concat(o)),yi(r,"lastBoundingBox",{width:-1,height:-1}),r}return BD(t,e),kD(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();return n.height=this.wrapperNode.offsetHeight,n.width=this.wrapperNode.offsetWidth,n}return null}},{key:"updateBBox",value:function(){var n=this.props.onBBoxUpdate,o=this.getBBox();o?(Math.abs(o.width-this.lastBoundingBox.width)>iv||Math.abs(o.height-this.lastBoundingBox.height)>iv)&&(this.lastBoundingBox.width=o.width,this.lastBoundingBox.height=o.height,n&&n(o)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,n&&n(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?rr({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(n){var o=this.props,a=o.layout,i=o.align,s=o.verticalAlign,c=o.margin,l=o.chartWidth,p=o.chartHeight,u,m;if(!n||(n.left===void 0||n.left===null)&&(n.right===void 0||n.right===null))if(i==="center"&&a==="vertical"){var b=this.getBBoxSnapshot();u={left:((l||0)-b.width)/2}}else u=i==="right"?{right:c&&c.right||0}:{left:c&&c.left||0};if(!n||(n.top===void 0||n.top===null)&&(n.bottom===void 0||n.bottom===null))if(s==="middle"){var g=this.getBBoxSnapshot();m={top:((p||0)-g.height)/2}}else m=s==="bottom"?{bottom:c&&c.bottom||0}:{top:c&&c.top||0};return rr(rr({},u),m)}},{key:"render",value:function(){var n=this,o=this.props,a=o.content,i=o.width,s=o.height,c=o.wrapperStyle,l=o.payloadUniqBy,p=o.payload,u=rr(rr({position:"absolute",width:i||"auto",height:s||"auto"},this.getDefaultPosition(c)),c);return E.createElement("div",{className:"recharts-legend-wrapper",style:u,ref:function(b){n.wrapperNode=b}},GD(a,rr(rr({},this.props),{},{payload:hw(p,l,VD)})))}}],[{key:"getWithHeight",value:function(n,o){var a=rr(rr({},this.defaultProps),n.props),i=a.layout;return i==="vertical"&&jt(n.props.height)?{height:n.props.height}:i==="horizontal"?{width:n.props.width||o}:null}}])}(E.PureComponent);yi(of,"displayName","Legend");yi(of,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var Pl,sv;function UD(){if(sv)return Pl;sv=1;var e=So(),t=ef(),r=zt(),n=e?e.isConcatSpreadable:void 0;function o(a){return r(a)||t(a)||!!(n&&a&&a[n])}return Pl=o,Pl}var Tl,cv;function WD(){if(cv)return Tl;cv=1;var e=iw(),t=UD();function r(n,o,a,i,s){var c=-1,l=n.length;for(a||(a=t),s||(s=[]);++c<l;){var p=n[c];o>0&&a(p)?o>1?r(p,o-1,a,i,s):e(s,p):i||(s[s.length]=p)}return s}return Tl=r,Tl}var Nl,lv;function KD(){if(lv)return Nl;lv=1;function e(t){return function(r,n,o){for(var a=-1,i=Object(r),s=o(r),c=s.length;c--;){var l=s[t?c:++a];if(n(i[l],l,i)===!1)break}return r}}return Nl=e,Nl}var Al,uv;function YD(){if(uv)return Al;uv=1;var e=KD(),t=e();return Al=t,Al}var Ml,dv;function XD(){if(dv)return Ml;dv=1;var e=YD(),t=nf();function r(n,o){return n&&e(n,o,t)}return Ml=r,Ml}var Ol,fv;function ZD(){if(fv)return Ol;fv=1;var e=vi();function t(r,n){return function(o,a){if(o==null)return o;if(!e(o))return r(o,a);for(var i=o.length,s=n?i:-1,c=Object(o);(n?s--:++s<i)&&a(c[s],s,c)!==!1;);return o}}return Ol=t,Ol}var Il,pv;function JD(){if(pv)return Il;pv=1;var e=XD(),t=ZD(),r=t(e);return Il=r,Il}var jl,mv;function QD(){if(mv)return jl;mv=1;var e=JD(),t=vi();function r(n,o){var a=-1,i=t(n)?Array(n.length):[];return e(n,function(s,c,l){i[++a]=o(s,c,l)}),i}return jl=r,jl}var Dl,hv;function ek(){if(hv)return Dl;hv=1;function e(t,r){var n=t.length;for(t.sort(r);n--;)t[n]=t[n].value;return t}return Dl=e,Dl}var kl,gv;function tk(){if(gv)return kl;gv=1;var e=Co();function t(r,n){if(r!==n){var o=r!==void 0,a=r===null,i=r===r,s=e(r),c=n!==void 0,l=n===null,p=n===n,u=e(n);if(!l&&!u&&!s&&r>n||s&&c&&p&&!l&&!u||a&&c&&p||!o&&p||!i)return 1;if(!a&&!s&&!u&&r<n||u&&o&&i&&!a&&!s||l&&o&&i||!c&&i||!p)return-1}return 0}return kl=t,kl}var $l,vv;function rk(){if(vv)return $l;vv=1;var e=tk();function t(r,n,o){for(var a=-1,i=r.criteria,s=n.criteria,c=i.length,l=o.length;++a<c;){var p=e(i[a],s[a]);if(p){if(a>=l)return p;var u=o[a];return p*(u=="desc"?-1:1)}}return r.index-n.index}return $l=t,$l}var Ll,bv;function nk(){if(bv)return Ll;bv=1;var e=$x(),t=Xd(),r=mw(),n=QD(),o=ek(),a=cw(),i=rk(),s=bi(),c=zt();function l(p,u,m){u.length?u=e(u,function(h){return c(h)?function(v){return t(v,h.length===1?h[0]:h)}:h}):u=[s];var b=-1;u=e(u,a(r));var g=n(p,function(h,v,y){var x=e(u,function(w){return w(h)});return{criteria:x,index:++b,value:h}});return o(g,function(h,v){return i(h,v,m)})}return Ll=l,Ll}var Fl,yv;function ok(){if(yv)return Fl;yv=1;function e(t,r,n){switch(n.length){case 0:return t.call(r);case 1:return t.call(r,n[0]);case 2:return t.call(r,n[0],n[1]);case 3:return t.call(r,n[0],n[1],n[2])}return t.apply(r,n)}return Fl=e,Fl}var Bl,xv;function ak(){if(xv)return Bl;xv=1;var e=ok(),t=Math.max;function r(n,o,a){return o=t(o===void 0?n.length-1:o,0),function(){for(var i=arguments,s=-1,c=t(i.length-o,0),l=Array(c);++s<c;)l[s]=i[o+s];s=-1;for(var p=Array(o+1);++s<o;)p[s]=i[s];return p[o]=a(l),e(n,this,p)}}return Bl=r,Bl}var zl,wv;function ik(){if(wv)return zl;wv=1;function e(t){return function(){return t}}return zl=e,zl}var ql,Sv;function sk(){if(Sv)return ql;Sv=1;var e=Gr(),t=function(){try{var r=e(Object,"defineProperty");return r({},"",{}),r}catch{}}();return ql=t,ql}var Hl,Cv;function ck(){if(Cv)return Hl;Cv=1;var e=ik(),t=sk(),r=bi(),n=t?function(o,a){return t(o,"toString",{configurable:!0,enumerable:!1,value:e(a),writable:!0})}:r;return Hl=n,Hl}var Vl,_v;function lk(){if(_v)return Vl;_v=1;var e=800,t=16,r=Date.now;function n(o){var a=0,i=0;return function(){var s=r(),c=t-(s-i);if(i=s,c>0){if(++a>=e)return arguments[0]}else a=0;return o.apply(void 0,arguments)}}return Vl=n,Vl}var Gl,Rv;function uk(){if(Rv)return Gl;Rv=1;var e=ck(),t=lk(),r=t(e);return Gl=r,Gl}var Ul,Ev;function dk(){if(Ev)return Ul;Ev=1;var e=bi(),t=ak(),r=uk();function n(o,a){return r(t(o,a,e),o+"")}return Ul=n,Ul}var Wl,Pv;function fk(){if(Pv)return Wl;Pv=1;var e=Wd(),t=vi(),r=tf(),n=wr();function o(a,i,s){if(!n(s))return!1;var c=typeof i;return(c=="number"?t(s)&&r(i,s.length):c=="string"&&i in s)?e(s[i],a):!1}return Wl=o,Wl}var Kl,Tv;function pk(){if(Tv)return Kl;Tv=1;var e=WD(),t=nk(),r=dk(),n=fk(),o=r(function(a,i){if(a==null)return[];var s=i.length;return s>1&&n(a,i[0],i[1])?i=[]:s>2&&n(i[0],i[1],i[2])&&(i=[i[0]]),t(a,e(i,1),[])});return Kl=o,Kl}var mk=pk();const hk=Yt(mk);function ro(e){"@babel/helpers - typeof";return ro=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},ro(e)}function ju(){return ju=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ju.apply(this,arguments)}function gk(e,t){return xk(e)||yk(e,t)||bk(e,t)||vk()}function vk(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
200
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function bk(e,t){if(e){if(typeof e=="string")return Nv(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Nv(e,t)}}function Nv(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function yk(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,o,a,i,s=[],c=!0,l=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(p){l=!0,o=p}finally{try{if(!c&&r.return!=null&&(i=r.return(),Object(i)!==i))return}finally{if(l)throw o}}return s}}function xk(e){if(Array.isArray(e))return e}function Av(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Yl(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Av(Object(r),!0).forEach(function(n){wk(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Av(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function wk(e,t,r){return t=Sk(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Sk(e){var t=Ck(e,"string");return ro(t)=="symbol"?t:t+""}function Ck(e,t){if(ro(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(ro(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function _k(e){return Array.isArray(e)&&Ca(e[0])&&Ca(e[1])?e.join(" ~ "):e}var Rk=function(t){var r=t.separator,n=r===void 0?" : ":r,o=t.contentStyle,a=o===void 0?{}:o,i=t.itemStyle,s=i===void 0?{}:i,c=t.labelStyle,l=c===void 0?{}:c,p=t.payload,u=t.formatter,m=t.itemSorter,b=t.wrapperClassName,g=t.labelClassName,h=t.label,v=t.labelFormatter,y=t.accessibilityLayer,x=y===void 0?!1:y,w=function(){if(p&&p.length){var L={padding:0,margin:0},N=(m?hk(p,m):p).map(function(D,$){if(D.type==="none")return null;var O=Yl({display:"block",paddingTop:4,paddingBottom:4,color:D.color||"#000"},s),G=D.formatter||u||_k,H=D.value,z=D.name,oe=H,Z=z;if(G&&oe!=null&&Z!=null){var te=G(H,z,D,$,p);if(Array.isArray(te)){var F=gk(te,2);oe=F[0],Z=F[1]}else oe=te}return E.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat($),style:O},Ca(Z)?E.createElement("span",{className:"recharts-tooltip-item-name"},Z):null,Ca(Z)?E.createElement("span",{className:"recharts-tooltip-item-separator"},n):null,E.createElement("span",{className:"recharts-tooltip-item-value"},oe),E.createElement("span",{className:"recharts-tooltip-item-unit"},D.unit||""))});return E.createElement("ul",{className:"recharts-tooltip-item-list",style:L},N)}return null},S=Yl({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},a),_=Yl({margin:0},l),R=!SI(h),C=R?h:"",A=ar("recharts-default-tooltip",b),P=ar("recharts-tooltip-label",g);R&&v&&p!==void 0&&p!==null&&(C=v(h,p));var k=x?{role:"status","aria-live":"assertive"}:{};return E.createElement("div",ju({className:A,style:S},k),E.createElement("p",{className:P,style:_},E.isValidElement(C)?C:"".concat(C)),w())};function no(e){"@babel/helpers - typeof";return no=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},no(e)}function Qo(e,t,r){return t=Ek(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ek(e){var t=Pk(e,"string");return no(t)=="symbol"?t:t+""}function Pk(e,t){if(no(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(no(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var kn="recharts-tooltip-wrapper",Tk={visibility:"hidden"};function Nk(e){var t=e.coordinate,r=e.translateX,n=e.translateY;return ar(kn,Qo(Qo(Qo(Qo({},"".concat(kn,"-right"),jt(r)&&t&&jt(t.x)&&r>=t.x),"".concat(kn,"-left"),jt(r)&&t&&jt(t.x)&&r<t.x),"".concat(kn,"-bottom"),jt(n)&&t&&jt(t.y)&&n>=t.y),"".concat(kn,"-top"),jt(n)&&t&&jt(t.y)&&n<t.y))}function Mv(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.key,o=e.offsetTopLeft,a=e.position,i=e.reverseDirection,s=e.tooltipDimension,c=e.viewBox,l=e.viewBoxDimension;if(a&&jt(a[n]))return a[n];var p=r[n]-s-o,u=r[n]+o;if(t[n])return i[n]?p:u;if(i[n]){var m=p,b=c[n];return m<b?Math.max(u,c[n]):Math.max(p,c[n])}var g=u+s,h=c[n]+l;return g>h?Math.max(p,c[n]):Math.max(u,c[n])}function Ak(e){var t=e.translateX,r=e.translateY,n=e.useTranslate3d;return{transform:n?"translate3d(".concat(t,"px, ").concat(r,"px, 0)"):"translate(".concat(t,"px, ").concat(r,"px)")}}function Mk(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.offsetTopLeft,o=e.position,a=e.reverseDirection,i=e.tooltipBox,s=e.useTranslate3d,c=e.viewBox,l,p,u;return i.height>0&&i.width>0&&r?(p=Mv({allowEscapeViewBox:t,coordinate:r,key:"x",offsetTopLeft:n,position:o,reverseDirection:a,tooltipDimension:i.width,viewBox:c,viewBoxDimension:c.width}),u=Mv({allowEscapeViewBox:t,coordinate:r,key:"y",offsetTopLeft:n,position:o,reverseDirection:a,tooltipDimension:i.height,viewBox:c,viewBoxDimension:c.height}),l=Ak({translateX:p,translateY:u,useTranslate3d:s})):l=Tk,{cssProperties:l,cssClasses:Nk({translateX:p,translateY:u,coordinate:r})}}function un(e){"@babel/helpers - typeof";return un=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},un(e)}function Ov(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function Iv(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ov(Object(r),!0).forEach(function(n){ku(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ov(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Ok(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ik(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,yw(n.key),n)}}function jk(e,t,r){return t&&Ik(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Dk(e,t,r){return t=Ta(t),kk(e,bw()?Reflect.construct(t,r||[],Ta(e).constructor):t.apply(e,r))}function kk(e,t){if(t&&(un(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $k(e)}function $k(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function bw(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(bw=function(){return!!e})()}function Ta(e){return Ta=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ta(e)}function Lk(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&&Du(e,t)}function Du(e,t){return Du=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},Du(e,t)}function ku(e,t,r){return t=yw(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function yw(e){var t=Fk(e,"string");return un(t)=="symbol"?t:t+""}function Fk(e,t){if(un(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(un(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var jv=1,Bk=function(e){function t(){var r;Ok(this,t);for(var n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];return r=Dk(this,t,[].concat(o)),ku(r,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),ku(r,"handleKeyDown",function(i){if(i.key==="Escape"){var s,c,l,p;r.setState({dismissed:!0,dismissedAtCoordinate:{x:(s=(c=r.props.coordinate)===null||c===void 0?void 0:c.x)!==null&&s!==void 0?s:0,y:(l=(p=r.props.coordinate)===null||p===void 0?void 0:p.y)!==null&&l!==void 0?l:0}})}}),r}return Lk(t,e),jk(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();(Math.abs(n.width-this.state.lastBoundingBox.width)>jv||Math.abs(n.height-this.state.lastBoundingBox.height)>jv)&&this.setState({lastBoundingBox:{width:n.width,height:n.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var n,o;this.props.active&&this.updateBBox(),this.state.dismissed&&(((n=this.props.coordinate)===null||n===void 0?void 0:n.x)!==this.state.dismissedAtCoordinate.x||((o=this.props.coordinate)===null||o===void 0?void 0:o.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var n=this,o=this.props,a=o.active,i=o.allowEscapeViewBox,s=o.animationDuration,c=o.animationEasing,l=o.children,p=o.coordinate,u=o.hasPayload,m=o.isAnimationActive,b=o.offset,g=o.position,h=o.reverseDirection,v=o.useTranslate3d,y=o.viewBox,x=o.wrapperStyle,w=Mk({allowEscapeViewBox:i,coordinate:p,offsetTopLeft:b,position:g,reverseDirection:h,tooltipBox:this.state.lastBoundingBox,useTranslate3d:v,viewBox:y}),S=w.cssClasses,_=w.cssProperties,R=Iv(Iv({transition:m&&a?"transform ".concat(s,"ms ").concat(c):void 0},_),{},{pointerEvents:"none",visibility:!this.state.dismissed&&a&&u?"visible":"hidden",position:"absolute",top:0,left:0},x);return E.createElement("div",{tabIndex:-1,className:S,style:R,ref:function(A){n.wrapperNode=A}},l)}}])}(E.PureComponent),zk=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},qk={isSsr:zk()};function dn(e){"@babel/helpers - typeof";return dn=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},dn(e)}function Dv(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function kv(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Dv(Object(r),!0).forEach(function(n){af(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Dv(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Hk(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vk(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,ww(n.key),n)}}function Gk(e,t,r){return t&&Vk(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Uk(e,t,r){return t=Na(t),Wk(e,xw()?Reflect.construct(t,r||[],Na(e).constructor):t.apply(e,r))}function Wk(e,t){if(t&&(dn(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Kk(e)}function Kk(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function xw(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(xw=function(){return!!e})()}function Na(e){return Na=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Na(e)}function Yk(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&&$u(e,t)}function $u(e,t){return $u=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,o){return n.__proto__=o,n},$u(e,t)}function af(e,t,r){return t=ww(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ww(e){var t=Xk(e,"string");return dn(t)=="symbol"?t:t+""}function Xk(e,t){if(dn(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(dn(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}function Zk(e){return e.dataKey}function Jk(e,t){return E.isValidElement(e)?E.cloneElement(e,t):typeof e=="function"?E.createElement(e,t):E.createElement(Rk,t)}var sf=function(e){function t(){return Hk(this,t),Uk(this,t,arguments)}return Yk(t,e),Gk(t,[{key:"render",value:function(){var n=this,o=this.props,a=o.active,i=o.allowEscapeViewBox,s=o.animationDuration,c=o.animationEasing,l=o.content,p=o.coordinate,u=o.filterNull,m=o.isAnimationActive,b=o.offset,g=o.payload,h=o.payloadUniqBy,v=o.position,y=o.reverseDirection,x=o.useTranslate3d,w=o.viewBox,S=o.wrapperStyle,_=g??[];u&&_.length&&(_=hw(g.filter(function(C){return C.value!=null&&(C.hide!==!0||n.props.includeHidden)}),h,Zk));var R=_.length>0;return E.createElement(Bk,{allowEscapeViewBox:i,animationDuration:s,animationEasing:c,isAnimationActive:m,active:a,coordinate:p,hasPayload:R,offset:b,position:v,reverseDirection:y,useTranslate3d:x,viewBox:w,wrapperStyle:S},Jk(l,kv(kv({},this.props),{},{payload:_})))}}])}(E.PureComponent);af(sf,"displayName","Tooltip");af(sf,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!qk.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var Xl,$v;function Qk(){if($v)return Xl;$v=1;var e=Xt(),t=function(){return e.Date.now()};return Xl=t,Xl}var Zl,Lv;function e$(){if(Lv)return Zl;Lv=1;var e=/\s/;function t(r){for(var n=r.length;n--&&e.test(r.charAt(n)););return n}return Zl=t,Zl}var Jl,Fv;function t$(){if(Fv)return Jl;Fv=1;var e=e$(),t=/^\s+/;function r(n){return n&&n.slice(0,e(n)+1).replace(t,"")}return Jl=r,Jl}var Ql,Bv;function r$(){if(Bv)return Ql;Bv=1;var e=t$(),t=wr(),r=Co(),n=NaN,o=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,i=/^0o[0-7]+$/i,s=parseInt;function c(l){if(typeof l=="number")return l;if(r(l))return n;if(t(l)){var p=typeof l.valueOf=="function"?l.valueOf():l;l=t(p)?p+"":p}if(typeof l!="string")return l===0?l:+l;l=e(l);var u=a.test(l);return u||i.test(l)?s(l.slice(2),u?2:8):o.test(l)?n:+l}return Ql=c,Ql}var eu,zv;function n$(){if(zv)return eu;zv=1;var e=wr(),t=Qk(),r=r$(),n="Expected a function",o=Math.max,a=Math.min;function i(s,c,l){var p,u,m,b,g,h,v=0,y=!1,x=!1,w=!0;if(typeof s!="function")throw new TypeError(n);c=r(c)||0,e(l)&&(y=!!l.leading,x="maxWait"in l,m=x?o(r(l.maxWait)||0,c):m,w="trailing"in l?!!l.trailing:w);function S(N){var D=p,$=u;return p=u=void 0,v=N,b=s.apply($,D),b}function _(N){return v=N,g=setTimeout(A,c),y?S(N):b}function R(N){var D=N-h,$=N-v,O=c-D;return x?a(O,m-$):O}function C(N){var D=N-h,$=N-v;return h===void 0||D>=c||D<0||x&&$>=m}function A(){var N=t();if(C(N))return P(N);g=setTimeout(A,R(N))}function P(N){return g=void 0,w&&p?S(N):(p=u=void 0,b)}function k(){g!==void 0&&clearTimeout(g),v=0,p=h=u=g=void 0}function j(){return g===void 0?b:P(t())}function L(){var N=t(),D=C(N);if(p=arguments,u=this,h=N,D){if(g===void 0)return _(h);if(x)return clearTimeout(g),g=setTimeout(A,c),S(h)}return g===void 0&&(g=setTimeout(A,c)),b}return L.cancel=k,L.flush=j,L}return eu=i,eu}var tu,qv;function o$(){if(qv)return tu;qv=1;var e=n$(),t=wr(),r="Expected a function";function n(o,a,i){var s=!0,c=!0;if(typeof o!="function")throw new TypeError(r);return t(i)&&(s="leading"in i?!!i.leading:s,c="trailing"in i?!!i.trailing:c),e(o,a,{leading:s,maxWait:a,trailing:c})}return tu=n,tu}var a$=o$();const i$=Yt(a$);function oo(e){"@babel/helpers - typeof";return oo=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},oo(e)}function Hv(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),r.push.apply(r,n)}return r}function ea(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Hv(Object(r),!0).forEach(function(n){s$(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Hv(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function s$(e,t,r){return t=c$(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function c$(e){var t=l$(e,"string");return oo(t)=="symbol"?t:t+""}function l$(e,t){if(oo(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(oo(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function u$(e,t){return m$(e)||p$(e,t)||f$(e,t)||d$()}function d$(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
201
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function f$(e,t){if(e){if(typeof e=="string")return Vv(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Vv(e,t)}}function Vv(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function p$(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,o,a,i,s=[],c=!0,l=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(c=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(p){l=!0,o=p}finally{try{if(!c&&r.return!=null&&(i=r.return(),Object(i)!==i))return}finally{if(l)throw o}}return s}}function m$(e){if(Array.isArray(e))return e}var h$=E.forwardRef(function(e,t){var r=e.aspect,n=e.initialDimension,o=n===void 0?{width:-1,height:-1}:n,a=e.width,i=a===void 0?"100%":a,s=e.height,c=s===void 0?"100%":s,l=e.minWidth,p=l===void 0?0:l,u=e.minHeight,m=e.maxHeight,b=e.children,g=e.debounce,h=g===void 0?0:g,v=e.id,y=e.className,x=e.onResize,w=e.style,S=w===void 0?{}:w,_=E.useRef(null),R=E.useRef();R.current=x,E.useImperativeHandle(t,function(){return Object.defineProperty(_.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),_.current},configurable:!0})});var C=E.useState({containerWidth:o.width,containerHeight:o.height}),A=u$(C,2),P=A[0],k=A[1],j=E.useCallback(function(N,D){k(function($){var O=Math.round(N),G=Math.round(D);return $.containerWidth===O&&$.containerHeight===G?$:{containerWidth:O,containerHeight:G}})},[]);E.useEffect(function(){var N=function(z){var oe,Z=z[0].contentRect,te=Z.width,F=Z.height;j(te,F),(oe=R.current)===null||oe===void 0||oe.call(R,te,F)};h>0&&(N=i$(N,h,{trailing:!0,leading:!1}));var D=new ResizeObserver(N),$=_.current.getBoundingClientRect(),O=$.width,G=$.height;return j(O,G),D.observe(_.current),function(){D.disconnect()}},[j,h]);var L=E.useMemo(function(){var N=P.containerWidth,D=P.containerHeight;if(N<0||D<0)return null;da(Zo(i)||Zo(c),`The width(%s) and height(%s) are both fixed numbers,
|
|
202
|
+
maybe you don't need to use a ResponsiveContainer.`,i,c),da(!r||r>0,"The aspect(%s) must be greater than zero.",r);var $=Zo(i)?N:i,O=Zo(c)?D:c;r&&r>0&&($?O=$/r:O&&($=O*r),m&&O>m&&(O=m)),da($>0||O>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
|
203
|
+
please check the style of container, or the props width(%s) and height(%s),
|
|
204
|
+
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
|
205
|
+
height and width.`,$,O,i,c,p,u,r);var G=!Array.isArray(b)&&FI(b.type).endsWith("Chart");return E.Children.map(b,function(H){return E.isValidElement(H)?E.cloneElement(H,ea({width:$,height:O},G?{style:ea({height:"100%",width:"100%",maxHeight:O,maxWidth:$},H.props.style)}:{})):H})},[r,b,c,m,u,p,P,i]);return E.createElement("div",{id:v?"".concat(v):void 0,className:ar("recharts-responsive-container",y),style:ea(ea({},S),{},{width:i,height:c,minWidth:p,minHeight:u,maxHeight:m}),ref:_},L)});const g$={light:"",dark:".dark"},Sw=d.createContext(null);function Cw(){const e=d.useContext(Sw);if(!e)throw new Error("useChart must be used within a <ChartContainer />");return e}const cf=d.forwardRef(({id:e,className:t,children:r,config:n,...o},a)=>{const i=d.useId(),s=`chart-${e||i.replace(/:/g,"")}`;return f.jsx(Sw.Provider,{value:{config:n},children:f.jsxs("div",{"data-chart":s,ref:a,className:M("flex aspect-video justify-center text-xs [&_.recharts-cartesian-axis-tick_text]:fill-muted-foreground [&_.recharts-cartesian-grid_line[stroke='#ccc']]:stroke-border/50 [&_.recharts-curve.recharts-tooltip-cursor]:stroke-border [&_.recharts-dot[stroke='#fff']]:stroke-transparent [&_.recharts-layer]:outline-none [&_.recharts-polar-grid_[stroke='#ccc']]:stroke-border [&_.recharts-radial-bar-background-sector]:fill-muted [&_.recharts-rectangle.recharts-tooltip-cursor]:fill-muted [&_.recharts-reference-line_[stroke='#ccc']]:stroke-border [&_.recharts-sector[stroke='#fff']]:stroke-transparent [&_.recharts-sector]:outline-none [&_.recharts-surface]:outline-none",t),...o,children:[f.jsx(_w,{id:s,config:n}),f.jsx(h$,{children:r})]})})});cf.displayName="Chart";const _w=({id:e,config:t})=>{const r=Object.entries(t).filter(([,n])=>n.theme||n.color);return r.length?f.jsx("style",{dangerouslySetInnerHTML:{__html:Object.entries(g$).map(([n,o])=>`
|
|
206
|
+
${o} [data-chart=${e}] {
|
|
207
|
+
${r.map(([a,i])=>{var c;const s=((c=i.theme)==null?void 0:c[n])||i.color;return s?` --color-${a}: ${s};`:null}).join(`
|
|
208
|
+
`)}
|
|
209
|
+
}
|
|
210
|
+
`).join(`
|
|
211
|
+
`)}}):null},v$=sf,Rw=d.forwardRef(({active:e,payload:t,className:r,indicator:n="dot",hideLabel:o=!1,hideIndicator:a=!1,label:i,labelFormatter:s,labelClassName:c,formatter:l,color:p,nameKey:u,labelKey:m},b)=>{const{config:g}=Cw(),h=d.useMemo(()=>{var _;if(o||!(t!=null&&t.length))return null;const[y]=t,x=`${m||(y==null?void 0:y.dataKey)||(y==null?void 0:y.name)||"value"}`,w=Lu(g,y,x),S=!m&&typeof i=="string"?((_=g[i])==null?void 0:_.label)||i:w==null?void 0:w.label;return s?f.jsx("div",{className:M("font-medium",c),children:s(S,t)}):S?f.jsx("div",{className:M("font-medium",c),children:S}):null},[i,s,t,o,c,g,m]);if(!e||!(t!=null&&t.length))return null;const v=t.length===1&&n!=="dot";return f.jsxs("div",{ref:b,className:M("grid min-w-[8rem] items-start gap-1.5 rounded-lg border border-border/50 bg-background px-2.5 py-1.5 text-xs shadow-xl",r),children:[v?null:h,f.jsx("div",{className:"grid gap-1.5",children:t.map((y,x)=>{const w=`${u||y.name||y.dataKey||"value"}`,S=Lu(g,y,w),_=p||y.payload.fill||y.color;return f.jsx("div",{className:M("flex w-full flex-wrap items-stretch gap-2 [&>svg]:h-2.5 [&>svg]:w-2.5 [&>svg]:text-muted-foreground",n==="dot"&&"items-center"),children:l&&(y==null?void 0:y.value)!==void 0&&y.name?l(y.value,y.name,y,x,y.payload):f.jsxs(f.Fragment,{children:[S!=null&&S.icon?f.jsx(S.icon,{}):!a&&f.jsx("div",{className:M("shrink-0 rounded-[2px] border-[--color-border] bg-[--color-bg]",{"h-2.5 w-2.5":n==="dot","w-1":n==="line","w-0 border-[1.5px] border-dashed bg-transparent":n==="dashed","my-0.5":v&&n==="dashed"}),style:{"--color-bg":_,"--color-border":_}}),f.jsxs("div",{className:M("flex flex-1 justify-between leading-none",v?"items-end":"items-center"),children:[f.jsxs("div",{className:"grid gap-1.5",children:[v?h:null,f.jsx("span",{className:"text-muted-foreground",children:(S==null?void 0:S.label)||y.name})]}),y.value&&f.jsx("span",{className:"font-mono font-medium tabular-nums text-foreground",children:y.value.toLocaleString()})]})]})},y.dataKey)})})]})});Rw.displayName="ChartTooltip";const b$=of,Ew=d.forwardRef(({className:e,hideIcon:t=!1,payload:r,verticalAlign:n="bottom",nameKey:o},a)=>{const{config:i}=Cw();return r!=null&&r.length?f.jsx("div",{ref:a,className:M("flex items-center justify-center gap-4",n==="top"?"pb-3":"pt-3",e),children:r.map(s=>{const c=`${o||s.dataKey||"value"}`,l=Lu(i,s,c);return f.jsxs("div",{className:M("flex items-center gap-1.5 [&>svg]:h-3 [&>svg]:w-3 [&>svg]:text-muted-foreground"),children:[l!=null&&l.icon&&!t?f.jsx(l.icon,{}):f.jsx("div",{className:"h-2 w-2 shrink-0 rounded-[2px]",style:{backgroundColor:s.color}}),l==null?void 0:l.label]},s.value)})}):null});Ew.displayName="ChartLegend";function Lu(e,t,r){if(typeof t!="object"||t===null)return;const n="payload"in t&&typeof t.payload=="object"&&t.payload!==null?t.payload:void 0;let o=r;return r in t&&typeof t[r]=="string"?o=t[r]:n&&r in n&&typeof n[r]=="string"&&(o=n[r]),o in e?e[o]:e[r]}function _n(e){const t=d.useRef({value:e,previous:e});return d.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function _o(e){const[t,r]=d.useState(void 0);return He(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let i,s;if("borderBoxSize"in a){const c=a.borderBoxSize,l=Array.isArray(c)?c[0]:c;i=l.inlineSize,s=l.blockSize}else i=e.offsetWidth,s=e.offsetHeight;r({width:i,height:s})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var lf="Checkbox",[y$,e3]=De(lf),[x$,w$]=y$(lf),Pw=d.forwardRef((e,t)=>{const{__scopeCheckbox:r,name:n,checked:o,defaultChecked:a,required:i,disabled:s,value:c="on",onCheckedChange:l,form:p,...u}=e,[m,b]=d.useState(null),g=de(t,S=>b(S)),h=d.useRef(!1),v=m?p||!!m.closest("form"):!0,[y=!1,x]=$e({prop:o,defaultProp:a,onChange:l}),w=d.useRef(y);return d.useEffect(()=>{const S=m==null?void 0:m.form;if(S){const _=()=>x(w.current);return S.addEventListener("reset",_),()=>S.removeEventListener("reset",_)}},[m,x]),f.jsxs(x$,{scope:r,state:y,disabled:s,children:[f.jsx(X.button,{type:"button",role:"checkbox","aria-checked":vr(y)?"mixed":y,"aria-required":i,"data-state":Aw(y),"data-disabled":s?"":void 0,disabled:s,value:c,...u,ref:g,onKeyDown:B(e.onKeyDown,S=>{S.key==="Enter"&&S.preventDefault()}),onClick:B(e.onClick,S=>{x(_=>vr(_)?!0:!_),v&&(h.current=S.isPropagationStopped(),h.current||S.stopPropagation())})}),v&&f.jsx(S$,{control:m,bubbles:!h.current,name:n,value:c,checked:y,required:i,disabled:s,form:p,style:{transform:"translateX(-100%)"},defaultChecked:vr(a)?!1:a})]})});Pw.displayName=lf;var Tw="CheckboxIndicator",Nw=d.forwardRef((e,t)=>{const{__scopeCheckbox:r,forceMount:n,...o}=e,a=w$(Tw,r);return f.jsx(Le,{present:n||vr(a.state)||a.state===!0,children:f.jsx(X.span,{"data-state":Aw(a.state),"data-disabled":a.disabled?"":void 0,...o,ref:t,style:{pointerEvents:"none",...e.style}})})});Nw.displayName=Tw;var S$=e=>{const{control:t,checked:r,bubbles:n=!0,defaultChecked:o,...a}=e,i=d.useRef(null),s=_n(r),c=_o(t);d.useEffect(()=>{const p=i.current,u=window.HTMLInputElement.prototype,b=Object.getOwnPropertyDescriptor(u,"checked").set;if(s!==r&&b){const g=new Event("click",{bubbles:n});p.indeterminate=vr(r),b.call(p,vr(r)?!1:r),p.dispatchEvent(g)}},[s,r,n]);const l=d.useRef(vr(r)?!1:r);return f.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:o??l.current,...a,tabIndex:-1,ref:i,style:{...e.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function vr(e){return e==="indeterminate"}function Aw(e){return vr(e)?"indeterminate":e?"checked":"unchecked"}var Mw=Pw,C$=Nw;const Ow=d.forwardRef(({className:e,...t},r)=>f.jsx(Mw,{ref:r,className:M("peer h-4 w-4 shrink-0 rounded-sm border border-primary shadow focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...t,children:f.jsx(C$,{className:M("flex items-center justify-center text-current"),children:f.jsx(vo,{className:"h-4 w-4"})})}));Ow.displayName=Mw.displayName;const _$=Ib,R$=yd,E$=wd,P$=["top","right","bottom","left"],br=Math.min,wt=Math.max,Aa=Math.round,ta=Math.floor,Wt=e=>({x:e,y:e}),T$={left:"right",right:"left",bottom:"top",top:"bottom"},N$={start:"end",end:"start"};function Fu(e,t,r){return wt(e,br(t,r))}function ir(e,t){return typeof e=="function"?e(t):e}function sr(e){return e.split("-")[0]}function Rn(e){return e.split("-")[1]}function uf(e){return e==="x"?"y":"x"}function df(e){return e==="y"?"height":"width"}function yr(e){return["top","bottom"].includes(sr(e))?"y":"x"}function ff(e){return uf(yr(e))}function A$(e,t,r){r===void 0&&(r=!1);const n=Rn(e),o=ff(e),a=df(o);let i=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=Ma(i)),[i,Ma(i)]}function M$(e){const t=Ma(e);return[Bu(e),t,Bu(t)]}function Bu(e){return e.replace(/start|end/g,t=>N$[t])}function O$(e,t,r){const n=["left","right"],o=["right","left"],a=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return r?t?o:n:t?n:o;case"left":case"right":return t?a:i;default:return[]}}function I$(e,t,r,n){const o=Rn(e);let a=O$(sr(e),r==="start",n);return o&&(a=a.map(i=>i+"-"+o),t&&(a=a.concat(a.map(Bu)))),a}function Ma(e){return e.replace(/left|right|bottom|top/g,t=>T$[t])}function j$(e){return{top:0,right:0,bottom:0,left:0,...e}}function Iw(e){return typeof e!="number"?j$(e):{top:e,right:e,bottom:e,left:e}}function Oa(e){const{x:t,y:r,width:n,height:o}=e;return{width:n,height:o,top:r,left:t,right:t+n,bottom:r+o,x:t,y:r}}function Gv(e,t,r){let{reference:n,floating:o}=e;const a=yr(t),i=ff(t),s=df(i),c=sr(t),l=a==="y",p=n.x+n.width/2-o.width/2,u=n.y+n.height/2-o.height/2,m=n[s]/2-o[s]/2;let b;switch(c){case"top":b={x:p,y:n.y-o.height};break;case"bottom":b={x:p,y:n.y+n.height};break;case"right":b={x:n.x+n.width,y:u};break;case"left":b={x:n.x-o.width,y:u};break;default:b={x:n.x,y:n.y}}switch(Rn(t)){case"start":b[i]-=m*(r&&l?-1:1);break;case"end":b[i]+=m*(r&&l?-1:1);break}return b}const D$=async(e,t,r)=>{const{placement:n="bottom",strategy:o="absolute",middleware:a=[],platform:i}=r,s=a.filter(Boolean),c=await(i.isRTL==null?void 0:i.isRTL(t));let l=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:p,y:u}=Gv(l,n,c),m=n,b={},g=0;for(let h=0;h<s.length;h++){const{name:v,fn:y}=s[h],{x,y:w,data:S,reset:_}=await y({x:p,y:u,initialPlacement:n,placement:m,strategy:o,middlewareData:b,rects:l,platform:i,elements:{reference:e,floating:t}});p=x??p,u=w??u,b={...b,[v]:{...b[v],...S}},_&&g<=50&&(g++,typeof _=="object"&&(_.placement&&(m=_.placement),_.rects&&(l=_.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):_.rects),{x:p,y:u}=Gv(l,m,c)),h=-1)}return{x:p,y:u,placement:m,strategy:o,middlewareData:b}};async function ao(e,t){var r;t===void 0&&(t={});const{x:n,y:o,platform:a,rects:i,elements:s,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:p="viewport",elementContext:u="floating",altBoundary:m=!1,padding:b=0}=ir(t,e),g=Iw(b),v=s[m?u==="floating"?"reference":"floating":u],y=Oa(await a.getClippingRect({element:(r=await(a.isElement==null?void 0:a.isElement(v)))==null||r?v:v.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:p,strategy:c})),x=u==="floating"?{x:n,y:o,width:i.floating.width,height:i.floating.height}:i.reference,w=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),S=await(a.isElement==null?void 0:a.isElement(w))?await(a.getScale==null?void 0:a.getScale(w))||{x:1,y:1}:{x:1,y:1},_=Oa(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:x,offsetParent:w,strategy:c}):x);return{top:(y.top-_.top+g.top)/S.y,bottom:(_.bottom-y.bottom+g.bottom)/S.y,left:(y.left-_.left+g.left)/S.x,right:(_.right-y.right+g.right)/S.x}}const k$=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:o,rects:a,platform:i,elements:s,middlewareData:c}=t,{element:l,padding:p=0}=ir(e,t)||{};if(l==null)return{};const u=Iw(p),m={x:r,y:n},b=ff(o),g=df(b),h=await i.getDimensions(l),v=b==="y",y=v?"top":"left",x=v?"bottom":"right",w=v?"clientHeight":"clientWidth",S=a.reference[g]+a.reference[b]-m[b]-a.floating[g],_=m[b]-a.reference[b],R=await(i.getOffsetParent==null?void 0:i.getOffsetParent(l));let C=R?R[w]:0;(!C||!await(i.isElement==null?void 0:i.isElement(R)))&&(C=s.floating[w]||a.floating[g]);const A=S/2-_/2,P=C/2-h[g]/2-1,k=br(u[y],P),j=br(u[x],P),L=k,N=C-h[g]-j,D=C/2-h[g]/2+A,$=Fu(L,D,N),O=!c.arrow&&Rn(o)!=null&&D!==$&&a.reference[g]/2-(D<L?k:j)-h[g]/2<0,G=O?D<L?D-L:D-N:0;return{[b]:m[b]+G,data:{[b]:$,centerOffset:D-$-G,...O&&{alignmentOffset:G}},reset:O}}}),$$=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:o,middlewareData:a,rects:i,initialPlacement:s,platform:c,elements:l}=t,{mainAxis:p=!0,crossAxis:u=!0,fallbackPlacements:m,fallbackStrategy:b="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:h=!0,...v}=ir(e,t);if((r=a.arrow)!=null&&r.alignmentOffset)return{};const y=sr(o),x=yr(s),w=sr(s)===s,S=await(c.isRTL==null?void 0:c.isRTL(l.floating)),_=m||(w||!h?[Ma(s)]:M$(s)),R=g!=="none";!m&&R&&_.push(...I$(s,h,g,S));const C=[s,..._],A=await ao(t,v),P=[];let k=((n=a.flip)==null?void 0:n.overflows)||[];if(p&&P.push(A[y]),u){const D=A$(o,i,S);P.push(A[D[0]],A[D[1]])}if(k=[...k,{placement:o,overflows:P}],!P.every(D=>D<=0)){var j,L;const D=(((j=a.flip)==null?void 0:j.index)||0)+1,$=C[D];if($)return{data:{index:D,overflows:k},reset:{placement:$}};let O=(L=k.filter(G=>G.overflows[0]<=0).sort((G,H)=>G.overflows[1]-H.overflows[1])[0])==null?void 0:L.placement;if(!O)switch(b){case"bestFit":{var N;const G=(N=k.filter(H=>{if(R){const z=yr(H.placement);return z===x||z==="y"}return!0}).map(H=>[H.placement,H.overflows.filter(z=>z>0).reduce((z,oe)=>z+oe,0)]).sort((H,z)=>H[1]-z[1])[0])==null?void 0:N[0];G&&(O=G);break}case"initialPlacement":O=s;break}if(o!==O)return{reset:{placement:O}}}return{}}}};function Uv(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Wv(e){return P$.some(t=>e[t]>=0)}const L$=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:n="referenceHidden",...o}=ir(e,t);switch(n){case"referenceHidden":{const a=await ao(t,{...o,elementContext:"reference"}),i=Uv(a,r.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:Wv(i)}}}case"escaped":{const a=await ao(t,{...o,altBoundary:!0}),i=Uv(a,r.floating);return{data:{escapedOffsets:i,escaped:Wv(i)}}}default:return{}}}}};async function F$(e,t){const{placement:r,platform:n,elements:o}=e,a=await(n.isRTL==null?void 0:n.isRTL(o.floating)),i=sr(r),s=Rn(r),c=yr(r)==="y",l=["left","top"].includes(i)?-1:1,p=a&&c?-1:1,u=ir(t,e);let{mainAxis:m,crossAxis:b,alignmentAxis:g}=typeof u=="number"?{mainAxis:u,crossAxis:0,alignmentAxis:null}:{mainAxis:u.mainAxis||0,crossAxis:u.crossAxis||0,alignmentAxis:u.alignmentAxis};return s&&typeof g=="number"&&(b=s==="end"?g*-1:g),c?{x:b*p,y:m*l}:{x:m*l,y:b*p}}const B$=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:o,y:a,placement:i,middlewareData:s}=t,c=await F$(t,e);return i===((r=s.offset)==null?void 0:r.placement)&&(n=s.arrow)!=null&&n.alignmentOffset?{}:{x:o+c.x,y:a+c.y,data:{...c,placement:i}}}}},z$=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:v=>{let{x:y,y:x}=v;return{x:y,y:x}}},...c}=ir(e,t),l={x:r,y:n},p=await ao(t,c),u=yr(sr(o)),m=uf(u);let b=l[m],g=l[u];if(a){const v=m==="y"?"top":"left",y=m==="y"?"bottom":"right",x=b+p[v],w=b-p[y];b=Fu(x,b,w)}if(i){const v=u==="y"?"top":"left",y=u==="y"?"bottom":"right",x=g+p[v],w=g-p[y];g=Fu(x,g,w)}const h=s.fn({...t,[m]:b,[u]:g});return{...h,data:{x:h.x-r,y:h.y-n,enabled:{[m]:a,[u]:i}}}}}},q$=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:o,rects:a,middlewareData:i}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=ir(e,t),p={x:r,y:n},u=yr(o),m=uf(u);let b=p[m],g=p[u];const h=ir(s,t),v=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){const w=m==="y"?"height":"width",S=a.reference[m]-a.floating[w]+v.mainAxis,_=a.reference[m]+a.reference[w]-v.mainAxis;b<S?b=S:b>_&&(b=_)}if(l){var y,x;const w=m==="y"?"width":"height",S=["top","left"].includes(sr(o)),_=a.reference[u]-a.floating[w]+(S&&((y=i.offset)==null?void 0:y[u])||0)+(S?0:v.crossAxis),R=a.reference[u]+a.reference[w]+(S?0:((x=i.offset)==null?void 0:x[u])||0)-(S?v.crossAxis:0);g<_?g=_:g>R&&(g=R)}return{[m]:b,[u]:g}}}},H$=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:o,rects:a,platform:i,elements:s}=t,{apply:c=()=>{},...l}=ir(e,t),p=await ao(t,l),u=sr(o),m=Rn(o),b=yr(o)==="y",{width:g,height:h}=a.floating;let v,y;u==="top"||u==="bottom"?(v=u,y=m===(await(i.isRTL==null?void 0:i.isRTL(s.floating))?"start":"end")?"left":"right"):(y=u,v=m==="end"?"top":"bottom");const x=h-p.top-p.bottom,w=g-p.left-p.right,S=br(h-p[v],x),_=br(g-p[y],w),R=!t.middlewareData.shift;let C=S,A=_;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(A=w),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(C=x),R&&!m){const k=wt(p.left,0),j=wt(p.right,0),L=wt(p.top,0),N=wt(p.bottom,0);b?A=g-2*(k!==0||j!==0?k+j:wt(p.left,p.right)):C=h-2*(L!==0||N!==0?L+N:wt(p.top,p.bottom))}await c({...t,availableWidth:A,availableHeight:C});const P=await i.getDimensions(s.floating);return g!==P.width||h!==P.height?{reset:{rects:!0}}:{}}}};function xi(){return typeof window<"u"}function En(e){return jw(e)?(e.nodeName||"").toLowerCase():"#document"}function St(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Zt(e){var t;return(t=(jw(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function jw(e){return xi()?e instanceof Node||e instanceof St(e).Node:!1}function $t(e){return xi()?e instanceof Element||e instanceof St(e).Element:!1}function Kt(e){return xi()?e instanceof HTMLElement||e instanceof St(e).HTMLElement:!1}function Kv(e){return!xi()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof St(e).ShadowRoot}function Ro(e){const{overflow:t,overflowX:r,overflowY:n,display:o}=Lt(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!["inline","contents"].includes(o)}function V$(e){return["table","td","th"].includes(En(e))}function wi(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function pf(e){const t=mf(),r=$t(e)?Lt(e):e;return["transform","translate","scale","rotate","perspective"].some(n=>r[n]?r[n]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(n=>(r.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(r.contain||"").includes(n))}function G$(e){let t=xr(e);for(;Kt(t)&&!fn(t);){if(pf(t))return t;if(wi(t))return null;t=xr(t)}return null}function mf(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function fn(e){return["html","body","#document"].includes(En(e))}function Lt(e){return St(e).getComputedStyle(e)}function Si(e){return $t(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function xr(e){if(En(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Kv(e)&&e.host||Zt(e);return Kv(t)?t.host:t}function Dw(e){const t=xr(e);return fn(t)?e.ownerDocument?e.ownerDocument.body:e.body:Kt(t)&&Ro(t)?t:Dw(t)}function io(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const o=Dw(e),a=o===((n=e.ownerDocument)==null?void 0:n.body),i=St(o);if(a){const s=zu(i);return t.concat(i,i.visualViewport||[],Ro(o)?o:[],s&&r?io(s):[])}return t.concat(o,io(o,[],r))}function zu(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function kw(e){const t=Lt(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=Kt(e),a=o?e.offsetWidth:r,i=o?e.offsetHeight:n,s=Aa(r)!==a||Aa(n)!==i;return s&&(r=a,n=i),{width:r,height:n,$:s}}function hf(e){return $t(e)?e:e.contextElement}function on(e){const t=hf(e);if(!Kt(t))return Wt(1);const r=t.getBoundingClientRect(),{width:n,height:o,$:a}=kw(t);let i=(a?Aa(r.width):r.width)/n,s=(a?Aa(r.height):r.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!s||!Number.isFinite(s))&&(s=1),{x:i,y:s}}const U$=Wt(0);function $w(e){const t=St(e);return!mf()||!t.visualViewport?U$:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function W$(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==St(e)?!1:t}function Lr(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const o=e.getBoundingClientRect(),a=hf(e);let i=Wt(1);t&&(n?$t(n)&&(i=on(n)):i=on(e));const s=W$(a,r,n)?$w(a):Wt(0);let c=(o.left+s.x)/i.x,l=(o.top+s.y)/i.y,p=o.width/i.x,u=o.height/i.y;if(a){const m=St(a),b=n&&$t(n)?St(n):n;let g=m,h=zu(g);for(;h&&n&&b!==g;){const v=on(h),y=h.getBoundingClientRect(),x=Lt(h),w=y.left+(h.clientLeft+parseFloat(x.paddingLeft))*v.x,S=y.top+(h.clientTop+parseFloat(x.paddingTop))*v.y;c*=v.x,l*=v.y,p*=v.x,u*=v.y,c+=w,l+=S,g=St(h),h=zu(g)}}return Oa({width:p,height:u,x:c,y:l})}function gf(e,t){const r=Si(e).scrollLeft;return t?t.left+r:Lr(Zt(e)).left+r}function Lw(e,t,r){r===void 0&&(r=!1);const n=e.getBoundingClientRect(),o=n.left+t.scrollLeft-(r?0:gf(e,n)),a=n.top+t.scrollTop;return{x:o,y:a}}function K$(e){let{elements:t,rect:r,offsetParent:n,strategy:o}=e;const a=o==="fixed",i=Zt(n),s=t?wi(t.floating):!1;if(n===i||s&&a)return r;let c={scrollLeft:0,scrollTop:0},l=Wt(1);const p=Wt(0),u=Kt(n);if((u||!u&&!a)&&((En(n)!=="body"||Ro(i))&&(c=Si(n)),Kt(n))){const b=Lr(n);l=on(n),p.x=b.x+n.clientLeft,p.y=b.y+n.clientTop}const m=i&&!u&&!a?Lw(i,c,!0):Wt(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-c.scrollLeft*l.x+p.x+m.x,y:r.y*l.y-c.scrollTop*l.y+p.y+m.y}}function Y$(e){return Array.from(e.getClientRects())}function X$(e){const t=Zt(e),r=Si(e),n=e.ownerDocument.body,o=wt(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),a=wt(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let i=-r.scrollLeft+gf(e);const s=-r.scrollTop;return Lt(n).direction==="rtl"&&(i+=wt(t.clientWidth,n.clientWidth)-o),{width:o,height:a,x:i,y:s}}function Z$(e,t){const r=St(e),n=Zt(e),o=r.visualViewport;let a=n.clientWidth,i=n.clientHeight,s=0,c=0;if(o){a=o.width,i=o.height;const l=mf();(!l||l&&t==="fixed")&&(s=o.offsetLeft,c=o.offsetTop)}return{width:a,height:i,x:s,y:c}}function J$(e,t){const r=Lr(e,!0,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft,a=Kt(e)?on(e):Wt(1),i=e.clientWidth*a.x,s=e.clientHeight*a.y,c=o*a.x,l=n*a.y;return{width:i,height:s,x:c,y:l}}function Yv(e,t,r){let n;if(t==="viewport")n=Z$(e,r);else if(t==="document")n=X$(Zt(e));else if($t(t))n=J$(t,r);else{const o=$w(e);n={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Oa(n)}function Fw(e,t){const r=xr(e);return r===t||!$t(r)||fn(r)?!1:Lt(r).position==="fixed"||Fw(r,t)}function Q$(e,t){const r=t.get(e);if(r)return r;let n=io(e,[],!1).filter(s=>$t(s)&&En(s)!=="body"),o=null;const a=Lt(e).position==="fixed";let i=a?xr(e):e;for(;$t(i)&&!fn(i);){const s=Lt(i),c=pf(i);!c&&s.position==="fixed"&&(o=null),(a?!c&&!o:!c&&s.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Ro(i)&&!c&&Fw(e,i))?n=n.filter(p=>p!==i):o=s,i=xr(i)}return t.set(e,n),n}function eL(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e;const i=[...r==="clippingAncestors"?wi(t)?[]:Q$(t,this._c):[].concat(r),n],s=i[0],c=i.reduce((l,p)=>{const u=Yv(t,p,o);return l.top=wt(u.top,l.top),l.right=br(u.right,l.right),l.bottom=br(u.bottom,l.bottom),l.left=wt(u.left,l.left),l},Yv(t,s,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function tL(e){const{width:t,height:r}=kw(e);return{width:t,height:r}}function rL(e,t,r){const n=Kt(t),o=Zt(t),a=r==="fixed",i=Lr(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const c=Wt(0);if(n||!n&&!a)if((En(t)!=="body"||Ro(o))&&(s=Si(t)),n){const m=Lr(t,!0,a,t);c.x=m.x+t.clientLeft,c.y=m.y+t.clientTop}else o&&(c.x=gf(o));const l=o&&!n&&!a?Lw(o,s):Wt(0),p=i.left+s.scrollLeft-c.x-l.x,u=i.top+s.scrollTop-c.y-l.y;return{x:p,y:u,width:i.width,height:i.height}}function ru(e){return Lt(e).position==="static"}function Xv(e,t){if(!Kt(e)||Lt(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Zt(e)===r&&(r=r.ownerDocument.body),r}function Bw(e,t){const r=St(e);if(wi(e))return r;if(!Kt(e)){let o=xr(e);for(;o&&!fn(o);){if($t(o)&&!ru(o))return o;o=xr(o)}return r}let n=Xv(e,t);for(;n&&V$(n)&&ru(n);)n=Xv(n,t);return n&&fn(n)&&ru(n)&&!pf(n)?r:n||G$(e)||r}const nL=async function(e){const t=this.getOffsetParent||Bw,r=this.getDimensions,n=await r(e.floating);return{reference:rL(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function oL(e){return Lt(e).direction==="rtl"}const aL={convertOffsetParentRelativeRectToViewportRelativeRect:K$,getDocumentElement:Zt,getClippingRect:eL,getOffsetParent:Bw,getElementRects:nL,getClientRects:Y$,getDimensions:tL,getScale:on,isElement:$t,isRTL:oL};function zw(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function iL(e,t){let r=null,n;const o=Zt(e);function a(){var s;clearTimeout(n),(s=r)==null||s.disconnect(),r=null}function i(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();const l=e.getBoundingClientRect(),{left:p,top:u,width:m,height:b}=l;if(s||t(),!m||!b)return;const g=ta(u),h=ta(o.clientWidth-(p+m)),v=ta(o.clientHeight-(u+b)),y=ta(p),w={rootMargin:-g+"px "+-h+"px "+-v+"px "+-y+"px",threshold:wt(0,br(1,c))||1};let S=!0;function _(R){const C=R[0].intersectionRatio;if(C!==c){if(!S)return i();C?i(!1,C):n=setTimeout(()=>{i(!1,1e-7)},1e3)}C===1&&!zw(l,e.getBoundingClientRect())&&i(),S=!1}try{r=new IntersectionObserver(_,{...w,root:o.ownerDocument})}catch{r=new IntersectionObserver(_,w)}r.observe(e)}return i(!0),a}function sL(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:c=!1}=n,l=hf(e),p=o||a?[...l?io(l):[],...io(t)]:[];p.forEach(y=>{o&&y.addEventListener("scroll",r,{passive:!0}),a&&y.addEventListener("resize",r)});const u=l&&s?iL(l,r):null;let m=-1,b=null;i&&(b=new ResizeObserver(y=>{let[x]=y;x&&x.target===l&&b&&(b.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var w;(w=b)==null||w.observe(t)})),r()}),l&&!c&&b.observe(l),b.observe(t));let g,h=c?Lr(e):null;c&&v();function v(){const y=Lr(e);h&&!zw(h,y)&&r(),h=y,g=requestAnimationFrame(v)}return r(),()=>{var y;p.forEach(x=>{o&&x.removeEventListener("scroll",r),a&&x.removeEventListener("resize",r)}),u==null||u(),(y=b)==null||y.disconnect(),b=null,c&&cancelAnimationFrame(g)}}const cL=B$,lL=z$,uL=$$,dL=H$,fL=L$,Zv=k$,pL=q$,mL=(e,t,r)=>{const n=new Map,o={platform:aL,...r},a={...o.platform,_c:n};return D$(e,t,{...o,platform:a})};var fa=typeof document<"u"?E.useLayoutEffect:E.useEffect;function Ia(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 r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!Ia(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){const a=o[n];if(!(a==="_owner"&&e.$$typeof)&&!Ia(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function qw(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Jv(e,t){const r=qw(e);return Math.round(t*r)/r}function nu(e){const t=d.useRef(e);return fa(()=>{t.current=e}),t}function hL(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:o,elements:{reference:a,floating:i}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[p,u]=d.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[m,b]=d.useState(n);Ia(m,n)||b(n);const[g,h]=d.useState(null),[v,y]=d.useState(null),x=d.useCallback(H=>{H!==R.current&&(R.current=H,h(H))},[]),w=d.useCallback(H=>{H!==C.current&&(C.current=H,y(H))},[]),S=a||g,_=i||v,R=d.useRef(null),C=d.useRef(null),A=d.useRef(p),P=c!=null,k=nu(c),j=nu(o),L=nu(l),N=d.useCallback(()=>{if(!R.current||!C.current)return;const H={placement:t,strategy:r,middleware:m};j.current&&(H.platform=j.current),mL(R.current,C.current,H).then(z=>{const oe={...z,isPositioned:L.current!==!1};D.current&&!Ia(A.current,oe)&&(A.current=oe,ho.flushSync(()=>{u(oe)}))})},[m,t,r,j,L]);fa(()=>{l===!1&&A.current.isPositioned&&(A.current.isPositioned=!1,u(H=>({...H,isPositioned:!1})))},[l]);const D=d.useRef(!1);fa(()=>(D.current=!0,()=>{D.current=!1}),[]),fa(()=>{if(S&&(R.current=S),_&&(C.current=_),S&&_){if(k.current)return k.current(S,_,N);N()}},[S,_,N,k,P]);const $=d.useMemo(()=>({reference:R,floating:C,setReference:x,setFloating:w}),[x,w]),O=d.useMemo(()=>({reference:S,floating:_}),[S,_]),G=d.useMemo(()=>{const H={position:r,left:0,top:0};if(!O.floating)return H;const z=Jv(O.floating,p.x),oe=Jv(O.floating,p.y);return s?{...H,transform:"translate("+z+"px, "+oe+"px)",...qw(O.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:z,top:oe}},[r,s,O.floating,p.x,p.y]);return d.useMemo(()=>({...p,update:N,refs:$,elements:O,floatingStyles:G}),[p,N,$,O,G])}const gL=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:o}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Zv({element:n.current,padding:o}).fn(r):{}:n?Zv({element:n,padding:o}).fn(r):{}}}},vL=(e,t)=>({...cL(e),options:[e,t]}),bL=(e,t)=>({...lL(e),options:[e,t]}),yL=(e,t)=>({...pL(e),options:[e,t]}),xL=(e,t)=>({...uL(e),options:[e,t]}),wL=(e,t)=>({...dL(e),options:[e,t]}),SL=(e,t)=>({...fL(e),options:[e,t]}),CL=(e,t)=>({...gL(e),options:[e,t]});var _L="Arrow",Hw=d.forwardRef((e,t)=>{const{children:r,width:n=10,height:o=5,...a}=e;return f.jsx(X.svg,{...a,ref:t,width:n,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:f.jsx("polygon",{points:"0,0 30,0 15,10"})})});Hw.displayName=_L;var RL=Hw,vf="Popper",[Vw,Jt]=De(vf),[EL,Gw]=Vw(vf),Uw=e=>{const{__scopePopper:t,children:r}=e,[n,o]=d.useState(null);return f.jsx(EL,{scope:t,anchor:n,onAnchorChange:o,children:r})};Uw.displayName=vf;var Ww="PopperAnchor",Kw=d.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...o}=e,a=Gw(Ww,r),i=d.useRef(null),s=de(t,i);return d.useEffect(()=>{a.onAnchorChange((n==null?void 0:n.current)||i.current)}),n?null:f.jsx(X.div,{...o,ref:s})});Kw.displayName=Ww;var bf="PopperContent",[PL,TL]=Vw(bf),Yw=d.forwardRef((e,t)=>{var q,W,re,J,ne,V;const{__scopePopper:r,side:n="bottom",sideOffset:o=0,align:a="center",alignOffset:i=0,arrowPadding:s=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:p=0,sticky:u="partial",hideWhenDetached:m=!1,updatePositionStrategy:b="optimized",onPlaced:g,...h}=e,v=Gw(bf,r),[y,x]=d.useState(null),w=de(t,ae=>x(ae)),[S,_]=d.useState(null),R=_o(S),C=(R==null?void 0:R.width)??0,A=(R==null?void 0:R.height)??0,P=n+(a!=="center"?"-"+a:""),k=typeof p=="number"?p:{top:0,right:0,bottom:0,left:0,...p},j=Array.isArray(l)?l:[l],L=j.length>0,N={padding:k,boundary:j.filter(AL),altBoundary:L},{refs:D,floatingStyles:$,placement:O,isPositioned:G,middlewareData:H}=hL({strategy:"fixed",placement:P,whileElementsMounted:(...ae)=>sL(...ae,{animationFrame:b==="always"}),elements:{reference:v.anchor},middleware:[vL({mainAxis:o+A,alignmentAxis:i}),c&&bL({mainAxis:!0,crossAxis:!1,limiter:u==="partial"?yL():void 0,...N}),c&&xL({...N}),wL({...N,apply:({elements:ae,rects:I,availableWidth:ee,availableHeight:pe})=>{const{width:me,height:ge}=I.reference,fe=ae.floating.style;fe.setProperty("--radix-popper-available-width",`${ee}px`),fe.setProperty("--radix-popper-available-height",`${pe}px`),fe.setProperty("--radix-popper-anchor-width",`${me}px`),fe.setProperty("--radix-popper-anchor-height",`${ge}px`)}}),S&&CL({element:S,padding:s}),ML({arrowWidth:C,arrowHeight:A}),m&&SL({strategy:"referenceHidden",...N})]}),[z,oe]=Jw(O),Z=Te(g);He(()=>{G&&(Z==null||Z())},[G,Z]);const te=(q=H.arrow)==null?void 0:q.x,F=(W=H.arrow)==null?void 0:W.y,U=((re=H.arrow)==null?void 0:re.centerOffset)!==0,[Q,K]=d.useState();return He(()=>{y&&K(window.getComputedStyle(y).zIndex)},[y]),f.jsx("div",{ref:D.setFloating,"data-radix-popper-content-wrapper":"",style:{...$,transform:G?$.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Q,"--radix-popper-transform-origin":[(J=H.transformOrigin)==null?void 0:J.x,(ne=H.transformOrigin)==null?void 0:ne.y].join(" "),...((V=H.hide)==null?void 0:V.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:f.jsx(PL,{scope:r,placedSide:z,onArrowChange:_,arrowX:te,arrowY:F,shouldHideArrow:U,children:f.jsx(X.div,{"data-side":z,"data-align":oe,...h,ref:w,style:{...h.style,animation:G?void 0:"none"}})})})});Yw.displayName=bf;var Xw="PopperArrow",NL={top:"bottom",right:"left",bottom:"top",left:"right"},Zw=d.forwardRef(function(t,r){const{__scopePopper:n,...o}=t,a=TL(Xw,n),i=NL[a.placedSide];return f.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:f.jsx(RL,{...o,ref:r,style:{...o.style,display:"block"}})})});Zw.displayName=Xw;function AL(e){return e!==null}var ML=e=>({name:"transformOrigin",options:e,fn(t){var v,y,x;const{placement:r,rects:n,middlewareData:o}=t,i=((v=o.arrow)==null?void 0:v.centerOffset)!==0,s=i?0:e.arrowWidth,c=i?0:e.arrowHeight,[l,p]=Jw(r),u={start:"0%",center:"50%",end:"100%"}[p],m=(((y=o.arrow)==null?void 0:y.x)??0)+s/2,b=(((x=o.arrow)==null?void 0:x.y)??0)+c/2;let g="",h="";return l==="bottom"?(g=i?u:`${m}px`,h=`${-c}px`):l==="top"?(g=i?u:`${m}px`,h=`${n.floating.height+c}px`):l==="right"?(g=`${-c}px`,h=i?u:`${b}px`):l==="left"&&(g=`${n.floating.width+c}px`,h=i?u:`${b}px`),{data:{x:g,y:h}}}});function Jw(e){const[t,r="center"]=e.split("-");return[t,r]}var Pn=Uw,Tn=Kw,Eo=Yw,Po=Zw,ou="rovingFocusGroup.onEntryFocus",OL={bubbles:!1,cancelable:!0},Ci="RovingFocusGroup",[qu,Qw,IL]=cr(Ci),[jL,Qt]=De(Ci,[IL]),[DL,kL]=jL(Ci),e0=d.forwardRef((e,t)=>f.jsx(qu.Provider,{scope:e.__scopeRovingFocusGroup,children:f.jsx(qu.Slot,{scope:e.__scopeRovingFocusGroup,children:f.jsx($L,{...e,ref:t})})}));e0.displayName=Ci;var $L=d.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:r,orientation:n,loop:o=!1,dir:a,currentTabStopId:i,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:c,onEntryFocus:l,preventScrollOnEntryFocus:p=!1,...u}=e,m=d.useRef(null),b=de(t,m),g=Ft(a),[h=null,v]=$e({prop:i,defaultProp:s,onChange:c}),[y,x]=d.useState(!1),w=Te(l),S=Qw(r),_=d.useRef(!1),[R,C]=d.useState(0);return d.useEffect(()=>{const A=m.current;if(A)return A.addEventListener(ou,w),()=>A.removeEventListener(ou,w)},[w]),f.jsx(DL,{scope:r,orientation:n,dir:g,loop:o,currentTabStopId:h,onItemFocus:d.useCallback(A=>v(A),[v]),onItemShiftTab:d.useCallback(()=>x(!0),[]),onFocusableItemAdd:d.useCallback(()=>C(A=>A+1),[]),onFocusableItemRemove:d.useCallback(()=>C(A=>A-1),[]),children:f.jsx(X.div,{tabIndex:y||R===0?-1:0,"data-orientation":n,...u,ref:b,style:{outline:"none",...e.style},onMouseDown:B(e.onMouseDown,()=>{_.current=!0}),onFocus:B(e.onFocus,A=>{const P=!_.current;if(A.target===A.currentTarget&&P&&!y){const k=new CustomEvent(ou,OL);if(A.currentTarget.dispatchEvent(k),!k.defaultPrevented){const j=S().filter(O=>O.focusable),L=j.find(O=>O.active),N=j.find(O=>O.id===h),$=[L,N,...j].filter(Boolean).map(O=>O.ref.current);n0($,p)}}_.current=!1}),onBlur:B(e.onBlur,()=>x(!1))})})}),t0="RovingFocusGroupItem",r0=d.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:r,focusable:n=!0,active:o=!1,tabStopId:a,...i}=e,s=Ue(),c=a||s,l=kL(t0,r),p=l.currentTabStopId===c,u=Qw(r),{onFocusableItemAdd:m,onFocusableItemRemove:b}=l;return d.useEffect(()=>{if(n)return m(),()=>b()},[n,m,b]),f.jsx(qu.ItemSlot,{scope:r,id:c,focusable:n,active:o,children:f.jsx(X.span,{tabIndex:p?0:-1,"data-orientation":l.orientation,...i,ref:t,onMouseDown:B(e.onMouseDown,g=>{n?l.onItemFocus(c):g.preventDefault()}),onFocus:B(e.onFocus,()=>l.onItemFocus(c)),onKeyDown:B(e.onKeyDown,g=>{if(g.key==="Tab"&&g.shiftKey){l.onItemShiftTab();return}if(g.target!==g.currentTarget)return;const h=BL(g,l.orientation,l.dir);if(h!==void 0){if(g.metaKey||g.ctrlKey||g.altKey||g.shiftKey)return;g.preventDefault();let y=u().filter(x=>x.focusable).map(x=>x.ref.current);if(h==="last")y.reverse();else if(h==="prev"||h==="next"){h==="prev"&&y.reverse();const x=y.indexOf(g.currentTarget);y=l.loop?zL(y,x+1):y.slice(x+1)}setTimeout(()=>n0(y))}})})})});r0.displayName=t0;var LL={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function FL(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function BL(e,t,r){const n=FL(e.key,r);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(n))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(n)))return LL[n]}function n0(e,t=!1){const r=document.activeElement;for(const n of e)if(n===r||(n.focus({preventScroll:t}),document.activeElement!==r))return}function zL(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var To=e0,No=r0,Hu=["Enter"," "],qL=["ArrowDown","PageUp","Home"],o0=["ArrowUp","PageDown","End"],HL=[...qL,...o0],VL={ltr:[...Hu,"ArrowRight"],rtl:[...Hu,"ArrowLeft"]},GL={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Ao="Menu",[so,UL,WL]=cr(Ao),[Ur,Mo]=De(Ao,[WL,Jt,Qt]),Oo=Jt(),a0=Qt(),[i0,Sr]=Ur(Ao),[KL,Io]=Ur(Ao),s0=e=>{const{__scopeMenu:t,open:r=!1,children:n,dir:o,onOpenChange:a,modal:i=!0}=e,s=Oo(t),[c,l]=d.useState(null),p=d.useRef(!1),u=Te(a),m=Ft(o);return d.useEffect(()=>{const b=()=>{p.current=!0,document.addEventListener("pointerdown",g,{capture:!0,once:!0}),document.addEventListener("pointermove",g,{capture:!0,once:!0})},g=()=>p.current=!1;return document.addEventListener("keydown",b,{capture:!0}),()=>{document.removeEventListener("keydown",b,{capture:!0}),document.removeEventListener("pointerdown",g,{capture:!0}),document.removeEventListener("pointermove",g,{capture:!0})}},[]),f.jsx(Pn,{...s,children:f.jsx(i0,{scope:t,open:r,onOpenChange:u,content:c,onContentChange:l,children:f.jsx(KL,{scope:t,onClose:d.useCallback(()=>u(!1),[u]),isUsingKeyboardRef:p,dir:m,modal:i,children:n})})})};s0.displayName=Ao;var YL="MenuAnchor",yf=d.forwardRef((e,t)=>{const{__scopeMenu:r,...n}=e,o=Oo(r);return f.jsx(Tn,{...o,...n,ref:t})});yf.displayName=YL;var xf="MenuPortal",[XL,c0]=Ur(xf,{forceMount:void 0}),l0=e=>{const{__scopeMenu:t,forceMount:r,children:n,container:o}=e,a=Sr(xf,t);return f.jsx(XL,{scope:t,forceMount:r,children:f.jsx(Le,{present:r||a.open,children:f.jsx(zr,{asChild:!0,container:o,children:n})})})};l0.displayName=xf;var Pt="MenuContent",[ZL,wf]=Ur(Pt),u0=d.forwardRef((e,t)=>{const r=c0(Pt,e.__scopeMenu),{forceMount:n=r.forceMount,...o}=e,a=Sr(Pt,e.__scopeMenu),i=Io(Pt,e.__scopeMenu);return f.jsx(so.Provider,{scope:e.__scopeMenu,children:f.jsx(Le,{present:n||a.open,children:f.jsx(so.Slot,{scope:e.__scopeMenu,children:i.modal?f.jsx(JL,{...o,ref:t}):f.jsx(QL,{...o,ref:t})})})})}),JL=d.forwardRef((e,t)=>{const r=Sr(Pt,e.__scopeMenu),n=d.useRef(null),o=de(t,n);return d.useEffect(()=>{const a=n.current;if(a)return ei(a)},[]),f.jsx(Sf,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:r.open,disableOutsideScroll:!0,onFocusOutside:B(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>r.onOpenChange(!1)})}),QL=d.forwardRef((e,t)=>{const r=Sr(Pt,e.__scopeMenu);return f.jsx(Sf,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>r.onOpenChange(!1)})}),Sf=d.forwardRef((e,t)=>{const{__scopeMenu:r,loop:n=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:i,disableOutsidePointerEvents:s,onEntryFocus:c,onEscapeKeyDown:l,onPointerDownOutside:p,onFocusOutside:u,onInteractOutside:m,onDismiss:b,disableOutsideScroll:g,...h}=e,v=Sr(Pt,r),y=Io(Pt,r),x=Oo(r),w=a0(r),S=UL(r),[_,R]=d.useState(null),C=d.useRef(null),A=de(t,C,v.onContentChange),P=d.useRef(0),k=d.useRef(""),j=d.useRef(0),L=d.useRef(null),N=d.useRef("right"),D=d.useRef(0),$=g?yo:d.Fragment,O=g?{as:st,allowPinchZoom:!0}:void 0,G=z=>{var q,W;const oe=k.current+z,Z=S().filter(re=>!re.disabled),te=document.activeElement,F=(q=Z.find(re=>re.ref.current===te))==null?void 0:q.textValue,U=Z.map(re=>re.textValue),Q=d2(U,oe,F),K=(W=Z.find(re=>re.textValue===Q))==null?void 0:W.ref.current;(function re(J){k.current=J,window.clearTimeout(P.current),J!==""&&(P.current=window.setTimeout(()=>re(""),1e3))})(oe),K&&setTimeout(()=>K.focus())};d.useEffect(()=>()=>window.clearTimeout(P.current),[]),Ja();const H=d.useCallback(z=>{var Z,te;return N.current===((Z=L.current)==null?void 0:Z.side)&&p2(z,(te=L.current)==null?void 0:te.area)},[]);return f.jsx(ZL,{scope:r,searchRef:k,onItemEnter:d.useCallback(z=>{H(z)&&z.preventDefault()},[H]),onItemLeave:d.useCallback(z=>{var oe;H(z)||((oe=C.current)==null||oe.focus(),R(null))},[H]),onTriggerLeave:d.useCallback(z=>{H(z)&&z.preventDefault()},[H]),pointerGraceTimerRef:j,onPointerGraceIntentChange:d.useCallback(z=>{L.current=z},[]),children:f.jsx($,{...O,children:f.jsx(bo,{asChild:!0,trapped:o,onMountAutoFocus:B(a,z=>{var oe;z.preventDefault(),(oe=C.current)==null||oe.focus({preventScroll:!0})}),onUnmountAutoFocus:i,children:f.jsx(ur,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:p,onFocusOutside:u,onInteractOutside:m,onDismiss:b,children:f.jsx(To,{asChild:!0,...w,dir:y.dir,orientation:"vertical",loop:n,currentTabStopId:_,onCurrentTabStopIdChange:R,onEntryFocus:B(c,z=>{y.isUsingKeyboardRef.current||z.preventDefault()}),preventScrollOnEntryFocus:!0,children:f.jsx(Eo,{role:"menu","aria-orientation":"vertical","data-state":P0(v.open),"data-radix-menu-content":"",dir:y.dir,...x,...h,ref:A,style:{outline:"none",...h.style},onKeyDown:B(h.onKeyDown,z=>{const Z=z.target.closest("[data-radix-menu-content]")===z.currentTarget,te=z.ctrlKey||z.altKey||z.metaKey,F=z.key.length===1;Z&&(z.key==="Tab"&&z.preventDefault(),!te&&F&&G(z.key));const U=C.current;if(z.target!==U||!HL.includes(z.key))return;z.preventDefault();const K=S().filter(q=>!q.disabled).map(q=>q.ref.current);o0.includes(z.key)&&K.reverse(),l2(K)}),onBlur:B(e.onBlur,z=>{z.currentTarget.contains(z.target)||(window.clearTimeout(P.current),k.current="")}),onPointerMove:B(e.onPointerMove,co(z=>{const oe=z.target,Z=D.current!==z.clientX;if(z.currentTarget.contains(oe)&&Z){const te=z.clientX>D.current?"right":"left";N.current=te,D.current=z.clientX}}))})})})})})})});u0.displayName=Pt;var e2="MenuGroup",Cf=d.forwardRef((e,t)=>{const{__scopeMenu:r,...n}=e;return f.jsx(X.div,{role:"group",...n,ref:t})});Cf.displayName=e2;var t2="MenuLabel",d0=d.forwardRef((e,t)=>{const{__scopeMenu:r,...n}=e;return f.jsx(X.div,{...n,ref:t})});d0.displayName=t2;var ja="MenuItem",Qv="menu.itemSelect",_i=d.forwardRef((e,t)=>{const{disabled:r=!1,onSelect:n,...o}=e,a=d.useRef(null),i=Io(ja,e.__scopeMenu),s=wf(ja,e.__scopeMenu),c=de(t,a),l=d.useRef(!1),p=()=>{const u=a.current;if(!r&&u){const m=new CustomEvent(Qv,{bubbles:!0,cancelable:!0});u.addEventListener(Qv,b=>n==null?void 0:n(b),{once:!0}),Xn(u,m),m.defaultPrevented?l.current=!1:i.onClose()}};return f.jsx(f0,{...o,ref:c,disabled:r,onClick:B(e.onClick,p),onPointerDown:u=>{var m;(m=e.onPointerDown)==null||m.call(e,u),l.current=!0},onPointerUp:B(e.onPointerUp,u=>{var m;l.current||(m=u.currentTarget)==null||m.click()}),onKeyDown:B(e.onKeyDown,u=>{const m=s.searchRef.current!=="";r||m&&u.key===" "||Hu.includes(u.key)&&(u.currentTarget.click(),u.preventDefault())})})});_i.displayName=ja;var f0=d.forwardRef((e,t)=>{const{__scopeMenu:r,disabled:n=!1,textValue:o,...a}=e,i=wf(ja,r),s=a0(r),c=d.useRef(null),l=de(t,c),[p,u]=d.useState(!1),[m,b]=d.useState("");return d.useEffect(()=>{const g=c.current;g&&b((g.textContent??"").trim())},[a.children]),f.jsx(so.ItemSlot,{scope:r,disabled:n,textValue:o??m,children:f.jsx(No,{asChild:!0,...s,focusable:!n,children:f.jsx(X.div,{role:"menuitem","data-highlighted":p?"":void 0,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,...a,ref:l,onPointerMove:B(e.onPointerMove,co(g=>{n?i.onItemLeave(g):(i.onItemEnter(g),g.defaultPrevented||g.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:B(e.onPointerLeave,co(g=>i.onItemLeave(g))),onFocus:B(e.onFocus,()=>u(!0)),onBlur:B(e.onBlur,()=>u(!1))})})})}),r2="MenuCheckboxItem",p0=d.forwardRef((e,t)=>{const{checked:r=!1,onCheckedChange:n,...o}=e;return f.jsx(b0,{scope:e.__scopeMenu,checked:r,children:f.jsx(_i,{role:"menuitemcheckbox","aria-checked":Da(r)?"mixed":r,...o,ref:t,"data-state":Ef(r),onSelect:B(o.onSelect,()=>n==null?void 0:n(Da(r)?!0:!r),{checkForDefaultPrevented:!1})})})});p0.displayName=r2;var m0="MenuRadioGroup",[n2,o2]=Ur(m0,{value:void 0,onValueChange:()=>{}}),h0=d.forwardRef((e,t)=>{const{value:r,onValueChange:n,...o}=e,a=Te(n);return f.jsx(n2,{scope:e.__scopeMenu,value:r,onValueChange:a,children:f.jsx(Cf,{...o,ref:t})})});h0.displayName=m0;var g0="MenuRadioItem",v0=d.forwardRef((e,t)=>{const{value:r,...n}=e,o=o2(g0,e.__scopeMenu),a=r===o.value;return f.jsx(b0,{scope:e.__scopeMenu,checked:a,children:f.jsx(_i,{role:"menuitemradio","aria-checked":a,...n,ref:t,"data-state":Ef(a),onSelect:B(n.onSelect,()=>{var i;return(i=o.onValueChange)==null?void 0:i.call(o,r)},{checkForDefaultPrevented:!1})})})});v0.displayName=g0;var _f="MenuItemIndicator",[b0,a2]=Ur(_f,{checked:!1}),y0=d.forwardRef((e,t)=>{const{__scopeMenu:r,forceMount:n,...o}=e,a=a2(_f,r);return f.jsx(Le,{present:n||Da(a.checked)||a.checked===!0,children:f.jsx(X.span,{...o,ref:t,"data-state":Ef(a.checked)})})});y0.displayName=_f;var i2="MenuSeparator",x0=d.forwardRef((e,t)=>{const{__scopeMenu:r,...n}=e;return f.jsx(X.div,{role:"separator","aria-orientation":"horizontal",...n,ref:t})});x0.displayName=i2;var s2="MenuArrow",w0=d.forwardRef((e,t)=>{const{__scopeMenu:r,...n}=e,o=Oo(r);return f.jsx(Po,{...o,...n,ref:t})});w0.displayName=s2;var Rf="MenuSub",[c2,S0]=Ur(Rf),C0=e=>{const{__scopeMenu:t,children:r,open:n=!1,onOpenChange:o}=e,a=Sr(Rf,t),i=Oo(t),[s,c]=d.useState(null),[l,p]=d.useState(null),u=Te(o);return d.useEffect(()=>(a.open===!1&&u(!1),()=>u(!1)),[a.open,u]),f.jsx(Pn,{...i,children:f.jsx(i0,{scope:t,open:n,onOpenChange:u,content:l,onContentChange:p,children:f.jsx(c2,{scope:t,contentId:Ue(),triggerId:Ue(),trigger:s,onTriggerChange:c,children:r})})})};C0.displayName=Rf;var Vn="MenuSubTrigger",_0=d.forwardRef((e,t)=>{const r=Sr(Vn,e.__scopeMenu),n=Io(Vn,e.__scopeMenu),o=S0(Vn,e.__scopeMenu),a=wf(Vn,e.__scopeMenu),i=d.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:c}=a,l={__scopeMenu:e.__scopeMenu},p=d.useCallback(()=>{i.current&&window.clearTimeout(i.current),i.current=null},[]);return d.useEffect(()=>p,[p]),d.useEffect(()=>{const u=s.current;return()=>{window.clearTimeout(u),c(null)}},[s,c]),f.jsx(yf,{asChild:!0,...l,children:f.jsx(f0,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":r.open,"aria-controls":o.contentId,"data-state":P0(r.open),...e,ref:go(t,o.onTriggerChange),onClick:u=>{var m;(m=e.onClick)==null||m.call(e,u),!(e.disabled||u.defaultPrevented)&&(u.currentTarget.focus(),r.open||r.onOpenChange(!0))},onPointerMove:B(e.onPointerMove,co(u=>{a.onItemEnter(u),!u.defaultPrevented&&!e.disabled&&!r.open&&!i.current&&(a.onPointerGraceIntentChange(null),i.current=window.setTimeout(()=>{r.onOpenChange(!0),p()},100))})),onPointerLeave:B(e.onPointerLeave,co(u=>{var b,g;p();const m=(b=r.content)==null?void 0:b.getBoundingClientRect();if(m){const h=(g=r.content)==null?void 0:g.dataset.side,v=h==="right",y=v?-5:5,x=m[v?"left":"right"],w=m[v?"right":"left"];a.onPointerGraceIntentChange({area:[{x:u.clientX+y,y:u.clientY},{x,y:m.top},{x:w,y:m.top},{x:w,y:m.bottom},{x,y:m.bottom}],side:h}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(u),u.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:B(e.onKeyDown,u=>{var b;const m=a.searchRef.current!=="";e.disabled||m&&u.key===" "||VL[n.dir].includes(u.key)&&(r.onOpenChange(!0),(b=r.content)==null||b.focus(),u.preventDefault())})})})});_0.displayName=Vn;var R0="MenuSubContent",E0=d.forwardRef((e,t)=>{const r=c0(Pt,e.__scopeMenu),{forceMount:n=r.forceMount,...o}=e,a=Sr(Pt,e.__scopeMenu),i=Io(Pt,e.__scopeMenu),s=S0(R0,e.__scopeMenu),c=d.useRef(null),l=de(t,c);return f.jsx(so.Provider,{scope:e.__scopeMenu,children:f.jsx(Le,{present:n||a.open,children:f.jsx(so.Slot,{scope:e.__scopeMenu,children:f.jsx(Sf,{id:s.contentId,"aria-labelledby":s.triggerId,...o,ref:l,align:"start",side:i.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:p=>{var u;i.isUsingKeyboardRef.current&&((u=c.current)==null||u.focus()),p.preventDefault()},onCloseAutoFocus:p=>p.preventDefault(),onFocusOutside:B(e.onFocusOutside,p=>{p.target!==s.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:B(e.onEscapeKeyDown,p=>{i.onClose(),p.preventDefault()}),onKeyDown:B(e.onKeyDown,p=>{var b;const u=p.currentTarget.contains(p.target),m=GL[i.dir].includes(p.key);u&&m&&(a.onOpenChange(!1),(b=s.trigger)==null||b.focus(),p.preventDefault())})})})})})});E0.displayName=R0;function P0(e){return e?"open":"closed"}function Da(e){return e==="indeterminate"}function Ef(e){return Da(e)?"indeterminate":e?"checked":"unchecked"}function l2(e){const t=document.activeElement;for(const r of e)if(r===t||(r.focus(),document.activeElement!==t))return}function u2(e,t){return e.map((r,n)=>e[(t+n)%e.length])}function d2(e,t,r){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,a=r?e.indexOf(r):-1;let i=u2(e,Math.max(a,0));o.length===1&&(i=i.filter(l=>l!==r));const c=i.find(l=>l.toLowerCase().startsWith(o.toLowerCase()));return c!==r?c:void 0}function f2(e,t){const{x:r,y:n}=e;let o=!1;for(let a=0,i=t.length-1;a<t.length;i=a++){const s=t[a].x,c=t[a].y,l=t[i].x,p=t[i].y;c>n!=p>n&&r<(l-s)*(n-c)/(p-c)+s&&(o=!o)}return o}function p2(e,t){if(!t)return!1;const r={x:e.clientX,y:e.clientY};return f2(r,t)}function co(e){return t=>t.pointerType==="mouse"?e(t):void 0}var Pf=s0,Tf=yf,Nf=l0,Af=u0,Mf=Cf,Of=d0,If=_i,jf=p0,Df=h0,kf=v0,$f=y0,Lf=x0,Ff=w0,Bf=C0,zf=_0,qf=E0,Hf="ContextMenu",[m2,t3]=De(Hf,[Mo]),lt=Mo(),[h2,T0]=m2(Hf),N0=e=>{const{__scopeContextMenu:t,children:r,onOpenChange:n,dir:o,modal:a=!0}=e,[i,s]=d.useState(!1),c=lt(t),l=Te(n),p=d.useCallback(u=>{s(u),l(u)},[l]);return f.jsx(h2,{scope:t,open:i,onOpenChange:p,modal:a,children:f.jsx(Pf,{...c,dir:o,open:i,onOpenChange:p,modal:a,children:r})})};N0.displayName=Hf;var A0="ContextMenuTrigger",M0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,disabled:n=!1,...o}=e,a=T0(A0,r),i=lt(r),s=d.useRef({x:0,y:0}),c=d.useRef({getBoundingClientRect:()=>DOMRect.fromRect({width:0,height:0,...s.current})}),l=d.useRef(0),p=d.useCallback(()=>window.clearTimeout(l.current),[]),u=m=>{s.current={x:m.clientX,y:m.clientY},a.onOpenChange(!0)};return d.useEffect(()=>p,[p]),d.useEffect(()=>void(n&&p()),[n,p]),f.jsxs(f.Fragment,{children:[f.jsx(Tf,{...i,virtualRef:c}),f.jsx(X.span,{"data-state":a.open?"open":"closed","data-disabled":n?"":void 0,...o,ref:t,style:{WebkitTouchCallout:"none",...e.style},onContextMenu:n?e.onContextMenu:B(e.onContextMenu,m=>{p(),u(m),m.preventDefault()}),onPointerDown:n?e.onPointerDown:B(e.onPointerDown,ra(m=>{p(),l.current=window.setTimeout(()=>u(m),700)})),onPointerMove:n?e.onPointerMove:B(e.onPointerMove,ra(p)),onPointerCancel:n?e.onPointerCancel:B(e.onPointerCancel,ra(p)),onPointerUp:n?e.onPointerUp:B(e.onPointerUp,ra(p))})]})});M0.displayName=A0;var g2="ContextMenuPortal",O0=e=>{const{__scopeContextMenu:t,...r}=e,n=lt(t);return f.jsx(Nf,{...n,...r})};O0.displayName=g2;var I0="ContextMenuContent",j0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=T0(I0,r),a=lt(r),i=d.useRef(!1);return f.jsx(Af,{...a,...n,ref:t,side:"right",sideOffset:2,align:"start",onCloseAutoFocus:s=>{var c;(c=e.onCloseAutoFocus)==null||c.call(e,s),!s.defaultPrevented&&i.current&&s.preventDefault(),i.current=!1},onInteractOutside:s=>{var c;(c=e.onInteractOutside)==null||c.call(e,s),!s.defaultPrevented&&!o.modal&&(i.current=!0)},style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});j0.displayName=I0;var v2="ContextMenuGroup",D0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(Mf,{...o,...n,ref:t})});D0.displayName=v2;var b2="ContextMenuLabel",k0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(Of,{...o,...n,ref:t})});k0.displayName=b2;var y2="ContextMenuItem",$0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(If,{...o,...n,ref:t})});$0.displayName=y2;var x2="ContextMenuCheckboxItem",L0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(jf,{...o,...n,ref:t})});L0.displayName=x2;var w2="ContextMenuRadioGroup",F0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(Df,{...o,...n,ref:t})});F0.displayName=w2;var S2="ContextMenuRadioItem",B0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(kf,{...o,...n,ref:t})});B0.displayName=S2;var C2="ContextMenuItemIndicator",z0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx($f,{...o,...n,ref:t})});z0.displayName=C2;var _2="ContextMenuSeparator",q0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(Lf,{...o,...n,ref:t})});q0.displayName=_2;var R2="ContextMenuArrow",E2=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(Ff,{...o,...n,ref:t})});E2.displayName=R2;var P2="ContextMenuSub",H0=e=>{const{__scopeContextMenu:t,children:r,onOpenChange:n,open:o,defaultOpen:a}=e,i=lt(t),[s,c]=$e({prop:o,defaultProp:a,onChange:n});return f.jsx(Bf,{...i,open:s,onOpenChange:c,children:r})};H0.displayName=P2;var T2="ContextMenuSubTrigger",V0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(zf,{...o,...n,ref:t})});V0.displayName=T2;var N2="ContextMenuSubContent",G0=d.forwardRef((e,t)=>{const{__scopeContextMenu:r,...n}=e,o=lt(r);return f.jsx(qf,{...o,...n,ref:t,style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});G0.displayName=N2;function ra(e){return t=>t.pointerType!=="mouse"?e(t):void 0}var A2=N0,M2=M0,U0=O0,W0=j0,O2=D0,K0=k0,Y0=$0,X0=L0,I2=F0,Z0=B0,J0=z0,Q0=q0,j2=H0,eS=V0,tS=G0;const D2=A2,k2=M2,$2=O2,L2=U0,F2=j2,B2=I2,rS=d.forwardRef(({className:e,inset:t,children:r,...n},o)=>f.jsxs(eS,{ref:o,className:M("flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",t&&"pl-8",e),...n,children:[r,f.jsx(Dr,{className:"ml-auto h-4 w-4"})]}));rS.displayName=eS.displayName;const nS=d.forwardRef(({className:e,...t},r)=>f.jsx(tS,{ref:r,className:M("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-context-menu-content-transform-origin]",e),...t}));nS.displayName=tS.displayName;const oS=d.forwardRef(({className:e,...t},r)=>f.jsx(U0,{children:f.jsx(W0,{ref:r,className:M("z-50 max-h-[--radix-context-menu-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-context-menu-content-transform-origin]",e),...t})}));oS.displayName=W0.displayName;const aS=d.forwardRef(({className:e,inset:t,...r},n)=>f.jsx(Y0,{ref:n,className:M("relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t&&"pl-8",e),...r}));aS.displayName=Y0.displayName;const iS=d.forwardRef(({className:e,children:t,checked:r,...n},o)=>f.jsxs(X0,{ref:o,className:M("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:r,...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(J0,{children:f.jsx(vo,{className:"h-4 w-4"})})}),t]}));iS.displayName=X0.displayName;const sS=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(Z0,{ref:n,className:M("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(J0,{children:f.jsx(Za,{className:"h-4 w-4 fill-current"})})}),t]}));sS.displayName=Z0.displayName;const cS=d.forwardRef(({className:e,inset:t,...r},n)=>f.jsx(K0,{ref:n,className:M("px-2 py-1.5 text-sm font-semibold text-foreground",t&&"pl-8",e),...r}));cS.displayName=K0.displayName;const lS=d.forwardRef(({className:e,...t},r)=>f.jsx(Q0,{ref:r,className:M("-mx-1 my-1 h-px bg-border",e),...t}));lS.displayName=Q0.displayName;const uS=({className:e,...t})=>f.jsx("span",{className:M("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});uS.displayName="ContextMenuShortcut";const z2=ti,q2=ri,dS=ni,H2=qr,Vf=d.forwardRef(({className:e,...t},r)=>f.jsx(xn,{ref:r,className:M("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));Vf.displayName=xn.displayName;const fS=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(dS,{children:[f.jsx(Vf,{}),f.jsxs(wn,{ref:n,className:M("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...r,children:[t,f.jsxs(qr,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[f.jsx(Pd,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));fS.displayName=wn.displayName;const pS=({className:e,...t})=>f.jsx("div",{className:M("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});pS.displayName="DialogHeader";const mS=({className:e,...t})=>f.jsx("div",{className:M("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});mS.displayName="DialogFooter";const hS=d.forwardRef(({className:e,...t},r)=>f.jsx(Sn,{ref:r,className:M("text-lg font-semibold leading-none tracking-tight",e),...t}));hS.displayName=Sn.displayName;const gS=d.forwardRef(({className:e,...t},r)=>f.jsx(Cn,{ref:r,className:M("text-sm text-muted-foreground",e),...t}));gS.displayName=Cn.displayName;function V2(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}const vS=E.createContext({drawerRef:{current:null},overlayRef:{current:null},onPress:()=>{},onRelease:()=>{},onDrag:()=>{},onNestedDrag:()=>{},onNestedOpenChange:()=>{},onNestedRelease:()=>{},openProp:void 0,dismissible:!1,isOpen:!1,isDragging:!1,keyboardIsOpen:{current:!1},snapPointsOffset:null,snapPoints:null,handleOnly:!1,modal:!1,shouldFade:!1,activeSnapPoint:null,onOpenChange:()=>{},setActiveSnapPoint:()=>{},closeDrawer:()=>{},direction:"bottom",shouldAnimate:{current:!0},shouldScaleBackground:!1,setBackgroundColorOnScale:!0,noBodyStyles:!1,container:null,autoFocus:!1}),jo=()=>{const e=E.useContext(vS);if(!e)throw new Error("useDrawerContext must be used within a Drawer.Root");return e};V2(`[data-vaul-drawer]{touch-action:none;will-change:transform;transition:transform .5s cubic-bezier(.32, .72, 0, 1);animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=open]{animation-name:slideFromBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=bottom][data-state=closed]{animation-name:slideToBottom}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=open]{animation-name:slideFromTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=top][data-state=closed]{animation-name:slideToTop}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=open]{animation-name:slideFromLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=left][data-state=closed]{animation-name:slideToLeft}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=open]{animation-name:slideFromRight}[data-vaul-drawer][data-vaul-snap-points=false][data-vaul-drawer-direction=right][data-state=closed]{animation-name:slideToRight}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--initial-transform,100%),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}[data-vaul-drawer][data-vaul-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--initial-transform,100%),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=top]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=bottom]{transform:translate3d(0,var(--snap-point-height,0),0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=left]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-drawer][data-vaul-delayed-snap-points=true][data-vaul-drawer-direction=right]{transform:translate3d(var(--snap-point-height,0),0,0)}[data-vaul-overlay][data-vaul-snap-points=false]{animation-duration:.5s;animation-timing-function:cubic-bezier(0.32,0.72,0,1)}[data-vaul-overlay][data-vaul-snap-points=false][data-state=open]{animation-name:fadeIn}[data-vaul-overlay][data-state=closed]{animation-name:fadeOut}[data-vaul-animate=false]{animation:none!important}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:0;transition:opacity .5s cubic-bezier(.32, .72, 0, 1)}[data-vaul-overlay][data-vaul-snap-points=true]{opacity:1}[data-vaul-drawer]:not([data-vaul-custom-container=true])::after{content:'';position:absolute;background:inherit;background-color:inherit}[data-vaul-drawer][data-vaul-drawer-direction=top]::after{top:initial;bottom:100%;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=bottom]::after{top:100%;bottom:initial;left:0;right:0;height:200%}[data-vaul-drawer][data-vaul-drawer-direction=left]::after{left:initial;right:100%;top:0;bottom:0;width:200%}[data-vaul-drawer][data-vaul-drawer-direction=right]::after{left:100%;right:initial;top:0;bottom:0;width:200%}[data-vaul-overlay][data-vaul-snap-points=true]:not([data-vaul-snap-points-overlay=true]):not(
|
|
212
|
+
[data-state=closed]
|
|
213
|
+
){opacity:0}[data-vaul-overlay][data-vaul-snap-points-overlay=true]{opacity:1}[data-vaul-handle]{display:block;position:relative;opacity:.7;background:#e2e2e4;margin-left:auto;margin-right:auto;height:5px;width:32px;border-radius:1rem;touch-action:pan-y}[data-vaul-handle]:active,[data-vaul-handle]:hover{opacity:1}[data-vaul-handle-hitarea]{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:max(100%,2.75rem);height:max(100%,2.75rem);touch-action:inherit}@media (hover:hover) and (pointer:fine){[data-vaul-drawer]{user-select:none}}@media (pointer:fine){[data-vaul-handle-hitarea]:{width:100%;height:100%}}@keyframes fadeIn{from{opacity:0}to{opacity:1}}@keyframes fadeOut{to{opacity:0}}@keyframes slideFromBottom{from{transform:translate3d(0,var(--initial-transform,100%),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToBottom{to{transform:translate3d(0,var(--initial-transform,100%),0)}}@keyframes slideFromTop{from{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}to{transform:translate3d(0,0,0)}}@keyframes slideToTop{to{transform:translate3d(0,calc(var(--initial-transform,100%) * -1),0)}}@keyframes slideFromLeft{from{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToLeft{to{transform:translate3d(calc(var(--initial-transform,100%) * -1),0,0)}}@keyframes slideFromRight{from{transform:translate3d(var(--initial-transform,100%),0,0)}to{transform:translate3d(0,0,0)}}@keyframes slideToRight{to{transform:translate3d(var(--initial-transform,100%),0,0)}}`);function G2(){const e=navigator.userAgent;return typeof window<"u"&&(/Firefox/.test(e)&&/Mobile/.test(e)||/FxiOS/.test(e))}function U2(){return Gf(/^Mac/)}function W2(){return Gf(/^iPhone/)}function eb(){return/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}function K2(){return Gf(/^iPad/)||U2()&&navigator.maxTouchPoints>1}function bS(){return W2()||K2()}function Gf(e){return typeof window<"u"&&window.navigator!=null?e.test(window.navigator.platform):void 0}const Y2=24,X2=typeof window<"u"?E.useLayoutEffect:E.useEffect;function tb(...e){return(...t)=>{for(let r of e)typeof r=="function"&&r(...t)}}const au=typeof document<"u"&&window.visualViewport;function rb(e){let t=window.getComputedStyle(e);return/(auto|scroll)/.test(t.overflow+t.overflowX+t.overflowY)}function yS(e){for(rb(e)&&(e=e.parentElement);e&&!rb(e);)e=e.parentElement;return e||document.scrollingElement||document.documentElement}const Z2=new Set(["checkbox","radio","range","color","file","image","button","submit","reset"]);let na=0,iu;function J2(e={}){let{isDisabled:t}=e;X2(()=>{if(!t)return na++,na===1&&bS()&&(iu=Q2()),()=>{na--,na===0&&(iu==null||iu())}},[t])}function Q2(){let e,t=0,r=u=>{e=yS(u.target),!(e===document.documentElement&&e===document.body)&&(t=u.changedTouches[0].pageY)},n=u=>{if(!e||e===document.documentElement||e===document.body){u.preventDefault();return}let m=u.changedTouches[0].pageY,b=e.scrollTop,g=e.scrollHeight-e.clientHeight;g!==0&&((b<=0&&m>t||b>=g&&m<t)&&u.preventDefault(),t=m)},o=u=>{let m=u.target;Vu(m)&&m!==document.activeElement&&(u.preventDefault(),m.style.transform="translateY(-2000px)",m.focus(),requestAnimationFrame(()=>{m.style.transform=""}))},a=u=>{let m=u.target;Vu(m)&&(m.style.transform="translateY(-2000px)",requestAnimationFrame(()=>{m.style.transform="",au&&(au.height<window.innerHeight?requestAnimationFrame(()=>{nb(m)}):au.addEventListener("resize",()=>nb(m),{once:!0}))}))},i=()=>{window.scrollTo(0,0)},s=window.pageXOffset,c=window.pageYOffset,l=tb(eF(document.documentElement,"paddingRight",`${window.innerWidth-document.documentElement.clientWidth}px`));window.scrollTo(0,0);let p=tb($n(document,"touchstart",r,{passive:!1,capture:!0}),$n(document,"touchmove",n,{passive:!1,capture:!0}),$n(document,"touchend",o,{passive:!1,capture:!0}),$n(document,"focus",a,!0),$n(window,"scroll",i));return()=>{l(),p(),window.scrollTo(s,c)}}function eF(e,t,r){let n=e.style[t];return e.style[t]=r,()=>{e.style[t]=n}}function $n(e,t,r,n){return e.addEventListener(t,r,n),()=>{e.removeEventListener(t,r,n)}}function nb(e){let t=document.scrollingElement||document.documentElement;for(;e&&e!==t;){let r=yS(e);if(r!==document.documentElement&&r!==document.body&&r!==e){let n=r.getBoundingClientRect().top,o=e.getBoundingClientRect().top,a=e.getBoundingClientRect().bottom;const i=r.getBoundingClientRect().bottom+Y2;a>i&&(r.scrollTop+=o-n)}e=r.parentElement}}function Vu(e){return e instanceof HTMLInputElement&&!Z2.has(e.type)||e instanceof HTMLTextAreaElement||e instanceof HTMLElement&&e.isContentEditable}function tF(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function rF(...e){return t=>e.forEach(r=>tF(r,t))}function xS(...e){return d.useCallback(rF(...e),e)}const wS=new WeakMap;function tt(e,t,r=!1){if(!e||!(e instanceof HTMLElement))return;let n={};Object.entries(t).forEach(([o,a])=>{if(o.startsWith("--")){e.style.setProperty(o,a);return}n[o]=e.style[o],e.style[o]=a}),!r&&wS.set(e,n)}function nF(e,t){if(!e||!(e instanceof HTMLElement))return;let r=wS.get(e);r&&(e.style[t]=r[t])}const Xe=e=>{switch(e){case"top":case"bottom":return!0;case"left":case"right":return!1;default:return e}};function oa(e,t){if(!e)return null;const r=window.getComputedStyle(e),n=r.transform||r.webkitTransform||r.mozTransform;let o=n.match(/^matrix3d\((.+)\)$/);return o?parseFloat(o[1].split(", ")[Xe(t)?13:12]):(o=n.match(/^matrix\((.+)\)$/),o?parseFloat(o[1].split(", ")[Xe(t)?5:4]):null)}function oF(e){return 8*(Math.log(e+1)-2)}function su(e,t){if(!e)return()=>{};const r=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=r}}function aF(...e){return(...t)=>{for(const r of e)typeof r=="function"&&r(...t)}}const ze={DURATION:.5,EASE:[.32,.72,0,1]},SS=.4,iF=.25,sF=100,CS=8,aa=16,Gu=26,cu="vaul-dragging";function _S(e){const t=E.useRef(e);return E.useEffect(()=>{t.current=e}),E.useMemo(()=>(...r)=>t.current==null?void 0:t.current.call(t,...r),[])}function cF({defaultProp:e,onChange:t}){const r=E.useState(e),[n]=r,o=E.useRef(n),a=_S(t);return E.useEffect(()=>{o.current!==n&&(a(n),o.current=n)},[n,o,a]),r}function RS({prop:e,defaultProp:t,onChange:r=()=>{}}){const[n,o]=cF({defaultProp:t,onChange:r}),a=e!==void 0,i=a?e:n,s=_S(r),c=E.useCallback(l=>{if(a){const u=typeof l=="function"?l(e):l;u!==e&&s(u)}else o(l)},[a,e,o,s]);return[i,c]}function lF({activeSnapPointProp:e,setActiveSnapPointProp:t,snapPoints:r,drawerRef:n,overlayRef:o,fadeFromIndex:a,onSnapPointChange:i,direction:s="bottom",container:c,snapToSequentialPoint:l}){const[p,u]=RS({prop:e,defaultProp:r==null?void 0:r[0],onChange:t}),[m,b]=E.useState(typeof window<"u"?{innerWidth:window.innerWidth,innerHeight:window.innerHeight}:void 0);E.useEffect(()=>{function C(){b({innerWidth:window.innerWidth,innerHeight:window.innerHeight})}return window.addEventListener("resize",C),()=>window.removeEventListener("resize",C)},[]);const g=E.useMemo(()=>p===(r==null?void 0:r[r.length-1])||null,[r,p]),h=E.useMemo(()=>{var C;return(C=r==null?void 0:r.findIndex(A=>A===p))!=null?C:null},[r,p]),v=r&&r.length>0&&(a||a===0)&&!Number.isNaN(a)&&r[a]===p||!r,y=E.useMemo(()=>{const C=c?{width:c.getBoundingClientRect().width,height:c.getBoundingClientRect().height}:typeof window<"u"?{width:window.innerWidth,height:window.innerHeight}:{width:0,height:0};var A;return(A=r==null?void 0:r.map(P=>{const k=typeof P=="string";let j=0;if(k&&(j=parseInt(P,10)),Xe(s)){const N=k?j:m?P*C.height:0;return m?s==="bottom"?C.height-N:-C.height+N:N}const L=k?j:m?P*C.width:0;return m?s==="right"?C.width-L:-C.width+L:L}))!=null?A:[]},[r,m,c]),x=E.useMemo(()=>h!==null?y==null?void 0:y[h]:null,[y,h]),w=E.useCallback(C=>{var A;const P=(A=y==null?void 0:y.findIndex(k=>k===C))!=null?A:null;i(P),tt(n.current,{transition:`transform ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`,transform:Xe(s)?`translate3d(0, ${C}px, 0)`:`translate3d(${C}px, 0, 0)`}),y&&P!==y.length-1&&a!==void 0&&P!==a&&P<a?tt(o.current,{transition:`opacity ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`,opacity:"0"}):tt(o.current,{transition:`opacity ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`,opacity:"1"}),u(r==null?void 0:r[Math.max(P,0)])},[n.current,r,y,a,o,u]);E.useEffect(()=>{if(p||e){var C;const A=(C=r==null?void 0:r.findIndex(P=>P===e||P===p))!=null?C:-1;y&&A!==-1&&typeof y[A]=="number"&&w(y[A])}},[p,e,r,y,w]);function S({draggedDistance:C,closeDrawer:A,velocity:P,dismissible:k}){if(a===void 0)return;const j=s==="bottom"||s==="right"?(x??0)-C:(x??0)+C,L=h===a-1,N=h===0,D=C>0;if(L&&tt(o.current,{transition:`opacity ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`}),!l&&P>2&&!D){k?A():w(y[0]);return}if(!l&&P>2&&D&&y&&r){w(y[r.length-1]);return}const $=y==null?void 0:y.reduce((G,H)=>typeof G!="number"||typeof H!="number"?G:Math.abs(H-j)<Math.abs(G-j)?H:G),O=Xe(s)?window.innerHeight:window.innerWidth;if(P>SS&&Math.abs(C)<O*.4){const G=D?1:-1;if(G>0&&g&&r){w(y[r.length-1]);return}if(N&&G<0&&k&&A(),h===null)return;w(y[h+G]);return}w($)}function _({draggedDistance:C}){if(x===null)return;const A=s==="bottom"||s==="right"?x-C:x+C;(s==="bottom"||s==="right")&&A<y[y.length-1]||(s==="top"||s==="left")&&A>y[y.length-1]||tt(n.current,{transform:Xe(s)?`translate3d(0, ${A}px, 0)`:`translate3d(${A}px, 0, 0)`})}function R(C,A){if(!r||typeof h!="number"||!y||a===void 0)return null;const P=h===a-1;if(h>=a&&A)return 0;if(P&&!A)return 1;if(!v&&!P)return null;const j=P?h+1:h-1,L=P?y[j]-y[j-1]:y[j+1]-y[j],N=C/Math.abs(L);return P?1-N:N}return{isLastSnapPoint:g,activeSnapPoint:p,shouldFade:v,getPercentageDragged:R,setActiveSnapPoint:u,activeSnapPointIndex:h,onRelease:S,onDrag:_,snapPointsOffset:y}}const uF=()=>()=>{};function dF(){const{direction:e,isOpen:t,shouldScaleBackground:r,setBackgroundColorOnScale:n,noBodyStyles:o}=jo(),a=E.useRef(null),i=E.useMemo(()=>document.body.style.backgroundColor,[]);function s(){return(window.innerWidth-Gu)/window.innerWidth}E.useEffect(()=>{if(t&&r){a.current&&clearTimeout(a.current);const c=document.querySelector("[data-vaul-drawer-wrapper]")||document.querySelector("[vaul-drawer-wrapper]");if(!c)return;aF(n&&!o?su(document.body,{background:"black"}):uF,su(c,{transformOrigin:Xe(e)?"top":"left",transitionProperty:"transform, border-radius",transitionDuration:`${ze.DURATION}s`,transitionTimingFunction:`cubic-bezier(${ze.EASE.join(",")})`}));const l=su(c,{borderRadius:`${CS}px`,overflow:"hidden",...Xe(e)?{transform:`scale(${s()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`}:{transform:`scale(${s()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`}});return()=>{l(),a.current=window.setTimeout(()=>{i?document.body.style.background=i:document.body.style.removeProperty("background")},ze.DURATION*1e3)}}},[t,r,i])}let Ln=null;function fF({isOpen:e,modal:t,nested:r,hasBeenOpened:n,preventScrollRestoration:o,noBodyStyles:a}){const[i,s]=E.useState(()=>typeof window<"u"?window.location.href:""),c=E.useRef(0),l=E.useCallback(()=>{if(eb()&&Ln===null&&e&&!a){Ln={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,height:document.body.style.height,right:"unset"};const{scrollX:u,innerHeight:m}=window;document.body.style.setProperty("position","fixed","important"),Object.assign(document.body.style,{top:`${-c.current}px`,left:`${-u}px`,right:"0px",height:"auto"}),window.setTimeout(()=>window.requestAnimationFrame(()=>{const b=m-window.innerHeight;b&&c.current>=m&&(document.body.style.top=`${-(c.current+b)}px`)}),300)}},[e]),p=E.useCallback(()=>{if(eb()&&Ln!==null&&!a){const u=-parseInt(document.body.style.top,10),m=-parseInt(document.body.style.left,10);Object.assign(document.body.style,Ln),window.requestAnimationFrame(()=>{if(o&&i!==window.location.href){s(window.location.href);return}window.scrollTo(m,u)}),Ln=null}},[i]);return E.useEffect(()=>{function u(){c.current=window.scrollY}return u(),window.addEventListener("scroll",u),()=>{window.removeEventListener("scroll",u)}},[]),E.useEffect(()=>{if(t)return()=>{typeof document>"u"||document.querySelector("[data-vaul-drawer]")||p()}},[t,p]),E.useEffect(()=>{r||!n||(e?(!window.matchMedia("(display-mode: standalone)").matches&&l(),t||window.setTimeout(()=>{p()},500)):p())},[e,n,i,t,r,l,p]),{restorePositionSetting:p}}function pF({open:e,onOpenChange:t,children:r,onDrag:n,onRelease:o,snapPoints:a,shouldScaleBackground:i=!1,setBackgroundColorOnScale:s=!0,closeThreshold:c=iF,scrollLockTimeout:l=sF,dismissible:p=!0,handleOnly:u=!1,fadeFromIndex:m=a&&a.length-1,activeSnapPoint:b,setActiveSnapPoint:g,fixed:h,modal:v=!0,onClose:y,nested:x,noBodyStyles:w=!1,direction:S="bottom",defaultOpen:_=!1,disablePreventScroll:R=!0,snapToSequentialPoint:C=!1,preventScrollRestoration:A=!1,repositionInputs:P=!0,onAnimationEnd:k,container:j,autoFocus:L=!1}){var N,D;const[$=!1,O]=RS({defaultProp:_,prop:e,onChange:ue=>{t==null||t(ue),!ue&&!x&&ot(),setTimeout(()=>{k==null||k(ue)},ze.DURATION*1e3),ue&&!v&&typeof window<"u"&&window.requestAnimationFrame(()=>{document.body.style.pointerEvents="auto"}),ue||(document.body.style.pointerEvents="auto")}}),[G,H]=E.useState(!1),[z,oe]=E.useState(!1),[Z,te]=E.useState(!1),F=E.useRef(null),U=E.useRef(null),Q=E.useRef(null),K=E.useRef(null),q=E.useRef(null),W=E.useRef(!1),re=E.useRef(null),J=E.useRef(0),ne=E.useRef(!1),V=E.useRef(!_),ae=E.useRef(0),I=E.useRef(null),ee=E.useRef(((N=I.current)==null?void 0:N.getBoundingClientRect().height)||0),pe=E.useRef(((D=I.current)==null?void 0:D.getBoundingClientRect().width)||0),me=E.useRef(0),ge=E.useCallback(ue=>{a&&ue===Oe.length-1&&(U.current=new Date)},[]),{activeSnapPoint:fe,activeSnapPointIndex:Ee,setActiveSnapPoint:Fe,onRelease:we,snapPointsOffset:Oe,onDrag:rt,shouldFade:Ze,getPercentageDragged:We}=lF({snapPoints:a,activeSnapPointProp:b,setActiveSnapPointProp:g,drawerRef:I,fadeFromIndex:m,overlayRef:F,onSnapPointChange:ge,direction:S,container:j,snapToSequentialPoint:C});J2({isDisabled:!$||z||!v||Z||!G||!P||!R});const{restorePositionSetting:ot}=fF({isOpen:$,modal:v,nested:x??!1,hasBeenOpened:G,preventScrollRestoration:A,noBodyStyles:w});function mt(){return(window.innerWidth-Gu)/window.innerWidth}function ft(ue){var be,Ce;!p&&!a||I.current&&!I.current.contains(ue.target)||(ee.current=((be=I.current)==null?void 0:be.getBoundingClientRect().height)||0,pe.current=((Ce=I.current)==null?void 0:Ce.getBoundingClientRect().width)||0,oe(!0),Q.current=new Date,bS()&&window.addEventListener("touchend",()=>W.current=!1,{once:!0}),ue.target.setPointerCapture(ue.pointerId),J.current=Xe(S)?ue.pageY:ue.pageX)}function Ve(ue,be){var Ce;let ve=ue;const ie=(Ce=window.getSelection())==null?void 0:Ce.toString(),Se=I.current?oa(I.current,S):null,xe=new Date;if(ve.tagName==="SELECT"||ve.hasAttribute("data-vaul-no-drag")||ve.closest("[data-vaul-no-drag]"))return!1;if(S==="right"||S==="left")return!0;if(U.current&&xe.getTime()-U.current.getTime()<500)return!1;if(Se!==null&&(S==="bottom"?Se>0:Se<0))return!0;if(ie&&ie.length>0)return!1;if(q.current&&xe.getTime()-q.current.getTime()<l&&Se===0||be)return q.current=xe,!1;for(;ve;){if(ve.scrollHeight>ve.clientHeight){if(ve.scrollTop!==0)return q.current=new Date,!1;if(ve.getAttribute("role")==="dialog")return!0}ve=ve.parentNode}return!0}function Ct(ue){if(I.current&&z){const be=S==="bottom"||S==="right"?1:-1,Ce=(J.current-(Xe(S)?ue.pageY:ue.pageX))*be,ve=Ce>0,ie=a&&!p&&!ve;if(ie&&Ee===0)return;const Se=Math.abs(Ce),xe=document.querySelector("[data-vaul-drawer-wrapper]"),ke=S==="bottom"||S==="top"?ee.current:pe.current;let Qe=Se/ke;const Ie=We(Se,ve);if(Ie!==null&&(Qe=Ie),ie&&Qe>=1||!W.current&&!Ve(ue.target,ve))return;if(I.current.classList.add(cu),W.current=!0,tt(I.current,{transition:"none"}),tt(F.current,{transition:"none"}),a&&rt({draggedDistance:Ce}),ve&&!a){const at=oF(Ce),et=Math.min(at*-1,0)*be;tt(I.current,{transform:Xe(S)?`translate3d(0, ${et}px, 0)`:`translate3d(${et}px, 0, 0)`});return}const Be=1-Qe;if((Ze||m&&Ee===m-1)&&(n==null||n(ue,Qe),tt(F.current,{opacity:`${Be}`,transition:"none"},!0)),xe&&F.current&&i){const at=Math.min(mt()+Qe*(1-mt()),1),et=8-Qe*8,it=Math.max(0,14-Qe*14);tt(xe,{borderRadius:`${et}px`,transform:Xe(S)?`scale(${at}) translate3d(0, ${it}px, 0)`:`scale(${at}) translate3d(${it}px, 0, 0)`,transition:"none"},!0)}if(!a){const at=Se*be;tt(I.current,{transform:Xe(S)?`translate3d(0, ${at}px, 0)`:`translate3d(${at}px, 0, 0)`})}}}E.useEffect(()=>{window.requestAnimationFrame(()=>{V.current=!0})},[]),E.useEffect(()=>{var ue;function be(){if(!I.current||!P)return;const Ce=document.activeElement;if(Vu(Ce)||ne.current){var ve;const ie=((ve=window.visualViewport)==null?void 0:ve.height)||0,Se=window.innerHeight;let xe=Se-ie;const ke=I.current.getBoundingClientRect().height||0,Qe=ke>Se*.8;me.current||(me.current=ke);const Ie=I.current.getBoundingClientRect().top;if(Math.abs(ae.current-xe)>60&&(ne.current=!ne.current),a&&a.length>0&&Oe&&Ee){const Be=Oe[Ee]||0;xe+=Be}if(ae.current=xe,ke>ie||ne.current){const Be=I.current.getBoundingClientRect().height;let at=Be;Be>ie&&(at=ie-(Qe?Ie:Gu)),h?I.current.style.height=`${Be-Math.max(xe,0)}px`:I.current.style.height=`${Math.max(at,ie-Ie)}px`}else G2()||(I.current.style.height=`${me.current}px`);a&&a.length>0&&!ne.current?I.current.style.bottom="0px":I.current.style.bottom=`${Math.max(xe,0)}px`}}return(ue=window.visualViewport)==null||ue.addEventListener("resize",be),()=>{var Ce;return(Ce=window.visualViewport)==null?void 0:Ce.removeEventListener("resize",be)}},[Ee,a,Oe]);function Ke(ue){At(),y==null||y(),ue||O(!1),setTimeout(()=>{a&&Fe(a[0])},ze.DURATION*1e3)}function Je(){if(!I.current)return;const ue=document.querySelector("[data-vaul-drawer-wrapper]"),be=oa(I.current,S);tt(I.current,{transform:"translate3d(0, 0, 0)",transition:`transform ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`}),tt(F.current,{transition:`opacity ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`,opacity:"1"}),i&&be&&be>0&&$&&tt(ue,{borderRadius:`${CS}px`,overflow:"hidden",...Xe(S)?{transform:`scale(${mt()}) translate3d(0, calc(env(safe-area-inset-top) + 14px), 0)`,transformOrigin:"top"}:{transform:`scale(${mt()}) translate3d(calc(env(safe-area-inset-top) + 14px), 0, 0)`,transformOrigin:"left"},transitionProperty:"transform, border-radius",transitionDuration:`${ze.DURATION}s`,transitionTimingFunction:`cubic-bezier(${ze.EASE.join(",")})`},!0)}function At(){!z||!I.current||(I.current.classList.remove(cu),W.current=!1,oe(!1),K.current=new Date)}function Vt(ue){if(!z||!I.current)return;I.current.classList.remove(cu),W.current=!1,oe(!1),K.current=new Date;const be=oa(I.current,S);if(!ue||!Ve(ue.target,!1)||!be||Number.isNaN(be)||Q.current===null)return;const Ce=K.current.getTime()-Q.current.getTime(),ve=J.current-(Xe(S)?ue.pageY:ue.pageX),ie=Math.abs(ve)/Ce;if(ie>.05&&(te(!0),setTimeout(()=>{te(!1)},200)),a){we({draggedDistance:ve*(S==="bottom"||S==="right"?1:-1),closeDrawer:Ke,velocity:ie,dismissible:p}),o==null||o(ue,!0);return}if(S==="bottom"||S==="right"?ve>0:ve<0){Je(),o==null||o(ue,!0);return}if(ie>SS){Ke(),o==null||o(ue,!1);return}var Se;const xe=Math.min((Se=I.current.getBoundingClientRect().height)!=null?Se:0,window.innerHeight);var ke;const Qe=Math.min((ke=I.current.getBoundingClientRect().width)!=null?ke:0,window.innerWidth),Ie=S==="left"||S==="right";if(Math.abs(be)>=(Ie?Qe:xe)*c){Ke(),o==null||o(ue,!1);return}o==null||o(ue,!0),Je()}E.useEffect(()=>($&&(tt(document.documentElement,{scrollBehavior:"auto"}),U.current=new Date),()=>{nF(document.documentElement,"scrollBehavior")}),[$]);function pr(ue){const be=ue?(window.innerWidth-aa)/window.innerWidth:1,Ce=ue?-16:0;re.current&&window.clearTimeout(re.current),tt(I.current,{transition:`transform ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`,transform:Xe(S)?`scale(${be}) translate3d(0, ${Ce}px, 0)`:`scale(${be}) translate3d(${Ce}px, 0, 0)`}),!ue&&I.current&&(re.current=setTimeout(()=>{const ve=oa(I.current,S);tt(I.current,{transition:"none",transform:Xe(S)?`translate3d(0, ${ve}px, 0)`:`translate3d(${ve}px, 0, 0)`})},500))}function Er(ue,be){if(be<0)return;const Ce=(window.innerWidth-aa)/window.innerWidth,ve=Ce+be*(1-Ce),ie=-16+be*aa;tt(I.current,{transform:Xe(S)?`scale(${ve}) translate3d(0, ${ie}px, 0)`:`scale(${ve}) translate3d(${ie}px, 0, 0)`,transition:"none"})}function Mt(ue,be){const Ce=Xe(S)?window.innerHeight:window.innerWidth,ve=be?(Ce-aa)/Ce:1,ie=be?-16:0;be&&tt(I.current,{transition:`transform ${ze.DURATION}s cubic-bezier(${ze.EASE.join(",")})`,transform:Xe(S)?`scale(${ve}) translate3d(0, ${ie}px, 0)`:`scale(${ve}) translate3d(${ie}px, 0, 0)`})}return E.useEffect(()=>{v||window.requestAnimationFrame(()=>{document.body.style.pointerEvents="auto"})},[v]),E.createElement(ti,{defaultOpen:_,onOpenChange:ue=>{!p&&!ue||(ue?H(!0):Ke(!0),O(ue))},open:$},E.createElement(vS.Provider,{value:{activeSnapPoint:fe,snapPoints:a,setActiveSnapPoint:Fe,drawerRef:I,overlayRef:F,onOpenChange:t,onPress:ft,onRelease:Vt,onDrag:Ct,dismissible:p,shouldAnimate:V,handleOnly:u,isOpen:$,isDragging:z,shouldFade:Ze,closeDrawer:Ke,onNestedDrag:Er,onNestedOpenChange:pr,onNestedRelease:Mt,keyboardIsOpen:ne,modal:v,snapPointsOffset:Oe,activeSnapPointIndex:Ee,direction:S,shouldScaleBackground:i,setBackgroundColorOnScale:s,noBodyStyles:w,container:j,autoFocus:L}},r))}const ES=E.forwardRef(function({...e},t){const{overlayRef:r,snapPoints:n,onRelease:o,shouldFade:a,isOpen:i,modal:s,shouldAnimate:c}=jo(),l=xS(t,r),p=n&&n.length>0;if(!s)return null;const u=E.useCallback(m=>o(m),[o]);return E.createElement(xn,{onMouseUp:u,ref:l,"data-vaul-overlay":"","data-vaul-snap-points":i&&p?"true":"false","data-vaul-snap-points-overlay":i&&a?"true":"false","data-vaul-animate":c!=null&&c.current?"true":"false",...e})});ES.displayName="Drawer.Overlay";const PS=E.forwardRef(function({onPointerDownOutside:e,style:t,onOpenAutoFocus:r,...n},o){const{drawerRef:a,onPress:i,onRelease:s,onDrag:c,keyboardIsOpen:l,snapPointsOffset:p,activeSnapPointIndex:u,modal:m,isOpen:b,direction:g,snapPoints:h,container:v,handleOnly:y,shouldAnimate:x,autoFocus:w}=jo(),[S,_]=E.useState(!1),R=xS(o,a),C=E.useRef(null),A=E.useRef(null),P=E.useRef(!1),k=h&&h.length>0;dF();const j=(N,D,$=0)=>{if(P.current)return!0;const O=Math.abs(N.y),G=Math.abs(N.x),H=G>O,z=["bottom","right"].includes(D)?1:-1;if(D==="left"||D==="right"){if(!(N.x*z<0)&&G>=0&&G<=$)return H}else if(!(N.y*z<0)&&O>=0&&O<=$)return!H;return P.current=!0,!0};E.useEffect(()=>{k&&window.requestAnimationFrame(()=>{_(!0)})},[]);function L(N){C.current=null,P.current=!1,s(N)}return E.createElement(wn,{"data-vaul-drawer-direction":g,"data-vaul-drawer":"","data-vaul-delayed-snap-points":S?"true":"false","data-vaul-snap-points":b&&k?"true":"false","data-vaul-custom-container":v?"true":"false","data-vaul-animate":x!=null&&x.current?"true":"false",...n,ref:R,style:p&&p.length>0?{"--snap-point-height":`${p[u??0]}px`,...t}:t,onPointerDown:N=>{y||(n.onPointerDown==null||n.onPointerDown.call(n,N),C.current={x:N.pageX,y:N.pageY},i(N))},onOpenAutoFocus:N=>{r==null||r(N),w||N.preventDefault()},onPointerDownOutside:N=>{if(e==null||e(N),!m||N.defaultPrevented){N.preventDefault();return}l.current&&(l.current=!1)},onFocusOutside:N=>{if(!m){N.preventDefault();return}},onPointerMove:N=>{if(A.current=N,y||(n.onPointerMove==null||n.onPointerMove.call(n,N),!C.current))return;const D=N.pageY-C.current.y,$=N.pageX-C.current.x,O=N.pointerType==="touch"?10:2;j({x:$,y:D},g,O)?c(N):(Math.abs($)>O||Math.abs(D)>O)&&(C.current=null)},onPointerUp:N=>{n.onPointerUp==null||n.onPointerUp.call(n,N),C.current=null,P.current=!1,s(N)},onPointerOut:N=>{n.onPointerOut==null||n.onPointerOut.call(n,N),L(A.current)},onContextMenu:N=>{n.onContextMenu==null||n.onContextMenu.call(n,N),A.current&&L(A.current)}})});PS.displayName="Drawer.Content";const mF=250,hF=120,gF=E.forwardRef(function({preventCycle:e=!1,children:t,...r},n){const{closeDrawer:o,isDragging:a,snapPoints:i,activeSnapPoint:s,setActiveSnapPoint:c,dismissible:l,handleOnly:p,isOpen:u,onPress:m,onDrag:b}=jo(),g=E.useRef(null),h=E.useRef(!1);function v(){if(h.current){w();return}window.setTimeout(()=>{y()},hF)}function y(){if(a||e||h.current){w();return}if(w(),!i||i.length===0){l||o();return}if(s===i[i.length-1]&&l){o();return}const _=i.findIndex(C=>C===s);if(_===-1)return;const R=i[_+1];c(R)}function x(){g.current=window.setTimeout(()=>{h.current=!0},mF)}function w(){g.current&&window.clearTimeout(g.current),h.current=!1}return E.createElement("div",{onClick:v,onPointerCancel:w,onPointerDown:S=>{p&&m(S),x()},onPointerMove:S=>{p&&b(S)},ref:n,"data-vaul-drawer-visible":u?"true":"false","data-vaul-handle":"","aria-hidden":"true",...r},E.createElement("span",{"data-vaul-handle-hitarea":"","aria-hidden":"true"},t))});gF.displayName="Drawer.Handle";function vF(e){const t=jo(),{container:r=t.container,...n}=e;return E.createElement(ni,{container:r,...n})}const Ht={Root:pF,Content:PS,Overlay:ES,Trigger:ri,Portal:vF,Close:qr,Title:Sn,Description:Cn},TS=({shouldScaleBackground:e=!0,...t})=>f.jsx(Ht.Root,{shouldScaleBackground:e,...t});TS.displayName="Drawer";const bF=Ht.Trigger,NS=Ht.Portal,yF=Ht.Close,Uf=d.forwardRef(({className:e,...t},r)=>f.jsx(Ht.Overlay,{ref:r,className:M("fixed inset-0 z-50 bg-black/80",e),...t}));Uf.displayName=Ht.Overlay.displayName;const AS=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(NS,{children:[f.jsx(Uf,{}),f.jsxs(Ht.Content,{ref:n,className:M("fixed inset-x-0 bottom-0 z-50 mt-24 flex h-auto flex-col rounded-t-[10px] border bg-background",e),...r,children:[f.jsx("div",{className:"mx-auto mt-4 h-2 w-[100px] rounded-full bg-muted"}),t]})]}));AS.displayName="DrawerContent";const MS=({className:e,...t})=>f.jsx("div",{className:M("grid gap-1.5 p-4 text-center sm:text-left",e),...t});MS.displayName="DrawerHeader";const OS=({className:e,...t})=>f.jsx("div",{className:M("mt-auto flex flex-col gap-2 p-4",e),...t});OS.displayName="DrawerFooter";const IS=d.forwardRef(({className:e,...t},r)=>f.jsx(Ht.Title,{ref:r,className:M("text-lg font-semibold leading-none tracking-tight",e),...t}));IS.displayName=Ht.Title.displayName;const jS=d.forwardRef(({className:e,...t},r)=>f.jsx(Ht.Description,{ref:r,className:M("text-sm text-muted-foreground",e),...t}));jS.displayName=Ht.Description.displayName;var Wf="DropdownMenu",[xF,r3]=De(Wf,[Mo]),ut=Mo(),[wF,DS]=xF(Wf),kS=e=>{const{__scopeDropdownMenu:t,children:r,dir:n,open:o,defaultOpen:a,onOpenChange:i,modal:s=!0}=e,c=ut(t),l=d.useRef(null),[p=!1,u]=$e({prop:o,defaultProp:a,onChange:i});return f.jsx(wF,{scope:t,triggerId:Ue(),triggerRef:l,contentId:Ue(),open:p,onOpenChange:u,onOpenToggle:d.useCallback(()=>u(m=>!m),[u]),modal:s,children:f.jsx(Pf,{...c,open:p,onOpenChange:u,dir:n,modal:s,children:r})})};kS.displayName=Wf;var $S="DropdownMenuTrigger",LS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,disabled:n=!1,...o}=e,a=DS($S,r),i=ut(r);return f.jsx(Tf,{asChild:!0,...i,children:f.jsx(X.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":n?"":void 0,disabled:n,...o,ref:go(t,a.triggerRef),onPointerDown:B(e.onPointerDown,s=>{!n&&s.button===0&&s.ctrlKey===!1&&(a.onOpenToggle(),a.open||s.preventDefault())}),onKeyDown:B(e.onKeyDown,s=>{n||(["Enter"," "].includes(s.key)&&a.onOpenToggle(),s.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});LS.displayName=$S;var SF="DropdownMenuPortal",FS=e=>{const{__scopeDropdownMenu:t,...r}=e,n=ut(t);return f.jsx(Nf,{...n,...r})};FS.displayName=SF;var BS="DropdownMenuContent",zS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=DS(BS,r),a=ut(r),i=d.useRef(!1);return f.jsx(Af,{id:o.contentId,"aria-labelledby":o.triggerId,...a,...n,ref:t,onCloseAutoFocus:B(e.onCloseAutoFocus,s=>{var c;i.current||(c=o.triggerRef.current)==null||c.focus(),i.current=!1,s.preventDefault()}),onInteractOutside:B(e.onInteractOutside,s=>{const c=s.detail.originalEvent,l=c.button===0&&c.ctrlKey===!0,p=c.button===2||l;(!o.modal||p)&&(i.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});zS.displayName=BS;var CF="DropdownMenuGroup",qS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(Mf,{...o,...n,ref:t})});qS.displayName=CF;var _F="DropdownMenuLabel",HS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(Of,{...o,...n,ref:t})});HS.displayName=_F;var RF="DropdownMenuItem",VS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(If,{...o,...n,ref:t})});VS.displayName=RF;var EF="DropdownMenuCheckboxItem",GS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(jf,{...o,...n,ref:t})});GS.displayName=EF;var PF="DropdownMenuRadioGroup",US=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(Df,{...o,...n,ref:t})});US.displayName=PF;var TF="DropdownMenuRadioItem",WS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(kf,{...o,...n,ref:t})});WS.displayName=TF;var NF="DropdownMenuItemIndicator",KS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx($f,{...o,...n,ref:t})});KS.displayName=NF;var AF="DropdownMenuSeparator",YS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(Lf,{...o,...n,ref:t})});YS.displayName=AF;var MF="DropdownMenuArrow",OF=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(Ff,{...o,...n,ref:t})});OF.displayName=MF;var IF=e=>{const{__scopeDropdownMenu:t,children:r,open:n,onOpenChange:o,defaultOpen:a}=e,i=ut(t),[s=!1,c]=$e({prop:n,defaultProp:a,onChange:o});return f.jsx(Bf,{...i,open:s,onOpenChange:c,children:r})},jF="DropdownMenuSubTrigger",XS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(zf,{...o,...n,ref:t})});XS.displayName=jF;var DF="DropdownMenuSubContent",ZS=d.forwardRef((e,t)=>{const{__scopeDropdownMenu:r,...n}=e,o=ut(r);return f.jsx(qf,{...o,...n,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});ZS.displayName=DF;var kF=kS,$F=LS,JS=FS,QS=zS,LF=qS,eC=HS,tC=VS,rC=GS,FF=US,nC=WS,oC=KS,aC=YS,BF=IF,iC=XS,sC=ZS;const cC=kF,lC=$F,zF=LF,qF=JS,HF=BF,VF=FF,uC=d.forwardRef(({className:e,inset:t,children:r,...n},o)=>f.jsxs(iC,{ref:o,className:M("flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...n,children:[r,f.jsx(Dr,{className:"ml-auto"})]}));uC.displayName=iC.displayName;const dC=d.forwardRef(({className:e,...t},r)=>f.jsx(sC,{ref:r,className:M("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-dropdown-menu-content-transform-origin]",e),...t}));dC.displayName=sC.displayName;const Kf=d.forwardRef(({className:e,sideOffset:t=4,...r},n)=>f.jsx(JS,{children:f.jsx(QS,{ref:n,sideOffset:t,className:M("z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-dropdown-menu-content-transform-origin]",e),...r})}));Kf.displayName=QS.displayName;const Yf=d.forwardRef(({className:e,inset:t,...r},n)=>f.jsx(tC,{ref:n,className:M("relative flex cursor-default select-none items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&>svg]:size-4 [&>svg]:shrink-0",t&&"pl-8",e),...r}));Yf.displayName=tC.displayName;const fC=d.forwardRef(({className:e,children:t,checked:r,...n},o)=>f.jsxs(rC,{ref:o,className:M("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:r,...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(oC,{children:f.jsx(vo,{className:"h-4 w-4"})})}),t]}));fC.displayName=rC.displayName;const pC=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(nC,{ref:n,className:M("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(oC,{children:f.jsx(Za,{className:"h-2 w-2 fill-current"})})}),t]}));pC.displayName=nC.displayName;const mC=d.forwardRef(({className:e,inset:t,...r},n)=>f.jsx(eC,{ref:n,className:M("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...r}));mC.displayName=eC.displayName;const hC=d.forwardRef(({className:e,...t},r)=>f.jsx(aC,{ref:r,className:M("-mx-1 my-1 h-px bg-muted",e),...t}));hC.displayName=aC.displayName;const gC=({className:e,...t})=>f.jsx("span",{className:M("ml-auto text-xs tracking-widest opacity-60",e),...t});gC.displayName="DropdownMenuShortcut";var GF=e=>e.type==="checkbox",UF=e=>e instanceof Date,vC=e=>e==null;const WF=e=>typeof e=="object";var Nn=e=>!vC(e)&&!Array.isArray(e)&&WF(e)&&!UF(e),KF=e=>Nn(e)&&e.target?GF(e.target)?e.target.checked:e.target.value:e,YF=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,XF=(e,t)=>e.has(YF(t)),ZF=e=>{const t=e.constructor&&e.constructor.prototype;return Nn(t)&&t.hasOwnProperty("isPrototypeOf")},JF=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Xf(e){let t;const r=Array.isArray(e),n=typeof FileList<"u"?e instanceof FileList:!1;if(e instanceof Date)t=new Date(e);else if(e instanceof Set)t=new Set(e);else if(!(JF&&(e instanceof Blob||n))&&(r||Nn(e)))if(t=r?[]:{},!r&&!ZF(e))t=e;else for(const o in e)e.hasOwnProperty(o)&&(t[o]=Xf(e[o]));else return e;return t}var bC=e=>Array.isArray(e)?e.filter(Boolean):[],Uu=e=>e===void 0,vt=(e,t,r)=>{if(!t||!Nn(e))return r;const n=bC(t.split(/[,[\].]+?/)).reduce((o,a)=>vC(o)?o:o[a],e);return Uu(n)||n===e?Uu(e[t])?r:e[t]:n},ob=e=>typeof e=="boolean",QF=e=>/^\w*$/.test(e),eB=e=>bC(e.replace(/["|']|\]/g,"").split(/\.|\[/)),ab=(e,t,r)=>{let n=-1;const o=QF(t)?[t]:eB(t),a=o.length,i=a-1;for(;++n<a;){const s=o[n];let c=r;if(n!==i){const l=e[s];c=Nn(l)||Array.isArray(l)?l:isNaN(+o[n+1])?{}:[]}if(s==="__proto__"||s==="constructor"||s==="prototype")return;e[s]=c,e=e[s]}return e};const ib={BLUR:"blur",CHANGE:"change"},sb={all:"all"},yC=E.createContext(null),Ri=()=>E.useContext(yC),tB=e=>{const{children:t,...r}=e;return E.createElement(yC.Provider,{value:r},t)};var rB=(e,t,r,n=!0)=>{const o={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(o,a,{get:()=>{const i=a;return t._proxyFormState[i]!==sb.all&&(t._proxyFormState[i]=!n||sb.all),r&&(r[i]=!0),e[i]}});return o},nB=e=>Nn(e)&&!Object.keys(e).length,oB=(e,t,r,n)=>{r(e);const{name:o,...a}=e;return nB(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(i=>t[i]===!0)},aB=e=>Array.isArray(e)?e:[e],xC=(e,t,r)=>!e||!t||e===t||aB(e).some(n=>n&&(r?n===t:n.startsWith(t)||t.startsWith(n)));function wC(e){const t=E.useRef(e);t.current=e,E.useEffect(()=>{const r=!e.disabled&&t.current.subject&&t.current.subject.subscribe({next:t.current.next});return()=>{r&&r.unsubscribe()}},[e.disabled])}function iB(e){const t=Ri(),{control:r=t.control,disabled:n,name:o,exact:a}=e||{},[i,s]=E.useState(r._formState),c=E.useRef(!0),l=E.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),p=E.useRef(o);return p.current=o,wC({disabled:n,next:u=>c.current&&xC(p.current,u.name,a)&&oB(u,l.current,r._updateFormState)&&s({...r._formState,...u}),subject:r._subjects.state}),E.useEffect(()=>(c.current=!0,l.current.isValid&&r._updateValid(!0),()=>{c.current=!1}),[r]),E.useMemo(()=>rB(i,r,l.current,!1),[i,r])}var sB=e=>typeof e=="string",cB=(e,t,r,n,o)=>sB(e)?vt(r,e,o):Array.isArray(e)?e.map(a=>vt(r,a)):r;function lB(e){const t=Ri(),{control:r=t.control,name:n,defaultValue:o,disabled:a,exact:i}=e||{},s=E.useRef(n);s.current=n,wC({disabled:a,subject:r._subjects.values,next:p=>{xC(s.current,p.name,i)&&l(Xf(cB(s.current,r._names,p.values||r._formValues,!1,o)))}});const[c,l]=E.useState(r._getWatch(n,o));return E.useEffect(()=>r._removeUnmounted()),c}function uB(e){const t=Ri(),{name:r,disabled:n,control:o=t.control,shouldUnregister:a}=e,i=XF(o._names.array,r),s=lB({control:o,name:r,defaultValue:vt(o._formValues,r,vt(o._defaultValues,r,e.defaultValue)),exact:!0}),c=iB({control:o,name:r,exact:!0}),l=E.useRef(o.register(r,{...e.rules,value:s,...ob(e.disabled)?{disabled:e.disabled}:{}})),p=E.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!vt(c.errors,r)},isDirty:{enumerable:!0,get:()=>!!vt(c.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!vt(c.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!vt(c.validatingFields,r)},error:{enumerable:!0,get:()=>vt(c.errors,r)}}),[c,r]),u=E.useMemo(()=>({name:r,value:s,...ob(n)||c.disabled?{disabled:c.disabled||n}:{},onChange:m=>l.current.onChange({target:{value:KF(m),name:r},type:ib.CHANGE}),onBlur:()=>l.current.onBlur({target:{value:vt(o._formValues,r),name:r},type:ib.BLUR}),ref:m=>{const b=vt(o._fields,r);b&&m&&(b._f.ref={focus:()=>m.focus(),select:()=>m.select(),setCustomValidity:g=>m.setCustomValidity(g),reportValidity:()=>m.reportValidity()})}}),[r,o._formValues,n,c.disabled,s,o._fields]);return E.useEffect(()=>{const m=o._options.shouldUnregister||a,b=(g,h)=>{const v=vt(o._fields,g);v&&v._f&&(v._f.mount=h)};if(b(r,!0),m){const g=Xf(vt(o._options.defaultValues,r));ab(o._defaultValues,r,g),Uu(vt(o._formValues,r))&&ab(o._formValues,r,g)}return!i&&o.register(r),()=>{(i?m&&!o._state.action:m)?o.unregister(r):b(r,!1)}},[r,o,i,a]),E.useEffect(()=>{o._updateDisabledField({disabled:n,fields:o._fields,name:r})},[n,r,o]),E.useMemo(()=>({field:u,formState:c,fieldState:p}),[u,c,p])}const dB=e=>e.render(uB(e));var fB="Label",SC=d.forwardRef((e,t)=>f.jsx(X.label,{...e,ref:t,onMouseDown:r=>{var o;r.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,r),!r.defaultPrevented&&r.detail>1&&r.preventDefault())}}));SC.displayName=fB;var CC=SC;const pB=fr("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),lo=d.forwardRef(({className:e,...t},r)=>f.jsx(CC,{ref:r,className:M(pB(),e),...t}));lo.displayName=CC.displayName;const mB=tB,_C=d.createContext({}),hB=({...e})=>f.jsx(_C.Provider,{value:{name:e.name},children:f.jsx(dB,{...e})}),Do=()=>{const e=d.useContext(_C),t=d.useContext(RC),{getFieldState:r,formState:n}=Ri(),o=r(e.name,n);if(!e)throw new Error("useFormField should be used within <FormField>");const{id:a}=t;return{id:a,name:e.name,formItemId:`${a}-form-item`,formDescriptionId:`${a}-form-item-description`,formMessageId:`${a}-form-item-message`,...o}},RC=d.createContext({}),EC=d.forwardRef(({className:e,...t},r)=>{const n=d.useId();return f.jsx(RC.Provider,{value:{id:n},children:f.jsx("div",{ref:r,className:M("space-y-2",e),...t})})});EC.displayName="FormItem";const PC=d.forwardRef(({className:e,...t},r)=>{const{error:n,formItemId:o}=Do();return f.jsx(lo,{ref:r,className:M(n&&"text-destructive",e),htmlFor:o,...t})});PC.displayName="FormLabel";const TC=d.forwardRef(({...e},t)=>{const{error:r,formItemId:n,formDescriptionId:o,formMessageId:a}=Do();return f.jsx(st,{ref:t,id:n,"aria-describedby":r?`${o} ${a}`:`${o}`,"aria-invalid":!!r,...e})});TC.displayName="FormControl";const NC=d.forwardRef(({className:e,...t},r)=>{const{formDescriptionId:n}=Do();return f.jsx("p",{ref:r,id:n,className:M("text-[0.8rem] text-muted-foreground",e),...t})});NC.displayName="FormDescription";const AC=d.forwardRef(({className:e,children:t,...r},n)=>{const{error:o,formMessageId:a}=Do(),i=o?String((o==null?void 0:o.message)??""):t;return i?f.jsx("p",{ref:n,id:a,className:M("text-[0.8rem] font-medium text-destructive",e),...r,children:i}):null});AC.displayName="FormMessage";var lu,Zf="HoverCard",[MC,n3]=De(Zf,[Jt]),Ei=Jt(),[gB,Jf]=MC(Zf),OC=e=>{const{__scopeHoverCard:t,children:r,open:n,defaultOpen:o,onOpenChange:a,openDelay:i=700,closeDelay:s=300}=e,c=Ei(t),l=d.useRef(0),p=d.useRef(0),u=d.useRef(!1),m=d.useRef(!1),[b=!1,g]=$e({prop:n,defaultProp:o,onChange:a}),h=d.useCallback(()=>{clearTimeout(p.current),l.current=window.setTimeout(()=>g(!0),i)},[i,g]),v=d.useCallback(()=>{clearTimeout(l.current),!u.current&&!m.current&&(p.current=window.setTimeout(()=>g(!1),s))},[s,g]),y=d.useCallback(()=>g(!1),[g]);return d.useEffect(()=>()=>{clearTimeout(l.current),clearTimeout(p.current)},[]),f.jsx(gB,{scope:t,open:b,onOpenChange:g,onOpen:h,onClose:v,onDismiss:y,hasSelectionRef:u,isPointerDownOnContentRef:m,children:f.jsx(Pn,{...c,children:r})})};OC.displayName=Zf;var IC="HoverCardTrigger",jC=d.forwardRef((e,t)=>{const{__scopeHoverCard:r,...n}=e,o=Jf(IC,r),a=Ei(r);return f.jsx(Tn,{asChild:!0,...a,children:f.jsx(X.a,{"data-state":o.open?"open":"closed",...n,ref:t,onPointerEnter:B(e.onPointerEnter,$a(o.onOpen)),onPointerLeave:B(e.onPointerLeave,$a(o.onClose)),onFocus:B(e.onFocus,o.onOpen),onBlur:B(e.onBlur,o.onClose),onTouchStart:B(e.onTouchStart,i=>i.preventDefault())})})});jC.displayName=IC;var vB="HoverCardPortal",[o3,bB]=MC(vB,{forceMount:void 0}),ka="HoverCardContent",DC=d.forwardRef((e,t)=>{const r=bB(ka,e.__scopeHoverCard),{forceMount:n=r.forceMount,...o}=e,a=Jf(ka,e.__scopeHoverCard);return f.jsx(Le,{present:n||a.open,children:f.jsx(yB,{"data-state":a.open?"open":"closed",...o,onPointerEnter:B(e.onPointerEnter,$a(a.onOpen)),onPointerLeave:B(e.onPointerLeave,$a(a.onClose)),ref:t})})});DC.displayName=ka;var yB=d.forwardRef((e,t)=>{const{__scopeHoverCard:r,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:i,...s}=e,c=Jf(ka,r),l=Ei(r),p=d.useRef(null),u=de(t,p),[m,b]=d.useState(!1);return d.useEffect(()=>{if(m){const g=document.body;return lu=g.style.userSelect||g.style.webkitUserSelect,g.style.userSelect="none",g.style.webkitUserSelect="none",()=>{g.style.userSelect=lu,g.style.webkitUserSelect=lu}}},[m]),d.useEffect(()=>{if(p.current){const g=()=>{b(!1),c.isPointerDownOnContentRef.current=!1,setTimeout(()=>{var v;((v=document.getSelection())==null?void 0:v.toString())!==""&&(c.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",g),()=>{document.removeEventListener("pointerup",g),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!1}}},[c.isPointerDownOnContentRef,c.hasSelectionRef]),d.useEffect(()=>{p.current&&SB(p.current).forEach(h=>h.setAttribute("tabindex","-1"))}),f.jsx(ur,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:i,onEscapeKeyDown:n,onPointerDownOutside:o,onFocusOutside:B(a,g=>{g.preventDefault()}),onDismiss:c.onDismiss,children:f.jsx(Eo,{...l,...s,onPointerDown:B(s.onPointerDown,g=>{g.currentTarget.contains(g.target)&&b(!0),c.hasSelectionRef.current=!1,c.isPointerDownOnContentRef.current=!0}),ref:u,style:{...s.style,userSelect:m?"text":void 0,WebkitUserSelect:m?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),xB="HoverCardArrow",wB=d.forwardRef((e,t)=>{const{__scopeHoverCard:r,...n}=e,o=Ei(r);return f.jsx(Po,{...o,...n,ref:t})});wB.displayName=xB;function $a(e){return t=>t.pointerType==="touch"?void 0:e()}function SB(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;r.nextNode();)t.push(r.currentNode);return t}var CB=OC,_B=jC,kC=DC;const RB=CB,EB=_B,$C=d.forwardRef(({className:e,align:t="center",sideOffset:r=4,...n},o)=>f.jsx(kC,{ref:o,align:t,sideOffset:r,className:M("z-50 w-64 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-hover-card-content-transform-origin]",e),...n}));$C.displayName=kC.displayName;var PB=Object.defineProperty,TB=Object.defineProperties,NB=Object.getOwnPropertyDescriptors,La=Object.getOwnPropertySymbols,LC=Object.prototype.hasOwnProperty,FC=Object.prototype.propertyIsEnumerable,cb=(e,t,r)=>t in e?PB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,AB=(e,t)=>{for(var r in t||(t={}))LC.call(t,r)&&cb(e,r,t[r]);if(La)for(var r of La(t))FC.call(t,r)&&cb(e,r,t[r]);return e},MB=(e,t)=>TB(e,NB(t)),OB=(e,t)=>{var r={};for(var n in e)LC.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&La)for(var n of La(e))t.indexOf(n)<0&&FC.call(e,n)&&(r[n]=e[n]);return r};function IB(e){let t=setTimeout(e,0),r=setTimeout(e,10),n=setTimeout(e,50);return[t,r,n]}function jB(e){let t=d.useRef();return d.useEffect(()=>{t.current=e}),t.current}var DB=18,BC=40,kB=`${BC}px`,$B=["[data-lastpass-icon-root]","com-1password-button","[data-dashlanecreated]",'[style$="2147483647 !important;"]'].join(",");function LB({containerRef:e,inputRef:t,pushPasswordManagerStrategy:r,isFocused:n}){let[o,a]=d.useState(!1),[i,s]=d.useState(!1),[c,l]=d.useState(!1),p=d.useMemo(()=>r==="none"?!1:(r==="increase-width"||r==="experimental-no-flickering")&&o&&i,[o,i,r]),u=d.useCallback(()=>{let m=e.current,b=t.current;if(!m||!b||c||r==="none")return;let g=m,h=g.getBoundingClientRect().left+g.offsetWidth,v=g.getBoundingClientRect().top+g.offsetHeight/2,y=h-DB,x=v;document.querySelectorAll($B).length===0&&document.elementFromPoint(y,x)===m||(a(!0),l(!0))},[e,t,c,r]);return d.useEffect(()=>{let m=e.current;if(!m||r==="none")return;function b(){let h=window.innerWidth-m.getBoundingClientRect().right;s(h>=BC)}b();let g=setInterval(b,1e3);return()=>{clearInterval(g)}},[e,r]),d.useEffect(()=>{let m=n||document.activeElement===t.current;if(r==="none"||!m)return;let b=setTimeout(u,0),g=setTimeout(u,2e3),h=setTimeout(u,5e3),v=setTimeout(()=>{l(!0)},6e3);return()=>{clearTimeout(b),clearTimeout(g),clearTimeout(h),clearTimeout(v)}},[t,n,r,u]),{hasPWMBadge:o,willPushPWMBadge:p,PWM_BADGE_SPACE_WIDTH:kB}}var zC=d.createContext({}),qC=d.forwardRef((e,t)=>{var r=e,{value:n,onChange:o,maxLength:a,textAlign:i="left",pattern:s,placeholder:c,inputMode:l="numeric",onComplete:p,pushPasswordManagerStrategy:u="increase-width",pasteTransformer:m,containerClassName:b,noScriptCSSFallback:g=FB,render:h,children:v}=r,y=OB(r,["value","onChange","maxLength","textAlign","pattern","placeholder","inputMode","onComplete","pushPasswordManagerStrategy","pasteTransformer","containerClassName","noScriptCSSFallback","render","children"]),x,w,S,_,R;let[C,A]=d.useState(typeof y.defaultValue=="string"?y.defaultValue:""),P=n??C,k=jB(P),j=d.useCallback(I=>{o==null||o(I),A(I)},[o]),L=d.useMemo(()=>s?typeof s=="string"?new RegExp(s):s:null,[s]),N=d.useRef(null),D=d.useRef(null),$=d.useRef({value:P,onChange:j,isIOS:typeof window<"u"&&((w=(x=window==null?void 0:window.CSS)==null?void 0:x.supports)==null?void 0:w.call(x,"-webkit-touch-callout","none"))}),O=d.useRef({prev:[(S=N.current)==null?void 0:S.selectionStart,(_=N.current)==null?void 0:_.selectionEnd,(R=N.current)==null?void 0:R.selectionDirection]});d.useImperativeHandle(t,()=>N.current,[]),d.useEffect(()=>{let I=N.current,ee=D.current;if(!I||!ee)return;$.current.value!==I.value&&$.current.onChange(I.value),O.current.prev=[I.selectionStart,I.selectionEnd,I.selectionDirection];function pe(){if(document.activeElement!==I){te(null),U(null);return}let fe=I.selectionStart,Ee=I.selectionEnd,Fe=I.selectionDirection,we=I.maxLength,Oe=I.value,rt=O.current.prev,Ze=-1,We=-1,ot;if(Oe.length!==0&&fe!==null&&Ee!==null){let Ct=fe===Ee,Ke=fe===Oe.length&&Oe.length<we;if(Ct&&!Ke){let Je=fe;if(Je===0)Ze=0,We=1,ot="forward";else if(Je===we)Ze=Je-1,We=Je,ot="backward";else if(we>1&&Oe.length>1){let At=0;if(rt[0]!==null&&rt[1]!==null){ot=Je<rt[1]?"backward":"forward";let Vt=rt[0]===rt[1]&&rt[0]<we;ot==="backward"&&!Vt&&(At=-1)}Ze=At+Je,We=At+Je+1}}Ze!==-1&&We!==-1&&Ze!==We&&N.current.setSelectionRange(Ze,We,ot)}let mt=Ze!==-1?Ze:fe,ft=We!==-1?We:Ee,Ve=ot??Fe;te(mt),U(ft),O.current.prev=[mt,ft,Ve]}if(document.addEventListener("selectionchange",pe,{capture:!0}),pe(),document.activeElement===I&&oe(!0),!document.getElementById("input-otp-style")){let fe=document.createElement("style");if(fe.id="input-otp-style",document.head.appendChild(fe),fe.sheet){let Ee="background: transparent !important; color: transparent !important; border-color: transparent !important; opacity: 0 !important; box-shadow: none !important; -webkit-box-shadow: none !important; -webkit-text-fill-color: transparent !important;";Fn(fe.sheet,"[data-input-otp]::selection { background: transparent !important; color: transparent !important; }"),Fn(fe.sheet,`[data-input-otp]:autofill { ${Ee} }`),Fn(fe.sheet,`[data-input-otp]:-webkit-autofill { ${Ee} }`),Fn(fe.sheet,"@supports (-webkit-touch-callout: none) { [data-input-otp] { letter-spacing: -.6em !important; font-weight: 100 !important; font-stretch: ultra-condensed; font-optical-sizing: none !important; left: -1px !important; right: 1px !important; } }"),Fn(fe.sheet,"[data-input-otp] + * { pointer-events: all !important; }")}}let me=()=>{ee&&ee.style.setProperty("--root-height",`${I.clientHeight}px`)};me();let ge=new ResizeObserver(me);return ge.observe(I),()=>{document.removeEventListener("selectionchange",pe,{capture:!0}),ge.disconnect()}},[]);let[G,H]=d.useState(!1),[z,oe]=d.useState(!1),[Z,te]=d.useState(null),[F,U]=d.useState(null);d.useEffect(()=>{IB(()=>{var I,ee,pe,me;(I=N.current)==null||I.dispatchEvent(new Event("input"));let ge=(ee=N.current)==null?void 0:ee.selectionStart,fe=(pe=N.current)==null?void 0:pe.selectionEnd,Ee=(me=N.current)==null?void 0:me.selectionDirection;ge!==null&&fe!==null&&(te(ge),U(fe),O.current.prev=[ge,fe,Ee])})},[P,z]),d.useEffect(()=>{k!==void 0&&P!==k&&k.length<a&&P.length===a&&(p==null||p(P))},[a,p,k,P]);let Q=LB({containerRef:D,inputRef:N,pushPasswordManagerStrategy:u,isFocused:z}),K=d.useCallback(I=>{let ee=I.currentTarget.value.slice(0,a);if(ee.length>0&&L&&!L.test(ee)){I.preventDefault();return}typeof k=="string"&&ee.length<k.length&&document.dispatchEvent(new Event("selectionchange")),j(ee)},[a,j,k,L]),q=d.useCallback(()=>{var I;if(N.current){let ee=Math.min(N.current.value.length,a-1),pe=N.current.value.length;(I=N.current)==null||I.setSelectionRange(ee,pe),te(ee),U(pe)}oe(!0)},[a]),W=d.useCallback(I=>{var ee,pe;let me=N.current;if(!m&&(!$.current.isIOS||!I.clipboardData||!me))return;let ge=I.clipboardData.getData("text/plain"),fe=m?m(ge):ge;I.preventDefault();let Ee=(ee=N.current)==null?void 0:ee.selectionStart,Fe=(pe=N.current)==null?void 0:pe.selectionEnd,we=(Ee!==Fe?P.slice(0,Ee)+fe+P.slice(Fe):P.slice(0,Ee)+fe+P.slice(Ee)).slice(0,a);if(we.length>0&&L&&!L.test(we))return;me.value=we,j(we);let Oe=Math.min(we.length,a-1),rt=we.length;me.setSelectionRange(Oe,rt),te(Oe),U(rt)},[a,j,L,P]),re=d.useMemo(()=>({position:"relative",cursor:y.disabled?"default":"text",userSelect:"none",WebkitUserSelect:"none",pointerEvents:"none"}),[y.disabled]),J=d.useMemo(()=>({position:"absolute",inset:0,width:Q.willPushPWMBadge?`calc(100% + ${Q.PWM_BADGE_SPACE_WIDTH})`:"100%",clipPath:Q.willPushPWMBadge?`inset(0 ${Q.PWM_BADGE_SPACE_WIDTH} 0 0)`:void 0,height:"100%",display:"flex",textAlign:i,opacity:"1",color:"transparent",pointerEvents:"all",background:"transparent",caretColor:"transparent",border:"0 solid transparent",outline:"0 solid transparent",boxShadow:"none",lineHeight:"1",letterSpacing:"-.5em",fontSize:"var(--root-height)",fontFamily:"monospace",fontVariantNumeric:"tabular-nums"}),[Q.PWM_BADGE_SPACE_WIDTH,Q.willPushPWMBadge,i]),ne=d.useMemo(()=>d.createElement("input",MB(AB({autoComplete:y.autoComplete||"one-time-code"},y),{"data-input-otp":!0,"data-input-otp-placeholder-shown":P.length===0||void 0,"data-input-otp-mss":Z,"data-input-otp-mse":F,inputMode:l,pattern:L==null?void 0:L.source,"aria-placeholder":c,style:J,maxLength:a,value:P,ref:N,onPaste:I=>{var ee;W(I),(ee=y.onPaste)==null||ee.call(y,I)},onChange:K,onMouseOver:I=>{var ee;H(!0),(ee=y.onMouseOver)==null||ee.call(y,I)},onMouseLeave:I=>{var ee;H(!1),(ee=y.onMouseLeave)==null||ee.call(y,I)},onFocus:I=>{var ee;q(),(ee=y.onFocus)==null||ee.call(y,I)},onBlur:I=>{var ee;oe(!1),(ee=y.onBlur)==null||ee.call(y,I)}})),[K,q,W,l,J,a,F,Z,y,L==null?void 0:L.source,P]),V=d.useMemo(()=>({slots:Array.from({length:a}).map((I,ee)=>{var pe;let me=z&&Z!==null&&F!==null&&(Z===F&&ee===Z||ee>=Z&&ee<F),ge=P[ee]!==void 0?P[ee]:null,fe=P[0]!==void 0?null:(pe=c==null?void 0:c[ee])!=null?pe:null;return{char:ge,placeholderChar:fe,isActive:me,hasFakeCaret:me&&ge===null}}),isFocused:z,isHovering:!y.disabled&&G}),[z,G,a,F,Z,y.disabled,P]),ae=d.useMemo(()=>h?h(V):d.createElement(zC.Provider,{value:V},v),[v,V,h]);return d.createElement(d.Fragment,null,g!==null&&d.createElement("noscript",null,d.createElement("style",null,g)),d.createElement("div",{ref:D,"data-input-otp-container":!0,style:re,className:b},ae,d.createElement("div",{style:{position:"absolute",inset:0,pointerEvents:"none"}},ne)))});qC.displayName="Input";function Fn(e,t){try{e.insertRule(t)}catch{console.error("input-otp could not insert CSS rule:",t)}}var FB=`
|
|
214
|
+
[data-input-otp] {
|
|
215
|
+
--nojs-bg: white !important;
|
|
216
|
+
--nojs-fg: black !important;
|
|
217
|
+
|
|
218
|
+
background-color: var(--nojs-bg) !important;
|
|
219
|
+
color: var(--nojs-fg) !important;
|
|
220
|
+
caret-color: var(--nojs-fg) !important;
|
|
221
|
+
letter-spacing: .25em !important;
|
|
222
|
+
text-align: center !important;
|
|
223
|
+
border: 1px solid var(--nojs-fg) !important;
|
|
224
|
+
border-radius: 4px !important;
|
|
225
|
+
width: 100% !important;
|
|
226
|
+
}
|
|
227
|
+
@media (prefers-color-scheme: dark) {
|
|
228
|
+
[data-input-otp] {
|
|
229
|
+
--nojs-bg: black !important;
|
|
230
|
+
--nojs-fg: white !important;
|
|
231
|
+
}
|
|
232
|
+
}`;const HC=d.forwardRef(({className:e,containerClassName:t,...r},n)=>f.jsx(qC,{ref:n,containerClassName:M("flex items-center gap-2 has-[:disabled]:opacity-50",t),className:M("disabled:cursor-not-allowed",e),...r}));HC.displayName="InputOTP";const VC=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,className:M("flex items-center",e),...t}));VC.displayName="InputOTPGroup";const GC=d.forwardRef(({index:e,className:t,...r},n)=>{const o=d.useContext(zC),{char:a,hasFakeCaret:i,isActive:s}=o.slots[e];return f.jsxs("div",{ref:n,className:M("relative flex h-9 w-9 items-center justify-center border-y border-r border-input text-sm shadow-sm transition-all first:rounded-l-md first:border-l last:rounded-r-md",s&&"z-10 ring-1 ring-ring",t),...r,children:[a,i&&f.jsx("div",{className:"pointer-events-none absolute inset-0 flex items-center justify-center",children:f.jsx("div",{className:"h-4 w-px animate-caret-blink bg-foreground duration-1000"})})]})});GC.displayName="InputOTPSlot";const UC=d.forwardRef(({...e},t)=>f.jsx("div",{ref:t,role:"separator",...e,children:f.jsx(H1,{})}));UC.displayName="InputOTPSeparator";const uo=d.forwardRef(({className:e,type:t,...r},n)=>f.jsx("input",{type:t,className:M("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:n,...r}));uo.displayName="Input";var Pi="Menubar",[Wu,BB,zB]=cr(Pi),[WC,a3]=De(Pi,[zB,Qt]),dt=Mo(),KC=Qt(),[qB,Qf]=WC(Pi),YC=d.forwardRef((e,t)=>{const{__scopeMenubar:r,value:n,onValueChange:o,defaultValue:a,loop:i=!0,dir:s,...c}=e,l=Ft(s),p=KC(r),[u="",m]=$e({prop:n,onChange:o,defaultProp:a}),[b,g]=d.useState(null);return f.jsx(qB,{scope:r,value:u,onMenuOpen:d.useCallback(h=>{m(h),g(h)},[m]),onMenuClose:d.useCallback(()=>m(""),[m]),onMenuToggle:d.useCallback(h=>{m(v=>v?"":h),g(h)},[m]),dir:l,loop:i,children:f.jsx(Wu.Provider,{scope:r,children:f.jsx(Wu.Slot,{scope:r,children:f.jsx(To,{asChild:!0,...p,orientation:"horizontal",loop:i,dir:l,currentTabStopId:b,onCurrentTabStopIdChange:g,children:f.jsx(X.div,{role:"menubar",...c,ref:t})})})})})});YC.displayName=Pi;var ep="MenubarMenu",[HB,XC]=WC(ep),ZC=e=>{const{__scopeMenubar:t,value:r,...n}=e,o=Ue(),a=r||o||"LEGACY_REACT_AUTO_VALUE",i=Qf(ep,t),s=dt(t),c=d.useRef(null),l=d.useRef(!1),p=i.value===a;return d.useEffect(()=>{p||(l.current=!1)},[p]),f.jsx(HB,{scope:t,value:a,triggerId:Ue(),triggerRef:c,contentId:Ue(),wasKeyboardTriggerOpenRef:l,children:f.jsx(Pf,{...s,open:p,onOpenChange:u=>{u||i.onMenuClose()},modal:!1,dir:i.dir,...n})})};ZC.displayName=ep;var Ku="MenubarTrigger",JC=d.forwardRef((e,t)=>{const{__scopeMenubar:r,disabled:n=!1,...o}=e,a=KC(r),i=dt(r),s=Qf(Ku,r),c=XC(Ku,r),l=d.useRef(null),p=de(t,l,c.triggerRef),[u,m]=d.useState(!1),b=s.value===c.value;return f.jsx(Wu.ItemSlot,{scope:r,value:c.value,disabled:n,children:f.jsx(No,{asChild:!0,...a,focusable:!n,tabStopId:c.value,children:f.jsx(Tf,{asChild:!0,...i,children:f.jsx(X.button,{type:"button",role:"menuitem",id:c.triggerId,"aria-haspopup":"menu","aria-expanded":b,"aria-controls":b?c.contentId:void 0,"data-highlighted":u?"":void 0,"data-state":b?"open":"closed","data-disabled":n?"":void 0,disabled:n,...o,ref:p,onPointerDown:B(e.onPointerDown,g=>{!n&&g.button===0&&g.ctrlKey===!1&&(s.onMenuOpen(c.value),b||g.preventDefault())}),onPointerEnter:B(e.onPointerEnter,()=>{var h;!!s.value&&!b&&(s.onMenuOpen(c.value),(h=l.current)==null||h.focus())}),onKeyDown:B(e.onKeyDown,g=>{n||(["Enter"," "].includes(g.key)&&s.onMenuToggle(c.value),g.key==="ArrowDown"&&s.onMenuOpen(c.value),["Enter"," ","ArrowDown"].includes(g.key)&&(c.wasKeyboardTriggerOpenRef.current=!0,g.preventDefault()))}),onFocus:B(e.onFocus,()=>m(!0)),onBlur:B(e.onBlur,()=>m(!1))})})})})});JC.displayName=Ku;var VB="MenubarPortal",QC=e=>{const{__scopeMenubar:t,...r}=e,n=dt(t);return f.jsx(Nf,{...n,...r})};QC.displayName=VB;var Yu="MenubarContent",e_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,align:n="start",...o}=e,a=dt(r),i=Qf(Yu,r),s=XC(Yu,r),c=BB(r),l=d.useRef(!1);return f.jsx(Af,{id:s.contentId,"aria-labelledby":s.triggerId,"data-radix-menubar-content":"",...a,...o,ref:t,align:n,onCloseAutoFocus:B(e.onCloseAutoFocus,p=>{var m;!!!i.value&&!l.current&&((m=s.triggerRef.current)==null||m.focus()),l.current=!1,p.preventDefault()}),onFocusOutside:B(e.onFocusOutside,p=>{const u=p.target;c().some(b=>{var g;return(g=b.ref.current)==null?void 0:g.contains(u)})&&p.preventDefault()}),onInteractOutside:B(e.onInteractOutside,()=>{l.current=!0}),onEntryFocus:p=>{s.wasKeyboardTriggerOpenRef.current||p.preventDefault()},onKeyDown:B(e.onKeyDown,p=>{if(["ArrowRight","ArrowLeft"].includes(p.key)){const u=p.target,m=u.hasAttribute("data-radix-menubar-subtrigger"),b=u.closest("[data-radix-menubar-content]")!==p.currentTarget,h=(i.dir==="rtl"?"ArrowRight":"ArrowLeft")===p.key;if(!h&&m||b&&h)return;let x=c().filter(_=>!_.disabled).map(_=>_.value);h&&x.reverse();const w=x.indexOf(s.value);x=i.loop?oz(x,w+1):x.slice(w+1);const[S]=x;S&&i.onMenuOpen(S)}},{checkForDefaultPrevented:!1}),style:{...e.style,"--radix-menubar-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-menubar-content-available-width":"var(--radix-popper-available-width)","--radix-menubar-content-available-height":"var(--radix-popper-available-height)","--radix-menubar-trigger-width":"var(--radix-popper-anchor-width)","--radix-menubar-trigger-height":"var(--radix-popper-anchor-height)"}})});e_.displayName=Yu;var GB="MenubarGroup",t_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(Mf,{...o,...n,ref:t})});t_.displayName=GB;var UB="MenubarLabel",r_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(Of,{...o,...n,ref:t})});r_.displayName=UB;var WB="MenubarItem",n_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(If,{...o,...n,ref:t})});n_.displayName=WB;var KB="MenubarCheckboxItem",o_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(jf,{...o,...n,ref:t})});o_.displayName=KB;var YB="MenubarRadioGroup",a_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(Df,{...o,...n,ref:t})});a_.displayName=YB;var XB="MenubarRadioItem",i_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(kf,{...o,...n,ref:t})});i_.displayName=XB;var ZB="MenubarItemIndicator",s_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx($f,{...o,...n,ref:t})});s_.displayName=ZB;var JB="MenubarSeparator",c_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(Lf,{...o,...n,ref:t})});c_.displayName=JB;var QB="MenubarArrow",ez=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(Ff,{...o,...n,ref:t})});ez.displayName=QB;var tz="MenubarSub",l_=e=>{const{__scopeMenubar:t,children:r,open:n,onOpenChange:o,defaultOpen:a}=e,i=dt(t),[s=!1,c]=$e({prop:n,defaultProp:a,onChange:o});return f.jsx(Bf,{...i,open:s,onOpenChange:c,children:r})};l_.displayName=tz;var rz="MenubarSubTrigger",u_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(zf,{"data-radix-menubar-subtrigger":"",...o,...n,ref:t})});u_.displayName=rz;var nz="MenubarSubContent",d_=d.forwardRef((e,t)=>{const{__scopeMenubar:r,...n}=e,o=dt(r);return f.jsx(qf,{...o,"data-radix-menubar-content":"",...n,ref:t,style:{...e.style,"--radix-menubar-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-menubar-content-available-width":"var(--radix-popper-available-width)","--radix-menubar-content-available-height":"var(--radix-popper-available-height)","--radix-menubar-trigger-width":"var(--radix-popper-anchor-width)","--radix-menubar-trigger-height":"var(--radix-popper-anchor-height)"}})});d_.displayName=nz;function oz(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var f_=YC,az=ZC,p_=JC,m_=QC,h_=e_,iz=t_,g_=r_,v_=n_,b_=o_,sz=a_,y_=i_,x_=s_,w_=c_,cz=l_,S_=u_,C_=d_;function lz({...e}){return f.jsx(az,{...e})}function uz({...e}){return f.jsx(iz,{...e})}function dz({...e}){return f.jsx(m_,{...e})}function fz({...e}){return f.jsx(sz,{...e})}function pz({...e}){return f.jsx(cz,{"data-slot":"menubar-sub",...e})}const __=d.forwardRef(({className:e,...t},r)=>f.jsx(f_,{ref:r,className:M("flex h-9 items-center space-x-1 rounded-md border bg-background p-1 shadow-sm",e),...t}));__.displayName=f_.displayName;const R_=d.forwardRef(({className:e,...t},r)=>f.jsx(p_,{ref:r,className:M("flex cursor-default select-none items-center rounded-sm px-3 py-1 text-sm font-medium outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",e),...t}));R_.displayName=p_.displayName;const E_=d.forwardRef(({className:e,inset:t,children:r,...n},o)=>f.jsxs(S_,{ref:o,className:M("flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground",t&&"pl-8",e),...n,children:[r,f.jsx(Dr,{className:"ml-auto h-4 w-4"})]}));E_.displayName=S_.displayName;const P_=d.forwardRef(({className:e,...t},r)=>f.jsx(C_,{ref:r,className:M("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-menubar-content-transform-origin]",e),...t}));P_.displayName=C_.displayName;const T_=d.forwardRef(({className:e,align:t="start",alignOffset:r=-4,sideOffset:n=8,...o},a)=>f.jsx(m_,{children:f.jsx(h_,{ref:a,align:t,alignOffset:r,sideOffset:n,className:M("z-50 min-w-[12rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-menubar-content-transform-origin]",e),...o})}));T_.displayName=h_.displayName;const N_=d.forwardRef(({className:e,inset:t,...r},n)=>f.jsx(v_,{ref:n,className:M("relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t&&"pl-8",e),...r}));N_.displayName=v_.displayName;const A_=d.forwardRef(({className:e,children:t,checked:r,...n},o)=>f.jsxs(b_,{ref:o,className:M("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:r,...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(x_,{children:f.jsx(vo,{className:"h-4 w-4"})})}),t]}));A_.displayName=b_.displayName;const M_=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(y_,{ref:n,className:M("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(x_,{children:f.jsx(Za,{className:"h-4 w-4 fill-current"})})}),t]}));M_.displayName=y_.displayName;const O_=d.forwardRef(({className:e,inset:t,...r},n)=>f.jsx(g_,{ref:n,className:M("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...r}));O_.displayName=g_.displayName;const I_=d.forwardRef(({className:e,...t},r)=>f.jsx(w_,{ref:r,className:M("-mx-1 my-1 h-px bg-muted",e),...t}));I_.displayName=w_.displayName;const j_=({className:e,...t})=>f.jsx("span",{className:M("ml-auto text-xs tracking-widest text-muted-foreground",e),...t});j_.displayname="MenubarShortcut";var mz="VisuallyHidden",ko=d.forwardRef((e,t)=>f.jsx(X.span,{...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}}));ko.displayName=mz;var D_=ko,An="NavigationMenu",[tp,k_,hz]=cr(An),[Xu,gz,vz]=cr(An),[rp,i3]=De(An,[hz,vz]),[bz,Tt]=rp(An),[yz,xz]=rp(An),$_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,value:n,onValueChange:o,defaultValue:a,delayDuration:i=200,skipDelayDuration:s=300,orientation:c="horizontal",dir:l,...p}=e,[u,m]=d.useState(null),b=de(t,P=>m(P)),g=Ft(l),h=d.useRef(0),v=d.useRef(0),y=d.useRef(0),[x,w]=d.useState(!0),[S="",_]=$e({prop:n,onChange:P=>{const k=P!=="",j=s>0;k?(window.clearTimeout(y.current),j&&w(!1)):(window.clearTimeout(y.current),y.current=window.setTimeout(()=>w(!0),s)),o==null||o(P)},defaultProp:a}),R=d.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>_(""),150)},[_]),C=d.useCallback(P=>{window.clearTimeout(v.current),_(P)},[_]),A=d.useCallback(P=>{S===P?window.clearTimeout(v.current):h.current=window.setTimeout(()=>{window.clearTimeout(v.current),_(P)},i)},[S,_,i]);return d.useEffect(()=>()=>{window.clearTimeout(h.current),window.clearTimeout(v.current),window.clearTimeout(y.current)},[]),f.jsx(F_,{scope:r,isRootMenu:!0,value:S,dir:g,orientation:c,rootNavigationMenu:u,onTriggerEnter:P=>{window.clearTimeout(h.current),x?A(P):C(P)},onTriggerLeave:()=>{window.clearTimeout(h.current),R()},onContentEnter:()=>window.clearTimeout(v.current),onContentLeave:R,onItemSelect:P=>{_(k=>k===P?"":P)},onItemDismiss:()=>_(""),children:f.jsx(X.nav,{"aria-label":"Main","data-orientation":c,dir:g,...p,ref:b})})});$_.displayName=An;var L_="NavigationMenuSub",wz=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,value:n,onValueChange:o,defaultValue:a,orientation:i="horizontal",...s}=e,c=Tt(L_,r),[l="",p]=$e({prop:n,onChange:o,defaultProp:a});return f.jsx(F_,{scope:r,isRootMenu:!1,value:l,dir:c.dir,orientation:i,rootNavigationMenu:c.rootNavigationMenu,onTriggerEnter:u=>p(u),onItemSelect:u=>p(u),onItemDismiss:()=>p(""),children:f.jsx(X.div,{"data-orientation":i,...s,ref:t})})});wz.displayName=L_;var F_=e=>{const{scope:t,isRootMenu:r,rootNavigationMenu:n,dir:o,orientation:a,children:i,value:s,onItemSelect:c,onItemDismiss:l,onTriggerEnter:p,onTriggerLeave:u,onContentEnter:m,onContentLeave:b}=e,[g,h]=d.useState(null),[v,y]=d.useState(new Map),[x,w]=d.useState(null);return f.jsx(bz,{scope:t,isRootMenu:r,rootNavigationMenu:n,value:s,previousValue:_n(s),baseId:Ue(),dir:o,orientation:a,viewport:g,onViewportChange:h,indicatorTrack:x,onIndicatorTrackChange:w,onTriggerEnter:Te(p),onTriggerLeave:Te(u),onContentEnter:Te(m),onContentLeave:Te(b),onItemSelect:Te(c),onItemDismiss:Te(l),onViewportContentChange:d.useCallback((S,_)=>{y(R=>(R.set(S,_),new Map(R)))},[]),onViewportContentRemove:d.useCallback(S=>{y(_=>_.has(S)?(_.delete(S),new Map(_)):_)},[]),children:f.jsx(tp.Provider,{scope:t,children:f.jsx(yz,{scope:t,items:v,children:i})})})},B_="NavigationMenuList",z_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,...n}=e,o=Tt(B_,r),a=f.jsx(X.ul,{"data-orientation":o.orientation,...n,ref:t});return f.jsx(X.div,{style:{position:"relative"},ref:o.onIndicatorTrackChange,children:f.jsx(tp.Slot,{scope:r,children:o.isRootMenu?f.jsx(Z_,{asChild:!0,children:a}):a})})});z_.displayName=B_;var q_="NavigationMenuItem",[Sz,H_]=rp(q_),V_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,value:n,...o}=e,a=Ue(),i=n||a||"LEGACY_REACT_AUTO_VALUE",s=d.useRef(null),c=d.useRef(null),l=d.useRef(null),p=d.useRef(()=>{}),u=d.useRef(!1),m=d.useCallback((g="start")=>{if(s.current){p.current();const h=Ju(s.current);h.length&&ap(g==="start"?h:h.reverse())}},[]),b=d.useCallback(()=>{if(s.current){const g=Ju(s.current);g.length&&(p.current=Nz(g))}},[]);return f.jsx(Sz,{scope:r,value:i,triggerRef:c,contentRef:s,focusProxyRef:l,wasEscapeCloseRef:u,onEntryKeyDown:m,onFocusProxyEnter:m,onRootContentClose:b,onContentFocusOutside:b,children:f.jsx(X.li,{...o,ref:t})})});V_.displayName=q_;var Zu="NavigationMenuTrigger",G_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,disabled:n,...o}=e,a=Tt(Zu,e.__scopeNavigationMenu),i=H_(Zu,e.__scopeNavigationMenu),s=d.useRef(null),c=de(s,i.triggerRef,t),l=Q_(a.baseId,i.value),p=eR(a.baseId,i.value),u=d.useRef(!1),m=d.useRef(!1),b=i.value===a.value;return f.jsxs(f.Fragment,{children:[f.jsx(tp.ItemSlot,{scope:r,value:i.value,children:f.jsx(J_,{asChild:!0,children:f.jsx(X.button,{id:l,disabled:n,"data-disabled":n?"":void 0,"data-state":ip(b),"aria-expanded":b,"aria-controls":p,...o,ref:c,onPointerEnter:B(e.onPointerEnter,()=>{m.current=!1,i.wasEscapeCloseRef.current=!1}),onPointerMove:B(e.onPointerMove,Fa(()=>{n||m.current||i.wasEscapeCloseRef.current||u.current||(a.onTriggerEnter(i.value),u.current=!0)})),onPointerLeave:B(e.onPointerLeave,Fa(()=>{n||(a.onTriggerLeave(),u.current=!1)})),onClick:B(e.onClick,()=>{a.onItemSelect(i.value),m.current=b}),onKeyDown:B(e.onKeyDown,g=>{const v={horizontal:"ArrowDown",vertical:a.dir==="rtl"?"ArrowLeft":"ArrowRight"}[a.orientation];b&&g.key===v&&(i.onEntryKeyDown(),g.preventDefault())})})})}),b&&f.jsxs(f.Fragment,{children:[f.jsx(D_,{"aria-hidden":!0,tabIndex:0,ref:i.focusProxyRef,onFocus:g=>{const h=i.contentRef.current,v=g.relatedTarget,y=v===s.current,x=h==null?void 0:h.contains(v);(y||!x)&&i.onFocusProxyEnter(y?"start":"end")}}),a.viewport&&f.jsx("span",{"aria-owns":p})]})]})});G_.displayName=Zu;var Cz="NavigationMenuLink",lb="navigationMenu.linkSelect",U_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,active:n,onSelect:o,...a}=e;return f.jsx(J_,{asChild:!0,children:f.jsx(X.a,{"data-active":n?"":void 0,"aria-current":n?"page":void 0,...a,ref:t,onClick:B(e.onClick,i=>{const s=i.target,c=new CustomEvent(lb,{bubbles:!0,cancelable:!0});if(s.addEventListener(lb,l=>o==null?void 0:o(l),{once:!0}),Xn(s,c),!c.defaultPrevented&&!i.metaKey){const l=new CustomEvent(pa,{bubbles:!0,cancelable:!0});Xn(s,l)}},{checkForDefaultPrevented:!1})})})});U_.displayName=Cz;var np="NavigationMenuIndicator",W_=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=Tt(np,e.__scopeNavigationMenu),a=!!o.value;return o.indicatorTrack?Wa.createPortal(f.jsx(Le,{present:r||a,children:f.jsx(_z,{...n,ref:t})}),o.indicatorTrack):null});W_.displayName=np;var _z=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,...n}=e,o=Tt(np,r),a=k_(r),[i,s]=d.useState(null),[c,l]=d.useState(null),p=o.orientation==="horizontal",u=!!o.value;d.useEffect(()=>{var h;const g=(h=a().find(v=>v.value===o.value))==null?void 0:h.ref.current;g&&s(g)},[a,o.value]);const m=()=>{i&&l({size:p?i.offsetWidth:i.offsetHeight,offset:p?i.offsetLeft:i.offsetTop})};return Qu(i,m),Qu(o.indicatorTrack,m),c?f.jsx(X.div,{"aria-hidden":!0,"data-state":u?"visible":"hidden","data-orientation":o.orientation,...n,ref:t,style:{position:"absolute",...p?{left:0,width:c.size+"px",transform:`translateX(${c.offset}px)`}:{top:0,height:c.size+"px",transform:`translateY(${c.offset}px)`},...n.style}}):null}),pn="NavigationMenuContent",K_=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=Tt(pn,e.__scopeNavigationMenu),a=H_(pn,e.__scopeNavigationMenu),i=de(a.contentRef,t),s=a.value===o.value,c={value:a.value,triggerRef:a.triggerRef,focusProxyRef:a.focusProxyRef,wasEscapeCloseRef:a.wasEscapeCloseRef,onContentFocusOutside:a.onContentFocusOutside,onRootContentClose:a.onRootContentClose,...n};return o.viewport?f.jsx(Rz,{forceMount:r,...c,ref:i}):f.jsx(Le,{present:r||s,children:f.jsx(Y_,{"data-state":ip(s),...c,ref:i,onPointerEnter:B(e.onPointerEnter,o.onContentEnter),onPointerLeave:B(e.onPointerLeave,Fa(o.onContentLeave)),style:{pointerEvents:!s&&o.isRootMenu?"none":void 0,...c.style}})})});K_.displayName=pn;var Rz=d.forwardRef((e,t)=>{const r=Tt(pn,e.__scopeNavigationMenu),{onViewportContentChange:n,onViewportContentRemove:o}=r;return He(()=>{n(e.value,{ref:t,...e})},[e,t,n]),He(()=>()=>o(e.value),[e.value,o]),null}),pa="navigationMenu.rootContentDismiss",Y_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,value:n,triggerRef:o,focusProxyRef:a,wasEscapeCloseRef:i,onRootContentClose:s,onContentFocusOutside:c,...l}=e,p=Tt(pn,r),u=d.useRef(null),m=de(u,t),b=Q_(p.baseId,n),g=eR(p.baseId,n),h=k_(r),v=d.useRef(null),{onItemDismiss:y}=p;d.useEffect(()=>{const w=u.current;if(p.isRootMenu&&w){const S=()=>{var _;y(),s(),w.contains(document.activeElement)&&((_=o.current)==null||_.focus())};return w.addEventListener(pa,S),()=>w.removeEventListener(pa,S)}},[p.isRootMenu,e.value,o,y,s]);const x=d.useMemo(()=>{const S=h().map(k=>k.value);p.dir==="rtl"&&S.reverse();const _=S.indexOf(p.value),R=S.indexOf(p.previousValue),C=n===p.value,A=R===S.indexOf(n);if(!C&&!A)return v.current;const P=(()=>{if(_!==R){if(C&&R!==-1)return _>R?"from-end":"from-start";if(A&&_!==-1)return _>R?"to-start":"to-end"}return null})();return v.current=P,P},[p.previousValue,p.value,p.dir,h,n]);return f.jsx(Z_,{asChild:!0,children:f.jsx(ur,{id:g,"aria-labelledby":b,"data-motion":x,"data-orientation":p.orientation,...l,ref:m,disableOutsidePointerEvents:!1,onDismiss:()=>{var S;const w=new Event(pa,{bubbles:!0,cancelable:!0});(S=u.current)==null||S.dispatchEvent(w)},onFocusOutside:B(e.onFocusOutside,w=>{var _;c();const S=w.target;(_=p.rootNavigationMenu)!=null&&_.contains(S)&&w.preventDefault()}),onPointerDownOutside:B(e.onPointerDownOutside,w=>{var C;const S=w.target,_=h().some(A=>{var P;return(P=A.ref.current)==null?void 0:P.contains(S)}),R=p.isRootMenu&&((C=p.viewport)==null?void 0:C.contains(S));(_||R||!p.isRootMenu)&&w.preventDefault()}),onKeyDown:B(e.onKeyDown,w=>{var R;const S=w.altKey||w.ctrlKey||w.metaKey;if(w.key==="Tab"&&!S){const C=Ju(w.currentTarget),A=document.activeElement,P=C.findIndex(L=>L===A),j=w.shiftKey?C.slice(0,P).reverse():C.slice(P+1,C.length);ap(j)?w.preventDefault():(R=a.current)==null||R.focus()}}),onEscapeKeyDown:B(e.onEscapeKeyDown,w=>{i.current=!0})})})}),op="NavigationMenuViewport",X_=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,a=!!Tt(op,e.__scopeNavigationMenu).value;return f.jsx(Le,{present:r||a,children:f.jsx(Ez,{...n,ref:t})})});X_.displayName=op;var Ez=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,children:n,...o}=e,a=Tt(op,r),i=de(t,a.onViewportChange),s=xz(pn,e.__scopeNavigationMenu),[c,l]=d.useState(null),[p,u]=d.useState(null),m=c?(c==null?void 0:c.width)+"px":void 0,b=c?(c==null?void 0:c.height)+"px":void 0,g=!!a.value,h=g?a.value:a.previousValue;return Qu(p,()=>{p&&l({width:p.offsetWidth,height:p.offsetHeight})}),f.jsx(X.div,{"data-state":ip(g),"data-orientation":a.orientation,...o,ref:i,style:{pointerEvents:!g&&a.isRootMenu?"none":void 0,"--radix-navigation-menu-viewport-width":m,"--radix-navigation-menu-viewport-height":b,...o.style},onPointerEnter:B(e.onPointerEnter,a.onContentEnter),onPointerLeave:B(e.onPointerLeave,Fa(a.onContentLeave)),children:Array.from(s.items).map(([y,{ref:x,forceMount:w,...S}])=>{const _=h===y;return f.jsx(Le,{present:w||_,children:f.jsx(Y_,{...S,ref:go(x,R=>{_&&R&&u(R)})})},y)})})}),Pz="FocusGroup",Z_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,...n}=e,o=Tt(Pz,r);return f.jsx(Xu.Provider,{scope:r,children:f.jsx(Xu.Slot,{scope:r,children:f.jsx(X.div,{dir:o.dir,...n,ref:t})})})}),ub=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],Tz="FocusGroupItem",J_=d.forwardRef((e,t)=>{const{__scopeNavigationMenu:r,...n}=e,o=gz(r),a=Tt(Tz,r);return f.jsx(Xu.ItemSlot,{scope:r,children:f.jsx(X.button,{...n,ref:t,onKeyDown:B(e.onKeyDown,i=>{if(["Home","End",...ub].includes(i.key)){let c=o().map(u=>u.ref.current);if([a.dir==="rtl"?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(i.key)&&c.reverse(),ub.includes(i.key)){const u=c.indexOf(i.currentTarget);c=c.slice(u+1)}setTimeout(()=>ap(c)),i.preventDefault()}})})})});function Ju(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function ap(e){const t=document.activeElement;return e.some(r=>r===t?!0:(r.focus(),document.activeElement!==t))}function Nz(e){return e.forEach(t=>{t.dataset.tabindex=t.getAttribute("tabindex")||"",t.setAttribute("tabindex","-1")}),()=>{e.forEach(t=>{const r=t.dataset.tabindex;t.setAttribute("tabindex",r)})}}function Qu(e,t){const r=Te(t);He(()=>{let n=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(n),n=window.requestAnimationFrame(r)});return o.observe(e),()=>{window.cancelAnimationFrame(n),o.unobserve(e)}}},[e,r])}function ip(e){return e?"open":"closed"}function Q_(e,t){return`${e}-trigger-${t}`}function eR(e,t){return`${e}-content-${t}`}function Fa(e){return t=>t.pointerType==="mouse"?e(t):void 0}var tR=$_,rR=z_,Az=V_,nR=G_,Mz=U_,oR=W_,aR=K_,iR=X_;const sR=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(tR,{ref:n,className:M("relative z-10 flex max-w-max flex-1 items-center justify-center",e),...r,children:[t,f.jsx(sp,{})]}));sR.displayName=tR.displayName;const cR=d.forwardRef(({className:e,...t},r)=>f.jsx(rR,{ref:r,className:M("group flex flex-1 list-none items-center justify-center space-x-1",e),...t}));cR.displayName=rR.displayName;const Oz=Az,lR=fr("group inline-flex h-9 w-max items-center justify-center rounded-md bg-background px-4 py-2 text-sm font-medium transition-colors hover:bg-accent hover:text-accent-foreground focus:bg-accent focus:text-accent-foreground focus:outline-none disabled:pointer-events-none disabled:opacity-50 data-[state=open]:text-accent-foreground data-[state=open]:bg-accent/50 data-[state=open]:hover:bg-accent data-[state=open]:focus:bg-accent"),uR=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(nR,{ref:n,className:M(lR(),"group",e),...r,children:[t," ",f.jsx(Xa,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-300 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));uR.displayName=nR.displayName;const dR=d.forwardRef(({className:e,...t},r)=>f.jsx(aR,{ref:r,className:M("left-0 top-0 w-full data-[motion^=from-]:animate-in data-[motion^=to-]:animate-out data-[motion^=from-]:fade-in data-[motion^=to-]:fade-out data-[motion=from-end]:slide-in-from-right-52 data-[motion=from-start]:slide-in-from-left-52 data-[motion=to-end]:slide-out-to-right-52 data-[motion=to-start]:slide-out-to-left-52 md:absolute md:w-auto ",e),...t}));dR.displayName=aR.displayName;const Iz=Mz,sp=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{className:M("absolute left-0 top-full flex justify-center"),children:f.jsx(iR,{className:M("origin-top-center relative mt-1.5 h-[var(--radix-navigation-menu-viewport-height)] w-full overflow-hidden rounded-md border bg-popover text-popover-foreground shadow data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-90 md:w-[var(--radix-navigation-menu-viewport-width)]",e),ref:r,...t})}));sp.displayName=iR.displayName;const fR=d.forwardRef(({className:e,...t},r)=>f.jsx(oR,{ref:r,className:M("top-full z-[1] flex h-1.5 items-end justify-center overflow-hidden data-[state=visible]:animate-in data-[state=hidden]:animate-out data-[state=hidden]:fade-out data-[state=visible]:fade-in",e),...t,children:f.jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));fR.displayName=oR.displayName;const pR=({className:e,...t})=>f.jsx("nav",{role:"navigation","aria-label":"pagination",className:M("mx-auto flex w-full justify-center",e),...t});pR.displayName="Pagination";const mR=d.forwardRef(({className:e,...t},r)=>f.jsx("ul",{ref:r,className:M("flex flex-row items-center gap-1",e),...t}));mR.displayName="PaginationContent";const hR=d.forwardRef(({className:e,...t},r)=>f.jsx("li",{ref:r,className:M("",e),...t}));hR.displayName="PaginationItem";const Ti=({className:e,isActive:t,size:r="icon",...n})=>f.jsx("a",{"aria-current":t?"page":void 0,className:M(xo({variant:t?"outline":"ghost",size:r}),e),...n});Ti.displayName="PaginationLink";const gR=({className:e,...t})=>f.jsxs(Ti,{"aria-label":"Go to previous page",size:"default",className:M("gap-1 pl-2.5",e),...t,children:[f.jsx(O1,{className:"h-4 w-4"}),f.jsx("span",{children:"Previous"})]});gR.displayName="PaginationPrevious";const vR=({className:e,...t})=>f.jsxs(Ti,{"aria-label":"Go to next page",size:"default",className:M("gap-1 pr-2.5",e),...t,children:[f.jsx("span",{children:"Next"}),f.jsx(Dr,{className:"h-4 w-4"})]});vR.displayName="PaginationNext";const bR=({className:e,...t})=>f.jsxs("span",{"aria-hidden":!0,className:M("flex h-9 w-9 items-center justify-center",e),...t,children:[f.jsx(Ed,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"More pages"})]});bR.displayName="PaginationEllipsis";var cp="Popover",[yR,s3]=De(cp,[Jt]),$o=Jt(),[jz,Cr]=yR(cp),xR=e=>{const{__scopePopover:t,children:r,open:n,defaultOpen:o,onOpenChange:a,modal:i=!1}=e,s=$o(t),c=d.useRef(null),[l,p]=d.useState(!1),[u=!1,m]=$e({prop:n,defaultProp:o,onChange:a});return f.jsx(Pn,{...s,children:f.jsx(jz,{scope:t,contentId:Ue(),triggerRef:c,open:u,onOpenChange:m,onOpenToggle:d.useCallback(()=>m(b=>!b),[m]),hasCustomAnchor:l,onCustomAnchorAdd:d.useCallback(()=>p(!0),[]),onCustomAnchorRemove:d.useCallback(()=>p(!1),[]),modal:i,children:r})})};xR.displayName=cp;var wR="PopoverAnchor",SR=d.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,o=Cr(wR,r),a=$o(r),{onCustomAnchorAdd:i,onCustomAnchorRemove:s}=o;return d.useEffect(()=>(i(),()=>s()),[i,s]),f.jsx(Tn,{...a,...n,ref:t})});SR.displayName=wR;var CR="PopoverTrigger",_R=d.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,o=Cr(CR,r),a=$o(r),i=de(t,o.triggerRef),s=f.jsx(X.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":NR(o.open),...n,ref:i,onClick:B(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?s:f.jsx(Tn,{asChild:!0,...a,children:s})});_R.displayName=CR;var lp="PopoverPortal",[Dz,kz]=yR(lp,{forceMount:void 0}),RR=e=>{const{__scopePopover:t,forceMount:r,children:n,container:o}=e,a=Cr(lp,t);return f.jsx(Dz,{scope:t,forceMount:r,children:f.jsx(Le,{present:r||a.open,children:f.jsx(zr,{asChild:!0,container:o,children:n})})})};RR.displayName=lp;var mn="PopoverContent",ER=d.forwardRef((e,t)=>{const r=kz(mn,e.__scopePopover),{forceMount:n=r.forceMount,...o}=e,a=Cr(mn,e.__scopePopover);return f.jsx(Le,{present:n||a.open,children:a.modal?f.jsx($z,{...o,ref:t}):f.jsx(Lz,{...o,ref:t})})});ER.displayName=mn;var $z=d.forwardRef((e,t)=>{const r=Cr(mn,e.__scopePopover),n=d.useRef(null),o=de(t,n),a=d.useRef(!1);return d.useEffect(()=>{const i=n.current;if(i)return ei(i)},[]),f.jsx(yo,{as:st,allowPinchZoom:!0,children:f.jsx(PR,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:B(e.onCloseAutoFocus,i=>{var s;i.preventDefault(),a.current||(s=r.triggerRef.current)==null||s.focus()}),onPointerDownOutside:B(e.onPointerDownOutside,i=>{const s=i.detail.originalEvent,c=s.button===0&&s.ctrlKey===!0,l=s.button===2||c;a.current=l},{checkForDefaultPrevented:!1}),onFocusOutside:B(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),Lz=d.forwardRef((e,t)=>{const r=Cr(mn,e.__scopePopover),n=d.useRef(!1),o=d.useRef(!1);return f.jsx(PR,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var i,s;(i=e.onCloseAutoFocus)==null||i.call(e,a),a.defaultPrevented||(n.current||(s=r.triggerRef.current)==null||s.focus(),a.preventDefault()),n.current=!1,o.current=!1},onInteractOutside:a=>{var c,l;(c=e.onInteractOutside)==null||c.call(e,a),a.defaultPrevented||(n.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=a.target;((l=r.triggerRef.current)==null?void 0:l.contains(i))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),PR=d.forwardRef((e,t)=>{const{__scopePopover:r,trapFocus:n,onOpenAutoFocus:o,onCloseAutoFocus:a,disableOutsidePointerEvents:i,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:p,...u}=e,m=Cr(mn,r),b=$o(r);return Ja(),f.jsx(bo,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:o,onUnmountAutoFocus:a,children:f.jsx(ur,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:p,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>m.onOpenChange(!1),children:f.jsx(Eo,{"data-state":NR(m.open),role:"dialog",id:m.contentId,...b,...u,ref:t,style:{...u.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),TR="PopoverClose",Fz=d.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,o=Cr(TR,r);return f.jsx(X.button,{type:"button",...n,ref:t,onClick:B(e.onClick,()=>o.onOpenChange(!1))})});Fz.displayName=TR;var Bz="PopoverArrow",zz=d.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,o=$o(r);return f.jsx(Po,{...o,...n,ref:t})});zz.displayName=Bz;function NR(e){return e?"open":"closed"}var qz=xR,Hz=SR,Vz=_R,Gz=RR,AR=ER;const Uz=qz,Wz=Vz,Kz=Hz,MR=d.forwardRef(({className:e,align:t="center",sideOffset:r=4,...n},o)=>f.jsx(Gz,{children:f.jsx(AR,{ref:o,align:t,sideOffset:r,className:M("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-popover-content-transform-origin]",e),...n})}));MR.displayName=AR.displayName;var up="Progress",dp=100,[Yz,c3]=De(up),[Xz,Zz]=Yz(up),OR=d.forwardRef((e,t)=>{const{__scopeProgress:r,value:n=null,max:o,getValueLabel:a=Jz,...i}=e;(o||o===0)&&!db(o)&&console.error(Qz(`${o}`,"Progress"));const s=db(o)?o:dp;n!==null&&!fb(n,s)&&console.error(eq(`${n}`,"Progress"));const c=fb(n,s)?n:null,l=Ba(c)?a(c,s):void 0;return f.jsx(Xz,{scope:r,value:c,max:s,children:f.jsx(X.div,{"aria-valuemax":s,"aria-valuemin":0,"aria-valuenow":Ba(c)?c:void 0,"aria-valuetext":l,role:"progressbar","data-state":DR(c,s),"data-value":c??void 0,"data-max":s,...i,ref:t})})});OR.displayName=up;var IR="ProgressIndicator",jR=d.forwardRef((e,t)=>{const{__scopeProgress:r,...n}=e,o=Zz(IR,r);return f.jsx(X.div,{"data-state":DR(o.value,o.max),"data-value":o.value??void 0,"data-max":o.max,...n,ref:t})});jR.displayName=IR;function Jz(e,t){return`${Math.round(e/t*100)}%`}function DR(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function Ba(e){return typeof e=="number"}function db(e){return Ba(e)&&!isNaN(e)&&e>0}function fb(e,t){return Ba(e)&&!isNaN(e)&&e<=t&&e>=0}function Qz(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${dp}\`.`}function eq(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
|
|
233
|
+
- a positive number
|
|
234
|
+
- less than the value passed to \`max\` (or ${dp} if no \`max\` prop is set)
|
|
235
|
+
- \`null\` or \`undefined\` if the progress is indeterminate.
|
|
236
|
+
|
|
237
|
+
Defaulting to \`null\`.`}var kR=OR,tq=jR;const $R=d.forwardRef(({className:e,value:t,...r},n)=>f.jsx(kR,{ref:n,className:M("relative h-2 w-full overflow-hidden rounded-full bg-primary/20",e),...r,children:f.jsx(tq,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));$R.displayName=kR.displayName;var fp="Radio",[rq,LR]=De(fp),[nq,oq]=rq(fp),FR=d.forwardRef((e,t)=>{const{__scopeRadio:r,name:n,checked:o=!1,required:a,disabled:i,value:s="on",onCheck:c,form:l,...p}=e,[u,m]=d.useState(null),b=de(t,v=>m(v)),g=d.useRef(!1),h=u?l||!!u.closest("form"):!0;return f.jsxs(nq,{scope:r,checked:o,disabled:i,children:[f.jsx(X.button,{type:"button",role:"radio","aria-checked":o,"data-state":qR(o),"data-disabled":i?"":void 0,disabled:i,value:s,...p,ref:b,onClick:B(e.onClick,v=>{o||c==null||c(),h&&(g.current=v.isPropagationStopped(),g.current||v.stopPropagation())})}),h&&f.jsx(aq,{control:u,bubbles:!g.current,name:n,value:s,checked:o,required:a,disabled:i,form:l,style:{transform:"translateX(-100%)"}})]})});FR.displayName=fp;var BR="RadioIndicator",zR=d.forwardRef((e,t)=>{const{__scopeRadio:r,forceMount:n,...o}=e,a=oq(BR,r);return f.jsx(Le,{present:n||a.checked,children:f.jsx(X.span,{"data-state":qR(a.checked),"data-disabled":a.disabled?"":void 0,...o,ref:t})})});zR.displayName=BR;var aq=e=>{const{control:t,checked:r,bubbles:n=!0,...o}=e,a=d.useRef(null),i=_n(r),s=_o(t);return d.useEffect(()=>{const c=a.current,l=window.HTMLInputElement.prototype,u=Object.getOwnPropertyDescriptor(l,"checked").set;if(i!==r&&u){const m=new Event("click",{bubbles:n});u.call(c,r),c.dispatchEvent(m)}},[i,r,n]),f.jsx("input",{type:"radio","aria-hidden":!0,defaultChecked:r,...o,tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function qR(e){return e?"checked":"unchecked"}var iq=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],pp="RadioGroup",[sq,l3]=De(pp,[Qt,LR]),HR=Qt(),VR=LR(),[cq,lq]=sq(pp),GR=d.forwardRef((e,t)=>{const{__scopeRadioGroup:r,name:n,defaultValue:o,value:a,required:i=!1,disabled:s=!1,orientation:c,dir:l,loop:p=!0,onValueChange:u,...m}=e,b=HR(r),g=Ft(l),[h,v]=$e({prop:a,defaultProp:o,onChange:u});return f.jsx(cq,{scope:r,name:n,required:i,disabled:s,value:h,onValueChange:v,children:f.jsx(To,{asChild:!0,...b,orientation:c,dir:g,loop:p,children:f.jsx(X.div,{role:"radiogroup","aria-required":i,"aria-orientation":c,"data-disabled":s?"":void 0,dir:g,...m,ref:t})})})});GR.displayName=pp;var UR="RadioGroupItem",WR=d.forwardRef((e,t)=>{const{__scopeRadioGroup:r,disabled:n,...o}=e,a=lq(UR,r),i=a.disabled||n,s=HR(r),c=VR(r),l=d.useRef(null),p=de(t,l),u=a.value===o.value,m=d.useRef(!1);return d.useEffect(()=>{const b=h=>{iq.includes(h.key)&&(m.current=!0)},g=()=>m.current=!1;return document.addEventListener("keydown",b),document.addEventListener("keyup",g),()=>{document.removeEventListener("keydown",b),document.removeEventListener("keyup",g)}},[]),f.jsx(No,{asChild:!0,...s,focusable:!i,active:u,children:f.jsx(FR,{disabled:i,required:a.required,checked:u,...c,...o,name:a.name,ref:p,onCheck:()=>a.onValueChange(o.value),onKeyDown:B(b=>{b.key==="Enter"&&b.preventDefault()}),onFocus:B(o.onFocus,()=>{var b;m.current&&((b=l.current)==null||b.click())})})})});WR.displayName=UR;var uq="RadioGroupIndicator",KR=d.forwardRef((e,t)=>{const{__scopeRadioGroup:r,...n}=e,o=VR(r);return f.jsx(zR,{...o,...n,ref:t})});KR.displayName=uq;var YR=GR,XR=WR,dq=KR;const ZR=d.forwardRef(({className:e,...t},r)=>f.jsx(YR,{className:M("grid gap-2",e),...t,ref:r}));ZR.displayName=YR.displayName;const JR=d.forwardRef(({className:e,...t},r)=>f.jsx(XR,{ref:r,className:M("aspect-square h-4 w-4 rounded-full border border-primary text-primary shadow focus:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",e),...t,children:f.jsx(dq,{className:"flex items-center justify-center",children:f.jsx(Za,{className:"h-3.5 w-3.5 fill-primary"})})}));JR.displayName=XR.displayName;const{createElement:hn,createContext:fq,forwardRef:QR,useCallback:gt,useContext:eE,useEffect:Ir,useImperativeHandle:tE,useLayoutEffect:pq,useMemo:mq,useRef:yt,useState:an}=d,pb=d[`useId${Math.random()}`.slice(0,5)],hq=pq,Ni=fq(null);Ni.displayName="PanelGroupContext";const jr=hq,gq=typeof pb=="function"?pb:()=>null;let vq=0;function mp(e=null){const t=gq(),r=yt(e||t||null);return r.current===null&&(r.current=""+vq++),e??r.current}function rE({children:e,className:t="",collapsedSize:r,collapsible:n,defaultSize:o,forwardedRef:a,id:i,maxSize:s,minSize:c,onCollapse:l,onExpand:p,onResize:u,order:m,style:b,tagName:g="div",...h}){const v=eE(Ni);if(v===null)throw Error("Panel components must be rendered within a PanelGroup container");const{collapsePanel:y,expandPanel:x,getPanelSize:w,getPanelStyle:S,groupId:_,isPanelCollapsed:R,reevaluatePanelConstraints:C,registerPanel:A,resizePanel:P,unregisterPanel:k}=v,j=mp(i),L=yt({callbacks:{onCollapse:l,onExpand:p,onResize:u},constraints:{collapsedSize:r,collapsible:n,defaultSize:o,maxSize:s,minSize:c},id:j,idIsFromProps:i!==void 0,order:m});yt({didLogMissingDefaultSizeWarning:!1}),jr(()=>{const{callbacks:D,constraints:$}=L.current,O={...$};L.current.id=j,L.current.idIsFromProps=i!==void 0,L.current.order=m,D.onCollapse=l,D.onExpand=p,D.onResize=u,$.collapsedSize=r,$.collapsible=n,$.defaultSize=o,$.maxSize=s,$.minSize=c,(O.collapsedSize!==$.collapsedSize||O.collapsible!==$.collapsible||O.maxSize!==$.maxSize||O.minSize!==$.minSize)&&C(L.current,O)}),jr(()=>{const D=L.current;return A(D),()=>{k(D)}},[m,j,A,k]),tE(a,()=>({collapse:()=>{y(L.current)},expand:D=>{x(L.current,D)},getId(){return j},getSize(){return w(L.current)},isCollapsed(){return R(L.current)},isExpanded(){return!R(L.current)},resize:D=>{P(L.current,D)}}),[y,x,w,R,j,P]);const N=S(L.current,o);return hn(g,{...h,children:e,className:t,id:i,style:{...N,...b},"data-panel":"","data-panel-collapsible":n||void 0,"data-panel-group-id":_,"data-panel-id":j,"data-panel-size":parseFloat(""+N.flexGrow).toFixed(1)})}const nE=QR((e,t)=>hn(rE,{...e,forwardedRef:t}));rE.displayName="Panel";nE.displayName="forwardRef(Panel)";let ed=null,Or=null;function bq(e,t){if(t){const r=(t&cE)!==0,n=(t&lE)!==0,o=(t&uE)!==0,a=(t&dE)!==0;if(r)return o?"se-resize":a?"ne-resize":"e-resize";if(n)return o?"sw-resize":a?"nw-resize":"w-resize";if(o)return"s-resize";if(a)return"n-resize"}switch(e){case"horizontal":return"ew-resize";case"intersection":return"move";case"vertical":return"ns-resize"}}function yq(){Or!==null&&(document.head.removeChild(Or),ed=null,Or=null)}function uu(e,t){const r=bq(e,t);ed!==r&&(ed=r,Or===null&&(Or=document.createElement("style"),document.head.appendChild(Or)),Or.innerHTML=`*{cursor: ${r}!important;}`)}function oE(e){return e.type==="keydown"}function aE(e){return e.type.startsWith("pointer")}function iE(e){return e.type.startsWith("mouse")}function Ai(e){if(aE(e)){if(e.isPrimary)return{x:e.clientX,y:e.clientY}}else if(iE(e))return{x:e.clientX,y:e.clientY};return{x:1/0,y:1/0}}function xq(){if(typeof matchMedia=="function")return matchMedia("(pointer:coarse)").matches?"coarse":"fine"}function wq(e,t,r){return e.x<t.x+t.width&&e.x+e.width>t.x&&e.y<t.y+t.height&&e.y+e.height>t.y}function Sq(e,t){if(e===t)throw new Error("Cannot compare node with itself");const r={a:gb(e),b:gb(t)};let n;for(;r.a.at(-1)===r.b.at(-1);)e=r.a.pop(),t=r.b.pop(),n=e;ye(n,"Stacking order can only be calculated for elements with a common ancestor");const o={a:hb(mb(r.a)),b:hb(mb(r.b))};if(o.a===o.b){const a=n.childNodes,i={a:r.a.at(-1),b:r.b.at(-1)};let s=a.length;for(;s--;){const c=a[s];if(c===i.a)return 1;if(c===i.b)return-1}}return Math.sign(o.a-o.b)}const Cq=/\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\b/;function _q(e){var t;const r=getComputedStyle((t=sE(e))!==null&&t!==void 0?t:e).display;return r==="flex"||r==="inline-flex"}function Rq(e){const t=getComputedStyle(e);return!!(t.position==="fixed"||t.zIndex!=="auto"&&(t.position!=="static"||_q(e))||+t.opacity<1||"transform"in t&&t.transform!=="none"||"webkitTransform"in t&&t.webkitTransform!=="none"||"mixBlendMode"in t&&t.mixBlendMode!=="normal"||"filter"in t&&t.filter!=="none"||"webkitFilter"in t&&t.webkitFilter!=="none"||"isolation"in t&&t.isolation==="isolate"||Cq.test(t.willChange)||t.webkitOverflowScrolling==="touch")}function mb(e){let t=e.length;for(;t--;){const r=e[t];if(ye(r,"Missing node"),Rq(r))return r}return null}function hb(e){return e&&Number(getComputedStyle(e).zIndex)||0}function gb(e){const t=[];for(;e;)t.push(e),e=sE(e);return t}function sE(e){const{parentNode:t}=e;return t&&t instanceof ShadowRoot?t.host:t}const cE=1,lE=2,uE=4,dE=8,Eq=xq()==="coarse";let kt=[],sn=!1,gr=new Map,Mi=new Map;const fo=new Set;function Pq(e,t,r,n,o){var a;const{ownerDocument:i}=t,s={direction:r,element:t,hitAreaMargins:n,setResizeHandlerState:o},c=(a=gr.get(i))!==null&&a!==void 0?a:0;return gr.set(i,c+1),fo.add(s),za(),function(){var p;Mi.delete(e),fo.delete(s);const u=(p=gr.get(i))!==null&&p!==void 0?p:1;if(gr.set(i,u-1),za(),u===1&&gr.delete(i),kt.includes(s)){const m=kt.indexOf(s);m>=0&&kt.splice(m,1),gp(),o("up",!0,null)}}}function vb(e){const{target:t}=e,{x:r,y:n}=Ai(e);sn=!0,hp({target:t,x:r,y:n}),za(),kt.length>0&&(qa("down",e),e.preventDefault(),e.stopPropagation())}function Bn(e){const{x:t,y:r}=Ai(e);if(sn&&e.buttons===0&&(sn=!1,qa("up",e)),!sn){const{target:n}=e;hp({target:n,x:t,y:r})}qa("move",e),gp(),kt.length>0&&e.preventDefault()}function Jr(e){const{target:t}=e,{x:r,y:n}=Ai(e);Mi.clear(),sn=!1,kt.length>0&&e.preventDefault(),qa("up",e),hp({target:t,x:r,y:n}),gp(),za()}function hp({target:e,x:t,y:r}){kt.splice(0);let n=null;(e instanceof HTMLElement||e instanceof SVGElement)&&(n=e),fo.forEach(o=>{const{element:a,hitAreaMargins:i}=o,s=a.getBoundingClientRect(),{bottom:c,left:l,right:p,top:u}=s,m=Eq?i.coarse:i.fine;if(t>=l-m&&t<=p+m&&r>=u-m&&r<=c+m){if(n!==null&&document.contains(n)&&a!==n&&!a.contains(n)&&!n.contains(a)&&Sq(n,a)>0){let g=n,h=!1;for(;g&&!g.contains(a);){if(wq(g.getBoundingClientRect(),s)){h=!0;break}g=g.parentElement}if(h)return}kt.push(o)}})}function du(e,t){Mi.set(e,t)}function gp(){let e=!1,t=!1;kt.forEach(n=>{const{direction:o}=n;o==="horizontal"?e=!0:t=!0});let r=0;Mi.forEach(n=>{r|=n}),e&&t?uu("intersection",r):e?uu("horizontal",r):t?uu("vertical",r):yq()}function za(){gr.forEach((e,t)=>{const{body:r}=t;r.removeEventListener("contextmenu",Jr),r.removeEventListener("pointerdown",vb),r.removeEventListener("pointerleave",Bn),r.removeEventListener("pointermove",Bn)}),window.removeEventListener("pointerup",Jr),window.removeEventListener("pointercancel",Jr),fo.size>0&&(sn?(kt.length>0&&gr.forEach((e,t)=>{const{body:r}=t;e>0&&(r.addEventListener("contextmenu",Jr),r.addEventListener("pointerleave",Bn),r.addEventListener("pointermove",Bn))}),window.addEventListener("pointerup",Jr),window.addEventListener("pointercancel",Jr)):gr.forEach((e,t)=>{const{body:r}=t;e>0&&(r.addEventListener("pointerdown",vb,{capture:!0}),r.addEventListener("pointermove",Bn))}))}function qa(e,t){fo.forEach(r=>{const{setResizeHandlerState:n}=r,o=kt.includes(r);n(e,o,t)})}function Tq(){const[e,t]=an(0);return gt(()=>t(r=>r+1),[])}function ye(e,t){if(!e)throw console.error(t),Error(t)}const vp=10;function Fr(e,t,r=vp){return e.toFixed(r)===t.toFixed(r)?0:e>t?1:-1}function nr(e,t,r=vp){return Fr(e,t,r)===0}function xt(e,t,r){return Fr(e,t,r)===0}function Nq(e,t,r){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++){const o=e[n],a=t[n];if(!xt(o,a,r))return!1}return!0}function tn({panelConstraints:e,panelIndex:t,size:r}){const n=e[t];ye(n!=null,`Panel constraints not found for index ${t}`);let{collapsedSize:o=0,collapsible:a,maxSize:i=100,minSize:s=0}=n;if(Fr(r,s)<0)if(a){const c=(o+s)/2;Fr(r,c)<0?r=o:r=s}else r=s;return r=Math.min(i,r),r=parseFloat(r.toFixed(vp)),r}function Gn({delta:e,initialLayout:t,panelConstraints:r,pivotIndices:n,prevLayout:o,trigger:a}){if(xt(e,0))return t;const i=[...t],[s,c]=n;ye(s!=null,"Invalid first pivot index"),ye(c!=null,"Invalid second pivot index");let l=0;if(a==="keyboard"){{const u=e<0?c:s,m=r[u];ye(m,`Panel constraints not found for index ${u}`);const{collapsedSize:b=0,collapsible:g,minSize:h=0}=m;if(g){const v=t[u];if(ye(v!=null,`Previous layout not found for panel index ${u}`),xt(v,b)){const y=h-v;Fr(y,Math.abs(e))>0&&(e=e<0?0-y:y)}}}{const u=e<0?s:c,m=r[u];ye(m,`No panel constraints found for index ${u}`);const{collapsedSize:b=0,collapsible:g,minSize:h=0}=m;if(g){const v=t[u];if(ye(v!=null,`Previous layout not found for panel index ${u}`),xt(v,h)){const y=v-b;Fr(y,Math.abs(e))>0&&(e=e<0?0-y:y)}}}}{const u=e<0?1:-1;let m=e<0?c:s,b=0;for(;;){const h=t[m];ye(h!=null,`Previous layout not found for panel index ${m}`);const y=tn({panelConstraints:r,panelIndex:m,size:100})-h;if(b+=y,m+=u,m<0||m>=r.length)break}const g=Math.min(Math.abs(e),Math.abs(b));e=e<0?0-g:g}{let m=e<0?s:c;for(;m>=0&&m<r.length;){const b=Math.abs(e)-Math.abs(l),g=t[m];ye(g!=null,`Previous layout not found for panel index ${m}`);const h=g-b,v=tn({panelConstraints:r,panelIndex:m,size:h});if(!xt(g,v)&&(l+=g-v,i[m]=v,l.toPrecision(3).localeCompare(Math.abs(e).toPrecision(3),void 0,{numeric:!0})>=0))break;e<0?m--:m++}}if(Nq(o,i))return o;{const u=e<0?c:s,m=t[u];ye(m!=null,`Previous layout not found for panel index ${u}`);const b=m+l,g=tn({panelConstraints:r,panelIndex:u,size:b});if(i[u]=g,!xt(g,b)){let h=b-g,y=e<0?c:s;for(;y>=0&&y<r.length;){const x=i[y];ye(x!=null,`Previous layout not found for panel index ${y}`);const w=x+h,S=tn({panelConstraints:r,panelIndex:y,size:w});if(xt(x,S)||(h-=S-x,i[y]=S),xt(h,0))break;e>0?y--:y++}}}const p=i.reduce((u,m)=>m+u,0);return xt(p,100)?i:o}function Aq({layout:e,panelsArray:t,pivotIndices:r}){let n=0,o=100,a=0,i=0;const s=r[0];ye(s!=null,"No pivot index found"),t.forEach((u,m)=>{const{constraints:b}=u,{maxSize:g=100,minSize:h=0}=b;m===s?(n=h,o=g):(a+=h,i+=g)});const c=Math.min(o,100-a),l=Math.max(n,100-i),p=e[s];return{valueMax:c,valueMin:l,valueNow:p}}function po(e,t=document){return Array.from(t.querySelectorAll(`[data-panel-resize-handle-id][data-panel-group-id="${e}"]`))}function fE(e,t,r=document){const o=po(e,r).findIndex(a=>a.getAttribute("data-panel-resize-handle-id")===t);return o??null}function pE(e,t,r){const n=fE(e,t,r);return n!=null?[n,n+1]:[-1,-1]}function mE(e,t=document){var r;if(t instanceof HTMLElement&&(t==null||(r=t.dataset)===null||r===void 0?void 0:r.panelGroupId)==e)return t;const n=t.querySelector(`[data-panel-group][data-panel-group-id="${e}"]`);return n||null}function Oi(e,t=document){const r=t.querySelector(`[data-panel-resize-handle-id="${e}"]`);return r||null}function Mq(e,t,r,n=document){var o,a,i,s;const c=Oi(t,n),l=po(e,n),p=c?l.indexOf(c):-1,u=(o=(a=r[p])===null||a===void 0?void 0:a.id)!==null&&o!==void 0?o:null,m=(i=(s=r[p+1])===null||s===void 0?void 0:s.id)!==null&&i!==void 0?i:null;return[u,m]}function Oq({committedValuesRef:e,eagerValuesRef:t,groupId:r,layout:n,panelDataArray:o,panelGroupElement:a,setLayout:i}){yt({didWarnAboutMissingResizeHandle:!1}),jr(()=>{if(!a)return;const s=po(r,a);for(let c=0;c<o.length-1;c++){const{valueMax:l,valueMin:p,valueNow:u}=Aq({layout:n,panelsArray:o,pivotIndices:[c,c+1]}),m=s[c];if(m!=null){const b=o[c];ye(b,`No panel data found for index "${c}"`),m.setAttribute("aria-controls",b.id),m.setAttribute("aria-valuemax",""+Math.round(l)),m.setAttribute("aria-valuemin",""+Math.round(p)),m.setAttribute("aria-valuenow",u!=null?""+Math.round(u):"")}}return()=>{s.forEach((c,l)=>{c.removeAttribute("aria-controls"),c.removeAttribute("aria-valuemax"),c.removeAttribute("aria-valuemin"),c.removeAttribute("aria-valuenow")})}},[r,n,o,a]),Ir(()=>{if(!a)return;const s=t.current;ye(s,"Eager values not found");const{panelDataArray:c}=s,l=mE(r,a);ye(l!=null,`No group found for id "${r}"`);const p=po(r,a);ye(p,`No resize handles found for group id "${r}"`);const u=p.map(m=>{const b=m.getAttribute("data-panel-resize-handle-id");ye(b,"Resize handle element has no handle id attribute");const[g,h]=Mq(r,b,c,a);if(g==null||h==null)return()=>{};const v=y=>{if(!y.defaultPrevented)switch(y.key){case"Enter":{y.preventDefault();const x=c.findIndex(w=>w.id===g);if(x>=0){const w=c[x];ye(w,`No panel data found for index ${x}`);const S=n[x],{collapsedSize:_=0,collapsible:R,minSize:C=0}=w.constraints;if(S!=null&&R){const A=Gn({delta:xt(S,_)?C-_:_-S,initialLayout:n,panelConstraints:c.map(P=>P.constraints),pivotIndices:pE(r,b,a),prevLayout:n,trigger:"keyboard"});n!==A&&i(A)}}break}}};return m.addEventListener("keydown",v),()=>{m.removeEventListener("keydown",v)}});return()=>{u.forEach(m=>m())}},[a,e,t,r,n,o,i])}function bb(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}function hE(e,t){const r=e==="horizontal",{x:n,y:o}=Ai(t);return r?n:o}function Iq(e,t,r,n,o){const a=r==="horizontal",i=Oi(t,o);ye(i,`No resize handle element found for id "${t}"`);const s=i.getAttribute("data-panel-group-id");ye(s,"Resize handle element has no group id attribute");let{initialCursorPosition:c}=n;const l=hE(r,e),p=mE(s,o);ye(p,`No group element found for id "${s}"`);const u=p.getBoundingClientRect(),m=a?u.width:u.height;return(l-c)/m*100}function jq(e,t,r,n,o,a){if(oE(e)){const i=r==="horizontal";let s=0;e.shiftKey?s=100:o!=null?s=o:s=10;let c=0;switch(e.key){case"ArrowDown":c=i?0:s;break;case"ArrowLeft":c=i?-s:0;break;case"ArrowRight":c=i?s:0;break;case"ArrowUp":c=i?0:-s;break;case"End":c=100;break;case"Home":c=-100;break}return c}else return n==null?0:Iq(e,t,r,n,a)}function Dq({panelDataArray:e}){const t=Array(e.length),r=e.map(a=>a.constraints);let n=0,o=100;for(let a=0;a<e.length;a++){const i=r[a];ye(i,`Panel constraints not found for index ${a}`);const{defaultSize:s}=i;s!=null&&(n++,t[a]=s,o-=s)}for(let a=0;a<e.length;a++){const i=r[a];ye(i,`Panel constraints not found for index ${a}`);const{defaultSize:s}=i;if(s!=null)continue;const c=e.length-n,l=o/c;n++,t[a]=l,o-=l}return t}function Qr(e,t,r){t.forEach((n,o)=>{const a=e[o];ye(a,`Panel data not found for index ${o}`);const{callbacks:i,constraints:s,id:c}=a,{collapsedSize:l=0,collapsible:p}=s,u=r[c];if(u==null||n!==u){r[c]=n;const{onCollapse:m,onExpand:b,onResize:g}=i;g&&g(n,u),p&&(m||b)&&(b&&(u==null||nr(u,l))&&!nr(n,l)&&b(),m&&(u==null||!nr(u,l))&&nr(n,l)&&m())}})}function ia(e,t){if(e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(e[r]!=t[r])return!1;return!0}function kq({defaultSize:e,dragState:t,layout:r,panelData:n,panelIndex:o,precision:a=3}){const i=r[o];let s;return i==null?s=e!=null?e.toPrecision(a):"1":n.length===1?s="1":s=i.toPrecision(a),{flexBasis:0,flexGrow:s,flexShrink:1,overflow:"hidden",pointerEvents:t!==null?"none":void 0}}function $q(e,t=10){let r=null;return(...o)=>{r!==null&&clearTimeout(r),r=setTimeout(()=>{e(...o)},t)}}function yb(e){try{if(typeof localStorage<"u")e.getItem=t=>localStorage.getItem(t),e.setItem=(t,r)=>{localStorage.setItem(t,r)};else throw new Error("localStorage not supported in this environment")}catch(t){console.error(t),e.getItem=()=>null,e.setItem=()=>{}}}function gE(e){return`react-resizable-panels:${e}`}function vE(e){return e.map(t=>{const{constraints:r,id:n,idIsFromProps:o,order:a}=t;return o?n:a?`${a}:${JSON.stringify(r)}`:JSON.stringify(r)}).sort((t,r)=>t.localeCompare(r)).join(",")}function bE(e,t){try{const r=gE(e),n=t.getItem(r);if(n){const o=JSON.parse(n);if(typeof o=="object"&&o!=null)return o}}catch{}return null}function Lq(e,t,r){var n,o;const a=(n=bE(e,r))!==null&&n!==void 0?n:{},i=vE(t);return(o=a[i])!==null&&o!==void 0?o:null}function Fq(e,t,r,n,o){var a;const i=gE(e),s=vE(t),c=(a=bE(e,o))!==null&&a!==void 0?a:{};c[s]={expandToSizes:Object.fromEntries(r.entries()),layout:n};try{o.setItem(i,JSON.stringify(c))}catch(l){console.error(l)}}function xb({layout:e,panelConstraints:t}){const r=[...e],n=r.reduce((a,i)=>a+i,0);if(r.length!==t.length)throw Error(`Invalid ${t.length} panel layout: ${r.map(a=>`${a}%`).join(", ")}`);if(!xt(n,100)&&r.length>0)for(let a=0;a<t.length;a++){const i=r[a];ye(i!=null,`No layout data found for index ${a}`);const s=100/n*i;r[a]=s}let o=0;for(let a=0;a<t.length;a++){const i=r[a];ye(i!=null,`No layout data found for index ${a}`);const s=tn({panelConstraints:t,panelIndex:a,size:i});i!=s&&(o+=i-s,r[a]=s)}if(!xt(o,0))for(let a=0;a<t.length;a++){const i=r[a];ye(i!=null,`No layout data found for index ${a}`);const s=i+o,c=tn({panelConstraints:t,panelIndex:a,size:s});if(i!==c&&(o-=c-i,r[a]=c,xt(o,0)))break}return r}const Bq=100,Un={getItem:e=>(yb(Un),Un.getItem(e)),setItem:(e,t)=>{yb(Un),Un.setItem(e,t)}},wb={};function yE({autoSaveId:e=null,children:t,className:r="",direction:n,forwardedRef:o,id:a=null,onLayout:i=null,keyboardResizeBy:s=null,storage:c=Un,style:l,tagName:p="div",...u}){const m=mp(a),b=yt(null),[g,h]=an(null),[v,y]=an([]),x=Tq(),w=yt({}),S=yt(new Map),_=yt(0),R=yt({autoSaveId:e,direction:n,dragState:g,id:m,keyboardResizeBy:s,onLayout:i,storage:c}),C=yt({layout:v,panelDataArray:[],panelDataArrayChanged:!1});yt({didLogIdAndOrderWarning:!1,didLogPanelConstraintsWarning:!1,prevPanelIds:[]}),tE(o,()=>({getId:()=>R.current.id,getLayout:()=>{const{layout:F}=C.current;return F},setLayout:F=>{const{onLayout:U}=R.current,{layout:Q,panelDataArray:K}=C.current,q=xb({layout:F,panelConstraints:K.map(W=>W.constraints)});bb(Q,q)||(y(q),C.current.layout=q,U&&U(q),Qr(K,q,w.current))}}),[]),jr(()=>{R.current.autoSaveId=e,R.current.direction=n,R.current.dragState=g,R.current.id=m,R.current.onLayout=i,R.current.storage=c}),Oq({committedValuesRef:R,eagerValuesRef:C,groupId:m,layout:v,panelDataArray:C.current.panelDataArray,setLayout:y,panelGroupElement:b.current}),Ir(()=>{const{panelDataArray:F}=C.current;if(e){if(v.length===0||v.length!==F.length)return;let U=wb[e];U==null&&(U=$q(Fq,Bq),wb[e]=U);const Q=[...F],K=new Map(S.current);U(e,Q,K,v,c)}},[e,v,c]),Ir(()=>{});const A=gt(F=>{const{onLayout:U}=R.current,{layout:Q,panelDataArray:K}=C.current;if(F.constraints.collapsible){const q=K.map(ne=>ne.constraints),{collapsedSize:W=0,panelSize:re,pivotIndices:J}=Ar(K,F,Q);if(ye(re!=null,`Panel size not found for panel "${F.id}"`),!nr(re,W)){S.current.set(F.id,re);const V=en(K,F)===K.length-1?re-W:W-re,ae=Gn({delta:V,initialLayout:Q,panelConstraints:q,pivotIndices:J,prevLayout:Q,trigger:"imperative-api"});ia(Q,ae)||(y(ae),C.current.layout=ae,U&&U(ae),Qr(K,ae,w.current))}}},[]),P=gt((F,U)=>{const{onLayout:Q}=R.current,{layout:K,panelDataArray:q}=C.current;if(F.constraints.collapsible){const W=q.map(I=>I.constraints),{collapsedSize:re=0,panelSize:J=0,minSize:ne=0,pivotIndices:V}=Ar(q,F,K),ae=U??ne;if(nr(J,re)){const I=S.current.get(F.id),ee=I!=null&&I>=ae?I:ae,me=en(q,F)===q.length-1?J-ee:ee-J,ge=Gn({delta:me,initialLayout:K,panelConstraints:W,pivotIndices:V,prevLayout:K,trigger:"imperative-api"});ia(K,ge)||(y(ge),C.current.layout=ge,Q&&Q(ge),Qr(q,ge,w.current))}}},[]),k=gt(F=>{const{layout:U,panelDataArray:Q}=C.current,{panelSize:K}=Ar(Q,F,U);return ye(K!=null,`Panel size not found for panel "${F.id}"`),K},[]),j=gt((F,U)=>{const{panelDataArray:Q}=C.current,K=en(Q,F);return kq({defaultSize:U,dragState:g,layout:v,panelData:Q,panelIndex:K})},[g,v]),L=gt(F=>{const{layout:U,panelDataArray:Q}=C.current,{collapsedSize:K=0,collapsible:q,panelSize:W}=Ar(Q,F,U);return ye(W!=null,`Panel size not found for panel "${F.id}"`),q===!0&&nr(W,K)},[]),N=gt(F=>{const{layout:U,panelDataArray:Q}=C.current,{collapsedSize:K=0,collapsible:q,panelSize:W}=Ar(Q,F,U);return ye(W!=null,`Panel size not found for panel "${F.id}"`),!q||Fr(W,K)>0},[]),D=gt(F=>{const{panelDataArray:U}=C.current;U.push(F),U.sort((Q,K)=>{const q=Q.order,W=K.order;return q==null&&W==null?0:q==null?-1:W==null?1:q-W}),C.current.panelDataArrayChanged=!0,x()},[x]);jr(()=>{if(C.current.panelDataArrayChanged){C.current.panelDataArrayChanged=!1;const{autoSaveId:F,onLayout:U,storage:Q}=R.current,{layout:K,panelDataArray:q}=C.current;let W=null;if(F){const J=Lq(F,q,Q);J&&(S.current=new Map(Object.entries(J.expandToSizes)),W=J.layout)}W==null&&(W=Dq({panelDataArray:q}));const re=xb({layout:W,panelConstraints:q.map(J=>J.constraints)});bb(K,re)||(y(re),C.current.layout=re,U&&U(re),Qr(q,re,w.current))}}),jr(()=>{const F=C.current;return()=>{F.layout=[]}},[]);const $=gt(F=>{let U=!1;const Q=b.current;return Q&&window.getComputedStyle(Q,null).getPropertyValue("direction")==="rtl"&&(U=!0),function(q){q.preventDefault();const W=b.current;if(!W)return()=>null;const{direction:re,dragState:J,id:ne,keyboardResizeBy:V,onLayout:ae}=R.current,{layout:I,panelDataArray:ee}=C.current,{initialLayout:pe}=J??{},me=pE(ne,F,W);let ge=jq(q,F,re,J,V,W);const fe=re==="horizontal";fe&&U&&(ge=-ge);const Ee=ee.map(Oe=>Oe.constraints),Fe=Gn({delta:ge,initialLayout:pe??I,panelConstraints:Ee,pivotIndices:me,prevLayout:I,trigger:oE(q)?"keyboard":"mouse-or-touch"}),we=!ia(I,Fe);(aE(q)||iE(q))&&_.current!=ge&&(_.current=ge,!we&&ge!==0?fe?du(F,ge<0?cE:lE):du(F,ge<0?uE:dE):du(F,0)),we&&(y(Fe),C.current.layout=Fe,ae&&ae(Fe),Qr(ee,Fe,w.current))}},[]),O=gt((F,U)=>{const{onLayout:Q}=R.current,{layout:K,panelDataArray:q}=C.current,W=q.map(I=>I.constraints),{panelSize:re,pivotIndices:J}=Ar(q,F,K);ye(re!=null,`Panel size not found for panel "${F.id}"`);const V=en(q,F)===q.length-1?re-U:U-re,ae=Gn({delta:V,initialLayout:K,panelConstraints:W,pivotIndices:J,prevLayout:K,trigger:"imperative-api"});ia(K,ae)||(y(ae),C.current.layout=ae,Q&&Q(ae),Qr(q,ae,w.current))},[]),G=gt((F,U)=>{const{layout:Q,panelDataArray:K}=C.current,{collapsedSize:q=0,collapsible:W}=U,{collapsedSize:re=0,collapsible:J,maxSize:ne=100,minSize:V=0}=F.constraints,{panelSize:ae}=Ar(K,F,Q);ae!=null&&(W&&J&&nr(ae,q)?nr(q,re)||O(F,re):ae<V?O(F,V):ae>ne&&O(F,ne))},[O]),H=gt((F,U)=>{const{direction:Q}=R.current,{layout:K}=C.current;if(!b.current)return;const q=Oi(F,b.current);ye(q,`Drag handle element not found for id "${F}"`);const W=hE(Q,U);h({dragHandleId:F,dragHandleRect:q.getBoundingClientRect(),initialCursorPosition:W,initialLayout:K})},[]),z=gt(()=>{h(null)},[]),oe=gt(F=>{const{panelDataArray:U}=C.current,Q=en(U,F);Q>=0&&(U.splice(Q,1),delete w.current[F.id],C.current.panelDataArrayChanged=!0,x())},[x]),Z=mq(()=>({collapsePanel:A,direction:n,dragState:g,expandPanel:P,getPanelSize:k,getPanelStyle:j,groupId:m,isPanelCollapsed:L,isPanelExpanded:N,reevaluatePanelConstraints:G,registerPanel:D,registerResizeHandle:$,resizePanel:O,startDragging:H,stopDragging:z,unregisterPanel:oe,panelGroupElement:b.current}),[A,g,n,P,k,j,m,L,N,G,D,$,O,H,z,oe]),te={display:"flex",flexDirection:n==="horizontal"?"row":"column",height:"100%",overflow:"hidden",width:"100%"};return hn(Ni.Provider,{value:Z},hn(p,{...u,children:t,className:r,id:a,ref:b,style:{...te,...l},"data-panel-group":"","data-panel-group-direction":n,"data-panel-group-id":m}))}const xE=QR((e,t)=>hn(yE,{...e,forwardedRef:t}));yE.displayName="PanelGroup";xE.displayName="forwardRef(PanelGroup)";function en(e,t){return e.findIndex(r=>r===t||r.id===t.id)}function Ar(e,t,r){const n=en(e,t),a=n===e.length-1?[n-1,n]:[n,n+1],i=r[n];return{...t.constraints,panelSize:i,pivotIndices:a}}function zq({disabled:e,handleId:t,resizeHandler:r,panelGroupElement:n}){Ir(()=>{if(e||r==null||n==null)return;const o=Oi(t,n);if(o==null)return;const a=i=>{if(!i.defaultPrevented)switch(i.key){case"ArrowDown":case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"End":case"Home":{i.preventDefault(),r(i);break}case"F6":{i.preventDefault();const s=o.getAttribute("data-panel-group-id");ye(s,`No group element found for id "${s}"`);const c=po(s,n),l=fE(s,t,n);ye(l!==null,`No resize element found for id "${t}"`);const p=i.shiftKey?l>0?l-1:c.length-1:l+1<c.length?l+1:0;c[p].focus();break}}};return o.addEventListener("keydown",a),()=>{o.removeEventListener("keydown",a)}},[n,e,t,r])}function wE({children:e=null,className:t="",disabled:r=!1,hitAreaMargins:n,id:o,onBlur:a,onDragging:i,onFocus:s,style:c={},tabIndex:l=0,tagName:p="div",...u}){var m,b;const g=yt(null),h=yt({onDragging:i});Ir(()=>{h.current.onDragging=i});const v=eE(Ni);if(v===null)throw Error("PanelResizeHandle components must be rendered within a PanelGroup container");const{direction:y,groupId:x,registerResizeHandle:w,startDragging:S,stopDragging:_,panelGroupElement:R}=v,C=mp(o),[A,P]=an("inactive"),[k,j]=an(!1),[L,N]=an(null),D=yt({state:A});jr(()=>{D.current.state=A}),Ir(()=>{if(r)N(null);else{const H=w(C);N(()=>H)}},[r,C,w]);const $=(m=n==null?void 0:n.coarse)!==null&&m!==void 0?m:15,O=(b=n==null?void 0:n.fine)!==null&&b!==void 0?b:5;return Ir(()=>{if(r||L==null)return;const H=g.current;return ye(H,"Element ref not attached"),Pq(C,H,y,{coarse:$,fine:O},(oe,Z,te)=>{if(Z)switch(oe){case"down":{P("drag"),ye(te,'Expected event to be defined for "down" action'),S(C,te);const{onDragging:F}=h.current;F&&F(!0);break}case"move":{const{state:F}=D.current;F!=="drag"&&P("hover"),ye(te,'Expected event to be defined for "move" action'),L(te);break}case"up":{P("hover"),_();const{onDragging:F}=h.current;F&&F(!1);break}}else P("inactive")})},[$,y,r,O,w,C,L,S,_]),zq({disabled:r,handleId:C,resizeHandler:L,panelGroupElement:R}),hn(p,{...u,children:e,className:t,id:o,onBlur:()=>{j(!1),a==null||a()},onFocus:()=>{j(!0),s==null||s()},ref:g,role:"separator",style:{...{touchAction:"none",userSelect:"none"},...c},tabIndex:l,"data-panel-group-direction":y,"data-panel-group-id":x,"data-resize-handle":"","data-resize-handle-active":A==="drag"?"pointer":k?"keyboard":void 0,"data-resize-handle-state":A,"data-panel-resize-handle-enabled":!r,"data-panel-resize-handle-id":C})}wE.displayName="PanelResizeHandle";const qq=({className:e,...t})=>f.jsx(xE,{className:M("flex h-full w-full data-[panel-group-direction=vertical]:flex-col",e),...t}),Hq=nE,Vq=({withHandle:e,className:t,...r})=>f.jsx(wE,{className:M("relative flex w-px items-center justify-center bg-border after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring focus-visible:ring-offset-1 data-[panel-group-direction=vertical]:h-px data-[panel-group-direction=vertical]:w-full data-[panel-group-direction=vertical]:after:left-0 data-[panel-group-direction=vertical]:after:h-1 data-[panel-group-direction=vertical]:after:w-full data-[panel-group-direction=vertical]:after:-translate-y-1/2 data-[panel-group-direction=vertical]:after:translate-x-0 [&[data-panel-group-direction=vertical]>div]:rotate-90",t),...r,children:e&&f.jsx("div",{className:"z-10 flex h-4 w-3 items-center justify-center rounded-sm border bg-border",children:f.jsx(F1,{className:"h-2.5 w-2.5"})})});function mo(e,[t,r]){return Math.min(r,Math.max(t,e))}function Gq(e,t){return d.useReducer((r,n)=>t[r][n]??r,e)}var bp="ScrollArea",[SE,u3]=De(bp),[Uq,Nt]=SE(bp),CE=d.forwardRef((e,t)=>{const{__scopeScrollArea:r,type:n="hover",dir:o,scrollHideDelay:a=600,...i}=e,[s,c]=d.useState(null),[l,p]=d.useState(null),[u,m]=d.useState(null),[b,g]=d.useState(null),[h,v]=d.useState(null),[y,x]=d.useState(0),[w,S]=d.useState(0),[_,R]=d.useState(!1),[C,A]=d.useState(!1),P=de(t,j=>c(j)),k=Ft(o);return f.jsx(Uq,{scope:r,type:n,dir:k,scrollHideDelay:a,scrollArea:s,viewport:l,onViewportChange:p,content:u,onContentChange:m,scrollbarX:b,onScrollbarXChange:g,scrollbarXEnabled:_,onScrollbarXEnabledChange:R,scrollbarY:h,onScrollbarYChange:v,scrollbarYEnabled:C,onScrollbarYEnabledChange:A,onCornerWidthChange:x,onCornerHeightChange:S,children:f.jsx(X.div,{dir:k,...i,ref:P,style:{position:"relative","--radix-scroll-area-corner-width":y+"px","--radix-scroll-area-corner-height":w+"px",...e.style}})})});CE.displayName=bp;var _E="ScrollAreaViewport",RE=d.forwardRef((e,t)=>{const{__scopeScrollArea:r,children:n,nonce:o,...a}=e,i=Nt(_E,r),s=d.useRef(null),c=de(t,s,i.onViewportChange);return f.jsxs(f.Fragment,{children:[f.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),f.jsx(X.div,{"data-radix-scroll-area-viewport":"",...a,ref:c,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style},children:f.jsx("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"},children:n})})]})});RE.displayName=_E;var er="ScrollAreaScrollbar",yp=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=Nt(er,e.__scopeScrollArea),{onScrollbarXEnabledChange:a,onScrollbarYEnabledChange:i}=o,s=e.orientation==="horizontal";return d.useEffect(()=>(s?a(!0):i(!0),()=>{s?a(!1):i(!1)}),[s,a,i]),o.type==="hover"?f.jsx(Wq,{...n,ref:t,forceMount:r}):o.type==="scroll"?f.jsx(Kq,{...n,ref:t,forceMount:r}):o.type==="auto"?f.jsx(EE,{...n,ref:t,forceMount:r}):o.type==="always"?f.jsx(xp,{...n,ref:t}):null});yp.displayName=er;var Wq=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=Nt(er,e.__scopeScrollArea),[a,i]=d.useState(!1);return d.useEffect(()=>{const s=o.scrollArea;let c=0;if(s){const l=()=>{window.clearTimeout(c),i(!0)},p=()=>{c=window.setTimeout(()=>i(!1),o.scrollHideDelay)};return s.addEventListener("pointerenter",l),s.addEventListener("pointerleave",p),()=>{window.clearTimeout(c),s.removeEventListener("pointerenter",l),s.removeEventListener("pointerleave",p)}}},[o.scrollArea,o.scrollHideDelay]),f.jsx(Le,{present:r||a,children:f.jsx(EE,{"data-state":a?"visible":"hidden",...n,ref:t})})}),Kq=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=Nt(er,e.__scopeScrollArea),a=e.orientation==="horizontal",i=ji(()=>c("SCROLL_END"),100),[s,c]=Gq("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return d.useEffect(()=>{if(s==="idle"){const l=window.setTimeout(()=>c("HIDE"),o.scrollHideDelay);return()=>window.clearTimeout(l)}},[s,o.scrollHideDelay,c]),d.useEffect(()=>{const l=o.viewport,p=a?"scrollLeft":"scrollTop";if(l){let u=l[p];const m=()=>{const b=l[p];u!==b&&(c("SCROLL"),i()),u=b};return l.addEventListener("scroll",m),()=>l.removeEventListener("scroll",m)}},[o.viewport,a,c,i]),f.jsx(Le,{present:r||s!=="hidden",children:f.jsx(xp,{"data-state":s==="hidden"?"hidden":"visible",...n,ref:t,onPointerEnter:B(e.onPointerEnter,()=>c("POINTER_ENTER")),onPointerLeave:B(e.onPointerLeave,()=>c("POINTER_LEAVE"))})})}),EE=d.forwardRef((e,t)=>{const r=Nt(er,e.__scopeScrollArea),{forceMount:n,...o}=e,[a,i]=d.useState(!1),s=e.orientation==="horizontal",c=ji(()=>{if(r.viewport){const l=r.viewport.offsetWidth<r.viewport.scrollWidth,p=r.viewport.offsetHeight<r.viewport.scrollHeight;i(s?l:p)}},10);return gn(r.viewport,c),gn(r.content,c),f.jsx(Le,{present:n||a,children:f.jsx(xp,{"data-state":a?"visible":"hidden",...o,ref:t})})}),xp=d.forwardRef((e,t)=>{const{orientation:r="vertical",...n}=e,o=Nt(er,e.__scopeScrollArea),a=d.useRef(null),i=d.useRef(0),[s,c]=d.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),l=ME(s.viewport,s.content),p={...n,sizes:s,onSizesChange:c,hasThumb:l>0&&l<1,onThumbChange:m=>a.current=m,onThumbPointerUp:()=>i.current=0,onThumbPointerDown:m=>i.current=m};function u(m,b){return e5(m,i.current,s,b)}return r==="horizontal"?f.jsx(Yq,{...p,ref:t,onThumbPositionChange:()=>{if(o.viewport&&a.current){const m=o.viewport.scrollLeft,b=Sb(m,s,o.dir);a.current.style.transform=`translate3d(${b}px, 0, 0)`}},onWheelScroll:m=>{o.viewport&&(o.viewport.scrollLeft=m)},onDragScroll:m=>{o.viewport&&(o.viewport.scrollLeft=u(m,o.dir))}}):r==="vertical"?f.jsx(Xq,{...p,ref:t,onThumbPositionChange:()=>{if(o.viewport&&a.current){const m=o.viewport.scrollTop,b=Sb(m,s);a.current.style.transform=`translate3d(0, ${b}px, 0)`}},onWheelScroll:m=>{o.viewport&&(o.viewport.scrollTop=m)},onDragScroll:m=>{o.viewport&&(o.viewport.scrollTop=u(m))}}):null}),Yq=d.forwardRef((e,t)=>{const{sizes:r,onSizesChange:n,...o}=e,a=Nt(er,e.__scopeScrollArea),[i,s]=d.useState(),c=d.useRef(null),l=de(t,c,a.onScrollbarXChange);return d.useEffect(()=>{c.current&&s(getComputedStyle(c.current))},[c]),f.jsx(TE,{"data-orientation":"horizontal",...o,ref:l,sizes:r,style:{bottom:0,left:a.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:a.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Ii(r)+"px",...e.style},onThumbPointerDown:p=>e.onThumbPointerDown(p.x),onDragScroll:p=>e.onDragScroll(p.x),onWheelScroll:(p,u)=>{if(a.viewport){const m=a.viewport.scrollLeft+p.deltaX;e.onWheelScroll(m),IE(m,u)&&p.preventDefault()}},onResize:()=>{c.current&&a.viewport&&i&&n({content:a.viewport.scrollWidth,viewport:a.viewport.offsetWidth,scrollbar:{size:c.current.clientWidth,paddingStart:Va(i.paddingLeft),paddingEnd:Va(i.paddingRight)}})}})}),Xq=d.forwardRef((e,t)=>{const{sizes:r,onSizesChange:n,...o}=e,a=Nt(er,e.__scopeScrollArea),[i,s]=d.useState(),c=d.useRef(null),l=de(t,c,a.onScrollbarYChange);return d.useEffect(()=>{c.current&&s(getComputedStyle(c.current))},[c]),f.jsx(TE,{"data-orientation":"vertical",...o,ref:l,sizes:r,style:{top:0,right:a.dir==="ltr"?0:void 0,left:a.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Ii(r)+"px",...e.style},onThumbPointerDown:p=>e.onThumbPointerDown(p.y),onDragScroll:p=>e.onDragScroll(p.y),onWheelScroll:(p,u)=>{if(a.viewport){const m=a.viewport.scrollTop+p.deltaY;e.onWheelScroll(m),IE(m,u)&&p.preventDefault()}},onResize:()=>{c.current&&a.viewport&&i&&n({content:a.viewport.scrollHeight,viewport:a.viewport.offsetHeight,scrollbar:{size:c.current.clientHeight,paddingStart:Va(i.paddingTop),paddingEnd:Va(i.paddingBottom)}})}})}),[Zq,PE]=SE(er),TE=d.forwardRef((e,t)=>{const{__scopeScrollArea:r,sizes:n,hasThumb:o,onThumbChange:a,onThumbPointerUp:i,onThumbPointerDown:s,onThumbPositionChange:c,onDragScroll:l,onWheelScroll:p,onResize:u,...m}=e,b=Nt(er,r),[g,h]=d.useState(null),v=de(t,P=>h(P)),y=d.useRef(null),x=d.useRef(""),w=b.viewport,S=n.content-n.viewport,_=Te(p),R=Te(c),C=ji(u,10);function A(P){if(y.current){const k=P.clientX-y.current.left,j=P.clientY-y.current.top;l({x:k,y:j})}}return d.useEffect(()=>{const P=k=>{const j=k.target;(g==null?void 0:g.contains(j))&&_(k,S)};return document.addEventListener("wheel",P,{passive:!1}),()=>document.removeEventListener("wheel",P,{passive:!1})},[w,g,S,_]),d.useEffect(R,[n,R]),gn(g,C),gn(b.content,C),f.jsx(Zq,{scope:r,scrollbar:g,hasThumb:o,onThumbChange:Te(a),onThumbPointerUp:Te(i),onThumbPositionChange:R,onThumbPointerDown:Te(s),children:f.jsx(X.div,{...m,ref:v,style:{position:"absolute",...m.style},onPointerDown:B(e.onPointerDown,P=>{P.button===0&&(P.target.setPointerCapture(P.pointerId),y.current=g.getBoundingClientRect(),x.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",b.viewport&&(b.viewport.style.scrollBehavior="auto"),A(P))}),onPointerMove:B(e.onPointerMove,A),onPointerUp:B(e.onPointerUp,P=>{const k=P.target;k.hasPointerCapture(P.pointerId)&&k.releasePointerCapture(P.pointerId),document.body.style.webkitUserSelect=x.current,b.viewport&&(b.viewport.style.scrollBehavior=""),y.current=null})})})}),Ha="ScrollAreaThumb",NE=d.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=PE(Ha,e.__scopeScrollArea);return f.jsx(Le,{present:r||o.hasThumb,children:f.jsx(Jq,{ref:t,...n})})}),Jq=d.forwardRef((e,t)=>{const{__scopeScrollArea:r,style:n,...o}=e,a=Nt(Ha,r),i=PE(Ha,r),{onThumbPositionChange:s}=i,c=de(t,u=>i.onThumbChange(u)),l=d.useRef(void 0),p=ji(()=>{l.current&&(l.current(),l.current=void 0)},100);return d.useEffect(()=>{const u=a.viewport;if(u){const m=()=>{if(p(),!l.current){const b=t5(u,s);l.current=b,s()}};return s(),u.addEventListener("scroll",m),()=>u.removeEventListener("scroll",m)}},[a.viewport,p,s]),f.jsx(X.div,{"data-state":i.hasThumb?"visible":"hidden",...o,ref:c,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...n},onPointerDownCapture:B(e.onPointerDownCapture,u=>{const b=u.target.getBoundingClientRect(),g=u.clientX-b.left,h=u.clientY-b.top;i.onThumbPointerDown({x:g,y:h})}),onPointerUp:B(e.onPointerUp,i.onThumbPointerUp)})});NE.displayName=Ha;var wp="ScrollAreaCorner",AE=d.forwardRef((e,t)=>{const r=Nt(wp,e.__scopeScrollArea),n=!!(r.scrollbarX&&r.scrollbarY);return r.type!=="scroll"&&n?f.jsx(Qq,{...e,ref:t}):null});AE.displayName=wp;var Qq=d.forwardRef((e,t)=>{const{__scopeScrollArea:r,...n}=e,o=Nt(wp,r),[a,i]=d.useState(0),[s,c]=d.useState(0),l=!!(a&&s);return gn(o.scrollbarX,()=>{var u;const p=((u=o.scrollbarX)==null?void 0:u.offsetHeight)||0;o.onCornerHeightChange(p),c(p)}),gn(o.scrollbarY,()=>{var u;const p=((u=o.scrollbarY)==null?void 0:u.offsetWidth)||0;o.onCornerWidthChange(p),i(p)}),l?f.jsx(X.div,{...n,ref:t,style:{width:a,height:s,position:"absolute",right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function Va(e){return e?parseInt(e,10):0}function ME(e,t){const r=e/t;return isNaN(r)?0:r}function Ii(e){const t=ME(e.viewport,e.content),r=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,n=(e.scrollbar.size-r)*t;return Math.max(n,18)}function e5(e,t,r,n="ltr"){const o=Ii(r),a=o/2,i=t||a,s=o-i,c=r.scrollbar.paddingStart+i,l=r.scrollbar.size-r.scrollbar.paddingEnd-s,p=r.content-r.viewport,u=n==="ltr"?[0,p]:[p*-1,0];return OE([c,l],u)(e)}function Sb(e,t,r="ltr"){const n=Ii(t),o=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,a=t.scrollbar.size-o,i=t.content-t.viewport,s=a-n,c=r==="ltr"?[0,i]:[i*-1,0],l=mo(e,c);return OE([0,i],[0,s])(l)}function OE(e,t){return r=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const n=(t[1]-t[0])/(e[1]-e[0]);return t[0]+n*(r-e[0])}}function IE(e,t){return e>0&&e<t}var t5=(e,t=()=>{})=>{let r={left:e.scrollLeft,top:e.scrollTop},n=0;return function o(){const a={left:e.scrollLeft,top:e.scrollTop},i=r.left!==a.left,s=r.top!==a.top;(i||s)&&t(),r=a,n=window.requestAnimationFrame(o)}(),()=>window.cancelAnimationFrame(n)};function ji(e,t){const r=Te(e),n=d.useRef(0);return d.useEffect(()=>()=>window.clearTimeout(n.current),[]),d.useCallback(()=>{window.clearTimeout(n.current),n.current=window.setTimeout(r,t)},[r,t])}function gn(e,t){const r=Te(t);He(()=>{let n=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(n),n=window.requestAnimationFrame(r)});return o.observe(e),()=>{window.cancelAnimationFrame(n),o.unobserve(e)}}},[e,r])}var jE=CE,r5=RE,n5=AE;const DE=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(jE,{ref:n,className:M("relative overflow-hidden",e),...r,children:[f.jsx(r5,{className:"h-full w-full rounded-[inherit]",children:t}),f.jsx(Sp,{}),f.jsx(n5,{})]}));DE.displayName=jE.displayName;const Sp=d.forwardRef(({className:e,orientation:t="vertical",...r},n)=>f.jsx(yp,{ref:n,orientation:t,className:M("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...r,children:f.jsx(NE,{className:"relative flex-1 rounded-full bg-border"})}));Sp.displayName=yp.displayName;var o5=[" ","Enter","ArrowUp","ArrowDown"],a5=[" ","Enter"],Lo="Select",[Di,ki,i5]=cr(Lo),[Mn,d3]=De(Lo,[i5,Jt]),$i=Jt(),[s5,_r]=Mn(Lo),[c5,l5]=Mn(Lo),kE=e=>{const{__scopeSelect:t,children:r,open:n,defaultOpen:o,onOpenChange:a,value:i,defaultValue:s,onValueChange:c,dir:l,name:p,autoComplete:u,disabled:m,required:b,form:g}=e,h=$i(t),[v,y]=d.useState(null),[x,w]=d.useState(null),[S,_]=d.useState(!1),R=Ft(l),[C=!1,A]=$e({prop:n,defaultProp:o,onChange:a}),[P,k]=$e({prop:i,defaultProp:s,onChange:c}),j=d.useRef(null),L=v?g||!!v.closest("form"):!0,[N,D]=d.useState(new Set),$=Array.from(N).map(O=>O.props.value).join(";");return f.jsx(Pn,{...h,children:f.jsxs(s5,{required:b,scope:t,trigger:v,onTriggerChange:y,valueNode:x,onValueNodeChange:w,valueNodeHasChildren:S,onValueNodeHasChildrenChange:_,contentId:Ue(),value:P,onValueChange:k,open:C,onOpenChange:A,dir:R,triggerPointerDownPosRef:j,disabled:m,children:[f.jsx(Di.Provider,{scope:t,children:f.jsx(c5,{scope:e.__scopeSelect,onNativeOptionAdd:d.useCallback(O=>{D(G=>new Set(G).add(O))},[]),onNativeOptionRemove:d.useCallback(O=>{D(G=>{const H=new Set(G);return H.delete(O),H})},[]),children:r})}),L?f.jsxs(cP,{"aria-hidden":!0,required:b,tabIndex:-1,name:p,autoComplete:u,value:P,onChange:O=>k(O.target.value),disabled:m,form:g,children:[P===void 0?f.jsx("option",{value:""}):null,Array.from(N)]},$):null]})})};kE.displayName=Lo;var $E="SelectTrigger",LE=d.forwardRef((e,t)=>{const{__scopeSelect:r,disabled:n=!1,...o}=e,a=$i(r),i=_r($E,r),s=i.disabled||n,c=de(t,i.onTriggerChange),l=ki(r),p=d.useRef("touch"),[u,m,b]=lP(h=>{const v=l().filter(w=>!w.disabled),y=v.find(w=>w.value===i.value),x=uP(v,h,y);x!==void 0&&i.onValueChange(x.value)}),g=h=>{s||(i.onOpenChange(!0),b()),h&&(i.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)})};return f.jsx(Tn,{asChild:!0,...a,children:f.jsx(X.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":sP(i.value)?"":void 0,...o,ref:c,onClick:B(o.onClick,h=>{h.currentTarget.focus(),p.current!=="mouse"&&g(h)}),onPointerDown:B(o.onPointerDown,h=>{p.current=h.pointerType;const v=h.target;v.hasPointerCapture(h.pointerId)&&v.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&h.pointerType==="mouse"&&(g(h),h.preventDefault())}),onKeyDown:B(o.onKeyDown,h=>{const v=u.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&m(h.key),!(v&&h.key===" ")&&o5.includes(h.key)&&(g(),h.preventDefault())})})})});LE.displayName=$E;var FE="SelectValue",BE=d.forwardRef((e,t)=>{const{__scopeSelect:r,className:n,style:o,children:a,placeholder:i="",...s}=e,c=_r(FE,r),{onValueNodeHasChildrenChange:l}=c,p=a!==void 0,u=de(t,c.onValueNodeChange);return He(()=>{l(p)},[l,p]),f.jsx(X.span,{...s,ref:u,style:{pointerEvents:"none"},children:sP(c.value)?f.jsx(f.Fragment,{children:i}):a})});BE.displayName=FE;var u5="SelectIcon",zE=d.forwardRef((e,t)=>{const{__scopeSelect:r,children:n,...o}=e;return f.jsx(X.span,{"aria-hidden":!0,...o,ref:t,children:n||"▼"})});zE.displayName=u5;var d5="SelectPortal",qE=e=>f.jsx(zr,{asChild:!0,...e});qE.displayName=d5;var Br="SelectContent",HE=d.forwardRef((e,t)=>{const r=_r(Br,e.__scopeSelect),[n,o]=d.useState();if(He(()=>{o(new DocumentFragment)},[]),!r.open){const a=n;return a?ho.createPortal(f.jsx(VE,{scope:e.__scopeSelect,children:f.jsx(Di.Slot,{scope:e.__scopeSelect,children:f.jsx("div",{children:e.children})})}),a):null}return f.jsx(GE,{...e,ref:t})});HE.displayName=Br;var It=10,[VE,Rr]=Mn(Br),f5="SelectContentImpl",GE=d.forwardRef((e,t)=>{const{__scopeSelect:r,position:n="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:a,onPointerDownOutside:i,side:s,sideOffset:c,align:l,alignOffset:p,arrowPadding:u,collisionBoundary:m,collisionPadding:b,sticky:g,hideWhenDetached:h,avoidCollisions:v,...y}=e,x=_r(Br,r),[w,S]=d.useState(null),[_,R]=d.useState(null),C=de(t,q=>S(q)),[A,P]=d.useState(null),[k,j]=d.useState(null),L=ki(r),[N,D]=d.useState(!1),$=d.useRef(!1);d.useEffect(()=>{if(w)return ei(w)},[w]),Ja();const O=d.useCallback(q=>{const[W,...re]=L().map(V=>V.ref.current),[J]=re.slice(-1),ne=document.activeElement;for(const V of q)if(V===ne||(V==null||V.scrollIntoView({block:"nearest"}),V===W&&_&&(_.scrollTop=0),V===J&&_&&(_.scrollTop=_.scrollHeight),V==null||V.focus(),document.activeElement!==ne))return},[L,_]),G=d.useCallback(()=>O([A,w]),[O,A,w]);d.useEffect(()=>{N&&G()},[N,G]);const{onOpenChange:H,triggerPointerDownPosRef:z}=x;d.useEffect(()=>{if(w){let q={x:0,y:0};const W=J=>{var ne,V;q={x:Math.abs(Math.round(J.pageX)-(((ne=z.current)==null?void 0:ne.x)??0)),y:Math.abs(Math.round(J.pageY)-(((V=z.current)==null?void 0:V.y)??0))}},re=J=>{q.x<=10&&q.y<=10?J.preventDefault():w.contains(J.target)||H(!1),document.removeEventListener("pointermove",W),z.current=null};return z.current!==null&&(document.addEventListener("pointermove",W),document.addEventListener("pointerup",re,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",W),document.removeEventListener("pointerup",re,{capture:!0})}}},[w,H,z]),d.useEffect(()=>{const q=()=>H(!1);return window.addEventListener("blur",q),window.addEventListener("resize",q),()=>{window.removeEventListener("blur",q),window.removeEventListener("resize",q)}},[H]);const[oe,Z]=lP(q=>{const W=L().filter(ne=>!ne.disabled),re=W.find(ne=>ne.ref.current===document.activeElement),J=uP(W,q,re);J&&setTimeout(()=>J.ref.current.focus())}),te=d.useCallback((q,W,re)=>{const J=!$.current&&!re;(x.value!==void 0&&x.value===W||J)&&(P(q),J&&($.current=!0))},[x.value]),F=d.useCallback(()=>w==null?void 0:w.focus(),[w]),U=d.useCallback((q,W,re)=>{const J=!$.current&&!re;(x.value!==void 0&&x.value===W||J)&&j(q)},[x.value]),Q=n==="popper"?td:UE,K=Q===td?{side:s,sideOffset:c,align:l,alignOffset:p,arrowPadding:u,collisionBoundary:m,collisionPadding:b,sticky:g,hideWhenDetached:h,avoidCollisions:v}:{};return f.jsx(VE,{scope:r,content:w,viewport:_,onViewportChange:R,itemRefCallback:te,selectedItem:A,onItemLeave:F,itemTextRefCallback:U,focusSelectedItem:G,selectedItemText:k,position:n,isPositioned:N,searchRef:oe,children:f.jsx(yo,{as:st,allowPinchZoom:!0,children:f.jsx(bo,{asChild:!0,trapped:x.open,onMountAutoFocus:q=>{q.preventDefault()},onUnmountAutoFocus:B(o,q=>{var W;(W=x.trigger)==null||W.focus({preventScroll:!0}),q.preventDefault()}),children:f.jsx(ur,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:q=>q.preventDefault(),onDismiss:()=>x.onOpenChange(!1),children:f.jsx(Q,{role:"listbox",id:x.contentId,"data-state":x.open?"open":"closed",dir:x.dir,onContextMenu:q=>q.preventDefault(),...y,...K,onPlaced:()=>D(!0),ref:C,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:B(y.onKeyDown,q=>{const W=q.ctrlKey||q.altKey||q.metaKey;if(q.key==="Tab"&&q.preventDefault(),!W&&q.key.length===1&&Z(q.key),["ArrowUp","ArrowDown","Home","End"].includes(q.key)){let J=L().filter(ne=>!ne.disabled).map(ne=>ne.ref.current);if(["ArrowUp","End"].includes(q.key)&&(J=J.slice().reverse()),["ArrowUp","ArrowDown"].includes(q.key)){const ne=q.target,V=J.indexOf(ne);J=J.slice(V+1)}setTimeout(()=>O(J)),q.preventDefault()}})})})})})})});GE.displayName=f5;var p5="SelectItemAlignedPosition",UE=d.forwardRef((e,t)=>{const{__scopeSelect:r,onPlaced:n,...o}=e,a=_r(Br,r),i=Rr(Br,r),[s,c]=d.useState(null),[l,p]=d.useState(null),u=de(t,C=>p(C)),m=ki(r),b=d.useRef(!1),g=d.useRef(!0),{viewport:h,selectedItem:v,selectedItemText:y,focusSelectedItem:x}=i,w=d.useCallback(()=>{if(a.trigger&&a.valueNode&&s&&l&&h&&v&&y){const C=a.trigger.getBoundingClientRect(),A=l.getBoundingClientRect(),P=a.valueNode.getBoundingClientRect(),k=y.getBoundingClientRect();if(a.dir!=="rtl"){const ne=k.left-A.left,V=P.left-ne,ae=C.left-V,I=C.width+ae,ee=Math.max(I,A.width),pe=window.innerWidth-It,me=mo(V,[It,Math.max(It,pe-ee)]);s.style.minWidth=I+"px",s.style.left=me+"px"}else{const ne=A.right-k.right,V=window.innerWidth-P.right-ne,ae=window.innerWidth-C.right-V,I=C.width+ae,ee=Math.max(I,A.width),pe=window.innerWidth-It,me=mo(V,[It,Math.max(It,pe-ee)]);s.style.minWidth=I+"px",s.style.right=me+"px"}const j=m(),L=window.innerHeight-It*2,N=h.scrollHeight,D=window.getComputedStyle(l),$=parseInt(D.borderTopWidth,10),O=parseInt(D.paddingTop,10),G=parseInt(D.borderBottomWidth,10),H=parseInt(D.paddingBottom,10),z=$+O+N+H+G,oe=Math.min(v.offsetHeight*5,z),Z=window.getComputedStyle(h),te=parseInt(Z.paddingTop,10),F=parseInt(Z.paddingBottom,10),U=C.top+C.height/2-It,Q=L-U,K=v.offsetHeight/2,q=v.offsetTop+K,W=$+O+q,re=z-W;if(W<=U){const ne=j.length>0&&v===j[j.length-1].ref.current;s.style.bottom="0px";const V=l.clientHeight-h.offsetTop-h.offsetHeight,ae=Math.max(Q,K+(ne?F:0)+V+G),I=W+ae;s.style.height=I+"px"}else{const ne=j.length>0&&v===j[0].ref.current;s.style.top="0px";const ae=Math.max(U,$+h.offsetTop+(ne?te:0)+K)+re;s.style.height=ae+"px",h.scrollTop=W-U+h.offsetTop}s.style.margin=`${It}px 0`,s.style.minHeight=oe+"px",s.style.maxHeight=L+"px",n==null||n(),requestAnimationFrame(()=>b.current=!0)}},[m,a.trigger,a.valueNode,s,l,h,v,y,a.dir,n]);He(()=>w(),[w]);const[S,_]=d.useState();He(()=>{l&&_(window.getComputedStyle(l).zIndex)},[l]);const R=d.useCallback(C=>{C&&g.current===!0&&(w(),x==null||x(),g.current=!1)},[w,x]);return f.jsx(h5,{scope:r,contentWrapper:s,shouldExpandOnScrollRef:b,onScrollButtonChange:R,children:f.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:S},children:f.jsx(X.div,{...o,ref:u,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});UE.displayName=p5;var m5="SelectPopperPosition",td=d.forwardRef((e,t)=>{const{__scopeSelect:r,align:n="start",collisionPadding:o=It,...a}=e,i=$i(r);return f.jsx(Eo,{...i,...a,ref:t,align:n,collisionPadding:o,style:{boxSizing:"border-box",...a.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)"}})});td.displayName=m5;var[h5,Cp]=Mn(Br,{}),rd="SelectViewport",WE=d.forwardRef((e,t)=>{const{__scopeSelect:r,nonce:n,...o}=e,a=Rr(rd,r),i=Cp(rd,r),s=de(t,a.onViewportChange),c=d.useRef(0);return f.jsxs(f.Fragment,{children:[f.jsx("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}"},nonce:n}),f.jsx(Di.Slot,{scope:r,children:f.jsx(X.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:s,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:B(o.onScroll,l=>{const p=l.currentTarget,{contentWrapper:u,shouldExpandOnScrollRef:m}=i;if(m!=null&&m.current&&u){const b=Math.abs(c.current-p.scrollTop);if(b>0){const g=window.innerHeight-It*2,h=parseFloat(u.style.minHeight),v=parseFloat(u.style.height),y=Math.max(h,v);if(y<g){const x=y+b,w=Math.min(g,x),S=x-w;u.style.height=w+"px",u.style.bottom==="0px"&&(p.scrollTop=S>0?S:0,u.style.justifyContent="flex-end")}}}c.current=p.scrollTop})})})]})});WE.displayName=rd;var KE="SelectGroup",[g5,v5]=Mn(KE),YE=d.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=Ue();return f.jsx(g5,{scope:r,id:o,children:f.jsx(X.div,{role:"group","aria-labelledby":o,...n,ref:t})})});YE.displayName=KE;var XE="SelectLabel",ZE=d.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=v5(XE,r);return f.jsx(X.div,{id:o.id,...n,ref:t})});ZE.displayName=XE;var Ga="SelectItem",[b5,JE]=Mn(Ga),QE=d.forwardRef((e,t)=>{const{__scopeSelect:r,value:n,disabled:o=!1,textValue:a,...i}=e,s=_r(Ga,r),c=Rr(Ga,r),l=s.value===n,[p,u]=d.useState(a??""),[m,b]=d.useState(!1),g=de(t,x=>{var w;return(w=c.itemRefCallback)==null?void 0:w.call(c,x,n,o)}),h=Ue(),v=d.useRef("touch"),y=()=>{o||(s.onValueChange(n),s.onOpenChange(!1))};if(n==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return f.jsx(b5,{scope:r,value:n,disabled:o,textId:h,isSelected:l,onItemTextChange:d.useCallback(x=>{u(w=>w||((x==null?void 0:x.textContent)??"").trim())},[]),children:f.jsx(Di.ItemSlot,{scope:r,value:n,disabled:o,textValue:p,children:f.jsx(X.div,{role:"option","aria-labelledby":h,"data-highlighted":m?"":void 0,"aria-selected":l&&m,"data-state":l?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...i,ref:g,onFocus:B(i.onFocus,()=>b(!0)),onBlur:B(i.onBlur,()=>b(!1)),onClick:B(i.onClick,()=>{v.current!=="mouse"&&y()}),onPointerUp:B(i.onPointerUp,()=>{v.current==="mouse"&&y()}),onPointerDown:B(i.onPointerDown,x=>{v.current=x.pointerType}),onPointerMove:B(i.onPointerMove,x=>{var w;v.current=x.pointerType,o?(w=c.onItemLeave)==null||w.call(c):v.current==="mouse"&&x.currentTarget.focus({preventScroll:!0})}),onPointerLeave:B(i.onPointerLeave,x=>{var w;x.currentTarget===document.activeElement&&((w=c.onItemLeave)==null||w.call(c))}),onKeyDown:B(i.onKeyDown,x=>{var S;((S=c.searchRef)==null?void 0:S.current)!==""&&x.key===" "||(a5.includes(x.key)&&y(),x.key===" "&&x.preventDefault())})})})})});QE.displayName=Ga;var Wn="SelectItemText",eP=d.forwardRef((e,t)=>{const{__scopeSelect:r,className:n,style:o,...a}=e,i=_r(Wn,r),s=Rr(Wn,r),c=JE(Wn,r),l=l5(Wn,r),[p,u]=d.useState(null),m=de(t,y=>u(y),c.onItemTextChange,y=>{var x;return(x=s.itemTextRefCallback)==null?void 0:x.call(s,y,c.value,c.disabled)}),b=p==null?void 0:p.textContent,g=d.useMemo(()=>f.jsx("option",{value:c.value,disabled:c.disabled,children:b},c.value),[c.disabled,c.value,b]),{onNativeOptionAdd:h,onNativeOptionRemove:v}=l;return He(()=>(h(g),()=>v(g)),[h,v,g]),f.jsxs(f.Fragment,{children:[f.jsx(X.span,{id:c.textId,...a,ref:m}),c.isSelected&&i.valueNode&&!i.valueNodeHasChildren?ho.createPortal(a.children,i.valueNode):null]})});eP.displayName=Wn;var tP="SelectItemIndicator",rP=d.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e;return JE(tP,r).isSelected?f.jsx(X.span,{"aria-hidden":!0,...n,ref:t}):null});rP.displayName=tP;var nd="SelectScrollUpButton",nP=d.forwardRef((e,t)=>{const r=Rr(nd,e.__scopeSelect),n=Cp(nd,e.__scopeSelect),[o,a]=d.useState(!1),i=de(t,n.onScrollButtonChange);return He(()=>{if(r.viewport&&r.isPositioned){let s=function(){const l=c.scrollTop>0;a(l)};const c=r.viewport;return s(),c.addEventListener("scroll",s),()=>c.removeEventListener("scroll",s)}},[r.viewport,r.isPositioned]),o?f.jsx(aP,{...e,ref:i,onAutoScroll:()=>{const{viewport:s,selectedItem:c}=r;s&&c&&(s.scrollTop=s.scrollTop-c.offsetHeight)}}):null});nP.displayName=nd;var od="SelectScrollDownButton",oP=d.forwardRef((e,t)=>{const r=Rr(od,e.__scopeSelect),n=Cp(od,e.__scopeSelect),[o,a]=d.useState(!1),i=de(t,n.onScrollButtonChange);return He(()=>{if(r.viewport&&r.isPositioned){let s=function(){const l=c.scrollHeight-c.clientHeight,p=Math.ceil(c.scrollTop)<l;a(p)};const c=r.viewport;return s(),c.addEventListener("scroll",s),()=>c.removeEventListener("scroll",s)}},[r.viewport,r.isPositioned]),o?f.jsx(aP,{...e,ref:i,onAutoScroll:()=>{const{viewport:s,selectedItem:c}=r;s&&c&&(s.scrollTop=s.scrollTop+c.offsetHeight)}}):null});oP.displayName=od;var aP=d.forwardRef((e,t)=>{const{__scopeSelect:r,onAutoScroll:n,...o}=e,a=Rr("SelectScrollButton",r),i=d.useRef(null),s=ki(r),c=d.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return d.useEffect(()=>()=>c(),[c]),He(()=>{var p;const l=s().find(u=>u.ref.current===document.activeElement);(p=l==null?void 0:l.ref.current)==null||p.scrollIntoView({block:"nearest"})},[s]),f.jsx(X.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:B(o.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(n,50))}),onPointerMove:B(o.onPointerMove,()=>{var l;(l=a.onItemLeave)==null||l.call(a),i.current===null&&(i.current=window.setInterval(n,50))}),onPointerLeave:B(o.onPointerLeave,()=>{c()})})}),y5="SelectSeparator",iP=d.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e;return f.jsx(X.div,{"aria-hidden":!0,...n,ref:t})});iP.displayName=y5;var ad="SelectArrow",x5=d.forwardRef((e,t)=>{const{__scopeSelect:r,...n}=e,o=$i(r),a=_r(ad,r),i=Rr(ad,r);return a.open&&i.position==="popper"?f.jsx(Po,{...o,...n,ref:t}):null});x5.displayName=ad;function sP(e){return e===""||e===void 0}var cP=d.forwardRef((e,t)=>{const{value:r,...n}=e,o=d.useRef(null),a=de(t,o),i=_n(r);return d.useEffect(()=>{const s=o.current,c=window.HTMLSelectElement.prototype,p=Object.getOwnPropertyDescriptor(c,"value").set;if(i!==r&&p){const u=new Event("change",{bubbles:!0});p.call(s,r),s.dispatchEvent(u)}},[i,r]),f.jsx(ko,{asChild:!0,children:f.jsx("select",{...n,ref:a,defaultValue:r})})});cP.displayName="BubbleSelect";function lP(e){const t=Te(e),r=d.useRef(""),n=d.useRef(0),o=d.useCallback(i=>{const s=r.current+i;t(s),function c(l){r.current=l,window.clearTimeout(n.current),l!==""&&(n.current=window.setTimeout(()=>c(""),1e3))}(s)},[t]),a=d.useCallback(()=>{r.current="",window.clearTimeout(n.current)},[]);return d.useEffect(()=>()=>window.clearTimeout(n.current),[]),[r,o,a]}function uP(e,t,r){const o=t.length>1&&Array.from(t).every(l=>l===t[0])?t[0]:t,a=r?e.indexOf(r):-1;let i=w5(e,Math.max(a,0));o.length===1&&(i=i.filter(l=>l!==r));const c=i.find(l=>l.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==r?c:void 0}function w5(e,t){return e.map((r,n)=>e[(t+n)%e.length])}var S5=kE,dP=LE,C5=BE,_5=zE,R5=qE,fP=HE,E5=WE,P5=YE,pP=ZE,mP=QE,T5=eP,N5=rP,hP=nP,gP=oP,vP=iP;const A5=S5,M5=P5,O5=C5,bP=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(dP,{ref:n,className:M("flex h-9 w-full items-center justify-between whitespace-nowrap rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm ring-offset-background data-[placeholder]:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...r,children:[t,f.jsx(_5,{asChild:!0,children:f.jsx(Xa,{className:"h-4 w-4 opacity-50"})})]}));bP.displayName=dP.displayName;const _p=d.forwardRef(({className:e,...t},r)=>f.jsx(hP,{ref:r,className:M("flex cursor-default items-center justify-center py-1",e),...t,children:f.jsx(D1,{className:"h-4 w-4"})}));_p.displayName=hP.displayName;const Rp=d.forwardRef(({className:e,...t},r)=>f.jsx(gP,{ref:r,className:M("flex cursor-default items-center justify-center py-1",e),...t,children:f.jsx(Xa,{className:"h-4 w-4"})}));Rp.displayName=gP.displayName;const yP=d.forwardRef(({className:e,children:t,position:r="popper",...n},o)=>f.jsx(R5,{children:f.jsxs(fP,{ref:o,className:M("relative z-50 max-h-[--radix-select-content-available-height] min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-select-content-transform-origin]",r==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:r,...n,children:[f.jsx(_p,{}),f.jsx(E5,{className:M("p-1",r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),f.jsx(Rp,{})]})}));yP.displayName=fP.displayName;const xP=d.forwardRef(({className:e,...t},r)=>f.jsx(pP,{ref:r,className:M("px-2 py-1.5 text-sm font-semibold",e),...t}));xP.displayName=pP.displayName;const wP=d.forwardRef(({className:e,children:t,...r},n)=>f.jsxs(mP,{ref:n,className:M("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...r,children:[f.jsx("span",{className:"absolute right-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(N5,{children:f.jsx(vo,{className:"h-4 w-4"})})}),f.jsx(T5,{children:t})]}));wP.displayName=mP.displayName;const SP=d.forwardRef(({className:e,...t},r)=>f.jsx(vP,{ref:r,className:M("-mx-1 my-1 h-px bg-muted",e),...t}));SP.displayName=vP.displayName;var I5="Separator",Cb="horizontal",j5=["horizontal","vertical"],CP=d.forwardRef((e,t)=>{const{decorative:r,orientation:n=Cb,...o}=e,a=D5(n)?n:Cb,s=r?{role:"none"}:{"aria-orientation":a==="vertical"?a:void 0,role:"separator"};return f.jsx(X.div,{"data-orientation":a,...s,...o,ref:t})});CP.displayName=I5;function D5(e){return j5.includes(e)}var _P=CP;const Ep=d.forwardRef(({className:e,orientation:t="horizontal",decorative:r=!0,...n},o)=>f.jsx(_P,{ref:o,decorative:r,orientation:t,className:M("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...n}));Ep.displayName=_P.displayName;const RP=ti,k5=ri,$5=qr,EP=ni,Pp=d.forwardRef(({className:e,...t},r)=>f.jsx(xn,{className:M("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:r}));Pp.displayName=xn.displayName;const L5=fr("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500 data-[state=open]:animate-in data-[state=closed]:animate-out",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),Tp=d.forwardRef(({side:e="right",className:t,children:r,...n},o)=>f.jsxs(EP,{children:[f.jsx(Pp,{}),f.jsxs(wn,{ref:o,className:M(L5({side:e}),t),...n,children:[f.jsxs(qr,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[f.jsx(Pd,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Close"})]}),r]})]}));Tp.displayName=wn.displayName;const Np=({className:e,...t})=>f.jsx("div",{className:M("flex flex-col space-y-2 text-center sm:text-left",e),...t});Np.displayName="SheetHeader";const PP=({className:e,...t})=>f.jsx("div",{className:M("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});PP.displayName="SheetFooter";const Ap=d.forwardRef(({className:e,...t},r)=>f.jsx(Sn,{ref:r,className:M("text-lg font-semibold text-foreground",e),...t}));Ap.displayName=Sn.displayName;const Mp=d.forwardRef(({className:e,...t},r)=>f.jsx(Cn,{ref:r,className:M("text-sm text-muted-foreground",e),...t}));Mp.displayName=Cn.displayName;const fu=768;function F5(){const[e,t]=d.useState(void 0);return d.useEffect(()=>{const r=window.matchMedia(`(max-width: ${fu-1}px)`),n=()=>{t(window.innerWidth<fu)};return r.addEventListener("change",n),t(window.innerWidth<fu),()=>r.removeEventListener("change",n)},[]),!!e}function id({className:e,...t}){return f.jsx("div",{className:M("animate-pulse rounded-md bg-primary/10",e),...t})}var[Li,f3]=De("Tooltip",[Jt]),Fi=Jt(),TP="TooltipProvider",B5=700,sd="tooltip.open",[z5,Op]=Li(TP),NP=e=>{const{__scopeTooltip:t,delayDuration:r=B5,skipDelayDuration:n=300,disableHoverableContent:o=!1,children:a}=e,[i,s]=d.useState(!0),c=d.useRef(!1),l=d.useRef(0);return d.useEffect(()=>{const p=l.current;return()=>window.clearTimeout(p)},[]),f.jsx(z5,{scope:t,isOpenDelayed:i,delayDuration:r,onOpen:d.useCallback(()=>{window.clearTimeout(l.current),s(!1)},[]),onClose:d.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>s(!0),n)},[n]),isPointerInTransitRef:c,onPointerInTransitChange:d.useCallback(p=>{c.current=p},[]),disableHoverableContent:o,children:a})};NP.displayName=TP;var Bi="Tooltip",[q5,Fo]=Li(Bi),AP=e=>{const{__scopeTooltip:t,children:r,open:n,defaultOpen:o=!1,onOpenChange:a,disableHoverableContent:i,delayDuration:s}=e,c=Op(Bi,e.__scopeTooltip),l=Fi(t),[p,u]=d.useState(null),m=Ue(),b=d.useRef(0),g=i??c.disableHoverableContent,h=s??c.delayDuration,v=d.useRef(!1),[y=!1,x]=$e({prop:n,defaultProp:o,onChange:C=>{C?(c.onOpen(),document.dispatchEvent(new CustomEvent(sd))):c.onClose(),a==null||a(C)}}),w=d.useMemo(()=>y?v.current?"delayed-open":"instant-open":"closed",[y]),S=d.useCallback(()=>{window.clearTimeout(b.current),b.current=0,v.current=!1,x(!0)},[x]),_=d.useCallback(()=>{window.clearTimeout(b.current),b.current=0,x(!1)},[x]),R=d.useCallback(()=>{window.clearTimeout(b.current),b.current=window.setTimeout(()=>{v.current=!0,x(!0),b.current=0},h)},[h,x]);return d.useEffect(()=>()=>{b.current&&(window.clearTimeout(b.current),b.current=0)},[]),f.jsx(Pn,{...l,children:f.jsx(q5,{scope:t,contentId:m,open:y,stateAttribute:w,trigger:p,onTriggerChange:u,onTriggerEnter:d.useCallback(()=>{c.isOpenDelayed?R():S()},[c.isOpenDelayed,R,S]),onTriggerLeave:d.useCallback(()=>{g?_():(window.clearTimeout(b.current),b.current=0)},[_,g]),onOpen:S,onClose:_,disableHoverableContent:g,children:r})})};AP.displayName=Bi;var cd="TooltipTrigger",MP=d.forwardRef((e,t)=>{const{__scopeTooltip:r,...n}=e,o=Fo(cd,r),a=Op(cd,r),i=Fi(r),s=d.useRef(null),c=de(t,s,o.onTriggerChange),l=d.useRef(!1),p=d.useRef(!1),u=d.useCallback(()=>l.current=!1,[]);return d.useEffect(()=>()=>document.removeEventListener("pointerup",u),[u]),f.jsx(Tn,{asChild:!0,...i,children:f.jsx(X.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...n,ref:c,onPointerMove:B(e.onPointerMove,m=>{m.pointerType!=="touch"&&!p.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),p.current=!0)}),onPointerLeave:B(e.onPointerLeave,()=>{o.onTriggerLeave(),p.current=!1}),onPointerDown:B(e.onPointerDown,()=>{l.current=!0,document.addEventListener("pointerup",u,{once:!0})}),onFocus:B(e.onFocus,()=>{l.current||o.onOpen()}),onBlur:B(e.onBlur,o.onClose),onClick:B(e.onClick,o.onClose)})})});MP.displayName=cd;var Ip="TooltipPortal",[H5,V5]=Li(Ip,{forceMount:void 0}),OP=e=>{const{__scopeTooltip:t,forceMount:r,children:n,container:o}=e,a=Fo(Ip,t);return f.jsx(H5,{scope:t,forceMount:r,children:f.jsx(Le,{present:r||a.open,children:f.jsx(zr,{asChild:!0,container:o,children:n})})})};OP.displayName=Ip;var vn="TooltipContent",IP=d.forwardRef((e,t)=>{const r=V5(vn,e.__scopeTooltip),{forceMount:n=r.forceMount,side:o="top",...a}=e,i=Fo(vn,e.__scopeTooltip);return f.jsx(Le,{present:n||i.open,children:i.disableHoverableContent?f.jsx(jP,{side:o,...a,ref:t}):f.jsx(G5,{side:o,...a,ref:t})})}),G5=d.forwardRef((e,t)=>{const r=Fo(vn,e.__scopeTooltip),n=Op(vn,e.__scopeTooltip),o=d.useRef(null),a=de(t,o),[i,s]=d.useState(null),{trigger:c,onClose:l}=r,p=o.current,{onPointerInTransitChange:u}=n,m=d.useCallback(()=>{s(null),u(!1)},[u]),b=d.useCallback((g,h)=>{const v=g.currentTarget,y={x:g.clientX,y:g.clientY},x=Y5(y,v.getBoundingClientRect()),w=X5(y,x),S=Z5(h.getBoundingClientRect()),_=Q5([...w,...S]);s(_),u(!0)},[u]);return d.useEffect(()=>()=>m(),[m]),d.useEffect(()=>{if(c&&p){const g=v=>b(v,p),h=v=>b(v,c);return c.addEventListener("pointerleave",g),p.addEventListener("pointerleave",h),()=>{c.removeEventListener("pointerleave",g),p.removeEventListener("pointerleave",h)}}},[c,p,b,m]),d.useEffect(()=>{if(i){const g=h=>{const v=h.target,y={x:h.clientX,y:h.clientY},x=(c==null?void 0:c.contains(v))||(p==null?void 0:p.contains(v)),w=!J5(y,i);x?m():w&&(m(),l())};return document.addEventListener("pointermove",g),()=>document.removeEventListener("pointermove",g)}},[c,p,i,l,m]),f.jsx(jP,{...e,ref:a})}),[U5,W5]=Li(Bi,{isInside:!1}),jP=d.forwardRef((e,t)=>{const{__scopeTooltip:r,children:n,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:i,...s}=e,c=Fo(vn,r),l=Fi(r),{onClose:p}=c;return d.useEffect(()=>(document.addEventListener(sd,p),()=>document.removeEventListener(sd,p)),[p]),d.useEffect(()=>{if(c.trigger){const u=m=>{const b=m.target;b!=null&&b.contains(c.trigger)&&p()};return window.addEventListener("scroll",u,{capture:!0}),()=>window.removeEventListener("scroll",u,{capture:!0})}},[c.trigger,p]),f.jsx(ur,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:u=>u.preventDefault(),onDismiss:p,children:f.jsxs(Eo,{"data-state":c.stateAttribute,...l,...s,ref:t,style:{...s.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)"},children:[f.jsx(gd,{children:n}),f.jsx(U5,{scope:r,isInside:!0,children:f.jsx(D_,{id:c.contentId,role:"tooltip",children:o||n})})]})})});IP.displayName=vn;var DP="TooltipArrow",K5=d.forwardRef((e,t)=>{const{__scopeTooltip:r,...n}=e,o=Fi(r);return W5(DP,r).isInside?null:f.jsx(Po,{...o,...n,ref:t})});K5.displayName=DP;function Y5(e,t){const r=Math.abs(t.top-e.y),n=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(r,n,o,a)){case a:return"left";case o:return"right";case r:return"top";case n:return"bottom";default:throw new Error("unreachable")}}function X5(e,t,r=5){const n=[];switch(t){case"top":n.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":n.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":n.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":n.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r});break}return n}function Z5(e){const{top:t,right:r,bottom:n,left:o}=e;return[{x:o,y:t},{x:r,y:t},{x:r,y:n},{x:o,y:n}]}function J5(e,t){const{x:r,y:n}=e;let o=!1;for(let a=0,i=t.length-1;a<t.length;i=a++){const s=t[a].x,c=t[a].y,l=t[i].x,p=t[i].y;c>n!=p>n&&r<(l-s)*(n-c)/(p-c)+s&&(o=!o)}return o}function Q5(e){const t=e.slice();return t.sort((r,n)=>r.x<n.x?-1:r.x>n.x?1:r.y<n.y?-1:r.y>n.y?1:0),eH(t)}function eH(e){if(e.length<=1)return e.slice();const t=[];for(let n=0;n<e.length;n++){const o=e[n];for(;t.length>=2;){const a=t[t.length-1],i=t[t.length-2];if((a.x-i.x)*(o.y-i.y)>=(a.y-i.y)*(o.x-i.x))t.pop();else break}t.push(o)}t.pop();const r=[];for(let n=e.length-1;n>=0;n--){const o=e[n];for(;r.length>=2;){const a=r[r.length-1],i=r[r.length-2];if((a.x-i.x)*(o.y-i.y)>=(a.y-i.y)*(o.x-i.x))r.pop();else break}r.push(o)}return r.pop(),t.length===1&&r.length===1&&t[0].x===r[0].x&&t[0].y===r[0].y?t:t.concat(r)}var tH=NP,rH=AP,nH=MP,oH=OP,kP=IP;const $P=tH,LP=rH,FP=nH,jp=d.forwardRef(({className:e,sideOffset:t=4,...r},n)=>f.jsx(oH,{children:f.jsx(kP,{ref:n,sideOffset:t,className:M("z-50 overflow-hidden rounded-md bg-primary px-3 py-1.5 text-xs text-primary-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-[--radix-tooltip-content-transform-origin]",e),...r})}));jp.displayName=kP.displayName;const aH="sidebar_state",iH=60*60*24*7,sH="16rem",cH="18rem",lH="3rem",uH="b",BP=d.createContext(null);function Bo(){const e=d.useContext(BP);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}const zP=d.forwardRef(({defaultOpen:e=!0,open:t,onOpenChange:r,className:n,style:o,children:a,...i},s)=>{const c=F5(),[l,p]=d.useState(!1),[u,m]=d.useState(e),b=t??u,g=d.useCallback(x=>{const w=typeof x=="function"?x(b):x;r?r(w):m(w),document.cookie=`${aH}=${w}; path=/; max-age=${iH}`},[r,b]),h=d.useCallback(()=>c?p(x=>!x):g(x=>!x),[c,g,p]);d.useEffect(()=>{const x=w=>{w.key===uH&&(w.metaKey||w.ctrlKey)&&(w.preventDefault(),h())};return window.addEventListener("keydown",x),()=>window.removeEventListener("keydown",x)},[h]);const v=b?"expanded":"collapsed",y=d.useMemo(()=>({state:v,open:b,setOpen:g,isMobile:c,openMobile:l,setOpenMobile:p,toggleSidebar:h}),[v,b,g,c,l,p,h]);return f.jsx(BP.Provider,{value:y,children:f.jsx($P,{delayDuration:0,children:f.jsx("div",{style:{"--sidebar-width":sH,"--sidebar-width-icon":lH,...o},className:M("group/sidebar-wrapper flex min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar",n),ref:s,...i,children:a})})})});zP.displayName="SidebarProvider";const qP=d.forwardRef(({side:e="left",variant:t="sidebar",collapsible:r="offcanvas",className:n,children:o,...a},i)=>{const{isMobile:s,state:c,openMobile:l,setOpenMobile:p}=Bo();return r==="none"?f.jsx("div",{className:M("flex h-full w-[--sidebar-width] flex-col bg-sidebar text-sidebar-foreground",n),ref:i,...a,children:o}):s?f.jsx(RP,{open:l,onOpenChange:p,...a,children:f.jsxs(Tp,{"data-sidebar":"sidebar","data-mobile":"true",className:"w-[--sidebar-width] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden",style:{"--sidebar-width":cH},side:e,children:[f.jsxs(Np,{className:"sr-only",children:[f.jsx(Ap,{children:"Sidebar"}),f.jsx(Mp,{children:"Displays the mobile sidebar."})]}),f.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):f.jsxs("div",{ref:i,className:"group peer hidden text-sidebar-foreground md:block","data-state":c,"data-collapsible":c==="collapsed"?r:"","data-variant":t,"data-side":e,children:[f.jsx("div",{className:M("relative w-[--sidebar-width] bg-transparent transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon]")}),f.jsx("div",{className:M("fixed inset-y-0 z-10 hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]":"group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",n),...a,children:f.jsx("div",{"data-sidebar":"sidebar",className:"flex h-full w-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-sidebar-border group-data-[variant=floating]:shadow",children:o})})]})});qP.displayName="Sidebar";const HP=d.forwardRef(({className:e,onClick:t,...r},n)=>{const{toggleSidebar:o}=Bo();return f.jsxs(or,{ref:n,"data-sidebar":"trigger",variant:"ghost",size:"icon",className:M("h-7 w-7",e),onClick:a=>{t==null||t(a),o()},...r,children:[f.jsx(G1,{}),f.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})});HP.displayName="SidebarTrigger";const VP=d.forwardRef(({className:e,...t},r)=>{const{toggleSidebar:n}=Bo();return f.jsx("button",{ref:r,"data-sidebar":"rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:n,title:"Toggle Sidebar",className:M("absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex","[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-sidebar","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})});VP.displayName="SidebarRail";const GP=d.forwardRef(({className:e,...t},r)=>f.jsx("main",{ref:r,className:M("relative flex w-full flex-1 flex-col bg-background","md:peer-data-[variant=inset]:m-2 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow",e),...t}));GP.displayName="SidebarInset";const UP=d.forwardRef(({className:e,...t},r)=>f.jsx(uo,{ref:r,"data-sidebar":"input",className:M("h-8 w-full bg-background shadow-none focus-visible:ring-2 focus-visible:ring-sidebar-ring",e),...t}));UP.displayName="SidebarInput";const WP=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,"data-sidebar":"header",className:M("flex flex-col gap-2 p-2",e),...t}));WP.displayName="SidebarHeader";const KP=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,"data-sidebar":"footer",className:M("flex flex-col gap-2 p-2",e),...t}));KP.displayName="SidebarFooter";const YP=d.forwardRef(({className:e,...t},r)=>f.jsx(Ep,{ref:r,"data-sidebar":"separator",className:M("mx-2 w-auto bg-sidebar-border",e),...t}));YP.displayName="SidebarSeparator";const XP=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,"data-sidebar":"content",className:M("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t}));XP.displayName="SidebarContent";const ZP=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,"data-sidebar":"group",className:M("relative flex w-full min-w-0 flex-col p-2",e),...t}));ZP.displayName="SidebarGroup";const JP=d.forwardRef(({className:e,asChild:t=!1,...r},n)=>{const o=t?st:"div";return f.jsx(o,{ref:n,"data-sidebar":"group-label",className:M("flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...r})});JP.displayName="SidebarGroupLabel";const QP=d.forwardRef(({className:e,asChild:t=!1,...r},n)=>{const o=t?st:"button";return f.jsx(o,{ref:n,"data-sidebar":"group-action",className:M("absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","group-data-[collapsible=icon]:hidden",e),...r})});QP.displayName="SidebarGroupAction";const eT=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,"data-sidebar":"group-content",className:M("w-full text-sm",e),...t}));eT.displayName="SidebarGroupContent";const tT=d.forwardRef(({className:e,...t},r)=>f.jsx("ul",{ref:r,"data-sidebar":"menu",className:M("flex w-full min-w-0 flex-col gap-1",e),...t}));tT.displayName="SidebarMenu";const rT=d.forwardRef(({className:e,...t},r)=>f.jsx("li",{ref:r,"data-sidebar":"menu-item",className:M("group/menu-item relative",e),...t}));rT.displayName="SidebarMenuItem";const dH=fr("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-[[data-sidebar=menu-action]]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-2 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:!p-0"}},defaultVariants:{variant:"default",size:"default"}}),nT=d.forwardRef(({asChild:e=!1,isActive:t=!1,variant:r="default",size:n="default",tooltip:o,className:a,...i},s)=>{const c=e?st:"button",{isMobile:l,state:p}=Bo(),u=f.jsx(c,{ref:s,"data-sidebar":"menu-button","data-size":n,"data-active":t,className:M(dH({variant:r,size:n}),a),...i});return o?(typeof o=="string"&&(o={children:o}),f.jsxs(LP,{children:[f.jsx(FP,{asChild:!0,children:u}),f.jsx(jp,{side:"right",align:"center",hidden:p!=="collapsed"||l,...o})]})):u});nT.displayName="SidebarMenuButton";const oT=d.forwardRef(({className:e,asChild:t=!1,showOnHover:r=!1,...n},o)=>{const a=t?st:"button";return f.jsx(a,{ref:o,"data-sidebar":"menu-action",className:M("absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 peer-hover/menu-button:text-sidebar-accent-foreground [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 after:md:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",r&&"group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-sidebar-accent-foreground md:opacity-0",e),...n})});oT.displayName="SidebarMenuAction";const aT=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{ref:r,"data-sidebar":"menu-badge",className:M("pointer-events-none absolute right-1 flex h-5 min-w-5 select-none items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums text-sidebar-foreground","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...t}));aT.displayName="SidebarMenuBadge";const iT=d.forwardRef(({className:e,showIcon:t=!1,...r},n)=>{const o=d.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return f.jsxs("div",{ref:n,"data-sidebar":"menu-skeleton",className:M("flex h-8 items-center gap-2 rounded-md px-2",e),...r,children:[t&&f.jsx(id,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),f.jsx(id,{className:"h-4 max-w-[--skeleton-width] flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":o}})]})});iT.displayName="SidebarMenuSkeleton";const sT=d.forwardRef(({className:e,...t},r)=>f.jsx("ul",{ref:r,"data-sidebar":"menu-sub",className:M("mx-3.5 flex min-w-0 translate-x-px flex-col gap-1 border-l border-sidebar-border px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...t}));sT.displayName="SidebarMenuSub";const cT=d.forwardRef(({...e},t)=>f.jsx("li",{ref:t,...e}));cT.displayName="SidebarMenuSubItem";const lT=d.forwardRef(({asChild:e=!1,size:t="md",isActive:r,className:n,...o},a)=>{const i=e?st:"a";return f.jsx(i,{ref:a,"data-sidebar":"menu-sub-button","data-size":t,"data-active":r,className:M("flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground outline-none ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",n),...o})});lT.displayName="SidebarMenuSubButton";var uT=["PageUp","PageDown"],dT=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],fT={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},On="Slider",[ld,fH,pH]=cr(On),[pT,p3]=De(On,[pH]),[mH,zi]=pT(On),mT=d.forwardRef((e,t)=>{const{name:r,min:n=0,max:o=100,step:a=1,orientation:i="horizontal",disabled:s=!1,minStepsBetweenThumbs:c=0,defaultValue:l=[n],value:p,onValueChange:u=()=>{},onValueCommit:m=()=>{},inverted:b=!1,form:g,...h}=e,v=d.useRef(new Set),y=d.useRef(0),w=i==="horizontal"?hH:gH,[S=[],_]=$e({prop:p,defaultProp:l,onChange:j=>{var N;(N=[...v.current][y.current])==null||N.focus(),u(j)}}),R=d.useRef(S);function C(j){const L=wH(S,j);k(j,L)}function A(j){k(j,y.current)}function P(){const j=R.current[y.current];S[y.current]!==j&&m(S)}function k(j,L,{commit:N}={commit:!1}){const D=RH(a),$=EH(Math.round((j-n)/a)*a+n,D),O=mo($,[n,o]);_((G=[])=>{const H=yH(G,O,L);if(_H(H,c*a)){y.current=H.indexOf(O);const z=String(H)!==String(G);return z&&N&&m(H),z?H:G}else return G})}return f.jsx(mH,{scope:e.__scopeSlider,name:r,disabled:s,min:n,max:o,valueIndexToChangeRef:y,thumbs:v.current,values:S,orientation:i,form:g,children:f.jsx(ld.Provider,{scope:e.__scopeSlider,children:f.jsx(ld.Slot,{scope:e.__scopeSlider,children:f.jsx(w,{"aria-disabled":s,"data-disabled":s?"":void 0,...h,ref:t,onPointerDown:B(h.onPointerDown,()=>{s||(R.current=S)}),min:n,max:o,inverted:b,onSlideStart:s?void 0:C,onSlideMove:s?void 0:A,onSlideEnd:s?void 0:P,onHomeKeyDown:()=>!s&&k(n,0,{commit:!0}),onEndKeyDown:()=>!s&&k(o,S.length-1,{commit:!0}),onStepKeyDown:({event:j,direction:L})=>{if(!s){const $=uT.includes(j.key)||j.shiftKey&&dT.includes(j.key)?10:1,O=y.current,G=S[O],H=a*$*L;k(G+H,O,{commit:!0})}}})})})})});mT.displayName=On;var[hT,gT]=pT(On,{startEdge:"left",endEdge:"right",size:"width",direction:1}),hH=d.forwardRef((e,t)=>{const{min:r,max:n,dir:o,inverted:a,onSlideStart:i,onSlideMove:s,onSlideEnd:c,onStepKeyDown:l,...p}=e,[u,m]=d.useState(null),b=de(t,w=>m(w)),g=d.useRef(void 0),h=Ft(o),v=h==="ltr",y=v&&!a||!v&&a;function x(w){const S=g.current||u.getBoundingClientRect(),_=[0,S.width],C=Dp(_,y?[r,n]:[n,r]);return g.current=S,C(w-S.left)}return f.jsx(hT,{scope:e.__scopeSlider,startEdge:y?"left":"right",endEdge:y?"right":"left",direction:y?1:-1,size:"width",children:f.jsx(vT,{dir:h,"data-orientation":"horizontal",...p,ref:b,style:{...p.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:w=>{const S=x(w.clientX);i==null||i(S)},onSlideMove:w=>{const S=x(w.clientX);s==null||s(S)},onSlideEnd:()=>{g.current=void 0,c==null||c()},onStepKeyDown:w=>{const _=fT[y?"from-left":"from-right"].includes(w.key);l==null||l({event:w,direction:_?-1:1})}})})}),gH=d.forwardRef((e,t)=>{const{min:r,max:n,inverted:o,onSlideStart:a,onSlideMove:i,onSlideEnd:s,onStepKeyDown:c,...l}=e,p=d.useRef(null),u=de(t,p),m=d.useRef(void 0),b=!o;function g(h){const v=m.current||p.current.getBoundingClientRect(),y=[0,v.height],w=Dp(y,b?[n,r]:[r,n]);return m.current=v,w(h-v.top)}return f.jsx(hT,{scope:e.__scopeSlider,startEdge:b?"bottom":"top",endEdge:b?"top":"bottom",size:"height",direction:b?1:-1,children:f.jsx(vT,{"data-orientation":"vertical",...l,ref:u,style:{...l.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:h=>{const v=g(h.clientY);a==null||a(v)},onSlideMove:h=>{const v=g(h.clientY);i==null||i(v)},onSlideEnd:()=>{m.current=void 0,s==null||s()},onStepKeyDown:h=>{const y=fT[b?"from-bottom":"from-top"].includes(h.key);c==null||c({event:h,direction:y?-1:1})}})})}),vT=d.forwardRef((e,t)=>{const{__scopeSlider:r,onSlideStart:n,onSlideMove:o,onSlideEnd:a,onHomeKeyDown:i,onEndKeyDown:s,onStepKeyDown:c,...l}=e,p=zi(On,r);return f.jsx(X.span,{...l,ref:t,onKeyDown:B(e.onKeyDown,u=>{u.key==="Home"?(i(u),u.preventDefault()):u.key==="End"?(s(u),u.preventDefault()):uT.concat(dT).includes(u.key)&&(c(u),u.preventDefault())}),onPointerDown:B(e.onPointerDown,u=>{const m=u.target;m.setPointerCapture(u.pointerId),u.preventDefault(),p.thumbs.has(m)?m.focus():n(u)}),onPointerMove:B(e.onPointerMove,u=>{u.target.hasPointerCapture(u.pointerId)&&o(u)}),onPointerUp:B(e.onPointerUp,u=>{const m=u.target;m.hasPointerCapture(u.pointerId)&&(m.releasePointerCapture(u.pointerId),a(u))})})}),bT="SliderTrack",yT=d.forwardRef((e,t)=>{const{__scopeSlider:r,...n}=e,o=zi(bT,r);return f.jsx(X.span,{"data-disabled":o.disabled?"":void 0,"data-orientation":o.orientation,...n,ref:t})});yT.displayName=bT;var ud="SliderRange",xT=d.forwardRef((e,t)=>{const{__scopeSlider:r,...n}=e,o=zi(ud,r),a=gT(ud,r),i=d.useRef(null),s=de(t,i),c=o.values.length,l=o.values.map(m=>ST(m,o.min,o.max)),p=c>1?Math.min(...l):0,u=100-Math.max(...l);return f.jsx(X.span,{"data-orientation":o.orientation,"data-disabled":o.disabled?"":void 0,...n,ref:s,style:{...e.style,[a.startEdge]:p+"%",[a.endEdge]:u+"%"}})});xT.displayName=ud;var dd="SliderThumb",wT=d.forwardRef((e,t)=>{const r=fH(e.__scopeSlider),[n,o]=d.useState(null),a=de(t,s=>o(s)),i=d.useMemo(()=>n?r().findIndex(s=>s.ref.current===n):-1,[r,n]);return f.jsx(vH,{...e,ref:a,index:i})}),vH=d.forwardRef((e,t)=>{const{__scopeSlider:r,index:n,name:o,...a}=e,i=zi(dd,r),s=gT(dd,r),[c,l]=d.useState(null),p=de(t,x=>l(x)),u=c?i.form||!!c.closest("form"):!0,m=_o(c),b=i.values[n],g=b===void 0?0:ST(b,i.min,i.max),h=xH(n,i.values.length),v=m==null?void 0:m[s.size],y=v?SH(v,g,s.direction):0;return d.useEffect(()=>{if(c)return i.thumbs.add(c),()=>{i.thumbs.delete(c)}},[c,i.thumbs]),f.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[s.startEdge]:`calc(${g}% + ${y}px)`},children:[f.jsx(ld.ItemSlot,{scope:e.__scopeSlider,children:f.jsx(X.span,{role:"slider","aria-label":e["aria-label"]||h,"aria-valuemin":i.min,"aria-valuenow":b,"aria-valuemax":i.max,"aria-orientation":i.orientation,"data-orientation":i.orientation,"data-disabled":i.disabled?"":void 0,tabIndex:i.disabled?void 0:0,...a,ref:p,style:b===void 0?{display:"none"}:e.style,onFocus:B(e.onFocus,()=>{i.valueIndexToChangeRef.current=n})})}),u&&f.jsx(bH,{name:o??(i.name?i.name+(i.values.length>1?"[]":""):void 0),form:i.form,value:b},n)]})});wT.displayName=dd;var bH=e=>{const{value:t,...r}=e,n=d.useRef(null),o=_n(t);return d.useEffect(()=>{const a=n.current,i=window.HTMLInputElement.prototype,c=Object.getOwnPropertyDescriptor(i,"value").set;if(o!==t&&c){const l=new Event("input",{bubbles:!0});c.call(a,t),a.dispatchEvent(l)}},[o,t]),f.jsx("input",{style:{display:"none"},...r,ref:n,defaultValue:t})};function yH(e=[],t,r){const n=[...e];return n[r]=t,n.sort((o,a)=>o-a)}function ST(e,t,r){const a=100/(r-t)*(e-t);return mo(a,[0,100])}function xH(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function wH(e,t){if(e.length===1)return 0;const r=e.map(o=>Math.abs(o-t)),n=Math.min(...r);return r.indexOf(n)}function SH(e,t,r){const n=e/2,a=Dp([0,50],[0,n]);return(n-a(t)*r)*r}function CH(e){return e.slice(0,-1).map((t,r)=>e[r+1]-t)}function _H(e,t){if(t>0){const r=CH(e);return Math.min(...r)>=t}return!0}function Dp(e,t){return r=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const n=(t[1]-t[0])/(e[1]-e[0]);return t[0]+n*(r-e[0])}}function RH(e){return(String(e).split(".")[1]||"").length}function EH(e,t){const r=Math.pow(10,t);return Math.round(e*r)/r}var CT=mT,PH=yT,TH=xT,NH=wT;const _T=d.forwardRef(({className:e,...t},r)=>f.jsxs(CT,{ref:r,className:M("relative flex w-full touch-none select-none items-center",e),...t,children:[f.jsx(PH,{className:"relative h-1.5 w-full grow overflow-hidden rounded-full bg-primary/20",children:f.jsx(TH,{className:"absolute h-full bg-primary"})}),f.jsx(NH,{className:"block h-4 w-4 rounded-full border border-primary/50 bg-background shadow transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50"})]}));_T.displayName=CT.displayName;var AH=(e,t,r,n,o,a,i,s)=>{let c=document.documentElement,l=["light","dark"];function p(b){(Array.isArray(e)?e:[e]).forEach(g=>{let h=g==="class",v=h&&a?o.map(y=>a[y]||y):o;h?(c.classList.remove(...v),c.classList.add(a&&a[b]?a[b]:b)):c.setAttribute(g,b)}),u(b)}function u(b){s&&l.includes(b)&&(c.style.colorScheme=b)}function m(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}if(n)p(n);else try{let b=localStorage.getItem(t)||r,g=i&&b==="system"?m():b;p(g)}catch{}},MH=d.createContext(void 0),OH={setTheme:e=>{},themes:[]},IH=()=>{var e;return(e=d.useContext(MH))!=null?e:OH};d.memo(({forcedTheme:e,storageKey:t,attribute:r,enableSystem:n,enableColorScheme:o,defaultTheme:a,value:i,themes:s,nonce:c,scriptProps:l})=>{let p=JSON.stringify([r,t,a,e,s,i,n,o]).slice(1,-1);return d.createElement("script",{...l,suppressHydrationWarning:!0,nonce:typeof window>"u"?c:"",dangerouslySetInnerHTML:{__html:`(${AH.toString()})(${p})`}})});function jH(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}const DH=e=>{switch(e){case"success":return LH;case"info":return BH;case"warning":return FH;case"error":return zH;default:return null}},kH=Array(12).fill(0),$H=({visible:e,className:t})=>E.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},E.createElement("div",{className:"sonner-spinner"},kH.map((r,n)=>E.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${n}`})))),LH=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),FH=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},E.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),BH=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),zH=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},E.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),qH=E.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},E.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),E.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),HH=()=>{const[e,t]=E.useState(document.hidden);return E.useEffect(()=>{const r=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e};let fd=1;class VH{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const r=this.subscribers.indexOf(t);this.subscribers.splice(r,1)}),this.publish=t=>{this.subscribers.forEach(r=>r(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var r;const{message:n,...o}=t,a=typeof(t==null?void 0:t.id)=="number"||((r=t.id)==null?void 0:r.length)>0?t.id:fd++,i=this.toasts.find(c=>c.id===a),s=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(a)&&this.dismissedToasts.delete(a),i?this.toasts=this.toasts.map(c=>c.id===a?(this.publish({...c,...t,id:a,title:n}),{...c,...t,id:a,dismissible:s,title:n}):c):this.addToast({title:n,...o,dismissible:s,id:a}),a},this.dismiss=t=>(this.dismissedToasts.add(t),t||this.toasts.forEach(r=>{this.subscribers.forEach(n=>n({id:r.id,dismiss:!0}))}),requestAnimationFrame(()=>this.subscribers.forEach(r=>r({id:t,dismiss:!0}))),t),this.message=(t,r)=>this.create({...r,message:t}),this.error=(t,r)=>this.create({...r,message:t,type:"error"}),this.success=(t,r)=>this.create({...r,type:"success",message:t}),this.info=(t,r)=>this.create({...r,type:"info",message:t}),this.warning=(t,r)=>this.create({...r,type:"warning",message:t}),this.loading=(t,r)=>this.create({...r,type:"loading",message:t}),this.promise=(t,r)=>{if(!r)return;let n;r.loading!==void 0&&(n=this.create({...r,promise:t,type:"loading",message:r.loading,description:typeof r.description!="function"?r.description:void 0}));const o=Promise.resolve(t instanceof Function?t():t);let a=n!==void 0,i;const s=o.then(async l=>{if(i=["resolve",l],E.isValidElement(l))a=!1,this.create({id:n,type:"default",message:l});else if(UH(l)&&!l.ok){a=!1;const u=typeof r.error=="function"?await r.error(`HTTP error! status: ${l.status}`):r.error,m=typeof r.description=="function"?await r.description(`HTTP error! status: ${l.status}`):r.description,b=typeof u=="object"?u:{message:u};this.create({id:n,type:"error",description:m,...b})}else if(l instanceof Error){a=!1;const u=typeof r.error=="function"?await r.error(l):r.error,m=typeof r.description=="function"?await r.description(l):r.description,b=typeof u=="object"?u:{message:u};this.create({id:n,type:"error",description:m,...b})}else if(r.success!==void 0){a=!1;const u=typeof r.success=="function"?await r.success(l):r.success,m=typeof r.description=="function"?await r.description(l):r.description,b=typeof u=="object"?u:{message:u};this.create({id:n,type:"success",description:m,...b})}}).catch(async l=>{if(i=["reject",l],r.error!==void 0){a=!1;const p=typeof r.error=="function"?await r.error(l):r.error,u=typeof r.description=="function"?await r.description(l):r.description,m=typeof p=="object"?p:{message:p};this.create({id:n,type:"error",description:u,...m})}}).finally(()=>{a&&(this.dismiss(n),n=void 0),r.finally==null||r.finally.call(r)}),c=()=>new Promise((l,p)=>s.then(()=>i[0]==="reject"?p(i[1]):l(i[1])).catch(p));return typeof n!="string"&&typeof n!="number"?{unwrap:c}:Object.assign(n,{unwrap:c})},this.custom=(t,r)=>{const n=(r==null?void 0:r.id)||fd++;return this.create({jsx:t(n),id:n,...r}),n},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const bt=new VH,GH=(e,t)=>{const r=(t==null?void 0:t.id)||fd++;return bt.addToast({title:e,...t,id:r}),r},UH=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",WH=GH,KH=()=>bt.toasts,YH=()=>bt.getActiveToasts();Object.assign(WH,{success:bt.success,info:bt.info,warning:bt.warning,error:bt.error,custom:bt.custom,message:bt.message,promise:bt.promise,dismiss:bt.dismiss,loading:bt.loading},{getHistory:KH,getToasts:YH});jH("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}[data-sonner-toaster][data-lifted=true]{transform:translateY(-8px)}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function sa(e){return e.label!==void 0}const XH=3,ZH="24px",JH="16px",_b=4e3,QH=356,eV=14,tV=45,rV=200;function Gt(...e){return e.filter(Boolean).join(" ")}function nV(e){const[t,r]=e.split("-"),n=[];return t&&n.push(t),r&&n.push(r),n}const oV=e=>{var t,r,n,o,a,i,s,c,l;const{invert:p,toast:u,unstyled:m,interacting:b,setHeights:g,visibleToasts:h,heights:v,index:y,toasts:x,expanded:w,removeToast:S,defaultRichColors:_,closeButton:R,style:C,cancelButtonStyle:A,actionButtonStyle:P,className:k="",descriptionClassName:j="",duration:L,position:N,gap:D,expandByDefault:$,classNames:O,icons:G,closeButtonAriaLabel:H="Close toast"}=e,[z,oe]=E.useState(null),[Z,te]=E.useState(null),[F,U]=E.useState(!1),[Q,K]=E.useState(!1),[q,W]=E.useState(!1),[re,J]=E.useState(!1),[ne,V]=E.useState(!1),[ae,I]=E.useState(0),[ee,pe]=E.useState(0),me=E.useRef(u.duration||L||_b),ge=E.useRef(null),fe=E.useRef(null),Ee=y===0,Fe=y+1<=h,we=u.type,Oe=u.dismissible!==!1,rt=u.className||"",Ze=u.descriptionClassName||"",We=E.useMemo(()=>v.findIndex(ie=>ie.toastId===u.id)||0,[v,u.id]),ot=E.useMemo(()=>{var ie;return(ie=u.closeButton)!=null?ie:R},[u.closeButton,R]),mt=E.useMemo(()=>u.duration||L||_b,[u.duration,L]),ft=E.useRef(0),Ve=E.useRef(0),Ct=E.useRef(0),Ke=E.useRef(null),[Je,At]=N.split("-"),Vt=E.useMemo(()=>v.reduce((ie,Se,xe)=>xe>=We?ie:ie+Se.height,0),[v,We]),pr=HH(),Er=u.invert||p,Mt=we==="loading";Ve.current=E.useMemo(()=>We*D+Vt,[We,Vt]),E.useEffect(()=>{me.current=mt},[mt]),E.useEffect(()=>{U(!0)},[]),E.useEffect(()=>{const ie=fe.current;if(ie){const Se=ie.getBoundingClientRect().height;return pe(Se),g(xe=>[{toastId:u.id,height:Se,position:u.position},...xe]),()=>g(xe=>xe.filter(ke=>ke.toastId!==u.id))}},[g,u.id]),E.useLayoutEffect(()=>{if(!F)return;const ie=fe.current,Se=ie.style.height;ie.style.height="auto";const xe=ie.getBoundingClientRect().height;ie.style.height=Se,pe(xe),g(ke=>ke.find(Ie=>Ie.toastId===u.id)?ke.map(Ie=>Ie.toastId===u.id?{...Ie,height:xe}:Ie):[{toastId:u.id,height:xe,position:u.position},...ke])},[F,u.title,u.description,g,u.id]);const ue=E.useCallback(()=>{K(!0),I(Ve.current),g(ie=>ie.filter(Se=>Se.toastId!==u.id)),setTimeout(()=>{S(u)},rV)},[u,S,g,Ve]);E.useEffect(()=>{if(u.promise&&we==="loading"||u.duration===1/0||u.type==="loading")return;let ie;return w||b||pr?(()=>{if(Ct.current<ft.current){const ke=new Date().getTime()-ft.current;me.current=me.current-ke}Ct.current=new Date().getTime()})():(()=>{me.current!==1/0&&(ft.current=new Date().getTime(),ie=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),ue()},me.current))})(),()=>clearTimeout(ie)},[w,b,u,we,pr,ue]),E.useEffect(()=>{u.delete&&ue()},[ue,u.delete]);function be(){var ie;if(G!=null&&G.loading){var Se;return E.createElement("div",{className:Gt(O==null?void 0:O.loader,u==null||(Se=u.classNames)==null?void 0:Se.loader,"sonner-loader"),"data-visible":we==="loading"},G.loading)}return E.createElement($H,{className:Gt(O==null?void 0:O.loader,u==null||(ie=u.classNames)==null?void 0:ie.loader),visible:we==="loading"})}var Ce,ve;return E.createElement("li",{tabIndex:0,ref:fe,className:Gt(k,rt,O==null?void 0:O.toast,u==null||(t=u.classNames)==null?void 0:t.toast,O==null?void 0:O.default,O==null?void 0:O[we],u==null||(r=u.classNames)==null?void 0:r[we]),"data-sonner-toast":"","data-rich-colors":(Ce=u.richColors)!=null?Ce:_,"data-styled":!(u.jsx||u.unstyled||m),"data-mounted":F,"data-promise":!!u.promise,"data-swiped":ne,"data-removed":Q,"data-visible":Fe,"data-y-position":Je,"data-x-position":At,"data-index":y,"data-front":Ee,"data-swiping":q,"data-dismissible":Oe,"data-type":we,"data-invert":Er,"data-swipe-out":re,"data-swipe-direction":Z,"data-expanded":!!(w||$&&F),style:{"--index":y,"--toasts-before":y,"--z-index":x.length-y,"--offset":`${Q?ae:Ve.current}px`,"--initial-height":$?"auto":`${ee}px`,...C,...u.style},onDragEnd:()=>{W(!1),oe(null),Ke.current=null},onPointerDown:ie=>{Mt||!Oe||(ge.current=new Date,I(Ve.current),ie.target.setPointerCapture(ie.pointerId),ie.target.tagName!=="BUTTON"&&(W(!0),Ke.current={x:ie.clientX,y:ie.clientY}))},onPointerUp:()=>{var ie,Se,xe;if(re||!Oe)return;Ke.current=null;const ke=Number(((ie=fe.current)==null?void 0:ie.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Qe=Number(((Se=fe.current)==null?void 0:Se.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Ie=new Date().getTime()-((xe=ge.current)==null?void 0:xe.getTime()),Be=z==="x"?ke:Qe,at=Math.abs(Be)/Ie;if(Math.abs(Be)>=tV||at>.11){I(Ve.current),u.onDismiss==null||u.onDismiss.call(u,u),te(z==="x"?ke>0?"right":"left":Qe>0?"down":"up"),ue(),J(!0);return}else{var et,it;(et=fe.current)==null||et.style.setProperty("--swipe-amount-x","0px"),(it=fe.current)==null||it.style.setProperty("--swipe-amount-y","0px")}V(!1),W(!1),oe(null)},onPointerMove:ie=>{var Se,xe,ke;if(!Ke.current||!Oe||((Se=window.getSelection())==null?void 0:Se.toString().length)>0)return;const Ie=ie.clientY-Ke.current.y,Be=ie.clientX-Ke.current.x;var at;const et=(at=e.swipeDirections)!=null?at:nV(N);!z&&(Math.abs(Be)>1||Math.abs(Ie)>1)&&oe(Math.abs(Be)>Math.abs(Ie)?"x":"y");let it={x:0,y:0};const zo=tr=>1/(1.5+Math.abs(tr)/20);if(z==="y"){if(et.includes("top")||et.includes("bottom"))if(et.includes("top")&&Ie<0||et.includes("bottom")&&Ie>0)it.y=Ie;else{const tr=Ie*zo(Ie);it.y=Math.abs(tr)<Math.abs(Ie)?tr:Ie}}else if(z==="x"&&(et.includes("left")||et.includes("right")))if(et.includes("left")&&Be<0||et.includes("right")&&Be>0)it.x=Be;else{const tr=Be*zo(Be);it.x=Math.abs(tr)<Math.abs(Be)?tr:Be}(Math.abs(it.x)>0||Math.abs(it.y)>0)&&V(!0),(xe=fe.current)==null||xe.style.setProperty("--swipe-amount-x",`${it.x}px`),(ke=fe.current)==null||ke.style.setProperty("--swipe-amount-y",`${it.y}px`)}},ot&&!u.jsx&&we!=="loading"?E.createElement("button",{"aria-label":H,"data-disabled":Mt,"data-close-button":!0,onClick:Mt||!Oe?()=>{}:()=>{ue(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Gt(O==null?void 0:O.closeButton,u==null||(n=u.classNames)==null?void 0:n.closeButton)},(ve=G==null?void 0:G.close)!=null?ve:qH):null,we||u.icon||u.promise?E.createElement("div",{"data-icon":"",className:Gt(O==null?void 0:O.icon,u==null||(o=u.classNames)==null?void 0:o.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||be():null,u.type!=="loading"?u.icon||(G==null?void 0:G[we])||DH(we):null):null,E.createElement("div",{"data-content":"",className:Gt(O==null?void 0:O.content,u==null||(a=u.classNames)==null?void 0:a.content)},E.createElement("div",{"data-title":"",className:Gt(O==null?void 0:O.title,u==null||(i=u.classNames)==null?void 0:i.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?E.createElement("div",{"data-description":"",className:Gt(j,Ze,O==null?void 0:O.description,u==null||(s=u.classNames)==null?void 0:s.description)},typeof u.description=="function"?u.description():u.description):null),E.isValidElement(u.cancel)?u.cancel:u.cancel&&sa(u.cancel)?E.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||A,onClick:ie=>{sa(u.cancel)&&Oe&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,ie),ue())},className:Gt(O==null?void 0:O.cancelButton,u==null||(c=u.classNames)==null?void 0:c.cancelButton)},u.cancel.label):null,E.isValidElement(u.action)?u.action:u.action&&sa(u.action)?E.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||P,onClick:ie=>{sa(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,ie),!ie.defaultPrevented&&ue())},className:Gt(O==null?void 0:O.actionButton,u==null||(l=u.classNames)==null?void 0:l.actionButton)},u.action.label):null)};function Rb(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function aV(e,t){const r={};return[e,t].forEach((n,o)=>{const a=o===1,i=a?"--mobile-offset":"--offset",s=a?JH:ZH;function c(l){["top","right","bottom","left"].forEach(p=>{r[`${i}-${p}`]=typeof l=="number"?`${l}px`:l})}typeof n=="number"||typeof n=="string"?c(n):typeof n=="object"?["top","right","bottom","left"].forEach(l=>{n[l]===void 0?r[`${i}-${l}`]=s:r[`${i}-${l}`]=typeof n[l]=="number"?`${n[l]}px`:n[l]}):c(s)}),r}const iV=E.forwardRef(function(t,r){const{invert:n,position:o="bottom-right",hotkey:a=["altKey","KeyT"],expand:i,closeButton:s,className:c,offset:l,mobileOffset:p,theme:u="light",richColors:m,duration:b,style:g,visibleToasts:h=XH,toastOptions:v,dir:y=Rb(),gap:x=eV,icons:w,containerAriaLabel:S="Notifications"}=t,[_,R]=E.useState([]),C=E.useMemo(()=>Array.from(new Set([o].concat(_.filter(Z=>Z.position).map(Z=>Z.position)))),[_,o]),[A,P]=E.useState([]),[k,j]=E.useState(!1),[L,N]=E.useState(!1),[D,$]=E.useState(u!=="system"?u:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),O=E.useRef(null),G=a.join("+").replace(/Key/g,"").replace(/Digit/g,""),H=E.useRef(null),z=E.useRef(!1),oe=E.useCallback(Z=>{R(te=>{var F;return(F=te.find(U=>U.id===Z.id))!=null&&F.delete||bt.dismiss(Z.id),te.filter(({id:U})=>U!==Z.id)})},[]);return E.useEffect(()=>bt.subscribe(Z=>{if(Z.dismiss){const te=_.map(F=>F.id===Z.id?{...F,delete:!0}:F);requestAnimationFrame(()=>{R(te)});return}setTimeout(()=>{Wa.flushSync(()=>{R(te=>{const F=te.findIndex(U=>U.id===Z.id);return F!==-1?[...te.slice(0,F),{...te[F],...Z},...te.slice(F+1)]:[Z,...te]})})})}),[_]),E.useEffect(()=>{if(u!=="system"){$(u);return}if(u==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?$("dark"):$("light")),typeof window>"u")return;const Z=window.matchMedia("(prefers-color-scheme: dark)");try{Z.addEventListener("change",({matches:te})=>{$(te?"dark":"light")})}catch{Z.addListener(({matches:F})=>{try{$(F?"dark":"light")}catch(U){console.error(U)}})}},[u]),E.useEffect(()=>{_.length<=1&&j(!1)},[_]),E.useEffect(()=>{const Z=te=>{var F;if(a.every(K=>te[K]||te.code===K)){var Q;j(!0),(Q=O.current)==null||Q.focus()}te.code==="Escape"&&(document.activeElement===O.current||(F=O.current)!=null&&F.contains(document.activeElement))&&j(!1)};return document.addEventListener("keydown",Z),()=>document.removeEventListener("keydown",Z)},[a]),E.useEffect(()=>{if(O.current)return()=>{H.current&&(H.current.focus({preventScroll:!0}),H.current=null,z.current=!1)}},[O.current]),E.createElement("section",{ref:r,"aria-label":`${S} ${G}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},C.map((Z,te)=>{var F;const[U,Q]=Z.split("-");return _.length?E.createElement("ol",{key:Z,dir:y==="auto"?Rb():y,tabIndex:-1,ref:O,className:c,"data-sonner-toaster":!0,"data-sonner-theme":D,"data-y-position":U,"data-lifted":k&&_.length>1&&!i,"data-x-position":Q,style:{"--front-toast-height":`${((F=A[0])==null?void 0:F.height)||0}px`,"--width":`${QH}px`,"--gap":`${x}px`,...g,...aV(l,p)},onBlur:K=>{z.current&&!K.currentTarget.contains(K.relatedTarget)&&(z.current=!1,H.current&&(H.current.focus({preventScroll:!0}),H.current=null))},onFocus:K=>{K.target instanceof HTMLElement&&K.target.dataset.dismissible==="false"||z.current||(z.current=!0,H.current=K.relatedTarget)},onMouseEnter:()=>j(!0),onMouseMove:()=>j(!0),onMouseLeave:()=>{L||j(!1)},onDragEnd:()=>j(!1),onPointerDown:K=>{K.target instanceof HTMLElement&&K.target.dataset.dismissible==="false"||N(!0)},onPointerUp:()=>N(!1)},_.filter(K=>!K.position&&te===0||K.position===Z).map((K,q)=>{var W,re;return E.createElement(oV,{key:K.id,icons:w,index:q,toast:K,defaultRichColors:m,duration:(W=v==null?void 0:v.duration)!=null?W:b,className:v==null?void 0:v.className,descriptionClassName:v==null?void 0:v.descriptionClassName,invert:n,visibleToasts:h,closeButton:(re=v==null?void 0:v.closeButton)!=null?re:s,interacting:L,position:Z,style:v==null?void 0:v.style,unstyled:v==null?void 0:v.unstyled,classNames:v==null?void 0:v.classNames,cancelButtonStyle:v==null?void 0:v.cancelButtonStyle,actionButtonStyle:v==null?void 0:v.actionButtonStyle,closeButtonAriaLabel:v==null?void 0:v.closeButtonAriaLabel,removeToast:oe,toasts:_.filter(J=>J.position==K.position),heights:A.filter(J=>J.position==K.position),setHeights:P,expandByDefault:i,gap:x,expanded:k,swipeDirections:t.swipeDirections})})):null}))}),sV=({...e})=>{const{theme:t="system"}=IH();return f.jsx(iV,{theme:t,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})};var kp="Switch",[cV,m3]=De(kp),[lV,uV]=cV(kp),RT=d.forwardRef((e,t)=>{const{__scopeSwitch:r,name:n,checked:o,defaultChecked:a,required:i,disabled:s,value:c="on",onCheckedChange:l,form:p,...u}=e,[m,b]=d.useState(null),g=de(t,w=>b(w)),h=d.useRef(!1),v=m?p||!!m.closest("form"):!0,[y=!1,x]=$e({prop:o,defaultProp:a,onChange:l});return f.jsxs(lV,{scope:r,checked:y,disabled:s,children:[f.jsx(X.button,{type:"button",role:"switch","aria-checked":y,"aria-required":i,"data-state":TT(y),"data-disabled":s?"":void 0,disabled:s,value:c,...u,ref:g,onClick:B(e.onClick,w=>{x(S=>!S),v&&(h.current=w.isPropagationStopped(),h.current||w.stopPropagation())})}),v&&f.jsx(dV,{control:m,bubbles:!h.current,name:n,value:c,checked:y,required:i,disabled:s,form:p,style:{transform:"translateX(-100%)"}})]})});RT.displayName=kp;var ET="SwitchThumb",PT=d.forwardRef((e,t)=>{const{__scopeSwitch:r,...n}=e,o=uV(ET,r);return f.jsx(X.span,{"data-state":TT(o.checked),"data-disabled":o.disabled?"":void 0,...n,ref:t})});PT.displayName=ET;var dV=e=>{const{control:t,checked:r,bubbles:n=!0,...o}=e,a=d.useRef(null),i=_n(r),s=_o(t);return d.useEffect(()=>{const c=a.current,l=window.HTMLInputElement.prototype,u=Object.getOwnPropertyDescriptor(l,"checked").set;if(i!==r&&u){const m=new Event("click",{bubbles:n});u.call(c,r),c.dispatchEvent(m)}},[i,r,n]),f.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:r,...o,tabIndex:-1,ref:a,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function TT(e){return e?"checked":"unchecked"}var NT=RT,fV=PT;const AT=d.forwardRef(({className:e,...t},r)=>f.jsx(NT,{className:M("peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:r,children:f.jsx(fV,{className:M("pointer-events-none block h-4 w-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0")})}));AT.displayName=NT.displayName;const MT=d.forwardRef(({className:e,...t},r)=>f.jsx("div",{className:"relative w-full overflow-auto",children:f.jsx("table",{ref:r,className:M("w-full caption-bottom text-sm",e),...t})}));MT.displayName="Table";const OT=d.forwardRef(({className:e,...t},r)=>f.jsx("thead",{ref:r,className:M("[&_tr]:border-b",e),...t}));OT.displayName="TableHeader";const IT=d.forwardRef(({className:e,...t},r)=>f.jsx("tbody",{ref:r,className:M("[&_tr:last-child]:border-0",e),...t}));IT.displayName="TableBody";const jT=d.forwardRef(({className:e,...t},r)=>f.jsx("tfoot",{ref:r,className:M("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",e),...t}));jT.displayName="TableFooter";const DT=d.forwardRef(({className:e,...t},r)=>f.jsx("tr",{ref:r,className:M("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",e),...t}));DT.displayName="TableRow";const kT=d.forwardRef(({className:e,...t},r)=>f.jsx("th",{ref:r,className:M("h-10 px-2 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));kT.displayName="TableHead";const $T=d.forwardRef(({className:e,...t},r)=>f.jsx("td",{ref:r,className:M("p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));$T.displayName="TableCell";const LT=d.forwardRef(({className:e,...t},r)=>f.jsx("caption",{ref:r,className:M("mt-4 text-sm text-muted-foreground",e),...t}));LT.displayName="TableCaption";var $p="Tabs",[pV,h3]=De($p,[Qt]),FT=Qt(),[mV,Lp]=pV($p),BT=d.forwardRef((e,t)=>{const{__scopeTabs:r,value:n,onValueChange:o,defaultValue:a,orientation:i="horizontal",dir:s,activationMode:c="automatic",...l}=e,p=Ft(s),[u,m]=$e({prop:n,onChange:o,defaultProp:a});return f.jsx(mV,{scope:r,baseId:Ue(),value:u,onValueChange:m,orientation:i,dir:p,activationMode:c,children:f.jsx(X.div,{dir:p,"data-orientation":i,...l,ref:t})})});BT.displayName=$p;var zT="TabsList",qT=d.forwardRef((e,t)=>{const{__scopeTabs:r,loop:n=!0,...o}=e,a=Lp(zT,r),i=FT(r);return f.jsx(To,{asChild:!0,...i,orientation:a.orientation,dir:a.dir,loop:n,children:f.jsx(X.div,{role:"tablist","aria-orientation":a.orientation,...o,ref:t})})});qT.displayName=zT;var HT="TabsTrigger",VT=d.forwardRef((e,t)=>{const{__scopeTabs:r,value:n,disabled:o=!1,...a}=e,i=Lp(HT,r),s=FT(r),c=WT(i.baseId,n),l=KT(i.baseId,n),p=n===i.value;return f.jsx(No,{asChild:!0,...s,focusable:!o,active:p,children:f.jsx(X.button,{type:"button",role:"tab","aria-selected":p,"aria-controls":l,"data-state":p?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:c,...a,ref:t,onMouseDown:B(e.onMouseDown,u=>{!o&&u.button===0&&u.ctrlKey===!1?i.onValueChange(n):u.preventDefault()}),onKeyDown:B(e.onKeyDown,u=>{[" ","Enter"].includes(u.key)&&i.onValueChange(n)}),onFocus:B(e.onFocus,()=>{const u=i.activationMode!=="manual";!p&&!o&&u&&i.onValueChange(n)})})})});VT.displayName=HT;var GT="TabsContent",UT=d.forwardRef((e,t)=>{const{__scopeTabs:r,value:n,forceMount:o,children:a,...i}=e,s=Lp(GT,r),c=WT(s.baseId,n),l=KT(s.baseId,n),p=n===s.value,u=d.useRef(p);return d.useEffect(()=>{const m=requestAnimationFrame(()=>u.current=!1);return()=>cancelAnimationFrame(m)},[]),f.jsx(Le,{present:o||p,children:({present:m})=>f.jsx(X.div,{"data-state":p?"active":"inactive","data-orientation":s.orientation,role:"tabpanel","aria-labelledby":c,hidden:!m,id:l,tabIndex:0,...i,ref:t,style:{...e.style,animationDuration:u.current?"0s":void 0},children:m&&a})})});UT.displayName=GT;function WT(e,t){return`${e}-trigger-${t}`}function KT(e,t){return`${e}-content-${t}`}var hV=BT,YT=qT,XT=VT,ZT=UT;const gV=hV,JT=d.forwardRef(({className:e,...t},r)=>f.jsx(YT,{ref:r,className:M("inline-flex h-9 items-center justify-center rounded-lg bg-muted p-1 text-muted-foreground",e),...t}));JT.displayName=YT.displayName;const QT=d.forwardRef(({className:e,...t},r)=>f.jsx(XT,{ref:r,className:M("inline-flex items-center justify-center whitespace-nowrap rounded-md px-3 py-1 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow",e),...t}));QT.displayName=XT.displayName;const eN=d.forwardRef(({className:e,...t},r)=>f.jsx(ZT,{ref:r,className:M("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));eN.displayName=ZT.displayName;const tN=d.forwardRef(({className:e,...t},r)=>f.jsx("textarea",{className:M("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...t}));tN.displayName="Textarea";var Fp="ToastProvider",[Bp,vV,bV]=cr("Toast"),[rN,g3]=De("Toast",[bV]),[yV,qi]=rN(Fp),nN=e=>{const{__scopeToast:t,label:r="Notification",duration:n=5e3,swipeDirection:o="right",swipeThreshold:a=50,children:i}=e,[s,c]=d.useState(null),[l,p]=d.useState(0),u=d.useRef(!1),m=d.useRef(!1);return r.trim()||console.error(`Invalid prop \`label\` supplied to \`${Fp}\`. Expected non-empty \`string\`.`),f.jsx(Bp.Provider,{scope:t,children:f.jsx(yV,{scope:t,label:r,duration:n,swipeDirection:o,swipeThreshold:a,toastCount:l,viewport:s,onViewportChange:c,onToastAdd:d.useCallback(()=>p(b=>b+1),[]),onToastRemove:d.useCallback(()=>p(b=>b-1),[]),isFocusedToastEscapeKeyDownRef:u,isClosePausedRef:m,children:i})})};nN.displayName=Fp;var oN="ToastViewport",xV=["F8"],pd="toast.viewportPause",md="toast.viewportResume",aN=d.forwardRef((e,t)=>{const{__scopeToast:r,hotkey:n=xV,label:o="Notifications ({hotkey})",...a}=e,i=qi(oN,r),s=vV(r),c=d.useRef(null),l=d.useRef(null),p=d.useRef(null),u=d.useRef(null),m=de(t,u,i.onViewportChange),b=n.join("+").replace(/Key/g,"").replace(/Digit/g,""),g=i.toastCount>0;d.useEffect(()=>{const v=y=>{var w;n.length!==0&&n.every(S=>y[S]||y.code===S)&&((w=u.current)==null||w.focus())};return document.addEventListener("keydown",v),()=>document.removeEventListener("keydown",v)},[n]),d.useEffect(()=>{const v=c.current,y=u.current;if(g&&v&&y){const x=()=>{if(!i.isClosePausedRef.current){const R=new CustomEvent(pd);y.dispatchEvent(R),i.isClosePausedRef.current=!0}},w=()=>{if(i.isClosePausedRef.current){const R=new CustomEvent(md);y.dispatchEvent(R),i.isClosePausedRef.current=!1}},S=R=>{!v.contains(R.relatedTarget)&&w()},_=()=>{v.contains(document.activeElement)||w()};return v.addEventListener("focusin",x),v.addEventListener("focusout",S),v.addEventListener("pointermove",x),v.addEventListener("pointerleave",_),window.addEventListener("blur",x),window.addEventListener("focus",w),()=>{v.removeEventListener("focusin",x),v.removeEventListener("focusout",S),v.removeEventListener("pointermove",x),v.removeEventListener("pointerleave",_),window.removeEventListener("blur",x),window.removeEventListener("focus",w)}}},[g,i.isClosePausedRef]);const h=d.useCallback(({tabbingDirection:v})=>{const x=s().map(w=>{const S=w.ref.current,_=[S,...IV(S)];return v==="forwards"?_:_.reverse()});return(v==="forwards"?x.reverse():x).flat()},[s]);return d.useEffect(()=>{const v=u.current;if(v){const y=x=>{var _,R,C;const w=x.altKey||x.ctrlKey||x.metaKey;if(x.key==="Tab"&&!w){const A=document.activeElement,P=x.shiftKey;if(x.target===v&&P){(_=l.current)==null||_.focus();return}const L=h({tabbingDirection:P?"backwards":"forwards"}),N=L.findIndex(D=>D===A);pu(L.slice(N+1))?x.preventDefault():P?(R=l.current)==null||R.focus():(C=p.current)==null||C.focus()}};return v.addEventListener("keydown",y),()=>v.removeEventListener("keydown",y)}},[s,h]),f.jsxs(HA,{ref:c,role:"region","aria-label":o.replace("{hotkey}",b),tabIndex:-1,style:{pointerEvents:g?void 0:"none"},children:[g&&f.jsx(hd,{ref:l,onFocusFromOutsideViewport:()=>{const v=h({tabbingDirection:"forwards"});pu(v)}}),f.jsx(Bp.Slot,{scope:r,children:f.jsx(X.ol,{tabIndex:-1,...a,ref:m})}),g&&f.jsx(hd,{ref:p,onFocusFromOutsideViewport:()=>{const v=h({tabbingDirection:"backwards"});pu(v)}})]})});aN.displayName=oN;var iN="ToastFocusProxy",hd=d.forwardRef((e,t)=>{const{__scopeToast:r,onFocusFromOutsideViewport:n,...o}=e,a=qi(iN,r);return f.jsx(ko,{"aria-hidden":!0,tabIndex:0,...o,ref:t,style:{position:"fixed"},onFocus:i=>{var l;const s=i.relatedTarget;!((l=a.viewport)!=null&&l.contains(s))&&n()}})});hd.displayName=iN;var Hi="Toast",wV="toast.swipeStart",SV="toast.swipeMove",CV="toast.swipeCancel",_V="toast.swipeEnd",sN=d.forwardRef((e,t)=>{const{forceMount:r,open:n,defaultOpen:o,onOpenChange:a,...i}=e,[s=!0,c]=$e({prop:n,defaultProp:o,onChange:a});return f.jsx(Le,{present:r||s,children:f.jsx(PV,{open:s,...i,ref:t,onClose:()=>c(!1),onPause:Te(e.onPause),onResume:Te(e.onResume),onSwipeStart:B(e.onSwipeStart,l=>{l.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:B(e.onSwipeMove,l=>{const{x:p,y:u}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","move"),l.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${p}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${u}px`)}),onSwipeCancel:B(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:B(e.onSwipeEnd,l=>{const{x:p,y:u}=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",`${p}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${u}px`),c(!1)})})})});sN.displayName=Hi;var[RV,EV]=rN(Hi,{onClose(){}}),PV=d.forwardRef((e,t)=>{const{__scopeToast:r,type:n="foreground",duration:o,open:a,onClose:i,onEscapeKeyDown:s,onPause:c,onResume:l,onSwipeStart:p,onSwipeMove:u,onSwipeCancel:m,onSwipeEnd:b,...g}=e,h=qi(Hi,r),[v,y]=d.useState(null),x=de(t,D=>y(D)),w=d.useRef(null),S=d.useRef(null),_=o||h.duration,R=d.useRef(0),C=d.useRef(_),A=d.useRef(0),{onToastAdd:P,onToastRemove:k}=h,j=Te(()=>{var $;(v==null?void 0:v.contains(document.activeElement))&&(($=h.viewport)==null||$.focus()),i()}),L=d.useCallback(D=>{!D||D===1/0||(window.clearTimeout(A.current),R.current=new Date().getTime(),A.current=window.setTimeout(j,D))},[j]);d.useEffect(()=>{const D=h.viewport;if(D){const $=()=>{L(C.current),l==null||l()},O=()=>{const G=new Date().getTime()-R.current;C.current=C.current-G,window.clearTimeout(A.current),c==null||c()};return D.addEventListener(pd,O),D.addEventListener(md,$),()=>{D.removeEventListener(pd,O),D.removeEventListener(md,$)}}},[h.viewport,_,c,l,L]),d.useEffect(()=>{a&&!h.isClosePausedRef.current&&L(_)},[a,_,h.isClosePausedRef,L]),d.useEffect(()=>(P(),()=>k()),[P,k]);const N=d.useMemo(()=>v?mN(v):null,[v]);return h.viewport?f.jsxs(f.Fragment,{children:[N&&f.jsx(TV,{__scopeToast:r,role:"status","aria-live":n==="foreground"?"assertive":"polite","aria-atomic":!0,children:N}),f.jsx(RV,{scope:r,onClose:j,children:ho.createPortal(f.jsx(Bp.ItemSlot,{scope:r,children:f.jsx(qA,{asChild:!0,onEscapeKeyDown:B(s,()=>{h.isFocusedToastEscapeKeyDownRef.current||j(),h.isFocusedToastEscapeKeyDownRef.current=!1}),children:f.jsx(X.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":a?"open":"closed","data-swipe-direction":h.swipeDirection,...g,ref:x,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:B(e.onKeyDown,D=>{D.key==="Escape"&&(s==null||s(D.nativeEvent),D.nativeEvent.defaultPrevented||(h.isFocusedToastEscapeKeyDownRef.current=!0,j()))}),onPointerDown:B(e.onPointerDown,D=>{D.button===0&&(w.current={x:D.clientX,y:D.clientY})}),onPointerMove:B(e.onPointerMove,D=>{if(!w.current)return;const $=D.clientX-w.current.x,O=D.clientY-w.current.y,G=!!S.current,H=["left","right"].includes(h.swipeDirection),z=["left","up"].includes(h.swipeDirection)?Math.min:Math.max,oe=H?z(0,$):0,Z=H?0:z(0,O),te=D.pointerType==="touch"?10:2,F={x:oe,y:Z},U={originalEvent:D,delta:F};G?(S.current=F,ca(SV,u,U,{discrete:!1})):Eb(F,h.swipeDirection,te)?(S.current=F,ca(wV,p,U,{discrete:!1}),D.target.setPointerCapture(D.pointerId)):(Math.abs($)>te||Math.abs(O)>te)&&(w.current=null)}),onPointerUp:B(e.onPointerUp,D=>{const $=S.current,O=D.target;if(O.hasPointerCapture(D.pointerId)&&O.releasePointerCapture(D.pointerId),S.current=null,w.current=null,$){const G=D.currentTarget,H={originalEvent:D,delta:$};Eb($,h.swipeDirection,h.swipeThreshold)?ca(_V,b,H,{discrete:!0}):ca(CV,m,H,{discrete:!0}),G.addEventListener("click",z=>z.preventDefault(),{once:!0})}})})})}),h.viewport)})]}):null}),TV=e=>{const{__scopeToast:t,children:r,...n}=e,o=qi(Hi,t),[a,i]=d.useState(!1),[s,c]=d.useState(!1);return MV(()=>i(!0)),d.useEffect(()=>{const l=window.setTimeout(()=>c(!0),1e3);return()=>window.clearTimeout(l)},[]),s?null:f.jsx(zr,{asChild:!0,children:f.jsx(ko,{...n,children:a&&f.jsxs(f.Fragment,{children:[o.label," ",r]})})})},NV="ToastTitle",cN=d.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e;return f.jsx(X.div,{...n,ref:t})});cN.displayName=NV;var AV="ToastDescription",lN=d.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e;return f.jsx(X.div,{...n,ref:t})});lN.displayName=AV;var uN="ToastAction",dN=d.forwardRef((e,t)=>{const{altText:r,...n}=e;return r.trim()?f.jsx(pN,{altText:r,asChild:!0,children:f.jsx(zp,{...n,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${uN}\`. Expected non-empty \`string\`.`),null)});dN.displayName=uN;var fN="ToastClose",zp=d.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e,o=EV(fN,r);return f.jsx(pN,{asChild:!0,children:f.jsx(X.button,{type:"button",...n,ref:t,onClick:B(e.onClick,o.onClose)})})});zp.displayName=fN;var pN=d.forwardRef((e,t)=>{const{__scopeToast:r,altText:n,...o}=e;return f.jsx(X.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":n||void 0,...o,ref:t})});function mN(e){const t=[];return Array.from(e.childNodes).forEach(n=>{if(n.nodeType===n.TEXT_NODE&&n.textContent&&t.push(n.textContent),OV(n)){const o=n.ariaHidden||n.hidden||n.style.display==="none",a=n.dataset.radixToastAnnounceExclude==="";if(!o)if(a){const i=n.dataset.radixToastAnnounceAlt;i&&t.push(i)}else t.push(...mN(n))}}),t}function ca(e,t,r,{discrete:n}){const o=r.originalEvent.currentTarget,a=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:r});t&&o.addEventListener(e,t,{once:!0}),n?Xn(o,a):o.dispatchEvent(a)}var Eb=(e,t,r=0)=>{const n=Math.abs(e.x),o=Math.abs(e.y),a=n>o;return t==="left"||t==="right"?a&&n>r:!a&&o>r};function MV(e=()=>{}){const t=Te(e);He(()=>{let r=0,n=0;return r=window.requestAnimationFrame(()=>n=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(r),window.cancelAnimationFrame(n)}},[t])}function OV(e){return e.nodeType===e.ELEMENT_NODE}function IV(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const o=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||o?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function pu(e){const t=document.activeElement;return e.some(r=>r===t?!0:(r.focus(),document.activeElement!==t))}var jV=nN,hN=aN,gN=sN,vN=cN,bN=lN,yN=dN,xN=zp;const wN=jV,qp=d.forwardRef(({className:e,...t},r)=>f.jsx(hN,{ref:r,className:M("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",e),...t}));qp.displayName=hN.displayName;const DV=fr("group pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Hp=d.forwardRef(({className:e,variant:t,...r},n)=>f.jsx(gN,{ref:n,className:M(DV({variant:t}),e),...r}));Hp.displayName=gN.displayName;const SN=d.forwardRef(({className:e,...t},r)=>f.jsx(yN,{ref:r,className:M("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium transition-colors hover:bg-secondary focus:outline-none focus:ring-1 focus:ring-ring disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...t}));SN.displayName=yN.displayName;const Vp=d.forwardRef(({className:e,...t},r)=>f.jsx(xN,{ref:r,className:M("absolute right-1 top-1 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:f.jsx(Pd,{className:"h-4 w-4"})}));Vp.displayName=xN.displayName;const Gp=d.forwardRef(({className:e,...t},r)=>f.jsx(vN,{ref:r,className:M("text-sm font-semibold [&+div]:text-xs",e),...t}));Gp.displayName=vN.displayName;const Up=d.forwardRef(({className:e,...t},r)=>f.jsx(bN,{ref:r,className:M("text-sm opacity-90",e),...t}));Up.displayName=bN.displayName;const kV=1,$V=1e6;let mu=0;function LV(){return mu=(mu+1)%Number.MAX_SAFE_INTEGER,mu.toString()}const hu=new Map,Pb=e=>{if(hu.has(e))return;const t=setTimeout(()=>{hu.delete(e),Yn({type:"REMOVE_TOAST",toastId:e})},$V);hu.set(e,t)},FV=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,kV)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(r=>r.id===t.toast.id?{...r,...t.toast}:r)};case"DISMISS_TOAST":{const{toastId:r}=t;return r?Pb(r):e.toasts.forEach(n=>{Pb(n.id)}),{...e,toasts:e.toasts.map(n=>n.id===r||r===void 0?{...n,open:!1}:n)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(r=>r.id!==t.toastId)}}},ma=[];let ha={toasts:[]};function Yn(e){ha=FV(ha,e),ma.forEach(t=>{t(ha)})}function BV({...e}){const t=LV(),r=o=>Yn({type:"UPDATE_TOAST",toast:{...o,id:t}}),n=()=>Yn({type:"DISMISS_TOAST",toastId:t});return Yn({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:o=>{o||n()}}}),{id:t,dismiss:n,update:r}}function zV(){const[e,t]=d.useState(ha);return d.useEffect(()=>(ma.push(t),()=>{const r=ma.indexOf(t);r>-1&&ma.splice(r,1)}),[e]),{...e,toast:BV,dismiss:r=>Yn({type:"DISMISS_TOAST",toastId:r})}}function qV(){const{toasts:e}=zV();return f.jsxs(wN,{children:[e.map(function({id:t,title:r,description:n,action:o,...a}){return f.jsxs(Hp,{...a,children:[f.jsxs("div",{className:"grid gap-1",children:[r&&f.jsx(Gp,{children:r}),n&&f.jsx(Up,{children:n})]}),o,f.jsx(Vp,{})]},t)}),f.jsx(qp,{})]})}var HV="Toggle",Wp=d.forwardRef((e,t)=>{const{pressed:r,defaultPressed:n=!1,onPressedChange:o,...a}=e,[i=!1,s]=$e({prop:r,onChange:o,defaultProp:n});return f.jsx(X.button,{type:"button","aria-pressed":i,"data-state":i?"on":"off","data-disabled":e.disabled?"":void 0,...a,ref:t,onClick:B(e.onClick,()=>{e.disabled||s(!i)})})});Wp.displayName=HV;var CN=Wp,In="ToggleGroup",[_N,v3]=De(In,[Qt]),RN=Qt(),Kp=E.forwardRef((e,t)=>{const{type:r,...n}=e;if(r==="single"){const o=n;return f.jsx(VV,{...o,ref:t})}if(r==="multiple"){const o=n;return f.jsx(GV,{...o,ref:t})}throw new Error(`Missing prop \`type\` expected on \`${In}\``)});Kp.displayName=In;var[EN,PN]=_N(In),VV=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},...a}=e,[i,s]=$e({prop:r,defaultProp:n,onChange:o});return f.jsx(EN,{scope:e.__scopeToggleGroup,type:"single",value:i?[i]:[],onItemActivate:s,onItemDeactivate:E.useCallback(()=>s(""),[s]),children:f.jsx(TN,{...a,ref:t})})}),GV=E.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:o=()=>{},...a}=e,[i=[],s]=$e({prop:r,defaultProp:n,onChange:o}),c=E.useCallback(p=>s((u=[])=>[...u,p]),[s]),l=E.useCallback(p=>s((u=[])=>u.filter(m=>m!==p)),[s]);return f.jsx(EN,{scope:e.__scopeToggleGroup,type:"multiple",value:i,onItemActivate:c,onItemDeactivate:l,children:f.jsx(TN,{...a,ref:t})})});Kp.displayName=In;var[UV,WV]=_N(In),TN=E.forwardRef((e,t)=>{const{__scopeToggleGroup:r,disabled:n=!1,rovingFocus:o=!0,orientation:a,dir:i,loop:s=!0,...c}=e,l=RN(r),p=Ft(i),u={role:"group",dir:p,...c};return f.jsx(UV,{scope:r,rovingFocus:o,disabled:n,children:o?f.jsx(To,{asChild:!0,...l,orientation:a,dir:p,loop:s,children:f.jsx(X.div,{...u,ref:t})}):f.jsx(X.div,{...u,ref:t})})}),Ua="ToggleGroupItem",NN=E.forwardRef((e,t)=>{const r=PN(Ua,e.__scopeToggleGroup),n=WV(Ua,e.__scopeToggleGroup),o=RN(e.__scopeToggleGroup),a=r.value.includes(e.value),i=n.disabled||e.disabled,s={...e,pressed:a,disabled:i},c=E.useRef(null);return n.rovingFocus?f.jsx(No,{asChild:!0,...o,focusable:!i,active:a,ref:c,children:f.jsx(Tb,{...s,ref:t})}):f.jsx(Tb,{...s,ref:t})});NN.displayName=Ua;var Tb=E.forwardRef((e,t)=>{const{__scopeToggleGroup:r,value:n,...o}=e,a=PN(Ua,r),i={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},s=a.type==="single"?i:void 0;return f.jsx(Wp,{...s,...o,ref:t,onPressedChange:c=>{c?a.onItemActivate(n):a.onItemDeactivate(n)}})}),AN=Kp,MN=NN;const Yp=fr("inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-transparent",outline:"border border-input bg-transparent shadow-sm hover:bg-accent hover:text-accent-foreground"},size:{default:"h-9 px-2 min-w-9",sm:"h-8 px-1.5 min-w-8",lg:"h-10 px-2.5 min-w-10"}},defaultVariants:{variant:"default",size:"default"}}),ON=d.forwardRef(({className:e,variant:t,size:r,...n},o)=>f.jsx(CN,{ref:o,className:M(Yp({variant:t,size:r,className:e})),...n}));ON.displayName=CN.displayName;const IN=d.createContext({size:"default",variant:"default"}),jN=d.forwardRef(({className:e,variant:t,size:r,children:n,...o},a)=>f.jsx(AN,{ref:a,className:M("flex items-center justify-center gap-1",e),...o,children:f.jsx(IN.Provider,{value:{variant:t,size:r},children:n})}));jN.displayName=AN.displayName;const DN=d.forwardRef(({className:e,children:t,variant:r,size:n,...o},a)=>{const i=d.useContext(IN);return f.jsx(MN,{ref:a,className:M(Yp({variant:i.variant||r,size:i.size||n}),e),...o,children:t})});DN.displayName=MN.displayName;function KV({title:e,description:t,chart:r,value:n,previousValue:o,change:a,changeType:i,changeLabel:s,className:c,footerContent:l,menuItems:p,chartConfig:u,isLoading:m=!1}){const b=()=>i==="increase"?f.jsx(T1,{className:"h-4 w-4 text-emerald-500"}):i==="decrease"?f.jsx(S1,{className:"h-4 w-4 text-red-500"}):null,g=()=>i==="increase"?"text-emerald-500":i==="decrease"?"text-red-500":"text-muted-foreground";return f.jsxs(oi,{className:M("overflow-hidden",c),children:[f.jsxs(ai,{className:"flex flex-row items-center justify-between pb-2",children:[f.jsxs("div",{children:[f.jsx(ii,{className:"text-base font-medium",children:e}),t&&f.jsx(si,{children:t})]}),p&&p.length>0&&f.jsxs(cC,{children:[f.jsx(lC,{asChild:!0,children:f.jsxs(or,{variant:"ghost",className:"h-8 w-8 p-0",children:[f.jsx("span",{className:"sr-only",children:"Open menu"}),f.jsx(Ed,{className:"h-4 w-4"})]})}),f.jsx(Kf,{align:"end",children:p.map((h,v)=>f.jsx(Yf,{onClick:h.onClick,children:h.label},v))})]})]}),f.jsxs(ci,{className:"pb-2",children:[n&&f.jsx("div",{className:"flex items-center justify-between",children:f.jsxs("div",{className:"space-y-1",children:[f.jsx("p",{className:"text-2xl font-bold",children:n}),(a!==void 0||o)&&f.jsxs("div",{className:"flex items-center text-xs",children:[b(),f.jsxs("span",{className:M("ml-1",g()),children:[a!==void 0&&`${Math.abs(a)}%`,o&&!a&&`from ${o}`]}),s&&f.jsx("span",{className:"ml-1 text-muted-foreground",children:s})]})]})}),f.jsx("div",{className:M("mt-4",n?"h-[180px]":"h-[240px]"),children:m?f.jsx("div",{className:"flex h-full items-center justify-center",children:f.jsx("div",{className:"h-8 w-8 animate-spin rounded-full border-4 border-primary border-t-transparent"})}):u&&r?f.jsx(cf,{config:u,children:r}):r})]}),l&&f.jsx(Fd,{children:l})]})}function YV({title:e,breadcrumbItems:t=[],showHomeLink:r=!0,className:n="",children:o}){return f.jsx("header",{className:`border-b pb-4 ${n}`,children:f.jsxs("div",{className:"container mx-auto p-4",children:[(t.length>0||r)&&f.jsx(kd,{className:"mb-2",children:f.jsxs($d,{children:[r&&f.jsxs(f.Fragment,{children:[f.jsx(ba,{children:f.jsxs(ya,{href:"/",className:"flex items-center",children:[f.jsx(z1,{className:"h-3.5 w-3.5 mr-1"}),"Home"]})}),t.length>0&&f.jsx(xa,{children:f.jsx(Dr,{className:"h-3.5 w-3.5"})})]}),t.map((a,i)=>f.jsxs(E.Fragment,{children:[f.jsx(ba,{children:a.isCurrentPage?f.jsx(Ld,{children:a.label}):f.jsx(ya,{href:a.href||"#",children:a.label})}),i<t.length-1&&f.jsx(xa,{children:f.jsx(Dr,{className:"h-3.5 w-3.5"})})]},i))]})}),e&&f.jsx("h1",{className:"text-2xl font-bold tracking-tight",children:e}),o]})})}function XV({className:e,...t}){return f.jsxs("div",{className:M("flex flex-col gap-6",e),...t,children:[f.jsxs(oi,{children:[f.jsxs(ai,{className:"text-center",children:[f.jsx(ii,{className:"text-xl",children:"Welcome back"}),f.jsx(si,{children:"Login with your Apple or Google account"})]}),f.jsx(ci,{children:f.jsx("form",{children:f.jsxs("div",{className:"grid gap-6",children:[f.jsxs("div",{className:"flex flex-col gap-4",children:[f.jsxs(or,{variant:"outline",className:"w-full",children:[f.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:f.jsx("path",{d:"M12.152 6.896c-.948 0-2.415-1.078-3.96-1.04-2.04.027-3.91 1.183-4.961 3.014-2.117 3.675-.546 9.103 1.519 12.09 1.013 1.454 2.208 3.09 3.792 3.039 1.52-.065 2.09-.987 3.935-.987 1.831 0 2.35.987 3.96.948 1.637-.026 2.676-1.48 3.676-2.948 1.156-1.688 1.636-3.325 1.662-3.415-.039-.013-3.182-1.221-3.22-4.857-.026-3.04 2.48-4.494 2.597-4.559-1.429-2.09-3.623-2.324-4.39-2.376-2-.156-3.675 1.09-4.61 1.09zM15.53 3.83c.843-1.012 1.4-2.427 1.245-3.83-1.207.052-2.662.805-3.532 1.818-.78.896-1.454 2.338-1.273 3.714 1.338.104 2.715-.688 3.559-1.701",fill:"currentColor"})}),"Login with Apple"]}),f.jsxs(or,{variant:"outline",className:"w-full",children:[f.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:f.jsx("path",{d:"M12.48 10.92v3.28h7.84c-.24 1.84-.853 3.187-1.787 4.133-1.147 1.147-2.933 2.4-6.053 2.4-4.827 0-8.6-3.893-8.6-8.72s3.773-8.72 8.6-8.72c2.6 0 4.507 1.027 5.907 2.347l2.307-2.307C18.747 1.44 16.133 0 12.48 0 5.867 0 .307 5.387.307 12s5.56 12 12.173 12c3.573 0 6.267-1.173 8.373-3.36 2.16-2.16 2.84-5.213 2.84-7.667 0-.76-.053-1.467-.173-2.053H12.48z",fill:"currentColor"})}),"Login with Google"]})]}),f.jsx("div",{className:"relative text-center text-sm after:absolute after:inset-0 after:top-1/2 after:z-0 after:flex after:items-center after:border-t after:border-border",children:f.jsx("span",{className:"relative z-10 bg-background px-2 text-muted-foreground",children:"Or continue with"})}),f.jsxs("div",{className:"grid gap-6",children:[f.jsxs("div",{className:"grid gap-2",children:[f.jsx(lo,{htmlFor:"email",children:"Email"}),f.jsx(uo,{id:"email",type:"email",placeholder:"m@example.com",required:!0})]}),f.jsxs("div",{className:"grid gap-2",children:[f.jsxs("div",{className:"flex items-center",children:[f.jsx(lo,{htmlFor:"password",children:"Password"}),f.jsx("a",{href:"#",className:"ml-auto text-sm underline-offset-4 hover:underline",children:"Forgot your password?"})]}),f.jsx(uo,{id:"password",type:"password",required:!0})]}),f.jsx(or,{type:"submit",className:"w-full",children:"Login"})]}),f.jsxs("div",{className:"text-center text-sm",children:["Don't have an account?"," ",f.jsx("a",{href:"#",className:"underline underline-offset-4",children:"Sign up"})]})]})})})]}),f.jsxs("div",{className:"text-balance text-center text-xs text-muted-foreground [&_a]:underline [&_a]:underline-offset-4 [&_a]:hover:text-primary ",children:["By clicking continue, you agree to our ",f.jsx("a",{href:"#",children:"Terms of Service"})," ","and ",f.jsx("a",{href:"#",children:"Privacy Policy"}),"."]})]})}exports.Accordion=jA;exports.AccordionContent=ay;exports.AccordionItem=ny;exports.AccordionTrigger=oy;exports.Alert=cx;exports.AlertDescription=ux;exports.AlertDialog=nO;exports.AlertDialogAction=ix;exports.AlertDialogCancel=sx;exports.AlertDialogContent=tx;exports.AlertDialogDescription=ax;exports.AlertDialogFooter=nx;exports.AlertDialogHeader=rx;exports.AlertDialogOverlay=jd;exports.AlertDialogPortal=ex;exports.AlertDialogTitle=ox;exports.AlertDialogTrigger=oO;exports.AlertTitle=lx;exports.AspectRatio=cO;exports.Avatar=wx;exports.AvatarFallback=Cx;exports.AvatarImage=Sx;exports.Badge=fO;exports.Breadcrumb=kd;exports.BreadcrumbEllipsis=Rx;exports.BreadcrumbItem=ba;exports.BreadcrumbLink=ya;exports.BreadcrumbList=$d;exports.BreadcrumbPage=Ld;exports.BreadcrumbSeparator=xa;exports.Button=or;exports.Card=oi;exports.CardContent=ci;exports.CardDescription=si;exports.CardFooter=Fd;exports.CardHeader=ai;exports.CardTitle=ii;exports.Carousel=Ax;exports.CarouselContent=Mx;exports.CarouselItem=Ox;exports.CarouselNext=jx;exports.CarouselPrevious=Ix;exports.ChartContainer=cf;exports.ChartLegend=b$;exports.ChartLegendContent=Ew;exports.ChartStyle=_w;exports.ChartTooltip=v$;exports.ChartTooltipContent=Rw;exports.Checkbox=Ow;exports.Collapsible=_$;exports.CollapsibleContent=E$;exports.CollapsibleTrigger=R$;exports.ContextMenu=D2;exports.ContextMenuCheckboxItem=iS;exports.ContextMenuContent=oS;exports.ContextMenuGroup=$2;exports.ContextMenuItem=aS;exports.ContextMenuLabel=cS;exports.ContextMenuPortal=L2;exports.ContextMenuRadioGroup=B2;exports.ContextMenuRadioItem=sS;exports.ContextMenuSeparator=lS;exports.ContextMenuShortcut=uS;exports.ContextMenuSub=F2;exports.ContextMenuSubContent=nS;exports.ContextMenuSubTrigger=rS;exports.ContextMenuTrigger=k2;exports.Dialog=z2;exports.DialogClose=H2;exports.DialogContent=fS;exports.DialogDescription=gS;exports.DialogFooter=mS;exports.DialogHeader=pS;exports.DialogOverlay=Vf;exports.DialogPortal=dS;exports.DialogTitle=hS;exports.DialogTrigger=q2;exports.Drawer=TS;exports.DrawerClose=yF;exports.DrawerContent=AS;exports.DrawerDescription=jS;exports.DrawerFooter=OS;exports.DrawerHeader=MS;exports.DrawerOverlay=Uf;exports.DrawerPortal=NS;exports.DrawerTitle=IS;exports.DrawerTrigger=bF;exports.DropdownMenu=cC;exports.DropdownMenuCheckboxItem=fC;exports.DropdownMenuContent=Kf;exports.DropdownMenuGroup=zF;exports.DropdownMenuItem=Yf;exports.DropdownMenuLabel=mC;exports.DropdownMenuPortal=qF;exports.DropdownMenuRadioGroup=VF;exports.DropdownMenuRadioItem=pC;exports.DropdownMenuSeparator=hC;exports.DropdownMenuShortcut=gC;exports.DropdownMenuSub=HF;exports.DropdownMenuSubContent=dC;exports.DropdownMenuSubTrigger=uC;exports.DropdownMenuTrigger=lC;exports.Form=mB;exports.FormControl=TC;exports.FormDescription=NC;exports.FormField=hB;exports.FormItem=EC;exports.FormLabel=PC;exports.FormMessage=AC;exports.GraphCard=KV;exports.Header=YV;exports.HoverCard=RB;exports.HoverCardContent=$C;exports.HoverCardTrigger=EB;exports.Input=uo;exports.InputOTP=HC;exports.InputOTPGroup=VC;exports.InputOTPSeparator=UC;exports.InputOTPSlot=GC;exports.Label=lo;exports.LoginForm=XV;exports.Menubar=__;exports.MenubarCheckboxItem=A_;exports.MenubarContent=T_;exports.MenubarGroup=uz;exports.MenubarItem=N_;exports.MenubarLabel=O_;exports.MenubarMenu=lz;exports.MenubarPortal=dz;exports.MenubarRadioGroup=fz;exports.MenubarRadioItem=M_;exports.MenubarSeparator=I_;exports.MenubarShortcut=j_;exports.MenubarSub=pz;exports.MenubarSubContent=P_;exports.MenubarSubTrigger=E_;exports.MenubarTrigger=R_;exports.NavigationMenu=sR;exports.NavigationMenuContent=dR;exports.NavigationMenuIndicator=fR;exports.NavigationMenuItem=Oz;exports.NavigationMenuLink=Iz;exports.NavigationMenuList=cR;exports.NavigationMenuTrigger=uR;exports.NavigationMenuViewport=sp;exports.Pagination=pR;exports.PaginationContent=mR;exports.PaginationEllipsis=bR;exports.PaginationItem=hR;exports.PaginationLink=Ti;exports.PaginationNext=vR;exports.PaginationPrevious=gR;exports.Popover=Uz;exports.PopoverAnchor=Kz;exports.PopoverContent=MR;exports.PopoverTrigger=Wz;exports.Progress=$R;exports.RadioGroup=ZR;exports.RadioGroupItem=JR;exports.ResizableHandle=Vq;exports.ResizablePanel=Hq;exports.ResizablePanelGroup=qq;exports.ScrollArea=DE;exports.ScrollBar=Sp;exports.Select=A5;exports.SelectContent=yP;exports.SelectGroup=M5;exports.SelectItem=wP;exports.SelectLabel=xP;exports.SelectScrollDownButton=Rp;exports.SelectScrollUpButton=_p;exports.SelectSeparator=SP;exports.SelectTrigger=bP;exports.SelectValue=O5;exports.Separator=Ep;exports.Sheet=RP;exports.SheetClose=$5;exports.SheetContent=Tp;exports.SheetDescription=Mp;exports.SheetFooter=PP;exports.SheetHeader=Np;exports.SheetOverlay=Pp;exports.SheetPortal=EP;exports.SheetTitle=Ap;exports.SheetTrigger=k5;exports.Sidebar=qP;exports.SidebarContent=XP;exports.SidebarFooter=KP;exports.SidebarGroup=ZP;exports.SidebarGroupAction=QP;exports.SidebarGroupContent=eT;exports.SidebarGroupLabel=JP;exports.SidebarHeader=WP;exports.SidebarInput=UP;exports.SidebarInset=GP;exports.SidebarMenu=tT;exports.SidebarMenuAction=oT;exports.SidebarMenuBadge=aT;exports.SidebarMenuButton=nT;exports.SidebarMenuItem=rT;exports.SidebarMenuSkeleton=iT;exports.SidebarMenuSub=sT;exports.SidebarMenuSubButton=lT;exports.SidebarMenuSubItem=cT;exports.SidebarProvider=zP;exports.SidebarRail=VP;exports.SidebarSeparator=YP;exports.SidebarTrigger=HP;exports.Skeleton=id;exports.Slider=_T;exports.SonnerToaster=sV;exports.Switch=AT;exports.Table=MT;exports.TableBody=IT;exports.TableCaption=LT;exports.TableCell=$T;exports.TableFooter=jT;exports.TableHead=kT;exports.TableHeader=OT;exports.TableRow=DT;exports.Tabs=gV;exports.TabsContent=eN;exports.TabsList=JT;exports.TabsTrigger=QT;exports.Textarea=tN;exports.Toast=Hp;exports.ToastAction=SN;exports.ToastClose=Vp;exports.ToastDescription=Up;exports.ToastProvider=wN;exports.ToastTitle=Gp;exports.ToastViewport=qp;exports.Toaster=qV;exports.Toggle=ON;exports.ToggleGroup=jN;exports.ToggleGroupItem=DN;exports.Tooltip=LP;exports.TooltipContent=jp;exports.TooltipProvider=$P;exports.TooltipTrigger=FP;exports.badgeVariants=_x;exports.buttonVariants=xo;exports.navigationMenuTriggerStyle=lR;exports.toggleVariants=Yp;exports.useFormField=Do;exports.useSidebar=Bo;
|