buildgrid-ui 1.1.0-dev.21 → 1.1.0-dev.22

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.
@@ -1,4 +1,4 @@
1
- (function(E,x){typeof exports=="object"&&typeof module<"u"?x(exports,require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","react-dom"],x):(E=typeof globalThis<"u"?globalThis:E||self,x(E.BuildgridUI={},E.React,E.ReactDOM))})(this,function(E,x,Zn){"use strict";function Ja(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const l=Ja(x),Jn=Ja(Zn);var er={exports:{}},vn={};/**
1
+ (function(P,S){typeof exports=="object"&&typeof module<"u"?S(exports,require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react","react-dom"],S):(P=typeof globalThis<"u"?globalThis:P||self,S(P.BuildgridUI={},P.React,P.ReactDOM))})(this,function(P,S,En){"use strict";function Ca(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const l=Ca(S),Sn=Ca(En);var Pn={exports:{}},Ut={};/**
2
2
  * @license React
3
3
  * react-jsx-runtime.production.js
4
4
  *
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */var es;function uh(){if(es)return vn;es=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,a){var s=null;if(a!==void 0&&(s=""+a),o.key!==void 0&&(s=""+o.key),"key"in o){a={};for(var i in o)i!=="key"&&(a[i]=o[i])}else a=o;return o=a.ref,{$$typeof:e,type:r,key:s,ref:o!==void 0?o:null,props:a}}return vn.Fragment=t,vn.jsx=n,vn.jsxs=n,vn}var yn={};/**
9
+ */var Na;function Xf(){if(Na)return Ut;Na=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(o,r,a){var s=null;if(a!==void 0&&(s=""+a),r.key!==void 0&&(s=""+r.key),"key"in r){a={};for(var i in r)i!=="key"&&(a[i]=r[i])}else a=r;return r=a.ref,{$$typeof:e,type:o,key:s,ref:r!==void 0?r:null,props:a}}return Ut.Fragment=t,Ut.jsx=n,Ut.jsxs=n,Ut}var Kt={};/**
10
10
  * @license React
11
11
  * react-jsx-runtime.development.js
12
12
  *
@@ -14,184 +14,184 @@
14
14
  *
15
15
  * This source code is licensed under the MIT license found in the
16
16
  * LICENSE file in the root directory of this source tree.
17
- */var ts;function dh(){return ts||(ts=1,process.env.NODE_ENV!=="production"&&function(){function e(N){if(N==null)return null;if(typeof N=="function")return N.$$typeof===L?null:N.displayName||N.name||null;if(typeof N=="string")return N;switch(N){case k:return"Fragment";case S:return"Portal";case D:return"Profiler";case P:return"StrictMode";case _:return"Suspense";case z:return"SuspenseList"}if(typeof N=="object")switch(typeof N.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),N.$$typeof){case $:return(N.displayName||"Context")+".Provider";case R:return(N._context.displayName||"Context")+".Consumer";case V:var B=N.render;return N=N.displayName,N||(N=B.displayName||B.name||"",N=N!==""?"ForwardRef("+N+")":"ForwardRef"),N;case G:return B=N.displayName||null,B!==null?B:e(N.type)||"Memo";case ee:B=N._payload,N=N._init;try{return e(N(B))}catch{}}return null}function t(N){return""+N}function n(N){try{t(N);var B=!1}catch{B=!0}if(B){B=console;var j=B.error,ae=typeof Symbol=="function"&&Symbol.toStringTag&&N[Symbol.toStringTag]||N.constructor.name||"Object";return j.call(B,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",ae),t(N)}}function r(){}function o(){if(Z===0){me=console.log,ge=console.info,I=console.warn,ie=console.error,ce=console.group,oe=console.groupCollapsed,se=console.groupEnd;var N={configurable:!0,enumerable:!0,value:r,writable:!0};Object.defineProperties(console,{info:N,log:N,warn:N,error:N,group:N,groupCollapsed:N,groupEnd:N})}Z++}function a(){if(Z--,Z===0){var N={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:q({},N,{value:me}),info:q({},N,{value:ge}),warn:q({},N,{value:I}),error:q({},N,{value:ie}),group:q({},N,{value:ce}),groupCollapsed:q({},N,{value:oe}),groupEnd:q({},N,{value:se})})}0>Z&&console.error("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}function s(N){if(le===void 0)try{throw Error()}catch(j){var B=j.stack.trim().match(/\n( *(at )?)/);le=B&&B[1]||"",Me=-1<j.stack.indexOf(`
18
- at`)?" (<anonymous>)":-1<j.stack.indexOf("@")?"@unknown:0:0":""}return`
19
- `+le+N+Me}function i(N,B){if(!N||Re)return"";var j=$e.get(N);if(j!==void 0)return j;Re=!0,j=Error.prepareStackTrace,Error.prepareStackTrace=void 0;var ae=null;ae=T.H,T.H=null,o();try{var Pe={DetermineComponentFrameRoot:function(){try{if(B){var ue=function(){throw Error()};if(Object.defineProperty(ue.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ue,[])}catch(Se){var de=Se}Reflect.construct(N,[],ue)}else{try{ue.call()}catch(Se){de=Se}N.call(ue.prototype)}}else{try{throw Error()}catch(Se){de=Se}(ue=N())&&typeof ue.catch=="function"&&ue.catch(function(){})}}catch(Se){if(Se&&de&&typeof Se.stack=="string")return[Se.stack,de.stack]}return[null,null]}};Pe.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var ye=Object.getOwnPropertyDescriptor(Pe.DetermineComponentFrameRoot,"name");ye&&ye.configurable&&Object.defineProperty(Pe.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var Q=Pe.DetermineComponentFrameRoot(),Ue=Q[0],Qe=Q[1];if(Ue&&Qe){var Ce=Ue.split(`
20
- `),Ze=Qe.split(`
21
- `);for(Q=ye=0;ye<Ce.length&&!Ce[ye].includes("DetermineComponentFrameRoot");)ye++;for(;Q<Ze.length&&!Ze[Q].includes("DetermineComponentFrameRoot");)Q++;if(ye===Ce.length||Q===Ze.length)for(ye=Ce.length-1,Q=Ze.length-1;1<=ye&&0<=Q&&Ce[ye]!==Ze[Q];)Q--;for(;1<=ye&&0<=Q;ye--,Q--)if(Ce[ye]!==Ze[Q]){if(ye!==1||Q!==1)do if(ye--,Q--,0>Q||Ce[ye]!==Ze[Q]){var J=`
22
- `+Ce[ye].replace(" at new "," at ");return N.displayName&&J.includes("<anonymous>")&&(J=J.replace("<anonymous>",N.displayName)),typeof N=="function"&&$e.set(N,J),J}while(1<=ye&&0<=Q);break}}}finally{Re=!1,T.H=ae,a(),Error.prepareStackTrace=j}return Ce=(Ce=N?N.displayName||N.name:"")?s(Ce):"",typeof N=="function"&&$e.set(N,Ce),Ce}function c(N){if(N==null)return"";if(typeof N=="function"){var B=N.prototype;return i(N,!(!B||!B.isReactComponent))}if(typeof N=="string")return s(N);switch(N){case _:return s("Suspense");case z:return s("SuspenseList")}if(typeof N=="object")switch(N.$$typeof){case V:return N=i(N.render,!1),N;case G:return c(N.type);case ee:B=N._payload,N=N._init;try{return c(N(B))}catch{}}return""}function d(){var N=T.A;return N===null?null:N.getOwner()}function f(N){if(H.call(N,"key")){var B=Object.getOwnPropertyDescriptor(N,"key").get;if(B&&B.isReactWarning)return!1}return N.key!==void 0}function m(N,B){function j(){Be||(Be=!0,console.error("%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://react.dev/link/special-props)",B))}j.isReactWarning=!0,Object.defineProperty(N,"key",{get:j,configurable:!0})}function p(){var N=e(this.type);return at[N]||(at[N]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),N=this.props.ref,N!==void 0?N:null}function h(N,B,j,ae,Pe,ye){return j=ye.ref,N={$$typeof:M,type:N,key:B,props:ye,_owner:Pe},(j!==void 0?j:null)!==null?Object.defineProperty(N,"ref",{enumerable:!1,get:p}):Object.defineProperty(N,"ref",{enumerable:!1,value:null}),N._store={},Object.defineProperty(N._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(N,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.freeze&&(Object.freeze(N.props),Object.freeze(N)),N}function v(N,B,j,ae,Pe,ye){if(typeof N=="string"||typeof N=="function"||N===k||N===D||N===P||N===_||N===z||N===W||typeof N=="object"&&N!==null&&(N.$$typeof===ee||N.$$typeof===G||N.$$typeof===$||N.$$typeof===R||N.$$typeof===V||N.$$typeof===X||N.getModuleId!==void 0)){var Q=B.children;if(Q!==void 0)if(ae)if(K(Q)){for(ae=0;ae<Q.length;ae++)g(Q[ae],N);Object.freeze&&Object.freeze(Q)}else console.error("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 g(Q,N)}else Q="",(N===void 0||typeof N=="object"&&N!==null&&Object.keys(N).length===0)&&(Q+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."),N===null?ae="null":K(N)?ae="array":N!==void 0&&N.$$typeof===M?(ae="<"+(e(N.type)||"Unknown")+" />",Q=" Did you accidentally export a JSX literal instead of a component?"):ae=typeof N,console.error("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",ae,Q);if(H.call(B,"key")){Q=e(N);var Ue=Object.keys(B).filter(function(Ce){return Ce!=="key"});ae=0<Ue.length?"{key: someKey, "+Ue.join(": ..., ")+": ...}":"{key: someKey}",Xe[Q+ae]||(Ue=0<Ue.length?"{"+Ue.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
17
+ */var Ea;function qf(){return Ea||(Ea=1,process.env.NODE_ENV!=="production"&&function(){function e(x){if(x==null)return null;if(typeof x=="function")return x.$$typeof===V?null:x.displayName||x.name||null;if(typeof x=="string")return x;switch(x){case A:return"Fragment";case E:return"Portal";case I:return"Profiler";case M:return"StrictMode";case O:return"Suspense";case U:return"SuspenseList"}if(typeof x=="object")switch(typeof x.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),x.$$typeof){case B:return(x.displayName||"Context")+".Provider";case j:return(x._context.displayName||"Context")+".Consumer";case z:var F=x.render;return x=x.displayName,x||(x=F.displayName||F.name||"",x=x!==""?"ForwardRef("+x+")":"ForwardRef"),x;case W:return F=x.displayName||null,F!==null?F:e(x.type)||"Memo";case oe:F=x._payload,x=x._init;try{return e(x(F))}catch{}}return null}function t(x){return""+x}function n(x){try{t(x);var F=!1}catch{F=!0}if(F){F=console;var D=F.error,ne=typeof Symbol=="function"&&Symbol.toStringTag&&x[Symbol.toStringTag]||x.constructor.name||"Object";return D.call(F,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",ne),t(x)}}function o(){}function r(){if(q===0){ce=console.log,fe=console.info,k=console.warn,ae=console.error,se=console.group,te=console.groupCollapsed,re=console.groupEnd;var x={configurable:!0,enumerable:!0,value:o,writable:!0};Object.defineProperties(console,{info:x,log:x,warn:x,error:x,group:x,groupCollapsed:x,groupEnd:x})}q++}function a(){if(q--,q===0){var x={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:Z({},x,{value:ce}),info:Z({},x,{value:fe}),warn:Z({},x,{value:k}),error:Z({},x,{value:ae}),group:Z({},x,{value:se}),groupCollapsed:Z({},x,{value:te}),groupEnd:Z({},x,{value:re})})}0>q&&console.error("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}function s(x){if(ie===void 0)try{throw Error()}catch(D){var F=D.stack.trim().match(/\n( *(at )?)/);ie=F&&F[1]||"",ye=-1<D.stack.indexOf(`
18
+ at`)?" (<anonymous>)":-1<D.stack.indexOf("@")?"@unknown:0:0":""}return`
19
+ `+ie+x+ye}function i(x,F){if(!x||Se)return"";var D=Ae.get(x);if(D!==void 0)return D;Se=!0,D=Error.prepareStackTrace,Error.prepareStackTrace=void 0;var ne=null;ne=T.H,T.H=null,r();try{var xe={DetermineComponentFrameRoot:function(){try{if(F){var Ve=function(){throw Error()};if(Object.defineProperty(Ve.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Ve,[])}catch(ke){var Ht=ke}Reflect.construct(x,[],Ve)}else{try{Ve.call()}catch(ke){Ht=ke}x.call(Ve.prototype)}}else{try{throw Error()}catch(ke){Ht=ke}(Ve=x())&&typeof Ve.catch=="function"&&Ve.catch(function(){})}}catch(ke){if(ke&&Ht&&typeof ke.stack=="string")return[ke.stack,Ht.stack]}return[null,null]}};xe.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var de=Object.getOwnPropertyDescriptor(xe.DetermineComponentFrameRoot,"name");de&&de.configurable&&Object.defineProperty(xe.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var Y=xe.DetermineComponentFrameRoot(),$e=Y[0],Xe=Y[1];if($e&&Xe){var me=$e.split(`
20
+ `),qe=Xe.split(`
21
+ `);for(Y=de=0;de<me.length&&!me[de].includes("DetermineComponentFrameRoot");)de++;for(;Y<qe.length&&!qe[Y].includes("DetermineComponentFrameRoot");)Y++;if(de===me.length||Y===qe.length)for(de=me.length-1,Y=qe.length-1;1<=de&&0<=Y&&me[de]!==qe[Y];)Y--;for(;1<=de&&0<=Y;de--,Y--)if(me[de]!==qe[Y]){if(de!==1||Y!==1)do if(de--,Y--,0>Y||me[de]!==qe[Y]){var Je=`
22
+ `+me[de].replace(" at new "," at ");return x.displayName&&Je.includes("<anonymous>")&&(Je=Je.replace("<anonymous>",x.displayName)),typeof x=="function"&&Ae.set(x,Je),Je}while(1<=de&&0<=Y);break}}}finally{Se=!1,T.H=ne,a(),Error.prepareStackTrace=D}return me=(me=x?x.displayName||x.name:"")?s(me):"",typeof x=="function"&&Ae.set(x,me),me}function u(x){if(x==null)return"";if(typeof x=="function"){var F=x.prototype;return i(x,!(!F||!F.isReactComponent))}if(typeof x=="string")return s(x);switch(x){case O:return s("Suspense");case U:return s("SuspenseList")}if(typeof x=="object")switch(x.$$typeof){case z:return x=i(x.render,!1),x;case W:return u(x.type);case oe:F=x._payload,x=x._init;try{return u(x(F))}catch{}}return""}function d(){var x=T.A;return x===null?null:x.getOwner()}function f(x){if(H.call(x,"key")){var F=Object.getOwnPropertyDescriptor(x,"key").get;if(F&&F.isReactWarning)return!1}return x.key!==void 0}function m(x,F){function D(){Fe||(Fe=!0,console.error("%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://react.dev/link/special-props)",F))}D.isReactWarning=!0,Object.defineProperty(x,"key",{get:D,configurable:!0})}function h(){var x=e(this.type);return rt[x]||(rt[x]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),x=this.props.ref,x!==void 0?x:null}function p(x,F,D,ne,xe,de){return D=de.ref,x={$$typeof:N,type:x,key:F,props:de,_owner:xe},(D!==void 0?D:null)!==null?Object.defineProperty(x,"ref",{enumerable:!1,get:h}):Object.defineProperty(x,"ref",{enumerable:!1,value:null}),x._store={},Object.defineProperty(x._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(x,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.freeze&&(Object.freeze(x.props),Object.freeze(x)),x}function b(x,F,D,ne,xe,de){if(typeof x=="string"||typeof x=="function"||x===A||x===I||x===M||x===O||x===U||x===$||typeof x=="object"&&x!==null&&(x.$$typeof===oe||x.$$typeof===W||x.$$typeof===B||x.$$typeof===j||x.$$typeof===z||x.$$typeof===X||x.getModuleId!==void 0)){var Y=F.children;if(Y!==void 0)if(ne)if(K(Y)){for(ne=0;ne<Y.length;ne++)g(Y[ne],x);Object.freeze&&Object.freeze(Y)}else console.error("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 g(Y,x)}else Y="",(x===void 0||typeof x=="object"&&x!==null&&Object.keys(x).length===0)&&(Y+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."),x===null?ne="null":K(x)?ne="array":x!==void 0&&x.$$typeof===N?(ne="<"+(e(x.type)||"Unknown")+" />",Y=" Did you accidentally export a JSX literal instead of a component?"):ne=typeof x,console.error("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",ne,Y);if(H.call(F,"key")){Y=e(x);var $e=Object.keys(F).filter(function(me){return me!=="key"});ne=0<$e.length?"{key: someKey, "+$e.join(": ..., ")+": ...}":"{key: someKey}",Ye[Y+ne]||($e=0<$e.length?"{"+$e.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
23
23
  let props = %s;
24
24
  <%s {...props} />
25
25
  React keys must be passed directly to JSX without using spread:
26
26
  let props = %s;
27
- <%s key={someKey} {...props} />`,ae,Q,Ue,Q),Xe[Q+ae]=!0)}if(Q=null,j!==void 0&&(n(j),Q=""+j),f(B)&&(n(B.key),Q=""+B.key),"key"in B){j={};for(var Qe in B)Qe!=="key"&&(j[Qe]=B[Qe])}else j=B;return Q&&m(j,typeof N=="function"?N.displayName||N.name||"Unknown":N),h(N,Q,ye,Pe,d(),j)}function g(N,B){if(typeof N=="object"&&N&&N.$$typeof!==ot){if(K(N))for(var j=0;j<N.length;j++){var ae=N[j];y(ae)&&w(ae,B)}else if(y(N))N._store&&(N._store.validated=1);else if(N===null||typeof N!="object"?j=null:(j=Y&&N[Y]||N["@@iterator"],j=typeof j=="function"?j:null),typeof j=="function"&&j!==N.entries&&(j=j.call(N),j!==N))for(;!(N=j.next()).done;)y(N.value)&&w(N.value,B)}}function y(N){return typeof N=="object"&&N!==null&&N.$$typeof===M}function w(N,B){if(N._store&&!N._store.validated&&N.key==null&&(N._store.validated=1,B=b(B),!st[B])){st[B]=!0;var j="";N&&N._owner!=null&&N._owner!==d()&&(j=null,typeof N._owner.tag=="number"?j=e(N._owner.type):typeof N._owner.name=="string"&&(j=N._owner.name),j=" It was passed a child from "+j+".");var ae=T.getCurrentStack;T.getCurrentStack=function(){var Pe=c(N.type);return ae&&(Pe+=ae()||""),Pe},console.error('Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',B,j),T.getCurrentStack=ae}}function b(N){var B="",j=d();return j&&(j=e(j.type))&&(B=`
27
+ <%s key={someKey} {...props} />`,ne,Y,$e,Y),Ye[Y+ne]=!0)}if(Y=null,D!==void 0&&(n(D),Y=""+D),f(F)&&(n(F.key),Y=""+F.key),"key"in F){D={};for(var Xe in F)Xe!=="key"&&(D[Xe]=F[Xe])}else D=F;return Y&&m(D,typeof x=="function"?x.displayName||x.name||"Unknown":x),p(x,Y,de,xe,d(),D)}function g(x,F){if(typeof x=="object"&&x&&x.$$typeof!==ot){if(K(x))for(var D=0;D<x.length;D++){var ne=x[D];v(ne)&&y(ne,F)}else if(v(x))x._store&&(x._store.validated=1);else if(x===null||typeof x!="object"?D=null:(D=G&&x[G]||x["@@iterator"],D=typeof D=="function"?D:null),typeof D=="function"&&D!==x.entries&&(D=D.call(x),D!==x))for(;!(x=D.next()).done;)v(x.value)&&y(x.value,F)}}function v(x){return typeof x=="object"&&x!==null&&x.$$typeof===N}function y(x,F){if(x._store&&!x._store.validated&&x.key==null&&(x._store.validated=1,F=w(F),!at[F])){at[F]=!0;var D="";x&&x._owner!=null&&x._owner!==d()&&(D=null,typeof x._owner.tag=="number"?D=e(x._owner.type):typeof x._owner.name=="string"&&(D=x._owner.name),D=" It was passed a child from "+D+".");var ne=T.getCurrentStack;T.getCurrentStack=function(){var xe=u(x.type);return ne&&(xe+=ne()||""),xe},console.error('Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',F,D),T.getCurrentStack=ne}}function w(x){var F="",D=d();return D&&(D=e(D.type))&&(F=`
28
28
 
29
- Check the render method of \``+j+"`."),B||(N=e(N))&&(B=`
29
+ Check the render method of \``+D+"`."),F||(x=e(x))&&(F=`
30
30
 
31
- Check the top-level render call using <`+N+">."),B}var C=x,M=Symbol.for("react.transitional.element"),S=Symbol.for("react.portal"),k=Symbol.for("react.fragment"),P=Symbol.for("react.strict_mode"),D=Symbol.for("react.profiler"),R=Symbol.for("react.consumer"),$=Symbol.for("react.context"),V=Symbol.for("react.forward_ref"),_=Symbol.for("react.suspense"),z=Symbol.for("react.suspense_list"),G=Symbol.for("react.memo"),ee=Symbol.for("react.lazy"),W=Symbol.for("react.offscreen"),Y=Symbol.iterator,L=Symbol.for("react.client.reference"),T=C.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,H=Object.prototype.hasOwnProperty,q=Object.assign,X=Symbol.for("react.client.reference"),K=Array.isArray,Z=0,me,ge,I,ie,ce,oe,se;r.__reactDisabledLog=!0;var le,Me,Re=!1,$e=new(typeof WeakMap=="function"?WeakMap:Map),ot=Symbol.for("react.client.reference"),Be,at={},Xe={},st={};yn.Fragment=k,yn.jsx=function(N,B,j,ae,Pe){return v(N,B,j,!1,ae,Pe)},yn.jsxs=function(N,B,j,ae,Pe){return v(N,B,j,!0,ae,Pe)}}()),yn}var ns;function fh(){return ns||(ns=1,process.env.NODE_ENV==="production"?er.exports=uh():er.exports=dh()),er.exports}var u=fh();function rs(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=rs(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function os(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=rs(e))&&(r&&(r+=" "),r+=t);return r}const eo="-",mh=e=>{const t=ph(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const i=s.split(eo);return i[0]===""&&i.length!==1&&i.shift(),as(i,t)||hh(s)},getConflictingClassGroupIds:(s,i)=>{const c=n[s]||[];return i&&r[s]?[...c,...r[s]]:c}}},as=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?as(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const a=e.join(eo);return(s=t.validators.find(({validator:i})=>i(a)))==null?void 0:s.classGroupId},ss=/^\[(.+)\]$/,hh=e=>{if(ss.test(e)){const t=ss.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},ph=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return vh(Object.entries(e.classGroups),n).forEach(([a,s])=>{to(s,r,a,t)}),r},to=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const a=o===""?t:is(t,o);a.classGroupId=n;return}if(typeof o=="function"){if(gh(o)){to(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([a,s])=>{to(s,is(t,a),n,r)})})},is=(e,t)=>{let n=e;return t.split(eo).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},gh=e=>e.isThemeGetter,vh=(e,t)=>t?e.map(([n,r])=>{const o=r.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([s,i])=>[t+s,i])):a);return[n,o]}):e,yh=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(a,s)=>{n.set(a,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(a){let s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return o(a,s),s},set(a,s){n.has(a)?n.set(a,s):o(a,s)}}},cs="!",bh=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,o=t[0],a=t.length,s=i=>{const c=[];let d=0,f=0,m;for(let y=0;y<i.length;y++){let w=i[y];if(d===0){if(w===o&&(r||i.slice(y,y+a)===t)){c.push(i.slice(f,y)),f=y+a;continue}if(w==="/"){m=y;continue}}w==="["?d++:w==="]"&&d--}const p=c.length===0?i:i.substring(f),h=p.startsWith(cs),v=h?p.substring(1):p,g=m&&m>f?m-f:void 0;return{modifiers:c,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:g}};return n?i=>n({className:i,parseClassName:s}):s},wh=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},xh=e=>({cache:yh(e.cacheSize),parseClassName:bh(e),...mh(e)}),Ch=/\s+/,Nh=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,a=[],s=e.trim().split(Ch);let i="";for(let c=s.length-1;c>=0;c-=1){const d=s[c],{modifiers:f,hasImportantModifier:m,baseClassName:p,maybePostfixModifierPosition:h}=n(d);let v=!!h,g=r(v?p.substring(0,h):p);if(!g){if(!v){i=d+(i.length>0?" "+i:i);continue}if(g=r(p),!g){i=d+(i.length>0?" "+i:i);continue}v=!1}const y=wh(f).join(":"),w=m?y+cs:y,b=w+g;if(a.includes(b))continue;a.push(b);const C=o(g,v);for(let M=0;M<C.length;++M){const S=C[M];a.push(w+S)}i=d+(i.length>0?" "+i:i)}return i};function Mh(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=ls(t))&&(r&&(r+=" "),r+=n);return r}const ls=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=ls(e[r]))&&(n&&(n+=" "),n+=t);return n};function Sh(e,...t){let n,r,o,a=s;function s(c){const d=t.reduce((f,m)=>m(f),e());return n=xh(d),r=n.cache.get,o=n.cache.set,a=i,i(c)}function i(c){const d=r(c);if(d)return d;const f=Nh(c,n);return o(c,f),f}return function(){return a(Mh.apply(null,arguments))}}const xe=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},us=/^\[(?:([a-z-]+):)?(.+)\]$/i,Eh=/^\d+\/\d+$/,Ph=new Set(["px","full","screen"]),kh=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Th=/\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$/,Dh=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Oh=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Ah=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,gt=e=>Ht(e)||Ph.has(e)||Eh.test(e),Mt=e=>Ut(e,"length",Lh),Ht=e=>!!e&&!Number.isNaN(Number(e)),no=e=>Ut(e,"number",Ht),bn=e=>!!e&&Number.isInteger(Number(e)),_h=e=>e.endsWith("%")&&Ht(e.slice(0,-1)),re=e=>us.test(e),St=e=>kh.test(e),Rh=new Set(["length","size","percentage"]),Ih=e=>Ut(e,Rh,ds),jh=e=>Ut(e,"position",ds),Fh=new Set(["image","url"]),$h=e=>Ut(e,Fh,Vh),Wh=e=>Ut(e,"",Bh),wn=()=>!0,Ut=(e,t,n)=>{const r=us.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},Lh=e=>Th.test(e)&&!Dh.test(e),ds=()=>!1,Bh=e=>Oh.test(e),Vh=e=>Ah.test(e),Yh=Sh(()=>{const e=xe("colors"),t=xe("spacing"),n=xe("blur"),r=xe("brightness"),o=xe("borderColor"),a=xe("borderRadius"),s=xe("borderSpacing"),i=xe("borderWidth"),c=xe("contrast"),d=xe("grayscale"),f=xe("hueRotate"),m=xe("invert"),p=xe("gap"),h=xe("gradientColorStops"),v=xe("gradientColorStopPositions"),g=xe("inset"),y=xe("margin"),w=xe("opacity"),b=xe("padding"),C=xe("saturate"),M=xe("scale"),S=xe("sepia"),k=xe("skew"),P=xe("space"),D=xe("translate"),R=()=>["auto","contain","none"],$=()=>["auto","hidden","clip","visible","scroll"],V=()=>["auto",re,t],_=()=>[re,t],z=()=>["",gt,Mt],G=()=>["auto",Ht,re],ee=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],W=()=>["solid","dashed","dotted","double","none"],Y=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],L=()=>["start","end","center","between","around","evenly","stretch"],T=()=>["","0",re],H=()=>["auto","avoid","all","avoid-page","page","left","right","column"],q=()=>[Ht,re];return{cacheSize:500,separator:":",theme:{colors:[wn],spacing:[gt,Mt],blur:["none","",St,re],brightness:q(),borderColor:[e],borderRadius:["none","","full",St,re],borderSpacing:_(),borderWidth:z(),contrast:q(),grayscale:T(),hueRotate:q(),invert:T(),gap:_(),gradientColorStops:[e],gradientColorStopPositions:[_h,Mt],inset:V(),margin:V(),opacity:q(),padding:_(),saturate:q(),scale:q(),sepia:T(),skew:q(),space:_(),translate:_()},classGroups:{aspect:[{aspect:["auto","square","video",re]}],container:["container"],columns:[{columns:[St]}],"break-after":[{"break-after":H()}],"break-before":[{"break-before":H()}],"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"],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:[...ee(),re]}],overflow:[{overflow:$()}],"overflow-x":[{"overflow-x":$()}],"overflow-y":[{"overflow-y":$()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[g]}],"inset-x":[{"inset-x":[g]}],"inset-y":[{"inset-y":[g]}],start:[{start:[g]}],end:[{end:[g]}],top:[{top:[g]}],right:[{right:[g]}],bottom:[{bottom:[g]}],left:[{left:[g]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",bn,re]}],basis:[{basis:V()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",re]}],grow:[{grow:T()}],shrink:[{shrink:T()}],order:[{order:["first","last","none",bn,re]}],"grid-cols":[{"grid-cols":[wn]}],"col-start-end":[{col:["auto",{span:["full",bn,re]},re]}],"col-start":[{"col-start":G()}],"col-end":[{"col-end":G()}],"grid-rows":[{"grid-rows":[wn]}],"row-start-end":[{row:["auto",{span:[bn,re]},re]}],"row-start":[{"row-start":G()}],"row-end":[{"row-end":G()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",re]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",re]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...L()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...L(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...L(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[b]}],px:[{px:[b]}],py:[{py:[b]}],ps:[{ps:[b]}],pe:[{pe:[b]}],pt:[{pt:[b]}],pr:[{pr:[b]}],pb:[{pb:[b]}],pl:[{pl:[b]}],m:[{m:[y]}],mx:[{mx:[y]}],my:[{my:[y]}],ms:[{ms:[y]}],me:[{me:[y]}],mt:[{mt:[y]}],mr:[{mr:[y]}],mb:[{mb:[y]}],ml:[{ml:[y]}],"space-x":[{"space-x":[P]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[P]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",re,t]}],"min-w":[{"min-w":[re,t,"min","max","fit"]}],"max-w":[{"max-w":[re,t,"none","full","min","max","fit","prose",{screen:[St]},St]}],h:[{h:[re,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[re,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[re,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[re,t,"auto","min","max","fit"]}],"font-size":[{text:["base",St,Mt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",no]}],"font-family":[{font:[wn]}],"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:["tighter","tight","normal","wide","wider","widest",re]}],"line-clamp":[{"line-clamp":["none",Ht,no]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",gt,re]}],"list-image":[{"list-image":["none",re]}],"list-style-type":[{list:["none","disc","decimal",re]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[w]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[w]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...W(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",gt,Mt]}],"underline-offset":[{"underline-offset":["auto",gt,re]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:_()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",re]}],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",re]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[w]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ee(),jh]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Ih]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},$h]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[v]}],"gradient-via-pos":[{via:[v]}],"gradient-to-pos":[{to:[v]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[w]}],"border-style":[{border:[...W(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[w]}],"divide-style":[{divide:W()}],"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:["",...W()]}],"outline-offset":[{"outline-offset":[gt,re]}],"outline-w":[{outline:[gt,Mt]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[w]}],"ring-offset-w":[{"ring-offset":[gt,Mt]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",St,Wh]}],"shadow-color":[{shadow:[wn]}],opacity:[{opacity:[w]}],"mix-blend":[{"mix-blend":[...Y(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":Y()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",St,re]}],grayscale:[{grayscale:[d]}],"hue-rotate":[{"hue-rotate":[f]}],invert:[{invert:[m]}],saturate:[{saturate:[C]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[d]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[f]}],"backdrop-invert":[{"backdrop-invert":[m]}],"backdrop-opacity":[{"backdrop-opacity":[w]}],"backdrop-saturate":[{"backdrop-saturate":[C]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",re]}],duration:[{duration:q()}],ease:[{ease:["linear","in","out","in-out",re]}],delay:[{delay:q()}],animate:[{animate:["none","spin","ping","pulse","bounce",re]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[M]}],"scale-x":[{"scale-x":[M]}],"scale-y":[{"scale-y":[M]}],rotate:[{rotate:[bn,re]}],"translate-x":[{"translate-x":[D]}],"translate-y":[{"translate-y":[D]}],"skew-x":[{"skew-x":[k]}],"skew-y":[{"skew-y":[k]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",re]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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",re]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":_()}],"scroll-mx":[{"scroll-mx":_()}],"scroll-my":[{"scroll-my":_()}],"scroll-ms":[{"scroll-ms":_()}],"scroll-me":[{"scroll-me":_()}],"scroll-mt":[{"scroll-mt":_()}],"scroll-mr":[{"scroll-mr":_()}],"scroll-mb":[{"scroll-mb":_()}],"scroll-ml":[{"scroll-ml":_()}],"scroll-p":[{"scroll-p":_()}],"scroll-px":[{"scroll-px":_()}],"scroll-py":[{"scroll-py":_()}],"scroll-ps":[{"scroll-ps":_()}],"scroll-pe":[{"scroll-pe":_()}],"scroll-pt":[{"scroll-pt":_()}],"scroll-pr":[{"scroll-pr":_()}],"scroll-pb":[{"scroll-pb":_()}],"scroll-pl":[{"scroll-pl":_()}],"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",re]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[gt,Mt,no]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"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"],"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"]}}});function O(...e){return Yh(os(e))}const Gh=(e,t="pt-BR",n="BRL")=>new Intl.NumberFormat(t,{style:"currency",currency:n,minimumFractionDigits:2}).format(e),zh=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{day:"2-digit",month:"long",weekday:"long"}).format(new Date(e)),Hh=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{day:"2-digit",month:"long",weekday:"long",year:"numeric"}).format(new Date(e)),Uh=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{day:"2-digit",month:"long"}).format(new Date(e)),Kh=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{dateStyle:"long"}).format(typeof e=="string"?new Date(e):e),qh=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{dateStyle:"short"}).format(e),Xh=e=>e.slice(0,7),Qh=(e,t="pt-BR")=>e.toLocaleDateString(t,{weekday:"short",day:"2-digit",month:"2-digit"}),fs=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,ms=os,Kt=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return ms(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:a}=t,s=Object.keys(o).map(d=>{const f=n==null?void 0:n[d],m=a==null?void 0:a[d];if(f===null)return null;const p=fs(f)||fs(m);return o[d][p]}),i=n&&Object.entries(n).reduce((d,f)=>{let[m,p]=f;return p===void 0||(d[m]=p),d},{}),c=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((d,f)=>{let{class:m,className:p,...h}=f;return Object.entries(h).every(v=>{let[g,y]=v;return Array.isArray(y)?y.includes({...a,...i}[g]):{...a,...i}[g]===y})?[...d,m,p]:d},[]);return ms(e,s,c,n==null?void 0:n.class,n==null?void 0:n.className)},Zh=Kt("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",{variants:{sizing:{sm:"h-8 text-xs px-2",md:"h-10 text-sm px-3",lg:"h-12 text-base px-4",xl:"h-14 text-lg px-5","2xl":"h-16 text-xl px-6"}},defaultVariants:{sizing:"md"}}),tr=l.forwardRef(({className:e,sizing:t,type:n,...r},o)=>u.jsx("input",{type:n,className:O(Zh({sizing:t,className:e})),ref:o,...r}));tr.displayName="Input";const Jh=(e,t)=>{const n=e.replace(/\D/g,"");let r="",o=0,a=0;for(;o<t.length&&a<n.length;)t[o]==="0"?(r+=n[a],a++):r+=t[o],o++;return r},nr=l.forwardRef(({className:e,leftIcon:t,rightIcon:n,mask:r,onChange:o,...a},s)=>{const i=c=>{const d=c.target;if(r){const f=Jh(d.value,r);d.value=f}o==null||o(c)};return u.jsxs("div",{className:"relative w-full",children:[t&&u.jsx("div",{className:"absolute left-2 top-1/2 -translate-y-1/2 text-muted-foreground",children:t}),u.jsx(tr,{className:O(t&&"pl-8",n&&"pr-8",e),ref:s,onInput:i,...a}),n&&u.jsx("div",{className:"absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground",children:n})]})});nr.displayName="AdaptiveInput";function ep(e,t){const n=l.createContext(t),r=a=>{const{children:s,...i}=a,c=l.useMemo(()=>i,Object.values(i));return u.jsx(n.Provider,{value:c,children:s})};r.displayName=e+"Provider";function o(a){const s=l.useContext(n);if(s)return s;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[r,o]}function Te(e,t=[]){let n=[];function r(a,s){const i=l.createContext(s),c=n.length;n=[...n,s];const d=m=>{var w;const{scope:p,children:h,...v}=m,g=((w=p==null?void 0:p[e])==null?void 0:w[c])||i,y=l.useMemo(()=>v,Object.values(v));return u.jsx(g.Provider,{value:y,children:h})};d.displayName=a+"Provider";function f(m,p){var g;const h=((g=p==null?void 0:p[e])==null?void 0:g[c])||i,v=l.useContext(h);if(v)return v;if(s!==void 0)return s;throw new Error(`\`${m}\` must be used within \`${a}\``)}return[d,f]}const o=()=>{const a=n.map(s=>l.createContext(s));return function(i){const c=(i==null?void 0:i[e])||a;return l.useMemo(()=>({[`__scope${e}`]:{...i,[e]:c}}),[i,c])}};return o.scopeName=e,[r,tp(o,...t)]}function tp(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const s=r.reduce((i,{useScope:c,scopeName:d})=>{const m=c(a)[`__scope${d}`];return{...i,...m}},{});return l.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function hs(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function xn(...e){return t=>{let n=!1;const r=e.map(o=>{const a=hs(o,t);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let o=0;o<r.length;o++){const a=r[o];typeof a=="function"?a():hs(e[o],null)}}}}function ne(...e){return l.useCallback(xn(...e),e)}function A(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}var Ee=globalThis!=null&&globalThis.document?l.useLayoutEffect:()=>{},np=l.useId||(()=>{}),rp=0;function je(e){const[t,n]=l.useState(np());return Ee(()=>{e||n(r=>r??String(rp++))},[e]),e||(t?`radix-${t}`:"")}function Ne(e){const t=l.useRef(e);return l.useEffect(()=>{t.current=e}),l.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function Ie({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=op({defaultProp:t,onChange:n}),a=e!==void 0,s=a?e:r,i=Ne(n),c=l.useCallback(d=>{if(a){const m=typeof d=="function"?d(e):d;m!==e&&i(m)}else o(d)},[a,e,o,i]);return[s,c]}function op({defaultProp:e,onChange:t}){const n=l.useState(e),[r]=n,o=l.useRef(r),a=Ne(t);return l.useEffect(()=>{o.current!==r&&(a(r),o.current=r)},[r,o,a]),n}var it=l.forwardRef((e,t)=>{const{children:n,...r}=e,o=l.Children.toArray(n),a=o.find(ap);if(a){const s=a.props.children,i=o.map(c=>c===a?l.Children.count(s)>1?l.Children.only(null):l.isValidElement(s)?s.props.children:null:c);return u.jsx(ro,{...r,ref:t,children:l.isValidElement(s)?l.cloneElement(s,void 0,i):null})}return u.jsx(ro,{...r,ref:t,children:n})});it.displayName="Slot";var ro=l.forwardRef((e,t)=>{const{children:n,...r}=e;if(l.isValidElement(n)){const o=ip(n);return l.cloneElement(n,{...sp(r,n.props),ref:t?xn(t,o):o})}return l.Children.count(n)>1?l.Children.only(null):null});ro.displayName="SlotClone";var oo=({children:e})=>u.jsx(u.Fragment,{children:e});function ap(e){return l.isValidElement(e)&&e.type===oo}function sp(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...i)=>{a(...i),o(...i)}:o&&(n[r]=o):r==="style"?n[r]={...o,...a}:r==="className"&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function ip(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var cp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],F=cp.reduce((e,t)=>{const n=l.forwardRef((r,o)=>{const{asChild:a,...s}=r,i=a?it:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(i,{...s,ref:o})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function rr(e,t){e&&Jn.flushSync(()=>e.dispatchEvent(t))}function lp(e,t=globalThis==null?void 0:globalThis.document){const n=Ne(e);l.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var up="DismissableLayer",ao="dismissableLayer.update",dp="dismissableLayer.pointerDownOutside",fp="dismissableLayer.focusOutside",ps,gs=l.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),$t=l.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:s,onDismiss:i,...c}=e,d=l.useContext(gs),[f,m]=l.useState(null),p=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=l.useState({}),v=ne(t,P=>m(P)),g=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),w=g.indexOf(y),b=f?g.indexOf(f):-1,C=d.layersWithOutsidePointerEventsDisabled.size>0,M=b>=w,S=pp(P=>{const D=P.target,R=[...d.branches].some($=>$.contains(D));!M||R||(o==null||o(P),s==null||s(P),P.defaultPrevented||i==null||i())},p),k=gp(P=>{const D=P.target;[...d.branches].some($=>$.contains(D))||(a==null||a(P),s==null||s(P),P.defaultPrevented||i==null||i())},p);return lp(P=>{b===d.layers.size-1&&(r==null||r(P),!P.defaultPrevented&&i&&(P.preventDefault(),i()))},p),l.useEffect(()=>{if(f)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(ps=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),vs(),()=>{n&&d.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=ps)}},[f,p,n,d]),l.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),vs())},[f,d]),l.useEffect(()=>{const P=()=>h({});return document.addEventListener(ao,P),()=>document.removeEventListener(ao,P)},[]),u.jsx(F.div,{...c,ref:v,style:{pointerEvents:C?M?"auto":"none":void 0,...e.style},onFocusCapture:A(e.onFocusCapture,k.onFocusCapture),onBlurCapture:A(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:A(e.onPointerDownCapture,S.onPointerDownCapture)})});$t.displayName=up;var mp="DismissableLayerBranch",hp=l.forwardRef((e,t)=>{const n=l.useContext(gs),r=l.useRef(null),o=ne(t,r);return l.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),u.jsx(F.div,{...e,ref:o})});hp.displayName=mp;function pp(e,t=globalThis==null?void 0:globalThis.document){const n=Ne(e),r=l.useRef(!1),o=l.useRef(()=>{});return l.useEffect(()=>{const a=i=>{if(i.target&&!r.current){let c=function(){ys(dp,n,d,{discrete:!0})};const d={originalEvent:i};i.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function gp(e,t=globalThis==null?void 0:globalThis.document){const n=Ne(e),r=l.useRef(!1);return l.useEffect(()=>{const o=a=>{a.target&&!r.current&&ys(fp,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function vs(){const e=new CustomEvent(ao);document.dispatchEvent(e)}function ys(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?rr(o,a):o.dispatchEvent(a)}var so="focusScope.autoFocusOnMount",io="focusScope.autoFocusOnUnmount",bs={bubbles:!1,cancelable:!0},vp="FocusScope",Cn=l.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...s}=e,[i,c]=l.useState(null),d=Ne(o),f=Ne(a),m=l.useRef(null),p=ne(t,g=>c(g)),h=l.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;l.useEffect(()=>{if(r){let g=function(C){if(h.paused||!i)return;const M=C.target;i.contains(M)?m.current=M:Et(m.current,{select:!0})},y=function(C){if(h.paused||!i)return;const M=C.relatedTarget;M!==null&&(i.contains(M)||Et(m.current,{select:!0}))},w=function(C){if(document.activeElement===document.body)for(const S of C)S.removedNodes.length>0&&Et(i)};document.addEventListener("focusin",g),document.addEventListener("focusout",y);const b=new MutationObserver(w);return i&&b.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",y),b.disconnect()}}},[r,i,h.paused]),l.useEffect(()=>{if(i){Cs.add(h);const g=document.activeElement;if(!i.contains(g)){const w=new CustomEvent(so,bs);i.addEventListener(so,d),i.dispatchEvent(w),w.defaultPrevented||(yp(Np(ws(i)),{select:!0}),document.activeElement===g&&Et(i))}return()=>{i.removeEventListener(so,d),setTimeout(()=>{const w=new CustomEvent(io,bs);i.addEventListener(io,f),i.dispatchEvent(w),w.defaultPrevented||Et(g??document.body,{select:!0}),i.removeEventListener(io,f),Cs.remove(h)},0)}}},[i,d,f,h]);const v=l.useCallback(g=>{if(!n&&!r||h.paused)return;const y=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,w=document.activeElement;if(y&&w){const b=g.currentTarget,[C,M]=bp(b);C&&M?!g.shiftKey&&w===M?(g.preventDefault(),n&&Et(C,{select:!0})):g.shiftKey&&w===C&&(g.preventDefault(),n&&Et(M,{select:!0})):w===b&&g.preventDefault()}},[n,r,h.paused]);return u.jsx(F.div,{tabIndex:-1,...s,ref:p,onKeyDown:v})});Cn.displayName=vp;function yp(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Et(r,{select:t}),document.activeElement!==n)return}function bp(e){const t=ws(e),n=xs(t,e),r=xs(t.reverse(),e);return[n,r]}function ws(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function xs(e,t){for(const n of e)if(!wp(n,{upTo:t}))return n}function wp(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 xp(e){return e instanceof HTMLInputElement&&"select"in e}function Et(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&xp(e)&&t&&e.select()}}var Cs=Cp();function Cp(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Ns(e,t),e.unshift(t)},remove(t){var n;e=Ns(e,t),(n=e[0])==null||n.resume()}}}function Ns(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Np(e){return e.filter(t=>t.tagName!=="A")}var Mp="Portal",Nn=l.forwardRef((e,t)=>{var i;const{container:n,...r}=e,[o,a]=l.useState(!1);Ee(()=>a(!0),[]);const s=n||o&&((i=globalThis==null?void 0:globalThis.document)==null?void 0:i.body);return s?Zn.createPortal(u.jsx(F.div,{...r,ref:t}),s):null});Nn.displayName=Mp;function Sp(e,t){return l.useReducer((n,r)=>t[n][r]??n,e)}var De=e=>{const{present:t,children:n}=e,r=Ep(t),o=typeof n=="function"?n({present:r.isPresent}):l.Children.only(n),a=ne(r.ref,Pp(o));return typeof n=="function"||r.isPresent?l.cloneElement(o,{ref:a}):null};De.displayName="Presence";function Ep(e){const[t,n]=l.useState(),r=l.useRef({}),o=l.useRef(e),a=l.useRef("none"),s=e?"mounted":"unmounted",[i,c]=Sp(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return l.useEffect(()=>{const d=or(r.current);a.current=i==="mounted"?d:"none"},[i]),Ee(()=>{const d=r.current,f=o.current;if(f!==e){const p=a.current,h=or(d);e?c("MOUNT"):h==="none"||(d==null?void 0:d.display)==="none"?c("UNMOUNT"):c(f&&p!==h?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),Ee(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,m=h=>{const g=or(r.current).includes(h.animationName);if(h.target===t&&g&&(c("ANIMATION_END"),!o.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},p=h=>{h.target===t&&(a.current=or(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",m),t.addEventListener("animationend",m),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",m),t.removeEventListener("animationend",m)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:l.useCallback(d=>{d&&(r.current=getComputedStyle(d)),n(d)},[])}}function or(e){return(e==null?void 0:e.animationName)||"none"}function Pp(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var co=0;function ar(){l.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Ms()),document.body.insertAdjacentElement("beforeend",e[1]??Ms()),co++,()=>{co===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),co--}},[])}function Ms(){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 ct=function(){return ct=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},ct.apply(this,arguments)};function Ss(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function kp(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,a;r<o;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var sr="right-scroll-bar-position",ir="width-before-scroll-bar",Tp="with-scroll-bars-hidden",Dp="--removed-body-scroll-bar-size";function lo(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Op(e,t){var n=x.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var Ap=typeof window<"u"?l.useLayoutEffect:l.useEffect,Es=new WeakMap;function _p(e,t){var n=Op(null,function(r){return e.forEach(function(o){return lo(o,r)})});return Ap(function(){var r=Es.get(n);if(r){var o=new Set(r),a=new Set(e),s=n.current;o.forEach(function(i){a.has(i)||lo(i,null)}),a.forEach(function(i){o.has(i)||lo(i,s)})}Es.set(n,e)},[e]),n}function Rp(e){return e}function Ip(e,t){t===void 0&&(t=Rp);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var s=t(a,r);return n.push(s),function(){n=n.filter(function(i){return i!==s})}},assignSyncMedium:function(a){for(r=!0;n.length;){var s=n;n=[],s.forEach(a)}n={push:function(i){return a(i)},filter:function(){return n}}},assignMedium:function(a){r=!0;var s=[];if(n.length){var i=n;n=[],i.forEach(a),s=n}var c=function(){var f=s;s=[],f.forEach(a)},d=function(){return Promise.resolve().then(c)};d(),n={push:function(f){s.push(f),d()},filter:function(f){return s=s.filter(f),n}}}};return o}function jp(e){e===void 0&&(e={});var t=Ip(null);return t.options=ct({async:!0,ssr:!1},e),t}var Ps=function(e){var t=e.sideCar,n=Ss(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return l.createElement(r,ct({},n))};Ps.isSideCarExport=!0;function Fp(e,t){return e.useMedium(t),Ps}var ks=jp(),uo=function(){},cr=l.forwardRef(function(e,t){var n=l.useRef(null),r=l.useState({onScrollCapture:uo,onWheelCapture:uo,onTouchMoveCapture:uo}),o=r[0],a=r[1],s=e.forwardProps,i=e.children,c=e.className,d=e.removeScrollBar,f=e.enabled,m=e.shards,p=e.sideCar,h=e.noIsolation,v=e.inert,g=e.allowPinchZoom,y=e.as,w=y===void 0?"div":y,b=e.gapMode,C=Ss(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),M=p,S=_p([n,t]),k=ct(ct({},C),o);return l.createElement(l.Fragment,null,f&&l.createElement(M,{sideCar:ks,removeScrollBar:d,shards:m,noIsolation:h,inert:v,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:b}),s?l.cloneElement(l.Children.only(i),ct(ct({},k),{ref:S})):l.createElement(w,ct({},k,{className:c,ref:S}),i))});cr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},cr.classNames={fullWidth:ir,zeroRight:sr};var $p=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Wp(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=$p();return t&&e.setAttribute("nonce",t),e}function Lp(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Bp(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Vp=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Wp())&&(Lp(t,n),Bp(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Yp=function(){var e=Vp();return function(t,n){l.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ts=function(){var e=Yp(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},Gp={left:0,top:0,right:0,gap:0},fo=function(e){return parseInt(e||"",10)||0},zp=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[fo(n),fo(r),fo(o)]},Hp=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Gp;var t=zp(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Up=Ts(),qt="data-scroll-locked",Kp=function(e,t,n,r){var o=e.left,a=e.top,s=e.right,i=e.gap;return n===void 0&&(n="margin"),`
32
- .`.concat(Tp,` {
33
- overflow: hidden `).concat(r,`;
34
- padding-right: `).concat(i,"px ").concat(r,`;
31
+ Check the top-level render call using <`+x+">."),F}var C=S,N=Symbol.for("react.transitional.element"),E=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),M=Symbol.for("react.strict_mode"),I=Symbol.for("react.profiler"),j=Symbol.for("react.consumer"),B=Symbol.for("react.context"),z=Symbol.for("react.forward_ref"),O=Symbol.for("react.suspense"),U=Symbol.for("react.suspense_list"),W=Symbol.for("react.memo"),oe=Symbol.for("react.lazy"),$=Symbol.for("react.offscreen"),G=Symbol.iterator,V=Symbol.for("react.client.reference"),T=C.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,H=Object.prototype.hasOwnProperty,Z=Object.assign,X=Symbol.for("react.client.reference"),K=Array.isArray,q=0,ce,fe,k,ae,se,te,re;o.__reactDisabledLog=!0;var ie,ye,Se=!1,Ae=new(typeof WeakMap=="function"?WeakMap:Map),ot=Symbol.for("react.client.reference"),Fe,rt={},Ye={},at={};Kt.Fragment=A,Kt.jsx=function(x,F,D,ne,xe){return b(x,F,D,!1,ne,xe)},Kt.jsxs=function(x,F,D,ne,xe){return b(x,F,D,!0,ne,xe)}}()),Kt}var Sa;function Jf(){return Sa||(Sa=1,process.env.NODE_ENV==="production"?Pn.exports=Xf():Pn.exports=qf()),Pn.exports}var c=Jf();function Pa(e){var t,n,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;t<r;t++)e[t]&&(n=Pa(e[t]))&&(o&&(o+=" "),o+=n)}else for(n in e)e[n]&&(o&&(o+=" "),o+=n);return o}function Ta(){for(var e,t,n=0,o="",r=arguments.length;n<r;n++)(e=arguments[n])&&(t=Pa(e))&&(o&&(o+=" "),o+=t);return o}const So="-",Zf=e=>{const t=ep(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:s=>{const i=s.split(So);return i[0]===""&&i.length!==1&&i.shift(),Ma(i,t)||Qf(s)},getConflictingClassGroupIds:(s,i)=>{const u=n[s]||[];return i&&o[s]?[...u,...o[s]]:u}}},Ma=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],o=t.nextPart.get(n),r=o?Ma(e.slice(1),o):void 0;if(r)return r;if(t.validators.length===0)return;const a=e.join(So);return(s=t.validators.find(({validator:i})=>i(a)))==null?void 0:s.classGroupId},Ra=/^\[(.+)\]$/,Qf=e=>{if(Ra.test(e)){const t=Ra.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},ep=e=>{const{theme:t,prefix:n}=e,o={nextPart:new Map,validators:[]};return np(Object.entries(e.classGroups),n).forEach(([a,s])=>{Po(s,o,a,t)}),o},Po=(e,t,n,o)=>{e.forEach(r=>{if(typeof r=="string"){const a=r===""?t:Aa(t,r);a.classGroupId=n;return}if(typeof r=="function"){if(tp(r)){Po(r(o),t,n,o);return}t.validators.push({validator:r,classGroupId:n});return}Object.entries(r).forEach(([a,s])=>{Po(s,Aa(t,a),n,o)})})},Aa=(e,t)=>{let n=e;return t.split(So).forEach(o=>{n.nextPart.has(o)||n.nextPart.set(o,{nextPart:new Map,validators:[]}),n=n.nextPart.get(o)}),n},tp=e=>e.isThemeGetter,np=(e,t)=>t?e.map(([n,o])=>{const r=o.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([s,i])=>[t+s,i])):a);return[n,r]}):e,op=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,o=new Map;const r=(a,s)=>{n.set(a,s),t++,t>e&&(t=0,o=n,n=new Map)};return{get(a){let s=n.get(a);if(s!==void 0)return s;if((s=o.get(a))!==void 0)return r(a,s),s},set(a,s){n.has(a)?n.set(a,s):r(a,s)}}},_a="!",rp=e=>{const{separator:t,experimentalParseClassName:n}=e,o=t.length===1,r=t[0],a=t.length,s=i=>{const u=[];let d=0,f=0,m;for(let v=0;v<i.length;v++){let y=i[v];if(d===0){if(y===r&&(o||i.slice(v,v+a)===t)){u.push(i.slice(f,v)),f=v+a;continue}if(y==="/"){m=v;continue}}y==="["?d++:y==="]"&&d--}const h=u.length===0?i:i.substring(f),p=h.startsWith(_a),b=p?h.substring(1):h,g=m&&m>f?m-f:void 0;return{modifiers:u,hasImportantModifier:p,baseClassName:b,maybePostfixModifierPosition:g}};return n?i=>n({className:i,parseClassName:s}):s},ap=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(o=>{o[0]==="["?(t.push(...n.sort(),o),n=[]):n.push(o)}),t.push(...n.sort()),t},sp=e=>({cache:op(e.cacheSize),parseClassName:rp(e),...Zf(e)}),ip=/\s+/,lp=(e,t)=>{const{parseClassName:n,getClassGroupId:o,getConflictingClassGroupIds:r}=t,a=[],s=e.trim().split(ip);let i="";for(let u=s.length-1;u>=0;u-=1){const d=s[u],{modifiers:f,hasImportantModifier:m,baseClassName:h,maybePostfixModifierPosition:p}=n(d);let b=!!p,g=o(b?h.substring(0,p):h);if(!g){if(!b){i=d+(i.length>0?" "+i:i);continue}if(g=o(h),!g){i=d+(i.length>0?" "+i:i);continue}b=!1}const v=ap(f).join(":"),y=m?v+_a:v,w=y+g;if(a.includes(w))continue;a.push(w);const C=r(g,b);for(let N=0;N<C.length;++N){const E=C[N];a.push(y+E)}i=d+(i.length>0?" "+i:i)}return i};function cp(){let e=0,t,n,o="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Ia(t))&&(o&&(o+=" "),o+=n);return o}const Ia=e=>{if(typeof e=="string")return e;let t,n="";for(let o=0;o<e.length;o++)e[o]&&(t=Ia(e[o]))&&(n&&(n+=" "),n+=t);return n};function up(e,...t){let n,o,r,a=s;function s(u){const d=t.reduce((f,m)=>m(f),e());return n=sp(d),o=n.cache.get,r=n.cache.set,a=i,i(u)}function i(u){const d=o(u);if(d)return d;const f=lp(u,n);return r(u,f),f}return function(){return a(cp.apply(null,arguments))}}const ue=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},ka=/^\[(?:([a-z-]+):)?(.+)\]$/i,dp=/^\d+\/\d+$/,fp=new Set(["px","full","screen"]),pp=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,mp=/\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$/,gp=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,hp=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,vp=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Qe=e=>Pt(e)||fp.has(e)||dp.test(e),st=e=>Tt(e,"length",Sp),Pt=e=>!!e&&!Number.isNaN(Number(e)),To=e=>Tt(e,"number",Pt),Yt=e=>!!e&&Number.isInteger(Number(e)),bp=e=>e.endsWith("%")&&Pt(e.slice(0,-1)),ee=e=>ka.test(e),it=e=>pp.test(e),yp=new Set(["length","size","percentage"]),wp=e=>Tt(e,yp,ja),xp=e=>Tt(e,"position",ja),Cp=new Set(["image","url"]),Np=e=>Tt(e,Cp,Tp),Ep=e=>Tt(e,"",Pp),Xt=()=>!0,Tt=(e,t,n)=>{const o=ka.exec(e);return o?o[1]?typeof t=="string"?o[1]===t:t.has(o[1]):n(o[2]):!1},Sp=e=>mp.test(e)&&!gp.test(e),ja=()=>!1,Pp=e=>hp.test(e),Tp=e=>vp.test(e),Mp=up(()=>{const e=ue("colors"),t=ue("spacing"),n=ue("blur"),o=ue("brightness"),r=ue("borderColor"),a=ue("borderRadius"),s=ue("borderSpacing"),i=ue("borderWidth"),u=ue("contrast"),d=ue("grayscale"),f=ue("hueRotate"),m=ue("invert"),h=ue("gap"),p=ue("gradientColorStops"),b=ue("gradientColorStopPositions"),g=ue("inset"),v=ue("margin"),y=ue("opacity"),w=ue("padding"),C=ue("saturate"),N=ue("scale"),E=ue("sepia"),A=ue("skew"),M=ue("space"),I=ue("translate"),j=()=>["auto","contain","none"],B=()=>["auto","hidden","clip","visible","scroll"],z=()=>["auto",ee,t],O=()=>[ee,t],U=()=>["",Qe,st],W=()=>["auto",Pt,ee],oe=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],$=()=>["solid","dashed","dotted","double","none"],G=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],V=()=>["start","end","center","between","around","evenly","stretch"],T=()=>["","0",ee],H=()=>["auto","avoid","all","avoid-page","page","left","right","column"],Z=()=>[Pt,ee];return{cacheSize:500,separator:":",theme:{colors:[Xt],spacing:[Qe,st],blur:["none","",it,ee],brightness:Z(),borderColor:[e],borderRadius:["none","","full",it,ee],borderSpacing:O(),borderWidth:U(),contrast:Z(),grayscale:T(),hueRotate:Z(),invert:T(),gap:O(),gradientColorStops:[e],gradientColorStopPositions:[bp,st],inset:z(),margin:z(),opacity:Z(),padding:O(),saturate:Z(),scale:Z(),sepia:T(),skew:Z(),space:O(),translate:O()},classGroups:{aspect:[{aspect:["auto","square","video",ee]}],container:["container"],columns:[{columns:[it]}],"break-after":[{"break-after":H()}],"break-before":[{"break-before":H()}],"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"],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:[...oe(),ee]}],overflow:[{overflow:B()}],"overflow-x":[{"overflow-x":B()}],"overflow-y":[{"overflow-y":B()}],overscroll:[{overscroll:j()}],"overscroll-x":[{"overscroll-x":j()}],"overscroll-y":[{"overscroll-y":j()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[g]}],"inset-x":[{"inset-x":[g]}],"inset-y":[{"inset-y":[g]}],start:[{start:[g]}],end:[{end:[g]}],top:[{top:[g]}],right:[{right:[g]}],bottom:[{bottom:[g]}],left:[{left:[g]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Yt,ee]}],basis:[{basis:z()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ee]}],grow:[{grow:T()}],shrink:[{shrink:T()}],order:[{order:["first","last","none",Yt,ee]}],"grid-cols":[{"grid-cols":[Xt]}],"col-start-end":[{col:["auto",{span:["full",Yt,ee]},ee]}],"col-start":[{"col-start":W()}],"col-end":[{"col-end":W()}],"grid-rows":[{"grid-rows":[Xt]}],"row-start-end":[{row:["auto",{span:[Yt,ee]},ee]}],"row-start":[{"row-start":W()}],"row-end":[{"row-end":W()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ee]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ee]}],gap:[{gap:[h]}],"gap-x":[{"gap-x":[h]}],"gap-y":[{"gap-y":[h]}],"justify-content":[{justify:["normal",...V()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...V(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...V(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[w]}],px:[{px:[w]}],py:[{py:[w]}],ps:[{ps:[w]}],pe:[{pe:[w]}],pt:[{pt:[w]}],pr:[{pr:[w]}],pb:[{pb:[w]}],pl:[{pl:[w]}],m:[{m:[v]}],mx:[{mx:[v]}],my:[{my:[v]}],ms:[{ms:[v]}],me:[{me:[v]}],mt:[{mt:[v]}],mr:[{mr:[v]}],mb:[{mb:[v]}],ml:[{ml:[v]}],"space-x":[{"space-x":[M]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[M]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",ee,t]}],"min-w":[{"min-w":[ee,t,"min","max","fit"]}],"max-w":[{"max-w":[ee,t,"none","full","min","max","fit","prose",{screen:[it]},it]}],h:[{h:[ee,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[ee,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[ee,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[ee,t,"auto","min","max","fit"]}],"font-size":[{text:["base",it,st]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",To]}],"font-family":[{font:[Xt]}],"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:["tighter","tight","normal","wide","wider","widest",ee]}],"line-clamp":[{"line-clamp":["none",Pt,To]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Qe,ee]}],"list-image":[{"list-image":["none",ee]}],"list-style-type":[{list:["none","disc","decimal",ee]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...$(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Qe,st]}],"underline-offset":[{"underline-offset":["auto",Qe,ee]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:O()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ee]}],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",ee]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...oe(),xp]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",wp]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Np]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[...$(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:$()}],"border-color":[{border:[r]}],"border-color-x":[{"border-x":[r]}],"border-color-y":[{"border-y":[r]}],"border-color-s":[{"border-s":[r]}],"border-color-e":[{"border-e":[r]}],"border-color-t":[{"border-t":[r]}],"border-color-r":[{"border-r":[r]}],"border-color-b":[{"border-b":[r]}],"border-color-l":[{"border-l":[r]}],"divide-color":[{divide:[r]}],"outline-style":[{outline:["",...$()]}],"outline-offset":[{"outline-offset":[Qe,ee]}],"outline-w":[{outline:[Qe,st]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:U()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Qe,st]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",it,Ep]}],"shadow-color":[{shadow:[Xt]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":[...G(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":G()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[o]}],contrast:[{contrast:[u]}],"drop-shadow":[{"drop-shadow":["","none",it,ee]}],grayscale:[{grayscale:[d]}],"hue-rotate":[{"hue-rotate":[f]}],invert:[{invert:[m]}],saturate:[{saturate:[C]}],sepia:[{sepia:[E]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[u]}],"backdrop-grayscale":[{"backdrop-grayscale":[d]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[f]}],"backdrop-invert":[{"backdrop-invert":[m]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[C]}],"backdrop-sepia":[{"backdrop-sepia":[E]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",ee]}],duration:[{duration:Z()}],ease:[{ease:["linear","in","out","in-out",ee]}],delay:[{delay:Z()}],animate:[{animate:["none","spin","ping","pulse","bounce",ee]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[N]}],"scale-x":[{"scale-x":[N]}],"scale-y":[{"scale-y":[N]}],rotate:[{rotate:[Yt,ee]}],"translate-x":[{"translate-x":[I]}],"translate-y":[{"translate-y":[I]}],"skew-x":[{"skew-x":[A]}],"skew-y":[{"skew-y":[A]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",ee]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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",ee]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":O()}],"scroll-mx":[{"scroll-mx":O()}],"scroll-my":[{"scroll-my":O()}],"scroll-ms":[{"scroll-ms":O()}],"scroll-me":[{"scroll-me":O()}],"scroll-mt":[{"scroll-mt":O()}],"scroll-mr":[{"scroll-mr":O()}],"scroll-mb":[{"scroll-mb":O()}],"scroll-ml":[{"scroll-ml":O()}],"scroll-p":[{"scroll-p":O()}],"scroll-px":[{"scroll-px":O()}],"scroll-py":[{"scroll-py":O()}],"scroll-ps":[{"scroll-ps":O()}],"scroll-pe":[{"scroll-pe":O()}],"scroll-pt":[{"scroll-pt":O()}],"scroll-pr":[{"scroll-pr":O()}],"scroll-pb":[{"scroll-pb":O()}],"scroll-pl":[{"scroll-pl":O()}],"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",ee]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Qe,st,To]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"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"],"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"]}}});function R(...e){return Mp(Ta(e))}const Rp=(e,t="pt-BR",n="BRL")=>new Intl.NumberFormat(t,{style:"currency",currency:n,minimumFractionDigits:2}).format(e),Ap=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{day:"2-digit",month:"long",weekday:"long"}).format(new Date(e)),_p=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{day:"2-digit",month:"long",weekday:"long",year:"numeric"}).format(new Date(e)),Ip=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{day:"2-digit",month:"long"}).format(new Date(e)),kp=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{dateStyle:"long"}).format(typeof e=="string"?new Date(e):e),jp=(e,t="pt-BR")=>new Intl.DateTimeFormat(t,{dateStyle:"short"}).format(e),Dp=e=>e.slice(0,7),Op=(e,t="pt-BR")=>e.toLocaleDateString(t,{weekday:"short",day:"2-digit",month:"2-digit"}),Da=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Oa=Ta,Mt=(e,t)=>n=>{var o;if((t==null?void 0:t.variants)==null)return Oa(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:r,defaultVariants:a}=t,s=Object.keys(r).map(d=>{const f=n==null?void 0:n[d],m=a==null?void 0:a[d];if(f===null)return null;const h=Da(f)||Da(m);return r[d][h]}),i=n&&Object.entries(n).reduce((d,f)=>{let[m,h]=f;return h===void 0||(d[m]=h),d},{}),u=t==null||(o=t.compoundVariants)===null||o===void 0?void 0:o.reduce((d,f)=>{let{class:m,className:h,...p}=f;return Object.entries(p).every(b=>{let[g,v]=b;return Array.isArray(v)?v.includes({...a,...i}[g]):{...a,...i}[g]===v})?[...d,m,h]:d},[]);return Oa(e,s,u,n==null?void 0:n.class,n==null?void 0:n.className)},Lp=Mt("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",{variants:{sizing:{sm:"h-8 text-xs px-2",md:"h-10 text-sm px-3",lg:"h-12 text-base px-4",xl:"h-14 text-lg px-5","2xl":"h-16 text-xl px-6"}},defaultVariants:{sizing:"md"}}),Tn=l.forwardRef(({className:e,sizing:t,type:n,...o},r)=>c.jsx("input",{type:n,className:R(Lp({sizing:t,className:e})),ref:r,...o}));Tn.displayName="Input";const Fp=(e,t)=>{const n=e.replace(/\D/g,"");let o="",r=0,a=0;for(;r<t.length&&a<n.length;)t[r]==="0"?(o+=n[a],a++):o+=t[r],r++;return o},Mn=l.forwardRef(({className:e,leftIcon:t,rightIcon:n,mask:o,onChange:r,...a},s)=>{const i=u=>{const d=u.target;if(o){const f=Fp(d.value,o);d.value=f}r==null||r(u)};return c.jsxs("div",{className:"relative w-full",children:[t&&c.jsx("div",{className:"absolute left-2 top-1/2 -translate-y-1/2 text-muted-foreground",children:t}),c.jsx(Tn,{className:R(t&&"pl-8",n&&"pr-8",e),ref:s,onInput:i,...a}),n&&c.jsx("div",{className:"absolute right-2 top-1/2 -translate-y-1/2 text-muted-foreground",children:n})]})});Mn.displayName="AdaptiveInput";function $p(e,t){const n=l.createContext(t),o=a=>{const{children:s,...i}=a,u=l.useMemo(()=>i,Object.values(i));return c.jsx(n.Provider,{value:u,children:s})};o.displayName=e+"Provider";function r(a){const s=l.useContext(n);if(s)return s;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[o,r]}function ve(e,t=[]){let n=[];function o(a,s){const i=l.createContext(s),u=n.length;n=[...n,s];const d=m=>{var y;const{scope:h,children:p,...b}=m,g=((y=h==null?void 0:h[e])==null?void 0:y[u])||i,v=l.useMemo(()=>b,Object.values(b));return c.jsx(g.Provider,{value:v,children:p})};d.displayName=a+"Provider";function f(m,h){var g;const p=((g=h==null?void 0:h[e])==null?void 0:g[u])||i,b=l.useContext(p);if(b)return b;if(s!==void 0)return s;throw new Error(`\`${m}\` must be used within \`${a}\``)}return[d,f]}const r=()=>{const a=n.map(s=>l.createContext(s));return function(i){const u=(i==null?void 0:i[e])||a;return l.useMemo(()=>({[`__scope${e}`]:{...i,[e]:u}}),[i,u])}};return r.scopeName=e,[o,Vp(r,...t)]}function Vp(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(a){const s=o.reduce((i,{useScope:u,scopeName:d})=>{const m=u(a)[`__scope${d}`];return{...i,...m}},{});return l.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}function La(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function qt(...e){return t=>{let n=!1;const o=e.map(r=>{const a=La(r,t);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let r=0;r<o.length;r++){const a=o[r];typeof a=="function"?a():La(e[r],null)}}}}function J(...e){return l.useCallback(qt(...e),e)}function _(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}var he=globalThis!=null&&globalThis.document?l.useLayoutEffect:()=>{},Bp=l.useId||(()=>{}),Wp=0;function Ne(e){const[t,n]=l.useState(Bp());return he(()=>{e||n(o=>o??String(Wp++))},[e]),e||(t?`radix-${t}`:"")}function ge(e){const t=l.useRef(e);return l.useEffect(()=>{t.current=e}),l.useMemo(()=>(...n)=>{var o;return(o=t.current)==null?void 0:o.call(t,...n)},[])}function Ce({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,r]=zp({defaultProp:t,onChange:n}),a=e!==void 0,s=a?e:o,i=ge(n),u=l.useCallback(d=>{if(a){const m=typeof d=="function"?d(e):d;m!==e&&i(m)}else r(d)},[a,e,r,i]);return[s,u]}function zp({defaultProp:e,onChange:t}){const n=l.useState(e),[o]=n,r=l.useRef(o),a=ge(t);return l.useEffect(()=>{r.current!==o&&(a(o),r.current=o)},[o,r,a]),n}var We=l.forwardRef((e,t)=>{const{children:n,...o}=e,r=l.Children.toArray(n),a=r.find(Gp);if(a){const s=a.props.children,i=r.map(u=>u===a?l.Children.count(s)>1?l.Children.only(null):l.isValidElement(s)?s.props.children:null:u);return c.jsx(Mo,{...o,ref:t,children:l.isValidElement(s)?l.cloneElement(s,void 0,i):null})}return c.jsx(Mo,{...o,ref:t,children:n})});We.displayName="Slot";var Mo=l.forwardRef((e,t)=>{const{children:n,...o}=e;if(l.isValidElement(n)){const r=Up(n);return l.cloneElement(n,{...Hp(o,n.props),ref:t?qt(t,r):r})}return l.Children.count(n)>1?l.Children.only(null):null});Mo.displayName="SlotClone";var Ro=({children:e})=>c.jsx(c.Fragment,{children:e});function Gp(e){return l.isValidElement(e)&&e.type===Ro}function Hp(e,t){const n={...t};for(const o in t){const r=e[o],a=t[o];/^on[A-Z]/.test(o)?r&&a?n[o]=(...i)=>{a(...i),r(...i)}:r&&(n[o]=r):o==="style"?n[o]={...r,...a}:o==="className"&&(n[o]=[r,a].filter(Boolean).join(" "))}return{...e,...n}}function Up(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Kp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],L=Kp.reduce((e,t)=>{const n=l.forwardRef((o,r)=>{const{asChild:a,...s}=o,i=a?We:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),c.jsx(i,{...s,ref:r})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Rn(e,t){e&&Sn.flushSync(()=>e.dispatchEvent(t))}function Yp(e,t=globalThis==null?void 0:globalThis.document){const n=ge(e);l.useEffect(()=>{const o=r=>{r.key==="Escape"&&n(r)};return t.addEventListener("keydown",o,{capture:!0}),()=>t.removeEventListener("keydown",o,{capture:!0})},[n,t])}var Xp="DismissableLayer",Ao="dismissableLayer.update",qp="dismissableLayer.pointerDownOutside",Jp="dismissableLayer.focusOutside",Fa,$a=l.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),wt=l.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:a,onInteractOutside:s,onDismiss:i,...u}=e,d=l.useContext($a),[f,m]=l.useState(null),h=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,p]=l.useState({}),b=J(t,M=>m(M)),g=Array.from(d.layers),[v]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),y=g.indexOf(v),w=f?g.indexOf(f):-1,C=d.layersWithOutsidePointerEventsDisabled.size>0,N=w>=y,E=em(M=>{const I=M.target,j=[...d.branches].some(B=>B.contains(I));!N||j||(r==null||r(M),s==null||s(M),M.defaultPrevented||i==null||i())},h),A=tm(M=>{const I=M.target;[...d.branches].some(B=>B.contains(I))||(a==null||a(M),s==null||s(M),M.defaultPrevented||i==null||i())},h);return Yp(M=>{w===d.layers.size-1&&(o==null||o(M),!M.defaultPrevented&&i&&(M.preventDefault(),i()))},h),l.useEffect(()=>{if(f)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Fa=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),Va(),()=>{n&&d.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=Fa)}},[f,h,n,d]),l.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),Va())},[f,d]),l.useEffect(()=>{const M=()=>p({});return document.addEventListener(Ao,M),()=>document.removeEventListener(Ao,M)},[]),c.jsx(L.div,{...u,ref:b,style:{pointerEvents:C?N?"auto":"none":void 0,...e.style},onFocusCapture:_(e.onFocusCapture,A.onFocusCapture),onBlurCapture:_(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:_(e.onPointerDownCapture,E.onPointerDownCapture)})});wt.displayName=Xp;var Zp="DismissableLayerBranch",Qp=l.forwardRef((e,t)=>{const n=l.useContext($a),o=l.useRef(null),r=J(t,o);return l.useEffect(()=>{const a=o.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),c.jsx(L.div,{...e,ref:r})});Qp.displayName=Zp;function em(e,t=globalThis==null?void 0:globalThis.document){const n=ge(e),o=l.useRef(!1),r=l.useRef(()=>{});return l.useEffect(()=>{const a=i=>{if(i.target&&!o.current){let u=function(){Ba(qp,n,d,{discrete:!0})};const d={originalEvent:i};i.pointerType==="touch"?(t.removeEventListener("click",r.current),r.current=u,t.addEventListener("click",r.current,{once:!0})):u()}else t.removeEventListener("click",r.current);o.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",a),t.removeEventListener("click",r.current)}},[t,n]),{onPointerDownCapture:()=>o.current=!0}}function tm(e,t=globalThis==null?void 0:globalThis.document){const n=ge(e),o=l.useRef(!1);return l.useEffect(()=>{const r=a=>{a.target&&!o.current&&Ba(Jp,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",r),()=>t.removeEventListener("focusin",r)},[t,n]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}function Va(){const e=new CustomEvent(Ao);document.dispatchEvent(e)}function Ba(e,t,n,{discrete:o}){const r=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),o?Rn(r,a):r.dispatchEvent(a)}var _o="focusScope.autoFocusOnMount",Io="focusScope.autoFocusOnUnmount",Wa={bubbles:!1,cancelable:!0},nm="FocusScope",Jt=l.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:a,...s}=e,[i,u]=l.useState(null),d=ge(r),f=ge(a),m=l.useRef(null),h=J(t,g=>u(g)),p=l.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;l.useEffect(()=>{if(o){let g=function(C){if(p.paused||!i)return;const N=C.target;i.contains(N)?m.current=N:lt(m.current,{select:!0})},v=function(C){if(p.paused||!i)return;const N=C.relatedTarget;N!==null&&(i.contains(N)||lt(m.current,{select:!0}))},y=function(C){if(document.activeElement===document.body)for(const E of C)E.removedNodes.length>0&&lt(i)};document.addEventListener("focusin",g),document.addEventListener("focusout",v);const w=new MutationObserver(y);return i&&w.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",v),w.disconnect()}}},[o,i,p.paused]),l.useEffect(()=>{if(i){Ha.add(p);const g=document.activeElement;if(!i.contains(g)){const y=new CustomEvent(_o,Wa);i.addEventListener(_o,d),i.dispatchEvent(y),y.defaultPrevented||(om(lm(za(i)),{select:!0}),document.activeElement===g&&lt(i))}return()=>{i.removeEventListener(_o,d),setTimeout(()=>{const y=new CustomEvent(Io,Wa);i.addEventListener(Io,f),i.dispatchEvent(y),y.defaultPrevented||lt(g??document.body,{select:!0}),i.removeEventListener(Io,f),Ha.remove(p)},0)}}},[i,d,f,p]);const b=l.useCallback(g=>{if(!n&&!o||p.paused)return;const v=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,y=document.activeElement;if(v&&y){const w=g.currentTarget,[C,N]=rm(w);C&&N?!g.shiftKey&&y===N?(g.preventDefault(),n&&lt(C,{select:!0})):g.shiftKey&&y===C&&(g.preventDefault(),n&&lt(N,{select:!0})):y===w&&g.preventDefault()}},[n,o,p.paused]);return c.jsx(L.div,{tabIndex:-1,...s,ref:h,onKeyDown:b})});Jt.displayName=nm;function om(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(lt(o,{select:t}),document.activeElement!==n)return}function rm(e){const t=za(e),n=Ga(t,e),o=Ga(t.reverse(),e);return[n,o]}function za(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ga(e,t){for(const n of e)if(!am(n,{upTo:t}))return n}function am(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 sm(e){return e instanceof HTMLInputElement&&"select"in e}function lt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&sm(e)&&t&&e.select()}}var Ha=im();function im(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Ua(e,t),e.unshift(t)},remove(t){var n;e=Ua(e,t),(n=e[0])==null||n.resume()}}}function Ua(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function lm(e){return e.filter(t=>t.tagName!=="A")}var cm="Portal",Zt=l.forwardRef((e,t)=>{var i;const{container:n,...o}=e,[r,a]=l.useState(!1);he(()=>a(!0),[]);const s=n||r&&((i=globalThis==null?void 0:globalThis.document)==null?void 0:i.body);return s?En.createPortal(c.jsx(L.div,{...o,ref:t}),s):null});Zt.displayName=cm;function um(e,t){return l.useReducer((n,o)=>t[n][o]??n,e)}var be=e=>{const{present:t,children:n}=e,o=dm(t),r=typeof n=="function"?n({present:o.isPresent}):l.Children.only(n),a=J(o.ref,fm(r));return typeof n=="function"||o.isPresent?l.cloneElement(r,{ref:a}):null};be.displayName="Presence";function dm(e){const[t,n]=l.useState(),o=l.useRef({}),r=l.useRef(e),a=l.useRef("none"),s=e?"mounted":"unmounted",[i,u]=um(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return l.useEffect(()=>{const d=An(o.current);a.current=i==="mounted"?d:"none"},[i]),he(()=>{const d=o.current,f=r.current;if(f!==e){const h=a.current,p=An(d);e?u("MOUNT"):p==="none"||(d==null?void 0:d.display)==="none"?u("UNMOUNT"):u(f&&h!==p?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,u]),he(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,m=p=>{const g=An(o.current).includes(p.animationName);if(p.target===t&&g&&(u("ANIMATION_END"),!r.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},h=p=>{p.target===t&&(a.current=An(o.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",m),t.addEventListener("animationend",m),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",m),t.removeEventListener("animationend",m)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:l.useCallback(d=>{d&&(o.current=getComputedStyle(d)),n(d)},[])}}function An(e){return(e==null?void 0:e.animationName)||"none"}function fm(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var ko=0;function _n(){l.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Ka()),document.body.insertAdjacentElement("beforeend",e[1]??Ka()),ko++,()=>{ko===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),ko--}},[])}function Ka(){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 ze=function(){return ze=Object.assign||function(t){for(var n,o=1,r=arguments.length;o<r;o++){n=arguments[o];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},ze.apply(this,arguments)};function Ya(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,o=Object.getOwnPropertySymbols(e);r<o.length;r++)t.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]]);return n}function pm(e,t,n){if(n||arguments.length===2)for(var o=0,r=t.length,a;o<r;o++)(a||!(o in t))&&(a||(a=Array.prototype.slice.call(t,0,o)),a[o]=t[o]);return e.concat(a||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var In="right-scroll-bar-position",kn="width-before-scroll-bar",mm="with-scroll-bars-hidden",gm="--removed-body-scroll-bar-size";function jo(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function hm(e,t){var n=S.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(o){var r=n.value;r!==o&&(n.value=o,n.callback(o,r))}}}})[0];return n.callback=t,n.facade}var vm=typeof window<"u"?l.useLayoutEffect:l.useEffect,Xa=new WeakMap;function bm(e,t){var n=hm(null,function(o){return e.forEach(function(r){return jo(r,o)})});return vm(function(){var o=Xa.get(n);if(o){var r=new Set(o),a=new Set(e),s=n.current;r.forEach(function(i){a.has(i)||jo(i,null)}),a.forEach(function(i){r.has(i)||jo(i,s)})}Xa.set(n,e)},[e]),n}function ym(e){return e}function wm(e,t){t===void 0&&(t=ym);var n=[],o=!1,r={read:function(){if(o)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var s=t(a,o);return n.push(s),function(){n=n.filter(function(i){return i!==s})}},assignSyncMedium:function(a){for(o=!0;n.length;){var s=n;n=[],s.forEach(a)}n={push:function(i){return a(i)},filter:function(){return n}}},assignMedium:function(a){o=!0;var s=[];if(n.length){var i=n;n=[],i.forEach(a),s=n}var u=function(){var f=s;s=[],f.forEach(a)},d=function(){return Promise.resolve().then(u)};d(),n={push:function(f){s.push(f),d()},filter:function(f){return s=s.filter(f),n}}}};return r}function xm(e){e===void 0&&(e={});var t=wm(null);return t.options=ze({async:!0,ssr:!1},e),t}var qa=function(e){var t=e.sideCar,n=Ya(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var o=t.read();if(!o)throw new Error("Sidecar medium not found");return l.createElement(o,ze({},n))};qa.isSideCarExport=!0;function Cm(e,t){return e.useMedium(t),qa}var Ja=xm(),Do=function(){},jn=l.forwardRef(function(e,t){var n=l.useRef(null),o=l.useState({onScrollCapture:Do,onWheelCapture:Do,onTouchMoveCapture:Do}),r=o[0],a=o[1],s=e.forwardProps,i=e.children,u=e.className,d=e.removeScrollBar,f=e.enabled,m=e.shards,h=e.sideCar,p=e.noIsolation,b=e.inert,g=e.allowPinchZoom,v=e.as,y=v===void 0?"div":v,w=e.gapMode,C=Ya(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),N=h,E=bm([n,t]),A=ze(ze({},C),r);return l.createElement(l.Fragment,null,f&&l.createElement(N,{sideCar:Ja,removeScrollBar:d,shards:m,noIsolation:p,inert:b,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:w}),s?l.cloneElement(l.Children.only(i),ze(ze({},A),{ref:E})):l.createElement(y,ze({},A,{className:u,ref:E}),i))});jn.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},jn.classNames={fullWidth:kn,zeroRight:In};var Nm=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Em(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Nm();return t&&e.setAttribute("nonce",t),e}function Sm(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Pm(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Tm=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Em())&&(Sm(t,n),Pm(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Mm=function(){var e=Tm();return function(t,n){l.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Za=function(){var e=Mm(),t=function(n){var o=n.styles,r=n.dynamic;return e(o,r),null};return t},Rm={left:0,top:0,right:0,gap:0},Oo=function(e){return parseInt(e||"",10)||0},Am=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],o=t[e==="padding"?"paddingTop":"marginTop"],r=t[e==="padding"?"paddingRight":"marginRight"];return[Oo(n),Oo(o),Oo(r)]},_m=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Rm;var t=Am(e),n=document.documentElement.clientWidth,o=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,o-n+t[2]-t[0])}},Im=Za(),Rt="data-scroll-locked",km=function(e,t,n,o){var r=e.left,a=e.top,s=e.right,i=e.gap;return n===void 0&&(n="margin"),`
32
+ .`.concat(mm,` {
33
+ overflow: hidden `).concat(o,`;
34
+ padding-right: `).concat(i,"px ").concat(o,`;
35
35
  }
36
- body[`).concat(qt,`] {
37
- overflow: hidden `).concat(r,`;
36
+ body[`).concat(Rt,`] {
37
+ overflow: hidden `).concat(o,`;
38
38
  overscroll-behavior: contain;
39
- `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
40
- padding-left: `.concat(o,`px;
39
+ `).concat([t&&"position: relative ".concat(o,";"),n==="margin"&&`
40
+ padding-left: `.concat(r,`px;
41
41
  padding-top: `).concat(a,`px;
42
42
  padding-right: `).concat(s,`px;
43
43
  margin-left:0;
44
44
  margin-top:0;
45
- margin-right: `).concat(i,"px ").concat(r,`;
46
- `),n==="padding"&&"padding-right: ".concat(i,"px ").concat(r,";")].filter(Boolean).join(""),`
45
+ margin-right: `).concat(i,"px ").concat(o,`;
46
+ `),n==="padding"&&"padding-right: ".concat(i,"px ").concat(o,";")].filter(Boolean).join(""),`
47
47
  }
48
48
 
49
- .`).concat(sr,` {
50
- right: `).concat(i,"px ").concat(r,`;
49
+ .`).concat(In,` {
50
+ right: `).concat(i,"px ").concat(o,`;
51
51
  }
52
52
 
53
- .`).concat(ir,` {
54
- margin-right: `).concat(i,"px ").concat(r,`;
53
+ .`).concat(kn,` {
54
+ margin-right: `).concat(i,"px ").concat(o,`;
55
55
  }
56
56
 
57
- .`).concat(sr," .").concat(sr,` {
58
- right: 0 `).concat(r,`;
57
+ .`).concat(In," .").concat(In,` {
58
+ right: 0 `).concat(o,`;
59
59
  }
60
60
 
61
- .`).concat(ir," .").concat(ir,` {
62
- margin-right: 0 `).concat(r,`;
61
+ .`).concat(kn," .").concat(kn,` {
62
+ margin-right: 0 `).concat(o,`;
63
63
  }
64
64
 
65
- body[`).concat(qt,`] {
66
- `).concat(Dp,": ").concat(i,`px;
65
+ body[`).concat(Rt,`] {
66
+ `).concat(gm,": ").concat(i,`px;
67
67
  }
68
- `)},Ds=function(){var e=parseInt(document.body.getAttribute(qt)||"0",10);return isFinite(e)?e:0},qp=function(){l.useEffect(function(){return document.body.setAttribute(qt,(Ds()+1).toString()),function(){var e=Ds()-1;e<=0?document.body.removeAttribute(qt):document.body.setAttribute(qt,e.toString())}},[])},Xp=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;qp();var a=l.useMemo(function(){return Hp(o)},[o]);return l.createElement(Up,{styles:Kp(a,!t,o,n?"":"!important")})},mo=!1;if(typeof window<"u")try{var lr=Object.defineProperty({},"passive",{get:function(){return mo=!0,!0}});window.addEventListener("test",lr,lr),window.removeEventListener("test",lr,lr)}catch{mo=!1}var Xt=mo?{passive:!1}:!1,Qp=function(e){return e.tagName==="TEXTAREA"},Os=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Qp(e)&&n[t]==="visible")},Zp=function(e){return Os(e,"overflowY")},Jp=function(e){return Os(e,"overflowX")},As=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=_s(e,r);if(o){var a=Rs(e,r),s=a[1],i=a[2];if(s>i)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},eg=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},tg=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},_s=function(e,t){return e==="v"?Zp(t):Jp(t)},Rs=function(e,t){return e==="v"?eg(t):tg(t)},ng=function(e,t){return e==="h"&&t==="rtl"?-1:1},rg=function(e,t,n,r,o){var a=ng(e,window.getComputedStyle(t).direction),s=a*r,i=n.target,c=t.contains(i),d=!1,f=s>0,m=0,p=0;do{var h=Rs(e,i),v=h[0],g=h[1],y=h[2],w=g-y-a*v;(v||w)&&_s(e,i)&&(m+=w,p+=v),i instanceof ShadowRoot?i=i.host:i=i.parentNode}while(!c&&i!==document.body||c&&(t.contains(i)||t===i));return(f&&(Math.abs(m)<1||!o)||!f&&(Math.abs(p)<1||!o))&&(d=!0),d},ur=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Is=function(e){return[e.deltaX,e.deltaY]},js=function(e){return e&&"current"in e?e.current:e},og=function(e,t){return e[0]===t[0]&&e[1]===t[1]},ag=function(e){return`
68
+ `)},Qa=function(){var e=parseInt(document.body.getAttribute(Rt)||"0",10);return isFinite(e)?e:0},jm=function(){l.useEffect(function(){return document.body.setAttribute(Rt,(Qa()+1).toString()),function(){var e=Qa()-1;e<=0?document.body.removeAttribute(Rt):document.body.setAttribute(Rt,e.toString())}},[])},Dm=function(e){var t=e.noRelative,n=e.noImportant,o=e.gapMode,r=o===void 0?"margin":o;jm();var a=l.useMemo(function(){return _m(r)},[r]);return l.createElement(Im,{styles:km(a,!t,r,n?"":"!important")})},Lo=!1;if(typeof window<"u")try{var Dn=Object.defineProperty({},"passive",{get:function(){return Lo=!0,!0}});window.addEventListener("test",Dn,Dn),window.removeEventListener("test",Dn,Dn)}catch{Lo=!1}var At=Lo?{passive:!1}:!1,Om=function(e){return e.tagName==="TEXTAREA"},es=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Om(e)&&n[t]==="visible")},Lm=function(e){return es(e,"overflowY")},Fm=function(e){return es(e,"overflowX")},ts=function(e,t){var n=t.ownerDocument,o=t;do{typeof ShadowRoot<"u"&&o instanceof ShadowRoot&&(o=o.host);var r=ns(e,o);if(r){var a=os(e,o),s=a[1],i=a[2];if(s>i)return!0}o=o.parentNode}while(o&&o!==n.body);return!1},$m=function(e){var t=e.scrollTop,n=e.scrollHeight,o=e.clientHeight;return[t,n,o]},Vm=function(e){var t=e.scrollLeft,n=e.scrollWidth,o=e.clientWidth;return[t,n,o]},ns=function(e,t){return e==="v"?Lm(t):Fm(t)},os=function(e,t){return e==="v"?$m(t):Vm(t)},Bm=function(e,t){return e==="h"&&t==="rtl"?-1:1},Wm=function(e,t,n,o,r){var a=Bm(e,window.getComputedStyle(t).direction),s=a*o,i=n.target,u=t.contains(i),d=!1,f=s>0,m=0,h=0;do{var p=os(e,i),b=p[0],g=p[1],v=p[2],y=g-v-a*b;(b||y)&&ns(e,i)&&(m+=y,h+=b),i instanceof ShadowRoot?i=i.host:i=i.parentNode}while(!u&&i!==document.body||u&&(t.contains(i)||t===i));return(f&&(Math.abs(m)<1||!r)||!f&&(Math.abs(h)<1||!r))&&(d=!0),d},On=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},rs=function(e){return[e.deltaX,e.deltaY]},as=function(e){return e&&"current"in e?e.current:e},zm=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Gm=function(e){return`
69
69
  .block-interactivity-`.concat(e,` {pointer-events: none;}
70
70
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
71
- `)},sg=0,Qt=[];function ig(e){var t=l.useRef([]),n=l.useRef([0,0]),r=l.useRef(),o=l.useState(sg++)[0],a=l.useState(Ts)[0],s=l.useRef(e);l.useEffect(function(){s.current=e},[e]),l.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var g=kp([e.lockRef.current],(e.shards||[]).map(js),!0).filter(Boolean);return g.forEach(function(y){return y.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),g.forEach(function(y){return y.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var i=l.useCallback(function(g,y){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!s.current.allowPinchZoom;var w=ur(g),b=n.current,C="deltaX"in g?g.deltaX:b[0]-w[0],M="deltaY"in g?g.deltaY:b[1]-w[1],S,k=g.target,P=Math.abs(C)>Math.abs(M)?"h":"v";if("touches"in g&&P==="h"&&k.type==="range")return!1;var D=As(P,k);if(!D)return!0;if(D?S=P:(S=P==="v"?"h":"v",D=As(P,k)),!D)return!1;if(!r.current&&"changedTouches"in g&&(C||M)&&(r.current=S),!S)return!0;var R=r.current||S;return rg(R,y,g,R==="h"?C:M,!0)},[]),c=l.useCallback(function(g){var y=g;if(!(!Qt.length||Qt[Qt.length-1]!==a)){var w="deltaY"in y?Is(y):ur(y),b=t.current.filter(function(S){return S.name===y.type&&(S.target===y.target||y.target===S.shadowParent)&&og(S.delta,w)})[0];if(b&&b.should){y.cancelable&&y.preventDefault();return}if(!b){var C=(s.current.shards||[]).map(js).filter(Boolean).filter(function(S){return S.contains(y.target)}),M=C.length>0?i(y,C[0]):!s.current.noIsolation;M&&y.cancelable&&y.preventDefault()}}},[]),d=l.useCallback(function(g,y,w,b){var C={name:g,delta:y,target:w,should:b,shadowParent:cg(w)};t.current.push(C),setTimeout(function(){t.current=t.current.filter(function(M){return M!==C})},1)},[]),f=l.useCallback(function(g){n.current=ur(g),r.current=void 0},[]),m=l.useCallback(function(g){d(g.type,Is(g),g.target,i(g,e.lockRef.current))},[]),p=l.useCallback(function(g){d(g.type,ur(g),g.target,i(g,e.lockRef.current))},[]);l.useEffect(function(){return Qt.push(a),e.setCallbacks({onScrollCapture:m,onWheelCapture:m,onTouchMoveCapture:p}),document.addEventListener("wheel",c,Xt),document.addEventListener("touchmove",c,Xt),document.addEventListener("touchstart",f,Xt),function(){Qt=Qt.filter(function(g){return g!==a}),document.removeEventListener("wheel",c,Xt),document.removeEventListener("touchmove",c,Xt),document.removeEventListener("touchstart",f,Xt)}},[]);var h=e.removeScrollBar,v=e.inert;return l.createElement(l.Fragment,null,v?l.createElement(a,{styles:ag(o)}):null,h?l.createElement(Xp,{gapMode:e.gapMode}):null)}function cg(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const lg=Fp(ks,ig);var Mn=l.forwardRef(function(e,t){return l.createElement(cr,ct({},e,{ref:t,sideCar:lg}))});Mn.classNames=cr.classNames;var ug=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Zt=new WeakMap,dr=new WeakMap,fr={},ho=0,Fs=function(e){return e&&(e.host||Fs(e.parentNode))},dg=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Fs(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},fg=function(e,t,n,r){var o=dg(t,Array.isArray(e)?e:[e]);fr[n]||(fr[n]=new WeakMap);var a=fr[n],s=[],i=new Set,c=new Set(o),d=function(m){!m||i.has(m)||(i.add(m),d(m.parentNode))};o.forEach(d);var f=function(m){!m||c.has(m)||Array.prototype.forEach.call(m.children,function(p){if(i.has(p))f(p);else try{var h=p.getAttribute(r),v=h!==null&&h!=="false",g=(Zt.get(p)||0)+1,y=(a.get(p)||0)+1;Zt.set(p,g),a.set(p,y),s.push(p),g===1&&v&&dr.set(p,!0),y===1&&p.setAttribute(n,"true"),v||p.setAttribute(r,"true")}catch(w){console.error("aria-hidden: cannot operate on ",p,w)}})};return f(t),i.clear(),ho++,function(){s.forEach(function(m){var p=Zt.get(m)-1,h=a.get(m)-1;Zt.set(m,p),a.set(m,h),p||(dr.has(m)||m.removeAttribute(r),dr.delete(m)),h||m.removeAttribute(n)}),ho--,ho||(Zt=new WeakMap,Zt=new WeakMap,dr=new WeakMap,fr={})}},mr=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=ug(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),fg(r,o,n,"aria-hidden")):function(){return null}},po="Dialog",[$s,Ws]=Te(po),[mg,Je]=$s(po),Ls=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:s=!0}=e,i=l.useRef(null),c=l.useRef(null),[d=!1,f]=Ie({prop:r,defaultProp:o,onChange:a});return u.jsx(mg,{scope:t,triggerRef:i,contentRef:c,contentId:je(),titleId:je(),descriptionId:je(),open:d,onOpenChange:f,onOpenToggle:l.useCallback(()=>f(m=>!m),[f]),modal:s,children:n})};Ls.displayName=po;var Bs="DialogTrigger",Vs=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Je(Bs,n),a=ne(t,o.triggerRef);return u.jsx(F.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":yo(o.open),...r,ref:a,onClick:A(e.onClick,o.onOpenToggle)})});Vs.displayName=Bs;var go="DialogPortal",[hg,Ys]=$s(go,{forceMount:void 0}),Gs=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,a=Je(go,t);return u.jsx(hg,{scope:t,forceMount:n,children:l.Children.map(r,s=>u.jsx(De,{present:n||a.open,children:u.jsx(Nn,{asChild:!0,container:o,children:s})}))})};Gs.displayName=go;var hr="DialogOverlay",zs=l.forwardRef((e,t)=>{const n=Ys(hr,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=Je(hr,e.__scopeDialog);return a.modal?u.jsx(De,{present:r||a.open,children:u.jsx(pg,{...o,ref:t})}):null});zs.displayName=hr;var pg=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Je(hr,n);return u.jsx(Mn,{as:it,allowPinchZoom:!0,shards:[o.contentRef],children:u.jsx(F.div,{"data-state":yo(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Wt="DialogContent",Hs=l.forwardRef((e,t)=>{const n=Ys(Wt,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=Je(Wt,e.__scopeDialog);return u.jsx(De,{present:r||a.open,children:a.modal?u.jsx(gg,{...o,ref:t}):u.jsx(vg,{...o,ref:t})})});Hs.displayName=Wt;var gg=l.forwardRef((e,t)=>{const n=Je(Wt,e.__scopeDialog),r=l.useRef(null),o=ne(t,n.contentRef,r);return l.useEffect(()=>{const a=r.current;if(a)return mr(a)},[]),u.jsx(Us,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:A(e.onCloseAutoFocus,a=>{var s;a.preventDefault(),(s=n.triggerRef.current)==null||s.focus()}),onPointerDownOutside:A(e.onPointerDownOutside,a=>{const s=a.detail.originalEvent,i=s.button===0&&s.ctrlKey===!0;(s.button===2||i)&&a.preventDefault()}),onFocusOutside:A(e.onFocusOutside,a=>a.preventDefault())})}),vg=l.forwardRef((e,t)=>{const n=Je(Wt,e.__scopeDialog),r=l.useRef(!1),o=l.useRef(!1);return u.jsx(Us,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(r.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var c,d;(c=e.onInteractOutside)==null||c.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=a.target;((d=n.triggerRef.current)==null?void 0:d.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),Us=l.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,...s}=e,i=Je(Wt,n),c=l.useRef(null),d=ne(t,c);return ar(),u.jsxs(u.Fragment,{children:[u.jsx(Cn,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:u.jsx($t,{role:"dialog",id:i.contentId,"aria-describedby":i.descriptionId,"aria-labelledby":i.titleId,"data-state":yo(i.open),...s,ref:d,onDismiss:()=>i.onOpenChange(!1)})}),u.jsxs(u.Fragment,{children:[u.jsx(bg,{titleId:i.titleId}),u.jsx(xg,{contentRef:c,descriptionId:i.descriptionId})]})]})}),vo="DialogTitle",Ks=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Je(vo,n);return u.jsx(F.h2,{id:o.titleId,...r,ref:t})});Ks.displayName=vo;var qs="DialogDescription",Xs=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Je(qs,n);return u.jsx(F.p,{id:o.descriptionId,...r,ref:t})});Xs.displayName=qs;var Qs="DialogClose",Zs=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=Je(Qs,n);return u.jsx(F.button,{type:"button",...r,ref:t,onClick:A(e.onClick,()=>o.onOpenChange(!1))})});Zs.displayName=Qs;function yo(e){return e?"open":"closed"}var Js="DialogTitleWarning",[yg,ei]=ep(Js,{contentName:Wt,titleName:vo,docsSlug:"dialog"}),bg=({titleId:e})=>{const t=ei(Js),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
71
+ `)},Hm=0,_t=[];function Um(e){var t=l.useRef([]),n=l.useRef([0,0]),o=l.useRef(),r=l.useState(Hm++)[0],a=l.useState(Za)[0],s=l.useRef(e);l.useEffect(function(){s.current=e},[e]),l.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(r));var g=pm([e.lockRef.current],(e.shards||[]).map(as),!0).filter(Boolean);return g.forEach(function(v){return v.classList.add("allow-interactivity-".concat(r))}),function(){document.body.classList.remove("block-interactivity-".concat(r)),g.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(r))})}}},[e.inert,e.lockRef.current,e.shards]);var i=l.useCallback(function(g,v){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!s.current.allowPinchZoom;var y=On(g),w=n.current,C="deltaX"in g?g.deltaX:w[0]-y[0],N="deltaY"in g?g.deltaY:w[1]-y[1],E,A=g.target,M=Math.abs(C)>Math.abs(N)?"h":"v";if("touches"in g&&M==="h"&&A.type==="range")return!1;var I=ts(M,A);if(!I)return!0;if(I?E=M:(E=M==="v"?"h":"v",I=ts(M,A)),!I)return!1;if(!o.current&&"changedTouches"in g&&(C||N)&&(o.current=E),!E)return!0;var j=o.current||E;return Wm(j,v,g,j==="h"?C:N,!0)},[]),u=l.useCallback(function(g){var v=g;if(!(!_t.length||_t[_t.length-1]!==a)){var y="deltaY"in v?rs(v):On(v),w=t.current.filter(function(E){return E.name===v.type&&(E.target===v.target||v.target===E.shadowParent)&&zm(E.delta,y)})[0];if(w&&w.should){v.cancelable&&v.preventDefault();return}if(!w){var C=(s.current.shards||[]).map(as).filter(Boolean).filter(function(E){return E.contains(v.target)}),N=C.length>0?i(v,C[0]):!s.current.noIsolation;N&&v.cancelable&&v.preventDefault()}}},[]),d=l.useCallback(function(g,v,y,w){var C={name:g,delta:v,target:y,should:w,shadowParent:Km(y)};t.current.push(C),setTimeout(function(){t.current=t.current.filter(function(N){return N!==C})},1)},[]),f=l.useCallback(function(g){n.current=On(g),o.current=void 0},[]),m=l.useCallback(function(g){d(g.type,rs(g),g.target,i(g,e.lockRef.current))},[]),h=l.useCallback(function(g){d(g.type,On(g),g.target,i(g,e.lockRef.current))},[]);l.useEffect(function(){return _t.push(a),e.setCallbacks({onScrollCapture:m,onWheelCapture:m,onTouchMoveCapture:h}),document.addEventListener("wheel",u,At),document.addEventListener("touchmove",u,At),document.addEventListener("touchstart",f,At),function(){_t=_t.filter(function(g){return g!==a}),document.removeEventListener("wheel",u,At),document.removeEventListener("touchmove",u,At),document.removeEventListener("touchstart",f,At)}},[]);var p=e.removeScrollBar,b=e.inert;return l.createElement(l.Fragment,null,b?l.createElement(a,{styles:Gm(r)}):null,p?l.createElement(Dm,{gapMode:e.gapMode}):null)}function Km(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Ym=Cm(Ja,Um);var Qt=l.forwardRef(function(e,t){return l.createElement(jn,ze({},e,{ref:t,sideCar:Ym}))});Qt.classNames=jn.classNames;var Xm=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},It=new WeakMap,Ln=new WeakMap,Fn={},Fo=0,ss=function(e){return e&&(e.host||ss(e.parentNode))},qm=function(e,t){return t.map(function(n){if(e.contains(n))return n;var o=ss(n);return o&&e.contains(o)?o:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Jm=function(e,t,n,o){var r=qm(t,Array.isArray(e)?e:[e]);Fn[n]||(Fn[n]=new WeakMap);var a=Fn[n],s=[],i=new Set,u=new Set(r),d=function(m){!m||i.has(m)||(i.add(m),d(m.parentNode))};r.forEach(d);var f=function(m){!m||u.has(m)||Array.prototype.forEach.call(m.children,function(h){if(i.has(h))f(h);else try{var p=h.getAttribute(o),b=p!==null&&p!=="false",g=(It.get(h)||0)+1,v=(a.get(h)||0)+1;It.set(h,g),a.set(h,v),s.push(h),g===1&&b&&Ln.set(h,!0),v===1&&h.setAttribute(n,"true"),b||h.setAttribute(o,"true")}catch(y){console.error("aria-hidden: cannot operate on ",h,y)}})};return f(t),i.clear(),Fo++,function(){s.forEach(function(m){var h=It.get(m)-1,p=a.get(m)-1;It.set(m,h),a.set(m,p),h||(Ln.has(m)||m.removeAttribute(o),Ln.delete(m)),p||m.removeAttribute(n)}),Fo--,Fo||(It=new WeakMap,It=new WeakMap,Ln=new WeakMap,Fn={})}},$n=function(e,t,n){n===void 0&&(n="data-aria-hidden");var o=Array.from(Array.isArray(e)?e:[e]),r=Xm(e);return r?(o.push.apply(o,Array.from(r.querySelectorAll("[aria-live]"))),Jm(o,r,n,"aria-hidden")):function(){return null}},$o="Dialog",[is,ls]=ve($o),[Zm,je]=is($o),cs=e=>{const{__scopeDialog:t,children:n,open:o,defaultOpen:r,onOpenChange:a,modal:s=!0}=e,i=l.useRef(null),u=l.useRef(null),[d=!1,f]=Ce({prop:o,defaultProp:r,onChange:a});return c.jsx(Zm,{scope:t,triggerRef:i,contentRef:u,contentId:Ne(),titleId:Ne(),descriptionId:Ne(),open:d,onOpenChange:f,onOpenToggle:l.useCallback(()=>f(m=>!m),[f]),modal:s,children:n})};cs.displayName=$o;var us="DialogTrigger",ds=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=je(us,n),a=J(t,r.triggerRef);return c.jsx(L.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Wo(r.open),...o,ref:a,onClick:_(e.onClick,r.onOpenToggle)})});ds.displayName=us;var Vo="DialogPortal",[Qm,fs]=is(Vo,{forceMount:void 0}),ps=e=>{const{__scopeDialog:t,forceMount:n,children:o,container:r}=e,a=je(Vo,t);return c.jsx(Qm,{scope:t,forceMount:n,children:l.Children.map(o,s=>c.jsx(be,{present:n||a.open,children:c.jsx(Zt,{asChild:!0,container:r,children:s})}))})};ps.displayName=Vo;var Vn="DialogOverlay",ms=l.forwardRef((e,t)=>{const n=fs(Vn,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,a=je(Vn,e.__scopeDialog);return a.modal?c.jsx(be,{present:o||a.open,children:c.jsx(eg,{...r,ref:t})}):null});ms.displayName=Vn;var eg=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=je(Vn,n);return c.jsx(Qt,{as:We,allowPinchZoom:!0,shards:[r.contentRef],children:c.jsx(L.div,{"data-state":Wo(r.open),...o,ref:t,style:{pointerEvents:"auto",...o.style}})})}),xt="DialogContent",gs=l.forwardRef((e,t)=>{const n=fs(xt,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,a=je(xt,e.__scopeDialog);return c.jsx(be,{present:o||a.open,children:a.modal?c.jsx(tg,{...r,ref:t}):c.jsx(ng,{...r,ref:t})})});gs.displayName=xt;var tg=l.forwardRef((e,t)=>{const n=je(xt,e.__scopeDialog),o=l.useRef(null),r=J(t,n.contentRef,o);return l.useEffect(()=>{const a=o.current;if(a)return $n(a)},[]),c.jsx(hs,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:_(e.onCloseAutoFocus,a=>{var s;a.preventDefault(),(s=n.triggerRef.current)==null||s.focus()}),onPointerDownOutside:_(e.onPointerDownOutside,a=>{const s=a.detail.originalEvent,i=s.button===0&&s.ctrlKey===!0;(s.button===2||i)&&a.preventDefault()}),onFocusOutside:_(e.onFocusOutside,a=>a.preventDefault())})}),ng=l.forwardRef((e,t)=>{const n=je(xt,e.__scopeDialog),o=l.useRef(!1),r=l.useRef(!1);return c.jsx(hs,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(o.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:a=>{var u,d;(u=e.onInteractOutside)==null||u.call(e,a),a.defaultPrevented||(o.current=!0,a.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const s=a.target;((d=n.triggerRef.current)==null?void 0:d.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&r.current&&a.preventDefault()}})}),hs=l.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:a,...s}=e,i=je(xt,n),u=l.useRef(null),d=J(t,u);return _n(),c.jsxs(c.Fragment,{children:[c.jsx(Jt,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:a,children:c.jsx(wt,{role:"dialog",id:i.contentId,"aria-describedby":i.descriptionId,"aria-labelledby":i.titleId,"data-state":Wo(i.open),...s,ref:d,onDismiss:()=>i.onOpenChange(!1)})}),c.jsxs(c.Fragment,{children:[c.jsx(rg,{titleId:i.titleId}),c.jsx(sg,{contentRef:u,descriptionId:i.descriptionId})]})]})}),Bo="DialogTitle",vs=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=je(Bo,n);return c.jsx(L.h2,{id:r.titleId,...o,ref:t})});vs.displayName=Bo;var bs="DialogDescription",ys=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=je(bs,n);return c.jsx(L.p,{id:r.descriptionId,...o,ref:t})});ys.displayName=bs;var ws="DialogClose",xs=l.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=je(ws,n);return c.jsx(L.button,{type:"button",...o,ref:t,onClick:_(e.onClick,()=>r.onOpenChange(!1))})});xs.displayName=ws;function Wo(e){return e?"open":"closed"}var Cs="DialogTitleWarning",[og,Ns]=$p(Cs,{contentName:xt,titleName:Bo,docsSlug:"dialog"}),rg=({titleId:e})=>{const t=Ns(Cs),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
72
72
 
73
73
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
74
74
 
75
- For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return l.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},wg="DialogDescriptionWarning",xg=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${ei(wg).contentName}}.`;return l.useEffect(()=>{var a;const o=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},ti=Ls,ni=Vs,ri=Gs,bo=zs,wo=Hs,xo=Ks,Co=Xs,pr=Zs,oi="AlertDialog",[Cg,CS]=Te(oi,[Ws]),vt=Ws(),ai=e=>{const{__scopeAlertDialog:t,...n}=e,r=vt(t);return u.jsx(ti,{...r,...n,modal:!0})};ai.displayName=oi;var Ng="AlertDialogTrigger",si=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,o=vt(n);return u.jsx(ni,{...o,...r,ref:t})});si.displayName=Ng;var Mg="AlertDialogPortal",ii=e=>{const{__scopeAlertDialog:t,...n}=e,r=vt(t);return u.jsx(ri,{...r,...n})};ii.displayName=Mg;var Sg="AlertDialogOverlay",ci=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,o=vt(n);return u.jsx(bo,{...o,...r,ref:t})});ci.displayName=Sg;var Jt="AlertDialogContent",[Eg,Pg]=Cg(Jt),li=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,children:r,...o}=e,a=vt(n),s=l.useRef(null),i=ne(t,s),c=l.useRef(null);return u.jsx(yg,{contentName:Jt,titleName:ui,docsSlug:"alert-dialog",children:u.jsx(Eg,{scope:n,cancelRef:c,children:u.jsxs(wo,{role:"alertdialog",...a,...o,ref:i,onOpenAutoFocus:A(o.onOpenAutoFocus,d=>{var f;d.preventDefault(),(f=c.current)==null||f.focus({preventScroll:!0})}),onPointerDownOutside:d=>d.preventDefault(),onInteractOutside:d=>d.preventDefault(),children:[u.jsx(oo,{children:r}),u.jsx(Tg,{contentRef:s})]})})})});li.displayName=Jt;var ui="AlertDialogTitle",di=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,o=vt(n);return u.jsx(xo,{...o,...r,ref:t})});di.displayName=ui;var fi="AlertDialogDescription",mi=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,o=vt(n);return u.jsx(Co,{...o,...r,ref:t})});mi.displayName=fi;var kg="AlertDialogAction",hi=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,o=vt(n);return u.jsx(pr,{...o,...r,ref:t})});hi.displayName=kg;var pi="AlertDialogCancel",gi=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...r}=e,{cancelRef:o}=Pg(pi,n),a=vt(n),s=ne(t,o);return u.jsx(pr,{...a,...r,ref:s})});gi.displayName=pi;var Tg=({contentRef:e})=>{const t=`\`${Jt}\` requires a description for the component to be accessible for screen reader users.
75
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return l.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},ag="DialogDescriptionWarning",sg=({contentRef:e,descriptionId:t})=>{const o=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Ns(ag).contentName}}.`;return l.useEffect(()=>{var a;const r=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&r&&(document.getElementById(t)||console.warn(o))},[o,e,t]),null},Es=cs,Ss=ds,Ps=ps,zo=ms,Go=gs,Ho=vs,Uo=ys,Bn=xs,Ts="AlertDialog",[ig,b0]=ve(Ts,[ls]),et=ls(),Ms=e=>{const{__scopeAlertDialog:t,...n}=e,o=et(t);return c.jsx(Es,{...o,...n,modal:!0})};Ms.displayName=Ts;var lg="AlertDialogTrigger",Rs=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=et(n);return c.jsx(Ss,{...r,...o,ref:t})});Rs.displayName=lg;var cg="AlertDialogPortal",As=e=>{const{__scopeAlertDialog:t,...n}=e,o=et(t);return c.jsx(Ps,{...o,...n})};As.displayName=cg;var ug="AlertDialogOverlay",_s=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=et(n);return c.jsx(zo,{...r,...o,ref:t})});_s.displayName=ug;var kt="AlertDialogContent",[dg,fg]=ig(kt),Is=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,children:o,...r}=e,a=et(n),s=l.useRef(null),i=J(t,s),u=l.useRef(null);return c.jsx(og,{contentName:kt,titleName:ks,docsSlug:"alert-dialog",children:c.jsx(dg,{scope:n,cancelRef:u,children:c.jsxs(Go,{role:"alertdialog",...a,...r,ref:i,onOpenAutoFocus:_(r.onOpenAutoFocus,d=>{var f;d.preventDefault(),(f=u.current)==null||f.focus({preventScroll:!0})}),onPointerDownOutside:d=>d.preventDefault(),onInteractOutside:d=>d.preventDefault(),children:[c.jsx(Ro,{children:o}),c.jsx(mg,{contentRef:s})]})})})});Is.displayName=kt;var ks="AlertDialogTitle",js=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=et(n);return c.jsx(Ho,{...r,...o,ref:t})});js.displayName=ks;var Ds="AlertDialogDescription",Os=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=et(n);return c.jsx(Uo,{...r,...o,ref:t})});Os.displayName=Ds;var pg="AlertDialogAction",Ls=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=et(n);return c.jsx(Bn,{...r,...o,ref:t})});Ls.displayName=pg;var Fs="AlertDialogCancel",$s=l.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,{cancelRef:r}=fg(Fs,n),a=et(n),s=J(t,r);return c.jsx(Bn,{...a,...o,ref:s})});$s.displayName=Fs;var mg=({contentRef:e})=>{const t=`\`${kt}\` requires a description for the component to be accessible for screen reader users.
76
76
 
77
- You can add a description to the \`${Jt}\` by passing a \`${fi}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
77
+ You can add a description to the \`${kt}\` by passing a \`${Ds}\` component as a child, which also benefits sighted users by adding visible context to the dialog.
78
78
 
79
- 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 \`${Jt}\`. 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.
79
+ 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 \`${kt}\`. 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.
80
80
 
81
- For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return l.useEffect(()=>{var r;document.getElementById((r=e.current)==null?void 0:r.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},Dg=ai,Og=si,Ag=ii,vi=ci,yi=li,bi=hi,wi=gi,xi=di,Ci=mi;const Sn=Kt("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",xl:"h-12 rounded-md px-10 text-xl",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),lt=l.forwardRef(({className:e,variant:t,size:n,isLoading:r=!1,asChild:o=!1,...a},s)=>{const i=o?it:"button";return u.jsxs(i,{className:O(Sn({variant:t,size:n,className:e})),ref:s,...a,disabled:r||a.disabled,children:[r&&u.jsxs("svg",{className:"animate-spin -ml-1 h-5 w-5",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[u.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),u.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),a.children]})});lt.displayName="Button";const _g=Dg,Rg=Og,Ni=Ag,No=l.forwardRef(({className:e,...t},n)=>u.jsx(vi,{className:O("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:n}));No.displayName=vi.displayName;const Mi=l.forwardRef(({className:e,...t},n)=>u.jsxs(Ni,{children:[u.jsx(No,{}),u.jsx(yi,{ref:n,className:O("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})]}));Mi.displayName=yi.displayName;const Si=({className:e,...t})=>u.jsx("div",{className:O("flex flex-col space-y-2 text-center sm:text-left",e),...t});Si.displayName="AlertDialogHeader";const Ei=({className:e,...t})=>u.jsx("div",{className:O("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Ei.displayName="AlertDialogFooter";const Pi=l.forwardRef(({className:e,...t},n)=>u.jsx(xi,{ref:n,className:O("text-lg font-semibold",e),...t}));Pi.displayName=xi.displayName;const ki=l.forwardRef(({className:e,...t},n)=>u.jsx(Ci,{ref:n,className:O("text-sm text-muted-foreground",e),...t}));ki.displayName=Ci.displayName;const Ti=l.forwardRef(({className:e,...t},n)=>u.jsx(bi,{ref:n,className:O(Sn(),e),...t}));Ti.displayName=bi.displayName;const Di=l.forwardRef(({className:e,...t},n)=>u.jsx(wi,{ref:n,className:O(Sn({variant:"outline"}),"mt-2 sm:mt-0",e),...t}));Di.displayName=wi.displayName;/**
81
+ For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return l.useEffect(()=>{var o;document.getElementById((o=e.current)==null?void 0:o.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},gg=Ms,hg=Rs,vg=As,Vs=_s,Bs=Is,Ws=Ls,zs=$s,Gs=js,Hs=Os;const en=Mt("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",xl:"h-12 rounded-md px-10 text-xl",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),Ge=l.forwardRef(({className:e,variant:t,size:n,isLoading:o=!1,asChild:r=!1,...a},s)=>{const i=r?We:"button";return c.jsxs(i,{className:R(en({variant:t,size:n,className:e})),ref:s,...a,disabled:o||a.disabled,children:[o&&c.jsxs("svg",{className:"animate-spin -ml-1 h-5 w-5",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[c.jsx("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),c.jsx("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),a.children]})});Ge.displayName="Button";const bg=gg,yg=hg,Us=vg,Ko=l.forwardRef(({className:e,...t},n)=>c.jsx(Vs,{className:R("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:n}));Ko.displayName=Vs.displayName;const Ks=l.forwardRef(({className:e,...t},n)=>c.jsxs(Us,{children:[c.jsx(Ko,{}),c.jsx(Bs,{ref:n,className:R("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})]}));Ks.displayName=Bs.displayName;const Ys=({className:e,...t})=>c.jsx("div",{className:R("flex flex-col space-y-2 text-center sm:text-left",e),...t});Ys.displayName="AlertDialogHeader";const Xs=({className:e,...t})=>c.jsx("div",{className:R("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Xs.displayName="AlertDialogFooter";const qs=l.forwardRef(({className:e,...t},n)=>c.jsx(Gs,{ref:n,className:R("text-lg font-semibold",e),...t}));qs.displayName=Gs.displayName;const Js=l.forwardRef(({className:e,...t},n)=>c.jsx(Hs,{ref:n,className:R("text-sm text-muted-foreground",e),...t}));Js.displayName=Hs.displayName;const Zs=l.forwardRef(({className:e,...t},n)=>c.jsx(Ws,{ref:n,className:R(en(),e),...t}));Zs.displayName=Ws.displayName;const Qs=l.forwardRef(({className:e,...t},n)=>c.jsx(zs,{ref:n,className:R(en({variant:"outline"}),"mt-2 sm:mt-0",e),...t}));Qs.displayName=zs.displayName;/**
82
82
  * @license lucide-react v0.469.0 - ISC
83
83
  *
84
84
  * This source code is licensed under the ISC license.
85
85
  * See the LICENSE file in the root directory of this source tree.
86
- */const Ig=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Oi=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
86
+ */const wg=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),ei=(...e)=>e.filter((t,n,o)=>!!t&&t.trim()!==""&&o.indexOf(t)===n).join(" ").trim();/**
87
87
  * @license lucide-react v0.469.0 - ISC
88
88
  *
89
89
  * This source code is licensed under the ISC license.
90
90
  * See the LICENSE file in the root directory of this source tree.
91
- */var jg={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"};/**
91
+ */var xg={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"};/**
92
92
  * @license lucide-react v0.469.0 - ISC
93
93
  *
94
94
  * This source code is licensed under the ISC license.
95
95
  * See the LICENSE file in the root directory of this source tree.
96
- */const Fg=x.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:a,iconNode:s,...i},c)=>x.createElement("svg",{ref:c,...jg,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Oi("lucide",o),...i},[...s.map(([d,f])=>x.createElement(d,f)),...Array.isArray(a)?a:[a]]));/**
96
+ */const Cg=S.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:o,className:r="",children:a,iconNode:s,...i},u)=>S.createElement("svg",{ref:u,...xg,width:t,height:t,stroke:e,strokeWidth:o?Number(n)*24/Number(t):n,className:ei("lucide",r),...i},[...s.map(([d,f])=>S.createElement(d,f)),...Array.isArray(a)?a:[a]]));/**
97
97
  * @license lucide-react v0.469.0 - ISC
98
98
  *
99
99
  * This source code is licensed under the ISC license.
100
100
  * See the LICENSE file in the root directory of this source tree.
101
- */const _e=(e,t)=>{const n=x.forwardRef(({className:r,...o},a)=>x.createElement(Fg,{ref:a,iconNode:t,className:Oi(`lucide-${Ig(e)}`,r),...o}));return n.displayName=`${e}`,n};/**
101
+ */const we=(e,t)=>{const n=S.forwardRef(({className:o,...r},a)=>S.createElement(Cg,{ref:a,iconNode:t,className:ei(`lucide-${wg(e)}`,o),...r}));return n.displayName=`${e}`,n};/**
102
102
  * @license lucide-react v0.469.0 - ISC
103
103
  *
104
104
  * This source code is licensed under the ISC license.
105
105
  * See the LICENSE file in the root directory of this source tree.
106
- */const $g=_e("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
106
+ */const Ng=we("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
107
107
  * @license lucide-react v0.469.0 - ISC
108
108
  *
109
109
  * This source code is licensed under the ISC license.
110
110
  * See the LICENSE file in the root directory of this source tree.
111
- */const Wg=_e("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
111
+ */const Eg=we("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
112
112
  * @license lucide-react v0.469.0 - ISC
113
113
  *
114
114
  * This source code is licensed under the ISC license.
115
115
  * See the LICENSE file in the root directory of this source tree.
116
- */const Mo=_e("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
116
+ */const Yo=we("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
117
117
  * @license lucide-react v0.469.0 - ISC
118
118
  *
119
119
  * This source code is licensed under the ISC license.
120
120
  * See the LICENSE file in the root directory of this source tree.
121
- */const So=_e("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
121
+ */const Xo=we("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
122
122
  * @license lucide-react v0.469.0 - ISC
123
123
  *
124
124
  * This source code is licensed under the ISC license.
125
125
  * See the LICENSE file in the root directory of this source tree.
126
- */const Ai=_e("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
126
+ */const ti=we("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
127
127
  * @license lucide-react v0.469.0 - ISC
128
128
  *
129
129
  * This source code is licensed under the ISC license.
130
130
  * See the LICENSE file in the root directory of this source tree.
131
- */const Eo=_e("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
131
+ */const qo=we("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
132
132
  * @license lucide-react v0.469.0 - ISC
133
133
  *
134
134
  * This source code is licensed under the ISC license.
135
135
  * See the LICENSE file in the root directory of this source tree.
136
- */const Lg=_e("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
136
+ */const Sg=we("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
137
137
  * @license lucide-react v0.469.0 - ISC
138
138
  *
139
139
  * This source code is licensed under the ISC license.
140
140
  * See the LICENSE file in the root directory of this source tree.
141
- */const Bg=_e("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
141
+ */const Pg=we("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
142
142
  * @license lucide-react v0.469.0 - ISC
143
143
  *
144
144
  * This source code is licensed under the ISC license.
145
145
  * See the LICENSE file in the root directory of this source tree.
146
- */const Vg=_e("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
146
+ */const Tg=we("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
147
147
  * @license lucide-react v0.469.0 - ISC
148
148
  *
149
149
  * This source code is licensed under the ISC license.
150
150
  * See the LICENSE file in the root directory of this source tree.
151
- */const _i=_e("CircleHelp",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
151
+ */const ni=we("CircleHelp",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/**
152
152
  * @license lucide-react v0.469.0 - ISC
153
153
  *
154
154
  * This source code is licensed under the ISC license.
155
155
  * See the LICENSE file in the root directory of this source tree.
156
- */const Yg=_e("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
156
+ */const Mg=we("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
157
157
  * @license lucide-react v0.469.0 - ISC
158
158
  *
159
159
  * This source code is licensed under the ISC license.
160
160
  * See the LICENSE file in the root directory of this source tree.
161
- */const Ri=_e("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
161
+ */const oi=we("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
162
162
  * @license lucide-react v0.469.0 - ISC
163
163
  *
164
164
  * This source code is licensed under the ISC license.
165
165
  * See the LICENSE file in the root directory of this source tree.
166
- */const Gg=_e("Ellipsis",[["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"}]]);/**
166
+ */const Rg=we("Ellipsis",[["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"}]]);/**
167
167
  * @license lucide-react v0.469.0 - ISC
168
168
  *
169
169
  * This source code is licensed under the ISC license.
170
170
  * See the LICENSE file in the root directory of this source tree.
171
- */const zg=_e("EyeOff",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
171
+ */const Ag=we("EyeOff",[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]);/**
172
172
  * @license lucide-react v0.469.0 - ISC
173
173
  *
174
174
  * This source code is licensed under the ISC license.
175
175
  * See the LICENSE file in the root directory of this source tree.
176
- */const Hg=_e("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
176
+ */const _g=we("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
177
177
  * @license lucide-react v0.469.0 - ISC
178
178
  *
179
179
  * This source code is licensed under the ISC license.
180
180
  * See the LICENSE file in the root directory of this source tree.
181
- */const Ug=_e("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
181
+ */const Ig=we("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]);/**
182
182
  * @license lucide-react v0.469.0 - ISC
183
183
  *
184
184
  * This source code is licensed under the ISC license.
185
185
  * See the LICENSE file in the root directory of this source tree.
186
- */const Kg=_e("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
186
+ */const kg=we("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
187
187
  * @license lucide-react v0.469.0 - ISC
188
188
  *
189
189
  * This source code is licensed under the ISC license.
190
190
  * See the LICENSE file in the root directory of this source tree.
191
- */const qg=_e("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),Xg=["top","right","bottom","left"],Pt=Math.min,Ge=Math.max,gr=Math.round,vr=Math.floor,ut=e=>({x:e,y:e}),Qg={left:"right",right:"left",bottom:"top",top:"bottom"},Zg={start:"end",end:"start"};function Po(e,t,n){return Ge(e,Pt(t,n))}function yt(e,t){return typeof e=="function"?e(t):e}function bt(e){return e.split("-")[0]}function en(e){return e.split("-")[1]}function ko(e){return e==="x"?"y":"x"}function To(e){return e==="y"?"height":"width"}function kt(e){return["top","bottom"].includes(bt(e))?"y":"x"}function Do(e){return ko(kt(e))}function Jg(e,t,n){n===void 0&&(n=!1);const r=en(e),o=Do(e),a=To(o);let s=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=yr(s)),[s,yr(s)]}function ev(e){const t=yr(e);return[Oo(e),t,Oo(t)]}function Oo(e){return e.replace(/start|end/g,t=>Zg[t])}function tv(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:s;default:return[]}}function nv(e,t,n,r){const o=en(e);let a=tv(bt(e),n==="start",r);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(Oo)))),a}function yr(e){return e.replace(/left|right|bottom|top/g,t=>Qg[t])}function rv(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ii(e){return typeof e!="number"?rv(e):{top:e,right:e,bottom:e,left:e}}function br(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function ji(e,t,n){let{reference:r,floating:o}=e;const a=kt(t),s=Do(t),i=To(s),c=bt(t),d=a==="y",f=r.x+r.width/2-o.width/2,m=r.y+r.height/2-o.height/2,p=r[i]/2-o[i]/2;let h;switch(c){case"top":h={x:f,y:r.y-o.height};break;case"bottom":h={x:f,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:m};break;case"left":h={x:r.x-o.width,y:m};break;default:h={x:r.x,y:r.y}}switch(en(t)){case"start":h[s]-=p*(n&&d?-1:1);break;case"end":h[s]+=p*(n&&d?-1:1);break}return h}const ov=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:s}=n,i=a.filter(Boolean),c=await(s.isRTL==null?void 0:s.isRTL(t));let d=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:m}=ji(d,r,c),p=r,h={},v=0;for(let g=0;g<i.length;g++){const{name:y,fn:w}=i[g],{x:b,y:C,data:M,reset:S}=await w({x:f,y:m,initialPlacement:r,placement:p,strategy:o,middlewareData:h,rects:d,platform:s,elements:{reference:e,floating:t}});f=b??f,m=C??m,h={...h,[y]:{...h[y],...M}},S&&v<=50&&(v++,typeof S=="object"&&(S.placement&&(p=S.placement),S.rects&&(d=S.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:o}):S.rects),{x:f,y:m}=ji(d,p,c)),g=-1)}return{x:f,y:m,placement:p,strategy:o,middlewareData:h}};async function En(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:s,elements:i,strategy:c}=e,{boundary:d="clippingAncestors",rootBoundary:f="viewport",elementContext:m="floating",altBoundary:p=!1,padding:h=0}=yt(t,e),v=Ii(h),y=i[p?m==="floating"?"reference":"floating":m],w=br(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(y)))==null||n?y:y.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(i.floating)),boundary:d,rootBoundary:f,strategy:c})),b=m==="floating"?{x:r,y:o,width:s.floating.width,height:s.floating.height}:s.reference,C=await(a.getOffsetParent==null?void 0:a.getOffsetParent(i.floating)),M=await(a.isElement==null?void 0:a.isElement(C))?await(a.getScale==null?void 0:a.getScale(C))||{x:1,y:1}:{x:1,y:1},S=br(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:b,offsetParent:C,strategy:c}):b);return{top:(w.top-S.top+v.top)/M.y,bottom:(S.bottom-w.bottom+v.bottom)/M.y,left:(w.left-S.left+v.left)/M.x,right:(S.right-w.right+v.right)/M.x}}const av=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:s,elements:i,middlewareData:c}=t,{element:d,padding:f=0}=yt(e,t)||{};if(d==null)return{};const m=Ii(f),p={x:n,y:r},h=Do(o),v=To(h),g=await s.getDimensions(d),y=h==="y",w=y?"top":"left",b=y?"bottom":"right",C=y?"clientHeight":"clientWidth",M=a.reference[v]+a.reference[h]-p[h]-a.floating[v],S=p[h]-a.reference[h],k=await(s.getOffsetParent==null?void 0:s.getOffsetParent(d));let P=k?k[C]:0;(!P||!await(s.isElement==null?void 0:s.isElement(k)))&&(P=i.floating[C]||a.floating[v]);const D=M/2-S/2,R=P/2-g[v]/2-1,$=Pt(m[w],R),V=Pt(m[b],R),_=$,z=P-g[v]-V,G=P/2-g[v]/2+D,ee=Po(_,G,z),W=!c.arrow&&en(o)!=null&&G!==ee&&a.reference[v]/2-(G<_?$:V)-g[v]/2<0,Y=W?G<_?G-_:G-z:0;return{[h]:p[h]+Y,data:{[h]:ee,centerOffset:G-ee-Y,...W&&{alignmentOffset:Y}},reset:W}}}),sv=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:s,initialPlacement:i,platform:c,elements:d}=t,{mainAxis:f=!0,crossAxis:m=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:g=!0,...y}=yt(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const w=bt(o),b=kt(i),C=bt(i)===i,M=await(c.isRTL==null?void 0:c.isRTL(d.floating)),S=p||(C||!g?[yr(i)]:ev(i)),k=v!=="none";!p&&k&&S.push(...nv(i,g,v,M));const P=[i,...S],D=await En(t,y),R=[];let $=((r=a.flip)==null?void 0:r.overflows)||[];if(f&&R.push(D[w]),m){const G=Jg(o,s,M);R.push(D[G[0]],D[G[1]])}if($=[...$,{placement:o,overflows:R}],!R.every(G=>G<=0)){var V,_;const G=(((V=a.flip)==null?void 0:V.index)||0)+1,ee=P[G];if(ee)return{data:{index:G,overflows:$},reset:{placement:ee}};let W=(_=$.filter(Y=>Y.overflows[0]<=0).sort((Y,L)=>Y.overflows[1]-L.overflows[1])[0])==null?void 0:_.placement;if(!W)switch(h){case"bestFit":{var z;const Y=(z=$.filter(L=>{if(k){const T=kt(L.placement);return T===b||T==="y"}return!0}).map(L=>[L.placement,L.overflows.filter(T=>T>0).reduce((T,H)=>T+H,0)]).sort((L,T)=>L[1]-T[1])[0])==null?void 0:z[0];Y&&(W=Y);break}case"initialPlacement":W=i;break}if(o!==W)return{reset:{placement:W}}}return{}}}};function Fi(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function $i(e){return Xg.some(t=>e[t]>=0)}const iv=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=yt(e,t);switch(r){case"referenceHidden":{const a=await En(t,{...o,elementContext:"reference"}),s=Fi(a,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:$i(s)}}}case"escaped":{const a=await En(t,{...o,altBoundary:!0}),s=Fi(a,n.floating);return{data:{escapedOffsets:s,escaped:$i(s)}}}default:return{}}}}};async function cv(e,t){const{placement:n,platform:r,elements:o}=e,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),s=bt(n),i=en(n),c=kt(n)==="y",d=["left","top"].includes(s)?-1:1,f=a&&c?-1:1,m=yt(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:v}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return i&&typeof v=="number"&&(h=i==="end"?v*-1:v),c?{x:h*f,y:p*d}:{x:p*d,y:h*f}}const lv=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:a,placement:s,middlewareData:i}=t,c=await cv(t,e);return s===((n=i.offset)==null?void 0:n.placement)&&(r=i.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:a+c.y,data:{...c,placement:s}}}}},uv=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:i={fn:y=>{let{x:w,y:b}=y;return{x:w,y:b}}},...c}=yt(e,t),d={x:n,y:r},f=await En(t,c),m=kt(bt(o)),p=ko(m);let h=d[p],v=d[m];if(a){const y=p==="y"?"top":"left",w=p==="y"?"bottom":"right",b=h+f[y],C=h-f[w];h=Po(b,h,C)}if(s){const y=m==="y"?"top":"left",w=m==="y"?"bottom":"right",b=v+f[y],C=v-f[w];v=Po(b,v,C)}const g=i.fn({...t,[p]:h,[m]:v});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:a,[m]:s}}}}}},dv=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:s}=t,{offset:i=0,mainAxis:c=!0,crossAxis:d=!0}=yt(e,t),f={x:n,y:r},m=kt(o),p=ko(m);let h=f[p],v=f[m];const g=yt(i,t),y=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(c){const C=p==="y"?"height":"width",M=a.reference[p]-a.floating[C]+y.mainAxis,S=a.reference[p]+a.reference[C]-y.mainAxis;h<M?h=M:h>S&&(h=S)}if(d){var w,b;const C=p==="y"?"width":"height",M=["top","left"].includes(bt(o)),S=a.reference[m]-a.floating[C]+(M&&((w=s.offset)==null?void 0:w[m])||0)+(M?0:y.crossAxis),k=a.reference[m]+a.reference[C]+(M?0:((b=s.offset)==null?void 0:b[m])||0)-(M?y.crossAxis:0);v<S?v=S:v>k&&(v=k)}return{[p]:h,[m]:v}}}},fv=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:a,platform:s,elements:i}=t,{apply:c=()=>{},...d}=yt(e,t),f=await En(t,d),m=bt(o),p=en(o),h=kt(o)==="y",{width:v,height:g}=a.floating;let y,w;m==="top"||m==="bottom"?(y=m,w=p===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(w=m,y=p==="end"?"top":"bottom");const b=g-f.top-f.bottom,C=v-f.left-f.right,M=Pt(g-f[y],b),S=Pt(v-f[w],C),k=!t.middlewareData.shift;let P=M,D=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(D=C),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(P=b),k&&!p){const $=Ge(f.left,0),V=Ge(f.right,0),_=Ge(f.top,0),z=Ge(f.bottom,0);h?D=v-2*($!==0||V!==0?$+V:Ge(f.left,f.right)):P=g-2*(_!==0||z!==0?_+z:Ge(f.top,f.bottom))}await c({...t,availableWidth:D,availableHeight:P});const R=await s.getDimensions(i.floating);return v!==R.width||g!==R.height?{reset:{rects:!0}}:{}}}};function wr(){return typeof window<"u"}function tn(e){return Wi(e)?(e.nodeName||"").toLowerCase():"#document"}function ze(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dt(e){var t;return(t=(Wi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Wi(e){return wr()?e instanceof Node||e instanceof ze(e).Node:!1}function et(e){return wr()?e instanceof Element||e instanceof ze(e).Element:!1}function ft(e){return wr()?e instanceof HTMLElement||e instanceof ze(e).HTMLElement:!1}function Li(e){return!wr()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ze(e).ShadowRoot}function Pn(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=tt(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function mv(e){return["table","td","th"].includes(tn(e))}function xr(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Ao(e){const t=_o(),n=et(e)?tt(e):e;return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function hv(e){let t=Tt(e);for(;ft(t)&&!nn(t);){if(Ao(t))return t;if(xr(t))return null;t=Tt(t)}return null}function _o(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function nn(e){return["html","body","#document"].includes(tn(e))}function tt(e){return ze(e).getComputedStyle(e)}function Cr(e){return et(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Tt(e){if(tn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Li(e)&&e.host||dt(e);return Li(t)?t.host:t}function Bi(e){const t=Tt(e);return nn(t)?e.ownerDocument?e.ownerDocument.body:e.body:ft(t)&&Pn(t)?t:Bi(t)}function kn(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Bi(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),s=ze(o);if(a){const i=Ro(s);return t.concat(s,s.visualViewport||[],Pn(o)?o:[],i&&n?kn(i):[])}return t.concat(o,kn(o,[],n))}function Ro(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Vi(e){const t=tt(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=ft(e),a=o?e.offsetWidth:n,s=o?e.offsetHeight:r,i=gr(n)!==a||gr(r)!==s;return i&&(n=a,r=s),{width:n,height:r,$:i}}function Io(e){return et(e)?e:e.contextElement}function rn(e){const t=Io(e);if(!ft(t))return ut(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=Vi(t);let s=(a?gr(n.width):n.width)/r,i=(a?gr(n.height):n.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}const pv=ut(0);function Yi(e){const t=ze(e);return!_o()||!t.visualViewport?pv:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function gv(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==ze(e)?!1:t}function Lt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=Io(e);let s=ut(1);t&&(r?et(r)&&(s=rn(r)):s=rn(e));const i=gv(a,n,r)?Yi(a):ut(0);let c=(o.left+i.x)/s.x,d=(o.top+i.y)/s.y,f=o.width/s.x,m=o.height/s.y;if(a){const p=ze(a),h=r&&et(r)?ze(r):r;let v=p,g=Ro(v);for(;g&&r&&h!==v;){const y=rn(g),w=g.getBoundingClientRect(),b=tt(g),C=w.left+(g.clientLeft+parseFloat(b.paddingLeft))*y.x,M=w.top+(g.clientTop+parseFloat(b.paddingTop))*y.y;c*=y.x,d*=y.y,f*=y.x,m*=y.y,c+=C,d+=M,v=ze(g),g=Ro(v)}}return br({width:f,height:m,x:c,y:d})}function jo(e,t){const n=Cr(e).scrollLeft;return t?t.left+n:Lt(dt(e)).left+n}function Gi(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:jo(e,r)),a=r.top+t.scrollTop;return{x:o,y:a}}function vv(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",s=dt(r),i=t?xr(t.floating):!1;if(r===s||i&&a)return n;let c={scrollLeft:0,scrollTop:0},d=ut(1);const f=ut(0),m=ft(r);if((m||!m&&!a)&&((tn(r)!=="body"||Pn(s))&&(c=Cr(r)),ft(r))){const h=Lt(r);d=rn(r),f.x=h.x+r.clientLeft,f.y=h.y+r.clientTop}const p=s&&!m&&!a?Gi(s,c,!0):ut(0);return{width:n.width*d.x,height:n.height*d.y,x:n.x*d.x-c.scrollLeft*d.x+f.x+p.x,y:n.y*d.y-c.scrollTop*d.y+f.y+p.y}}function yv(e){return Array.from(e.getClientRects())}function bv(e){const t=dt(e),n=Cr(e),r=e.ownerDocument.body,o=Ge(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Ge(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+jo(e);const i=-n.scrollTop;return tt(r).direction==="rtl"&&(s+=Ge(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:s,y:i}}function wv(e,t){const n=ze(e),r=dt(e),o=n.visualViewport;let a=r.clientWidth,s=r.clientHeight,i=0,c=0;if(o){a=o.width,s=o.height;const d=_o();(!d||d&&t==="fixed")&&(i=o.offsetLeft,c=o.offsetTop)}return{width:a,height:s,x:i,y:c}}function xv(e,t){const n=Lt(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=ft(e)?rn(e):ut(1),s=e.clientWidth*a.x,i=e.clientHeight*a.y,c=o*a.x,d=r*a.y;return{width:s,height:i,x:c,y:d}}function zi(e,t,n){let r;if(t==="viewport")r=wv(e,n);else if(t==="document")r=bv(dt(e));else if(et(t))r=xv(t,n);else{const o=Yi(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return br(r)}function Hi(e,t){const n=Tt(e);return n===t||!et(n)||nn(n)?!1:tt(n).position==="fixed"||Hi(n,t)}function Cv(e,t){const n=t.get(e);if(n)return n;let r=kn(e,[],!1).filter(i=>et(i)&&tn(i)!=="body"),o=null;const a=tt(e).position==="fixed";let s=a?Tt(e):e;for(;et(s)&&!nn(s);){const i=tt(s),c=Ao(s);!c&&i.position==="fixed"&&(o=null),(a?!c&&!o:!c&&i.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Pn(s)&&!c&&Hi(e,s))?r=r.filter(f=>f!==s):o=i,s=Tt(s)}return t.set(e,r),r}function Nv(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const s=[...n==="clippingAncestors"?xr(t)?[]:Cv(t,this._c):[].concat(n),r],i=s[0],c=s.reduce((d,f)=>{const m=zi(t,f,o);return d.top=Ge(m.top,d.top),d.right=Pt(m.right,d.right),d.bottom=Pt(m.bottom,d.bottom),d.left=Ge(m.left,d.left),d},zi(t,i,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function Mv(e){const{width:t,height:n}=Vi(e);return{width:t,height:n}}function Sv(e,t,n){const r=ft(t),o=dt(t),a=n==="fixed",s=Lt(e,!0,a,t);let i={scrollLeft:0,scrollTop:0};const c=ut(0);if(r||!r&&!a)if((tn(t)!=="body"||Pn(o))&&(i=Cr(t)),r){const p=Lt(t,!0,a,t);c.x=p.x+t.clientLeft,c.y=p.y+t.clientTop}else o&&(c.x=jo(o));const d=o&&!r&&!a?Gi(o,i):ut(0),f=s.left+i.scrollLeft-c.x-d.x,m=s.top+i.scrollTop-c.y-d.y;return{x:f,y:m,width:s.width,height:s.height}}function Fo(e){return tt(e).position==="static"}function Ui(e,t){if(!ft(e)||tt(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return dt(e)===n&&(n=n.ownerDocument.body),n}function Ki(e,t){const n=ze(e);if(xr(e))return n;if(!ft(e)){let o=Tt(e);for(;o&&!nn(o);){if(et(o)&&!Fo(o))return o;o=Tt(o)}return n}let r=Ui(e,t);for(;r&&mv(r)&&Fo(r);)r=Ui(r,t);return r&&nn(r)&&Fo(r)&&!Ao(r)?n:r||hv(e)||n}const Ev=async function(e){const t=this.getOffsetParent||Ki,n=this.getDimensions,r=await n(e.floating);return{reference:Sv(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Pv(e){return tt(e).direction==="rtl"}const kv={convertOffsetParentRelativeRectToViewportRelativeRect:vv,getDocumentElement:dt,getClippingRect:Nv,getOffsetParent:Ki,getElementRects:Ev,getClientRects:yv,getDimensions:Mv,getScale:rn,isElement:et,isRTL:Pv};function Tv(e,t){let n=null,r;const o=dt(e);function a(){var i;clearTimeout(r),(i=n)==null||i.disconnect(),n=null}function s(i,c){i===void 0&&(i=!1),c===void 0&&(c=1),a();const{left:d,top:f,width:m,height:p}=e.getBoundingClientRect();if(i||t(),!m||!p)return;const h=vr(f),v=vr(o.clientWidth-(d+m)),g=vr(o.clientHeight-(f+p)),y=vr(d),b={rootMargin:-h+"px "+-v+"px "+-g+"px "+-y+"px",threshold:Ge(0,Pt(1,c))||1};let C=!0;function M(S){const k=S[0].intersectionRatio;if(k!==c){if(!C)return s();k?s(!1,k):r=setTimeout(()=>{s(!1,1e-7)},1e3)}C=!1}try{n=new IntersectionObserver(M,{...b,root:o.ownerDocument})}catch{n=new IntersectionObserver(M,b)}n.observe(e)}return s(!0),a}function Dv(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,d=Io(e),f=o||a?[...d?kn(d):[],...kn(t)]:[];f.forEach(w=>{o&&w.addEventListener("scroll",n,{passive:!0}),a&&w.addEventListener("resize",n)});const m=d&&i?Tv(d,n):null;let p=-1,h=null;s&&(h=new ResizeObserver(w=>{let[b]=w;b&&b.target===d&&h&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var C;(C=h)==null||C.observe(t)})),n()}),d&&!c&&h.observe(d),h.observe(t));let v,g=c?Lt(e):null;c&&y();function y(){const w=Lt(e);g&&(w.x!==g.x||w.y!==g.y||w.width!==g.width||w.height!==g.height)&&n(),g=w,v=requestAnimationFrame(y)}return n(),()=>{var w;f.forEach(b=>{o&&b.removeEventListener("scroll",n),a&&b.removeEventListener("resize",n)}),m==null||m(),(w=h)==null||w.disconnect(),h=null,c&&cancelAnimationFrame(v)}}const Ov=lv,Av=uv,_v=sv,Rv=fv,Iv=iv,qi=av,jv=dv,Fv=(e,t,n)=>{const r=new Map,o={platform:kv,...n},a={...o.platform,_c:r};return ov(e,t,{...o,platform:a})};var Nr=typeof document<"u"?x.useLayoutEffect:x.useEffect;function Mr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Mr(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const a=o[r];if(!(a==="_owner"&&e.$$typeof)&&!Mr(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function Xi(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Qi(e,t){const n=Xi(e);return Math.round(t*n)/n}function $o(e){const t=l.useRef(e);return Nr(()=>{t.current=e}),t}function $v(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:s}={},transform:i=!0,whileElementsMounted:c,open:d}=e,[f,m]=l.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=l.useState(r);Mr(p,r)||h(r);const[v,g]=l.useState(null),[y,w]=l.useState(null),b=l.useCallback(L=>{L!==k.current&&(k.current=L,g(L))},[]),C=l.useCallback(L=>{L!==P.current&&(P.current=L,w(L))},[]),M=a||v,S=s||y,k=l.useRef(null),P=l.useRef(null),D=l.useRef(f),R=c!=null,$=$o(c),V=$o(o),_=$o(d),z=l.useCallback(()=>{if(!k.current||!P.current)return;const L={placement:t,strategy:n,middleware:p};V.current&&(L.platform=V.current),Fv(k.current,P.current,L).then(T=>{const H={...T,isPositioned:_.current!==!1};G.current&&!Mr(D.current,H)&&(D.current=H,Jn.flushSync(()=>{m(H)}))})},[p,t,n,V,_]);Nr(()=>{d===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,m(L=>({...L,isPositioned:!1})))},[d]);const G=l.useRef(!1);Nr(()=>(G.current=!0,()=>{G.current=!1}),[]),Nr(()=>{if(M&&(k.current=M),S&&(P.current=S),M&&S){if($.current)return $.current(M,S,z);z()}},[M,S,z,$,R]);const ee=l.useMemo(()=>({reference:k,floating:P,setReference:b,setFloating:C}),[b,C]),W=l.useMemo(()=>({reference:M,floating:S}),[M,S]),Y=l.useMemo(()=>{const L={position:n,left:0,top:0};if(!W.floating)return L;const T=Qi(W.floating,f.x),H=Qi(W.floating,f.y);return i?{...L,transform:"translate("+T+"px, "+H+"px)",...Xi(W.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:T,top:H}},[n,i,W.floating,f.x,f.y]);return l.useMemo(()=>({...f,update:z,refs:ee,elements:W,floatingStyles:Y}),[f,z,ee,W,Y])}const Wv=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?qi({element:r.current,padding:o}).fn(n):{}:r?qi({element:r,padding:o}).fn(n):{}}}},Lv=(e,t)=>({...Ov(e),options:[e,t]}),Bv=(e,t)=>({...Av(e),options:[e,t]}),Vv=(e,t)=>({...jv(e),options:[e,t]}),Yv=(e,t)=>({..._v(e),options:[e,t]}),Gv=(e,t)=>({...Rv(e),options:[e,t]}),zv=(e,t)=>({...Iv(e),options:[e,t]}),Hv=(e,t)=>({...Wv(e),options:[e,t]});var Uv="Arrow",Zi=l.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...a}=e;return u.jsx(F.svg,{...a,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:u.jsx("polygon",{points:"0,0 30,0 15,10"})})});Zi.displayName=Uv;var Kv=Zi;function Sr(e){const[t,n]=l.useState(void 0);return Ee(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let s,i;if("borderBoxSize"in a){const c=a.borderBoxSize,d=Array.isArray(c)?c[0]:c;s=d.inlineSize,i=d.blockSize}else s=e.offsetWidth,i=e.offsetHeight;n({width:s,height:i})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Wo="Popper",[Ji,Dt]=Te(Wo),[qv,ec]=Ji(Wo),tc=e=>{const{__scopePopper:t,children:n}=e,[r,o]=l.useState(null);return u.jsx(qv,{scope:t,anchor:r,onAnchorChange:o,children:n})};tc.displayName=Wo;var nc="PopperAnchor",rc=l.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=ec(nc,n),s=l.useRef(null),i=ne(t,s);return l.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||s.current)}),r?null:u.jsx(F.div,{...o,ref:i})});rc.displayName=nc;var Lo="PopperContent",[Xv,Qv]=Ji(Lo),oc=l.forwardRef((e,t)=>{var I,ie,ce,oe,se,le;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:a="center",alignOffset:s=0,arrowPadding:i=0,avoidCollisions:c=!0,collisionBoundary:d=[],collisionPadding:f=0,sticky:m="partial",hideWhenDetached:p=!1,updatePositionStrategy:h="optimized",onPlaced:v,...g}=e,y=ec(Lo,n),[w,b]=l.useState(null),C=ne(t,Me=>b(Me)),[M,S]=l.useState(null),k=Sr(M),P=(k==null?void 0:k.width)??0,D=(k==null?void 0:k.height)??0,R=r+(a!=="center"?"-"+a:""),$=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},V=Array.isArray(d)?d:[d],_=V.length>0,z={padding:$,boundary:V.filter(Jv),altBoundary:_},{refs:G,floatingStyles:ee,placement:W,isPositioned:Y,middlewareData:L}=$v({strategy:"fixed",placement:R,whileElementsMounted:(...Me)=>Dv(...Me,{animationFrame:h==="always"}),elements:{reference:y.anchor},middleware:[Lv({mainAxis:o+D,alignmentAxis:s}),c&&Bv({mainAxis:!0,crossAxis:!1,limiter:m==="partial"?Vv():void 0,...z}),c&&Yv({...z}),Gv({...z,apply:({elements:Me,rects:Re,availableWidth:$e,availableHeight:ot})=>{const{width:Be,height:at}=Re.reference,Xe=Me.floating.style;Xe.setProperty("--radix-popper-available-width",`${$e}px`),Xe.setProperty("--radix-popper-available-height",`${ot}px`),Xe.setProperty("--radix-popper-anchor-width",`${Be}px`),Xe.setProperty("--radix-popper-anchor-height",`${at}px`)}}),M&&Hv({element:M,padding:i}),ey({arrowWidth:P,arrowHeight:D}),p&&zv({strategy:"referenceHidden",...z})]}),[T,H]=ic(W),q=Ne(v);Ee(()=>{Y&&(q==null||q())},[Y,q]);const X=(I=L.arrow)==null?void 0:I.x,K=(ie=L.arrow)==null?void 0:ie.y,Z=((ce=L.arrow)==null?void 0:ce.centerOffset)!==0,[me,ge]=l.useState();return Ee(()=>{w&&ge(window.getComputedStyle(w).zIndex)},[w]),u.jsx("div",{ref:G.setFloating,"data-radix-popper-content-wrapper":"",style:{...ee,transform:Y?ee.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:me,"--radix-popper-transform-origin":[(oe=L.transformOrigin)==null?void 0:oe.x,(se=L.transformOrigin)==null?void 0:se.y].join(" "),...((le=L.hide)==null?void 0:le.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:u.jsx(Xv,{scope:n,placedSide:T,onArrowChange:S,arrowX:X,arrowY:K,shouldHideArrow:Z,children:u.jsx(F.div,{"data-side":T,"data-align":H,...g,ref:C,style:{...g.style,animation:Y?void 0:"none"}})})})});oc.displayName=Lo;var ac="PopperArrow",Zv={top:"bottom",right:"left",bottom:"top",left:"right"},sc=l.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,a=Qv(ac,r),s=Zv[a.placedSide];return u.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[s]: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:u.jsx(Kv,{...o,ref:n,style:{...o.style,display:"block"}})})});sc.displayName=ac;function Jv(e){return e!==null}var ey=e=>({name:"transformOrigin",options:e,fn(t){var y,w,b;const{placement:n,rects:r,middlewareData:o}=t,s=((y=o.arrow)==null?void 0:y.centerOffset)!==0,i=s?0:e.arrowWidth,c=s?0:e.arrowHeight,[d,f]=ic(n),m={start:"0%",center:"50%",end:"100%"}[f],p=(((w=o.arrow)==null?void 0:w.x)??0)+i/2,h=(((b=o.arrow)==null?void 0:b.y)??0)+c/2;let v="",g="";return d==="bottom"?(v=s?m:`${p}px`,g=`${-c}px`):d==="top"?(v=s?m:`${p}px`,g=`${r.floating.height+c}px`):d==="right"?(v=`${-c}px`,g=s?m:`${h}px`):d==="left"&&(v=`${r.floating.width+c}px`,g=s?m:`${h}px`),{data:{x:v,y:g}}}});function ic(e){const[t,n="center"]=e.split("-");return[t,n]}var Tn=tc,Dn=rc,Er=oc,Pr=sc,Bo="Popover",[cc,NS]=Te(Bo,[Dt]),On=Dt(),[ty,Ot]=cc(Bo),lc=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:s=!1}=e,i=On(t),c=l.useRef(null),[d,f]=l.useState(!1),[m=!1,p]=Ie({prop:r,defaultProp:o,onChange:a});return u.jsx(Tn,{...i,children:u.jsx(ty,{scope:t,contentId:je(),triggerRef:c,open:m,onOpenChange:p,onOpenToggle:l.useCallback(()=>p(h=>!h),[p]),hasCustomAnchor:d,onCustomAnchorAdd:l.useCallback(()=>f(!0),[]),onCustomAnchorRemove:l.useCallback(()=>f(!1),[]),modal:s,children:n})})};lc.displayName=Bo;var uc="PopoverAnchor",dc=l.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Ot(uc,n),a=On(n),{onCustomAnchorAdd:s,onCustomAnchorRemove:i}=o;return l.useEffect(()=>(s(),()=>i()),[s,i]),u.jsx(Dn,{...a,...r,ref:t})});dc.displayName=uc;var fc="PopoverTrigger",mc=l.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Ot(fc,n),a=On(n),s=ne(t,o.triggerRef),i=u.jsx(F.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":yc(o.open),...r,ref:s,onClick:A(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?i:u.jsx(Dn,{asChild:!0,...a,children:i})});mc.displayName=fc;var Vo="PopoverPortal",[ny,ry]=cc(Vo,{forceMount:void 0}),hc=e=>{const{__scopePopover:t,forceMount:n,children:r,container:o}=e,a=Ot(Vo,t);return u.jsx(ny,{scope:t,forceMount:n,children:u.jsx(De,{present:n||a.open,children:u.jsx(Nn,{asChild:!0,container:o,children:r})})})};hc.displayName=Vo;var on="PopoverContent",pc=l.forwardRef((e,t)=>{const n=ry(on,e.__scopePopover),{forceMount:r=n.forceMount,...o}=e,a=Ot(on,e.__scopePopover);return u.jsx(De,{present:r||a.open,children:a.modal?u.jsx(oy,{...o,ref:t}):u.jsx(ay,{...o,ref:t})})});pc.displayName=on;var oy=l.forwardRef((e,t)=>{const n=Ot(on,e.__scopePopover),r=l.useRef(null),o=ne(t,r),a=l.useRef(!1);return l.useEffect(()=>{const s=r.current;if(s)return mr(s)},[]),u.jsx(Mn,{as:it,allowPinchZoom:!0,children:u.jsx(gc,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:A(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),a.current||(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:A(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,c=i.button===0&&i.ctrlKey===!0,d=i.button===2||c;a.current=d},{checkForDefaultPrevented:!1}),onFocusOutside:A(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1})})})}),ay=l.forwardRef((e,t)=>{const n=Ot(on,e.__scopePopover),r=l.useRef(!1),o=l.useRef(!1);return u.jsx(gc,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(r.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var c,d;(c=e.onInteractOutside)==null||c.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=a.target;((d=n.triggerRef.current)==null?void 0:d.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),gc=l.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEscapeKeyDown:i,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,...m}=e,p=Ot(on,n),h=On(n);return ar(),u.jsx(Cn,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:u.jsx($t,{asChild:!0,disableOutsidePointerEvents:s,onInteractOutside:f,onEscapeKeyDown:i,onPointerDownOutside:c,onFocusOutside:d,onDismiss:()=>p.onOpenChange(!1),children:u.jsx(Er,{"data-state":yc(p.open),role:"dialog",id:p.contentId,...h,...m,ref:t,style:{...m.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)"}})})})}),vc="PopoverClose",sy=l.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=Ot(vc,n);return u.jsx(F.button,{type:"button",...r,ref:t,onClick:A(e.onClick,()=>o.onOpenChange(!1))})});sy.displayName=vc;var iy="PopoverArrow",cy=l.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,o=On(n);return u.jsx(Pr,{...o,...r,ref:t})});cy.displayName=iy;function yc(e){return e?"open":"closed"}var ly=lc,uy=dc,dy=mc,fy=hc,bc=pc;const wc=ly,xc=dy,my=uy,Yo=l.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},o)=>u.jsx(fy,{children:u.jsx(bc,{ref:o,align:t,sideOffset:n,className:O("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",e),...r})}));Yo.displayName=bc.displayName;function hy(e){const{value:t="",onChange:n,options:r,className:o,placeholder:a="Search...",emptyMessage:s="Nothing found"}=e,[i,c]=x.useState(t),[d,f]=x.useState(r),[m,p]=x.useState(-1),[h,v]=x.useState(!1),g=M=>{const S=M.target.value;c(S),n==null||n(S),p(-1),v(!0),S.trim()===""?f(r):f(r.filter(k=>k.label.toLowerCase().includes(S.toLowerCase())))},y=M=>{if(M.key==="ArrowDown")M.preventDefault(),p(S=>S<d.length-1?S+1:S);else if(M.key==="ArrowUp")M.preventDefault(),p(S=>S>0?S-1:-1);else if(M.key==="Enter"&&m>=0){const S=d[m];c(S.label),n==null||n(S.value),f([]),p(-1),v(!1)}else M.key==="Escape"&&(f([]),p(-1))},w=M=>{v(!1),c(M.label),n==null||n(M.value),f(r),p(-1)},b=()=>{v(!0)},C=()=>{v(!1)};return u.jsxs(wc,{open:h,children:[u.jsx(xc,{asChild:!0,children:u.jsx("div",{className:"relative w-full",children:u.jsx(nr,{type:"text",placeholder:a,value:i,onChange:g,onKeyDown:y,onClick:b,onFocus:b,onBlur:C,className:O("pr-10",o),"aria-label":"Search field","aria-autocomplete":"list","aria-controls":"suggestions-list","aria-expanded":d.length>0,leftIcon:u.jsx(Kg,{className:"w-4 h-4"})})})}),u.jsx(Yo,{className:"p-0 w-[var(--radix-popover-trigger-width)] max-h-96 overflow-y-auto",children:d.length>0?u.jsx("ul",{id:"suggestions-list",role:"listbox",children:d.map((M,S)=>u.jsx("li",{className:`px-4 py-2 cursor-pointer hover:bg-muted ${S===m?"bg-muted":""}`,onClick:()=>w(M),role:"option","aria-selected":S===m,children:M.label},M.value))}):u.jsx("span",{className:"px-4 py-2 block",children:s})})]})}var Go="Avatar",[py,MS]=Te(Go),[gy,Cc]=py(Go),Nc=l.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[o,a]=l.useState("idle");return u.jsx(gy,{scope:n,imageLoadingStatus:o,onImageLoadingStatusChange:a,children:u.jsx(F.span,{...r,ref:t})})});Nc.displayName=Go;var Mc="AvatarImage",Sc=l.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:o=()=>{},...a}=e,s=Cc(Mc,n),i=vy(r,a.referrerPolicy),c=Ne(d=>{o(d),s.onImageLoadingStatusChange(d)});return Ee(()=>{i!=="idle"&&c(i)},[i,c]),i==="loaded"?u.jsx(F.img,{...a,ref:t,src:r}):null});Sc.displayName=Mc;var Ec="AvatarFallback",Pc=l.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...o}=e,a=Cc(Ec,n),[s,i]=l.useState(r===void 0);return l.useEffect(()=>{if(r!==void 0){const c=window.setTimeout(()=>i(!0),r);return()=>window.clearTimeout(c)}},[r]),s&&a.imageLoadingStatus!=="loaded"?u.jsx(F.span,{...o,ref:t}):null});Pc.displayName=Ec;function vy(e,t){const[n,r]=l.useState("idle");return Ee(()=>{if(!e){r("error");return}let o=!0;const a=new window.Image,s=i=>()=>{o&&r(i)};return r("loading"),a.onload=s("loaded"),a.onerror=s("error"),a.src=e,t&&(a.referrerPolicy=t),()=>{o=!1}},[e,t]),n}var kc=Nc,Tc=Sc,Dc=Pc;const Oc=l.forwardRef(({className:e,...t},n)=>u.jsx(kc,{ref:n,className:O("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));Oc.displayName=kc.displayName;const Ac=l.forwardRef(({className:e,...t},n)=>u.jsx(Tc,{ref:n,className:O("aspect-square h-full w-full",e),...t}));Ac.displayName=Tc.displayName;const _c=l.forwardRef(({className:e,...t},n)=>u.jsx(Dc,{ref:n,className:O("flex h-full w-full items-center justify-center rounded-full bg-muted",e),...t}));_c.displayName=Dc.displayName;const Rc=Kt("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 yy({className:e,variant:t,...n}){return u.jsx("div",{className:O(Rc({variant:t}),e),...n})}function an(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}function mt(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let o;if(r==="formatting"&&e.formattingValues){const s=e.defaultFormattingWidth||e.defaultWidth,i=n!=null&&n.width?String(n.width):s;o=e.formattingValues[i]||e.formattingValues[s]}else{const s=e.defaultWidth,i=n!=null&&n.width?String(n.width):e.defaultWidth;o=e.values[i]||e.values[s]}const a=e.argumentCallback?e.argumentCallback(t):t;return o[a]}}function ht(e){return(t,n={})=>{const r=n.width,o=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(o);if(!a)return null;const s=a[0],i=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(i)?wy(i,m=>m.test(s)):by(i,m=>m.test(s));let d;d=e.valueCallback?e.valueCallback(c):c,d=n.valueCallback?n.valueCallback(d):d;const f=t.slice(s.length);return{value:d,rest:f}}}function by(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function wy(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function Ic(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const o=r[0],a=t.match(e.parsePattern);if(!a)return null;let s=e.valueCallback?e.valueCallback(a[0]):a[0];s=n.valueCallback?n.valueCallback(s):s;const i=t.slice(o.length);return{value:s,rest:i}}}const jc=6048e5,xy=864e5,Fc=Symbol.for("constructDateFrom");function Oe(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&Fc in e?e[Fc](t):e instanceof Date?new e.constructor(t):new Date(t)}function sn(e,...t){const n=Oe.bind(null,t.find(r=>typeof r=="object"));return t.map(n)}let Cy={};function An(){return Cy}function ve(e,t){return Oe(t||e,e)}function cn(e,t){var i,c,d,f;const n=An(),r=(t==null?void 0:t.weekStartsOn)??((c=(i=t==null?void 0:t.locale)==null?void 0:i.options)==null?void 0:c.weekStartsOn)??n.weekStartsOn??((f=(d=n.locale)==null?void 0:d.options)==null?void 0:f.weekStartsOn)??0,o=ve(e,t==null?void 0:t.in),a=o.getDay(),s=(a<r?7:0)+a-r;return o.setDate(o.getDate()-s),o.setHours(0,0,0,0),o}const Ny={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},My=(e,t,n)=>{let r;const o=Ny[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r},Sy={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Ey=(e,t,n,r)=>Sy[e],Py={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},ky={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Ty={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Dy={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Oy={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Ay={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},_y={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:mt({values:Py,defaultWidth:"wide"}),quarter:mt({values:ky,defaultWidth:"wide",argumentCallback:e=>e-1}),month:mt({values:Ty,defaultWidth:"wide"}),day:mt({values:Dy,defaultWidth:"wide"}),dayPeriod:mt({values:Oy,defaultWidth:"wide",formattingValues:Ay,defaultFormattingWidth:"wide"})},Ry=/^(\d+)(th|st|nd|rd)?/i,Iy=/\d+/i,jy={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},Fy={any:[/^b/i,/^(a|c)/i]},$y={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Wy={any:[/1/i,/2/i,/3/i,/4/i]},Ly={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},By={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Vy={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Yy={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Gy={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},zy={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Hy={ordinalNumber:Ic({matchPattern:Ry,parsePattern:Iy,valueCallback:e=>parseInt(e,10)}),era:ht({matchPatterns:jy,defaultMatchWidth:"wide",parsePatterns:Fy,defaultParseWidth:"any"}),quarter:ht({matchPatterns:$y,defaultMatchWidth:"wide",parsePatterns:Wy,defaultParseWidth:"any",valueCallback:e=>e+1}),month:ht({matchPatterns:Ly,defaultMatchWidth:"wide",parsePatterns:By,defaultParseWidth:"any"}),day:ht({matchPatterns:Vy,defaultMatchWidth:"wide",parsePatterns:Yy,defaultParseWidth:"any"}),dayPeriod:ht({matchPatterns:Gy,defaultMatchWidth:"any",parsePatterns:zy,defaultParseWidth:"any"})},Uy={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},Ky={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},qy={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Xy={date:an({formats:Uy,defaultWidth:"full"}),time:an({formats:Ky,defaultWidth:"full"}),dateTime:an({formats:qy,defaultWidth:"full"})},kr={code:"en-US",formatDistance:My,formatLong:Xy,formatRelative:Ey,localize:_y,match:Hy,options:{weekStartsOn:0,firstWeekContainsDate:1}},Qy={lessThanXSeconds:{one:"menos de um segundo",other:"menos de {{count}} segundos"},xSeconds:{one:"1 segundo",other:"{{count}} segundos"},halfAMinute:"meio minuto",lessThanXMinutes:{one:"menos de um minuto",other:"menos de {{count}} minutos"},xMinutes:{one:"1 minuto",other:"{{count}} minutos"},aboutXHours:{one:"cerca de 1 hora",other:"cerca de {{count}} horas"},xHours:{one:"1 hora",other:"{{count}} horas"},xDays:{one:"1 dia",other:"{{count}} dias"},aboutXWeeks:{one:"cerca de 1 semana",other:"cerca de {{count}} semanas"},xWeeks:{one:"1 semana",other:"{{count}} semanas"},aboutXMonths:{one:"cerca de 1 mês",other:"cerca de {{count}} meses"},xMonths:{one:"1 mês",other:"{{count}} meses"},aboutXYears:{one:"cerca de 1 ano",other:"cerca de {{count}} anos"},xYears:{one:"1 ano",other:"{{count}} anos"},overXYears:{one:"mais de 1 ano",other:"mais de {{count}} anos"},almostXYears:{one:"quase 1 ano",other:"quase {{count}} anos"}},Zy=(e,t,n)=>{let r;const o=Qy[e];return typeof o=="string"?r=o:t===1?r=o.one:r=o.other.replace("{{count}}",String(t)),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"em "+r:"há "+r:r},Jy={full:"EEEE, d 'de' MMMM 'de' y",long:"d 'de' MMMM 'de' y",medium:"d MMM y",short:"dd/MM/yyyy"},eb={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},tb={full:"{{date}} 'às' {{time}}",long:"{{date}} 'às' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},nb={date:an({formats:Jy,defaultWidth:"full"}),time:an({formats:eb,defaultWidth:"full"}),dateTime:an({formats:tb,defaultWidth:"full"})},rb={lastWeek:e=>{const t=e.getDay();return"'"+(t===0||t===6?"último":"última")+"' eeee 'às' p"},yesterday:"'ontem às' p",today:"'hoje às' p",tomorrow:"'amanhã às' p",nextWeek:"eeee 'às' p",other:"P"},ob=(e,t,n,r)=>{const o=rb[e];return typeof o=="function"?o(t):o},ab={narrow:["AC","DC"],abbreviated:["AC","DC"],wide:["antes de cristo","depois de cristo"]},sb={narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},ib={narrow:["j","f","m","a","m","j","j","a","s","o","n","d"],abbreviated:["jan","fev","mar","abr","mai","jun","jul","ago","set","out","nov","dez"],wide:["janeiro","fevereiro","março","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"]},cb={narrow:["D","S","T","Q","Q","S","S"],short:["dom","seg","ter","qua","qui","sex","sab"],abbreviated:["domingo","segunda","terça","quarta","quinta","sexta","sábado"],wide:["domingo","segunda-feira","terça-feira","quarta-feira","quinta-feira","sexta-feira","sábado"]},lb={narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"manhã",afternoon:"tarde",evening:"tarde",night:"noite"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"tarde",night:"noite"},wide:{am:"a.m.",pm:"p.m.",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"tarde",night:"noite"}},ub={narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"da manhã",afternoon:"da tarde",evening:"da tarde",night:"da noite"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da tarde",night:"da noite"},wide:{am:"a.m.",pm:"p.m.",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da tarde",night:"da noite"}},db={ordinalNumber:(e,t)=>{const n=Number(e);return(t==null?void 0:t.unit)==="week"?n+"ª":n+"º"},era:mt({values:ab,defaultWidth:"wide"}),quarter:mt({values:sb,defaultWidth:"wide",argumentCallback:e=>e-1}),month:mt({values:ib,defaultWidth:"wide"}),day:mt({values:cb,defaultWidth:"wide"}),dayPeriod:mt({values:lb,defaultWidth:"wide",formattingValues:ub,defaultFormattingWidth:"wide"})},fb=/^(\d+)[ºªo]?/i,mb=/\d+/i,hb={narrow:/^(ac|dc|a|d)/i,abbreviated:/^(a\.?\s?c\.?|d\.?\s?c\.?)/i,wide:/^(antes de cristo|depois de cristo)/i},pb={any:[/^ac/i,/^dc/i],wide:[/^antes de cristo/i,/^depois de cristo/i]},gb={narrow:/^[1234]/i,abbreviated:/^T[1234]/i,wide:/^[1234](º)? trimestre/i},vb={any:[/1/i,/2/i,/3/i,/4/i]},yb={narrow:/^[jfmajsond]/i,abbreviated:/^(jan|fev|mar|abr|mai|jun|jul|ago|set|out|nov|dez)/i,wide:/^(janeiro|fevereiro|março|abril|maio|junho|julho|agosto|setembro|outubro|novembro|dezembro)/i},bb={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^fev/i,/^mar/i,/^abr/i,/^mai/i,/^jun/i,/^jul/i,/^ago/i,/^set/i,/^out/i,/^nov/i,/^dez/i]},wb={narrow:/^(dom|[23456]ª?|s[aá]b)/i,short:/^(dom|[23456]ª?|s[aá]b)/i,abbreviated:/^(dom|seg|ter|qua|qui|sex|s[aá]b)/i,wide:/^(domingo|(segunda|ter[cç]a|quarta|quinta|sexta)([- ]feira)?|s[aá]bado)/i},xb={short:[/^d/i,/^2/i,/^3/i,/^4/i,/^5/i,/^6/i,/^s[aá]/i],narrow:[/^d/i,/^2/i,/^3/i,/^4/i,/^5/i,/^6/i,/^s[aá]/i],any:[/^d/i,/^seg/i,/^t/i,/^qua/i,/^qui/i,/^sex/i,/^s[aá]b/i]},Cb={narrow:/^(a|p|mn|md|(da) (manhã|tarde|noite))/i,any:/^([ap]\.?\s?m\.?|meia[-\s]noite|meio[-\s]dia|(da) (manhã|tarde|noite))/i},Nb={any:{am:/^a/i,pm:/^p/i,midnight:/^mn|^meia[-\s]noite/i,noon:/^md|^meio[-\s]dia/i,morning:/manhã/i,afternoon:/tarde/i,evening:/tarde/i,night:/noite/i}},Mb={ordinalNumber:Ic({matchPattern:fb,parsePattern:mb,valueCallback:e=>parseInt(e,10)}),era:ht({matchPatterns:hb,defaultMatchWidth:"wide",parsePatterns:pb,defaultParseWidth:"any"}),quarter:ht({matchPatterns:gb,defaultMatchWidth:"wide",parsePatterns:vb,defaultParseWidth:"any",valueCallback:e=>e+1}),month:ht({matchPatterns:yb,defaultMatchWidth:"wide",parsePatterns:bb,defaultParseWidth:"any"}),day:ht({matchPatterns:wb,defaultMatchWidth:"wide",parsePatterns:xb,defaultParseWidth:"any"}),dayPeriod:ht({matchPatterns:Cb,defaultMatchWidth:"any",parsePatterns:Nb,defaultParseWidth:"any"})},Sb={code:"pt-BR",formatDistance:Zy,formatLong:nb,formatRelative:ob,localize:db,match:Mb,options:{weekStartsOn:0,firstWeekContainsDate:1}};var U;(function(e){e.Root="root",e.Chevron="chevron",e.Day="day",e.DayButton="day_button",e.CaptionLabel="caption_label",e.Dropdowns="dropdowns",e.Dropdown="dropdown",e.DropdownRoot="dropdown_root",e.Footer="footer",e.MonthGrid="month_grid",e.MonthCaption="month_caption",e.MonthsDropdown="months_dropdown",e.Month="month",e.Months="months",e.Nav="nav",e.NextMonthButton="button_next",e.PreviousMonthButton="button_previous",e.Week="week",e.Weeks="weeks",e.Weekday="weekday",e.Weekdays="weekdays",e.WeekNumber="week_number",e.WeekNumberHeader="week_number_header",e.YearsDropdown="years_dropdown"})(U||(U={}));var be;(function(e){e.disabled="disabled",e.hidden="hidden",e.outside="outside",e.focused="focused",e.today="today"})(be||(be={}));var nt;(function(e){e.range_end="range_end",e.range_middle="range_middle",e.range_start="range_start",e.selected="selected"})(nt||(nt={}));const zo={},_n={};function Rn(e,t){try{const r=(zo[e]||(zo[e]=new Intl.DateTimeFormat("en-GB",{timeZone:e,hour:"numeric",timeZoneName:"longOffset"}).format))(t).split("GMT")[1]||"";return r in _n?_n[r]:$c(r,r.split(":"))}catch{if(e in _n)return _n[e];const n=e==null?void 0:e.match(Eb);return n?$c(e,n.slice(1)):NaN}}const Eb=/([+-]\d\d):?(\d\d)?/;function $c(e,t){const n=+t[0],r=+(t[1]||0);return _n[e]=n>0?n*60+r:n*60-r}class pt extends Date{constructor(...t){super(),t.length>1&&typeof t[t.length-1]=="string"&&(this.timeZone=t.pop()),this.internal=new Date,isNaN(Rn(this.timeZone,this))?this.setTime(NaN):t.length?typeof t[0]=="number"&&(t.length===1||t.length===2&&typeof t[1]!="number")?this.setTime(t[0]):typeof t[0]=="string"?this.setTime(+new Date(t[0])):t[0]instanceof Date?this.setTime(+t[0]):(this.setTime(+new Date(...t)),Lc(this),Ho(this)):this.setTime(Date.now())}static tz(t,...n){return n.length?new pt(...n,t):new pt(Date.now(),t)}withTimeZone(t){return new pt(+this,t)}getTimezoneOffset(){return-Rn(this.timeZone,this)}setTime(t){return Date.prototype.setTime.apply(this,arguments),Ho(this),+this}[Symbol.for("constructDateFrom")](t){return new pt(+new Date(t),this.timeZone)}}const Wc=/^(get|set)(?!UTC)/;Object.getOwnPropertyNames(Date.prototype).forEach(e=>{if(!Wc.test(e))return;const t=e.replace(Wc,"$1UTC");pt.prototype[t]&&(e.startsWith("get")?pt.prototype[e]=function(){return this.internal[t]()}:(pt.prototype[e]=function(){return Date.prototype[t].apply(this.internal,arguments),Pb(this),+this},pt.prototype[t]=function(){return Date.prototype[t].apply(this,arguments),Ho(this),+this}))});function Ho(e){e.internal.setTime(+e),e.internal.setUTCMinutes(e.internal.getUTCMinutes()-e.getTimezoneOffset())}function Pb(e){Date.prototype.setFullYear.call(e,e.internal.getUTCFullYear(),e.internal.getUTCMonth(),e.internal.getUTCDate()),Date.prototype.setHours.call(e,e.internal.getUTCHours(),e.internal.getUTCMinutes(),e.internal.getUTCSeconds(),e.internal.getUTCMilliseconds()),Lc(e)}function Lc(e){const t=Rn(e.timeZone,e),n=new Date(+e);n.setUTCHours(n.getUTCHours()-1);const r=-new Date(+e).getTimezoneOffset(),o=-new Date(+n).getTimezoneOffset(),a=r-o,s=Date.prototype.getHours.apply(e)!==e.internal.getUTCHours();a&&s&&e.internal.setUTCMinutes(e.internal.getUTCMinutes()+a);const i=r-t;i&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+i);const c=Rn(e.timeZone,e),f=-new Date(+e).getTimezoneOffset()-c,m=c!==t,p=f-i;if(m&&p){Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+p);const h=Rn(e.timeZone,e),v=c-h;v&&(e.internal.setUTCMinutes(e.internal.getUTCMinutes()+v),Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+v))}}class Bt extends pt{static tz(t,...n){return n.length?new Bt(...n,t):new Bt(Date.now(),t)}toISOString(){const[t,n,r]=this.tzComponents(),o=`${t}${n}:${r}`;return this.internal.toISOString().slice(0,-1)+o}toString(){return`${this.toDateString()} ${this.toTimeString()}`}toDateString(){const[t,n,r,o]=this.internal.toUTCString().split(" ");return`${t==null?void 0:t.slice(0,-1)} ${r} ${n} ${o}`}toTimeString(){const t=this.internal.toUTCString().split(" ")[4],[n,r,o]=this.tzComponents();return`${t} GMT${n}${r}${o} (${kb(this.timeZone,this)})`}toLocaleString(t,n){return Date.prototype.toLocaleString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}toLocaleDateString(t,n){return Date.prototype.toLocaleDateString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}toLocaleTimeString(t,n){return Date.prototype.toLocaleTimeString.call(this,t,{...n,timeZone:(n==null?void 0:n.timeZone)||this.timeZone})}tzComponents(){const t=this.getTimezoneOffset(),n=t>0?"-":"+",r=String(Math.floor(Math.abs(t)/60)).padStart(2,"0"),o=String(Math.abs(t)%60).padStart(2,"0");return[n,r,o]}withTimeZone(t){return new Bt(+this,t)}[Symbol.for("constructDateFrom")](t){return new Bt(+new Date(t),this.timeZone)}}function kb(e,t){return new Intl.DateTimeFormat("en-GB",{timeZone:e,timeZoneName:"long"}).format(t).slice(12)}function Bc(e,t,n){const r=ve(e,n==null?void 0:n.in);return isNaN(t)?Oe(e,NaN):(t&&r.setDate(r.getDate()+t),r)}function Vc(e,t,n){const r=ve(e,n==null?void 0:n.in);if(isNaN(t))return Oe(e,NaN);if(!t)return r;const o=r.getDate(),a=Oe(e,r.getTime());a.setMonth(r.getMonth()+t+1,0);const s=a.getDate();return o>=s?a:(r.setFullYear(a.getFullYear(),a.getMonth(),o),r)}function In(e,t){return cn(e,{...t,weekStartsOn:1})}function Yc(e,t){const n=ve(e,t==null?void 0:t.in),r=n.getFullYear(),o=Oe(n,0);o.setFullYear(r+1,0,4),o.setHours(0,0,0,0);const a=In(o),s=Oe(n,0);s.setFullYear(r,0,4),s.setHours(0,0,0,0);const i=In(s);return n.getTime()>=a.getTime()?r+1:n.getTime()>=i.getTime()?r:r-1}function Gc(e){const t=ve(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function jn(e,t){const n=ve(e,t==null?void 0:t.in);return n.setHours(0,0,0,0),n}function zc(e,t,n){const[r,o]=sn(n==null?void 0:n.in,e,t),a=jn(r),s=jn(o),i=+a-Gc(a),c=+s-Gc(s);return Math.round((i-c)/xy)}function Tb(e,t){const n=Yc(e,t),r=Oe(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),In(r)}function Db(e,t,n){return Bc(e,t*7,n)}function Ob(e,t,n){return Vc(e,t*12,n)}function Ab(e,t){let n,r=t==null?void 0:t.in;return e.forEach(o=>{!r&&typeof o=="object"&&(r=Oe.bind(null,o));const a=ve(o,r);(!n||n<a||isNaN(+a))&&(n=a)}),Oe(r,n||NaN)}function _b(e,t){let n,r=t==null?void 0:t.in;return e.forEach(o=>{!r&&typeof o=="object"&&(r=Oe.bind(null,o));const a=ve(o,r);(!n||n>a||isNaN(+a))&&(n=a)}),Oe(r,n||NaN)}function Rb(e,t,n){const[r,o]=sn(n==null?void 0:n.in,e,t);return+jn(r)==+jn(o)}function Hc(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Ib(e){return!(!Hc(e)&&typeof e!="number"||isNaN(+ve(e)))}function jb(e,t,n){const[r,o]=sn(n==null?void 0:n.in,e,t),a=r.getFullYear()-o.getFullYear(),s=r.getMonth()-o.getMonth();return a*12+s}function Fb(e,t){const n=ve(e,t==null?void 0:t.in),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function $b(e,t){const[n,r]=sn(e,t.start,t.end);return{start:n,end:r}}function Wb(e,t){const{start:n,end:r}=$b(t==null?void 0:t.in,e);let o=+n>+r;const a=o?+n:+r,s=o?r:n;s.setHours(0,0,0,0),s.setDate(1);let i=1;const c=[];for(;+s<=a;)c.push(Oe(n,s)),s.setMonth(s.getMonth()+i);return o?c.reverse():c}function Lb(e,t){const n=ve(e,t==null?void 0:t.in);return n.setDate(1),n.setHours(0,0,0,0),n}function Bb(e,t){const n=ve(e,t==null?void 0:t.in),r=n.getFullYear();return n.setFullYear(r+1,0,0),n.setHours(23,59,59,999),n}function Uc(e,t){const n=ve(e,t==null?void 0:t.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function Kc(e,t){var i,c,d,f;const n=An(),r=(t==null?void 0:t.weekStartsOn)??((c=(i=t==null?void 0:t.locale)==null?void 0:i.options)==null?void 0:c.weekStartsOn)??n.weekStartsOn??((f=(d=n.locale)==null?void 0:d.options)==null?void 0:f.weekStartsOn)??0,o=ve(e,t==null?void 0:t.in),a=o.getDay(),s=(a<r?-7:0)+6-(a-r);return o.setDate(o.getDate()+s),o.setHours(23,59,59,999),o}function Vb(e,t){return Kc(e,{...t,weekStartsOn:1})}function Yb(e,t){const n=ve(e,t==null?void 0:t.in);return zc(n,Uc(n))+1}function qc(e,t){const n=ve(e,t==null?void 0:t.in),r=+In(n)-+Tb(n);return Math.round(r/jc)+1}function Xc(e,t){var f,m,p,h;const n=ve(e,t==null?void 0:t.in),r=n.getFullYear(),o=An(),a=(t==null?void 0:t.firstWeekContainsDate)??((m=(f=t==null?void 0:t.locale)==null?void 0:f.options)==null?void 0:m.firstWeekContainsDate)??o.firstWeekContainsDate??((h=(p=o.locale)==null?void 0:p.options)==null?void 0:h.firstWeekContainsDate)??1,s=Oe((t==null?void 0:t.in)||e,0);s.setFullYear(r+1,0,a),s.setHours(0,0,0,0);const i=cn(s,t),c=Oe((t==null?void 0:t.in)||e,0);c.setFullYear(r,0,a),c.setHours(0,0,0,0);const d=cn(c,t);return+n>=+i?r+1:+n>=+d?r:r-1}function Gb(e,t){var i,c,d,f;const n=An(),r=(t==null?void 0:t.firstWeekContainsDate)??((c=(i=t==null?void 0:t.locale)==null?void 0:i.options)==null?void 0:c.firstWeekContainsDate)??n.firstWeekContainsDate??((f=(d=n.locale)==null?void 0:d.options)==null?void 0:f.firstWeekContainsDate)??1,o=Xc(e,t),a=Oe((t==null?void 0:t.in)||e,0);return a.setFullYear(o,0,r),a.setHours(0,0,0,0),cn(a,t)}function Qc(e,t){const n=ve(e,t==null?void 0:t.in),r=+cn(n,t)-+Gb(n,t);return Math.round(r/jc)+1}function pe(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const At={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return pe(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):pe(n+1,2)},d(e,t){return pe(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return pe(e.getHours()%12||12,t.length)},H(e,t){return pe(e.getHours(),t.length)},m(e,t){return pe(e.getMinutes(),t.length)},s(e,t){return pe(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),o=Math.trunc(r*Math.pow(10,n-3));return pe(o,t.length)}},ln={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Zc={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),o=r>0?r:1-r;return n.ordinalNumber(o,{unit:"year"})}return At.y(e,t)},Y:function(e,t,n,r){const o=Xc(e,r),a=o>0?o:1-o;if(t==="YY"){const s=a%100;return pe(s,2)}return t==="Yo"?n.ordinalNumber(a,{unit:"year"}):pe(a,t.length)},R:function(e,t){const n=Yc(e);return pe(n,t.length)},u:function(e,t){const n=e.getFullYear();return pe(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return pe(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return pe(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return At.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return pe(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const o=Qc(e,r);return t==="wo"?n.ordinalNumber(o,{unit:"week"}):pe(o,t.length)},I:function(e,t,n){const r=qc(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):pe(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):At.d(e,t)},D:function(e,t,n){const r=Yb(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):pe(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(a);case"ee":return pe(a,2);case"eo":return n.ordinalNumber(a,{unit:"day"});case"eee":return n.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(o,{width:"short",context:"formatting"});case"eeee":default:return n.day(o,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const o=e.getDay(),a=(o-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(a);case"cc":return pe(a,t.length);case"co":return n.ordinalNumber(a,{unit:"day"});case"ccc":return n.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(o,{width:"narrow",context:"standalone"});case"cccccc":return n.day(o,{width:"short",context:"standalone"});case"cccc":default:return n.day(o,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),o=r===0?7:r;switch(t){case"i":return String(o);case"ii":return pe(o,t.length);case"io":return n.ordinalNumber(o,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const o=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let o;switch(r===12?o=ln.noon:r===0?o=ln.midnight:o=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let o;switch(r>=17?o=ln.evening:r>=12?o=ln.afternoon:r>=4?o=ln.morning:o=ln.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(o,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(o,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(o,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return At.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):At.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):pe(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):pe(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):At.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):At.s(e,t)},S:function(e,t){return At.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return el(r);case"XXXX":case"XX":return Vt(r);case"XXXXX":case"XXX":default:return Vt(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return el(r);case"xxxx":case"xx":return Vt(r);case"xxxxx":case"xxx":default:return Vt(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Jc(r,":");case"OOOO":default:return"GMT"+Vt(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Jc(r,":");case"zzzz":default:return"GMT"+Vt(r,":")}},t:function(e,t,n){const r=Math.trunc(+e/1e3);return pe(r,t.length)},T:function(e,t,n){return pe(+e,t.length)}};function Jc(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=Math.trunc(r/60),a=r%60;return a===0?n+String(o):n+String(o)+t+pe(a,2)}function el(e,t){return e%60===0?(e>0?"-":"+")+pe(Math.abs(e)/60,2):Vt(e,t)}function Vt(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),o=pe(Math.trunc(r/60),2),a=pe(r%60,2);return n+o+t+a}const tl=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},nl=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},zb={p:nl,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],o=n[2];if(!o)return tl(e,t);let a;switch(r){case"P":a=t.dateTime({width:"short"});break;case"PP":a=t.dateTime({width:"medium"});break;case"PPP":a=t.dateTime({width:"long"});break;case"PPPP":default:a=t.dateTime({width:"full"});break}return a.replace("{{date}}",tl(r,t)).replace("{{time}}",nl(o,t))}},Hb=/^D+$/,Ub=/^Y+$/,Kb=["D","DD","YY","YYYY"];function qb(e){return Hb.test(e)}function Xb(e){return Ub.test(e)}function Qb(e,t,n){const r=Zb(e,t,n);if(console.warn(r),Kb.includes(e))throw new RangeError(r)}function Zb(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const Jb=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,ew=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,tw=/^'([^]*?)'?$/,nw=/''/g,rw=/[a-zA-Z]/;function ow(e,t,n){var f,m,p,h,v,g,y,w;const r=An(),o=(n==null?void 0:n.locale)??r.locale??kr,a=(n==null?void 0:n.firstWeekContainsDate)??((m=(f=n==null?void 0:n.locale)==null?void 0:f.options)==null?void 0:m.firstWeekContainsDate)??r.firstWeekContainsDate??((h=(p=r.locale)==null?void 0:p.options)==null?void 0:h.firstWeekContainsDate)??1,s=(n==null?void 0:n.weekStartsOn)??((g=(v=n==null?void 0:n.locale)==null?void 0:v.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((w=(y=r.locale)==null?void 0:y.options)==null?void 0:w.weekStartsOn)??0,i=ve(e,n==null?void 0:n.in);if(!Ib(i))throw new RangeError("Invalid time value");let c=t.match(ew).map(b=>{const C=b[0];if(C==="p"||C==="P"){const M=zb[C];return M(b,o.formatLong)}return b}).join("").match(Jb).map(b=>{if(b==="''")return{isToken:!1,value:"'"};const C=b[0];if(C==="'")return{isToken:!1,value:aw(b)};if(Zc[C])return{isToken:!0,value:b};if(C.match(rw))throw new RangeError("Format string contains an unescaped latin alphabet character `"+C+"`");return{isToken:!1,value:b}});o.localize.preprocessor&&(c=o.localize.preprocessor(i,c));const d={firstWeekContainsDate:a,weekStartsOn:s,locale:o};return c.map(b=>{if(!b.isToken)return b.value;const C=b.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&Xb(C)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&qb(C))&&Qb(C,t,String(e));const M=Zc[C[0]];return M(i,C,o.localize,d)}).join("")}function aw(e){const t=e.match(tw);return t?t[1].replace(nw,"'"):e}function sw(e,t){const n=ve(e,t==null?void 0:t.in),r=n.getFullYear(),o=n.getMonth(),a=Oe(n,0);return a.setFullYear(r,o+1,0),a.setHours(0,0,0,0),a.getDate()}function iw(e,t){return ve(e,t==null?void 0:t.in).getMonth()}function cw(e,t){return ve(e,t==null?void 0:t.in).getFullYear()}function lw(e,t){return+ve(e)>+ve(t)}function uw(e,t){return+ve(e)<+ve(t)}function dw(e,t,n){const[r,o]=sn(n==null?void 0:n.in,e,t);return r.getFullYear()===o.getFullYear()&&r.getMonth()===o.getMonth()}function fw(e,t,n){const[r,o]=sn(n==null?void 0:n.in,e,t);return r.getFullYear()===o.getFullYear()}function mw(e,t,n){const r=ve(e,n==null?void 0:n.in),o=r.getFullYear(),a=r.getDate(),s=Oe(e,0);s.setFullYear(o,t,15),s.setHours(0,0,0,0);const i=sw(s);return r.setMonth(t,Math.min(a,i)),r}function hw(e,t,n){const r=ve(e,n==null?void 0:n.in);return isNaN(+r)?Oe(e,NaN):(r.setFullYear(t),r)}const rl=5,pw=4;function gw(e,t){const n=t.startOfMonth(e),r=n.getDay()>0?n.getDay():7,o=t.addDays(e,-r+1),a=t.addDays(o,rl*7-1);return t.getMonth(e)===t.getMonth(a)?rl:pw}function ol(e,t){const n=t.startOfMonth(e),r=n.getDay();return r===1?n:r===0?t.addDays(n,-1*6):t.addDays(n,-1*(r-1))}function vw(e,t){const n=ol(e,t),r=gw(e,t);return t.addDays(n,r*7-1)}class wt{constructor(t,n){this.Date=Date,this.today=()=>{var r;return(r=this.overrides)!=null&&r.today?this.overrides.today():this.options.timeZone?Bt.tz(this.options.timeZone):new this.Date},this.newDate=(r,o,a)=>{var s;return(s=this.overrides)!=null&&s.newDate?this.overrides.newDate(r,o,a):this.options.timeZone?new Bt(r,o,a,this.options.timeZone):new Date(r,o,a)},this.addDays=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addDays?this.overrides.addDays(r,o):Bc(r,o)},this.addMonths=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addMonths?this.overrides.addMonths(r,o):Vc(r,o)},this.addWeeks=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addWeeks?this.overrides.addWeeks(r,o):Db(r,o)},this.addYears=(r,o)=>{var a;return(a=this.overrides)!=null&&a.addYears?this.overrides.addYears(r,o):Ob(r,o)},this.differenceInCalendarDays=(r,o)=>{var a;return(a=this.overrides)!=null&&a.differenceInCalendarDays?this.overrides.differenceInCalendarDays(r,o):zc(r,o)},this.differenceInCalendarMonths=(r,o)=>{var a;return(a=this.overrides)!=null&&a.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(r,o):jb(r,o)},this.eachMonthOfInterval=r=>{var o;return(o=this.overrides)!=null&&o.eachMonthOfInterval?this.overrides.eachMonthOfInterval(r):Wb(r)},this.endOfBroadcastWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(r,this):vw(r,this)},this.endOfISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfISOWeek?this.overrides.endOfISOWeek(r):Vb(r)},this.endOfMonth=r=>{var o;return(o=this.overrides)!=null&&o.endOfMonth?this.overrides.endOfMonth(r):Fb(r)},this.endOfWeek=r=>{var o;return(o=this.overrides)!=null&&o.endOfWeek?this.overrides.endOfWeek(r,this.options):Kc(r,this.options)},this.endOfYear=r=>{var o;return(o=this.overrides)!=null&&o.endOfYear?this.overrides.endOfYear(r):Bb(r)},this.format=(r,o)=>{var s;const a=(s=this.overrides)!=null&&s.format?this.overrides.format(r,o,this.options):ow(r,o,this.options);return this.options.numerals&&this.options.numerals!=="latn"?this.replaceDigits(a):a},this.getISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.getISOWeek?this.overrides.getISOWeek(r):qc(r)},this.getMonth=r=>{var o;return(o=this.overrides)!=null&&o.getMonth?this.overrides.getMonth(r,this.options):iw(r,this.options)},this.getYear=r=>{var o;return(o=this.overrides)!=null&&o.getYear?this.overrides.getYear(r,this.options):cw(r,this.options)},this.getWeek=r=>{var o;return(o=this.overrides)!=null&&o.getWeek?this.overrides.getWeek(r,this.options):Qc(r,this.options)},this.isAfter=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isAfter?this.overrides.isAfter(r,o):lw(r,o)},this.isBefore=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isBefore?this.overrides.isBefore(r,o):uw(r,o)},this.isDate=r=>{var o;return(o=this.overrides)!=null&&o.isDate?this.overrides.isDate(r):Hc(r)},this.isSameDay=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isSameDay?this.overrides.isSameDay(r,o):Rb(r,o)},this.isSameMonth=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isSameMonth?this.overrides.isSameMonth(r,o):dw(r,o)},this.isSameYear=(r,o)=>{var a;return(a=this.overrides)!=null&&a.isSameYear?this.overrides.isSameYear(r,o):fw(r,o)},this.max=r=>{var o;return(o=this.overrides)!=null&&o.max?this.overrides.max(r):Ab(r)},this.min=r=>{var o;return(o=this.overrides)!=null&&o.min?this.overrides.min(r):_b(r)},this.setMonth=(r,o)=>{var a;return(a=this.overrides)!=null&&a.setMonth?this.overrides.setMonth(r,o):mw(r,o)},this.setYear=(r,o)=>{var a;return(a=this.overrides)!=null&&a.setYear?this.overrides.setYear(r,o):hw(r,o)},this.startOfBroadcastWeek=r=>{var o;return(o=this.overrides)!=null&&o.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(r,this):ol(r,this)},this.startOfDay=r=>{var o;return(o=this.overrides)!=null&&o.startOfDay?this.overrides.startOfDay(r):jn(r)},this.startOfISOWeek=r=>{var o;return(o=this.overrides)!=null&&o.startOfISOWeek?this.overrides.startOfISOWeek(r):In(r)},this.startOfMonth=r=>{var o;return(o=this.overrides)!=null&&o.startOfMonth?this.overrides.startOfMonth(r):Lb(r)},this.startOfWeek=r=>{var o;return(o=this.overrides)!=null&&o.startOfWeek?this.overrides.startOfWeek(r,this.options):cn(r,this.options)},this.startOfYear=r=>{var o;return(o=this.overrides)!=null&&o.startOfYear?this.overrides.startOfYear(r):Uc(r)},this.options={locale:kr,...t},this.overrides=n}getDigitMap(){const{numerals:t="latn"}=this.options,n=new Intl.NumberFormat("en-US",{numberingSystem:t}),r={};for(let o=0;o<10;o++)r[o.toString()]=n.format(o);return r}replaceDigits(t){const n=this.getDigitMap();return t.replace(/\d/g,r=>n[r]||r)}formatNumber(t){return this.replaceDigits(t.toString())}}const xt=new wt;function yw(e,t,n={}){return Object.entries(e).filter(([,o])=>o===!0).reduce((o,[a])=>(n[a]?o.push(n[a]):t[be[a]]?o.push(t[be[a]]):t[nt[a]]&&o.push(t[nt[a]]),o),[t[U.Day]])}function bw(e){return x.createElement("button",{...e})}function ww(e){return x.createElement("span",{...e})}function xw(e){const{size:t=24,orientation:n="left",className:r}=e;return x.createElement("svg",{className:r,width:t,height:t,viewBox:"0 0 24 24"},n==="up"&&x.createElement("polygon",{points:"6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28"}),n==="down"&&x.createElement("polygon",{points:"6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72"}),n==="left"&&x.createElement("polygon",{points:"16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20"}),n==="right"&&x.createElement("polygon",{points:"8 18.612 14.1888889 12.5 8 6.37733333 9.91111111 4.5 18 12.5 9.91111111 20.5"}))}function Cw(e){const{day:t,modifiers:n,...r}=e;return x.createElement("td",{...r})}function Nw(e){const{day:t,modifiers:n,...r}=e,o=x.useRef(null);return x.useEffect(()=>{var a;n.focused&&((a=o.current)==null||a.focus())},[n.focused]),x.createElement("button",{ref:o,...r})}function Mw(e){const{options:t,className:n,components:r,classNames:o,...a}=e,s=[o[U.Dropdown],n].join(" "),i=t==null?void 0:t.find(({value:c})=>c===a.value);return x.createElement("span",{"data-disabled":a.disabled,className:o[U.DropdownRoot]},x.createElement(r.Select,{className:s,...a},t==null?void 0:t.map(({value:c,label:d,disabled:f})=>x.createElement(r.Option,{key:c,value:c,disabled:f},d))),x.createElement("span",{className:o[U.CaptionLabel],"aria-hidden":!0},i==null?void 0:i.label,x.createElement(r.Chevron,{orientation:"down",size:18,className:o[U.Chevron]})))}function Sw(e){return x.createElement("div",{...e})}function Ew(e){return x.createElement("div",{...e})}function Pw(e){const{calendarMonth:t,displayIndex:n,...r}=e;return x.createElement("div",{...r},e.children)}function kw(e){const{calendarMonth:t,displayIndex:n,...r}=e;return x.createElement("div",{...r})}function Tw(e){return x.createElement("table",{...e})}function Dw(e){return x.createElement("div",{...e})}const al=x.createContext(void 0);function Fn(){const e=x.useContext(al);if(e===void 0)throw new Error("useDayPicker() must be used within a custom component.");return e}function Ow(e){const{components:t}=Fn();return x.createElement(t.Dropdown,{...e})}function Aw(e){const{onPreviousClick:t,onNextClick:n,previousMonth:r,nextMonth:o,...a}=e,{components:s,classNames:i,labels:{labelPrevious:c,labelNext:d}}=Fn();return x.createElement("nav",{...a},x.createElement(s.PreviousMonthButton,{type:"button",className:i[U.PreviousMonthButton],tabIndex:r?void 0:-1,disabled:r?void 0:!0,"aria-label":c(r),onClick:e.onPreviousClick},x.createElement(s.Chevron,{disabled:r?void 0:!0,className:i[U.Chevron],orientation:"left"})),x.createElement(s.NextMonthButton,{type:"button",className:i[U.NextMonthButton],tabIndex:o?void 0:-1,disabled:o?void 0:!0,"aria-label":d(o),onClick:e.onNextClick},x.createElement(s.Chevron,{disabled:o?void 0:!0,orientation:"right",className:i[U.Chevron]})))}function _w(e){const{components:t}=Fn();return x.createElement(t.Button,{...e})}function Rw(e){return x.createElement("option",{...e})}function Iw(e){const{components:t}=Fn();return x.createElement(t.Button,{...e})}function jw(e){return x.createElement("div",{...e})}function Fw(e){return x.createElement("select",{...e})}function $w(e){const{week:t,...n}=e;return x.createElement("tr",{...n})}function Ww(e){return x.createElement("th",{...e})}function Lw(e){return x.createElement("thead",{"aria-hidden":!0},x.createElement("tr",{...e}))}function Bw(e){const{week:t,...n}=e;return x.createElement("th",{...n})}function Vw(e){return x.createElement("th",{...e})}function Yw(e){return x.createElement("tbody",{...e})}function Gw(e){const{components:t}=Fn();return x.createElement(t.Dropdown,{...e})}const zw=Object.freeze(Object.defineProperty({__proto__:null,Button:bw,CaptionLabel:ww,Chevron:xw,Day:Cw,DayButton:Nw,Dropdown:Mw,DropdownNav:Sw,Footer:Ew,Month:Pw,MonthCaption:kw,MonthGrid:Tw,Months:Dw,MonthsDropdown:Ow,Nav:Aw,NextMonthButton:_w,Option:Rw,PreviousMonthButton:Iw,Root:jw,Select:Fw,Week:$w,WeekNumber:Bw,WeekNumberHeader:Vw,Weekday:Ww,Weekdays:Lw,Weeks:Yw,YearsDropdown:Gw},Symbol.toStringTag,{value:"Module"}));function Hw(e){return{...zw,...e}}function Uw(e){const t={"data-mode":e.mode??void 0,"data-required":"required"in e?e.required:void 0,"data-multiple-months":e.numberOfMonths&&e.numberOfMonths>1||void 0,"data-week-numbers":e.showWeekNumber||void 0,"data-broadcast-calendar":e.broadcastCalendar||void 0};return Object.entries(e).forEach(([n,r])=>{n.startsWith("data-")&&(t[n]=r)}),t}function Kw(){const e={};for(const t in U)e[U[t]]=`rdp-${U[t]}`;for(const t in be)e[be[t]]=`rdp-${be[t]}`;for(const t in nt)e[nt[t]]=`rdp-${nt[t]}`;return e}function sl(e,t,n){return(n??new wt(t)).format(e,"LLLL y")}const qw=sl;function Xw(e,t,n){return(n??new wt(t)).format(e,"d")}function Qw(e,t=xt){return t.format(e,"LLLL")}function Zw(e){return e<10?`0${e.toLocaleString()}`:`${e.toLocaleString()}`}function Jw(){return""}function ex(e,t,n){return(n??new wt(t)).format(e,"cccccc")}function il(e,t=xt){return t.format(e,"yyyy")}const tx=Object.freeze(Object.defineProperty({__proto__:null,formatCaption:sl,formatDay:Xw,formatMonthCaption:qw,formatMonthDropdown:Qw,formatWeekNumber:Zw,formatWeekNumberHeader:Jw,formatWeekdayName:ex,formatYearCaption:il,formatYearDropdown:il},Symbol.toStringTag,{value:"Module"}));function nx(e){return e!=null&&e.formatMonthCaption&&!e.formatCaption&&(e.formatCaption=e.formatMonthCaption),e!=null&&e.formatYearCaption&&!e.formatYearDropdown&&(e.formatYearDropdown=e.formatYearCaption),{...tx,...e}}function rx(e,t,n,r,o){const{startOfMonth:a,startOfYear:s,endOfYear:i,eachMonthOfInterval:c,getMonth:d}=o;return c({start:s(e),end:i(e)}).map(p=>{const h=r.formatMonthDropdown(p,o),v=d(p),g=t&&p<a(t)||n&&p>a(n)||!1;return{value:v,label:h,disabled:g}})}function ox(e,t={},n={}){let r={...t==null?void 0:t[U.Day]};return Object.entries(e).filter(([,o])=>o===!0).forEach(([o])=>{r={...r,...n==null?void 0:n[o]}}),r}function ax(e,t,n){const r=e.today(),o=t?e.startOfISOWeek(r):e.startOfWeek(r),a=[];for(let s=0;s<7;s++){const i=e.addDays(o,s);a.push(i)}return a}function sx(e,t,n,r){if(!e||!t)return;const{startOfYear:o,endOfYear:a,addYears:s,getYear:i,isBefore:c,isSameYear:d}=r,f=o(e),m=a(t),p=[];let h=f;for(;c(h,m)||d(h,m);)p.push(h),h=s(h,1);return p.map(v=>{const g=n.formatYearDropdown(v,r);return{value:i(v),label:g,disabled:!1}})}function cl(e,t,n){return(n??new wt(t)).format(e,"LLLL y")}const ix=cl;function cx(e,t,n,r){let o=(r??new wt(n)).format(e,"PPPP");return t!=null&&t.today&&(o=`Today, ${o}`),o}function ll(e,t,n,r){let o=(r??new wt(n)).format(e,"PPPP");return t.today&&(o=`Today, ${o}`),t.selected&&(o=`${o}, selected`),o}const lx=ll;function ux(){return""}function dx(e){return"Choose the Month"}function fx(e){return"Go to the Next Month"}function mx(e){return"Go to the Previous Month"}function hx(e,t,n){return(n??new wt(t)).format(e,"cccc")}function px(e,t){return`Week ${e}`}function gx(e){return"Week Number"}function vx(e){return"Choose the Year"}const yx=Object.freeze(Object.defineProperty({__proto__:null,labelCaption:ix,labelDay:lx,labelDayButton:ll,labelGrid:cl,labelGridcell:cx,labelMonthDropdown:dx,labelNav:ux,labelNext:fx,labelPrevious:mx,labelWeekNumber:px,labelWeekNumberHeader:gx,labelWeekday:hx,labelYearDropdown:vx},Symbol.toStringTag,{value:"Module"}));function bx(e,t,n,r){const o=e[0],a=e[e.length-1],{ISOWeek:s,fixedWeeks:i,broadcastCalendar:c}=n??{},{addDays:d,differenceInCalendarDays:f,differenceInCalendarMonths:m,endOfBroadcastWeek:p,endOfISOWeek:h,endOfMonth:v,endOfWeek:g,isAfter:y,startOfBroadcastWeek:w,startOfISOWeek:b,startOfWeek:C}=r,M=c?w(o,r):s?b(o):C(o),S=c?p(a,r):s?h(v(a)):g(v(a)),k=f(S,M),P=m(a,o)+1,D=[];for(let V=0;V<=k;V++){const _=d(M,V);if(t&&y(_,t))break;D.push(_)}const $=(c?35:42)*P;if(i&&D.length<$){const V=$-D.length;for(let _=0;_<V;_++){const z=d(D[D.length-1],1);D.push(z)}}return D}function wx(e){const t=[];return e.reduce((n,r)=>{const o=[],a=r.weeks.reduce((s,i)=>[...s,...i.days],o);return[...n,...a]},t)}function xx(e,t,n,r){const{numberOfMonths:o=1}=n,a=[];for(let s=0;s<o;s++){const i=r.addMonths(e,s);if(t&&i>t)break;a.push(i)}return a}function ul(e,t){const{month:n,defaultMonth:r,today:o=t.today(),numberOfMonths:a=1,endMonth:s,startMonth:i}=e;let c=n||r||o;const{differenceInCalendarMonths:d,addMonths:f,startOfMonth:m}=t;if(s&&d(s,c)<0){const p=-1*(a-1);c=f(s,p)}return i&&d(c,i)<0&&(c=i),m(c)}class dl{constructor(t,n,r=xt){this.date=t,this.displayMonth=n,this.outside=!!(n&&!r.isSameMonth(t,n)),this.dateLib=r}isEqualTo(t){return this.dateLib.isSameDay(t.date,this.date)&&this.dateLib.isSameMonth(t.displayMonth,this.displayMonth)}}class Cx{constructor(t,n){this.date=t,this.weeks=n}}class Nx{constructor(t,n){this.days=n,this.weekNumber=t}}function Mx(e,t,n,r){const{addDays:o,endOfBroadcastWeek:a,endOfISOWeek:s,endOfMonth:i,endOfWeek:c,getISOWeek:d,getWeek:f,startOfBroadcastWeek:m,startOfISOWeek:p,startOfWeek:h}=r,v=e.reduce((g,y)=>{const w=n.broadcastCalendar?m(y,r):n.ISOWeek?p(y):h(y),b=n.broadcastCalendar?a(y,r):n.ISOWeek?s(i(y)):c(i(y)),C=t.filter(P=>P>=w&&P<=b),M=n.broadcastCalendar?35:42;if(n.fixedWeeks&&C.length<M){const P=t.filter(D=>{const R=M-C.length;return D>b&&D<=o(b,R)});C.push(...P)}const S=C.reduce((P,D)=>{const R=n.ISOWeek?d(D):f(D),$=P.find(_=>_.weekNumber===R),V=new dl(D,y,r);return $?$.days.push(V):P.push(new Nx(R,[V])),P},[]),k=new Cx(y,S);return g.push(k),g},[]);return n.reverseMonths?v.reverse():v}function Sx(e,t){let{startMonth:n,endMonth:r}=e;const{startOfYear:o,startOfDay:a,startOfMonth:s,endOfMonth:i,addYears:c,endOfYear:d,newDate:f,today:m}=t,{fromYear:p,toYear:h,fromMonth:v,toMonth:g}=e;!n&&v&&(n=v),!n&&p&&(n=t.newDate(p,0,1)),!r&&g&&(r=g),!r&&h&&(r=f(h,11,31));const y=e.captionLayout==="dropdown"||e.captionLayout==="dropdown-years";return n?n=s(n):p?n=f(p,0,1):!n&&y&&(n=o(c(e.today??m(),-100))),r?r=i(r):h?r=f(h,11,31):!r&&y&&(r=d(e.today??m())),[n&&a(n),r&&a(r)]}function Ex(e,t,n,r){if(n.disableNavigation)return;const{pagedNavigation:o,numberOfMonths:a=1}=n,{startOfMonth:s,addMonths:i,differenceInCalendarMonths:c}=r,d=o?a:1,f=s(e);if(!t)return i(f,d);if(!(c(t,e)<a))return i(f,d)}function Px(e,t,n,r){if(n.disableNavigation)return;const{pagedNavigation:o,numberOfMonths:a}=n,{startOfMonth:s,addMonths:i,differenceInCalendarMonths:c}=r,d=o?a??1:1,f=s(e);if(!t)return i(f,-d);if(!(c(f,t)<=0))return i(f,-d)}function kx(e){const t=[];return e.reduce((n,r)=>[...n,...r.weeks],t)}function Tr(e,t){const[n,r]=x.useState(e);return[t===void 0?n:t,r]}function Tx(e,t){const[n,r]=Sx(e,t),{startOfMonth:o,endOfMonth:a}=t,s=ul(e,t),[i,c]=Tr(s,e.month?o(e.month):void 0);x.useEffect(()=>{const k=ul(e,t);c(k)},[e.timeZone]);const d=xx(i,r,e,t),f=bx(d,e.endMonth?a(e.endMonth):void 0,e,t),m=Mx(d,f,e,t),p=kx(m),h=wx(m),v=Px(i,n,e,t),g=Ex(i,r,e,t),{disableNavigation:y,onMonthChange:w}=e,b=k=>p.some(P=>P.days.some(D=>D.isEqualTo(k))),C=k=>{if(y)return;let P=o(k);n&&P<o(n)&&(P=o(n)),r&&P>o(r)&&(P=o(r)),c(P),w==null||w(P)};return{months:m,weeks:p,days:h,navStart:n,navEnd:r,previousMonth:v,nextMonth:g,goToMonth:C,goToDay:k=>{b(k)||C(k.date)}}}function Dx(e,t,n,r){let o,a=0,s=!1;for(;a<e.length&&!s;){const i=e[a],c=t(i);!c[be.disabled]&&!c[be.hidden]&&!c[be.outside]&&(c[be.focused]||r!=null&&r.isEqualTo(i)||n(i.date)||c[be.today])&&(o=i,s=!0),a++}return o||(o=e.find(i=>{const c=t(i);return!c[be.disabled]&&!c[be.hidden]&&!c[be.outside]})),o}function Ct(e,t,n=!1,r=xt){let{from:o,to:a}=e;const{differenceInCalendarDays:s,isSameDay:i}=r;return o&&a?(s(a,o)<0&&([o,a]=[a,o]),s(t,o)>=(n?1:0)&&s(a,t)>=(n?1:0)):!n&&a?i(a,t):!n&&o?i(o,t):!1}function fl(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function Uo(e){return!!(e&&typeof e=="object"&&"from"in e)}function ml(e){return!!(e&&typeof e=="object"&&"after"in e)}function hl(e){return!!(e&&typeof e=="object"&&"before"in e)}function pl(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function gl(e,t){return Array.isArray(e)&&e.every(t.isDate)}function Nt(e,t,n=xt){const r=Array.isArray(t)?t:[t],{isSameDay:o,differenceInCalendarDays:a,isAfter:s}=n;return r.some(i=>{if(typeof i=="boolean")return i;if(n.isDate(i))return o(e,i);if(gl(i,n))return i.includes(e);if(Uo(i))return Ct(i,e,!1,n);if(pl(i))return Array.isArray(i.dayOfWeek)?i.dayOfWeek.includes(e.getDay()):i.dayOfWeek===e.getDay();if(fl(i)){const c=a(i.before,e),d=a(i.after,e),f=c>0,m=d<0;return s(i.before,i.after)?m&&f:f||m}return ml(i)?a(e,i.after)>0:hl(i)?a(i.before,e)>0:typeof i=="function"?i(e):!1})}function Ox(e,t,n,r,o,a,s){const{ISOWeek:i,broadcastCalendar:c}=a,{addDays:d,addMonths:f,addWeeks:m,addYears:p,endOfBroadcastWeek:h,endOfISOWeek:v,endOfWeek:g,max:y,min:w,startOfBroadcastWeek:b,startOfISOWeek:C,startOfWeek:M}=s;let k={day:d,week:m,month:f,year:p,startOfWeek:P=>c?b(P,s):i?C(P):M(P),endOfWeek:P=>c?h(P,s):i?v(P):g(P)}[e](n,t==="after"?1:-1);return t==="before"&&r?k=y([r,k]):t==="after"&&o&&(k=w([o,k])),k}function vl(e,t,n,r,o,a,s,i=0){if(i>365)return;const c=Ox(e,t,n.date,r,o,a,s),d=!!(a.disabled&&Nt(c,a.disabled,s)),f=!!(a.hidden&&Nt(c,a.hidden,s)),m=c,p=new dl(c,m,s);return!d&&!f?p:vl(e,t,p,r,o,a,s,i+1)}function Ax(e,t,n,r,o){const{autoFocus:a}=e,[s,i]=x.useState(),c=Dx(t.days,n,r||(()=>!1),s),[d,f]=x.useState(a?c:void 0);return{isFocusTarget:g=>!!(c!=null&&c.isEqualTo(g)),setFocused:f,focused:d,blur:()=>{i(d),f(void 0)},moveFocus:(g,y)=>{if(!d)return;const w=vl(g,y,d,t.navStart,t.navEnd,e,o);w&&(t.goToDay(w),f(w))}}}function _x(e,t,n){const{disabled:r,hidden:o,modifiers:a,showOutsideDays:s,broadcastCalendar:i,today:c}=t,{isSameDay:d,isSameMonth:f,startOfMonth:m,isBefore:p,endOfMonth:h,isAfter:v}=n,g=t.startMonth&&m(t.startMonth),y=t.endMonth&&h(t.endMonth),w={[be.focused]:[],[be.outside]:[],[be.disabled]:[],[be.hidden]:[],[be.today]:[]},b={};for(const C of e){const{date:M,displayMonth:S}=C,k=!!(S&&!f(M,S)),P=!!(g&&p(M,g)),D=!!(y&&v(M,y)),R=!!(r&&Nt(M,r,n)),$=!!(o&&Nt(M,o,n))||P||D||!i&&!s&&k||i&&s===!1&&k,V=d(M,c??n.today());k&&w.outside.push(C),R&&w.disabled.push(C),$&&w.hidden.push(C),V&&w.today.push(C),a&&Object.keys(a).forEach(_=>{const z=a==null?void 0:a[_];z&&Nt(M,z,n)&&(b[_]?b[_].push(C):b[_]=[C])})}return C=>{const M={[be.focused]:!1,[be.disabled]:!1,[be.hidden]:!1,[be.outside]:!1,[be.today]:!1},S={};for(const k in w){const P=w[k];M[k]=P.some(D=>D===C)}for(const k in b)S[k]=b[k].some(P=>P===C);return{...M,...S}}}function Rx(e,t){const{selected:n,required:r,onSelect:o}=e,[a,s]=Tr(n,o?n:void 0),i=o?n:a,{isSameDay:c}=t,d=h=>(i==null?void 0:i.some(v=>c(v,h)))??!1,{min:f,max:m}=e;return{selected:i,select:(h,v,g)=>{let y=[...i??[]];if(d(h)){if((i==null?void 0:i.length)===f||r&&(i==null?void 0:i.length)===1)return;y=i==null?void 0:i.filter(w=>!c(w,h))}else(i==null?void 0:i.length)===m?y=[h]:y=[...y,h];return o||s(y),o==null||o(y,h,v,g),y},isSelected:d}}function Ix(e,t,n=0,r=0,o=!1,a=xt){const{from:s,to:i}=t||{},{isSameDay:c,isAfter:d,isBefore:f}=a;let m;if(!s&&!i)m={from:e,to:n>0?void 0:e};else if(s&&!i)c(s,e)?o?m={from:s,to:void 0}:m=void 0:f(e,s)?m={from:e,to:s}:m={from:s,to:e};else if(s&&i)if(c(s,e)&&c(i,e))o?m={from:s,to:i}:m=void 0;else if(c(s,e))m={from:s,to:n>0?void 0:e};else if(c(i,e))m={from:e,to:n>0?void 0:e};else if(f(e,s))m={from:e,to:i};else if(d(e,s))m={from:s,to:e};else if(d(e,i))m={from:s,to:e};else throw new Error("Invalid range");if(m!=null&&m.from&&(m!=null&&m.to)){const p=a.differenceInCalendarDays(m.to,m.from);r>0&&p>r?m={from:e,to:void 0}:n>1&&p<n&&(m={from:e,to:void 0})}return m}function jx(e,t,n=xt){const r=Array.isArray(t)?t:[t];let o=e.from;const a=n.differenceInCalendarDays(e.to,e.from),s=Math.min(a,6);for(let i=0;i<=s;i++){if(r.includes(o.getDay()))return!0;o=n.addDays(o,1)}return!1}function yl(e,t,n=xt){return Ct(e,t.from,!1,n)||Ct(e,t.to,!1,n)||Ct(t,e.from,!1,n)||Ct(t,e.to,!1,n)}function Fx(e,t,n=xt){const r=Array.isArray(t)?t:[t];if(r.filter(i=>typeof i!="function").some(i=>typeof i=="boolean"?i:n.isDate(i)?Ct(e,i,!1,n):gl(i,n)?i.some(c=>Ct(e,c,!1,n)):Uo(i)?i.from&&i.to?yl(e,{from:i.from,to:i.to},n):!1:pl(i)?jx(e,i.dayOfWeek,n):fl(i)?n.isAfter(i.before,i.after)?yl(e,{from:n.addDays(i.after,1),to:n.addDays(i.before,-1)},n):Nt(e.from,i,n)||Nt(e.to,i,n):ml(i)||hl(i)?Nt(e.from,i,n)||Nt(e.to,i,n):!1))return!0;const s=r.filter(i=>typeof i=="function");if(s.length){let i=e.from;const c=n.differenceInCalendarDays(e.to,e.from);for(let d=0;d<=c;d++){if(s.some(f=>f(i)))return!0;i=n.addDays(i,1)}}return!1}function $x(e,t){const{disabled:n,excludeDisabled:r,selected:o,required:a,onSelect:s}=e,[i,c]=Tr(o,s?o:void 0),d=s?o:i;return{selected:d,select:(p,h,v)=>{const{min:g,max:y}=e,w=p?Ix(p,d,g,y,a,t):void 0;return r&&n&&(w!=null&&w.from)&&w.to&&Fx({from:w.from,to:w.to},n,t)&&(w.from=p,w.to=void 0),s||c(w),s==null||s(w,p,h,v),w},isSelected:p=>d&&Ct(d,p,!1,t)}}function Wx(e,t){const{selected:n,required:r,onSelect:o}=e,[a,s]=Tr(n,o?n:void 0),i=o?n:a,{isSameDay:c}=t;return{selected:i,select:(m,p,h)=>{let v=m;return!r&&i&&i&&c(m,i)&&(v=void 0),o||s(v),o==null||o(v,m,p,h),v},isSelected:m=>i?c(i,m):!1}}function Lx(e,t){const n=Wx(e,t),r=Rx(e,t),o=$x(e,t);switch(e.mode){case"single":return n;case"multiple":return r;case"range":return o;default:return}}function Bx(e){const{components:t,formatters:n,labels:r,dateLib:o,locale:a,classNames:s}=x.useMemo(()=>{const J={...kr,...e.locale};return{dateLib:new wt({locale:J,weekStartsOn:e.broadcastCalendar?1:e.weekStartsOn,firstWeekContainsDate:e.firstWeekContainsDate,useAdditionalWeekYearTokens:e.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:e.useAdditionalDayOfYearTokens,timeZone:e.timeZone,numerals:e.numerals},e.dateLib),components:Hw(e.components),formatters:nx(e.formatters),labels:{...yx,...e.labels},locale:J,classNames:{...Kw(),...e.classNames}}},[e.locale,e.broadcastCalendar,e.weekStartsOn,e.firstWeekContainsDate,e.useAdditionalWeekYearTokens,e.useAdditionalDayOfYearTokens,e.timeZone,e.numerals,e.dateLib,e.components,e.formatters,e.labels,e.classNames]),{captionLayout:i,mode:c,onDayBlur:d,onDayClick:f,onDayFocus:m,onDayKeyDown:p,onDayMouseEnter:h,onDayMouseLeave:v,onNextClick:g,onPrevClick:y,showWeekNumber:w,styles:b}=e,{formatCaption:C,formatDay:M,formatMonthDropdown:S,formatWeekNumber:k,formatWeekNumberHeader:P,formatWeekdayName:D,formatYearDropdown:R}=n,$=Tx(e,o),{days:V,months:_,navStart:z,navEnd:G,previousMonth:ee,nextMonth:W,goToMonth:Y}=$,L=_x(V,e,o),{isSelected:T,select:H,selected:q}=Lx(e,o)??{},{blur:X,focused:K,isFocusTarget:Z,moveFocus:me,setFocused:ge}=Ax(e,$,L,T??(()=>!1),o),{labelDayButton:I,labelGridcell:ie,labelGrid:ce,labelMonthDropdown:oe,labelNav:se,labelWeekday:le,labelWeekNumber:Me,labelWeekNumberHeader:Re,labelYearDropdown:$e}=r,ot=x.useMemo(()=>ax(o,e.ISOWeek),[o,e.ISOWeek]),Be=c!==void 0||f!==void 0,at=x.useCallback(()=>{ee&&(Y(ee),y==null||y(ee))},[ee,Y,y]),Xe=x.useCallback(()=>{W&&(Y(W),g==null||g(W))},[Y,W,g]),st=x.useCallback((J,ue)=>de=>{de.preventDefault(),de.stopPropagation(),ge(J),H==null||H(J.date,ue,de),f==null||f(J.date,ue,de)},[H,f,ge]),N=x.useCallback((J,ue)=>de=>{ge(J),m==null||m(J.date,ue,de)},[m,ge]),B=x.useCallback((J,ue)=>de=>{X(),d==null||d(J.date,ue,de)},[X,d]),j=x.useCallback((J,ue)=>de=>{const Se={ArrowLeft:["day",e.dir==="rtl"?"after":"before"],ArrowRight:["day",e.dir==="rtl"?"before":"after"],ArrowDown:["week","after"],ArrowUp:["week","before"],PageUp:[de.shiftKey?"year":"month","before"],PageDown:[de.shiftKey?"year":"month","after"],Home:["startOfWeek","before"],End:["endOfWeek","after"]};if(Se[de.key]){de.preventDefault(),de.stopPropagation();const[Ve,gn]=Se[de.key];me(Ve,gn)}p==null||p(J.date,ue,de)},[me,p,e.dir]),ae=x.useCallback((J,ue)=>de=>{h==null||h(J.date,ue,de)},[h]),Pe=x.useCallback((J,ue)=>de=>{v==null||v(J.date,ue,de)},[v]),ye=x.useCallback(J=>ue=>{const de=Number(ue.target.value),Se=o.setMonth(o.startOfMonth(J),de);Y(Se)},[o,Y]),Q=x.useCallback(J=>ue=>{const de=Number(ue.target.value),Se=o.setYear(o.startOfMonth(J),de);Y(Se)},[o,Y]),{className:Ue,style:Qe}=x.useMemo(()=>({className:[s[U.Root],e.className].filter(Boolean).join(" "),style:{...b==null?void 0:b[U.Root],...e.style}}),[s,e.className,e.style,b]),Ce=Uw(e),Ze={dayPickerProps:e,selected:q,select:H,isSelected:T,months:_,nextMonth:W,previousMonth:ee,goToMonth:Y,getModifiers:L,components:t,classNames:s,styles:b,labels:r,formatters:n};return x.createElement(al.Provider,{value:Ze},x.createElement(t.Root,{className:Ue,style:Qe,dir:e.dir,id:e.id,lang:e.lang,nonce:e.nonce,title:e.title,role:e.role,"aria-label":e["aria-label"],...Ce},x.createElement(t.Months,{className:s[U.Months],style:b==null?void 0:b[U.Months]},!e.hideNavigation&&x.createElement(t.Nav,{className:s[U.Nav],style:b==null?void 0:b[U.Nav],"aria-label":se(),onPreviousClick:at,onNextClick:Xe,previousMonth:ee,nextMonth:W}),_.map((J,ue)=>{const de=rx(J.date,z,G,n,o),Se=sx(z,G,n,o);return x.createElement(t.Month,{className:s[U.Month],style:b==null?void 0:b[U.Month],key:ue,displayIndex:ue,calendarMonth:J},x.createElement(t.MonthCaption,{className:s[U.MonthCaption],style:b==null?void 0:b[U.MonthCaption],calendarMonth:J,displayIndex:ue},i!=null&&i.startsWith("dropdown")?x.createElement(t.DropdownNav,{className:s[U.Dropdowns],style:b==null?void 0:b[U.Dropdowns]},i==="dropdown"||i==="dropdown-months"?x.createElement(t.MonthsDropdown,{className:s[U.MonthsDropdown],"aria-label":oe(),classNames:s,components:t,disabled:!!e.disableNavigation,onChange:ye(J.date),options:de,style:b==null?void 0:b[U.Dropdown],value:o.getMonth(J.date)}):x.createElement("span",{role:"status","aria-live":"polite"},S(J.date,o)),i==="dropdown"||i==="dropdown-years"?x.createElement(t.YearsDropdown,{className:s[U.YearsDropdown],"aria-label":$e(o.options),classNames:s,components:t,disabled:!!e.disableNavigation,onChange:Q(J.date),options:Se,style:b==null?void 0:b[U.Dropdown],value:o.getYear(J.date)}):x.createElement("span",{role:"status","aria-live":"polite"},R(J.date,o))):x.createElement(t.CaptionLabel,{className:s[U.CaptionLabel],role:"status","aria-live":"polite"},C(J.date,o.options,o))),x.createElement(t.MonthGrid,{role:"grid","aria-multiselectable":c==="multiple"||c==="range","aria-label":ce(J.date,o.options,o)||void 0,className:s[U.MonthGrid],style:b==null?void 0:b[U.MonthGrid]},!e.hideWeekdays&&x.createElement(t.Weekdays,{className:s[U.Weekdays],style:b==null?void 0:b[U.Weekdays]},w&&x.createElement(t.WeekNumberHeader,{"aria-label":Re(o.options),className:s[U.WeekNumberHeader],style:b==null?void 0:b[U.WeekNumberHeader],scope:"col"},P()),ot.map((Ve,gn)=>x.createElement(t.Weekday,{"aria-label":le(Ve,o.options,o),className:s[U.Weekday],key:gn,style:b==null?void 0:b[U.Weekday],scope:"col"},D(Ve,o.options,o)))),x.createElement(t.Weeks,{className:s[U.Weeks],style:b==null?void 0:b[U.Weeks]},J.weeks.map((Ve,gn)=>x.createElement(t.Week,{className:s[U.Week],key:Ve.weekNumber,style:b==null?void 0:b[U.Week],week:Ve},w&&x.createElement(t.WeekNumber,{week:Ve,style:b==null?void 0:b[U.WeekNumber],"aria-label":Me(Ve.weekNumber,{locale:a}),className:s[U.WeekNumber],scope:"row",role:"rowheader"},k(Ve.weekNumber)),Ve.days.map(ke=>{const{date:Ae}=ke,fe=L(ke);if(fe[be.focused]=!fe.hidden&&!!(K!=null&&K.isEqualTo(ke)),fe[nt.selected]=!fe.disabled&&((T==null?void 0:T(Ae))||fe.selected),Uo(q)){const{from:We,to:Ye}=q;fe[nt.range_start]=!!(We&&Ye&&o.isSameDay(Ae,We)),fe[nt.range_end]=!!(We&&Ye&&o.isSameDay(Ae,Ye)),fe[nt.range_middle]=Ct(q,Ae,!0,o)}const te=ox(fe,b,e.modifiersStyles),he=yw(fe,s,e.modifiersClassNames),we=!Be&&!fe.hidden?ie(Ae,fe,o.options,o):void 0;return x.createElement(t.Day,{key:`${o.format(Ae,"yyyy-MM-dd")}_${o.format(ke.displayMonth,"yyyy-MM")}`,day:ke,modifiers:fe,className:he.join(" "),style:te,role:"gridcell","aria-selected":fe.selected||void 0,"aria-label":we,"data-day":o.format(Ae,"yyyy-MM-dd"),"data-month":ke.outside?o.format(Ae,"yyyy-MM"):void 0,"data-selected":fe.selected||void 0,"data-disabled":fe.disabled||void 0,"data-hidden":fe.hidden||void 0,"data-outside":ke.outside||void 0,"data-focused":fe.focused||void 0,"data-today":fe.today||void 0},!fe.hidden&&Be?x.createElement(t.DayButton,{className:s[U.DayButton],style:b==null?void 0:b[U.DayButton],type:"button",day:ke,modifiers:fe,disabled:fe.disabled||void 0,tabIndex:Z(ke)?0:-1,"aria-label":I(Ae,fe,o.options,o),onClick:st(ke,fe),onBlur:B(ke,fe),onFocus:N(ke,fe),onKeyDown:j(ke,fe),onMouseEnter:ae(ke,fe),onMouseLeave:Pe(ke,fe)},M(Ae,o.options,o)):!fe.hidden&&M(ke.date,o.options,o))}))))))})),e.footer&&x.createElement(t.Footer,{className:s[U.Footer],style:b==null?void 0:b[U.Footer],role:"status","aria-live":"polite"},e.footer)))}function bl(e){const{className:t,classNames:n,showOutsideDays:r=!0,...o}=e;return u.jsx(Bx,{showOutsideDays:r,className:O("p-3",t),classNames:{...n},locale:Sb,...o})}bl.displayName="Calendar";const wl=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{ref:n,className:O("rounded-xl border bg-card text-card-foreground shadow",e),...t}));wl.displayName="Card";const xl=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{ref:n,className:O("flex flex-col space-y-1.5 p-6",e),...t}));xl.displayName="CardHeader";const Cl=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{ref:n,className:O("font-semibold leading-none tracking-tight pb-4",e),...t}));Cl.displayName="CardTitle";const Nl=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{ref:n,className:O("text-sm text-muted-foreground",e),...t}));Nl.displayName="CardDescription";const Ml=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{ref:n,className:O("p-6 py-0",e),...t}));Ml.displayName="CardContent";const Sl=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{ref:n,className:O("flex items-center p-6 pt-6",e),...t}));Sl.displayName="CardFooter";function $n(e){const t=l.useRef({value:e,previous:e});return l.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Ko="Checkbox",[Vx,TS]=Te(Ko),[Yx,Gx]=Vx(Ko),El=l.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:a,required:s,disabled:i,value:c="on",onCheckedChange:d,form:f,...m}=e,[p,h]=l.useState(null),v=ne(t,M=>h(M)),g=l.useRef(!1),y=p?f||!!p.closest("form"):!0,[w=!1,b]=Ie({prop:o,defaultProp:a,onChange:d}),C=l.useRef(w);return l.useEffect(()=>{const M=p==null?void 0:p.form;if(M){const S=()=>b(C.current);return M.addEventListener("reset",S),()=>M.removeEventListener("reset",S)}},[p,b]),u.jsxs(Yx,{scope:n,state:w,disabled:i,children:[u.jsx(F.button,{type:"button",role:"checkbox","aria-checked":_t(w)?"mixed":w,"aria-required":s,"data-state":Tl(w),"data-disabled":i?"":void 0,disabled:i,value:c,...m,ref:v,onKeyDown:A(e.onKeyDown,M=>{M.key==="Enter"&&M.preventDefault()}),onClick:A(e.onClick,M=>{b(S=>_t(S)?!0:!S),y&&(g.current=M.isPropagationStopped(),g.current||M.stopPropagation())})}),y&&u.jsx(zx,{control:p,bubbles:!g.current,name:r,value:c,checked:w,required:s,disabled:i,form:f,style:{transform:"translateX(-100%)"},defaultChecked:_t(a)?!1:a})]})});El.displayName=Ko;var Pl="CheckboxIndicator",kl=l.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,a=Gx(Pl,n);return u.jsx(De,{present:r||_t(a.state)||a.state===!0,children:u.jsx(F.span,{"data-state":Tl(a.state),"data-disabled":a.disabled?"":void 0,...o,ref:t,style:{pointerEvents:"none",...e.style}})})});kl.displayName=Pl;var zx=e=>{const{control:t,checked:n,bubbles:r=!0,defaultChecked:o,...a}=e,s=l.useRef(null),i=$n(n),c=Sr(t);l.useEffect(()=>{const f=s.current,m=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(m,"checked").set;if(i!==n&&h){const v=new Event("click",{bubbles:r});f.indeterminate=_t(n),h.call(f,_t(n)?!1:n),f.dispatchEvent(v)}},[i,n,r]);const d=l.useRef(_t(n)?!1:n);return u.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:o??d.current,...a,tabIndex:-1,ref:s,style:{...e.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function _t(e){return e==="indeterminate"}function Tl(e){return _t(e)?"indeterminate":e?"checked":"unchecked"}var Dl=El,Hx=kl;const Ol=l.forwardRef(({className:e,...t},n)=>u.jsx(Dl,{ref:n,className:O("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:u.jsx(Hx,{className:O("flex items-center justify-center text-current"),children:u.jsx(Mo,{className:"h-4 w-4"})})}));Ol.displayName=Dl.displayName;const Al=x.forwardRef((e,t)=>{const{currencySymbol:n="$",decimalSeparator:r=".",thousandSeparator:o=",",onValueChange:a,className:s,value:i=0,...c}=e,d=x.useRef(null);x.useImperativeHandle(t,()=>d.current);const[f,m]=x.useState(""),p=g=>{const y=g.toFixed(2).split("."),w=y[0].replace(/\B(?=(\d{3})+(?!\d))/g,o);return`${n} ${w}${r}${y[1]}`},h=g=>{const y=g.target.value,w=parseFloat(y.replace(/\D/g,""))/100;m(p(w)),a(w),d.current&&window.requestAnimationFrame(()=>{var b;(b=d.current)==null||b.setSelectionRange(d.current.value.length,d.current.value.length)})},v=()=>{d.current&&d.current.setSelectionRange(d.current.value.length,d.current.value.length)};return x.useEffect(()=>{m(p(+i))},[i]),u.jsx(nr,{type:"text",inputMode:"numeric",value:f,ref:d,onChange:h,onFocus:v,onClick:v,placeholder:`${n} 0${r}00`,className:s,...c})});Al.displayName="CurrencyInput";const qo=ti,_l=ni,Rl=ri,Ux=pr,Xo=l.forwardRef(({className:e,...t},n)=>u.jsx(bo,{ref:n,className:O("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}));Xo.displayName=bo.displayName;const Dr=l.forwardRef(({className:e,children:t,...n},r)=>u.jsxs(Rl,{children:[u.jsx(Xo,{}),u.jsxs(wo,{ref:r,className:O("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 max-h-[100dvh] overflow-y-auto",e),...n,children:[t,u.jsxs(pr,{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:[u.jsx(qg,{className:"h-4 w-4"}),u.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Dr.displayName=wo.displayName;const Or=({className:e,...t})=>u.jsx("div",{className:O("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});Or.displayName="DialogHeader";const Il=({className:e,...t})=>u.jsx("div",{className:O("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Il.displayName="DialogFooter";const Ar=l.forwardRef(({className:e,...t},n)=>u.jsx(xo,{ref:n,className:O("text-lg font-semibold leading-none tracking-tight",e),...t}));Ar.displayName=xo.displayName;const _r=l.forwardRef(({className:e,...t},n)=>u.jsx(Co,{ref:n,className:O("text-sm text-muted-foreground",e),...t}));_r.displayName=Co.displayName;function Wn(e){const t=e+"CollectionProvider",[n,r]=Te(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=h=>{const{scope:v,children:g}=h,y=x.useRef(null),w=x.useRef(new Map).current;return u.jsx(o,{scope:v,itemMap:w,collectionRef:y,children:g})};s.displayName=t;const i=e+"CollectionSlot",c=x.forwardRef((h,v)=>{const{scope:g,children:y}=h,w=a(i,g),b=ne(v,w.collectionRef);return u.jsx(it,{ref:b,children:y})});c.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",m=x.forwardRef((h,v)=>{const{scope:g,children:y,...w}=h,b=x.useRef(null),C=ne(v,b),M=a(d,g);return x.useEffect(()=>(M.itemMap.set(b,{ref:b,...w}),()=>void M.itemMap.delete(b))),u.jsx(it,{[f]:"",ref:C,children:y})});m.displayName=d;function p(h){const v=a(e+"CollectionConsumer",h);return x.useCallback(()=>{const y=v.collectionRef.current;if(!y)return[];const w=Array.from(y.querySelectorAll(`[${f}]`));return Array.from(v.itemMap.values()).sort((M,S)=>w.indexOf(M.ref.current)-w.indexOf(S.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:s,Slot:c,ItemSlot:m},p,r]}var Kx=l.createContext(void 0);function Yt(e){const t=l.useContext(Kx);return e||t||"ltr"}var Qo="rovingFocusGroup.onEntryFocus",qx={bubbles:!1,cancelable:!0},Rr="RovingFocusGroup",[Zo,jl,Xx]=Wn(Rr),[Qx,Rt]=Te(Rr,[Xx]),[Zx,Jx]=Qx(Rr),Fl=l.forwardRef((e,t)=>u.jsx(Zo.Provider,{scope:e.__scopeRovingFocusGroup,children:u.jsx(Zo.Slot,{scope:e.__scopeRovingFocusGroup,children:u.jsx(e0,{...e,ref:t})})}));Fl.displayName=Rr;var e0=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:s,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:c,onEntryFocus:d,preventScrollOnEntryFocus:f=!1,...m}=e,p=l.useRef(null),h=ne(t,p),v=Yt(a),[g=null,y]=Ie({prop:s,defaultProp:i,onChange:c}),[w,b]=l.useState(!1),C=Ne(d),M=jl(n),S=l.useRef(!1),[k,P]=l.useState(0);return l.useEffect(()=>{const D=p.current;if(D)return D.addEventListener(Qo,C),()=>D.removeEventListener(Qo,C)},[C]),u.jsx(Zx,{scope:n,orientation:r,dir:v,loop:o,currentTabStopId:g,onItemFocus:l.useCallback(D=>y(D),[y]),onItemShiftTab:l.useCallback(()=>b(!0),[]),onFocusableItemAdd:l.useCallback(()=>P(D=>D+1),[]),onFocusableItemRemove:l.useCallback(()=>P(D=>D-1),[]),children:u.jsx(F.div,{tabIndex:w||k===0?-1:0,"data-orientation":r,...m,ref:h,style:{outline:"none",...e.style},onMouseDown:A(e.onMouseDown,()=>{S.current=!0}),onFocus:A(e.onFocus,D=>{const R=!S.current;if(D.target===D.currentTarget&&R&&!w){const $=new CustomEvent(Qo,qx);if(D.currentTarget.dispatchEvent($),!$.defaultPrevented){const V=M().filter(W=>W.focusable),_=V.find(W=>W.active),z=V.find(W=>W.id===g),ee=[_,z,...V].filter(Boolean).map(W=>W.ref.current);Ll(ee,f)}}S.current=!1}),onBlur:A(e.onBlur,()=>b(!1))})})}),$l="RovingFocusGroupItem",Wl=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,...s}=e,i=je(),c=a||i,d=Jx($l,n),f=d.currentTabStopId===c,m=jl(n),{onFocusableItemAdd:p,onFocusableItemRemove:h}=d;return l.useEffect(()=>{if(r)return p(),()=>h()},[r,p,h]),u.jsx(Zo.ItemSlot,{scope:n,id:c,focusable:r,active:o,children:u.jsx(F.span,{tabIndex:f?0:-1,"data-orientation":d.orientation,...s,ref:t,onMouseDown:A(e.onMouseDown,v=>{r?d.onItemFocus(c):v.preventDefault()}),onFocus:A(e.onFocus,()=>d.onItemFocus(c)),onKeyDown:A(e.onKeyDown,v=>{if(v.key==="Tab"&&v.shiftKey){d.onItemShiftTab();return}if(v.target!==v.currentTarget)return;const g=r0(v,d.orientation,d.dir);if(g!==void 0){if(v.metaKey||v.ctrlKey||v.altKey||v.shiftKey)return;v.preventDefault();let w=m().filter(b=>b.focusable).map(b=>b.ref.current);if(g==="last")w.reverse();else if(g==="prev"||g==="next"){g==="prev"&&w.reverse();const b=w.indexOf(v.currentTarget);w=d.loop?o0(w,b+1):w.slice(b+1)}setTimeout(()=>Ll(w))}})})})});Wl.displayName=$l;var t0={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function n0(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function r0(e,t,n){const r=n0(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return t0[r]}function Ll(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function o0(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Ir=Fl,jr=Wl,Jo=["Enter"," "],a0=["ArrowDown","PageUp","Home"],Bl=["ArrowUp","PageDown","End"],s0=[...a0,...Bl],i0={ltr:[...Jo,"ArrowRight"],rtl:[...Jo,"ArrowLeft"]},c0={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Ln="Menu",[Bn,l0,u0]=Wn(Ln),[Gt,Vl]=Te(Ln,[u0,Dt,Rt]),Vn=Dt(),Yl=Rt(),[Gl,It]=Gt(Ln),[d0,Yn]=Gt(Ln),zl=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:a,modal:s=!0}=e,i=Vn(t),[c,d]=l.useState(null),f=l.useRef(!1),m=Ne(a),p=Yt(o);return l.useEffect(()=>{const h=()=>{f.current=!0,document.addEventListener("pointerdown",v,{capture:!0,once:!0}),document.addEventListener("pointermove",v,{capture:!0,once:!0})},v=()=>f.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",v,{capture:!0}),document.removeEventListener("pointermove",v,{capture:!0})}},[]),u.jsx(Tn,{...i,children:u.jsx(Gl,{scope:t,open:n,onOpenChange:m,content:c,onContentChange:d,children:u.jsx(d0,{scope:t,onClose:l.useCallback(()=>m(!1),[m]),isUsingKeyboardRef:f,dir:p,modal:s,children:r})})})};zl.displayName=Ln;var f0="MenuAnchor",ea=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=Vn(n);return u.jsx(Dn,{...o,...r,ref:t})});ea.displayName=f0;var ta="MenuPortal",[m0,Hl]=Gt(ta,{forceMount:void 0}),Ul=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,a=It(ta,t);return u.jsx(m0,{scope:t,forceMount:n,children:u.jsx(De,{present:n||a.open,children:u.jsx(Nn,{asChild:!0,container:o,children:r})})})};Ul.displayName=ta;var Ke="MenuContent",[h0,na]=Gt(Ke),Kl=l.forwardRef((e,t)=>{const n=Hl(Ke,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=It(Ke,e.__scopeMenu),s=Yn(Ke,e.__scopeMenu);return u.jsx(Bn.Provider,{scope:e.__scopeMenu,children:u.jsx(De,{present:r||a.open,children:u.jsx(Bn.Slot,{scope:e.__scopeMenu,children:s.modal?u.jsx(p0,{...o,ref:t}):u.jsx(g0,{...o,ref:t})})})})}),p0=l.forwardRef((e,t)=>{const n=It(Ke,e.__scopeMenu),r=l.useRef(null),o=ne(t,r);return l.useEffect(()=>{const a=r.current;if(a)return mr(a)},[]),u.jsx(ra,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:A(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),g0=l.forwardRef((e,t)=>{const n=It(Ke,e.__scopeMenu);return u.jsx(ra,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),ra=l.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEntryFocus:c,onEscapeKeyDown:d,onPointerDownOutside:f,onFocusOutside:m,onInteractOutside:p,onDismiss:h,disableOutsideScroll:v,...g}=e,y=It(Ke,n),w=Yn(Ke,n),b=Vn(n),C=Yl(n),M=l0(n),[S,k]=l.useState(null),P=l.useRef(null),D=ne(t,P,y.onContentChange),R=l.useRef(0),$=l.useRef(""),V=l.useRef(0),_=l.useRef(null),z=l.useRef("right"),G=l.useRef(0),ee=v?Mn:l.Fragment,W=v?{as:it,allowPinchZoom:!0}:void 0,Y=T=>{var I,ie;const H=$.current+T,q=M().filter(ce=>!ce.disabled),X=document.activeElement,K=(I=q.find(ce=>ce.ref.current===X))==null?void 0:I.textValue,Z=q.map(ce=>ce.textValue),me=k0(Z,H,K),ge=(ie=q.find(ce=>ce.textValue===me))==null?void 0:ie.ref.current;(function ce(oe){$.current=oe,window.clearTimeout(R.current),oe!==""&&(R.current=window.setTimeout(()=>ce(""),1e3))})(H),ge&&setTimeout(()=>ge.focus())};l.useEffect(()=>()=>window.clearTimeout(R.current),[]),ar();const L=l.useCallback(T=>{var q,X;return z.current===((q=_.current)==null?void 0:q.side)&&D0(T,(X=_.current)==null?void 0:X.area)},[]);return u.jsx(h0,{scope:n,searchRef:$,onItemEnter:l.useCallback(T=>{L(T)&&T.preventDefault()},[L]),onItemLeave:l.useCallback(T=>{var H;L(T)||((H=P.current)==null||H.focus(),k(null))},[L]),onTriggerLeave:l.useCallback(T=>{L(T)&&T.preventDefault()},[L]),pointerGraceTimerRef:V,onPointerGraceIntentChange:l.useCallback(T=>{_.current=T},[]),children:u.jsx(ee,{...W,children:u.jsx(Cn,{asChild:!0,trapped:o,onMountAutoFocus:A(a,T=>{var H;T.preventDefault(),(H=P.current)==null||H.focus({preventScroll:!0})}),onUnmountAutoFocus:s,children:u.jsx($t,{asChild:!0,disableOutsidePointerEvents:i,onEscapeKeyDown:d,onPointerDownOutside:f,onFocusOutside:m,onInteractOutside:p,onDismiss:h,children:u.jsx(Ir,{asChild:!0,...C,dir:w.dir,orientation:"vertical",loop:r,currentTabStopId:S,onCurrentTabStopIdChange:k,onEntryFocus:A(c,T=>{w.isUsingKeyboardRef.current||T.preventDefault()}),preventScrollOnEntryFocus:!0,children:u.jsx(Er,{role:"menu","aria-orientation":"vertical","data-state":fu(y.open),"data-radix-menu-content":"",dir:w.dir,...b,...g,ref:D,style:{outline:"none",...g.style},onKeyDown:A(g.onKeyDown,T=>{const q=T.target.closest("[data-radix-menu-content]")===T.currentTarget,X=T.ctrlKey||T.altKey||T.metaKey,K=T.key.length===1;q&&(T.key==="Tab"&&T.preventDefault(),!X&&K&&Y(T.key));const Z=P.current;if(T.target!==Z||!s0.includes(T.key))return;T.preventDefault();const ge=M().filter(I=>!I.disabled).map(I=>I.ref.current);Bl.includes(T.key)&&ge.reverse(),E0(ge)}),onBlur:A(e.onBlur,T=>{T.currentTarget.contains(T.target)||(window.clearTimeout(R.current),$.current="")}),onPointerMove:A(e.onPointerMove,zn(T=>{const H=T.target,q=G.current!==T.clientX;if(T.currentTarget.contains(H)&&q){const X=T.clientX>G.current?"right":"left";z.current=X,G.current=T.clientX}}))})})})})})})});Kl.displayName=Ke;var v0="MenuGroup",oa=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(F.div,{role:"group",...r,ref:t})});oa.displayName=v0;var y0="MenuLabel",ql=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(F.div,{...r,ref:t})});ql.displayName=y0;var Fr="MenuItem",Xl="menu.itemSelect",$r=l.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,a=l.useRef(null),s=Yn(Fr,e.__scopeMenu),i=na(Fr,e.__scopeMenu),c=ne(t,a),d=l.useRef(!1),f=()=>{const m=a.current;if(!n&&m){const p=new CustomEvent(Xl,{bubbles:!0,cancelable:!0});m.addEventListener(Xl,h=>r==null?void 0:r(h),{once:!0}),rr(m,p),p.defaultPrevented?d.current=!1:s.onClose()}};return u.jsx(Ql,{...o,ref:c,disabled:n,onClick:A(e.onClick,f),onPointerDown:m=>{var p;(p=e.onPointerDown)==null||p.call(e,m),d.current=!0},onPointerUp:A(e.onPointerUp,m=>{var p;d.current||(p=m.currentTarget)==null||p.click()}),onKeyDown:A(e.onKeyDown,m=>{const p=i.searchRef.current!=="";n||p&&m.key===" "||Jo.includes(m.key)&&(m.currentTarget.click(),m.preventDefault())})})});$r.displayName=Fr;var Ql=l.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...a}=e,s=na(Fr,n),i=Yl(n),c=l.useRef(null),d=ne(t,c),[f,m]=l.useState(!1),[p,h]=l.useState("");return l.useEffect(()=>{const v=c.current;v&&h((v.textContent??"").trim())},[a.children]),u.jsx(Bn.ItemSlot,{scope:n,disabled:r,textValue:o??p,children:u.jsx(jr,{asChild:!0,...i,focusable:!r,children:u.jsx(F.div,{role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...a,ref:d,onPointerMove:A(e.onPointerMove,zn(v=>{r?s.onItemLeave(v):(s.onItemEnter(v),v.defaultPrevented||v.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:A(e.onPointerLeave,zn(v=>s.onItemLeave(v))),onFocus:A(e.onFocus,()=>m(!0)),onBlur:A(e.onBlur,()=>m(!1))})})})}),b0="MenuCheckboxItem",Zl=l.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return u.jsx(ru,{scope:e.__scopeMenu,checked:n,children:u.jsx($r,{role:"menuitemcheckbox","aria-checked":Wr(n)?"mixed":n,...o,ref:t,"data-state":ia(n),onSelect:A(o.onSelect,()=>r==null?void 0:r(Wr(n)?!0:!n),{checkForDefaultPrevented:!1})})})});Zl.displayName=b0;var Jl="MenuRadioGroup",[w0,x0]=Gt(Jl,{value:void 0,onValueChange:()=>{}}),eu=l.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,a=Ne(r);return u.jsx(w0,{scope:e.__scopeMenu,value:n,onValueChange:a,children:u.jsx(oa,{...o,ref:t})})});eu.displayName=Jl;var tu="MenuRadioItem",nu=l.forwardRef((e,t)=>{const{value:n,...r}=e,o=x0(tu,e.__scopeMenu),a=n===o.value;return u.jsx(ru,{scope:e.__scopeMenu,checked:a,children:u.jsx($r,{role:"menuitemradio","aria-checked":a,...r,ref:t,"data-state":ia(a),onSelect:A(r.onSelect,()=>{var s;return(s=o.onValueChange)==null?void 0:s.call(o,n)},{checkForDefaultPrevented:!1})})})});nu.displayName=tu;var aa="MenuItemIndicator",[ru,C0]=Gt(aa,{checked:!1}),ou=l.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,a=C0(aa,n);return u.jsx(De,{present:r||Wr(a.checked)||a.checked===!0,children:u.jsx(F.span,{...o,ref:t,"data-state":ia(a.checked)})})});ou.displayName=aa;var N0="MenuSeparator",au=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(F.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});au.displayName=N0;var M0="MenuArrow",su=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=Vn(n);return u.jsx(Pr,{...o,...r,ref:t})});su.displayName=M0;var sa="MenuSub",[S0,iu]=Gt(sa),cu=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,a=It(sa,t),s=Vn(t),[i,c]=l.useState(null),[d,f]=l.useState(null),m=Ne(o);return l.useEffect(()=>(a.open===!1&&m(!1),()=>m(!1)),[a.open,m]),u.jsx(Tn,{...s,children:u.jsx(Gl,{scope:t,open:r,onOpenChange:m,content:d,onContentChange:f,children:u.jsx(S0,{scope:t,contentId:je(),triggerId:je(),trigger:i,onTriggerChange:c,children:n})})})};cu.displayName=sa;var Gn="MenuSubTrigger",lu=l.forwardRef((e,t)=>{const n=It(Gn,e.__scopeMenu),r=Yn(Gn,e.__scopeMenu),o=iu(Gn,e.__scopeMenu),a=na(Gn,e.__scopeMenu),s=l.useRef(null),{pointerGraceTimerRef:i,onPointerGraceIntentChange:c}=a,d={__scopeMenu:e.__scopeMenu},f=l.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return l.useEffect(()=>f,[f]),l.useEffect(()=>{const m=i.current;return()=>{window.clearTimeout(m),c(null)}},[i,c]),u.jsx(ea,{asChild:!0,...d,children:u.jsx(Ql,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":fu(n.open),...e,ref:xn(t,o.onTriggerChange),onClick:m=>{var p;(p=e.onClick)==null||p.call(e,m),!(e.disabled||m.defaultPrevented)&&(m.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:A(e.onPointerMove,zn(m=>{a.onItemEnter(m),!m.defaultPrevented&&!e.disabled&&!n.open&&!s.current&&(a.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:A(e.onPointerLeave,zn(m=>{var h,v;f();const p=(h=n.content)==null?void 0:h.getBoundingClientRect();if(p){const g=(v=n.content)==null?void 0:v.dataset.side,y=g==="right",w=y?-5:5,b=p[y?"left":"right"],C=p[y?"right":"left"];a.onPointerGraceIntentChange({area:[{x:m.clientX+w,y:m.clientY},{x:b,y:p.top},{x:C,y:p.top},{x:C,y:p.bottom},{x:b,y:p.bottom}],side:g}),window.clearTimeout(i.current),i.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(m),m.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:A(e.onKeyDown,m=>{var h;const p=a.searchRef.current!=="";e.disabled||p&&m.key===" "||i0[r.dir].includes(m.key)&&(n.onOpenChange(!0),(h=n.content)==null||h.focus(),m.preventDefault())})})})});lu.displayName=Gn;var uu="MenuSubContent",du=l.forwardRef((e,t)=>{const n=Hl(Ke,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=It(Ke,e.__scopeMenu),s=Yn(Ke,e.__scopeMenu),i=iu(uu,e.__scopeMenu),c=l.useRef(null),d=ne(t,c);return u.jsx(Bn.Provider,{scope:e.__scopeMenu,children:u.jsx(De,{present:r||a.open,children:u.jsx(Bn.Slot,{scope:e.__scopeMenu,children:u.jsx(ra,{id:i.contentId,"aria-labelledby":i.triggerId,...o,ref:d,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{var m;s.isUsingKeyboardRef.current&&((m=c.current)==null||m.focus()),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:A(e.onFocusOutside,f=>{f.target!==i.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:A(e.onEscapeKeyDown,f=>{s.onClose(),f.preventDefault()}),onKeyDown:A(e.onKeyDown,f=>{var h;const m=f.currentTarget.contains(f.target),p=c0[s.dir].includes(f.key);m&&p&&(a.onOpenChange(!1),(h=i.trigger)==null||h.focus(),f.preventDefault())})})})})})});du.displayName=uu;function fu(e){return e?"open":"closed"}function Wr(e){return e==="indeterminate"}function ia(e){return Wr(e)?"indeterminate":e?"checked":"unchecked"}function E0(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function P0(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function k0(e,t,n){const o=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=P0(e,Math.max(a,0));o.length===1&&(s=s.filter(d=>d!==n));const c=s.find(d=>d.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function T0(e,t){const{x:n,y:r}=e;let o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a].x,c=t[a].y,d=t[s].x,f=t[s].y;c>r!=f>r&&n<(d-i)*(r-c)/(f-c)+i&&(o=!o)}return o}function D0(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return T0(n,t)}function zn(e){return t=>t.pointerType==="mouse"?e(t):void 0}var O0=zl,A0=ea,_0=Ul,R0=Kl,I0=oa,j0=ql,F0=$r,$0=Zl,W0=eu,L0=nu,B0=ou,V0=au,Y0=su,G0=cu,z0=lu,H0=du,ca="DropdownMenu",[U0,DS]=Te(ca,[Vl]),Fe=Vl(),[K0,mu]=U0(ca),hu=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:a,onOpenChange:s,modal:i=!0}=e,c=Fe(t),d=l.useRef(null),[f=!1,m]=Ie({prop:o,defaultProp:a,onChange:s});return u.jsx(K0,{scope:t,triggerId:je(),triggerRef:d,contentId:je(),open:f,onOpenChange:m,onOpenToggle:l.useCallback(()=>m(p=>!p),[m]),modal:i,children:u.jsx(O0,{...c,open:f,onOpenChange:m,dir:r,modal:i,children:n})})};hu.displayName=ca;var pu="DropdownMenuTrigger",gu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,a=mu(pu,n),s=Fe(n);return u.jsx(A0,{asChild:!0,...s,children:u.jsx(F.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":r?"":void 0,disabled:r,...o,ref:xn(t,a.triggerRef),onPointerDown:A(e.onPointerDown,i=>{!r&&i.button===0&&i.ctrlKey===!1&&(a.onOpenToggle(),a.open||i.preventDefault())}),onKeyDown:A(e.onKeyDown,i=>{r||(["Enter"," "].includes(i.key)&&a.onOpenToggle(),i.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(i.key)&&i.preventDefault())})})})});gu.displayName=pu;var q0="DropdownMenuPortal",vu=e=>{const{__scopeDropdownMenu:t,...n}=e,r=Fe(t);return u.jsx(_0,{...r,...n})};vu.displayName=q0;var yu="DropdownMenuContent",bu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=mu(yu,n),a=Fe(n),s=l.useRef(!1);return u.jsx(R0,{id:o.contentId,"aria-labelledby":o.triggerId,...a,...r,ref:t,onCloseAutoFocus:A(e.onCloseAutoFocus,i=>{var c;s.current||(c=o.triggerRef.current)==null||c.focus(),s.current=!1,i.preventDefault()}),onInteractOutside:A(e.onInteractOutside,i=>{const c=i.detail.originalEvent,d=c.button===0&&c.ctrlKey===!0,f=c.button===2||d;(!o.modal||f)&&(s.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)"}})});bu.displayName=yu;var X0="DropdownMenuGroup",wu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(I0,{...o,...r,ref:t})});wu.displayName=X0;var Q0="DropdownMenuLabel",xu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(j0,{...o,...r,ref:t})});xu.displayName=Q0;var Z0="DropdownMenuItem",Cu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(F0,{...o,...r,ref:t})});Cu.displayName=Z0;var J0="DropdownMenuCheckboxItem",Nu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx($0,{...o,...r,ref:t})});Nu.displayName=J0;var eC="DropdownMenuRadioGroup",Mu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(W0,{...o,...r,ref:t})});Mu.displayName=eC;var tC="DropdownMenuRadioItem",Su=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(L0,{...o,...r,ref:t})});Su.displayName=tC;var nC="DropdownMenuItemIndicator",Eu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(B0,{...o,...r,ref:t})});Eu.displayName=nC;var rC="DropdownMenuSeparator",Pu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(V0,{...o,...r,ref:t})});Pu.displayName=rC;var oC="DropdownMenuArrow",aC=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(Y0,{...o,...r,ref:t})});aC.displayName=oC;var sC=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:a}=e,s=Fe(t),[i=!1,c]=Ie({prop:r,defaultProp:a,onChange:o});return u.jsx(G0,{...s,open:i,onOpenChange:c,children:n})},iC="DropdownMenuSubTrigger",ku=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(z0,{...o,...r,ref:t})});ku.displayName=iC;var cC="DropdownMenuSubContent",Tu=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Fe(n);return u.jsx(H0,{...o,...r,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)"}})});Tu.displayName=cC;var lC=hu,uC=gu,Du=vu,Ou=bu,dC=wu,Au=xu,_u=Cu,Ru=Nu,fC=Mu,Iu=Su,ju=Eu,Fu=Pu,mC=sC,$u=ku,Wu=Tu;const hC=lC,pC=uC,gC=dC,vC=Du,yC=mC,bC=fC,Lu=l.forwardRef(({className:e,inset:t,children:n,...r},o)=>u.jsxs($u,{ref:o,className:O("flex cursor-default gap-2 select-none items-center 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),...r,children:[n,u.jsx(Eo,{className:"ml-auto"})]}));Lu.displayName=$u.displayName;const Bu=l.forwardRef(({className:e,...t},n)=>u.jsx(Wu,{ref:n,className:O("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",e),...t}));Bu.displayName=Wu.displayName;const Vu=l.forwardRef(({className:e,sideOffset:t=4,...n},r)=>u.jsx(Du,{children:u.jsx(Ou,{ref:r,sideOffset:t,className:O("z-50 min-w-[8rem] overflow-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",e),...n})}));Vu.displayName=Ou.displayName;const Yu=l.forwardRef(({className:e,inset:t,...n},r)=>u.jsx(_u,{ref:r,className:O("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),...n}));Yu.displayName=_u.displayName;const Gu=l.forwardRef(({className:e,children:t,checked:n,...r},o)=>u.jsxs(Ru,{ref:o,className:O("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:n,...r,children:[u.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:u.jsx(ju,{children:u.jsx(Mo,{className:"h-4 w-4"})})}),t]}));Gu.displayName=Ru.displayName;const zu=l.forwardRef(({className:e,children:t,...n},r)=>u.jsxs(Iu,{ref:r,className:O("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),...n,children:[u.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:u.jsx(ju,{children:u.jsx(Ri,{className:"h-2 w-2 fill-current"})})}),t]}));zu.displayName=Iu.displayName;const Hu=l.forwardRef(({className:e,inset:t,...n},r)=>u.jsx(Au,{ref:r,className:O("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));Hu.displayName=Au.displayName;const Uu=l.forwardRef(({className:e,...t},n)=>u.jsx(Fu,{ref:n,className:O("-mx-1 my-1 h-px bg-muted",e),...t}));Uu.displayName=Fu.displayName;const Ku=({className:e,...t})=>u.jsx("span",{className:O("ml-auto text-xs tracking-widest opacity-60",e),...t});Ku.displayName="DropdownMenuShortcut";var wC=e=>e.type==="checkbox",xC=e=>e instanceof Date,qu=e=>e==null;const CC=e=>typeof e=="object";var un=e=>!qu(e)&&!Array.isArray(e)&&CC(e)&&!xC(e),NC=e=>un(e)&&e.target?wC(e.target)?e.target.checked:e.target.value:e,MC=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,SC=(e,t)=>e.has(MC(t)),EC=e=>{const t=e.constructor&&e.constructor.prototype;return un(t)&&t.hasOwnProperty("isPrototypeOf")},PC=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function la(e){let t;const n=Array.isArray(e),r=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(!(PC&&(e instanceof Blob||r))&&(n||un(e)))if(t=n?[]:{},!n&&!EC(e))t=e;else for(const o in e)e.hasOwnProperty(o)&&(t[o]=la(e[o]));else return e;return t}var Xu=e=>Array.isArray(e)?e.filter(Boolean):[],ua=e=>e===void 0,Le=(e,t,n)=>{if(!t||!un(e))return n;const r=Xu(t.split(/[,[\].]+?/)).reduce((o,a)=>qu(o)?o:o[a],e);return ua(r)||r===e?ua(e[t])?n:e[t]:r},Qu=e=>typeof e=="boolean",kC=e=>/^\w*$/.test(e),TC=e=>Xu(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Zu=(e,t,n)=>{let r=-1;const o=kC(t)?[t]:TC(t),a=o.length,s=a-1;for(;++r<a;){const i=o[r];let c=n;if(r!==s){const d=e[i];c=un(d)||Array.isArray(d)?d:isNaN(+o[r+1])?{}:[]}if(i==="__proto__"||i==="constructor"||i==="prototype")return;e[i]=c,e=e[i]}return e};const Ju={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},ed={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},td=x.createContext(null),Lr=()=>x.useContext(td),DC=e=>{const{children:t,...n}=e;return x.createElement(td.Provider,{value:n},t)};var OC=(e,t,n,r=!0)=>{const o={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(o,a,{get:()=>{const s=a;return t._proxyFormState[s]!==ed.all&&(t._proxyFormState[s]=!r||ed.all),n&&(n[s]=!0),e[s]}});return o},AC=e=>un(e)&&!Object.keys(e).length,_C=(e,t,n,r)=>{n(e);const{name:o,...a}=e;return AC(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(s=>t[s]===!r)},RC=e=>Array.isArray(e)?e:[e],nd=(e,t,n)=>!e||!t||e===t||RC(e).some(r=>r&&(n?r===t:r.startsWith(t)||t.startsWith(r)));function rd(e){const t=x.useRef(e);t.current=e,x.useEffect(()=>{const n=!e.disabled&&t.current.subject&&t.current.subject.subscribe({next:t.current.next});return()=>{n&&n.unsubscribe()}},[e.disabled])}function IC(e){const t=Lr(),{control:n=t.control,disabled:r,name:o,exact:a}=e,[s,i]=x.useState(n._formState),c=x.useRef(!0),d=x.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),f=x.useRef(o);return f.current=o,rd({disabled:r,next:m=>c.current&&nd(f.current,m.name,a)&&_C(m,d.current,n._updateFormState)&&i({...n._formState,...m}),subject:n._subjects.state}),x.useEffect(()=>(c.current=!0,d.current.isValid&&n._updateValid(!0),()=>{c.current=!1}),[n]),x.useMemo(()=>OC(s,n,d.current,!1),[s,n])}var jC=e=>typeof e=="string",FC=(e,t,n,r,o)=>jC(e)?Le(n,e,o):Array.isArray(e)?e.map(a=>Le(n,a)):n;function $C(e){const t=Lr(),{control:n=t.control,name:r,defaultValue:o,disabled:a,exact:s}=e,i=x.useRef(r);i.current=r,rd({disabled:a,subject:n._subjects.values,next:f=>{nd(i.current,f.name,s)&&d(la(FC(i.current,n._names,f.values||n._formValues,!1,o)))}});const[c,d]=x.useState(n._getWatch(r,o));return x.useEffect(()=>n._removeUnmounted()),c}function WC(e){const t=Lr(),{name:n,disabled:r,control:o=t.control,shouldUnregister:a}=e,s=SC(o._names.array,n),i=$C({control:o,name:n,defaultValue:Le(o._formValues,n,Le(o._defaultValues,n,e.defaultValue)),exact:!0}),c=IC({control:o,name:n,exact:!0}),d=x.useRef(o.register(n,{...e.rules,value:i,...Qu(e.disabled)?{disabled:e.disabled}:{}})),f=x.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Le(c.errors,n)},isDirty:{enumerable:!0,get:()=>!!Le(c.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!Le(c.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!Le(c.validatingFields,n)},error:{enumerable:!0,get:()=>Le(c.errors,n)}}),[c,n]),m=x.useMemo(()=>({name:n,value:i,...Qu(r)||c.disabled?{disabled:c.disabled||r}:{},onChange:p=>d.current.onChange({target:{value:NC(p),name:n},type:Ju.CHANGE}),onBlur:()=>d.current.onBlur({target:{value:Le(o._formValues,n),name:n},type:Ju.BLUR}),ref:p=>{const h=Le(o._fields,n);h&&p&&(h._f.ref={focus:()=>p.focus(),select:()=>p.select(),setCustomValidity:v=>p.setCustomValidity(v),reportValidity:()=>p.reportValidity()})}}),[n,o._formValues,r,c.disabled,i,o._fields]);return x.useEffect(()=>{const p=o._options.shouldUnregister||a,h=(v,g)=>{const y=Le(o._fields,v);y&&y._f&&(y._f.mount=g)};if(h(n,!0),p){const v=la(Le(o._options.defaultValues,n));Zu(o._defaultValues,n,v),ua(Le(o._formValues,n))&&Zu(o._formValues,n,v)}return!s&&o.register(n),()=>{(s?p&&!o._state.action:p)?o.unregister(n):h(n,!1)}},[n,o,s,a]),x.useEffect(()=>{o._updateDisabledField({disabled:r,fields:o._fields,name:n})},[r,n,o]),x.useMemo(()=>({field:m,formState:c,fieldState:f}),[m,c,f])}const LC=e=>e.render(WC(e));var BC="Label",od=l.forwardRef((e,t)=>u.jsx(F.label,{...e,ref:t,onMouseDown:n=>{var o;n.target.closest("button, input, select, textarea")||((o=e.onMouseDown)==null||o.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));od.displayName=BC;var ad=od;const VC=Kt("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),da=l.forwardRef(({className:e,...t},n)=>u.jsx(ad,{ref:n,className:O(VC(),e),...t}));da.displayName=ad.displayName;const YC=DC,sd=l.createContext({}),GC=({...e})=>u.jsx(sd.Provider,{value:{name:e.name},children:u.jsx(LC,{...e})}),Hn=()=>{const e=l.useContext(sd),t=l.useContext(id),{getFieldState:n,formState:r}=Lr(),o=n(e.name,r);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}},id=l.createContext({}),cd=l.forwardRef(({className:e,...t},n)=>{const r=l.useId();return u.jsx(id.Provider,{value:{id:r},children:u.jsx("div",{ref:n,className:O("space-y-2",e),...t})})});cd.displayName="FormItem";const ld=l.forwardRef(({className:e,...t},n)=>{const{error:r,formItemId:o}=Hn();return u.jsx(da,{ref:n,className:O(r&&"text-destructive",e),htmlFor:o,...t})});ld.displayName="FormLabel";const ud=l.forwardRef(({...e},t)=>{const{error:n,formItemId:r,formDescriptionId:o,formMessageId:a}=Hn();return u.jsx(it,{ref:t,id:r,"aria-describedby":n?`${o} ${a}`:`${o}`,"aria-invalid":!!n,...e})});ud.displayName="FormControl";const dd=l.forwardRef(({className:e,...t},n)=>{const{formDescriptionId:r}=Hn();return u.jsx("p",{ref:n,id:r,className:O("text-[0.8rem] text-muted-foreground",e),...t})});dd.displayName="FormDescription";const fd=l.forwardRef(({className:e,children:t,...n},r)=>{const{error:o,formMessageId:a}=Hn(),s=o?String(o==null?void 0:o.message):t;return s?u.jsx("p",{ref:r,id:a,className:O("text-[0.8rem] font-medium text-destructive",e),...n,children:s}):null});fd.displayName="FormMessage";var zC="VisuallyHidden",fa=l.forwardRef((e,t)=>u.jsx(F.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}}));fa.displayName=zC;var md=fa,dn="NavigationMenu",[ma,hd,HC]=Wn(dn),[ha,UC,KC]=Wn(dn),[pa,OS]=Te(dn,[HC,KC]),[qC,qe]=pa(dn),[XC,QC]=pa(dn),pd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:r,onValueChange:o,defaultValue:a,delayDuration:s=200,skipDelayDuration:i=300,orientation:c="horizontal",dir:d,...f}=e,[m,p]=l.useState(null),h=ne(t,R=>p(R)),v=Yt(d),g=l.useRef(0),y=l.useRef(0),w=l.useRef(0),[b,C]=l.useState(!0),[M="",S]=Ie({prop:r,onChange:R=>{const $=R!=="",V=i>0;$?(window.clearTimeout(w.current),V&&C(!1)):(window.clearTimeout(w.current),w.current=window.setTimeout(()=>C(!0),i)),o==null||o(R)},defaultProp:a}),k=l.useCallback(()=>{window.clearTimeout(y.current),y.current=window.setTimeout(()=>S(""),150)},[S]),P=l.useCallback(R=>{window.clearTimeout(y.current),S(R)},[S]),D=l.useCallback(R=>{M===R?window.clearTimeout(y.current):g.current=window.setTimeout(()=>{window.clearTimeout(y.current),S(R)},s)},[M,S,s]);return l.useEffect(()=>()=>{window.clearTimeout(g.current),window.clearTimeout(y.current),window.clearTimeout(w.current)},[]),u.jsx(vd,{scope:n,isRootMenu:!0,value:M,dir:v,orientation:c,rootNavigationMenu:m,onTriggerEnter:R=>{window.clearTimeout(g.current),b?D(R):P(R)},onTriggerLeave:()=>{window.clearTimeout(g.current),k()},onContentEnter:()=>window.clearTimeout(y.current),onContentLeave:k,onItemSelect:R=>{S($=>$===R?"":R)},onItemDismiss:()=>S(""),children:u.jsx(F.nav,{"aria-label":"Main","data-orientation":c,dir:v,...f,ref:h})})});pd.displayName=dn;var gd="NavigationMenuSub",ZC=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:r,onValueChange:o,defaultValue:a,orientation:s="horizontal",...i}=e,c=qe(gd,n),[d="",f]=Ie({prop:r,onChange:o,defaultProp:a});return u.jsx(vd,{scope:n,isRootMenu:!1,value:d,dir:c.dir,orientation:s,rootNavigationMenu:c.rootNavigationMenu,onTriggerEnter:m=>f(m),onItemSelect:m=>f(m),onItemDismiss:()=>f(""),children:u.jsx(F.div,{"data-orientation":s,...i,ref:t})})});ZC.displayName=gd;var vd=e=>{const{scope:t,isRootMenu:n,rootNavigationMenu:r,dir:o,orientation:a,children:s,value:i,onItemSelect:c,onItemDismiss:d,onTriggerEnter:f,onTriggerLeave:m,onContentEnter:p,onContentLeave:h}=e,[v,g]=l.useState(null),[y,w]=l.useState(new Map),[b,C]=l.useState(null);return u.jsx(qC,{scope:t,isRootMenu:n,rootNavigationMenu:r,value:i,previousValue:$n(i),baseId:je(),dir:o,orientation:a,viewport:v,onViewportChange:g,indicatorTrack:b,onIndicatorTrackChange:C,onTriggerEnter:Ne(f),onTriggerLeave:Ne(m),onContentEnter:Ne(p),onContentLeave:Ne(h),onItemSelect:Ne(c),onItemDismiss:Ne(d),onViewportContentChange:l.useCallback((M,S)=>{w(k=>(k.set(M,S),new Map(k)))},[]),onViewportContentRemove:l.useCallback(M=>{w(S=>S.has(M)?(S.delete(M),new Map(S)):S)},[]),children:u.jsx(ma.Provider,{scope:t,children:u.jsx(XC,{scope:t,items:y,children:s})})})},yd="NavigationMenuList",bd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...r}=e,o=qe(yd,n),a=u.jsx(F.ul,{"data-orientation":o.orientation,...r,ref:t});return u.jsx(F.div,{style:{position:"relative"},ref:o.onIndicatorTrackChange,children:u.jsx(ma.Slot,{scope:n,children:o.isRootMenu?u.jsx(Dd,{asChild:!0,children:a}):a})})});bd.displayName=yd;var wd="NavigationMenuItem",[JC,xd]=pa(wd),Cd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:r,...o}=e,a=je(),s=r||a||"LEGACY_REACT_AUTO_VALUE",i=l.useRef(null),c=l.useRef(null),d=l.useRef(null),f=l.useRef(()=>{}),m=l.useRef(!1),p=l.useCallback((v="start")=>{if(i.current){f.current();const g=ba(i.current);g.length&&wa(v==="start"?g:g.reverse())}},[]),h=l.useCallback(()=>{if(i.current){const v=ba(i.current);v.length&&(f.current=sN(v))}},[]);return u.jsx(JC,{scope:n,value:s,triggerRef:c,contentRef:i,focusProxyRef:d,wasEscapeCloseRef:m,onEntryKeyDown:p,onFocusProxyEnter:p,onRootContentClose:h,onContentFocusOutside:h,children:u.jsx(F.li,{...o,ref:t})})});Cd.displayName=wd;var ga="NavigationMenuTrigger",Nd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,disabled:r,...o}=e,a=qe(ga,e.__scopeNavigationMenu),s=xd(ga,e.__scopeNavigationMenu),i=l.useRef(null),c=ne(i,s.triggerRef,t),d=_d(a.baseId,s.value),f=Rd(a.baseId,s.value),m=l.useRef(!1),p=l.useRef(!1),h=s.value===a.value;return u.jsxs(u.Fragment,{children:[u.jsx(ma.ItemSlot,{scope:n,value:s.value,children:u.jsx(Ad,{asChild:!0,children:u.jsx(F.button,{id:d,disabled:r,"data-disabled":r?"":void 0,"data-state":Ca(h),"aria-expanded":h,"aria-controls":f,...o,ref:c,onPointerEnter:A(e.onPointerEnter,()=>{p.current=!1,s.wasEscapeCloseRef.current=!1}),onPointerMove:A(e.onPointerMove,Vr(()=>{r||p.current||s.wasEscapeCloseRef.current||m.current||(a.onTriggerEnter(s.value),m.current=!0)})),onPointerLeave:A(e.onPointerLeave,Vr(()=>{r||(a.onTriggerLeave(),m.current=!1)})),onClick:A(e.onClick,()=>{a.onItemSelect(s.value),p.current=h}),onKeyDown:A(e.onKeyDown,v=>{const y={horizontal:"ArrowDown",vertical:a.dir==="rtl"?"ArrowLeft":"ArrowRight"}[a.orientation];h&&v.key===y&&(s.onEntryKeyDown(),v.preventDefault())})})})}),h&&u.jsxs(u.Fragment,{children:[u.jsx(md,{"aria-hidden":!0,tabIndex:0,ref:s.focusProxyRef,onFocus:v=>{const g=s.contentRef.current,y=v.relatedTarget,w=y===i.current,b=g==null?void 0:g.contains(y);(w||!b)&&s.onFocusProxyEnter(w?"start":"end")}}),a.viewport&&u.jsx("span",{"aria-owns":f})]})]})});Nd.displayName=ga;var eN="NavigationMenuLink",Md="navigationMenu.linkSelect",Sd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,active:r,onSelect:o,...a}=e;return u.jsx(Ad,{asChild:!0,children:u.jsx(F.a,{"data-active":r?"":void 0,"aria-current":r?"page":void 0,...a,ref:t,onClick:A(e.onClick,s=>{const i=s.target,c=new CustomEvent(Md,{bubbles:!0,cancelable:!0});if(i.addEventListener(Md,d=>o==null?void 0:o(d),{once:!0}),rr(i,c),!c.defaultPrevented&&!s.metaKey){const d=new CustomEvent(Br,{bubbles:!0,cancelable:!0});rr(i,d)}},{checkForDefaultPrevented:!1})})})});Sd.displayName=eN;var va="NavigationMenuIndicator",Ed=l.forwardRef((e,t)=>{const{forceMount:n,...r}=e,o=qe(va,e.__scopeNavigationMenu),a=!!o.value;return o.indicatorTrack?Zn.createPortal(u.jsx(De,{present:n||a,children:u.jsx(tN,{...r,ref:t})}),o.indicatorTrack):null});Ed.displayName=va;var tN=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...r}=e,o=qe(va,n),a=hd(n),[s,i]=l.useState(null),[c,d]=l.useState(null),f=o.orientation==="horizontal",m=!!o.value;l.useEffect(()=>{var g;const v=(g=a().find(y=>y.value===o.value))==null?void 0:g.ref.current;v&&i(v)},[a,o.value]);const p=()=>{s&&d({size:f?s.offsetWidth:s.offsetHeight,offset:f?s.offsetLeft:s.offsetTop})};return xa(s,p),xa(o.indicatorTrack,p),c?u.jsx(F.div,{"aria-hidden":!0,"data-state":m?"visible":"hidden","data-orientation":o.orientation,...r,ref:t,style:{position:"absolute",...f?{left:0,width:c.size+"px",transform:`translateX(${c.offset}px)`}:{top:0,height:c.size+"px",transform:`translateY(${c.offset}px)`},...r.style}}):null}),fn="NavigationMenuContent",Pd=l.forwardRef((e,t)=>{const{forceMount:n,...r}=e,o=qe(fn,e.__scopeNavigationMenu),a=xd(fn,e.__scopeNavigationMenu),s=ne(a.contentRef,t),i=a.value===o.value,c={value:a.value,triggerRef:a.triggerRef,focusProxyRef:a.focusProxyRef,wasEscapeCloseRef:a.wasEscapeCloseRef,onContentFocusOutside:a.onContentFocusOutside,onRootContentClose:a.onRootContentClose,...r};return o.viewport?u.jsx(nN,{forceMount:n,...c,ref:s}):u.jsx(De,{present:n||i,children:u.jsx(kd,{"data-state":Ca(i),...c,ref:s,onPointerEnter:A(e.onPointerEnter,o.onContentEnter),onPointerLeave:A(e.onPointerLeave,Vr(o.onContentLeave)),style:{pointerEvents:!i&&o.isRootMenu?"none":void 0,...c.style}})})});Pd.displayName=fn;var nN=l.forwardRef((e,t)=>{const n=qe(fn,e.__scopeNavigationMenu),{onViewportContentChange:r,onViewportContentRemove:o}=n;return Ee(()=>{r(e.value,{ref:t,...e})},[e,t,r]),Ee(()=>()=>o(e.value),[e.value,o]),null}),Br="navigationMenu.rootContentDismiss",kd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:r,triggerRef:o,focusProxyRef:a,wasEscapeCloseRef:s,onRootContentClose:i,onContentFocusOutside:c,...d}=e,f=qe(fn,n),m=l.useRef(null),p=ne(m,t),h=_d(f.baseId,r),v=Rd(f.baseId,r),g=hd(n),y=l.useRef(null),{onItemDismiss:w}=f;l.useEffect(()=>{const C=m.current;if(f.isRootMenu&&C){const M=()=>{var S;w(),i(),C.contains(document.activeElement)&&((S=o.current)==null||S.focus())};return C.addEventListener(Br,M),()=>C.removeEventListener(Br,M)}},[f.isRootMenu,e.value,o,w,i]);const b=l.useMemo(()=>{const M=g().map($=>$.value);f.dir==="rtl"&&M.reverse();const S=M.indexOf(f.value),k=M.indexOf(f.previousValue),P=r===f.value,D=k===M.indexOf(r);if(!P&&!D)return y.current;const R=(()=>{if(S!==k){if(P&&k!==-1)return S>k?"from-end":"from-start";if(D&&S!==-1)return S>k?"to-start":"to-end"}return null})();return y.current=R,R},[f.previousValue,f.value,f.dir,g,r]);return u.jsx(Dd,{asChild:!0,children:u.jsx($t,{id:v,"aria-labelledby":h,"data-motion":b,"data-orientation":f.orientation,...d,ref:p,disableOutsidePointerEvents:!1,onDismiss:()=>{var M;const C=new Event(Br,{bubbles:!0,cancelable:!0});(M=m.current)==null||M.dispatchEvent(C)},onFocusOutside:A(e.onFocusOutside,C=>{var S;c();const M=C.target;(S=f.rootNavigationMenu)!=null&&S.contains(M)&&C.preventDefault()}),onPointerDownOutside:A(e.onPointerDownOutside,C=>{var P;const M=C.target,S=g().some(D=>{var R;return(R=D.ref.current)==null?void 0:R.contains(M)}),k=f.isRootMenu&&((P=f.viewport)==null?void 0:P.contains(M));(S||k||!f.isRootMenu)&&C.preventDefault()}),onKeyDown:A(e.onKeyDown,C=>{var k;const M=C.altKey||C.ctrlKey||C.metaKey;if(C.key==="Tab"&&!M){const P=ba(C.currentTarget),D=document.activeElement,R=P.findIndex(_=>_===D),V=C.shiftKey?P.slice(0,R).reverse():P.slice(R+1,P.length);wa(V)?C.preventDefault():(k=a.current)==null||k.focus()}}),onEscapeKeyDown:A(e.onEscapeKeyDown,C=>{s.current=!0})})})}),ya="NavigationMenuViewport",Td=l.forwardRef((e,t)=>{const{forceMount:n,...r}=e,a=!!qe(ya,e.__scopeNavigationMenu).value;return u.jsx(De,{present:n||a,children:u.jsx(rN,{...r,ref:t})})});Td.displayName=ya;var rN=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,children:r,...o}=e,a=qe(ya,n),s=ne(t,a.onViewportChange),i=QC(fn,e.__scopeNavigationMenu),[c,d]=l.useState(null),[f,m]=l.useState(null),p=c?(c==null?void 0:c.width)+"px":void 0,h=c?(c==null?void 0:c.height)+"px":void 0,v=!!a.value,g=v?a.value:a.previousValue;return xa(f,()=>{f&&d({width:f.offsetWidth,height:f.offsetHeight})}),u.jsx(F.div,{"data-state":Ca(v),"data-orientation":a.orientation,...o,ref:s,style:{pointerEvents:!v&&a.isRootMenu?"none":void 0,"--radix-navigation-menu-viewport-width":p,"--radix-navigation-menu-viewport-height":h,...o.style},onPointerEnter:A(e.onPointerEnter,a.onContentEnter),onPointerLeave:A(e.onPointerLeave,Vr(a.onContentLeave)),children:Array.from(i.items).map(([w,{ref:b,forceMount:C,...M}])=>{const S=g===w;return u.jsx(De,{present:C||S,children:u.jsx(kd,{...M,ref:xn(b,k=>{S&&k&&m(k)})})},w)})})}),oN="FocusGroup",Dd=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...r}=e,o=qe(oN,n);return u.jsx(ha.Provider,{scope:n,children:u.jsx(ha.Slot,{scope:n,children:u.jsx(F.div,{dir:o.dir,...r,ref:t})})})}),Od=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],aN="FocusGroupItem",Ad=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...r}=e,o=UC(n),a=qe(aN,n);return u.jsx(ha.ItemSlot,{scope:n,children:u.jsx(F.button,{...r,ref:t,onKeyDown:A(e.onKeyDown,s=>{if(["Home","End",...Od].includes(s.key)){let c=o().map(m=>m.ref.current);if([a.dir==="rtl"?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(s.key)&&c.reverse(),Od.includes(s.key)){const m=c.indexOf(s.currentTarget);c=c.slice(m+1)}setTimeout(()=>wa(c)),s.preventDefault()}})})})});function ba(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function wa(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}function sN(e){return e.forEach(t=>{t.dataset.tabindex=t.getAttribute("tabindex")||"",t.setAttribute("tabindex","-1")}),()=>{e.forEach(t=>{const n=t.dataset.tabindex;t.setAttribute("tabindex",n)})}}function xa(e,t){const n=Ne(t);Ee(()=>{let r=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(n)});return o.observe(e),()=>{window.cancelAnimationFrame(r),o.unobserve(e)}}},[e,n])}function Ca(e){return e?"open":"closed"}function _d(e,t){return`${e}-trigger-${t}`}function Rd(e,t){return`${e}-content-${t}`}function Vr(e){return t=>t.pointerType==="mouse"?e(t):void 0}var Id=pd,jd=bd,iN=Cd,Fd=Nd,cN=Sd,$d=Ed,Wd=Pd,Ld=Td;const Bd=l.forwardRef(({className:e,children:t,...n},r)=>u.jsxs(Id,{ref:r,className:O("relative z-10 flex max-w-max flex-1 items-center justify-center",e),...n,children:[t,u.jsx(Na,{})]}));Bd.displayName=Id.displayName;const Vd=l.forwardRef(({className:e,...t},n)=>u.jsx(jd,{ref:n,className:O("group flex flex-1 list-none items-center justify-center space-x-1",e),...t}));Vd.displayName=jd.displayName;const lN=iN,Yd=Kt("group inline-flex h-10 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-[active]:bg-accent/50 data-[state=open]:bg-accent/50"),Gd=l.forwardRef(({className:e,children:t,...n},r)=>u.jsxs(Fd,{ref:r,className:O(Yd(),"group",e),...n,children:[t," ",u.jsx(So,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));Gd.displayName=Fd.displayName;const zd=l.forwardRef(({className:e,...t},n)=>u.jsx(Wd,{ref:n,className:O("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}));zd.displayName=Wd.displayName;const uN=cN,Na=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{className:O("absolute left-0 top-full flex justify-center"),children:u.jsx(Ld,{className:O("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-lg 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:n,...t})}));Na.displayName=Ld.displayName;const Hd=l.forwardRef(({className:e,...t},n)=>u.jsx($d,{ref:n,className:O("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:u.jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));Hd.displayName=$d.displayName;const Ma=({className:e,...t})=>u.jsx("nav",{role:"navigation","aria-label":"pagination",className:O("mx-auto flex w-full justify-center",e),...t});Ma.displayName="Pagination";const Sa=l.forwardRef(({className:e,...t},n)=>u.jsx("ul",{ref:n,className:O("flex flex-row items-center gap-1",e),...t}));Sa.displayName="PaginationContent";const Un=l.forwardRef(({className:e,...t},n)=>u.jsx("li",{ref:n,className:O("",e),...t}));Un.displayName="PaginationItem";const Kn=({className:e,isActive:t,size:n="icon",...r})=>u.jsx(lt,{"aria-current":t?"page":void 0,className:O(Sn({variant:t?"default":"outline",size:n}),t?"text-primary-foreground":"text-foreground",e),...r,children:r.children});Kn.displayName="PaginationLink";const Ea=({className:e,...t})=>u.jsx(Kn,{"aria-label":"Previous page",size:"default",className:O("gap-1",e),...t,children:u.jsx(Ai,{className:"h-4 w-4"})});Ea.displayName="PaginationPrevious";const Pa=({className:e,...t})=>u.jsx(Kn,{"aria-label":"Next page",size:"default",className:O("gap-1",e),...t,children:u.jsx(Eo,{className:"h-4 w-4"})});Pa.displayName="PaginationNext";const Ud=({className:e,...t})=>u.jsxs("span",{"aria-hidden":!0,className:O("flex h-9 w-9 items-center justify-center",e),...t,children:[u.jsx(Gg,{className:"h-4 w-4"}),u.jsx("span",{className:"sr-only",children:"More pages"})]});Ud.displayName="PaginationEllipsis";var ka="Progress",Ta=100,[dN,AS]=Te(ka),[fN,mN]=dN(ka),Kd=l.forwardRef((e,t)=>{const{__scopeProgress:n,value:r=null,max:o,getValueLabel:a=hN,...s}=e;(o||o===0)&&!Zd(o)&&console.error(pN(`${o}`,"Progress"));const i=Zd(o)?o:Ta;r!==null&&!Jd(r,i)&&console.error(gN(`${r}`,"Progress"));const c=Jd(r,i)?r:null,d=Yr(c)?a(c,i):void 0;return u.jsx(fN,{scope:n,value:c,max:i,children:u.jsx(F.div,{"aria-valuemax":i,"aria-valuemin":0,"aria-valuenow":Yr(c)?c:void 0,"aria-valuetext":d,role:"progressbar","data-state":Qd(c,i),"data-value":c??void 0,"data-max":i,...s,ref:t})})});Kd.displayName=ka;var qd="ProgressIndicator",Xd=l.forwardRef((e,t)=>{const{__scopeProgress:n,...r}=e,o=mN(qd,n);return u.jsx(F.div,{"data-state":Qd(o.value,o.max),"data-value":o.value??void 0,"data-max":o.max,...r,ref:t})});Xd.displayName=qd;function hN(e,t){return`${Math.round(e/t*100)}%`}function Qd(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function Yr(e){return typeof e=="number"}function Zd(e){return Yr(e)&&!isNaN(e)&&e>0}function Jd(e,t){return Yr(e)&&!isNaN(e)&&e<=t&&e>=0}function pN(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${Ta}\`.`}function gN(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
191
+ */const jg=we("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),Dg=["top","right","bottom","left"],ct=Math.min,Te=Math.max,Wn=Math.round,zn=Math.floor,He=e=>({x:e,y:e}),Og={left:"right",right:"left",bottom:"top",top:"bottom"},Lg={start:"end",end:"start"};function Jo(e,t,n){return Te(e,ct(t,n))}function tt(e,t){return typeof e=="function"?e(t):e}function nt(e){return e.split("-")[0]}function jt(e){return e.split("-")[1]}function Zo(e){return e==="x"?"y":"x"}function Qo(e){return e==="y"?"height":"width"}function ut(e){return["top","bottom"].includes(nt(e))?"y":"x"}function er(e){return Zo(ut(e))}function Fg(e,t,n){n===void 0&&(n=!1);const o=jt(e),r=er(e),a=Qo(r);let s=r==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=Gn(s)),[s,Gn(s)]}function $g(e){const t=Gn(e);return[tr(e),t,tr(t)]}function tr(e){return e.replace(/start|end/g,t=>Lg[t])}function Vg(e,t,n){const o=["left","right"],r=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?r:o:t?o:r;case"left":case"right":return t?a:s;default:return[]}}function Bg(e,t,n,o){const r=jt(e);let a=Vg(nt(e),n==="start",o);return r&&(a=a.map(s=>s+"-"+r),t&&(a=a.concat(a.map(tr)))),a}function Gn(e){return e.replace(/left|right|bottom|top/g,t=>Og[t])}function Wg(e){return{top:0,right:0,bottom:0,left:0,...e}}function ri(e){return typeof e!="number"?Wg(e):{top:e,right:e,bottom:e,left:e}}function Hn(e){const{x:t,y:n,width:o,height:r}=e;return{width:o,height:r,top:n,left:t,right:t+o,bottom:n+r,x:t,y:n}}function ai(e,t,n){let{reference:o,floating:r}=e;const a=ut(t),s=er(t),i=Qo(s),u=nt(t),d=a==="y",f=o.x+o.width/2-r.width/2,m=o.y+o.height/2-r.height/2,h=o[i]/2-r[i]/2;let p;switch(u){case"top":p={x:f,y:o.y-r.height};break;case"bottom":p={x:f,y:o.y+o.height};break;case"right":p={x:o.x+o.width,y:m};break;case"left":p={x:o.x-r.width,y:m};break;default:p={x:o.x,y:o.y}}switch(jt(t)){case"start":p[s]-=h*(n&&d?-1:1);break;case"end":p[s]+=h*(n&&d?-1:1);break}return p}const zg=async(e,t,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:a=[],platform:s}=n,i=a.filter(Boolean),u=await(s.isRTL==null?void 0:s.isRTL(t));let d=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:f,y:m}=ai(d,o,u),h=o,p={},b=0;for(let g=0;g<i.length;g++){const{name:v,fn:y}=i[g],{x:w,y:C,data:N,reset:E}=await y({x:f,y:m,initialPlacement:o,placement:h,strategy:r,middlewareData:p,rects:d,platform:s,elements:{reference:e,floating:t}});f=w??f,m=C??m,p={...p,[v]:{...p[v],...N}},E&&b<=50&&(b++,typeof E=="object"&&(E.placement&&(h=E.placement),E.rects&&(d=E.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:r}):E.rects),{x:f,y:m}=ai(d,h,u)),g=-1)}return{x:f,y:m,placement:h,strategy:r,middlewareData:p}};async function tn(e,t){var n;t===void 0&&(t={});const{x:o,y:r,platform:a,rects:s,elements:i,strategy:u}=e,{boundary:d="clippingAncestors",rootBoundary:f="viewport",elementContext:m="floating",altBoundary:h=!1,padding:p=0}=tt(t,e),b=ri(p),v=i[h?m==="floating"?"reference":"floating":m],y=Hn(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(v)))==null||n?v:v.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(i.floating)),boundary:d,rootBoundary:f,strategy:u})),w=m==="floating"?{x:o,y:r,width:s.floating.width,height:s.floating.height}:s.reference,C=await(a.getOffsetParent==null?void 0:a.getOffsetParent(i.floating)),N=await(a.isElement==null?void 0:a.isElement(C))?await(a.getScale==null?void 0:a.getScale(C))||{x:1,y:1}:{x:1,y:1},E=Hn(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:w,offsetParent:C,strategy:u}):w);return{top:(y.top-E.top+b.top)/N.y,bottom:(E.bottom-y.bottom+b.bottom)/N.y,left:(y.left-E.left+b.left)/N.x,right:(E.right-y.right+b.right)/N.x}}const Gg=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:o,placement:r,rects:a,platform:s,elements:i,middlewareData:u}=t,{element:d,padding:f=0}=tt(e,t)||{};if(d==null)return{};const m=ri(f),h={x:n,y:o},p=er(r),b=Qo(p),g=await s.getDimensions(d),v=p==="y",y=v?"top":"left",w=v?"bottom":"right",C=v?"clientHeight":"clientWidth",N=a.reference[b]+a.reference[p]-h[p]-a.floating[b],E=h[p]-a.reference[p],A=await(s.getOffsetParent==null?void 0:s.getOffsetParent(d));let M=A?A[C]:0;(!M||!await(s.isElement==null?void 0:s.isElement(A)))&&(M=i.floating[C]||a.floating[b]);const I=N/2-E/2,j=M/2-g[b]/2-1,B=ct(m[y],j),z=ct(m[w],j),O=B,U=M-g[b]-z,W=M/2-g[b]/2+I,oe=Jo(O,W,U),$=!u.arrow&&jt(r)!=null&&W!==oe&&a.reference[b]/2-(W<O?B:z)-g[b]/2<0,G=$?W<O?W-O:W-U:0;return{[p]:h[p]+G,data:{[p]:oe,centerOffset:W-oe-G,...$&&{alignmentOffset:G}},reset:$}}}),Hg=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,o;const{placement:r,middlewareData:a,rects:s,initialPlacement:i,platform:u,elements:d}=t,{mainAxis:f=!0,crossAxis:m=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:g=!0,...v}=tt(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const y=nt(r),w=ut(i),C=nt(i)===i,N=await(u.isRTL==null?void 0:u.isRTL(d.floating)),E=h||(C||!g?[Gn(i)]:$g(i)),A=b!=="none";!h&&A&&E.push(...Bg(i,g,b,N));const M=[i,...E],I=await tn(t,v),j=[];let B=((o=a.flip)==null?void 0:o.overflows)||[];if(f&&j.push(I[y]),m){const W=Fg(r,s,N);j.push(I[W[0]],I[W[1]])}if(B=[...B,{placement:r,overflows:j}],!j.every(W=>W<=0)){var z,O;const W=(((z=a.flip)==null?void 0:z.index)||0)+1,oe=M[W];if(oe)return{data:{index:W,overflows:B},reset:{placement:oe}};let $=(O=B.filter(G=>G.overflows[0]<=0).sort((G,V)=>G.overflows[1]-V.overflows[1])[0])==null?void 0:O.placement;if(!$)switch(p){case"bestFit":{var U;const G=(U=B.filter(V=>{if(A){const T=ut(V.placement);return T===w||T==="y"}return!0}).map(V=>[V.placement,V.overflows.filter(T=>T>0).reduce((T,H)=>T+H,0)]).sort((V,T)=>V[1]-T[1])[0])==null?void 0:U[0];G&&($=G);break}case"initialPlacement":$=i;break}if(r!==$)return{reset:{placement:$}}}return{}}}};function si(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ii(e){return Dg.some(t=>e[t]>=0)}const Ug=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:o="referenceHidden",...r}=tt(e,t);switch(o){case"referenceHidden":{const a=await tn(t,{...r,elementContext:"reference"}),s=si(a,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:ii(s)}}}case"escaped":{const a=await tn(t,{...r,altBoundary:!0}),s=si(a,n.floating);return{data:{escapedOffsets:s,escaped:ii(s)}}}default:return{}}}}};async function Kg(e,t){const{placement:n,platform:o,elements:r}=e,a=await(o.isRTL==null?void 0:o.isRTL(r.floating)),s=nt(n),i=jt(n),u=ut(n)==="y",d=["left","top"].includes(s)?-1:1,f=a&&u?-1:1,m=tt(t,e);let{mainAxis:h,crossAxis:p,alignmentAxis:b}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return i&&typeof b=="number"&&(p=i==="end"?b*-1:b),u?{x:p*f,y:h*d}:{x:h*d,y:p*f}}const Yg=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,o;const{x:r,y:a,placement:s,middlewareData:i}=t,u=await Kg(t,e);return s===((n=i.offset)==null?void 0:n.placement)&&(o=i.arrow)!=null&&o.alignmentOffset?{}:{x:r+u.x,y:a+u.y,data:{...u,placement:s}}}}},Xg=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:o,placement:r}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:i={fn:v=>{let{x:y,y:w}=v;return{x:y,y:w}}},...u}=tt(e,t),d={x:n,y:o},f=await tn(t,u),m=ut(nt(r)),h=Zo(m);let p=d[h],b=d[m];if(a){const v=h==="y"?"top":"left",y=h==="y"?"bottom":"right",w=p+f[v],C=p-f[y];p=Jo(w,p,C)}if(s){const v=m==="y"?"top":"left",y=m==="y"?"bottom":"right",w=b+f[v],C=b-f[y];b=Jo(w,b,C)}const g=i.fn({...t,[h]:p,[m]:b});return{...g,data:{x:g.x-n,y:g.y-o,enabled:{[h]:a,[m]:s}}}}}},qg=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:o,placement:r,rects:a,middlewareData:s}=t,{offset:i=0,mainAxis:u=!0,crossAxis:d=!0}=tt(e,t),f={x:n,y:o},m=ut(r),h=Zo(m);let p=f[h],b=f[m];const g=tt(i,t),v=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(u){const C=h==="y"?"height":"width",N=a.reference[h]-a.floating[C]+v.mainAxis,E=a.reference[h]+a.reference[C]-v.mainAxis;p<N?p=N:p>E&&(p=E)}if(d){var y,w;const C=h==="y"?"width":"height",N=["top","left"].includes(nt(r)),E=a.reference[m]-a.floating[C]+(N&&((y=s.offset)==null?void 0:y[m])||0)+(N?0:v.crossAxis),A=a.reference[m]+a.reference[C]+(N?0:((w=s.offset)==null?void 0:w[m])||0)-(N?v.crossAxis:0);b<E?b=E:b>A&&(b=A)}return{[h]:p,[m]:b}}}},Jg=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,o;const{placement:r,rects:a,platform:s,elements:i}=t,{apply:u=()=>{},...d}=tt(e,t),f=await tn(t,d),m=nt(r),h=jt(r),p=ut(r)==="y",{width:b,height:g}=a.floating;let v,y;m==="top"||m==="bottom"?(v=m,y=h===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(y=m,v=h==="end"?"top":"bottom");const w=g-f.top-f.bottom,C=b-f.left-f.right,N=ct(g-f[v],w),E=ct(b-f[y],C),A=!t.middlewareData.shift;let M=N,I=E;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(I=C),(o=t.middlewareData.shift)!=null&&o.enabled.y&&(M=w),A&&!h){const B=Te(f.left,0),z=Te(f.right,0),O=Te(f.top,0),U=Te(f.bottom,0);p?I=b-2*(B!==0||z!==0?B+z:Te(f.left,f.right)):M=g-2*(O!==0||U!==0?O+U:Te(f.top,f.bottom))}await u({...t,availableWidth:I,availableHeight:M});const j=await s.getDimensions(i.floating);return b!==j.width||g!==j.height?{reset:{rects:!0}}:{}}}};function Un(){return typeof window<"u"}function Dt(e){return li(e)?(e.nodeName||"").toLowerCase():"#document"}function Me(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ue(e){var t;return(t=(li(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function li(e){return Un()?e instanceof Node||e instanceof Me(e).Node:!1}function De(e){return Un()?e instanceof Element||e instanceof Me(e).Element:!1}function Ke(e){return Un()?e instanceof HTMLElement||e instanceof Me(e).HTMLElement:!1}function ci(e){return!Un()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Me(e).ShadowRoot}function nn(e){const{overflow:t,overflowX:n,overflowY:o,display:r}=Oe(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+n)&&!["inline","contents"].includes(r)}function Zg(e){return["table","td","th"].includes(Dt(e))}function Kn(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function nr(e){const t=or(),n=De(e)?Oe(e):e;return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(o=>(n.willChange||"").includes(o))||["paint","layout","strict","content"].some(o=>(n.contain||"").includes(o))}function Qg(e){let t=dt(e);for(;Ke(t)&&!Ot(t);){if(nr(t))return t;if(Kn(t))return null;t=dt(t)}return null}function or(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Ot(e){return["html","body","#document"].includes(Dt(e))}function Oe(e){return Me(e).getComputedStyle(e)}function Yn(e){return De(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function dt(e){if(Dt(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ci(e)&&e.host||Ue(e);return ci(t)?t.host:t}function ui(e){const t=dt(e);return Ot(t)?e.ownerDocument?e.ownerDocument.body:e.body:Ke(t)&&nn(t)?t:ui(t)}function on(e,t,n){var o;t===void 0&&(t=[]),n===void 0&&(n=!0);const r=ui(e),a=r===((o=e.ownerDocument)==null?void 0:o.body),s=Me(r);if(a){const i=rr(s);return t.concat(s,s.visualViewport||[],nn(r)?r:[],i&&n?on(i):[])}return t.concat(r,on(r,[],n))}function rr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function di(e){const t=Oe(e);let n=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=Ke(e),a=r?e.offsetWidth:n,s=r?e.offsetHeight:o,i=Wn(n)!==a||Wn(o)!==s;return i&&(n=a,o=s),{width:n,height:o,$:i}}function ar(e){return De(e)?e:e.contextElement}function Lt(e){const t=ar(e);if(!Ke(t))return He(1);const n=t.getBoundingClientRect(),{width:o,height:r,$:a}=di(t);let s=(a?Wn(n.width):n.width)/o,i=(a?Wn(n.height):n.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}const eh=He(0);function fi(e){const t=Me(e);return!or()||!t.visualViewport?eh:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function th(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Me(e)?!1:t}function Ct(e,t,n,o){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=e.getBoundingClientRect(),a=ar(e);let s=He(1);t&&(o?De(o)&&(s=Lt(o)):s=Lt(e));const i=th(a,n,o)?fi(a):He(0);let u=(r.left+i.x)/s.x,d=(r.top+i.y)/s.y,f=r.width/s.x,m=r.height/s.y;if(a){const h=Me(a),p=o&&De(o)?Me(o):o;let b=h,g=rr(b);for(;g&&o&&p!==b;){const v=Lt(g),y=g.getBoundingClientRect(),w=Oe(g),C=y.left+(g.clientLeft+parseFloat(w.paddingLeft))*v.x,N=y.top+(g.clientTop+parseFloat(w.paddingTop))*v.y;u*=v.x,d*=v.y,f*=v.x,m*=v.y,u+=C,d+=N,b=Me(g),g=rr(b)}}return Hn({width:f,height:m,x:u,y:d})}function sr(e,t){const n=Yn(e).scrollLeft;return t?t.left+n:Ct(Ue(e)).left+n}function pi(e,t,n){n===void 0&&(n=!1);const o=e.getBoundingClientRect(),r=o.left+t.scrollLeft-(n?0:sr(e,o)),a=o.top+t.scrollTop;return{x:r,y:a}}function nh(e){let{elements:t,rect:n,offsetParent:o,strategy:r}=e;const a=r==="fixed",s=Ue(o),i=t?Kn(t.floating):!1;if(o===s||i&&a)return n;let u={scrollLeft:0,scrollTop:0},d=He(1);const f=He(0),m=Ke(o);if((m||!m&&!a)&&((Dt(o)!=="body"||nn(s))&&(u=Yn(o)),Ke(o))){const p=Ct(o);d=Lt(o),f.x=p.x+o.clientLeft,f.y=p.y+o.clientTop}const h=s&&!m&&!a?pi(s,u,!0):He(0);return{width:n.width*d.x,height:n.height*d.y,x:n.x*d.x-u.scrollLeft*d.x+f.x+h.x,y:n.y*d.y-u.scrollTop*d.y+f.y+h.y}}function oh(e){return Array.from(e.getClientRects())}function rh(e){const t=Ue(e),n=Yn(e),o=e.ownerDocument.body,r=Te(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),a=Te(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let s=-n.scrollLeft+sr(e);const i=-n.scrollTop;return Oe(o).direction==="rtl"&&(s+=Te(t.clientWidth,o.clientWidth)-r),{width:r,height:a,x:s,y:i}}function ah(e,t){const n=Me(e),o=Ue(e),r=n.visualViewport;let a=o.clientWidth,s=o.clientHeight,i=0,u=0;if(r){a=r.width,s=r.height;const d=or();(!d||d&&t==="fixed")&&(i=r.offsetLeft,u=r.offsetTop)}return{width:a,height:s,x:i,y:u}}function sh(e,t){const n=Ct(e,!0,t==="fixed"),o=n.top+e.clientTop,r=n.left+e.clientLeft,a=Ke(e)?Lt(e):He(1),s=e.clientWidth*a.x,i=e.clientHeight*a.y,u=r*a.x,d=o*a.y;return{width:s,height:i,x:u,y:d}}function mi(e,t,n){let o;if(t==="viewport")o=ah(e,n);else if(t==="document")o=rh(Ue(e));else if(De(t))o=sh(t,n);else{const r=fi(e);o={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return Hn(o)}function gi(e,t){const n=dt(e);return n===t||!De(n)||Ot(n)?!1:Oe(n).position==="fixed"||gi(n,t)}function ih(e,t){const n=t.get(e);if(n)return n;let o=on(e,[],!1).filter(i=>De(i)&&Dt(i)!=="body"),r=null;const a=Oe(e).position==="fixed";let s=a?dt(e):e;for(;De(s)&&!Ot(s);){const i=Oe(s),u=nr(s);!u&&i.position==="fixed"&&(r=null),(a?!u&&!r:!u&&i.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||nn(s)&&!u&&gi(e,s))?o=o.filter(f=>f!==s):r=i,s=dt(s)}return t.set(e,o),o}function lh(e){let{element:t,boundary:n,rootBoundary:o,strategy:r}=e;const s=[...n==="clippingAncestors"?Kn(t)?[]:ih(t,this._c):[].concat(n),o],i=s[0],u=s.reduce((d,f)=>{const m=mi(t,f,r);return d.top=Te(m.top,d.top),d.right=ct(m.right,d.right),d.bottom=ct(m.bottom,d.bottom),d.left=Te(m.left,d.left),d},mi(t,i,r));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}}function ch(e){const{width:t,height:n}=di(e);return{width:t,height:n}}function uh(e,t,n){const o=Ke(t),r=Ue(t),a=n==="fixed",s=Ct(e,!0,a,t);let i={scrollLeft:0,scrollTop:0};const u=He(0);if(o||!o&&!a)if((Dt(t)!=="body"||nn(r))&&(i=Yn(t)),o){const h=Ct(t,!0,a,t);u.x=h.x+t.clientLeft,u.y=h.y+t.clientTop}else r&&(u.x=sr(r));const d=r&&!o&&!a?pi(r,i):He(0),f=s.left+i.scrollLeft-u.x-d.x,m=s.top+i.scrollTop-u.y-d.y;return{x:f,y:m,width:s.width,height:s.height}}function ir(e){return Oe(e).position==="static"}function hi(e,t){if(!Ke(e)||Oe(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ue(e)===n&&(n=n.ownerDocument.body),n}function vi(e,t){const n=Me(e);if(Kn(e))return n;if(!Ke(e)){let r=dt(e);for(;r&&!Ot(r);){if(De(r)&&!ir(r))return r;r=dt(r)}return n}let o=hi(e,t);for(;o&&Zg(o)&&ir(o);)o=hi(o,t);return o&&Ot(o)&&ir(o)&&!nr(o)?n:o||Qg(e)||n}const dh=async function(e){const t=this.getOffsetParent||vi,n=this.getDimensions,o=await n(e.floating);return{reference:uh(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function fh(e){return Oe(e).direction==="rtl"}const ph={convertOffsetParentRelativeRectToViewportRelativeRect:nh,getDocumentElement:Ue,getClippingRect:lh,getOffsetParent:vi,getElementRects:dh,getClientRects:oh,getDimensions:ch,getScale:Lt,isElement:De,isRTL:fh};function mh(e,t){let n=null,o;const r=Ue(e);function a(){var i;clearTimeout(o),(i=n)==null||i.disconnect(),n=null}function s(i,u){i===void 0&&(i=!1),u===void 0&&(u=1),a();const{left:d,top:f,width:m,height:h}=e.getBoundingClientRect();if(i||t(),!m||!h)return;const p=zn(f),b=zn(r.clientWidth-(d+m)),g=zn(r.clientHeight-(f+h)),v=zn(d),w={rootMargin:-p+"px "+-b+"px "+-g+"px "+-v+"px",threshold:Te(0,ct(1,u))||1};let C=!0;function N(E){const A=E[0].intersectionRatio;if(A!==u){if(!C)return s();A?s(!1,A):o=setTimeout(()=>{s(!1,1e-7)},1e3)}C=!1}try{n=new IntersectionObserver(N,{...w,root:r.ownerDocument})}catch{n=new IntersectionObserver(N,w)}n.observe(e)}return s(!0),a}function gh(e,t,n,o){o===void 0&&(o={});const{ancestorScroll:r=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:u=!1}=o,d=ar(e),f=r||a?[...d?on(d):[],...on(t)]:[];f.forEach(y=>{r&&y.addEventListener("scroll",n,{passive:!0}),a&&y.addEventListener("resize",n)});const m=d&&i?mh(d,n):null;let h=-1,p=null;s&&(p=new ResizeObserver(y=>{let[w]=y;w&&w.target===d&&p&&(p.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var C;(C=p)==null||C.observe(t)})),n()}),d&&!u&&p.observe(d),p.observe(t));let b,g=u?Ct(e):null;u&&v();function v(){const y=Ct(e);g&&(y.x!==g.x||y.y!==g.y||y.width!==g.width||y.height!==g.height)&&n(),g=y,b=requestAnimationFrame(v)}return n(),()=>{var y;f.forEach(w=>{r&&w.removeEventListener("scroll",n),a&&w.removeEventListener("resize",n)}),m==null||m(),(y=p)==null||y.disconnect(),p=null,u&&cancelAnimationFrame(b)}}const hh=Yg,vh=Xg,bh=Hg,yh=Jg,wh=Ug,bi=Gg,xh=qg,Ch=(e,t,n)=>{const o=new Map,r={platform:ph,...n},a={...r.platform,_c:o};return zg(e,t,{...r,platform:a})};var Xn=typeof document<"u"?S.useLayoutEffect:S.useEffect;function qn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,o,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(o=n;o--!==0;)if(!qn(e[o],t[o]))return!1;return!0}if(r=Object.keys(e),n=r.length,n!==Object.keys(t).length)return!1;for(o=n;o--!==0;)if(!{}.hasOwnProperty.call(t,r[o]))return!1;for(o=n;o--!==0;){const a=r[o];if(!(a==="_owner"&&e.$$typeof)&&!qn(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function yi(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function wi(e,t){const n=yi(e);return Math.round(t*n)/n}function lr(e){const t=l.useRef(e);return Xn(()=>{t.current=e}),t}function Nh(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:r,elements:{reference:a,floating:s}={},transform:i=!0,whileElementsMounted:u,open:d}=e,[f,m]=l.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,p]=l.useState(o);qn(h,o)||p(o);const[b,g]=l.useState(null),[v,y]=l.useState(null),w=l.useCallback(V=>{V!==A.current&&(A.current=V,g(V))},[]),C=l.useCallback(V=>{V!==M.current&&(M.current=V,y(V))},[]),N=a||b,E=s||v,A=l.useRef(null),M=l.useRef(null),I=l.useRef(f),j=u!=null,B=lr(u),z=lr(r),O=lr(d),U=l.useCallback(()=>{if(!A.current||!M.current)return;const V={placement:t,strategy:n,middleware:h};z.current&&(V.platform=z.current),Ch(A.current,M.current,V).then(T=>{const H={...T,isPositioned:O.current!==!1};W.current&&!qn(I.current,H)&&(I.current=H,Sn.flushSync(()=>{m(H)}))})},[h,t,n,z,O]);Xn(()=>{d===!1&&I.current.isPositioned&&(I.current.isPositioned=!1,m(V=>({...V,isPositioned:!1})))},[d]);const W=l.useRef(!1);Xn(()=>(W.current=!0,()=>{W.current=!1}),[]),Xn(()=>{if(N&&(A.current=N),E&&(M.current=E),N&&E){if(B.current)return B.current(N,E,U);U()}},[N,E,U,B,j]);const oe=l.useMemo(()=>({reference:A,floating:M,setReference:w,setFloating:C}),[w,C]),$=l.useMemo(()=>({reference:N,floating:E}),[N,E]),G=l.useMemo(()=>{const V={position:n,left:0,top:0};if(!$.floating)return V;const T=wi($.floating,f.x),H=wi($.floating,f.y);return i?{...V,transform:"translate("+T+"px, "+H+"px)",...yi($.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:T,top:H}},[n,i,$.floating,f.x,f.y]);return l.useMemo(()=>({...f,update:U,refs:oe,elements:$,floatingStyles:G}),[f,U,oe,$,G])}const Eh=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:o,padding:r}=typeof e=="function"?e(n):e;return o&&t(o)?o.current!=null?bi({element:o.current,padding:r}).fn(n):{}:o?bi({element:o,padding:r}).fn(n):{}}}},Sh=(e,t)=>({...hh(e),options:[e,t]}),Ph=(e,t)=>({...vh(e),options:[e,t]}),Th=(e,t)=>({...xh(e),options:[e,t]}),Mh=(e,t)=>({...bh(e),options:[e,t]}),Rh=(e,t)=>({...yh(e),options:[e,t]}),Ah=(e,t)=>({...wh(e),options:[e,t]}),_h=(e,t)=>({...Eh(e),options:[e,t]});var Ih="Arrow",xi=l.forwardRef((e,t)=>{const{children:n,width:o=10,height:r=5,...a}=e;return c.jsx(L.svg,{...a,ref:t,width:o,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:c.jsx("polygon",{points:"0,0 30,0 15,10"})})});xi.displayName=Ih;var kh=xi;function Jn(e){const[t,n]=l.useState(void 0);return he(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const o=new ResizeObserver(r=>{if(!Array.isArray(r)||!r.length)return;const a=r[0];let s,i;if("borderBoxSize"in a){const u=a.borderBoxSize,d=Array.isArray(u)?u[0]:u;s=d.inlineSize,i=d.blockSize}else s=e.offsetWidth,i=e.offsetHeight;n({width:s,height:i})});return o.observe(e,{box:"border-box"}),()=>o.unobserve(e)}else n(void 0)},[e]),t}var cr="Popper",[Ci,ft]=ve(cr),[jh,Ni]=Ci(cr),Ei=e=>{const{__scopePopper:t,children:n}=e,[o,r]=l.useState(null);return c.jsx(jh,{scope:t,anchor:o,onAnchorChange:r,children:n})};Ei.displayName=cr;var Si="PopperAnchor",Pi=l.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,a=Ni(Si,n),s=l.useRef(null),i=J(t,s);return l.useEffect(()=>{a.onAnchorChange((o==null?void 0:o.current)||s.current)}),o?null:c.jsx(L.div,{...r,ref:i})});Pi.displayName=Si;var ur="PopperContent",[Dh,Oh]=Ci(ur),Ti=l.forwardRef((e,t)=>{var k,ae,se,te,re,ie;const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:a="center",alignOffset:s=0,arrowPadding:i=0,avoidCollisions:u=!0,collisionBoundary:d=[],collisionPadding:f=0,sticky:m="partial",hideWhenDetached:h=!1,updatePositionStrategy:p="optimized",onPlaced:b,...g}=e,v=Ni(ur,n),[y,w]=l.useState(null),C=J(t,ye=>w(ye)),[N,E]=l.useState(null),A=Jn(N),M=(A==null?void 0:A.width)??0,I=(A==null?void 0:A.height)??0,j=o+(a!=="center"?"-"+a:""),B=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},z=Array.isArray(d)?d:[d],O=z.length>0,U={padding:B,boundary:z.filter(Fh),altBoundary:O},{refs:W,floatingStyles:oe,placement:$,isPositioned:G,middlewareData:V}=Nh({strategy:"fixed",placement:j,whileElementsMounted:(...ye)=>gh(...ye,{animationFrame:p==="always"}),elements:{reference:v.anchor},middleware:[Sh({mainAxis:r+I,alignmentAxis:s}),u&&Ph({mainAxis:!0,crossAxis:!1,limiter:m==="partial"?Th():void 0,...U}),u&&Mh({...U}),Rh({...U,apply:({elements:ye,rects:Se,availableWidth:Ae,availableHeight:ot})=>{const{width:Fe,height:rt}=Se.reference,Ye=ye.floating.style;Ye.setProperty("--radix-popper-available-width",`${Ae}px`),Ye.setProperty("--radix-popper-available-height",`${ot}px`),Ye.setProperty("--radix-popper-anchor-width",`${Fe}px`),Ye.setProperty("--radix-popper-anchor-height",`${rt}px`)}}),N&&_h({element:N,padding:i}),$h({arrowWidth:M,arrowHeight:I}),h&&Ah({strategy:"referenceHidden",...U})]}),[T,H]=Ai($),Z=ge(b);he(()=>{G&&(Z==null||Z())},[G,Z]);const X=(k=V.arrow)==null?void 0:k.x,K=(ae=V.arrow)==null?void 0:ae.y,q=((se=V.arrow)==null?void 0:se.centerOffset)!==0,[ce,fe]=l.useState();return he(()=>{y&&fe(window.getComputedStyle(y).zIndex)},[y]),c.jsx("div",{ref:W.setFloating,"data-radix-popper-content-wrapper":"",style:{...oe,transform:G?oe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ce,"--radix-popper-transform-origin":[(te=V.transformOrigin)==null?void 0:te.x,(re=V.transformOrigin)==null?void 0:re.y].join(" "),...((ie=V.hide)==null?void 0:ie.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:c.jsx(Dh,{scope:n,placedSide:T,onArrowChange:E,arrowX:X,arrowY:K,shouldHideArrow:q,children:c.jsx(L.div,{"data-side":T,"data-align":H,...g,ref:C,style:{...g.style,animation:G?void 0:"none"}})})})});Ti.displayName=ur;var Mi="PopperArrow",Lh={top:"bottom",right:"left",bottom:"top",left:"right"},Ri=l.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,a=Oh(Mi,o),s=Lh[a.placedSide];return c.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[s]: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:c.jsx(kh,{...r,ref:n,style:{...r.style,display:"block"}})})});Ri.displayName=Mi;function Fh(e){return e!==null}var $h=e=>({name:"transformOrigin",options:e,fn(t){var v,y,w;const{placement:n,rects:o,middlewareData:r}=t,s=((v=r.arrow)==null?void 0:v.centerOffset)!==0,i=s?0:e.arrowWidth,u=s?0:e.arrowHeight,[d,f]=Ai(n),m={start:"0%",center:"50%",end:"100%"}[f],h=(((y=r.arrow)==null?void 0:y.x)??0)+i/2,p=(((w=r.arrow)==null?void 0:w.y)??0)+u/2;let b="",g="";return d==="bottom"?(b=s?m:`${h}px`,g=`${-u}px`):d==="top"?(b=s?m:`${h}px`,g=`${o.floating.height+u}px`):d==="right"?(b=`${-u}px`,g=s?m:`${p}px`):d==="left"&&(b=`${o.floating.width+u}px`,g=s?m:`${p}px`),{data:{x:b,y:g}}}});function Ai(e){const[t,n="center"]=e.split("-");return[t,n]}var rn=Ei,an=Pi,Zn=Ti,Qn=Ri,dr="Popover",[_i,y0]=ve(dr,[ft]),sn=ft(),[Vh,pt]=_i(dr),Ii=e=>{const{__scopePopover:t,children:n,open:o,defaultOpen:r,onOpenChange:a,modal:s=!1}=e,i=sn(t),u=l.useRef(null),[d,f]=l.useState(!1),[m=!1,h]=Ce({prop:o,defaultProp:r,onChange:a});return c.jsx(rn,{...i,children:c.jsx(Vh,{scope:t,contentId:Ne(),triggerRef:u,open:m,onOpenChange:h,onOpenToggle:l.useCallback(()=>h(p=>!p),[h]),hasCustomAnchor:d,onCustomAnchorAdd:l.useCallback(()=>f(!0),[]),onCustomAnchorRemove:l.useCallback(()=>f(!1),[]),modal:s,children:n})})};Ii.displayName=dr;var ki="PopoverAnchor",ji=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=pt(ki,n),a=sn(n),{onCustomAnchorAdd:s,onCustomAnchorRemove:i}=r;return l.useEffect(()=>(s(),()=>i()),[s,i]),c.jsx(an,{...a,...o,ref:t})});ji.displayName=ki;var Di="PopoverTrigger",Oi=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=pt(Di,n),a=sn(n),s=J(t,r.triggerRef),i=c.jsx(L.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Bi(r.open),...o,ref:s,onClick:_(e.onClick,r.onOpenToggle)});return r.hasCustomAnchor?i:c.jsx(an,{asChild:!0,...a,children:i})});Oi.displayName=Di;var fr="PopoverPortal",[Bh,Wh]=_i(fr,{forceMount:void 0}),Li=e=>{const{__scopePopover:t,forceMount:n,children:o,container:r}=e,a=pt(fr,t);return c.jsx(Bh,{scope:t,forceMount:n,children:c.jsx(be,{present:n||a.open,children:c.jsx(Zt,{asChild:!0,container:r,children:o})})})};Li.displayName=fr;var Ft="PopoverContent",Fi=l.forwardRef((e,t)=>{const n=Wh(Ft,e.__scopePopover),{forceMount:o=n.forceMount,...r}=e,a=pt(Ft,e.__scopePopover);return c.jsx(be,{present:o||a.open,children:a.modal?c.jsx(zh,{...r,ref:t}):c.jsx(Gh,{...r,ref:t})})});Fi.displayName=Ft;var zh=l.forwardRef((e,t)=>{const n=pt(Ft,e.__scopePopover),o=l.useRef(null),r=J(t,o),a=l.useRef(!1);return l.useEffect(()=>{const s=o.current;if(s)return $n(s)},[]),c.jsx(Qt,{as:We,allowPinchZoom:!0,children:c.jsx($i,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:_(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),a.current||(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:_(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,u=i.button===0&&i.ctrlKey===!0,d=i.button===2||u;a.current=d},{checkForDefaultPrevented:!1}),onFocusOutside:_(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1})})})}),Gh=l.forwardRef((e,t)=>{const n=pt(Ft,e.__scopePopover),o=l.useRef(!1),r=l.useRef(!1);return c.jsx($i,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(o.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:a=>{var u,d;(u=e.onInteractOutside)==null||u.call(e,a),a.defaultPrevented||(o.current=!0,a.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const s=a.target;((d=n.triggerRef.current)==null?void 0:d.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&r.current&&a.preventDefault()}})}),$i=l.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEscapeKeyDown:i,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,...m}=e,h=pt(Ft,n),p=sn(n);return _n(),c.jsx(Jt,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:a,children:c.jsx(wt,{asChild:!0,disableOutsidePointerEvents:s,onInteractOutside:f,onEscapeKeyDown:i,onPointerDownOutside:u,onFocusOutside:d,onDismiss:()=>h.onOpenChange(!1),children:c.jsx(Zn,{"data-state":Bi(h.open),role:"dialog",id:h.contentId,...p,...m,ref:t,style:{...m.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)"}})})})}),Vi="PopoverClose",Hh=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=pt(Vi,n);return c.jsx(L.button,{type:"button",...o,ref:t,onClick:_(e.onClick,()=>r.onOpenChange(!1))})});Hh.displayName=Vi;var Uh="PopoverArrow",Kh=l.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=sn(n);return c.jsx(Qn,{...r,...o,ref:t})});Kh.displayName=Uh;function Bi(e){return e?"open":"closed"}var Yh=Ii,Xh=ji,qh=Oi,Jh=Li,Wi=Fi;const zi=Yh,Gi=qh,Zh=Xh,pr=l.forwardRef(({className:e,align:t="center",sideOffset:n=4,...o},r)=>c.jsx(Jh,{children:c.jsx(Wi,{ref:r,align:t,sideOffset:n,className:R("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",e),...o})}));pr.displayName=Wi.displayName;function Qh(e){const{value:t="",onChange:n,options:o,className:r,placeholder:a="Search...",emptyMessage:s="Nothing found"}=e,[i,u]=S.useState(t),[d,f]=S.useState(o),[m,h]=S.useState(-1),[p,b]=S.useState(!1),g=N=>{const E=N.target.value;u(E),n==null||n(E),h(-1),b(!0),E.trim()===""?f(o):f(o.filter(A=>A.label.toLowerCase().includes(E.toLowerCase())))},v=N=>{if(N.key==="ArrowDown")N.preventDefault(),h(E=>E<d.length-1?E+1:E);else if(N.key==="ArrowUp")N.preventDefault(),h(E=>E>0?E-1:-1);else if(N.key==="Enter"&&m>=0){const E=d[m];u(E.label),n==null||n(E.value),f([]),h(-1),b(!1)}else N.key==="Escape"&&(f([]),h(-1))},y=N=>{b(!1),u(N.label),n==null||n(N.value),f(o),h(-1)},w=()=>{b(!0)},C=()=>{b(!1)};return c.jsxs(zi,{open:p,children:[c.jsx(Gi,{asChild:!0,children:c.jsx("div",{className:"relative w-full",children:c.jsx(Mn,{type:"text",placeholder:a,value:i,onChange:g,onKeyDown:v,onClick:w,onFocus:w,onBlur:C,className:R("pr-10",r),"aria-label":"Search field","aria-autocomplete":"list","aria-controls":"suggestions-list","aria-expanded":d.length>0,leftIcon:c.jsx(kg,{className:"w-4 h-4"})})})}),c.jsx(pr,{className:"p-0 w-[var(--radix-popover-trigger-width)] max-h-96 overflow-y-auto",children:d.length>0?c.jsx("ul",{id:"suggestions-list",role:"listbox",children:d.map((N,E)=>c.jsx("li",{className:`px-4 py-2 cursor-pointer hover:bg-muted ${E===m?"bg-muted":""}`,onClick:()=>y(N),role:"option","aria-selected":E===m,children:N.label},N.value))}):c.jsx("span",{className:"px-4 py-2 block",children:s})})]})}var mr="Avatar",[ev,w0]=ve(mr),[tv,Hi]=ev(mr),Ui=l.forwardRef((e,t)=>{const{__scopeAvatar:n,...o}=e,[r,a]=l.useState("idle");return c.jsx(tv,{scope:n,imageLoadingStatus:r,onImageLoadingStatusChange:a,children:c.jsx(L.span,{...o,ref:t})})});Ui.displayName=mr;var Ki="AvatarImage",Yi=l.forwardRef((e,t)=>{const{__scopeAvatar:n,src:o,onLoadingStatusChange:r=()=>{},...a}=e,s=Hi(Ki,n),i=nv(o,a.referrerPolicy),u=ge(d=>{r(d),s.onImageLoadingStatusChange(d)});return he(()=>{i!=="idle"&&u(i)},[i,u]),i==="loaded"?c.jsx(L.img,{...a,ref:t,src:o}):null});Yi.displayName=Ki;var Xi="AvatarFallback",qi=l.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:o,...r}=e,a=Hi(Xi,n),[s,i]=l.useState(o===void 0);return l.useEffect(()=>{if(o!==void 0){const u=window.setTimeout(()=>i(!0),o);return()=>window.clearTimeout(u)}},[o]),s&&a.imageLoadingStatus!=="loaded"?c.jsx(L.span,{...r,ref:t}):null});qi.displayName=Xi;function nv(e,t){const[n,o]=l.useState("idle");return he(()=>{if(!e){o("error");return}let r=!0;const a=new window.Image,s=i=>()=>{r&&o(i)};return o("loading"),a.onload=s("loaded"),a.onerror=s("error"),a.src=e,t&&(a.referrerPolicy=t),()=>{r=!1}},[e,t]),n}var Ji=Ui,Zi=Yi,Qi=qi;const el=l.forwardRef(({className:e,...t},n)=>c.jsx(Ji,{ref:n,className:R("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));el.displayName=Ji.displayName;const tl=l.forwardRef(({className:e,...t},n)=>c.jsx(Zi,{ref:n,className:R("aspect-square h-full w-full",e),...t}));tl.displayName=Zi.displayName;const nl=l.forwardRef(({className:e,...t},n)=>c.jsx(Qi,{ref:n,className:R("flex h-full w-full items-center justify-center rounded-full bg-muted",e),...t}));nl.displayName=Qi.displayName;const ol=Mt("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 ov({className:e,variant:t,...n}){return c.jsx("div",{className:R(ol({variant:t}),e),...n})}const rl=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{ref:n,className:R("rounded-xl border bg-card text-card-foreground shadow",e),...t}));rl.displayName="Card";const al=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{ref:n,className:R("flex flex-col space-y-1.5 p-6",e),...t}));al.displayName="CardHeader";const sl=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{ref:n,className:R("font-semibold leading-none tracking-tight pb-4",e),...t}));sl.displayName="CardTitle";const il=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{ref:n,className:R("text-sm text-muted-foreground",e),...t}));il.displayName="CardDescription";const ll=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{ref:n,className:R("p-6 py-0",e),...t}));ll.displayName="CardContent";const cl=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{ref:n,className:R("flex items-center p-6 pt-6",e),...t}));cl.displayName="CardFooter";function ln(e){const t=l.useRef({value:e,previous:e});return l.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var gr="Checkbox",[rv,x0]=ve(gr),[av,sv]=rv(gr),ul=l.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:o,checked:r,defaultChecked:a,required:s,disabled:i,value:u="on",onCheckedChange:d,form:f,...m}=e,[h,p]=l.useState(null),b=J(t,N=>p(N)),g=l.useRef(!1),v=h?f||!!h.closest("form"):!0,[y=!1,w]=Ce({prop:r,defaultProp:a,onChange:d}),C=l.useRef(y);return l.useEffect(()=>{const N=h==null?void 0:h.form;if(N){const E=()=>w(C.current);return N.addEventListener("reset",E),()=>N.removeEventListener("reset",E)}},[h,w]),c.jsxs(av,{scope:n,state:y,disabled:i,children:[c.jsx(L.button,{type:"button",role:"checkbox","aria-checked":mt(y)?"mixed":y,"aria-required":s,"data-state":pl(y),"data-disabled":i?"":void 0,disabled:i,value:u,...m,ref:b,onKeyDown:_(e.onKeyDown,N=>{N.key==="Enter"&&N.preventDefault()}),onClick:_(e.onClick,N=>{w(E=>mt(E)?!0:!E),v&&(g.current=N.isPropagationStopped(),g.current||N.stopPropagation())})}),v&&c.jsx(iv,{control:h,bubbles:!g.current,name:o,value:u,checked:y,required:s,disabled:i,form:f,style:{transform:"translateX(-100%)"},defaultChecked:mt(a)?!1:a})]})});ul.displayName=gr;var dl="CheckboxIndicator",fl=l.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:o,...r}=e,a=sv(dl,n);return c.jsx(be,{present:o||mt(a.state)||a.state===!0,children:c.jsx(L.span,{"data-state":pl(a.state),"data-disabled":a.disabled?"":void 0,...r,ref:t,style:{pointerEvents:"none",...e.style}})})});fl.displayName=dl;var iv=e=>{const{control:t,checked:n,bubbles:o=!0,defaultChecked:r,...a}=e,s=l.useRef(null),i=ln(n),u=Jn(t);l.useEffect(()=>{const f=s.current,m=window.HTMLInputElement.prototype,p=Object.getOwnPropertyDescriptor(m,"checked").set;if(i!==n&&p){const b=new Event("click",{bubbles:o});f.indeterminate=mt(n),p.call(f,mt(n)?!1:n),f.dispatchEvent(b)}},[i,n,o]);const d=l.useRef(mt(n)?!1:n);return c.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:r??d.current,...a,tabIndex:-1,ref:s,style:{...e.style,...u,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function mt(e){return e==="indeterminate"}function pl(e){return mt(e)?"indeterminate":e?"checked":"unchecked"}var ml=ul,lv=fl;const gl=l.forwardRef(({className:e,...t},n)=>c.jsx(ml,{ref:n,className:R("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:c.jsx(lv,{className:R("flex items-center justify-center text-current"),children:c.jsx(Yo,{className:"h-4 w-4"})})}));gl.displayName=ml.displayName;const hl=S.forwardRef((e,t)=>{const{currencySymbol:n="$",decimalSeparator:o=".",thousandSeparator:r=",",onValueChange:a,className:s,value:i=0,...u}=e,d=S.useRef(null);S.useImperativeHandle(t,()=>d.current);const[f,m]=S.useState(""),h=g=>{const v=g.toFixed(2).split("."),y=v[0].replace(/\B(?=(\d{3})+(?!\d))/g,r);return`${n} ${y}${o}${v[1]}`},p=g=>{const v=g.target.value,y=parseFloat(v.replace(/\D/g,""))/100;m(h(y)),a(y),d.current&&window.requestAnimationFrame(()=>{var w;(w=d.current)==null||w.setSelectionRange(d.current.value.length,d.current.value.length)})},b=()=>{d.current&&d.current.setSelectionRange(d.current.value.length,d.current.value.length)};return S.useEffect(()=>{m(h(+i))},[i]),c.jsx(Mn,{type:"text",inputMode:"numeric",value:f,ref:d,onChange:p,onFocus:b,onClick:b,placeholder:`${n} 0${o}00`,className:s,...u})});hl.displayName="CurrencyInput";const hr=Es,vl=Ss,bl=Ps,cv=Bn,vr=l.forwardRef(({className:e,...t},n)=>c.jsx(zo,{ref:n,className:R("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}));vr.displayName=zo.displayName;const eo=l.forwardRef(({className:e,children:t,...n},o)=>c.jsxs(bl,{children:[c.jsx(vr,{}),c.jsxs(Go,{ref:o,className:R("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 max-h-[100dvh] overflow-y-auto",e),...n,children:[t,c.jsxs(Bn,{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:[c.jsx(jg,{className:"h-4 w-4"}),c.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));eo.displayName=Go.displayName;const to=({className:e,...t})=>c.jsx("div",{className:R("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});to.displayName="DialogHeader";const yl=({className:e,...t})=>c.jsx("div",{className:R("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});yl.displayName="DialogFooter";const no=l.forwardRef(({className:e,...t},n)=>c.jsx(Ho,{ref:n,className:R("text-lg font-semibold leading-none tracking-tight",e),...t}));no.displayName=Ho.displayName;const oo=l.forwardRef(({className:e,...t},n)=>c.jsx(Uo,{ref:n,className:R("text-sm text-muted-foreground",e),...t}));oo.displayName=Uo.displayName;function cn(e){const t=e+"CollectionProvider",[n,o]=ve(t),[r,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=p=>{const{scope:b,children:g}=p,v=S.useRef(null),y=S.useRef(new Map).current;return c.jsx(r,{scope:b,itemMap:y,collectionRef:v,children:g})};s.displayName=t;const i=e+"CollectionSlot",u=S.forwardRef((p,b)=>{const{scope:g,children:v}=p,y=a(i,g),w=J(b,y.collectionRef);return c.jsx(We,{ref:w,children:v})});u.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",m=S.forwardRef((p,b)=>{const{scope:g,children:v,...y}=p,w=S.useRef(null),C=J(b,w),N=a(d,g);return S.useEffect(()=>(N.itemMap.set(w,{ref:w,...y}),()=>void N.itemMap.delete(w))),c.jsx(We,{[f]:"",ref:C,children:v})});m.displayName=d;function h(p){const b=a(e+"CollectionConsumer",p);return S.useCallback(()=>{const v=b.collectionRef.current;if(!v)return[];const y=Array.from(v.querySelectorAll(`[${f}]`));return Array.from(b.itemMap.values()).sort((N,E)=>y.indexOf(N.ref.current)-y.indexOf(E.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:s,Slot:u,ItemSlot:m},h,o]}var uv=l.createContext(void 0);function Nt(e){const t=l.useContext(uv);return e||t||"ltr"}var br="rovingFocusGroup.onEntryFocus",dv={bubbles:!1,cancelable:!0},ro="RovingFocusGroup",[yr,wl,fv]=cn(ro),[pv,gt]=ve(ro,[fv]),[mv,gv]=pv(ro),xl=l.forwardRef((e,t)=>c.jsx(yr.Provider,{scope:e.__scopeRovingFocusGroup,children:c.jsx(yr.Slot,{scope:e.__scopeRovingFocusGroup,children:c.jsx(hv,{...e,ref:t})})}));xl.displayName=ro;var hv=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:a,currentTabStopId:s,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:u,onEntryFocus:d,preventScrollOnEntryFocus:f=!1,...m}=e,h=l.useRef(null),p=J(t,h),b=Nt(a),[g=null,v]=Ce({prop:s,defaultProp:i,onChange:u}),[y,w]=l.useState(!1),C=ge(d),N=wl(n),E=l.useRef(!1),[A,M]=l.useState(0);return l.useEffect(()=>{const I=h.current;if(I)return I.addEventListener(br,C),()=>I.removeEventListener(br,C)},[C]),c.jsx(mv,{scope:n,orientation:o,dir:b,loop:r,currentTabStopId:g,onItemFocus:l.useCallback(I=>v(I),[v]),onItemShiftTab:l.useCallback(()=>w(!0),[]),onFocusableItemAdd:l.useCallback(()=>M(I=>I+1),[]),onFocusableItemRemove:l.useCallback(()=>M(I=>I-1),[]),children:c.jsx(L.div,{tabIndex:y||A===0?-1:0,"data-orientation":o,...m,ref:p,style:{outline:"none",...e.style},onMouseDown:_(e.onMouseDown,()=>{E.current=!0}),onFocus:_(e.onFocus,I=>{const j=!E.current;if(I.target===I.currentTarget&&j&&!y){const B=new CustomEvent(br,dv);if(I.currentTarget.dispatchEvent(B),!B.defaultPrevented){const z=N().filter($=>$.focusable),O=z.find($=>$.active),U=z.find($=>$.id===g),oe=[O,U,...z].filter(Boolean).map($=>$.ref.current);El(oe,f)}}E.current=!1}),onBlur:_(e.onBlur,()=>w(!1))})})}),Cl="RovingFocusGroupItem",Nl=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:a,...s}=e,i=Ne(),u=a||i,d=gv(Cl,n),f=d.currentTabStopId===u,m=wl(n),{onFocusableItemAdd:h,onFocusableItemRemove:p}=d;return l.useEffect(()=>{if(o)return h(),()=>p()},[o,h,p]),c.jsx(yr.ItemSlot,{scope:n,id:u,focusable:o,active:r,children:c.jsx(L.span,{tabIndex:f?0:-1,"data-orientation":d.orientation,...s,ref:t,onMouseDown:_(e.onMouseDown,b=>{o?d.onItemFocus(u):b.preventDefault()}),onFocus:_(e.onFocus,()=>d.onItemFocus(u)),onKeyDown:_(e.onKeyDown,b=>{if(b.key==="Tab"&&b.shiftKey){d.onItemShiftTab();return}if(b.target!==b.currentTarget)return;const g=yv(b,d.orientation,d.dir);if(g!==void 0){if(b.metaKey||b.ctrlKey||b.altKey||b.shiftKey)return;b.preventDefault();let y=m().filter(w=>w.focusable).map(w=>w.ref.current);if(g==="last")y.reverse();else if(g==="prev"||g==="next"){g==="prev"&&y.reverse();const w=y.indexOf(b.currentTarget);y=d.loop?wv(y,w+1):y.slice(w+1)}setTimeout(()=>El(y))}})})})});Nl.displayName=Cl;var vv={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function bv(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function yv(e,t,n){const o=bv(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return vv[o]}function El(e,t=!1){const n=document.activeElement;for(const o of e)if(o===n||(o.focus({preventScroll:t}),document.activeElement!==n))return}function wv(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var ao=xl,so=Nl,wr=["Enter"," "],xv=["ArrowDown","PageUp","Home"],Sl=["ArrowUp","PageDown","End"],Cv=[...xv,...Sl],Nv={ltr:[...wr,"ArrowRight"],rtl:[...wr,"ArrowLeft"]},Ev={ltr:["ArrowLeft"],rtl:["ArrowRight"]},un="Menu",[dn,Sv,Pv]=cn(un),[Et,Pl]=ve(un,[Pv,ft,gt]),fn=ft(),Tl=gt(),[Ml,ht]=Et(un),[Tv,pn]=Et(un),Rl=e=>{const{__scopeMenu:t,open:n=!1,children:o,dir:r,onOpenChange:a,modal:s=!0}=e,i=fn(t),[u,d]=l.useState(null),f=l.useRef(!1),m=ge(a),h=Nt(r);return l.useEffect(()=>{const p=()=>{f.current=!0,document.addEventListener("pointerdown",b,{capture:!0,once:!0}),document.addEventListener("pointermove",b,{capture:!0,once:!0})},b=()=>f.current=!1;return document.addEventListener("keydown",p,{capture:!0}),()=>{document.removeEventListener("keydown",p,{capture:!0}),document.removeEventListener("pointerdown",b,{capture:!0}),document.removeEventListener("pointermove",b,{capture:!0})}},[]),c.jsx(rn,{...i,children:c.jsx(Ml,{scope:t,open:n,onOpenChange:m,content:u,onContentChange:d,children:c.jsx(Tv,{scope:t,onClose:l.useCallback(()=>m(!1),[m]),isUsingKeyboardRef:f,dir:h,modal:s,children:o})})})};Rl.displayName=un;var Mv="MenuAnchor",xr=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=fn(n);return c.jsx(an,{...r,...o,ref:t})});xr.displayName=Mv;var Cr="MenuPortal",[Rv,Al]=Et(Cr,{forceMount:void 0}),_l=e=>{const{__scopeMenu:t,forceMount:n,children:o,container:r}=e,a=ht(Cr,t);return c.jsx(Rv,{scope:t,forceMount:n,children:c.jsx(be,{present:n||a.open,children:c.jsx(Zt,{asChild:!0,container:r,children:o})})})};_l.displayName=Cr;var _e="MenuContent",[Av,Nr]=Et(_e),Il=l.forwardRef((e,t)=>{const n=Al(_e,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,a=ht(_e,e.__scopeMenu),s=pn(_e,e.__scopeMenu);return c.jsx(dn.Provider,{scope:e.__scopeMenu,children:c.jsx(be,{present:o||a.open,children:c.jsx(dn.Slot,{scope:e.__scopeMenu,children:s.modal?c.jsx(_v,{...r,ref:t}):c.jsx(Iv,{...r,ref:t})})})})}),_v=l.forwardRef((e,t)=>{const n=ht(_e,e.__scopeMenu),o=l.useRef(null),r=J(t,o);return l.useEffect(()=>{const a=o.current;if(a)return $n(a)},[]),c.jsx(Er,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:_(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Iv=l.forwardRef((e,t)=>{const n=ht(_e,e.__scopeMenu);return c.jsx(Er,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Er=l.forwardRef((e,t)=>{const{__scopeMenu:n,loop:o=!1,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEntryFocus:u,onEscapeKeyDown:d,onPointerDownOutside:f,onFocusOutside:m,onInteractOutside:h,onDismiss:p,disableOutsideScroll:b,...g}=e,v=ht(_e,n),y=pn(_e,n),w=fn(n),C=Tl(n),N=Sv(n),[E,A]=l.useState(null),M=l.useRef(null),I=J(t,M,v.onContentChange),j=l.useRef(0),B=l.useRef(""),z=l.useRef(0),O=l.useRef(null),U=l.useRef("right"),W=l.useRef(0),oe=b?Qt:l.Fragment,$=b?{as:We,allowPinchZoom:!0}:void 0,G=T=>{var k,ae;const H=B.current+T,Z=N().filter(se=>!se.disabled),X=document.activeElement,K=(k=Z.find(se=>se.ref.current===X))==null?void 0:k.textValue,q=Z.map(se=>se.textValue),ce=Gv(q,H,K),fe=(ae=Z.find(se=>se.textValue===ce))==null?void 0:ae.ref.current;(function se(te){B.current=te,window.clearTimeout(j.current),te!==""&&(j.current=window.setTimeout(()=>se(""),1e3))})(H),fe&&setTimeout(()=>fe.focus())};l.useEffect(()=>()=>window.clearTimeout(j.current),[]),_n();const V=l.useCallback(T=>{var Z,X;return U.current===((Z=O.current)==null?void 0:Z.side)&&Uv(T,(X=O.current)==null?void 0:X.area)},[]);return c.jsx(Av,{scope:n,searchRef:B,onItemEnter:l.useCallback(T=>{V(T)&&T.preventDefault()},[V]),onItemLeave:l.useCallback(T=>{var H;V(T)||((H=M.current)==null||H.focus(),A(null))},[V]),onTriggerLeave:l.useCallback(T=>{V(T)&&T.preventDefault()},[V]),pointerGraceTimerRef:z,onPointerGraceIntentChange:l.useCallback(T=>{O.current=T},[]),children:c.jsx(oe,{...$,children:c.jsx(Jt,{asChild:!0,trapped:r,onMountAutoFocus:_(a,T=>{var H;T.preventDefault(),(H=M.current)==null||H.focus({preventScroll:!0})}),onUnmountAutoFocus:s,children:c.jsx(wt,{asChild:!0,disableOutsidePointerEvents:i,onEscapeKeyDown:d,onPointerDownOutside:f,onFocusOutside:m,onInteractOutside:h,onDismiss:p,children:c.jsx(ao,{asChild:!0,...C,dir:y.dir,orientation:"vertical",loop:o,currentTabStopId:E,onCurrentTabStopIdChange:A,onEntryFocus:_(u,T=>{y.isUsingKeyboardRef.current||T.preventDefault()}),preventScrollOnEntryFocus:!0,children:c.jsx(Zn,{role:"menu","aria-orientation":"vertical","data-state":ql(v.open),"data-radix-menu-content":"",dir:y.dir,...w,...g,ref:I,style:{outline:"none",...g.style},onKeyDown:_(g.onKeyDown,T=>{const Z=T.target.closest("[data-radix-menu-content]")===T.currentTarget,X=T.ctrlKey||T.altKey||T.metaKey,K=T.key.length===1;Z&&(T.key==="Tab"&&T.preventDefault(),!X&&K&&G(T.key));const q=M.current;if(T.target!==q||!Cv.includes(T.key))return;T.preventDefault();const fe=N().filter(k=>!k.disabled).map(k=>k.ref.current);Sl.includes(T.key)&&fe.reverse(),Wv(fe)}),onBlur:_(e.onBlur,T=>{T.currentTarget.contains(T.target)||(window.clearTimeout(j.current),B.current="")}),onPointerMove:_(e.onPointerMove,gn(T=>{const H=T.target,Z=W.current!==T.clientX;if(T.currentTarget.contains(H)&&Z){const X=T.clientX>W.current?"right":"left";U.current=X,W.current=T.clientX}}))})})})})})})});Il.displayName=_e;var kv="MenuGroup",Sr=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return c.jsx(L.div,{role:"group",...o,ref:t})});Sr.displayName=kv;var jv="MenuLabel",kl=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return c.jsx(L.div,{...o,ref:t})});kl.displayName=jv;var io="MenuItem",jl="menu.itemSelect",lo=l.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:o,...r}=e,a=l.useRef(null),s=pn(io,e.__scopeMenu),i=Nr(io,e.__scopeMenu),u=J(t,a),d=l.useRef(!1),f=()=>{const m=a.current;if(!n&&m){const h=new CustomEvent(jl,{bubbles:!0,cancelable:!0});m.addEventListener(jl,p=>o==null?void 0:o(p),{once:!0}),Rn(m,h),h.defaultPrevented?d.current=!1:s.onClose()}};return c.jsx(Dl,{...r,ref:u,disabled:n,onClick:_(e.onClick,f),onPointerDown:m=>{var h;(h=e.onPointerDown)==null||h.call(e,m),d.current=!0},onPointerUp:_(e.onPointerUp,m=>{var h;d.current||(h=m.currentTarget)==null||h.click()}),onKeyDown:_(e.onKeyDown,m=>{const h=i.searchRef.current!=="";n||h&&m.key===" "||wr.includes(m.key)&&(m.currentTarget.click(),m.preventDefault())})})});lo.displayName=io;var Dl=l.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:o=!1,textValue:r,...a}=e,s=Nr(io,n),i=Tl(n),u=l.useRef(null),d=J(t,u),[f,m]=l.useState(!1),[h,p]=l.useState("");return l.useEffect(()=>{const b=u.current;b&&p((b.textContent??"").trim())},[a.children]),c.jsx(dn.ItemSlot,{scope:n,disabled:o,textValue:r??h,children:c.jsx(so,{asChild:!0,...i,focusable:!o,children:c.jsx(L.div,{role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":o||void 0,"data-disabled":o?"":void 0,...a,ref:d,onPointerMove:_(e.onPointerMove,gn(b=>{o?s.onItemLeave(b):(s.onItemEnter(b),b.defaultPrevented||b.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:_(e.onPointerLeave,gn(b=>s.onItemLeave(b))),onFocus:_(e.onFocus,()=>m(!0)),onBlur:_(e.onBlur,()=>m(!1))})})})}),Dv="MenuCheckboxItem",Ol=l.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:o,...r}=e;return c.jsx(Bl,{scope:e.__scopeMenu,checked:n,children:c.jsx(lo,{role:"menuitemcheckbox","aria-checked":co(n)?"mixed":n,...r,ref:t,"data-state":Mr(n),onSelect:_(r.onSelect,()=>o==null?void 0:o(co(n)?!0:!n),{checkForDefaultPrevented:!1})})})});Ol.displayName=Dv;var Ll="MenuRadioGroup",[Ov,Lv]=Et(Ll,{value:void 0,onValueChange:()=>{}}),Fl=l.forwardRef((e,t)=>{const{value:n,onValueChange:o,...r}=e,a=ge(o);return c.jsx(Ov,{scope:e.__scopeMenu,value:n,onValueChange:a,children:c.jsx(Sr,{...r,ref:t})})});Fl.displayName=Ll;var $l="MenuRadioItem",Vl=l.forwardRef((e,t)=>{const{value:n,...o}=e,r=Lv($l,e.__scopeMenu),a=n===r.value;return c.jsx(Bl,{scope:e.__scopeMenu,checked:a,children:c.jsx(lo,{role:"menuitemradio","aria-checked":a,...o,ref:t,"data-state":Mr(a),onSelect:_(o.onSelect,()=>{var s;return(s=r.onValueChange)==null?void 0:s.call(r,n)},{checkForDefaultPrevented:!1})})})});Vl.displayName=$l;var Pr="MenuItemIndicator",[Bl,Fv]=Et(Pr,{checked:!1}),Wl=l.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:o,...r}=e,a=Fv(Pr,n);return c.jsx(be,{present:o||co(a.checked)||a.checked===!0,children:c.jsx(L.span,{...r,ref:t,"data-state":Mr(a.checked)})})});Wl.displayName=Pr;var $v="MenuSeparator",zl=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return c.jsx(L.div,{role:"separator","aria-orientation":"horizontal",...o,ref:t})});zl.displayName=$v;var Vv="MenuArrow",Gl=l.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=fn(n);return c.jsx(Qn,{...r,...o,ref:t})});Gl.displayName=Vv;var Tr="MenuSub",[Bv,Hl]=Et(Tr),Ul=e=>{const{__scopeMenu:t,children:n,open:o=!1,onOpenChange:r}=e,a=ht(Tr,t),s=fn(t),[i,u]=l.useState(null),[d,f]=l.useState(null),m=ge(r);return l.useEffect(()=>(a.open===!1&&m(!1),()=>m(!1)),[a.open,m]),c.jsx(rn,{...s,children:c.jsx(Ml,{scope:t,open:o,onOpenChange:m,content:d,onContentChange:f,children:c.jsx(Bv,{scope:t,contentId:Ne(),triggerId:Ne(),trigger:i,onTriggerChange:u,children:n})})})};Ul.displayName=Tr;var mn="MenuSubTrigger",Kl=l.forwardRef((e,t)=>{const n=ht(mn,e.__scopeMenu),o=pn(mn,e.__scopeMenu),r=Hl(mn,e.__scopeMenu),a=Nr(mn,e.__scopeMenu),s=l.useRef(null),{pointerGraceTimerRef:i,onPointerGraceIntentChange:u}=a,d={__scopeMenu:e.__scopeMenu},f=l.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return l.useEffect(()=>f,[f]),l.useEffect(()=>{const m=i.current;return()=>{window.clearTimeout(m),u(null)}},[i,u]),c.jsx(xr,{asChild:!0,...d,children:c.jsx(Dl,{id:r.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":r.contentId,"data-state":ql(n.open),...e,ref:qt(t,r.onTriggerChange),onClick:m=>{var h;(h=e.onClick)==null||h.call(e,m),!(e.disabled||m.defaultPrevented)&&(m.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:_(e.onPointerMove,gn(m=>{a.onItemEnter(m),!m.defaultPrevented&&!e.disabled&&!n.open&&!s.current&&(a.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:_(e.onPointerLeave,gn(m=>{var p,b;f();const h=(p=n.content)==null?void 0:p.getBoundingClientRect();if(h){const g=(b=n.content)==null?void 0:b.dataset.side,v=g==="right",y=v?-5:5,w=h[v?"left":"right"],C=h[v?"right":"left"];a.onPointerGraceIntentChange({area:[{x:m.clientX+y,y:m.clientY},{x:w,y:h.top},{x:C,y:h.top},{x:C,y:h.bottom},{x:w,y:h.bottom}],side:g}),window.clearTimeout(i.current),i.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(m),m.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:_(e.onKeyDown,m=>{var p;const h=a.searchRef.current!=="";e.disabled||h&&m.key===" "||Nv[o.dir].includes(m.key)&&(n.onOpenChange(!0),(p=n.content)==null||p.focus(),m.preventDefault())})})})});Kl.displayName=mn;var Yl="MenuSubContent",Xl=l.forwardRef((e,t)=>{const n=Al(_e,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,a=ht(_e,e.__scopeMenu),s=pn(_e,e.__scopeMenu),i=Hl(Yl,e.__scopeMenu),u=l.useRef(null),d=J(t,u);return c.jsx(dn.Provider,{scope:e.__scopeMenu,children:c.jsx(be,{present:o||a.open,children:c.jsx(dn.Slot,{scope:e.__scopeMenu,children:c.jsx(Er,{id:i.contentId,"aria-labelledby":i.triggerId,...r,ref:d,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{var m;s.isUsingKeyboardRef.current&&((m=u.current)==null||m.focus()),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:_(e.onFocusOutside,f=>{f.target!==i.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:_(e.onEscapeKeyDown,f=>{s.onClose(),f.preventDefault()}),onKeyDown:_(e.onKeyDown,f=>{var p;const m=f.currentTarget.contains(f.target),h=Ev[s.dir].includes(f.key);m&&h&&(a.onOpenChange(!1),(p=i.trigger)==null||p.focus(),f.preventDefault())})})})})})});Xl.displayName=Yl;function ql(e){return e?"open":"closed"}function co(e){return e==="indeterminate"}function Mr(e){return co(e)?"indeterminate":e?"checked":"unchecked"}function Wv(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function zv(e,t){return e.map((n,o)=>e[(t+o)%e.length])}function Gv(e,t,n){const r=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=zv(e,Math.max(a,0));r.length===1&&(s=s.filter(d=>d!==n));const u=s.find(d=>d.toLowerCase().startsWith(r.toLowerCase()));return u!==n?u:void 0}function Hv(e,t){const{x:n,y:o}=e;let r=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a].x,u=t[a].y,d=t[s].x,f=t[s].y;u>o!=f>o&&n<(d-i)*(o-u)/(f-u)+i&&(r=!r)}return r}function Uv(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return Hv(n,t)}function gn(e){return t=>t.pointerType==="mouse"?e(t):void 0}var Kv=Rl,Yv=xr,Xv=_l,qv=Il,Jv=Sr,Zv=kl,Qv=lo,eb=Ol,tb=Fl,nb=Vl,ob=Wl,rb=zl,ab=Gl,sb=Ul,ib=Kl,lb=Xl,Rr="DropdownMenu",[cb,C0]=ve(Rr,[Pl]),Ee=Pl(),[ub,Jl]=cb(Rr),Zl=e=>{const{__scopeDropdownMenu:t,children:n,dir:o,open:r,defaultOpen:a,onOpenChange:s,modal:i=!0}=e,u=Ee(t),d=l.useRef(null),[f=!1,m]=Ce({prop:r,defaultProp:a,onChange:s});return c.jsx(ub,{scope:t,triggerId:Ne(),triggerRef:d,contentId:Ne(),open:f,onOpenChange:m,onOpenToggle:l.useCallback(()=>m(h=>!h),[m]),modal:i,children:c.jsx(Kv,{...u,open:f,onOpenChange:m,dir:o,modal:i,children:n})})};Zl.displayName=Rr;var Ql="DropdownMenuTrigger",ec=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:o=!1,...r}=e,a=Jl(Ql,n),s=Ee(n);return c.jsx(Yv,{asChild:!0,...s,children:c.jsx(L.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":o?"":void 0,disabled:o,...r,ref:qt(t,a.triggerRef),onPointerDown:_(e.onPointerDown,i=>{!o&&i.button===0&&i.ctrlKey===!1&&(a.onOpenToggle(),a.open||i.preventDefault())}),onKeyDown:_(e.onKeyDown,i=>{o||(["Enter"," "].includes(i.key)&&a.onOpenToggle(),i.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(i.key)&&i.preventDefault())})})})});ec.displayName=Ql;var db="DropdownMenuPortal",tc=e=>{const{__scopeDropdownMenu:t,...n}=e,o=Ee(t);return c.jsx(Xv,{...o,...n})};tc.displayName=db;var nc="DropdownMenuContent",oc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Jl(nc,n),a=Ee(n),s=l.useRef(!1);return c.jsx(qv,{id:r.contentId,"aria-labelledby":r.triggerId,...a,...o,ref:t,onCloseAutoFocus:_(e.onCloseAutoFocus,i=>{var u;s.current||(u=r.triggerRef.current)==null||u.focus(),s.current=!1,i.preventDefault()}),onInteractOutside:_(e.onInteractOutside,i=>{const u=i.detail.originalEvent,d=u.button===0&&u.ctrlKey===!0,f=u.button===2||d;(!r.modal||f)&&(s.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)"}})});oc.displayName=nc;var fb="DropdownMenuGroup",rc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(Jv,{...r,...o,ref:t})});rc.displayName=fb;var pb="DropdownMenuLabel",ac=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(Zv,{...r,...o,ref:t})});ac.displayName=pb;var mb="DropdownMenuItem",sc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(Qv,{...r,...o,ref:t})});sc.displayName=mb;var gb="DropdownMenuCheckboxItem",ic=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(eb,{...r,...o,ref:t})});ic.displayName=gb;var hb="DropdownMenuRadioGroup",lc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(tb,{...r,...o,ref:t})});lc.displayName=hb;var vb="DropdownMenuRadioItem",cc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(nb,{...r,...o,ref:t})});cc.displayName=vb;var bb="DropdownMenuItemIndicator",uc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(ob,{...r,...o,ref:t})});uc.displayName=bb;var yb="DropdownMenuSeparator",dc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(rb,{...r,...o,ref:t})});dc.displayName=yb;var wb="DropdownMenuArrow",xb=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(ab,{...r,...o,ref:t})});xb.displayName=wb;var Cb=e=>{const{__scopeDropdownMenu:t,children:n,open:o,onOpenChange:r,defaultOpen:a}=e,s=Ee(t),[i=!1,u]=Ce({prop:o,defaultProp:a,onChange:r});return c.jsx(sb,{...s,open:i,onOpenChange:u,children:n})},Nb="DropdownMenuSubTrigger",fc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(ib,{...r,...o,ref:t})});fc.displayName=Nb;var Eb="DropdownMenuSubContent",pc=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Ee(n);return c.jsx(lb,{...r,...o,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)"}})});pc.displayName=Eb;var Sb=Zl,Pb=ec,mc=tc,gc=oc,Tb=rc,hc=ac,vc=sc,bc=ic,Mb=lc,yc=cc,wc=uc,xc=dc,Rb=Cb,Cc=fc,Nc=pc;const Ab=Sb,_b=Pb,Ib=Tb,kb=mc,jb=Rb,Db=Mb,Ec=l.forwardRef(({className:e,inset:t,children:n,...o},r)=>c.jsxs(Cc,{ref:r,className:R("flex cursor-default gap-2 select-none items-center 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),...o,children:[n,c.jsx(qo,{className:"ml-auto"})]}));Ec.displayName=Cc.displayName;const Sc=l.forwardRef(({className:e,...t},n)=>c.jsx(Nc,{ref:n,className:R("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",e),...t}));Sc.displayName=Nc.displayName;const Pc=l.forwardRef(({className:e,sideOffset:t=4,...n},o)=>c.jsx(mc,{children:c.jsx(gc,{ref:o,sideOffset:t,className:R("z-50 min-w-[8rem] overflow-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",e),...n})}));Pc.displayName=gc.displayName;const Tc=l.forwardRef(({className:e,inset:t,...n},o)=>c.jsx(vc,{ref:o,className:R("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),...n}));Tc.displayName=vc.displayName;const Mc=l.forwardRef(({className:e,children:t,checked:n,...o},r)=>c.jsxs(bc,{ref:r,className:R("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:n,...o,children:[c.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:c.jsx(wc,{children:c.jsx(Yo,{className:"h-4 w-4"})})}),t]}));Mc.displayName=bc.displayName;const Rc=l.forwardRef(({className:e,children:t,...n},o)=>c.jsxs(yc,{ref:o,className:R("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),...n,children:[c.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:c.jsx(wc,{children:c.jsx(oi,{className:"h-2 w-2 fill-current"})})}),t]}));Rc.displayName=yc.displayName;const Ac=l.forwardRef(({className:e,inset:t,...n},o)=>c.jsx(hc,{ref:o,className:R("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));Ac.displayName=hc.displayName;const _c=l.forwardRef(({className:e,...t},n)=>c.jsx(xc,{ref:n,className:R("-mx-1 my-1 h-px bg-muted",e),...t}));_c.displayName=xc.displayName;const Ic=({className:e,...t})=>c.jsx("span",{className:R("ml-auto text-xs tracking-widest opacity-60",e),...t});Ic.displayName="DropdownMenuShortcut";var Ob=e=>e.type==="checkbox",Lb=e=>e instanceof Date,kc=e=>e==null;const Fb=e=>typeof e=="object";var $t=e=>!kc(e)&&!Array.isArray(e)&&Fb(e)&&!Lb(e),$b=e=>$t(e)&&e.target?Ob(e.target)?e.target.checked:e.target.value:e,Vb=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Bb=(e,t)=>e.has(Vb(t)),Wb=e=>{const t=e.constructor&&e.constructor.prototype;return $t(t)&&t.hasOwnProperty("isPrototypeOf")},zb=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Ar(e){let t;const n=Array.isArray(e),o=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(!(zb&&(e instanceof Blob||o))&&(n||$t(e)))if(t=n?[]:{},!n&&!Wb(e))t=e;else for(const r in e)e.hasOwnProperty(r)&&(t[r]=Ar(e[r]));else return e;return t}var jc=e=>Array.isArray(e)?e.filter(Boolean):[],_r=e=>e===void 0,Pe=(e,t,n)=>{if(!t||!$t(e))return n;const o=jc(t.split(/[,[\].]+?/)).reduce((r,a)=>kc(r)?r:r[a],e);return _r(o)||o===e?_r(e[t])?n:e[t]:o},Dc=e=>typeof e=="boolean",Gb=e=>/^\w*$/.test(e),Hb=e=>jc(e.replace(/["|']|\]/g,"").split(/\.|\[/)),Oc=(e,t,n)=>{let o=-1;const r=Gb(t)?[t]:Hb(t),a=r.length,s=a-1;for(;++o<a;){const i=r[o];let u=n;if(o!==s){const d=e[i];u=$t(d)||Array.isArray(d)?d:isNaN(+r[o+1])?{}:[]}if(i==="__proto__"||i==="constructor"||i==="prototype")return;e[i]=u,e=e[i]}return e};const Lc={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},Fc={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},$c=S.createContext(null),uo=()=>S.useContext($c),Ub=e=>{const{children:t,...n}=e;return S.createElement($c.Provider,{value:n},t)};var Kb=(e,t,n,o=!0)=>{const r={defaultValues:t._defaultValues};for(const a in e)Object.defineProperty(r,a,{get:()=>{const s=a;return t._proxyFormState[s]!==Fc.all&&(t._proxyFormState[s]=!o||Fc.all),n&&(n[s]=!0),e[s]}});return r},Yb=e=>$t(e)&&!Object.keys(e).length,Xb=(e,t,n,o)=>{n(e);const{name:r,...a}=e;return Yb(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(s=>t[s]===!o)},qb=e=>Array.isArray(e)?e:[e],Vc=(e,t,n)=>!e||!t||e===t||qb(e).some(o=>o&&(n?o===t:o.startsWith(t)||t.startsWith(o)));function Bc(e){const t=S.useRef(e);t.current=e,S.useEffect(()=>{const n=!e.disabled&&t.current.subject&&t.current.subject.subscribe({next:t.current.next});return()=>{n&&n.unsubscribe()}},[e.disabled])}function Jb(e){const t=uo(),{control:n=t.control,disabled:o,name:r,exact:a}=e,[s,i]=S.useState(n._formState),u=S.useRef(!0),d=S.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),f=S.useRef(r);return f.current=r,Bc({disabled:o,next:m=>u.current&&Vc(f.current,m.name,a)&&Xb(m,d.current,n._updateFormState)&&i({...n._formState,...m}),subject:n._subjects.state}),S.useEffect(()=>(u.current=!0,d.current.isValid&&n._updateValid(!0),()=>{u.current=!1}),[n]),S.useMemo(()=>Kb(s,n,d.current,!1),[s,n])}var Zb=e=>typeof e=="string",Qb=(e,t,n,o,r)=>Zb(e)?Pe(n,e,r):Array.isArray(e)?e.map(a=>Pe(n,a)):n;function ey(e){const t=uo(),{control:n=t.control,name:o,defaultValue:r,disabled:a,exact:s}=e,i=S.useRef(o);i.current=o,Bc({disabled:a,subject:n._subjects.values,next:f=>{Vc(i.current,f.name,s)&&d(Ar(Qb(i.current,n._names,f.values||n._formValues,!1,r)))}});const[u,d]=S.useState(n._getWatch(o,r));return S.useEffect(()=>n._removeUnmounted()),u}function ty(e){const t=uo(),{name:n,disabled:o,control:r=t.control,shouldUnregister:a}=e,s=Bb(r._names.array,n),i=ey({control:r,name:n,defaultValue:Pe(r._formValues,n,Pe(r._defaultValues,n,e.defaultValue)),exact:!0}),u=Jb({control:r,name:n,exact:!0}),d=S.useRef(r.register(n,{...e.rules,value:i,...Dc(e.disabled)?{disabled:e.disabled}:{}})),f=S.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Pe(u.errors,n)},isDirty:{enumerable:!0,get:()=>!!Pe(u.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!Pe(u.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!Pe(u.validatingFields,n)},error:{enumerable:!0,get:()=>Pe(u.errors,n)}}),[u,n]),m=S.useMemo(()=>({name:n,value:i,...Dc(o)||u.disabled?{disabled:u.disabled||o}:{},onChange:h=>d.current.onChange({target:{value:$b(h),name:n},type:Lc.CHANGE}),onBlur:()=>d.current.onBlur({target:{value:Pe(r._formValues,n),name:n},type:Lc.BLUR}),ref:h=>{const p=Pe(r._fields,n);p&&h&&(p._f.ref={focus:()=>h.focus(),select:()=>h.select(),setCustomValidity:b=>h.setCustomValidity(b),reportValidity:()=>h.reportValidity()})}}),[n,r._formValues,o,u.disabled,i,r._fields]);return S.useEffect(()=>{const h=r._options.shouldUnregister||a,p=(b,g)=>{const v=Pe(r._fields,b);v&&v._f&&(v._f.mount=g)};if(p(n,!0),h){const b=Ar(Pe(r._options.defaultValues,n));Oc(r._defaultValues,n,b),_r(Pe(r._formValues,n))&&Oc(r._formValues,n,b)}return!s&&r.register(n),()=>{(s?h&&!r._state.action:h)?r.unregister(n):p(n,!1)}},[n,r,s,a]),S.useEffect(()=>{r._updateDisabledField({disabled:o,fields:r._fields,name:n})},[o,n,r]),S.useMemo(()=>({field:m,formState:u,fieldState:f}),[m,u,f])}const ny=e=>e.render(ty(e));var oy="Label",Wc=l.forwardRef((e,t)=>c.jsx(L.label,{...e,ref:t,onMouseDown:n=>{var r;n.target.closest("button, input, select, textarea")||((r=e.onMouseDown)==null||r.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));Wc.displayName=oy;var zc=Wc;const ry=Mt("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Ir=l.forwardRef(({className:e,...t},n)=>c.jsx(zc,{ref:n,className:R(ry(),e),...t}));Ir.displayName=zc.displayName;const ay=Ub,Gc=l.createContext({}),sy=({...e})=>c.jsx(Gc.Provider,{value:{name:e.name},children:c.jsx(ny,{...e})}),hn=()=>{const e=l.useContext(Gc),t=l.useContext(Hc),{getFieldState:n,formState:o}=uo(),r=n(e.name,o);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`,...r}},Hc=l.createContext({}),Uc=l.forwardRef(({className:e,...t},n)=>{const o=l.useId();return c.jsx(Hc.Provider,{value:{id:o},children:c.jsx("div",{ref:n,className:R("space-y-2",e),...t})})});Uc.displayName="FormItem";const Kc=l.forwardRef(({className:e,...t},n)=>{const{error:o,formItemId:r}=hn();return c.jsx(Ir,{ref:n,className:R(o&&"text-destructive",e),htmlFor:r,...t})});Kc.displayName="FormLabel";const Yc=l.forwardRef(({...e},t)=>{const{error:n,formItemId:o,formDescriptionId:r,formMessageId:a}=hn();return c.jsx(We,{ref:t,id:o,"aria-describedby":n?`${r} ${a}`:`${r}`,"aria-invalid":!!n,...e})});Yc.displayName="FormControl";const Xc=l.forwardRef(({className:e,...t},n)=>{const{formDescriptionId:o}=hn();return c.jsx("p",{ref:n,id:o,className:R("text-[0.8rem] text-muted-foreground",e),...t})});Xc.displayName="FormDescription";const qc=l.forwardRef(({className:e,children:t,...n},o)=>{const{error:r,formMessageId:a}=hn(),s=r?String(r==null?void 0:r.message):t;return s?c.jsx("p",{ref:o,id:a,className:R("text-[0.8rem] font-medium text-destructive",e),...n,children:s}):null});qc.displayName="FormMessage";var iy="VisuallyHidden",kr=l.forwardRef((e,t)=>c.jsx(L.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}}));kr.displayName=iy;var Jc=kr,Vt="NavigationMenu",[jr,Zc,ly]=cn(Vt),[Dr,cy,uy]=cn(Vt),[Or,N0]=ve(Vt,[ly,uy]),[dy,Ie]=Or(Vt),[fy,py]=Or(Vt),Qc=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:o,onValueChange:r,defaultValue:a,delayDuration:s=200,skipDelayDuration:i=300,orientation:u="horizontal",dir:d,...f}=e,[m,h]=l.useState(null),p=J(t,j=>h(j)),b=Nt(d),g=l.useRef(0),v=l.useRef(0),y=l.useRef(0),[w,C]=l.useState(!0),[N="",E]=Ce({prop:o,onChange:j=>{const B=j!=="",z=i>0;B?(window.clearTimeout(y.current),z&&C(!1)):(window.clearTimeout(y.current),y.current=window.setTimeout(()=>C(!0),i)),r==null||r(j)},defaultProp:a}),A=l.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>E(""),150)},[E]),M=l.useCallback(j=>{window.clearTimeout(v.current),E(j)},[E]),I=l.useCallback(j=>{N===j?window.clearTimeout(v.current):g.current=window.setTimeout(()=>{window.clearTimeout(v.current),E(j)},s)},[N,E,s]);return l.useEffect(()=>()=>{window.clearTimeout(g.current),window.clearTimeout(v.current),window.clearTimeout(y.current)},[]),c.jsx(tu,{scope:n,isRootMenu:!0,value:N,dir:b,orientation:u,rootNavigationMenu:m,onTriggerEnter:j=>{window.clearTimeout(g.current),w?I(j):M(j)},onTriggerLeave:()=>{window.clearTimeout(g.current),A()},onContentEnter:()=>window.clearTimeout(v.current),onContentLeave:A,onItemSelect:j=>{E(B=>B===j?"":j)},onItemDismiss:()=>E(""),children:c.jsx(L.nav,{"aria-label":"Main","data-orientation":u,dir:b,...f,ref:p})})});Qc.displayName=Vt;var eu="NavigationMenuSub",my=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:o,onValueChange:r,defaultValue:a,orientation:s="horizontal",...i}=e,u=Ie(eu,n),[d="",f]=Ce({prop:o,onChange:r,defaultProp:a});return c.jsx(tu,{scope:n,isRootMenu:!1,value:d,dir:u.dir,orientation:s,rootNavigationMenu:u.rootNavigationMenu,onTriggerEnter:m=>f(m),onItemSelect:m=>f(m),onItemDismiss:()=>f(""),children:c.jsx(L.div,{"data-orientation":s,...i,ref:t})})});my.displayName=eu;var tu=e=>{const{scope:t,isRootMenu:n,rootNavigationMenu:o,dir:r,orientation:a,children:s,value:i,onItemSelect:u,onItemDismiss:d,onTriggerEnter:f,onTriggerLeave:m,onContentEnter:h,onContentLeave:p}=e,[b,g]=l.useState(null),[v,y]=l.useState(new Map),[w,C]=l.useState(null);return c.jsx(dy,{scope:t,isRootMenu:n,rootNavigationMenu:o,value:i,previousValue:ln(i),baseId:Ne(),dir:r,orientation:a,viewport:b,onViewportChange:g,indicatorTrack:w,onIndicatorTrackChange:C,onTriggerEnter:ge(f),onTriggerLeave:ge(m),onContentEnter:ge(h),onContentLeave:ge(p),onItemSelect:ge(u),onItemDismiss:ge(d),onViewportContentChange:l.useCallback((N,E)=>{y(A=>(A.set(N,E),new Map(A)))},[]),onViewportContentRemove:l.useCallback(N=>{y(E=>E.has(N)?(E.delete(N),new Map(E)):E)},[]),children:c.jsx(jr.Provider,{scope:t,children:c.jsx(fy,{scope:t,items:v,children:s})})})},nu="NavigationMenuList",ou=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...o}=e,r=Ie(nu,n),a=c.jsx(L.ul,{"data-orientation":r.orientation,...o,ref:t});return c.jsx(L.div,{style:{position:"relative"},ref:r.onIndicatorTrackChange,children:c.jsx(jr.Slot,{scope:n,children:r.isRootMenu?c.jsx(mu,{asChild:!0,children:a}):a})})});ou.displayName=nu;var ru="NavigationMenuItem",[gy,au]=Or(ru),su=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:o,...r}=e,a=Ne(),s=o||a||"LEGACY_REACT_AUTO_VALUE",i=l.useRef(null),u=l.useRef(null),d=l.useRef(null),f=l.useRef(()=>{}),m=l.useRef(!1),h=l.useCallback((b="start")=>{if(i.current){f.current();const g=Vr(i.current);g.length&&Br(b==="start"?g:g.reverse())}},[]),p=l.useCallback(()=>{if(i.current){const b=Vr(i.current);b.length&&(f.current=Cy(b))}},[]);return c.jsx(gy,{scope:n,value:s,triggerRef:u,contentRef:i,focusProxyRef:d,wasEscapeCloseRef:m,onEntryKeyDown:h,onFocusProxyEnter:h,onRootContentClose:p,onContentFocusOutside:p,children:c.jsx(L.li,{...r,ref:t})})});su.displayName=ru;var Lr="NavigationMenuTrigger",iu=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,disabled:o,...r}=e,a=Ie(Lr,e.__scopeNavigationMenu),s=au(Lr,e.__scopeNavigationMenu),i=l.useRef(null),u=J(i,s.triggerRef,t),d=vu(a.baseId,s.value),f=bu(a.baseId,s.value),m=l.useRef(!1),h=l.useRef(!1),p=s.value===a.value;return c.jsxs(c.Fragment,{children:[c.jsx(jr.ItemSlot,{scope:n,value:s.value,children:c.jsx(hu,{asChild:!0,children:c.jsx(L.button,{id:d,disabled:o,"data-disabled":o?"":void 0,"data-state":zr(p),"aria-expanded":p,"aria-controls":f,...r,ref:u,onPointerEnter:_(e.onPointerEnter,()=>{h.current=!1,s.wasEscapeCloseRef.current=!1}),onPointerMove:_(e.onPointerMove,po(()=>{o||h.current||s.wasEscapeCloseRef.current||m.current||(a.onTriggerEnter(s.value),m.current=!0)})),onPointerLeave:_(e.onPointerLeave,po(()=>{o||(a.onTriggerLeave(),m.current=!1)})),onClick:_(e.onClick,()=>{a.onItemSelect(s.value),h.current=p}),onKeyDown:_(e.onKeyDown,b=>{const v={horizontal:"ArrowDown",vertical:a.dir==="rtl"?"ArrowLeft":"ArrowRight"}[a.orientation];p&&b.key===v&&(s.onEntryKeyDown(),b.preventDefault())})})})}),p&&c.jsxs(c.Fragment,{children:[c.jsx(Jc,{"aria-hidden":!0,tabIndex:0,ref:s.focusProxyRef,onFocus:b=>{const g=s.contentRef.current,v=b.relatedTarget,y=v===i.current,w=g==null?void 0:g.contains(v);(y||!w)&&s.onFocusProxyEnter(y?"start":"end")}}),a.viewport&&c.jsx("span",{"aria-owns":f})]})]})});iu.displayName=Lr;var hy="NavigationMenuLink",lu="navigationMenu.linkSelect",cu=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,active:o,onSelect:r,...a}=e;return c.jsx(hu,{asChild:!0,children:c.jsx(L.a,{"data-active":o?"":void 0,"aria-current":o?"page":void 0,...a,ref:t,onClick:_(e.onClick,s=>{const i=s.target,u=new CustomEvent(lu,{bubbles:!0,cancelable:!0});if(i.addEventListener(lu,d=>r==null?void 0:r(d),{once:!0}),Rn(i,u),!u.defaultPrevented&&!s.metaKey){const d=new CustomEvent(fo,{bubbles:!0,cancelable:!0});Rn(i,d)}},{checkForDefaultPrevented:!1})})})});cu.displayName=hy;var Fr="NavigationMenuIndicator",uu=l.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=Ie(Fr,e.__scopeNavigationMenu),a=!!r.value;return r.indicatorTrack?En.createPortal(c.jsx(be,{present:n||a,children:c.jsx(vy,{...o,ref:t})}),r.indicatorTrack):null});uu.displayName=Fr;var vy=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...o}=e,r=Ie(Fr,n),a=Zc(n),[s,i]=l.useState(null),[u,d]=l.useState(null),f=r.orientation==="horizontal",m=!!r.value;l.useEffect(()=>{var g;const b=(g=a().find(v=>v.value===r.value))==null?void 0:g.ref.current;b&&i(b)},[a,r.value]);const h=()=>{s&&d({size:f?s.offsetWidth:s.offsetHeight,offset:f?s.offsetLeft:s.offsetTop})};return Wr(s,h),Wr(r.indicatorTrack,h),u?c.jsx(L.div,{"aria-hidden":!0,"data-state":m?"visible":"hidden","data-orientation":r.orientation,...o,ref:t,style:{position:"absolute",...f?{left:0,width:u.size+"px",transform:`translateX(${u.offset}px)`}:{top:0,height:u.size+"px",transform:`translateY(${u.offset}px)`},...o.style}}):null}),Bt="NavigationMenuContent",du=l.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=Ie(Bt,e.__scopeNavigationMenu),a=au(Bt,e.__scopeNavigationMenu),s=J(a.contentRef,t),i=a.value===r.value,u={value:a.value,triggerRef:a.triggerRef,focusProxyRef:a.focusProxyRef,wasEscapeCloseRef:a.wasEscapeCloseRef,onContentFocusOutside:a.onContentFocusOutside,onRootContentClose:a.onRootContentClose,...o};return r.viewport?c.jsx(by,{forceMount:n,...u,ref:s}):c.jsx(be,{present:n||i,children:c.jsx(fu,{"data-state":zr(i),...u,ref:s,onPointerEnter:_(e.onPointerEnter,r.onContentEnter),onPointerLeave:_(e.onPointerLeave,po(r.onContentLeave)),style:{pointerEvents:!i&&r.isRootMenu?"none":void 0,...u.style}})})});du.displayName=Bt;var by=l.forwardRef((e,t)=>{const n=Ie(Bt,e.__scopeNavigationMenu),{onViewportContentChange:o,onViewportContentRemove:r}=n;return he(()=>{o(e.value,{ref:t,...e})},[e,t,o]),he(()=>()=>r(e.value),[e.value,r]),null}),fo="navigationMenu.rootContentDismiss",fu=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,value:o,triggerRef:r,focusProxyRef:a,wasEscapeCloseRef:s,onRootContentClose:i,onContentFocusOutside:u,...d}=e,f=Ie(Bt,n),m=l.useRef(null),h=J(m,t),p=vu(f.baseId,o),b=bu(f.baseId,o),g=Zc(n),v=l.useRef(null),{onItemDismiss:y}=f;l.useEffect(()=>{const C=m.current;if(f.isRootMenu&&C){const N=()=>{var E;y(),i(),C.contains(document.activeElement)&&((E=r.current)==null||E.focus())};return C.addEventListener(fo,N),()=>C.removeEventListener(fo,N)}},[f.isRootMenu,e.value,r,y,i]);const w=l.useMemo(()=>{const N=g().map(B=>B.value);f.dir==="rtl"&&N.reverse();const E=N.indexOf(f.value),A=N.indexOf(f.previousValue),M=o===f.value,I=A===N.indexOf(o);if(!M&&!I)return v.current;const j=(()=>{if(E!==A){if(M&&A!==-1)return E>A?"from-end":"from-start";if(I&&E!==-1)return E>A?"to-start":"to-end"}return null})();return v.current=j,j},[f.previousValue,f.value,f.dir,g,o]);return c.jsx(mu,{asChild:!0,children:c.jsx(wt,{id:b,"aria-labelledby":p,"data-motion":w,"data-orientation":f.orientation,...d,ref:h,disableOutsidePointerEvents:!1,onDismiss:()=>{var N;const C=new Event(fo,{bubbles:!0,cancelable:!0});(N=m.current)==null||N.dispatchEvent(C)},onFocusOutside:_(e.onFocusOutside,C=>{var E;u();const N=C.target;(E=f.rootNavigationMenu)!=null&&E.contains(N)&&C.preventDefault()}),onPointerDownOutside:_(e.onPointerDownOutside,C=>{var M;const N=C.target,E=g().some(I=>{var j;return(j=I.ref.current)==null?void 0:j.contains(N)}),A=f.isRootMenu&&((M=f.viewport)==null?void 0:M.contains(N));(E||A||!f.isRootMenu)&&C.preventDefault()}),onKeyDown:_(e.onKeyDown,C=>{var A;const N=C.altKey||C.ctrlKey||C.metaKey;if(C.key==="Tab"&&!N){const M=Vr(C.currentTarget),I=document.activeElement,j=M.findIndex(O=>O===I),z=C.shiftKey?M.slice(0,j).reverse():M.slice(j+1,M.length);Br(z)?C.preventDefault():(A=a.current)==null||A.focus()}}),onEscapeKeyDown:_(e.onEscapeKeyDown,C=>{s.current=!0})})})}),$r="NavigationMenuViewport",pu=l.forwardRef((e,t)=>{const{forceMount:n,...o}=e,a=!!Ie($r,e.__scopeNavigationMenu).value;return c.jsx(be,{present:n||a,children:c.jsx(yy,{...o,ref:t})})});pu.displayName=$r;var yy=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,children:o,...r}=e,a=Ie($r,n),s=J(t,a.onViewportChange),i=py(Bt,e.__scopeNavigationMenu),[u,d]=l.useState(null),[f,m]=l.useState(null),h=u?(u==null?void 0:u.width)+"px":void 0,p=u?(u==null?void 0:u.height)+"px":void 0,b=!!a.value,g=b?a.value:a.previousValue;return Wr(f,()=>{f&&d({width:f.offsetWidth,height:f.offsetHeight})}),c.jsx(L.div,{"data-state":zr(b),"data-orientation":a.orientation,...r,ref:s,style:{pointerEvents:!b&&a.isRootMenu?"none":void 0,"--radix-navigation-menu-viewport-width":h,"--radix-navigation-menu-viewport-height":p,...r.style},onPointerEnter:_(e.onPointerEnter,a.onContentEnter),onPointerLeave:_(e.onPointerLeave,po(a.onContentLeave)),children:Array.from(i.items).map(([y,{ref:w,forceMount:C,...N}])=>{const E=g===y;return c.jsx(be,{present:C||E,children:c.jsx(fu,{...N,ref:qt(w,A=>{E&&A&&m(A)})})},y)})})}),wy="FocusGroup",mu=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...o}=e,r=Ie(wy,n);return c.jsx(Dr.Provider,{scope:n,children:c.jsx(Dr.Slot,{scope:n,children:c.jsx(L.div,{dir:r.dir,...o,ref:t})})})}),gu=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],xy="FocusGroupItem",hu=l.forwardRef((e,t)=>{const{__scopeNavigationMenu:n,...o}=e,r=cy(n),a=Ie(xy,n);return c.jsx(Dr.ItemSlot,{scope:n,children:c.jsx(L.button,{...o,ref:t,onKeyDown:_(e.onKeyDown,s=>{if(["Home","End",...gu].includes(s.key)){let u=r().map(m=>m.ref.current);if([a.dir==="rtl"?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(s.key)&&u.reverse(),gu.includes(s.key)){const m=u.indexOf(s.currentTarget);u=u.slice(m+1)}setTimeout(()=>Br(u)),s.preventDefault()}})})})});function Vr(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Br(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}function Cy(e){return e.forEach(t=>{t.dataset.tabindex=t.getAttribute("tabindex")||"",t.setAttribute("tabindex","-1")}),()=>{e.forEach(t=>{const n=t.dataset.tabindex;t.setAttribute("tabindex",n)})}}function Wr(e,t){const n=ge(t);he(()=>{let o=0;if(e){const r=new ResizeObserver(()=>{cancelAnimationFrame(o),o=window.requestAnimationFrame(n)});return r.observe(e),()=>{window.cancelAnimationFrame(o),r.unobserve(e)}}},[e,n])}function zr(e){return e?"open":"closed"}function vu(e,t){return`${e}-trigger-${t}`}function bu(e,t){return`${e}-content-${t}`}function po(e){return t=>t.pointerType==="mouse"?e(t):void 0}var yu=Qc,wu=ou,Ny=su,xu=iu,Ey=cu,Cu=uu,Nu=du,Eu=pu;const Su=l.forwardRef(({className:e,children:t,...n},o)=>c.jsxs(yu,{ref:o,className:R("relative z-10 flex max-w-max flex-1 items-center justify-center",e),...n,children:[t,c.jsx(Gr,{})]}));Su.displayName=yu.displayName;const Pu=l.forwardRef(({className:e,...t},n)=>c.jsx(wu,{ref:n,className:R("group flex flex-1 list-none items-center justify-center space-x-1",e),...t}));Pu.displayName=wu.displayName;const Sy=Ny,Tu=Mt("group inline-flex h-10 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-[active]:bg-accent/50 data-[state=open]:bg-accent/50"),Mu=l.forwardRef(({className:e,children:t,...n},o)=>c.jsxs(xu,{ref:o,className:R(Tu(),"group",e),...n,children:[t," ",c.jsx(Xo,{className:"relative top-[1px] ml-1 h-3 w-3 transition duration-200 group-data-[state=open]:rotate-180","aria-hidden":"true"})]}));Mu.displayName=xu.displayName;const Ru=l.forwardRef(({className:e,...t},n)=>c.jsx(Nu,{ref:n,className:R("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}));Ru.displayName=Nu.displayName;const Py=Ey,Gr=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:R("absolute left-0 top-full flex justify-center"),children:c.jsx(Eu,{className:R("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-lg 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:n,...t})}));Gr.displayName=Eu.displayName;const Au=l.forwardRef(({className:e,...t},n)=>c.jsx(Cu,{ref:n,className:R("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:c.jsx("div",{className:"relative top-[60%] h-2 w-2 rotate-45 rounded-tl-sm bg-border shadow-md"})}));Au.displayName=Cu.displayName;const Hr=({className:e,...t})=>c.jsx("nav",{role:"navigation","aria-label":"pagination",className:R("mx-auto flex w-full justify-center",e),...t});Hr.displayName="Pagination";const Ur=l.forwardRef(({className:e,...t},n)=>c.jsx("ul",{ref:n,className:R("flex flex-row items-center gap-1",e),...t}));Ur.displayName="PaginationContent";const vn=l.forwardRef(({className:e,...t},n)=>c.jsx("li",{ref:n,className:R("",e),...t}));vn.displayName="PaginationItem";const bn=({className:e,isActive:t,size:n="icon",...o})=>c.jsx(Ge,{"aria-current":t?"page":void 0,className:R(en({variant:t?"default":"outline",size:n}),t?"text-primary-foreground":"text-foreground",e),...o,children:o.children});bn.displayName="PaginationLink";const Kr=({className:e,...t})=>c.jsx(bn,{"aria-label":"Previous page",size:"default",className:R("gap-1",e),...t,children:c.jsx(ti,{className:"h-4 w-4"})});Kr.displayName="PaginationPrevious";const Yr=({className:e,...t})=>c.jsx(bn,{"aria-label":"Next page",size:"default",className:R("gap-1",e),...t,children:c.jsx(qo,{className:"h-4 w-4"})});Yr.displayName="PaginationNext";const _u=({className:e,...t})=>c.jsxs("span",{"aria-hidden":!0,className:R("flex h-9 w-9 items-center justify-center",e),...t,children:[c.jsx(Rg,{className:"h-4 w-4"}),c.jsx("span",{className:"sr-only",children:"More pages"})]});_u.displayName="PaginationEllipsis";var Xr="Progress",qr=100,[Ty,E0]=ve(Xr),[My,Ry]=Ty(Xr),Iu=l.forwardRef((e,t)=>{const{__scopeProgress:n,value:o=null,max:r,getValueLabel:a=Ay,...s}=e;(r||r===0)&&!Ou(r)&&console.error(_y(`${r}`,"Progress"));const i=Ou(r)?r:qr;o!==null&&!Lu(o,i)&&console.error(Iy(`${o}`,"Progress"));const u=Lu(o,i)?o:null,d=mo(u)?a(u,i):void 0;return c.jsx(My,{scope:n,value:u,max:i,children:c.jsx(L.div,{"aria-valuemax":i,"aria-valuemin":0,"aria-valuenow":mo(u)?u:void 0,"aria-valuetext":d,role:"progressbar","data-state":Du(u,i),"data-value":u??void 0,"data-max":i,...s,ref:t})})});Iu.displayName=Xr;var ku="ProgressIndicator",ju=l.forwardRef((e,t)=>{const{__scopeProgress:n,...o}=e,r=Ry(ku,n);return c.jsx(L.div,{"data-state":Du(r.value,r.max),"data-value":r.value??void 0,"data-max":r.max,...o,ref:t})});ju.displayName=ku;function Ay(e,t){return`${Math.round(e/t*100)}%`}function Du(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function mo(e){return typeof e=="number"}function Ou(e){return mo(e)&&!isNaN(e)&&e>0}function Lu(e,t){return mo(e)&&!isNaN(e)&&e<=t&&e>=0}function _y(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${qr}\`.`}function Iy(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
192
192
  - a positive number
193
- - less than the value passed to \`max\` (or ${Ta} if no \`max\` prop is set)
193
+ - less than the value passed to \`max\` (or ${qr} if no \`max\` prop is set)
194
194
  - \`null\` or \`undefined\` if the progress is indeterminate.
195
195
 
196
- Defaulting to \`null\`.`}var ef=Kd,vN=Xd;const Da=l.forwardRef(({className:e,value:t,...n},r)=>u.jsx(ef,{ref:r,className:O("relative h-2 w-full overflow-hidden rounded-full bg-primary/20",e),...n,children:u.jsx(vN,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));Da.displayName=ef.displayName;function yN(e){const{showStrengthMeter:t=!0,className:n,strengthLabels:r={veryWeak:"Very weak",weak:"Weak",medium:"Medium",strong:"Strong",veryStrong:"Very strong"},showPasswordLabel:o="Show password",hidePasswordLabel:a="Hide password",strengthTitle:s="Password strength",...i}=e,[c,d]=x.useState(""),[f,m]=x.useState(!1),p=w=>{let b=0;return w.length>=8&&(b+=25),w.match(/[a-z]/)&&(b+=25),w.match(/[A-Z]/)&&(b+=25),w.match(/[0-9]/)&&(b+=25),b},h=w=>w===0?r.veryWeak:w<=25?r.weak:w<=50?r.medium:w<=75?r.strong:r.veryStrong,v=p(c),g=h(v),y=w=>{var b;d(w.target.value),(b=e.onChange)==null||b.call(e,w)};return u.jsxs("div",{className:"w-full space-y-4",children:[u.jsxs("div",{className:"relative",children:[u.jsx(tr,{...i,type:f?"text":"password",value:c,onChange:y,className:`pr-10 ${n||""}`}),u.jsx(lt,{type:"button",variant:"ghost",size:"icon",className:"absolute right-0 top-0 h-full",onClick:()=>m(!f),"aria-label":f?a:o,children:f?u.jsx(zg,{className:"h-4 w-4"}):u.jsx(Hg,{className:"h-4 w-4"})})]}),t&&u.jsxs("div",{className:"space-y-2",children:[u.jsxs("div",{className:"flex justify-between text-sm",children:[u.jsxs("span",{children:[s,":"]}),u.jsx("span",{children:g})]}),u.jsx(Da,{value:v,className:"h-2"})]})]})}var Oa="Radio",[bN,tf]=Te(Oa),[wN,xN]=bN(Oa),nf=l.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:o=!1,required:a,disabled:s,value:i="on",onCheck:c,form:d,...f}=e,[m,p]=l.useState(null),h=ne(t,y=>p(y)),v=l.useRef(!1),g=m?d||!!m.closest("form"):!0;return u.jsxs(wN,{scope:n,checked:o,disabled:s,children:[u.jsx(F.button,{type:"button",role:"radio","aria-checked":o,"data-state":af(o),"data-disabled":s?"":void 0,disabled:s,value:i,...f,ref:h,onClick:A(e.onClick,y=>{o||c==null||c(),g&&(v.current=y.isPropagationStopped(),v.current||y.stopPropagation())})}),g&&u.jsx(CN,{control:m,bubbles:!v.current,name:r,value:i,checked:o,required:a,disabled:s,form:d,style:{transform:"translateX(-100%)"}})]})});nf.displayName=Oa;var rf="RadioIndicator",of=l.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...o}=e,a=xN(rf,n);return u.jsx(De,{present:r||a.checked,children:u.jsx(F.span,{"data-state":af(a.checked),"data-disabled":a.disabled?"":void 0,...o,ref:t})})});of.displayName=rf;var CN=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=l.useRef(null),s=$n(n),i=Sr(t);return l.useEffect(()=>{const c=a.current,d=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(d,"checked").set;if(s!==n&&m){const p=new Event("click",{bubbles:r});m.call(c,n),c.dispatchEvent(p)}},[s,n,r]),u.jsx("input",{type:"radio","aria-hidden":!0,defaultChecked:n,...o,tabIndex:-1,ref:a,style:{...e.style,...i,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function af(e){return e?"checked":"unchecked"}var NN=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Aa="RadioGroup",[MN,_S]=Te(Aa,[Rt,tf]),sf=Rt(),cf=tf(),[SN,EN]=MN(Aa),lf=l.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:o,value:a,required:s=!1,disabled:i=!1,orientation:c,dir:d,loop:f=!0,onValueChange:m,...p}=e,h=sf(n),v=Yt(d),[g,y]=Ie({prop:a,defaultProp:o,onChange:m});return u.jsx(SN,{scope:n,name:r,required:s,disabled:i,value:g,onValueChange:y,children:u.jsx(Ir,{asChild:!0,...h,orientation:c,dir:v,loop:f,children:u.jsx(F.div,{role:"radiogroup","aria-required":s,"aria-orientation":c,"data-disabled":i?"":void 0,dir:v,...p,ref:t})})})});lf.displayName=Aa;var uf="RadioGroupItem",df=l.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...o}=e,a=EN(uf,n),s=a.disabled||r,i=sf(n),c=cf(n),d=l.useRef(null),f=ne(t,d),m=a.value===o.value,p=l.useRef(!1);return l.useEffect(()=>{const h=g=>{NN.includes(g.key)&&(p.current=!0)},v=()=>p.current=!1;return document.addEventListener("keydown",h),document.addEventListener("keyup",v),()=>{document.removeEventListener("keydown",h),document.removeEventListener("keyup",v)}},[]),u.jsx(jr,{asChild:!0,...i,focusable:!s,active:m,children:u.jsx(nf,{disabled:s,required:a.required,checked:m,...c,...o,name:a.name,ref:f,onCheck:()=>a.onValueChange(o.value),onKeyDown:A(h=>{h.key==="Enter"&&h.preventDefault()}),onFocus:A(o.onFocus,()=>{var h;p.current&&((h=d.current)==null||h.click())})})})});df.displayName=uf;var PN="RadioGroupIndicator",ff=l.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,o=cf(n);return u.jsx(of,{...o,...r,ref:t})});ff.displayName=PN;var mf=lf,hf=df,kN=ff;const pf=l.forwardRef(({className:e,...t},n)=>u.jsx(mf,{className:O("grid gap-2",e),...t,ref:n}));pf.displayName=mf.displayName;const gf=l.forwardRef(({className:e,...t},n)=>u.jsx(hf,{ref:n,className:O("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:u.jsx(kN,{className:"flex items-center justify-center",children:u.jsx(Ri,{className:"h-3.5 w-3.5 fill-primary"})})}));gf.displayName=hf.displayName;function vf(e,[t,n]){return Math.min(n,Math.max(t,e))}var TN=[" ","Enter","ArrowUp","ArrowDown"],DN=[" ","Enter"],qn="Select",[Gr,zr,ON]=Wn(qn),[mn,RS]=Te(qn,[ON,Dt]),Hr=Dt(),[AN,jt]=mn(qn),[_N,RN]=mn(qn),yf=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:a,value:s,defaultValue:i,onValueChange:c,dir:d,name:f,autoComplete:m,disabled:p,required:h,form:v}=e,g=Hr(t),[y,w]=l.useState(null),[b,C]=l.useState(null),[M,S]=l.useState(!1),k=Yt(d),[P=!1,D]=Ie({prop:r,defaultProp:o,onChange:a}),[R,$]=Ie({prop:s,defaultProp:i,onChange:c}),V=l.useRef(null),_=y?v||!!y.closest("form"):!0,[z,G]=l.useState(new Set),ee=Array.from(z).map(W=>W.props.value).join(";");return u.jsx(Tn,{...g,children:u.jsxs(AN,{required:h,scope:t,trigger:y,onTriggerChange:w,valueNode:b,onValueNodeChange:C,valueNodeHasChildren:M,onValueNodeHasChildrenChange:S,contentId:je(),value:R,onValueChange:$,open:P,onOpenChange:D,dir:k,triggerPointerDownPosRef:V,disabled:p,children:[u.jsx(Gr.Provider,{scope:t,children:u.jsx(_N,{scope:e.__scopeSelect,onNativeOptionAdd:l.useCallback(W=>{G(Y=>new Set(Y).add(W))},[]),onNativeOptionRemove:l.useCallback(W=>{G(Y=>{const L=new Set(Y);return L.delete(W),L})},[]),children:n})}),_?u.jsxs(Yf,{"aria-hidden":!0,required:h,tabIndex:-1,name:f,autoComplete:m,value:R,onChange:W=>$(W.target.value),disabled:p,form:v,children:[R===void 0?u.jsx("option",{value:""}):null,Array.from(z)]},ee):null]})})};yf.displayName=qn;var bf="SelectTrigger",wf=l.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,a=Hr(n),s=jt(bf,n),i=s.disabled||r,c=ne(t,s.onTriggerChange),d=zr(n),f=l.useRef("touch"),[m,p,h]=Gf(g=>{const y=d().filter(C=>!C.disabled),w=y.find(C=>C.value===s.value),b=zf(y,g,w);b!==void 0&&s.onValueChange(b.value)}),v=g=>{i||(s.onOpenChange(!0),h()),g&&(s.triggerPointerDownPosRef.current={x:Math.round(g.pageX),y:Math.round(g.pageY)})};return u.jsx(Dn,{asChild:!0,...a,children:u.jsx(F.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:i,"data-disabled":i?"":void 0,"data-placeholder":Vf(s.value)?"":void 0,...o,ref:c,onClick:A(o.onClick,g=>{g.currentTarget.focus(),f.current!=="mouse"&&v(g)}),onPointerDown:A(o.onPointerDown,g=>{f.current=g.pointerType;const y=g.target;y.hasPointerCapture(g.pointerId)&&y.releasePointerCapture(g.pointerId),g.button===0&&g.ctrlKey===!1&&g.pointerType==="mouse"&&(v(g),g.preventDefault())}),onKeyDown:A(o.onKeyDown,g=>{const y=m.current!=="";!(g.ctrlKey||g.altKey||g.metaKey)&&g.key.length===1&&p(g.key),!(y&&g.key===" ")&&TN.includes(g.key)&&(v(),g.preventDefault())})})})});wf.displayName=bf;var xf="SelectValue",Cf=l.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:a,placeholder:s="",...i}=e,c=jt(xf,n),{onValueNodeHasChildrenChange:d}=c,f=a!==void 0,m=ne(t,c.onValueNodeChange);return Ee(()=>{d(f)},[d,f]),u.jsx(F.span,{...i,ref:m,style:{pointerEvents:"none"},children:Vf(c.value)?u.jsx(u.Fragment,{children:s}):a})});Cf.displayName=xf;var IN="SelectIcon",Nf=l.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return u.jsx(F.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});Nf.displayName=IN;var zt="SelectContent",Mf=l.forwardRef((e,t)=>{const n=jt(zt,e.__scopeSelect),[r,o]=l.useState();if(Ee(()=>{o(new DocumentFragment)},[]),!n.open){const a=r;return a?Jn.createPortal(u.jsx(Sf,{scope:e.__scopeSelect,children:u.jsx(Gr.Slot,{scope:e.__scopeSelect,children:u.jsx("div",{children:e.children})})}),a):null}return u.jsx(Ef,{...e,ref:t})});Mf.displayName=zt;var rt=10,[Sf,Ft]=mn(zt),jN="SelectContentImpl",Ef=l.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:a,onPointerDownOutside:s,side:i,sideOffset:c,align:d,alignOffset:f,arrowPadding:m,collisionBoundary:p,collisionPadding:h,sticky:v,hideWhenDetached:g,avoidCollisions:y,...w}=e,b=jt(zt,n),[C,M]=l.useState(null),[S,k]=l.useState(null),P=ne(t,I=>M(I)),[D,R]=l.useState(null),[$,V]=l.useState(null),_=zr(n),[z,G]=l.useState(!1),ee=l.useRef(!1);l.useEffect(()=>{if(C)return mr(C)},[C]),ar();const W=l.useCallback(I=>{const[ie,...ce]=_().map(le=>le.ref.current),[oe]=ce.slice(-1),se=document.activeElement;for(const le of I)if(le===se||(le==null||le.scrollIntoView({block:"nearest"}),le===ie&&S&&(S.scrollTop=0),le===oe&&S&&(S.scrollTop=S.scrollHeight),le==null||le.focus(),document.activeElement!==se))return},[_,S]),Y=l.useCallback(()=>W([D,C]),[W,D,C]);l.useEffect(()=>{z&&Y()},[z,Y]);const{onOpenChange:L,triggerPointerDownPosRef:T}=b;l.useEffect(()=>{if(C){let I={x:0,y:0};const ie=oe=>{var se,le;I={x:Math.abs(Math.round(oe.pageX)-(((se=T.current)==null?void 0:se.x)??0)),y:Math.abs(Math.round(oe.pageY)-(((le=T.current)==null?void 0:le.y)??0))}},ce=oe=>{I.x<=10&&I.y<=10?oe.preventDefault():C.contains(oe.target)||L(!1),document.removeEventListener("pointermove",ie),T.current=null};return T.current!==null&&(document.addEventListener("pointermove",ie),document.addEventListener("pointerup",ce,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",ie),document.removeEventListener("pointerup",ce,{capture:!0})}}},[C,L,T]),l.useEffect(()=>{const I=()=>L(!1);return window.addEventListener("blur",I),window.addEventListener("resize",I),()=>{window.removeEventListener("blur",I),window.removeEventListener("resize",I)}},[L]);const[H,q]=Gf(I=>{const ie=_().filter(se=>!se.disabled),ce=ie.find(se=>se.ref.current===document.activeElement),oe=zf(ie,I,ce);oe&&setTimeout(()=>oe.ref.current.focus())}),X=l.useCallback((I,ie,ce)=>{const oe=!ee.current&&!ce;(b.value!==void 0&&b.value===ie||oe)&&(R(I),oe&&(ee.current=!0))},[b.value]),K=l.useCallback(()=>C==null?void 0:C.focus(),[C]),Z=l.useCallback((I,ie,ce)=>{const oe=!ee.current&&!ce;(b.value!==void 0&&b.value===ie||oe)&&V(I)},[b.value]),me=r==="popper"?_a:Pf,ge=me===_a?{side:i,sideOffset:c,align:d,alignOffset:f,arrowPadding:m,collisionBoundary:p,collisionPadding:h,sticky:v,hideWhenDetached:g,avoidCollisions:y}:{};return u.jsx(Sf,{scope:n,content:C,viewport:S,onViewportChange:k,itemRefCallback:X,selectedItem:D,onItemLeave:K,itemTextRefCallback:Z,focusSelectedItem:Y,selectedItemText:$,position:r,isPositioned:z,searchRef:H,children:u.jsx(Mn,{as:it,allowPinchZoom:!0,children:u.jsx(Cn,{asChild:!0,trapped:b.open,onMountAutoFocus:I=>{I.preventDefault()},onUnmountAutoFocus:A(o,I=>{var ie;(ie=b.trigger)==null||ie.focus({preventScroll:!0}),I.preventDefault()}),children:u.jsx($t,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:I=>I.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:u.jsx(me,{role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:I=>I.preventDefault(),...w,...ge,onPlaced:()=>G(!0),ref:P,style:{display:"flex",flexDirection:"column",outline:"none",...w.style},onKeyDown:A(w.onKeyDown,I=>{const ie=I.ctrlKey||I.altKey||I.metaKey;if(I.key==="Tab"&&I.preventDefault(),!ie&&I.key.length===1&&q(I.key),["ArrowUp","ArrowDown","Home","End"].includes(I.key)){let oe=_().filter(se=>!se.disabled).map(se=>se.ref.current);if(["ArrowUp","End"].includes(I.key)&&(oe=oe.slice().reverse()),["ArrowUp","ArrowDown"].includes(I.key)){const se=I.target,le=oe.indexOf(se);oe=oe.slice(le+1)}setTimeout(()=>W(oe)),I.preventDefault()}})})})})})})});Ef.displayName=jN;var FN="SelectItemAlignedPosition",Pf=l.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,a=jt(zt,n),s=Ft(zt,n),[i,c]=l.useState(null),[d,f]=l.useState(null),m=ne(t,P=>f(P)),p=zr(n),h=l.useRef(!1),v=l.useRef(!0),{viewport:g,selectedItem:y,selectedItemText:w,focusSelectedItem:b}=s,C=l.useCallback(()=>{if(a.trigger&&a.valueNode&&i&&d&&g&&y&&w){const P=a.trigger.getBoundingClientRect(),D=d.getBoundingClientRect(),R=a.valueNode.getBoundingClientRect(),$=w.getBoundingClientRect();if(a.dir!=="rtl"){const se=$.left-D.left,le=R.left-se,Me=P.left-le,Re=P.width+Me,$e=Math.max(Re,D.width),ot=window.innerWidth-rt,Be=vf(le,[rt,Math.max(rt,ot-$e)]);i.style.minWidth=Re+"px",i.style.left=Be+"px"}else{const se=D.right-$.right,le=window.innerWidth-R.right-se,Me=window.innerWidth-P.right-le,Re=P.width+Me,$e=Math.max(Re,D.width),ot=window.innerWidth-rt,Be=vf(le,[rt,Math.max(rt,ot-$e)]);i.style.minWidth=Re+"px",i.style.right=Be+"px"}const V=p(),_=window.innerHeight-rt*2,z=g.scrollHeight,G=window.getComputedStyle(d),ee=parseInt(G.borderTopWidth,10),W=parseInt(G.paddingTop,10),Y=parseInt(G.borderBottomWidth,10),L=parseInt(G.paddingBottom,10),T=ee+W+z+L+Y,H=Math.min(y.offsetHeight*5,T),q=window.getComputedStyle(g),X=parseInt(q.paddingTop,10),K=parseInt(q.paddingBottom,10),Z=P.top+P.height/2-rt,me=_-Z,ge=y.offsetHeight/2,I=y.offsetTop+ge,ie=ee+W+I,ce=T-ie;if(ie<=Z){const se=V.length>0&&y===V[V.length-1].ref.current;i.style.bottom="0px";const le=d.clientHeight-g.offsetTop-g.offsetHeight,Me=Math.max(me,ge+(se?K:0)+le+Y),Re=ie+Me;i.style.height=Re+"px"}else{const se=V.length>0&&y===V[0].ref.current;i.style.top="0px";const Me=Math.max(Z,ee+g.offsetTop+(se?X:0)+ge)+ce;i.style.height=Me+"px",g.scrollTop=ie-Z+g.offsetTop}i.style.margin=`${rt}px 0`,i.style.minHeight=H+"px",i.style.maxHeight=_+"px",r==null||r(),requestAnimationFrame(()=>h.current=!0)}},[p,a.trigger,a.valueNode,i,d,g,y,w,a.dir,r]);Ee(()=>C(),[C]);const[M,S]=l.useState();Ee(()=>{d&&S(window.getComputedStyle(d).zIndex)},[d]);const k=l.useCallback(P=>{P&&v.current===!0&&(C(),b==null||b(),v.current=!1)},[C,b]);return u.jsx(WN,{scope:n,contentWrapper:i,shouldExpandOnScrollRef:h,onScrollButtonChange:k,children:u.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:M},children:u.jsx(F.div,{...o,ref:m,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});Pf.displayName=FN;var $N="SelectPopperPosition",_a=l.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=rt,...a}=e,s=Hr(n);return u.jsx(Er,{...s,...a,ref:t,align:r,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)"}})});_a.displayName=$N;var[WN,Ra]=mn(zt,{}),Ia="SelectViewport",kf=l.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,a=Ft(Ia,n),s=Ra(Ia,n),i=ne(t,a.onViewportChange),c=l.useRef(0);return u.jsxs(u.Fragment,{children:[u.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:r}),u.jsx(Gr.Slot,{scope:n,children:u.jsx(F.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:i,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:A(o.onScroll,d=>{const f=d.currentTarget,{contentWrapper:m,shouldExpandOnScrollRef:p}=s;if(p!=null&&p.current&&m){const h=Math.abs(c.current-f.scrollTop);if(h>0){const v=window.innerHeight-rt*2,g=parseFloat(m.style.minHeight),y=parseFloat(m.style.height),w=Math.max(g,y);if(w<v){const b=w+h,C=Math.min(v,b),M=b-C;m.style.height=C+"px",m.style.bottom==="0px"&&(f.scrollTop=M>0?M:0,m.style.justifyContent="flex-end")}}}c.current=f.scrollTop})})})]})});kf.displayName=Ia;var Tf="SelectGroup",[LN,BN]=mn(Tf),Df=l.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=je();return u.jsx(LN,{scope:n,id:o,children:u.jsx(F.div,{role:"group","aria-labelledby":o,...r,ref:t})})});Df.displayName=Tf;var Of="SelectLabel",Af=l.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=BN(Of,n);return u.jsx(F.div,{id:o.id,...r,ref:t})});Af.displayName=Of;var Ur="SelectItem",[VN,_f]=mn(Ur),Rf=l.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:a,...s}=e,i=jt(Ur,n),c=Ft(Ur,n),d=i.value===r,[f,m]=l.useState(a??""),[p,h]=l.useState(!1),v=ne(t,b=>{var C;return(C=c.itemRefCallback)==null?void 0:C.call(c,b,r,o)}),g=je(),y=l.useRef("touch"),w=()=>{o||(i.onValueChange(r),i.onOpenChange(!1))};if(r==="")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 u.jsx(VN,{scope:n,value:r,disabled:o,textId:g,isSelected:d,onItemTextChange:l.useCallback(b=>{m(C=>C||((b==null?void 0:b.textContent)??"").trim())},[]),children:u.jsx(Gr.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:u.jsx(F.div,{role:"option","aria-labelledby":g,"data-highlighted":p?"":void 0,"aria-selected":d&&p,"data-state":d?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...s,ref:v,onFocus:A(s.onFocus,()=>h(!0)),onBlur:A(s.onBlur,()=>h(!1)),onClick:A(s.onClick,()=>{y.current!=="mouse"&&w()}),onPointerUp:A(s.onPointerUp,()=>{y.current==="mouse"&&w()}),onPointerDown:A(s.onPointerDown,b=>{y.current=b.pointerType}),onPointerMove:A(s.onPointerMove,b=>{var C;y.current=b.pointerType,o?(C=c.onItemLeave)==null||C.call(c):y.current==="mouse"&&b.currentTarget.focus({preventScroll:!0})}),onPointerLeave:A(s.onPointerLeave,b=>{var C;b.currentTarget===document.activeElement&&((C=c.onItemLeave)==null||C.call(c))}),onKeyDown:A(s.onKeyDown,b=>{var M;((M=c.searchRef)==null?void 0:M.current)!==""&&b.key===" "||(DN.includes(b.key)&&w(),b.key===" "&&b.preventDefault())})})})})});Rf.displayName=Ur;var Xn="SelectItemText",If=l.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...a}=e,s=jt(Xn,n),i=Ft(Xn,n),c=_f(Xn,n),d=RN(Xn,n),[f,m]=l.useState(null),p=ne(t,w=>m(w),c.onItemTextChange,w=>{var b;return(b=i.itemTextRefCallback)==null?void 0:b.call(i,w,c.value,c.disabled)}),h=f==null?void 0:f.textContent,v=l.useMemo(()=>u.jsx("option",{value:c.value,disabled:c.disabled,children:h},c.value),[c.disabled,c.value,h]),{onNativeOptionAdd:g,onNativeOptionRemove:y}=d;return Ee(()=>(g(v),()=>y(v)),[g,y,v]),u.jsxs(u.Fragment,{children:[u.jsx(F.span,{id:c.textId,...a,ref:p}),c.isSelected&&s.valueNode&&!s.valueNodeHasChildren?Jn.createPortal(a.children,s.valueNode):null]})});If.displayName=Xn;var jf="SelectItemIndicator",Ff=l.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return _f(jf,n).isSelected?u.jsx(F.span,{"aria-hidden":!0,...r,ref:t}):null});Ff.displayName=jf;var ja="SelectScrollUpButton",$f=l.forwardRef((e,t)=>{const n=Ft(ja,e.__scopeSelect),r=Ra(ja,e.__scopeSelect),[o,a]=l.useState(!1),s=ne(t,r.onScrollButtonChange);return Ee(()=>{if(n.viewport&&n.isPositioned){let i=function(){const d=c.scrollTop>0;a(d)};const c=n.viewport;return i(),c.addEventListener("scroll",i),()=>c.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),o?u.jsx(Lf,{...e,ref:s,onAutoScroll:()=>{const{viewport:i,selectedItem:c}=n;i&&c&&(i.scrollTop=i.scrollTop-c.offsetHeight)}}):null});$f.displayName=ja;var Fa="SelectScrollDownButton",Wf=l.forwardRef((e,t)=>{const n=Ft(Fa,e.__scopeSelect),r=Ra(Fa,e.__scopeSelect),[o,a]=l.useState(!1),s=ne(t,r.onScrollButtonChange);return Ee(()=>{if(n.viewport&&n.isPositioned){let i=function(){const d=c.scrollHeight-c.clientHeight,f=Math.ceil(c.scrollTop)<d;a(f)};const c=n.viewport;return i(),c.addEventListener("scroll",i),()=>c.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),o?u.jsx(Lf,{...e,ref:s,onAutoScroll:()=>{const{viewport:i,selectedItem:c}=n;i&&c&&(i.scrollTop=i.scrollTop+c.offsetHeight)}}):null});Wf.displayName=Fa;var Lf=l.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,a=Ft("SelectScrollButton",n),s=l.useRef(null),i=zr(n),c=l.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return l.useEffect(()=>()=>c(),[c]),Ee(()=>{var f;const d=i().find(m=>m.ref.current===document.activeElement);(f=d==null?void 0:d.ref.current)==null||f.scrollIntoView({block:"nearest"})},[i]),u.jsx(F.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:A(o.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(r,50))}),onPointerMove:A(o.onPointerMove,()=>{var d;(d=a.onItemLeave)==null||d.call(a),s.current===null&&(s.current=window.setInterval(r,50))}),onPointerLeave:A(o.onPointerLeave,()=>{c()})})}),YN="SelectSeparator",Bf=l.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return u.jsx(F.div,{"aria-hidden":!0,...r,ref:t})});Bf.displayName=YN;var $a="SelectArrow",GN=l.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Hr(n),a=jt($a,n),s=Ft($a,n);return a.open&&s.position==="popper"?u.jsx(Pr,{...o,...r,ref:t}):null});GN.displayName=$a;function Vf(e){return e===""||e===void 0}var Yf=l.forwardRef((e,t)=>{const{value:n,...r}=e,o=l.useRef(null),a=ne(t,o),s=$n(n);return l.useEffect(()=>{const i=o.current,c=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(c,"value").set;if(s!==n&&f){const m=new Event("change",{bubbles:!0});f.call(i,n),i.dispatchEvent(m)}},[s,n]),u.jsx(fa,{asChild:!0,children:u.jsx("select",{...r,ref:a,defaultValue:n})})});Yf.displayName="BubbleSelect";function Gf(e){const t=Ne(e),n=l.useRef(""),r=l.useRef(0),o=l.useCallback(s=>{const i=n.current+s;t(i),function c(d){n.current=d,window.clearTimeout(r.current),d!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(i)},[t]),a=l.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return l.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,a]}function zf(e,t,n){const o=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=zN(e,Math.max(a,0));o.length===1&&(s=s.filter(d=>d!==n));const c=s.find(d=>d.textValue.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function zN(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var HN=yf,Hf=wf,UN=Cf,KN=Nf,Uf=Mf,qN=kf,XN=Df,Kf=Af,qf=Rf,QN=If,ZN=Ff,Xf=$f,Qf=Wf,Zf=Bf;const JN=HN,eM=XN,tM=UN,Jf=l.forwardRef(({className:e,children:t,...n},r)=>u.jsxs(Hf,{ref:r,className:O("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 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),...n,children:[t,u.jsx(KN,{asChild:!0,children:u.jsx(So,{className:"h-4 w-4 opacity-50"})})]}));Jf.displayName=Hf.displayName;const Wa=l.forwardRef(({className:e,...t},n)=>u.jsx(Xf,{ref:n,className:O("flex cursor-default items-center justify-center py-1",e),...t,children:u.jsx(Lg,{className:"h-4 w-4"})}));Wa.displayName=Xf.displayName;const La=l.forwardRef(({className:e,...t},n)=>u.jsx(Qf,{ref:n,className:O("flex cursor-default items-center justify-center py-1",e),...t,children:u.jsx(So,{className:"h-4 w-4"})}));La.displayName=Qf.displayName;const em=l.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>u.jsxs(Uf,{ref:o,className:O("relative z-50 max-h-96 min-w-[8rem] overflow-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",n==="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:n,...r,children:[u.jsx(Wa,{}),u.jsx(qN,{className:O("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),u.jsx(La,{})]}));em.displayName=Uf.displayName;const tm=l.forwardRef(({className:e,...t},n)=>u.jsx(Kf,{ref:n,className:O("px-2 py-1.5 text-sm font-semibold",e),...t}));tm.displayName=Kf.displayName;const nm=l.forwardRef(({className:e,children:t,...n},r)=>u.jsxs(qf,{ref:r,className:O("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),...n,children:[u.jsx("span",{className:"absolute right-2 flex h-3.5 w-3.5 items-center justify-center",children:u.jsx(ZN,{children:u.jsx(Mo,{className:"h-4 w-4"})})}),u.jsx(QN,{children:t})]}));nm.displayName=qf.displayName;const rm=l.forwardRef(({className:e,...t},n)=>u.jsx(Zf,{ref:n,className:O("-mx-1 my-1 h-px bg-muted",e),...t}));rm.displayName=Zf.displayName;const nM=({className:e,repeat:t=1,...n})=>u.jsx(u.Fragment,{children:Array.from({length:t??1}).map((r,o)=>u.jsx("div",{className:O("animate-pulse rounded-md bg-gray-700/10",e),...n},o))});var Ba="Switch",[rM,IS]=Te(Ba),[oM,aM]=rM(Ba),om=l.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:o,defaultChecked:a,required:s,disabled:i,value:c="on",onCheckedChange:d,form:f,...m}=e,[p,h]=l.useState(null),v=ne(t,C=>h(C)),g=l.useRef(!1),y=p?f||!!p.closest("form"):!0,[w=!1,b]=Ie({prop:o,defaultProp:a,onChange:d});return u.jsxs(oM,{scope:n,checked:w,disabled:i,children:[u.jsx(F.button,{type:"button",role:"switch","aria-checked":w,"aria-required":s,"data-state":im(w),"data-disabled":i?"":void 0,disabled:i,value:c,...m,ref:v,onClick:A(e.onClick,C=>{b(M=>!M),y&&(g.current=C.isPropagationStopped(),g.current||C.stopPropagation())})}),y&&u.jsx(sM,{control:p,bubbles:!g.current,name:r,value:c,checked:w,required:s,disabled:i,form:f,style:{transform:"translateX(-100%)"}})]})});om.displayName=Ba;var am="SwitchThumb",sm=l.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,o=aM(am,n);return u.jsx(F.span,{"data-state":im(o.checked),"data-disabled":o.disabled?"":void 0,...r,ref:t})});sm.displayName=am;var sM=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,a=l.useRef(null),s=$n(n),i=Sr(t);return l.useEffect(()=>{const c=a.current,d=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(d,"checked").set;if(s!==n&&m){const p=new Event("click",{bubbles:r});m.call(c,n),c.dispatchEvent(p)}},[s,n,r]),u.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...o,tabIndex:-1,ref:a,style:{...e.style,...i,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function im(e){return e?"checked":"unchecked"}var cm=om,iM=sm;const lm=l.forwardRef(({className:e,...t},n)=>u.jsx(cm,{className:O("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:n,children:u.jsx(iM,{className:O("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")})}));lm.displayName=cm.displayName;const um=l.forwardRef(({className:e,...t},n)=>u.jsx("div",{className:"relative w-full overflow-auto",children:u.jsx("table",{ref:n,className:O("w-full caption-bottom text-sm",e),...t})}));um.displayName="Table";const dm=l.forwardRef(({className:e,...t},n)=>u.jsx("thead",{ref:n,className:O("[&_tr]:border-b",e),...t}));dm.displayName="TableHeader";const fm=l.forwardRef(({className:e,...t},n)=>u.jsx("tbody",{ref:n,className:O("[&_tr:last-child]:border-0",e),...t}));fm.displayName="TableBody";const mm=l.forwardRef(({className:e,...t},n)=>u.jsx("tfoot",{ref:n,className:O("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",e),...t}));mm.displayName="TableFooter";const hm=l.forwardRef(({className:e,...t},n)=>u.jsx("tr",{ref:n,className:O("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",e),...t}));hm.displayName="TableRow";const pm=l.forwardRef(({className:e,...t},n)=>u.jsx("th",{ref:n,className:O("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}));pm.displayName="TableHead";const gm=l.forwardRef(({className:e,...t},n)=>u.jsx("td",{ref:n,className:O("p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));gm.displayName="TableCell";const vm=l.forwardRef(({className:e,...t},n)=>u.jsx("caption",{ref:n,className:O("mt-4 text-sm text-muted-foreground",e),...t}));vm.displayName="TableCaption";var Va="Tabs",[cM,jS]=Te(Va,[Rt]),ym=Rt(),[lM,Ya]=cM(Va),bm=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,onValueChange:o,defaultValue:a,orientation:s="horizontal",dir:i,activationMode:c="automatic",...d}=e,f=Yt(i),[m,p]=Ie({prop:r,onChange:o,defaultProp:a});return u.jsx(lM,{scope:n,baseId:je(),value:m,onValueChange:p,orientation:s,dir:f,activationMode:c,children:u.jsx(F.div,{dir:f,"data-orientation":s,...d,ref:t})})});bm.displayName=Va;var wm="TabsList",xm=l.forwardRef((e,t)=>{const{__scopeTabs:n,loop:r=!0,...o}=e,a=Ya(wm,n),s=ym(n);return u.jsx(Ir,{asChild:!0,...s,orientation:a.orientation,dir:a.dir,loop:r,children:u.jsx(F.div,{role:"tablist","aria-orientation":a.orientation,...o,ref:t})})});xm.displayName=wm;var Cm="TabsTrigger",Nm=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,disabled:o=!1,...a}=e,s=Ya(Cm,n),i=ym(n),c=Em(s.baseId,r),d=Pm(s.baseId,r),f=r===s.value;return u.jsx(jr,{asChild:!0,...i,focusable:!o,active:f,children:u.jsx(F.button,{type:"button",role:"tab","aria-selected":f,"aria-controls":d,"data-state":f?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:c,...a,ref:t,onMouseDown:A(e.onMouseDown,m=>{!o&&m.button===0&&m.ctrlKey===!1?s.onValueChange(r):m.preventDefault()}),onKeyDown:A(e.onKeyDown,m=>{[" ","Enter"].includes(m.key)&&s.onValueChange(r)}),onFocus:A(e.onFocus,()=>{const m=s.activationMode!=="manual";!f&&!o&&m&&s.onValueChange(r)})})})});Nm.displayName=Cm;var Mm="TabsContent",Sm=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:r,forceMount:o,children:a,...s}=e,i=Ya(Mm,n),c=Em(i.baseId,r),d=Pm(i.baseId,r),f=r===i.value,m=l.useRef(f);return l.useEffect(()=>{const p=requestAnimationFrame(()=>m.current=!1);return()=>cancelAnimationFrame(p)},[]),u.jsx(De,{present:o||f,children:({present:p})=>u.jsx(F.div,{"data-state":f?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":c,hidden:!p,id:d,tabIndex:0,...s,ref:t,style:{...e.style,animationDuration:m.current?"0s":void 0},children:p&&a})})});Sm.displayName=Mm;function Em(e,t){return`${e}-trigger-${t}`}function Pm(e,t){return`${e}-content-${t}`}var uM=bm,km=xm,Tm=Nm,Dm=Sm;const dM=uM,Om=l.forwardRef(({className:e,...t},n)=>u.jsx(km,{ref:n,className:O("inline-flex h-9 items-center justify-center rounded-lg bg-muted p-1 text-muted-foreground",e),...t}));Om.displayName=km.displayName;const Am=l.forwardRef(({className:e,...t},n)=>u.jsx(Tm,{ref:n,className:O("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}));Am.displayName=Tm.displayName;const _m=l.forwardRef(({className:e,...t},n)=>u.jsx(Dm,{ref:n,className:O("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));_m.displayName=Dm.displayName;const Rm=l.forwardRef(({className:e,...t},n)=>u.jsx("textarea",{className:O("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm 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:n,...t}));Rm.displayName="Textarea";var fM=e=>{switch(e){case"success":return pM;case"info":return vM;case"warning":return gM;case"error":return yM;default:return null}},mM=Array(12).fill(0),hM=({visible:e,className:t})=>x.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},x.createElement("div",{className:"sonner-spinner"},mM.map((n,r)=>x.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),pM=x.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},x.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"})),gM=x.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},x.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"})),vM=x.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},x.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"})),yM=x.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},x.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"})),bM=x.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"},x.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),x.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),wM=()=>{let[e,t]=x.useState(document.hidden);return x.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},Ga=1,xM=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,o=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:Ga++,a=this.toasts.find(i=>i.id===o),s=e.dismissible===void 0?!0:e.dismissible;return a?this.toasts=this.toasts.map(i=>i.id===o?(this.publish({...i,...e,id:o,title:n}),{...i,...e,id:o,dismissible:s,title:n}):i):this.addToast({title:n,...r,dismissible:s,id:o}),o},this.dismiss=e=>(e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let r=e instanceof Promise?e:e(),o=n!==void 0,a,s=r.then(async c=>{if(a=["resolve",c],x.isValidElement(c))o=!1,this.create({id:n,type:"default",message:c});else if(NM(c)&&!c.ok){o=!1;let d=typeof t.error=="function"?await t.error(`HTTP error! status: ${c.status}`):t.error,f=typeof t.description=="function"?await t.description(`HTTP error! status: ${c.status}`):t.description;this.create({id:n,type:"error",message:d,description:f})}else if(t.success!==void 0){o=!1;let d=typeof t.success=="function"?await t.success(c):t.success,f=typeof t.description=="function"?await t.description(c):t.description;this.create({id:n,type:"success",message:d,description:f})}}).catch(async c=>{if(a=["reject",c],t.error!==void 0){o=!1;let d=typeof t.error=="function"?await t.error(c):t.error,f=typeof t.description=="function"?await t.description(c):t.description;this.create({id:n,type:"error",message:d,description:f})}}).finally(()=>{var c;o&&(this.dismiss(n),n=void 0),(c=t.finally)==null||c.call(t)}),i=()=>new Promise((c,d)=>s.then(()=>a[0]==="reject"?d(a[1]):c(a[1])).catch(d));return typeof n!="string"&&typeof n!="number"?{unwrap:i}:Object.assign(n,{unwrap:i})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||Ga++;return this.create({jsx:e(n),id:n,...t}),n},this.subscribers=[],this.toasts=[]}},He=new xM,CM=(e,t)=>{let n=(t==null?void 0:t.id)||Ga++;return He.addToast({title:e,...t,id:n}),n},NM=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",MM=CM,SM=()=>He.toasts,EM=Object.assign(MM,{success:He.success,info:He.info,warning:He.warning,error:He.error,custom:He.custom,message:He.message,promise:He.promise,dismiss:He.dismiss,loading:He.loading},{getHistory:SM});function PM(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}PM(`:where(html[dir="ltr"]),:where([data-sonner-toaster][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%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][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%)}:where([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:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:max(var(--offset),env(safe-area-inset-right))}:where([data-sonner-toaster][data-x-position="left"]){left:max(var(--offset),env(safe-area-inset-left))}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:max(var(--offset),env(safe-area-inset-top))}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:max(var(--offset),env(safe-area-inset-bottom))}:where([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);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([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 #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([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)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([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;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([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);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-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:0;right:0;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([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}:where([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}:where([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, 0px));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:swipe-out .2s ease-out forwards}@keyframes swipe-out{0%{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount)));opacity:1}to{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount) + var(--lift) * -100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;--mobile-offset: 16px;right:var(--mobile-offset);left:var(--mobile-offset);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset)}[data-sonner-toaster][data-y-position=bottom]{bottom:20px}[data-sonner-toaster][data-y-position=top]{top:20px}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset);right:var(--mobile-offset);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--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-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-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--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, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--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-rich-colors=true][data-sonner-toast][data-type=success],[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],[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],[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],[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:nth-child(1){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)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{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%)}
197
- `);function Kr(e){return e.label!==void 0}var kM=3,TM="32px",Im=4e3,DM=356,OM=14,AM=20,_M=200;function RM(...e){return e.filter(Boolean).join(" ")}var IM=e=>{var t,n,r,o,a,s,i,c,d,f,m;let{invert:p,toast:h,unstyled:v,interacting:g,setHeights:y,visibleToasts:w,heights:b,index:C,toasts:M,expanded:S,removeToast:k,defaultRichColors:P,closeButton:D,style:R,cancelButtonStyle:$,actionButtonStyle:V,className:_="",descriptionClassName:z="",duration:G,position:ee,gap:W,loadingIcon:Y,expandByDefault:L,classNames:T,icons:H,closeButtonAriaLabel:q="Close toast",pauseWhenPageIsHidden:X,cn:K}=e,[Z,me]=x.useState(!1),[ge,I]=x.useState(!1),[ie,ce]=x.useState(!1),[oe,se]=x.useState(!1),[le,Me]=x.useState(!1),[Re,$e]=x.useState(0),[ot,Be]=x.useState(0),at=x.useRef(h.duration||G||Im),Xe=x.useRef(null),st=x.useRef(null),N=C===0,B=C+1<=w,j=h.type,ae=h.dismissible!==!1,Pe=h.className||"",ye=h.descriptionClassName||"",Q=x.useMemo(()=>b.findIndex(te=>te.toastId===h.id)||0,[b,h.id]),Ue=x.useMemo(()=>{var te;return(te=h.closeButton)!=null?te:D},[h.closeButton,D]);x.useMemo(()=>h.duration||G||Im,[h.duration,G]);let Qe=x.useRef(0),Ce=x.useRef(0),Ze=x.useRef(0),J=x.useRef(null),[ue,de]=ee.split("-"),Se=x.useMemo(()=>b.reduce((te,he,we)=>we>=Q?te:te+he.height,0),[b,Q]),Ve=wM(),gn=h.invert||p,ke=j==="loading";Ce.current=x.useMemo(()=>Q*W+Se,[Q,Se]),x.useEffect(()=>{me(!0)},[]),x.useEffect(()=>{let te=st.current;if(te){let he=te.getBoundingClientRect().height;return Be(he),y(we=>[{toastId:h.id,height:he,position:h.position},...we]),()=>y(we=>we.filter(We=>We.toastId!==h.id))}},[y,h.id]),x.useLayoutEffect(()=>{if(!Z)return;let te=st.current,he=te.style.height;te.style.height="auto";let we=te.getBoundingClientRect().height;te.style.height=he,Be(we),y(We=>We.find(Ye=>Ye.toastId===h.id)?We.map(Ye=>Ye.toastId===h.id?{...Ye,height:we}:Ye):[{toastId:h.id,height:we,position:h.position},...We])},[Z,h.title,h.description,y,h.id]);let Ae=x.useCallback(()=>{I(!0),$e(Ce.current),y(te=>te.filter(he=>he.toastId!==h.id)),setTimeout(()=>{k(h)},_M)},[h,k,y,Ce]);x.useEffect(()=>{if(h.promise&&j==="loading"||h.duration===1/0||h.type==="loading")return;let te;return S||g||X&&Ve?(()=>{if(Ze.current<Qe.current){let he=new Date().getTime()-Qe.current;at.current=at.current-he}Ze.current=new Date().getTime()})():at.current!==1/0&&(Qe.current=new Date().getTime(),te=setTimeout(()=>{var he;(he=h.onAutoClose)==null||he.call(h,h),Ae()},at.current)),()=>clearTimeout(te)},[S,g,h,j,X,Ve,Ae]),x.useEffect(()=>{h.delete&&Ae()},[Ae,h.delete]);function fe(){var te,he,we;return H!=null&&H.loading?x.createElement("div",{className:K(T==null?void 0:T.loader,(te=h==null?void 0:h.classNames)==null?void 0:te.loader,"sonner-loader"),"data-visible":j==="loading"},H.loading):Y?x.createElement("div",{className:K(T==null?void 0:T.loader,(he=h==null?void 0:h.classNames)==null?void 0:he.loader,"sonner-loader"),"data-visible":j==="loading"},Y):x.createElement(hM,{className:K(T==null?void 0:T.loader,(we=h==null?void 0:h.classNames)==null?void 0:we.loader),visible:j==="loading"})}return x.createElement("li",{tabIndex:0,ref:st,className:K(_,Pe,T==null?void 0:T.toast,(t=h==null?void 0:h.classNames)==null?void 0:t.toast,T==null?void 0:T.default,T==null?void 0:T[j],(n=h==null?void 0:h.classNames)==null?void 0:n[j]),"data-sonner-toast":"","data-rich-colors":(r=h.richColors)!=null?r:P,"data-styled":!(h.jsx||h.unstyled||v),"data-mounted":Z,"data-promise":!!h.promise,"data-swiped":le,"data-removed":ge,"data-visible":B,"data-y-position":ue,"data-x-position":de,"data-index":C,"data-front":N,"data-swiping":ie,"data-dismissible":ae,"data-type":j,"data-invert":gn,"data-swipe-out":oe,"data-expanded":!!(S||L&&Z),style:{"--index":C,"--toasts-before":C,"--z-index":M.length-C,"--offset":`${ge?Re:Ce.current}px`,"--initial-height":L?"auto":`${ot}px`,...R,...h.style},onPointerDown:te=>{ke||!ae||(Xe.current=new Date,$e(Ce.current),te.target.setPointerCapture(te.pointerId),te.target.tagName!=="BUTTON"&&(ce(!0),J.current={x:te.clientX,y:te.clientY}))},onPointerUp:()=>{var te,he,we,We;if(oe||!ae)return;J.current=null;let Ye=Number(((te=st.current)==null?void 0:te.style.getPropertyValue("--swipe-amount").replace("px",""))||0),Jr=new Date().getTime()-((he=Xe.current)==null?void 0:he.getTime()),wS=Math.abs(Ye)/Jr;if(Math.abs(Ye)>=AM||wS>.11){$e(Ce.current),(we=h.onDismiss)==null||we.call(h,h),Ae(),se(!0),Me(!1);return}(We=st.current)==null||We.style.setProperty("--swipe-amount","0px"),ce(!1)},onPointerMove:te=>{var he,we;if(!J.current||!ae)return;let We=te.clientY-J.current.y,Ye=((he=window.getSelection())==null?void 0:he.toString().length)>0,Jr=ue==="top"?Math.min(0,We):Math.max(0,We);Math.abs(Jr)>0&&Me(!0),!Ye&&((we=st.current)==null||we.style.setProperty("--swipe-amount",`${Jr}px`))}},Ue&&!h.jsx?x.createElement("button",{"aria-label":q,"data-disabled":ke,"data-close-button":!0,onClick:ke||!ae?()=>{}:()=>{var te;Ae(),(te=h.onDismiss)==null||te.call(h,h)},className:K(T==null?void 0:T.closeButton,(o=h==null?void 0:h.classNames)==null?void 0:o.closeButton)},(a=H==null?void 0:H.close)!=null?a:bM):null,h.jsx||x.isValidElement(h.title)?h.jsx?h.jsx:typeof h.title=="function"?h.title():h.title:x.createElement(x.Fragment,null,j||h.icon||h.promise?x.createElement("div",{"data-icon":"",className:K(T==null?void 0:T.icon,(s=h==null?void 0:h.classNames)==null?void 0:s.icon)},h.promise||h.type==="loading"&&!h.icon?h.icon||fe():null,h.type!=="loading"?h.icon||(H==null?void 0:H[j])||fM(j):null):null,x.createElement("div",{"data-content":"",className:K(T==null?void 0:T.content,(i=h==null?void 0:h.classNames)==null?void 0:i.content)},x.createElement("div",{"data-title":"",className:K(T==null?void 0:T.title,(c=h==null?void 0:h.classNames)==null?void 0:c.title)},typeof h.title=="function"?h.title():h.title),h.description?x.createElement("div",{"data-description":"",className:K(z,ye,T==null?void 0:T.description,(d=h==null?void 0:h.classNames)==null?void 0:d.description)},typeof h.description=="function"?h.description():h.description):null),x.isValidElement(h.cancel)?h.cancel:h.cancel&&Kr(h.cancel)?x.createElement("button",{"data-button":!0,"data-cancel":!0,style:h.cancelButtonStyle||$,onClick:te=>{var he,we;Kr(h.cancel)&&ae&&((we=(he=h.cancel).onClick)==null||we.call(he,te),Ae())},className:K(T==null?void 0:T.cancelButton,(f=h==null?void 0:h.classNames)==null?void 0:f.cancelButton)},h.cancel.label):null,x.isValidElement(h.action)?h.action:h.action&&Kr(h.action)?x.createElement("button",{"data-button":!0,"data-action":!0,style:h.actionButtonStyle||V,onClick:te=>{var he,we;Kr(h.action)&&((we=(he=h.action).onClick)==null||we.call(he,te),!te.defaultPrevented&&Ae())},className:K(T==null?void 0:T.actionButton,(m=h==null?void 0:h.classNames)==null?void 0:m.actionButton)},h.action.label):null))};function jm(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}var jM=x.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:a,closeButton:s,className:i,offset:c,theme:d="light",richColors:f,duration:m,style:p,visibleToasts:h=kM,toastOptions:v,dir:g=jm(),gap:y=OM,loadingIcon:w,icons:b,containerAriaLabel:C="Notifications",pauseWhenPageIsHidden:M,cn:S=RM}=e,[k,P]=x.useState([]),D=x.useMemo(()=>Array.from(new Set([r].concat(k.filter(X=>X.position).map(X=>X.position)))),[k,r]),[R,$]=x.useState([]),[V,_]=x.useState(!1),[z,G]=x.useState(!1),[ee,W]=x.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),Y=x.useRef(null),L=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),T=x.useRef(null),H=x.useRef(!1),q=x.useCallback(X=>{P(K=>{var Z;return(Z=K.find(me=>me.id===X.id))!=null&&Z.delete||He.dismiss(X.id),K.filter(({id:me})=>me!==X.id)})},[]);return x.useEffect(()=>He.subscribe(X=>{if(X.dismiss){P(K=>K.map(Z=>Z.id===X.id?{...Z,delete:!0}:Z));return}setTimeout(()=>{Zn.flushSync(()=>{P(K=>{let Z=K.findIndex(me=>me.id===X.id);return Z!==-1?[...K.slice(0,Z),{...K[Z],...X},...K.slice(Z+1)]:[X,...K]})})})}),[]),x.useEffect(()=>{if(d!=="system"){W(d);return}if(d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?W("dark"):W("light")),typeof window>"u")return;let X=window.matchMedia("(prefers-color-scheme: dark)");try{X.addEventListener("change",({matches:K})=>{W(K?"dark":"light")})}catch{X.addListener(({matches:Z})=>{try{W(Z?"dark":"light")}catch(me){console.error(me)}})}},[d]),x.useEffect(()=>{k.length<=1&&_(!1)},[k]),x.useEffect(()=>{let X=K=>{var Z,me;o.every(ge=>K[ge]||K.code===ge)&&(_(!0),(Z=Y.current)==null||Z.focus()),K.code==="Escape"&&(document.activeElement===Y.current||(me=Y.current)!=null&&me.contains(document.activeElement))&&_(!1)};return document.addEventListener("keydown",X),()=>document.removeEventListener("keydown",X)},[o]),x.useEffect(()=>{if(Y.current)return()=>{T.current&&(T.current.focus({preventScroll:!0}),T.current=null,H.current=!1)}},[Y.current]),x.createElement("section",{"aria-label":`${C} ${L}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false"},D.map((X,K)=>{var Z;let[me,ge]=X.split("-");return k.length?x.createElement("ol",{key:X,dir:g==="auto"?jm():g,tabIndex:-1,ref:Y,className:i,"data-sonner-toaster":!0,"data-theme":ee,"data-y-position":me,"data-lifted":V&&k.length>1&&!a,"data-x-position":ge,style:{"--front-toast-height":`${((Z=R[0])==null?void 0:Z.height)||0}px`,"--offset":typeof c=="number"?`${c}px`:c||TM,"--width":`${DM}px`,"--gap":`${y}px`,...p},onBlur:I=>{H.current&&!I.currentTarget.contains(I.relatedTarget)&&(H.current=!1,T.current&&(T.current.focus({preventScroll:!0}),T.current=null))},onFocus:I=>{I.target instanceof HTMLElement&&I.target.dataset.dismissible==="false"||H.current||(H.current=!0,T.current=I.relatedTarget)},onMouseEnter:()=>_(!0),onMouseMove:()=>_(!0),onMouseLeave:()=>{z||_(!1)},onPointerDown:I=>{I.target instanceof HTMLElement&&I.target.dataset.dismissible==="false"||G(!0)},onPointerUp:()=>G(!1)},k.filter(I=>!I.position&&K===0||I.position===X).map((I,ie)=>{var ce,oe;return x.createElement(IM,{key:I.id,icons:b,index:ie,toast:I,defaultRichColors:f,duration:(ce=v==null?void 0:v.duration)!=null?ce:m,className:v==null?void 0:v.className,descriptionClassName:v==null?void 0:v.descriptionClassName,invert:n,visibleToasts:h,closeButton:(oe=v==null?void 0:v.closeButton)!=null?oe:s,interacting:z,position:X,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,removeToast:q,toasts:k.filter(se=>se.position==I.position),heights:R.filter(se=>se.position==I.position),setHeights:$,expandByDefault:a,gap:y,loadingIcon:w,expanded:V,pauseWhenPageIsHidden:M,cn:S})})):null}))});const FM=({...e})=>u.jsx(jM,{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 $M="Toggle",za=l.forwardRef((e,t)=>{const{pressed:n,defaultPressed:r=!1,onPressedChange:o,...a}=e,[s=!1,i]=Ie({prop:n,onChange:o,defaultProp:r});return u.jsx(F.button,{type:"button","aria-pressed":s,"data-state":s?"on":"off","data-disabled":e.disabled?"":void 0,...a,ref:t,onClick:A(e.onClick,()=>{e.disabled||i(!s)})})});za.displayName=$M;var Fm=za;const Ha=Kt("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"}}),$m=l.forwardRef(({className:e,variant:t,size:n,...r},o)=>u.jsx(Fm,{ref:o,className:O(Ha({variant:t,size:n,className:e})),...r}));$m.displayName=Fm.displayName;var hn="ToggleGroup",[Wm,FS]=Te(hn,[Rt]),Lm=Rt(),Ua=x.forwardRef((e,t)=>{const{type:n,...r}=e;if(n==="single"){const o=r;return u.jsx(WM,{...o,ref:t})}if(n==="multiple"){const o=r;return u.jsx(LM,{...o,ref:t})}throw new Error(`Missing prop \`type\` expected on \`${hn}\``)});Ua.displayName=hn;var[Bm,Vm]=Wm(hn),WM=x.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...a}=e,[s,i]=Ie({prop:n,defaultProp:r,onChange:o});return u.jsx(Bm,{scope:e.__scopeToggleGroup,type:"single",value:s?[s]:[],onItemActivate:i,onItemDeactivate:x.useCallback(()=>i(""),[i]),children:u.jsx(Ym,{...a,ref:t})})}),LM=x.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...a}=e,[s=[],i]=Ie({prop:n,defaultProp:r,onChange:o}),c=x.useCallback(f=>i((m=[])=>[...m,f]),[i]),d=x.useCallback(f=>i((m=[])=>m.filter(p=>p!==f)),[i]);return u.jsx(Bm,{scope:e.__scopeToggleGroup,type:"multiple",value:s,onItemActivate:c,onItemDeactivate:d,children:u.jsx(Ym,{...a,ref:t})})});Ua.displayName=hn;var[BM,VM]=Wm(hn),Ym=x.forwardRef((e,t)=>{const{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:o=!0,orientation:a,dir:s,loop:i=!0,...c}=e,d=Lm(n),f=Yt(s),m={role:"group",dir:f,...c};return u.jsx(BM,{scope:n,rovingFocus:o,disabled:r,children:o?u.jsx(Ir,{asChild:!0,...d,orientation:a,dir:f,loop:i,children:u.jsx(F.div,{...m,ref:t})}):u.jsx(F.div,{...m,ref:t})})}),qr="ToggleGroupItem",Gm=x.forwardRef((e,t)=>{const n=Vm(qr,e.__scopeToggleGroup),r=VM(qr,e.__scopeToggleGroup),o=Lm(e.__scopeToggleGroup),a=n.value.includes(e.value),s=r.disabled||e.disabled,i={...e,pressed:a,disabled:s},c=x.useRef(null);return r.rovingFocus?u.jsx(jr,{asChild:!0,...o,focusable:!s,active:a,ref:c,children:u.jsx(zm,{...i,ref:t})}):u.jsx(zm,{...i,ref:t})});Gm.displayName=qr;var zm=x.forwardRef((e,t)=>{const{__scopeToggleGroup:n,value:r,...o}=e,a=Vm(qr,n),s={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},i=a.type==="single"?s:void 0;return u.jsx(za,{...i,...o,ref:t,onPressedChange:c=>{c?a.onItemActivate(r):a.onItemDeactivate(r)}})}),Hm=Ua,Um=Gm;const Km=l.createContext({size:"default",variant:"default"}),qm=l.forwardRef(({className:e,variant:t,size:n,children:r,...o},a)=>u.jsx(Hm,{ref:a,className:O("flex items-center justify-center gap-1",e),...o,children:u.jsx(Km.Provider,{value:{variant:t,size:n},children:r})}));qm.displayName=Hm.displayName;const Xm=l.forwardRef(({className:e,children:t,variant:n,size:r,...o},a)=>{const s=l.useContext(Km);return u.jsx(Um,{ref:a,className:O(Ha({variant:s.variant||n,size:s.size||r}),e),...o,children:t})});Xm.displayName=Um.displayName;var[Xr,$S]=Te("Tooltip",[Dt]),Qr=Dt(),Qm="TooltipProvider",YM=700,Ka="tooltip.open",[GM,qa]=Xr(Qm),Zm=e=>{const{__scopeTooltip:t,delayDuration:n=YM,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,[s,i]=l.useState(!0),c=l.useRef(!1),d=l.useRef(0);return l.useEffect(()=>{const f=d.current;return()=>window.clearTimeout(f)},[]),u.jsx(GM,{scope:t,isOpenDelayed:s,delayDuration:n,onOpen:l.useCallback(()=>{window.clearTimeout(d.current),i(!1)},[]),onClose:l.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>i(!0),r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:l.useCallback(f=>{c.current=f},[]),disableHoverableContent:o,children:a})};Zm.displayName=Qm;var Zr="Tooltip",[zM,Qn]=Xr(Zr),Jm=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:a,disableHoverableContent:s,delayDuration:i}=e,c=qa(Zr,e.__scopeTooltip),d=Qr(t),[f,m]=l.useState(null),p=je(),h=l.useRef(0),v=s??c.disableHoverableContent,g=i??c.delayDuration,y=l.useRef(!1),[w=!1,b]=Ie({prop:r,defaultProp:o,onChange:P=>{P?(c.onOpen(),document.dispatchEvent(new CustomEvent(Ka))):c.onClose(),a==null||a(P)}}),C=l.useMemo(()=>w?y.current?"delayed-open":"instant-open":"closed",[w]),M=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,y.current=!1,b(!0)},[b]),S=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,b(!1)},[b]),k=l.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{y.current=!0,b(!0),h.current=0},g)},[g,b]);return l.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),u.jsx(Tn,{...d,children:u.jsx(zM,{scope:t,contentId:p,open:w,stateAttribute:C,trigger:f,onTriggerChange:m,onTriggerEnter:l.useCallback(()=>{c.isOpenDelayed?k():M()},[c.isOpenDelayed,k,M]),onTriggerLeave:l.useCallback(()=>{v?S():(window.clearTimeout(h.current),h.current=0)},[S,v]),onOpen:M,onClose:S,disableHoverableContent:v,children:n})})};Jm.displayName=Zr;var Xa="TooltipTrigger",eh=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=Qn(Xa,n),a=qa(Xa,n),s=Qr(n),i=l.useRef(null),c=ne(t,i,o.onTriggerChange),d=l.useRef(!1),f=l.useRef(!1),m=l.useCallback(()=>d.current=!1,[]);return l.useEffect(()=>()=>document.removeEventListener("pointerup",m),[m]),u.jsx(Dn,{asChild:!0,...s,children:u.jsx(F.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:c,onPointerMove:A(e.onPointerMove,p=>{p.pointerType!=="touch"&&!f.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),f.current=!0)}),onPointerLeave:A(e.onPointerLeave,()=>{o.onTriggerLeave(),f.current=!1}),onPointerDown:A(e.onPointerDown,()=>{d.current=!0,document.addEventListener("pointerup",m,{once:!0})}),onFocus:A(e.onFocus,()=>{d.current||o.onOpen()}),onBlur:A(e.onBlur,o.onClose),onClick:A(e.onClick,o.onClose)})})});eh.displayName=Xa;var Qa="TooltipPortal",[HM,UM]=Xr(Qa,{forceMount:void 0}),th=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,a=Qn(Qa,t);return u.jsx(HM,{scope:t,forceMount:n,children:u.jsx(De,{present:n||a.open,children:u.jsx(Nn,{asChild:!0,container:o,children:r})})})};th.displayName=Qa;var pn="TooltipContent",nh=l.forwardRef((e,t)=>{const n=UM(pn,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...a}=e,s=Qn(pn,e.__scopeTooltip);return u.jsx(De,{present:r||s.open,children:s.disableHoverableContent?u.jsx(rh,{side:o,...a,ref:t}):u.jsx(KM,{side:o,...a,ref:t})})}),KM=l.forwardRef((e,t)=>{const n=Qn(pn,e.__scopeTooltip),r=qa(pn,e.__scopeTooltip),o=l.useRef(null),a=ne(t,o),[s,i]=l.useState(null),{trigger:c,onClose:d}=n,f=o.current,{onPointerInTransitChange:m}=r,p=l.useCallback(()=>{i(null),m(!1)},[m]),h=l.useCallback((v,g)=>{const y=v.currentTarget,w={x:v.clientX,y:v.clientY},b=ZM(w,y.getBoundingClientRect()),C=JM(w,b),M=eS(g.getBoundingClientRect()),S=nS([...C,...M]);i(S),m(!0)},[m]);return l.useEffect(()=>()=>p(),[p]),l.useEffect(()=>{if(c&&f){const v=y=>h(y,f),g=y=>h(y,c);return c.addEventListener("pointerleave",v),f.addEventListener("pointerleave",g),()=>{c.removeEventListener("pointerleave",v),f.removeEventListener("pointerleave",g)}}},[c,f,h,p]),l.useEffect(()=>{if(s){const v=g=>{const y=g.target,w={x:g.clientX,y:g.clientY},b=(c==null?void 0:c.contains(y))||(f==null?void 0:f.contains(y)),C=!tS(w,s);b?p():C&&(p(),d())};return document.addEventListener("pointermove",v),()=>document.removeEventListener("pointermove",v)}},[c,f,s,d,p]),u.jsx(rh,{...e,ref:a})}),[qM,XM]=Xr(Zr,{isInside:!1}),rh=l.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:s,...i}=e,c=Qn(pn,n),d=Qr(n),{onClose:f}=c;return l.useEffect(()=>(document.addEventListener(Ka,f),()=>document.removeEventListener(Ka,f)),[f]),l.useEffect(()=>{if(c.trigger){const m=p=>{const h=p.target;h!=null&&h.contains(c.trigger)&&f()};return window.addEventListener("scroll",m,{capture:!0}),()=>window.removeEventListener("scroll",m,{capture:!0})}},[c.trigger,f]),u.jsx($t,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:m=>m.preventDefault(),onDismiss:f,children:u.jsxs(Er,{"data-state":c.stateAttribute,...d,...i,ref:t,style:{...i.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:[u.jsx(oo,{children:r}),u.jsx(qM,{scope:n,isInside:!0,children:u.jsx(md,{id:c.contentId,role:"tooltip",children:o||r})})]})})});nh.displayName=pn;var oh="TooltipArrow",QM=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=Qr(n);return XM(oh,n).isInside?null:u.jsx(Pr,{...o,...r,ref:t})});QM.displayName=oh;function ZM(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,o,a)){case a:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function JM(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function eS(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function tS(e,t){const{x:n,y:r}=e;let o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a].x,c=t[a].y,d=t[s].x,f=t[s].y;c>r!=f>r&&n<(d-i)*(r-c)/(f-c)+i&&(o=!o)}return o}function nS(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),rS(t)}function rS(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const a=t[t.length-1],s=t[t.length-2];if((a.x-s.x)*(o.y-s.y)>=(a.y-s.y)*(o.x-s.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const a=n[n.length-1],s=n[n.length-2];if((a.x-s.x)*(o.y-s.y)>=(a.y-s.y)*(o.x-s.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var oS=Zm,aS=Jm,sS=eh,iS=th,ah=nh;const cS=oS,lS=aS,uS=sS,sh=l.forwardRef(({className:e,sideOffset:t=4,...n},r)=>u.jsx(iS,{children:u.jsx(ah,{ref:r,sideOffset:t,className:O("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",e),...n})}));sh.displayName=ah.displayName;function dS(e){const{triggerElement:t,steps:n}=e,[r,o]=x.useState(!1),[a,s]=x.useState(0),i=()=>{s(d=>d<n.length-1?d+1:d)},c=()=>{s(d=>d>0?d-1:d)};return u.jsxs(qo,{open:r,onOpenChange:o,children:[u.jsx(_l,{asChild:!0,children:t}),u.jsxs(Dr,{className:"sm:max-w-[425px]",children:[u.jsxs(Or,{className:O(n[a].title===""&&"sr-only"),children:[u.jsx(Ar,{children:n[a].title}),u.jsx(_r,{className:"sr-only",children:n[a].title})]}),u.jsx("div",{children:n[a].description}),u.jsxs("div",{className:"flex items-center justify-between mt-4",children:[u.jsx(lt,{variant:"ghost",size:"icon",onClick:c,disabled:a===0,children:u.jsx(Ai,{className:"h-4 w-4"})}),u.jsx("div",{className:"flex justify-center gap-1",children:n.map((d,f)=>u.jsx("div",{className:O("h-3 w-3 rounded-full",f===a?"bg-primary":"bg-gray-200")},f))}),u.jsx(lt,{variant:"ghost",size:"icon",onClick:i,disabled:a===n.length-1,children:u.jsx(Eo,{className:"h-4 w-4"})})]})]})]})}const fS=e=>{const{currentMonth:t,currentYear:n,onChangeMonthYear:r,locale:o=kr}=e,a=s=>{let i=t,c=n;s==="prev"?i===0?(i=11,c--):i--:i===11?(i=0,c++):i++,r(i,c)};return u.jsxs("div",{className:"flex items-center justify-between",children:[u.jsx(lt,{variant:"ghost",size:"icon",onClick:()=>a("prev"),"aria-label":"Previous month",children:u.jsx($g,{className:"!h-8 !w-8"})}),u.jsxs("div",{className:"text-center",children:[u.jsx("h2",{className:"text-2xl font-bold capitalize",children:o.localize.month(t,{width:"wide"})}),u.jsx("p",{className:"text-sm text-muted-foreground",children:n})]}),u.jsx(lt,{variant:"ghost",size:"icon",onClick:()=>a("next"),"aria-label":"Next month",children:u.jsx(Wg,{className:"!h-8 !w-8"})})]})};function mS({currentPage:e,totalPages:t,onPageChange:n}){const r=Array.from({length:t},(o,a)=>a+1);return u.jsx(Ma,{children:u.jsxs(Sa,{children:[u.jsx(Un,{children:u.jsx(Ea,{onClick:()=>n(Math.max(1,e-1)),disabled:e===1})}),r.map(o=>u.jsx(Un,{children:u.jsx(Kn,{onClick:()=>n(o),isActive:e===o,children:o})},o)),u.jsx(Un,{children:u.jsx(Pa,{onClick:()=>n(Math.min(t,e+1)),disabled:e===t})})]})})}function hS(e,t=250){const[n,r]=x.useState(e);return x.useEffect(()=>{const o=setTimeout(()=>{r(e)},t);return()=>{clearTimeout(o)}},[e,t]),n}const ih=l.createContext(void 0),ch={sm:"sm:max-w-[425px]",md:"sm:max-w-[550px]",lg:"sm:max-w-[700px]",xl:"sm:max-w-[900px]"},lh={info:{icon:Ug,className:"text-blue-500"},success:{icon:Vg,className:"text-green-500"},error:{icon:Yg,className:"text-red-500"},warning:{icon:Bg,className:"text-yellow-500"},confirm:{icon:_i,className:"text-blue-500"},custom:{icon:_i,className:"text-gray-500"}};function pS({children:e}){var h,v,g;const[t,n]=l.useState({isOpen:!1,options:null}),r=l.useCallback(y=>{n({isOpen:!0,options:y})},[]),o=l.useCallback(()=>{n(y=>({...y,isOpen:!1}))},[]),a=l.useCallback(y=>{r({...y,type:"info"})},[r]),s=l.useCallback(y=>{r({...y,type:"success"})},[r]),i=l.useCallback(y=>{r({...y,type:"error"})},[r]),c=l.useCallback(y=>{r({...y,type:"warning"})},[r]),d=l.useCallback(y=>{r({...y,type:"custom"})},[r]),f=l.useCallback(y=>{r({...y,type:"confirm"})},[r]),m=(y,w)=>{let b=lh[y].icon;return w&&(b=w),u.jsx(b,{className:O("h-24 w-24",lh[y].className)})},p=l.useMemo(()=>({open:r,close:o,info:a,success:s,error:i,warning:c,custom:d,confirm:f}),[r,o,a,s,i,c,d,f]);return u.jsxs(ih.Provider,{value:p,children:[e,u.jsx(qo,{open:t.isOpen,onOpenChange:y=>!y&&o(),modal:!0,children:u.jsxs(Dr,{className:O((h=t.options)!=null&&h.size?ch[t.options.size]:ch.sm,(v=t.options)==null?void 0:v.className),children:[t.options&&u.jsxs(Or,{children:[u.jsx("div",{className:"mx-auto mb-6",children:m(t.options.type,t.options.icon)}),t.options.title&&u.jsx(Ar,{className:"text-center",children:t.options.title}),u.jsx(_r,{className:"text-center",children:t.options.message})]}),((g=t.options)==null?void 0:g.type)==="confirm"&&u.jsxs("div",{className:"flex justify-center gap-4 mt-4",children:[u.jsx(lt,{onClick:()=>{var y,w;(w=(y=t.options)==null?void 0:y.onConfirm)==null||w.call(y),o()},children:t.options.confirmLabel||"Confirm"}),t.options.displayCancel&&u.jsx(lt,{variant:"outline",onClick:o,children:t.options.cancelLabel||"Cancel"})]})]})})]})}function gS(){const e=l.useContext(ih);if(e===void 0)throw new Error("useDialog must be used within a DialogProvider");return e}function vS(e){const[t,n]=x.useState(!1);return x.useEffect(()=>{const r=window.matchMedia(e);r.matches!==t&&n(r.matches);const o=()=>n(r.matches);return window.addEventListener("resize",o),()=>window.removeEventListener("resize",o)},[t,e]),t}const Za=768;function yS(){const[e,t]=l.useState(void 0);return l.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Za-1}px)`),r=()=>{t(window.innerWidth<Za)};return n.addEventListener("change",r),t(window.innerWidth<Za),()=>n.removeEventListener("change",r)},[]),!!e}const bS=()=>{const[e,t]=x.useState(null),[n,r]=x.useState(!1);return x.useEffect(()=>((()=>{const s=window.matchMedia("(display-mode: standalone)").matches||window.navigator.standalone;r(s)})(),window.addEventListener("beforeinstallprompt",s=>{s.preventDefault(),t(s)}),window.addEventListener("appinstalled",()=>{r(!0)}),()=>{window.removeEventListener("appinstalled",()=>r(!0))}),[]),{isPromptReady:!!e,isInstalled:n,showInstallPrompt:()=>{e&&(e.prompt(),e.userChoice.then(a=>{console.log(`User choice: ${a.outcome}`),t(null)}))}}};E.AdaptiveInput=nr,E.AlertDialog=_g,E.AlertDialogAction=Ti,E.AlertDialogCancel=Di,E.AlertDialogContent=Mi,E.AlertDialogDescription=ki,E.AlertDialogFooter=Ei,E.AlertDialogHeader=Si,E.AlertDialogOverlay=No,E.AlertDialogPortal=Ni,E.AlertDialogTitle=Pi,E.AlertDialogTrigger=Rg,E.Autocomplete=hy,E.Avatar=Oc,E.AvatarFallback=_c,E.AvatarImage=Ac,E.Badge=yy,E.Button=lt,E.Calendar=bl,E.Card=wl,E.CardContent=Ml,E.CardDescription=Nl,E.CardFooter=Sl,E.CardHeader=xl,E.CardTitle=Cl,E.Checkbox=Ol,E.CurrencyInput=Al,E.Dialog=qo,E.DialogClose=Ux,E.DialogContent=Dr,E.DialogDescription=_r,E.DialogFooter=Il,E.DialogHeader=Or,E.DialogOverlay=Xo,E.DialogPortal=Rl,E.DialogProvider=pS,E.DialogTitle=Ar,E.DialogTrigger=_l,E.DropdownMenu=hC,E.DropdownMenuCheckboxItem=Gu,E.DropdownMenuContent=Vu,E.DropdownMenuGroup=gC,E.DropdownMenuItem=Yu,E.DropdownMenuLabel=Hu,E.DropdownMenuPortal=vC,E.DropdownMenuRadioGroup=bC,E.DropdownMenuRadioItem=zu,E.DropdownMenuSeparator=Uu,E.DropdownMenuShortcut=Ku,E.DropdownMenuSub=yC,E.DropdownMenuSubContent=Bu,E.DropdownMenuSubTrigger=Lu,E.DropdownMenuTrigger=pC,E.Form=YC,E.FormControl=ud,E.FormDescription=dd,E.FormField=GC,E.FormItem=cd,E.FormLabel=ld,E.FormMessage=fd,E.HelpCarousel=dS,E.Input=tr,E.Label=da,E.MonthNavigator=fS,E.NavigationMenu=Bd,E.NavigationMenuContent=zd,E.NavigationMenuIndicator=Hd,E.NavigationMenuItem=lN,E.NavigationMenuLink=uN,E.NavigationMenuList=Vd,E.NavigationMenuTrigger=Gd,E.NavigationMenuViewport=Na,E.Pagination=Ma,E.PaginationContent=Sa,E.PaginationControls=mS,E.PaginationEllipsis=Ud,E.PaginationItem=Un,E.PaginationLink=Kn,E.PaginationNext=Pa,E.PaginationPrevious=Ea,E.PasswordInput=yN,E.Popover=wc,E.PopoverAnchor=my,E.PopoverContent=Yo,E.PopoverTrigger=xc,E.Progress=Da,E.RadioGroup=pf,E.RadioGroupItem=gf,E.Select=JN,E.SelectContent=em,E.SelectGroup=eM,E.SelectItem=nm,E.SelectLabel=tm,E.SelectScrollDownButton=La,E.SelectScrollUpButton=Wa,E.SelectSeparator=rm,E.SelectTrigger=Jf,E.SelectValue=tM,E.Skeleton=nM,E.Switch=lm,E.Table=um,E.TableBody=fm,E.TableCaption=vm,E.TableCell=gm,E.TableFooter=mm,E.TableHead=pm,E.TableHeader=dm,E.TableRow=hm,E.Tabs=dM,E.TabsContent=_m,E.TabsList=Om,E.TabsTrigger=Am,E.Textarea=Rm,E.Toaster=FM,E.Toggle=$m,E.ToggleGroup=qm,E.ToggleGroupItem=Xm,E.Tooltip=lS,E.TooltipContent=sh,E.TooltipProvider=cS,E.TooltipTrigger=uS,E.badgeVariants=Rc,E.buttonVariants=Sn,E.cn=O,E.formatCurrency=Gh,E.formatDateAndMonth=Uh,E.formatDateAndWeekday=zh,E.formatDateAndWeekdayAndYear=Hh,E.formatLongDate=Kh,E.formatShortDate=qh,E.formatWeekDayAndShortDate=Qh,E.getMonthYearFromISODate=Xh,E.navigationMenuTriggerStyle=Yd,E.toast=EM,E.toggleVariants=Ha,E.useDebounce=hS,E.useDialog=gS,E.useFormField=Hn,E.useIsMobile=yS,E.useMediaQuery=vS,E.usePWAInstall=bS,Object.defineProperty(E,Symbol.toStringTag,{value:"Module"})});
196
+ Defaulting to \`null\`.`}var Fu=Iu,ky=ju;const Jr=l.forwardRef(({className:e,value:t,...n},o)=>c.jsx(Fu,{ref:o,className:R("relative h-2 w-full overflow-hidden rounded-full bg-primary/20",e),...n,children:c.jsx(ky,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));Jr.displayName=Fu.displayName;function jy(e){const{showStrengthMeter:t=!0,className:n,strengthLabels:o={veryWeak:"Very weak",weak:"Weak",medium:"Medium",strong:"Strong",veryStrong:"Very strong"},showPasswordLabel:r="Show password",hidePasswordLabel:a="Hide password",strengthTitle:s="Password strength",...i}=e,[u,d]=S.useState(""),[f,m]=S.useState(!1),h=y=>{let w=0;return y.length>=8&&(w+=25),y.match(/[a-z]/)&&(w+=25),y.match(/[A-Z]/)&&(w+=25),y.match(/[0-9]/)&&(w+=25),w},p=y=>y===0?o.veryWeak:y<=25?o.weak:y<=50?o.medium:y<=75?o.strong:o.veryStrong,b=h(u),g=p(b),v=y=>{var w;d(y.target.value),(w=e.onChange)==null||w.call(e,y)};return c.jsxs("div",{className:"w-full space-y-4",children:[c.jsxs("div",{className:"relative",children:[c.jsx(Tn,{...i,type:f?"text":"password",value:u,onChange:v,className:`pr-10 ${n||""}`}),c.jsx(Ge,{type:"button",variant:"ghost",size:"icon",className:"absolute right-0 top-0 h-full",onClick:()=>m(!f),"aria-label":f?a:r,children:f?c.jsx(Ag,{className:"h-4 w-4"}):c.jsx(_g,{className:"h-4 w-4"})})]}),t&&c.jsxs("div",{className:"space-y-2",children:[c.jsxs("div",{className:"flex justify-between text-sm",children:[c.jsxs("span",{children:[s,":"]}),c.jsx("span",{children:g})]}),c.jsx(Jr,{value:b,className:"h-2"})]})]})}var Zr="Radio",[Dy,$u]=ve(Zr),[Oy,Ly]=Dy(Zr),Vu=l.forwardRef((e,t)=>{const{__scopeRadio:n,name:o,checked:r=!1,required:a,disabled:s,value:i="on",onCheck:u,form:d,...f}=e,[m,h]=l.useState(null),p=J(t,v=>h(v)),b=l.useRef(!1),g=m?d||!!m.closest("form"):!0;return c.jsxs(Oy,{scope:n,checked:r,disabled:s,children:[c.jsx(L.button,{type:"button",role:"radio","aria-checked":r,"data-state":zu(r),"data-disabled":s?"":void 0,disabled:s,value:i,...f,ref:p,onClick:_(e.onClick,v=>{r||u==null||u(),g&&(b.current=v.isPropagationStopped(),b.current||v.stopPropagation())})}),g&&c.jsx(Fy,{control:m,bubbles:!b.current,name:o,value:i,checked:r,required:a,disabled:s,form:d,style:{transform:"translateX(-100%)"}})]})});Vu.displayName=Zr;var Bu="RadioIndicator",Wu=l.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:o,...r}=e,a=Ly(Bu,n);return c.jsx(be,{present:o||a.checked,children:c.jsx(L.span,{"data-state":zu(a.checked),"data-disabled":a.disabled?"":void 0,...r,ref:t})})});Wu.displayName=Bu;var Fy=e=>{const{control:t,checked:n,bubbles:o=!0,...r}=e,a=l.useRef(null),s=ln(n),i=Jn(t);return l.useEffect(()=>{const u=a.current,d=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(d,"checked").set;if(s!==n&&m){const h=new Event("click",{bubbles:o});m.call(u,n),u.dispatchEvent(h)}},[s,n,o]),c.jsx("input",{type:"radio","aria-hidden":!0,defaultChecked:n,...r,tabIndex:-1,ref:a,style:{...e.style,...i,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function zu(e){return e?"checked":"unchecked"}var $y=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Qr="RadioGroup",[Vy,S0]=ve(Qr,[gt,$u]),Gu=gt(),Hu=$u(),[By,Wy]=Vy(Qr),Uu=l.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:o,defaultValue:r,value:a,required:s=!1,disabled:i=!1,orientation:u,dir:d,loop:f=!0,onValueChange:m,...h}=e,p=Gu(n),b=Nt(d),[g,v]=Ce({prop:a,defaultProp:r,onChange:m});return c.jsx(By,{scope:n,name:o,required:s,disabled:i,value:g,onValueChange:v,children:c.jsx(ao,{asChild:!0,...p,orientation:u,dir:b,loop:f,children:c.jsx(L.div,{role:"radiogroup","aria-required":s,"aria-orientation":u,"data-disabled":i?"":void 0,dir:b,...h,ref:t})})})});Uu.displayName=Qr;var Ku="RadioGroupItem",Yu=l.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:o,...r}=e,a=Wy(Ku,n),s=a.disabled||o,i=Gu(n),u=Hu(n),d=l.useRef(null),f=J(t,d),m=a.value===r.value,h=l.useRef(!1);return l.useEffect(()=>{const p=g=>{$y.includes(g.key)&&(h.current=!0)},b=()=>h.current=!1;return document.addEventListener("keydown",p),document.addEventListener("keyup",b),()=>{document.removeEventListener("keydown",p),document.removeEventListener("keyup",b)}},[]),c.jsx(so,{asChild:!0,...i,focusable:!s,active:m,children:c.jsx(Vu,{disabled:s,required:a.required,checked:m,...u,...r,name:a.name,ref:f,onCheck:()=>a.onValueChange(r.value),onKeyDown:_(p=>{p.key==="Enter"&&p.preventDefault()}),onFocus:_(r.onFocus,()=>{var p;h.current&&((p=d.current)==null||p.click())})})})});Yu.displayName=Ku;var zy="RadioGroupIndicator",Xu=l.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...o}=e,r=Hu(n);return c.jsx(Wu,{...r,...o,ref:t})});Xu.displayName=zy;var qu=Uu,Ju=Yu,Gy=Xu;const Zu=l.forwardRef(({className:e,...t},n)=>c.jsx(qu,{className:R("grid gap-2",e),...t,ref:n}));Zu.displayName=qu.displayName;const Qu=l.forwardRef(({className:e,...t},n)=>c.jsx(Ju,{ref:n,className:R("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:c.jsx(Gy,{className:"flex items-center justify-center",children:c.jsx(oi,{className:"h-3.5 w-3.5 fill-primary"})})}));Qu.displayName=Ju.displayName;function ed(e,[t,n]){return Math.min(n,Math.max(t,e))}var Hy=[" ","Enter","ArrowUp","ArrowDown"],Uy=[" ","Enter"],yn="Select",[go,ho,Ky]=cn(yn),[Wt,P0]=ve(yn,[Ky,ft]),vo=ft(),[Yy,vt]=Wt(yn),[Xy,qy]=Wt(yn),td=e=>{const{__scopeSelect:t,children:n,open:o,defaultOpen:r,onOpenChange:a,value:s,defaultValue:i,onValueChange:u,dir:d,name:f,autoComplete:m,disabled:h,required:p,form:b}=e,g=vo(t),[v,y]=l.useState(null),[w,C]=l.useState(null),[N,E]=l.useState(!1),A=Nt(d),[M=!1,I]=Ce({prop:o,defaultProp:r,onChange:a}),[j,B]=Ce({prop:s,defaultProp:i,onChange:u}),z=l.useRef(null),O=v?b||!!v.closest("form"):!0,[U,W]=l.useState(new Set),oe=Array.from(U).map($=>$.props.value).join(";");return c.jsx(rn,{...g,children:c.jsxs(Yy,{required:p,scope:t,trigger:v,onTriggerChange:y,valueNode:w,onValueNodeChange:C,valueNodeHasChildren:N,onValueNodeHasChildrenChange:E,contentId:Ne(),value:j,onValueChange:B,open:M,onOpenChange:I,dir:A,triggerPointerDownPosRef:z,disabled:h,children:[c.jsx(go.Provider,{scope:t,children:c.jsx(Xy,{scope:e.__scopeSelect,onNativeOptionAdd:l.useCallback($=>{W(G=>new Set(G).add($))},[]),onNativeOptionRemove:l.useCallback($=>{W(G=>{const V=new Set(G);return V.delete($),V})},[]),children:n})}),O?c.jsxs(Pd,{"aria-hidden":!0,required:p,tabIndex:-1,name:f,autoComplete:m,value:j,onChange:$=>B($.target.value),disabled:h,form:b,children:[j===void 0?c.jsx("option",{value:""}):null,Array.from(U)]},oe):null]})})};td.displayName=yn;var nd="SelectTrigger",od=l.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:o=!1,...r}=e,a=vo(n),s=vt(nd,n),i=s.disabled||o,u=J(t,s.onTriggerChange),d=ho(n),f=l.useRef("touch"),[m,h,p]=Td(g=>{const v=d().filter(C=>!C.disabled),y=v.find(C=>C.value===s.value),w=Md(v,g,y);w!==void 0&&s.onValueChange(w.value)}),b=g=>{i||(s.onOpenChange(!0),p()),g&&(s.triggerPointerDownPosRef.current={x:Math.round(g.pageX),y:Math.round(g.pageY)})};return c.jsx(an,{asChild:!0,...a,children:c.jsx(L.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:i,"data-disabled":i?"":void 0,"data-placeholder":Sd(s.value)?"":void 0,...r,ref:u,onClick:_(r.onClick,g=>{g.currentTarget.focus(),f.current!=="mouse"&&b(g)}),onPointerDown:_(r.onPointerDown,g=>{f.current=g.pointerType;const v=g.target;v.hasPointerCapture(g.pointerId)&&v.releasePointerCapture(g.pointerId),g.button===0&&g.ctrlKey===!1&&g.pointerType==="mouse"&&(b(g),g.preventDefault())}),onKeyDown:_(r.onKeyDown,g=>{const v=m.current!=="";!(g.ctrlKey||g.altKey||g.metaKey)&&g.key.length===1&&h(g.key),!(v&&g.key===" ")&&Hy.includes(g.key)&&(b(),g.preventDefault())})})})});od.displayName=nd;var rd="SelectValue",ad=l.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,children:a,placeholder:s="",...i}=e,u=vt(rd,n),{onValueNodeHasChildrenChange:d}=u,f=a!==void 0,m=J(t,u.onValueNodeChange);return he(()=>{d(f)},[d,f]),c.jsx(L.span,{...i,ref:m,style:{pointerEvents:"none"},children:Sd(u.value)?c.jsx(c.Fragment,{children:s}):a})});ad.displayName=rd;var Jy="SelectIcon",sd=l.forwardRef((e,t)=>{const{__scopeSelect:n,children:o,...r}=e;return c.jsx(L.span,{"aria-hidden":!0,...r,ref:t,children:o||"▼"})});sd.displayName=Jy;var St="SelectContent",id=l.forwardRef((e,t)=>{const n=vt(St,e.__scopeSelect),[o,r]=l.useState();if(he(()=>{r(new DocumentFragment)},[]),!n.open){const a=o;return a?Sn.createPortal(c.jsx(ld,{scope:e.__scopeSelect,children:c.jsx(go.Slot,{scope:e.__scopeSelect,children:c.jsx("div",{children:e.children})})}),a):null}return c.jsx(cd,{...e,ref:t})});id.displayName=St;var Le=10,[ld,bt]=Wt(St),Zy="SelectContentImpl",cd=l.forwardRef((e,t)=>{const{__scopeSelect:n,position:o="item-aligned",onCloseAutoFocus:r,onEscapeKeyDown:a,onPointerDownOutside:s,side:i,sideOffset:u,align:d,alignOffset:f,arrowPadding:m,collisionBoundary:h,collisionPadding:p,sticky:b,hideWhenDetached:g,avoidCollisions:v,...y}=e,w=vt(St,n),[C,N]=l.useState(null),[E,A]=l.useState(null),M=J(t,k=>N(k)),[I,j]=l.useState(null),[B,z]=l.useState(null),O=ho(n),[U,W]=l.useState(!1),oe=l.useRef(!1);l.useEffect(()=>{if(C)return $n(C)},[C]),_n();const $=l.useCallback(k=>{const[ae,...se]=O().map(ie=>ie.ref.current),[te]=se.slice(-1),re=document.activeElement;for(const ie of k)if(ie===re||(ie==null||ie.scrollIntoView({block:"nearest"}),ie===ae&&E&&(E.scrollTop=0),ie===te&&E&&(E.scrollTop=E.scrollHeight),ie==null||ie.focus(),document.activeElement!==re))return},[O,E]),G=l.useCallback(()=>$([I,C]),[$,I,C]);l.useEffect(()=>{U&&G()},[U,G]);const{onOpenChange:V,triggerPointerDownPosRef:T}=w;l.useEffect(()=>{if(C){let k={x:0,y:0};const ae=te=>{var re,ie;k={x:Math.abs(Math.round(te.pageX)-(((re=T.current)==null?void 0:re.x)??0)),y:Math.abs(Math.round(te.pageY)-(((ie=T.current)==null?void 0:ie.y)??0))}},se=te=>{k.x<=10&&k.y<=10?te.preventDefault():C.contains(te.target)||V(!1),document.removeEventListener("pointermove",ae),T.current=null};return T.current!==null&&(document.addEventListener("pointermove",ae),document.addEventListener("pointerup",se,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",ae),document.removeEventListener("pointerup",se,{capture:!0})}}},[C,V,T]),l.useEffect(()=>{const k=()=>V(!1);return window.addEventListener("blur",k),window.addEventListener("resize",k),()=>{window.removeEventListener("blur",k),window.removeEventListener("resize",k)}},[V]);const[H,Z]=Td(k=>{const ae=O().filter(re=>!re.disabled),se=ae.find(re=>re.ref.current===document.activeElement),te=Md(ae,k,se);te&&setTimeout(()=>te.ref.current.focus())}),X=l.useCallback((k,ae,se)=>{const te=!oe.current&&!se;(w.value!==void 0&&w.value===ae||te)&&(j(k),te&&(oe.current=!0))},[w.value]),K=l.useCallback(()=>C==null?void 0:C.focus(),[C]),q=l.useCallback((k,ae,se)=>{const te=!oe.current&&!se;(w.value!==void 0&&w.value===ae||te)&&z(k)},[w.value]),ce=o==="popper"?ea:ud,fe=ce===ea?{side:i,sideOffset:u,align:d,alignOffset:f,arrowPadding:m,collisionBoundary:h,collisionPadding:p,sticky:b,hideWhenDetached:g,avoidCollisions:v}:{};return c.jsx(ld,{scope:n,content:C,viewport:E,onViewportChange:A,itemRefCallback:X,selectedItem:I,onItemLeave:K,itemTextRefCallback:q,focusSelectedItem:G,selectedItemText:B,position:o,isPositioned:U,searchRef:H,children:c.jsx(Qt,{as:We,allowPinchZoom:!0,children:c.jsx(Jt,{asChild:!0,trapped:w.open,onMountAutoFocus:k=>{k.preventDefault()},onUnmountAutoFocus:_(r,k=>{var ae;(ae=w.trigger)==null||ae.focus({preventScroll:!0}),k.preventDefault()}),children:c.jsx(wt,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:k=>k.preventDefault(),onDismiss:()=>w.onOpenChange(!1),children:c.jsx(ce,{role:"listbox",id:w.contentId,"data-state":w.open?"open":"closed",dir:w.dir,onContextMenu:k=>k.preventDefault(),...y,...fe,onPlaced:()=>W(!0),ref:M,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:_(y.onKeyDown,k=>{const ae=k.ctrlKey||k.altKey||k.metaKey;if(k.key==="Tab"&&k.preventDefault(),!ae&&k.key.length===1&&Z(k.key),["ArrowUp","ArrowDown","Home","End"].includes(k.key)){let te=O().filter(re=>!re.disabled).map(re=>re.ref.current);if(["ArrowUp","End"].includes(k.key)&&(te=te.slice().reverse()),["ArrowUp","ArrowDown"].includes(k.key)){const re=k.target,ie=te.indexOf(re);te=te.slice(ie+1)}setTimeout(()=>$(te)),k.preventDefault()}})})})})})})});cd.displayName=Zy;var Qy="SelectItemAlignedPosition",ud=l.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:o,...r}=e,a=vt(St,n),s=bt(St,n),[i,u]=l.useState(null),[d,f]=l.useState(null),m=J(t,M=>f(M)),h=ho(n),p=l.useRef(!1),b=l.useRef(!0),{viewport:g,selectedItem:v,selectedItemText:y,focusSelectedItem:w}=s,C=l.useCallback(()=>{if(a.trigger&&a.valueNode&&i&&d&&g&&v&&y){const M=a.trigger.getBoundingClientRect(),I=d.getBoundingClientRect(),j=a.valueNode.getBoundingClientRect(),B=y.getBoundingClientRect();if(a.dir!=="rtl"){const re=B.left-I.left,ie=j.left-re,ye=M.left-ie,Se=M.width+ye,Ae=Math.max(Se,I.width),ot=window.innerWidth-Le,Fe=ed(ie,[Le,Math.max(Le,ot-Ae)]);i.style.minWidth=Se+"px",i.style.left=Fe+"px"}else{const re=I.right-B.right,ie=window.innerWidth-j.right-re,ye=window.innerWidth-M.right-ie,Se=M.width+ye,Ae=Math.max(Se,I.width),ot=window.innerWidth-Le,Fe=ed(ie,[Le,Math.max(Le,ot-Ae)]);i.style.minWidth=Se+"px",i.style.right=Fe+"px"}const z=h(),O=window.innerHeight-Le*2,U=g.scrollHeight,W=window.getComputedStyle(d),oe=parseInt(W.borderTopWidth,10),$=parseInt(W.paddingTop,10),G=parseInt(W.borderBottomWidth,10),V=parseInt(W.paddingBottom,10),T=oe+$+U+V+G,H=Math.min(v.offsetHeight*5,T),Z=window.getComputedStyle(g),X=parseInt(Z.paddingTop,10),K=parseInt(Z.paddingBottom,10),q=M.top+M.height/2-Le,ce=O-q,fe=v.offsetHeight/2,k=v.offsetTop+fe,ae=oe+$+k,se=T-ae;if(ae<=q){const re=z.length>0&&v===z[z.length-1].ref.current;i.style.bottom="0px";const ie=d.clientHeight-g.offsetTop-g.offsetHeight,ye=Math.max(ce,fe+(re?K:0)+ie+G),Se=ae+ye;i.style.height=Se+"px"}else{const re=z.length>0&&v===z[0].ref.current;i.style.top="0px";const ye=Math.max(q,oe+g.offsetTop+(re?X:0)+fe)+se;i.style.height=ye+"px",g.scrollTop=ae-q+g.offsetTop}i.style.margin=`${Le}px 0`,i.style.minHeight=H+"px",i.style.maxHeight=O+"px",o==null||o(),requestAnimationFrame(()=>p.current=!0)}},[h,a.trigger,a.valueNode,i,d,g,v,y,a.dir,o]);he(()=>C(),[C]);const[N,E]=l.useState();he(()=>{d&&E(window.getComputedStyle(d).zIndex)},[d]);const A=l.useCallback(M=>{M&&b.current===!0&&(C(),w==null||w(),b.current=!1)},[C,w]);return c.jsx(tw,{scope:n,contentWrapper:i,shouldExpandOnScrollRef:p,onScrollButtonChange:A,children:c.jsx("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:N},children:c.jsx(L.div,{...r,ref:m,style:{boxSizing:"border-box",maxHeight:"100%",...r.style}})})})});ud.displayName=Qy;var ew="SelectPopperPosition",ea=l.forwardRef((e,t)=>{const{__scopeSelect:n,align:o="start",collisionPadding:r=Le,...a}=e,s=vo(n);return c.jsx(Zn,{...s,...a,ref:t,align:o,collisionPadding:r,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)"}})});ea.displayName=ew;var[tw,ta]=Wt(St,{}),na="SelectViewport",dd=l.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:o,...r}=e,a=bt(na,n),s=ta(na,n),i=J(t,a.onViewportChange),u=l.useRef(0);return c.jsxs(c.Fragment,{children:[c.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:o}),c.jsx(go.Slot,{scope:n,children:c.jsx(L.div,{"data-radix-select-viewport":"",role:"presentation",...r,ref:i,style:{position:"relative",flex:1,overflow:"hidden auto",...r.style},onScroll:_(r.onScroll,d=>{const f=d.currentTarget,{contentWrapper:m,shouldExpandOnScrollRef:h}=s;if(h!=null&&h.current&&m){const p=Math.abs(u.current-f.scrollTop);if(p>0){const b=window.innerHeight-Le*2,g=parseFloat(m.style.minHeight),v=parseFloat(m.style.height),y=Math.max(g,v);if(y<b){const w=y+p,C=Math.min(b,w),N=w-C;m.style.height=C+"px",m.style.bottom==="0px"&&(f.scrollTop=N>0?N:0,m.style.justifyContent="flex-end")}}}u.current=f.scrollTop})})})]})});dd.displayName=na;var fd="SelectGroup",[nw,ow]=Wt(fd),pd=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=Ne();return c.jsx(nw,{scope:n,id:r,children:c.jsx(L.div,{role:"group","aria-labelledby":r,...o,ref:t})})});pd.displayName=fd;var md="SelectLabel",gd=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=ow(md,n);return c.jsx(L.div,{id:r.id,...o,ref:t})});gd.displayName=md;var bo="SelectItem",[rw,hd]=Wt(bo),vd=l.forwardRef((e,t)=>{const{__scopeSelect:n,value:o,disabled:r=!1,textValue:a,...s}=e,i=vt(bo,n),u=bt(bo,n),d=i.value===o,[f,m]=l.useState(a??""),[h,p]=l.useState(!1),b=J(t,w=>{var C;return(C=u.itemRefCallback)==null?void 0:C.call(u,w,o,r)}),g=Ne(),v=l.useRef("touch"),y=()=>{r||(i.onValueChange(o),i.onOpenChange(!1))};if(o==="")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 c.jsx(rw,{scope:n,value:o,disabled:r,textId:g,isSelected:d,onItemTextChange:l.useCallback(w=>{m(C=>C||((w==null?void 0:w.textContent)??"").trim())},[]),children:c.jsx(go.ItemSlot,{scope:n,value:o,disabled:r,textValue:f,children:c.jsx(L.div,{role:"option","aria-labelledby":g,"data-highlighted":h?"":void 0,"aria-selected":d&&h,"data-state":d?"checked":"unchecked","aria-disabled":r||void 0,"data-disabled":r?"":void 0,tabIndex:r?void 0:-1,...s,ref:b,onFocus:_(s.onFocus,()=>p(!0)),onBlur:_(s.onBlur,()=>p(!1)),onClick:_(s.onClick,()=>{v.current!=="mouse"&&y()}),onPointerUp:_(s.onPointerUp,()=>{v.current==="mouse"&&y()}),onPointerDown:_(s.onPointerDown,w=>{v.current=w.pointerType}),onPointerMove:_(s.onPointerMove,w=>{var C;v.current=w.pointerType,r?(C=u.onItemLeave)==null||C.call(u):v.current==="mouse"&&w.currentTarget.focus({preventScroll:!0})}),onPointerLeave:_(s.onPointerLeave,w=>{var C;w.currentTarget===document.activeElement&&((C=u.onItemLeave)==null||C.call(u))}),onKeyDown:_(s.onKeyDown,w=>{var N;((N=u.searchRef)==null?void 0:N.current)!==""&&w.key===" "||(Uy.includes(w.key)&&y(),w.key===" "&&w.preventDefault())})})})})});vd.displayName=bo;var wn="SelectItemText",bd=l.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,...a}=e,s=vt(wn,n),i=bt(wn,n),u=hd(wn,n),d=qy(wn,n),[f,m]=l.useState(null),h=J(t,y=>m(y),u.onItemTextChange,y=>{var w;return(w=i.itemTextRefCallback)==null?void 0:w.call(i,y,u.value,u.disabled)}),p=f==null?void 0:f.textContent,b=l.useMemo(()=>c.jsx("option",{value:u.value,disabled:u.disabled,children:p},u.value),[u.disabled,u.value,p]),{onNativeOptionAdd:g,onNativeOptionRemove:v}=d;return he(()=>(g(b),()=>v(b)),[g,v,b]),c.jsxs(c.Fragment,{children:[c.jsx(L.span,{id:u.textId,...a,ref:h}),u.isSelected&&s.valueNode&&!s.valueNodeHasChildren?Sn.createPortal(a.children,s.valueNode):null]})});bd.displayName=wn;var yd="SelectItemIndicator",wd=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return hd(yd,n).isSelected?c.jsx(L.span,{"aria-hidden":!0,...o,ref:t}):null});wd.displayName=yd;var oa="SelectScrollUpButton",xd=l.forwardRef((e,t)=>{const n=bt(oa,e.__scopeSelect),o=ta(oa,e.__scopeSelect),[r,a]=l.useState(!1),s=J(t,o.onScrollButtonChange);return he(()=>{if(n.viewport&&n.isPositioned){let i=function(){const d=u.scrollTop>0;a(d)};const u=n.viewport;return i(),u.addEventListener("scroll",i),()=>u.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),r?c.jsx(Nd,{...e,ref:s,onAutoScroll:()=>{const{viewport:i,selectedItem:u}=n;i&&u&&(i.scrollTop=i.scrollTop-u.offsetHeight)}}):null});xd.displayName=oa;var ra="SelectScrollDownButton",Cd=l.forwardRef((e,t)=>{const n=bt(ra,e.__scopeSelect),o=ta(ra,e.__scopeSelect),[r,a]=l.useState(!1),s=J(t,o.onScrollButtonChange);return he(()=>{if(n.viewport&&n.isPositioned){let i=function(){const d=u.scrollHeight-u.clientHeight,f=Math.ceil(u.scrollTop)<d;a(f)};const u=n.viewport;return i(),u.addEventListener("scroll",i),()=>u.removeEventListener("scroll",i)}},[n.viewport,n.isPositioned]),r?c.jsx(Nd,{...e,ref:s,onAutoScroll:()=>{const{viewport:i,selectedItem:u}=n;i&&u&&(i.scrollTop=i.scrollTop+u.offsetHeight)}}):null});Cd.displayName=ra;var Nd=l.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:o,...r}=e,a=bt("SelectScrollButton",n),s=l.useRef(null),i=ho(n),u=l.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return l.useEffect(()=>()=>u(),[u]),he(()=>{var f;const d=i().find(m=>m.ref.current===document.activeElement);(f=d==null?void 0:d.ref.current)==null||f.scrollIntoView({block:"nearest"})},[i]),c.jsx(L.div,{"aria-hidden":!0,...r,ref:t,style:{flexShrink:0,...r.style},onPointerDown:_(r.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(o,50))}),onPointerMove:_(r.onPointerMove,()=>{var d;(d=a.onItemLeave)==null||d.call(a),s.current===null&&(s.current=window.setInterval(o,50))}),onPointerLeave:_(r.onPointerLeave,()=>{u()})})}),aw="SelectSeparator",Ed=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return c.jsx(L.div,{"aria-hidden":!0,...o,ref:t})});Ed.displayName=aw;var aa="SelectArrow",sw=l.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=vo(n),a=vt(aa,n),s=bt(aa,n);return a.open&&s.position==="popper"?c.jsx(Qn,{...r,...o,ref:t}):null});sw.displayName=aa;function Sd(e){return e===""||e===void 0}var Pd=l.forwardRef((e,t)=>{const{value:n,...o}=e,r=l.useRef(null),a=J(t,r),s=ln(n);return l.useEffect(()=>{const i=r.current,u=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(u,"value").set;if(s!==n&&f){const m=new Event("change",{bubbles:!0});f.call(i,n),i.dispatchEvent(m)}},[s,n]),c.jsx(kr,{asChild:!0,children:c.jsx("select",{...o,ref:a,defaultValue:n})})});Pd.displayName="BubbleSelect";function Td(e){const t=ge(e),n=l.useRef(""),o=l.useRef(0),r=l.useCallback(s=>{const i=n.current+s;t(i),function u(d){n.current=d,window.clearTimeout(o.current),d!==""&&(o.current=window.setTimeout(()=>u(""),1e3))}(i)},[t]),a=l.useCallback(()=>{n.current="",window.clearTimeout(o.current)},[]);return l.useEffect(()=>()=>window.clearTimeout(o.current),[]),[n,r,a]}function Md(e,t,n){const r=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=iw(e,Math.max(a,0));r.length===1&&(s=s.filter(d=>d!==n));const u=s.find(d=>d.textValue.toLowerCase().startsWith(r.toLowerCase()));return u!==n?u:void 0}function iw(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var lw=td,Rd=od,cw=ad,uw=sd,Ad=id,dw=dd,fw=pd,_d=gd,Id=vd,pw=bd,mw=wd,kd=xd,jd=Cd,Dd=Ed;const gw=lw,hw=fw,vw=cw,Od=l.forwardRef(({className:e,children:t,...n},o)=>c.jsxs(Rd,{ref:o,className:R("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 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),...n,children:[t,c.jsx(uw,{asChild:!0,children:c.jsx(Xo,{className:"h-4 w-4 opacity-50"})})]}));Od.displayName=Rd.displayName;const sa=l.forwardRef(({className:e,...t},n)=>c.jsx(kd,{ref:n,className:R("flex cursor-default items-center justify-center py-1",e),...t,children:c.jsx(Sg,{className:"h-4 w-4"})}));sa.displayName=kd.displayName;const ia=l.forwardRef(({className:e,...t},n)=>c.jsx(jd,{ref:n,className:R("flex cursor-default items-center justify-center py-1",e),...t,children:c.jsx(Xo,{className:"h-4 w-4"})}));ia.displayName=jd.displayName;const Ld=l.forwardRef(({className:e,children:t,position:n="popper",...o},r)=>c.jsxs(Ad,{ref:r,className:R("relative z-50 max-h-96 min-w-[8rem] overflow-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",n==="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:n,...o,children:[c.jsx(sa,{}),c.jsx(dw,{className:R("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),c.jsx(ia,{})]}));Ld.displayName=Ad.displayName;const Fd=l.forwardRef(({className:e,...t},n)=>c.jsx(_d,{ref:n,className:R("px-2 py-1.5 text-sm font-semibold",e),...t}));Fd.displayName=_d.displayName;const $d=l.forwardRef(({className:e,children:t,...n},o)=>c.jsxs(Id,{ref:o,className:R("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),...n,children:[c.jsx("span",{className:"absolute right-2 flex h-3.5 w-3.5 items-center justify-center",children:c.jsx(mw,{children:c.jsx(Yo,{className:"h-4 w-4"})})}),c.jsx(pw,{children:t})]}));$d.displayName=Id.displayName;const Vd=l.forwardRef(({className:e,...t},n)=>c.jsx(Dd,{ref:n,className:R("-mx-1 my-1 h-px bg-muted",e),...t}));Vd.displayName=Dd.displayName;const bw=({className:e,repeat:t=1,...n})=>c.jsx(c.Fragment,{children:Array.from({length:t??1}).map((o,r)=>c.jsx("div",{className:R("animate-pulse rounded-md bg-gray-700/10",e),...n},r))});var la="Switch",[yw,T0]=ve(la),[ww,xw]=yw(la),Bd=l.forwardRef((e,t)=>{const{__scopeSwitch:n,name:o,checked:r,defaultChecked:a,required:s,disabled:i,value:u="on",onCheckedChange:d,form:f,...m}=e,[h,p]=l.useState(null),b=J(t,C=>p(C)),g=l.useRef(!1),v=h?f||!!h.closest("form"):!0,[y=!1,w]=Ce({prop:r,defaultProp:a,onChange:d});return c.jsxs(ww,{scope:n,checked:y,disabled:i,children:[c.jsx(L.button,{type:"button",role:"switch","aria-checked":y,"aria-required":s,"data-state":Gd(y),"data-disabled":i?"":void 0,disabled:i,value:u,...m,ref:b,onClick:_(e.onClick,C=>{w(N=>!N),v&&(g.current=C.isPropagationStopped(),g.current||C.stopPropagation())})}),v&&c.jsx(Cw,{control:h,bubbles:!g.current,name:o,value:u,checked:y,required:s,disabled:i,form:f,style:{transform:"translateX(-100%)"}})]})});Bd.displayName=la;var Wd="SwitchThumb",zd=l.forwardRef((e,t)=>{const{__scopeSwitch:n,...o}=e,r=xw(Wd,n);return c.jsx(L.span,{"data-state":Gd(r.checked),"data-disabled":r.disabled?"":void 0,...o,ref:t})});zd.displayName=Wd;var Cw=e=>{const{control:t,checked:n,bubbles:o=!0,...r}=e,a=l.useRef(null),s=ln(n),i=Jn(t);return l.useEffect(()=>{const u=a.current,d=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(d,"checked").set;if(s!==n&&m){const h=new Event("click",{bubbles:o});m.call(u,n),u.dispatchEvent(h)}},[s,n,o]),c.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...r,tabIndex:-1,ref:a,style:{...e.style,...i,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function Gd(e){return e?"checked":"unchecked"}var Hd=Bd,Nw=zd;const Ud=l.forwardRef(({className:e,...t},n)=>c.jsx(Hd,{className:R("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:n,children:c.jsx(Nw,{className:R("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")})}));Ud.displayName=Hd.displayName;const Kd=l.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:"relative w-full overflow-auto",children:c.jsx("table",{ref:n,className:R("w-full caption-bottom text-sm",e),...t})}));Kd.displayName="Table";const Yd=l.forwardRef(({className:e,...t},n)=>c.jsx("thead",{ref:n,className:R("[&_tr]:border-b",e),...t}));Yd.displayName="TableHeader";const Xd=l.forwardRef(({className:e,...t},n)=>c.jsx("tbody",{ref:n,className:R("[&_tr:last-child]:border-0",e),...t}));Xd.displayName="TableBody";const qd=l.forwardRef(({className:e,...t},n)=>c.jsx("tfoot",{ref:n,className:R("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",e),...t}));qd.displayName="TableFooter";const Jd=l.forwardRef(({className:e,...t},n)=>c.jsx("tr",{ref:n,className:R("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",e),...t}));Jd.displayName="TableRow";const Zd=l.forwardRef(({className:e,...t},n)=>c.jsx("th",{ref:n,className:R("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}));Zd.displayName="TableHead";const Qd=l.forwardRef(({className:e,...t},n)=>c.jsx("td",{ref:n,className:R("p-2 align-middle [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",e),...t}));Qd.displayName="TableCell";const ef=l.forwardRef(({className:e,...t},n)=>c.jsx("caption",{ref:n,className:R("mt-4 text-sm text-muted-foreground",e),...t}));ef.displayName="TableCaption";var ca="Tabs",[Ew,M0]=ve(ca,[gt]),tf=gt(),[Sw,ua]=Ew(ca),nf=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:a,orientation:s="horizontal",dir:i,activationMode:u="automatic",...d}=e,f=Nt(i),[m,h]=Ce({prop:o,onChange:r,defaultProp:a});return c.jsx(Sw,{scope:n,baseId:Ne(),value:m,onValueChange:h,orientation:s,dir:f,activationMode:u,children:c.jsx(L.div,{dir:f,"data-orientation":s,...d,ref:t})})});nf.displayName=ca;var of="TabsList",rf=l.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...r}=e,a=ua(of,n),s=tf(n);return c.jsx(ao,{asChild:!0,...s,orientation:a.orientation,dir:a.dir,loop:o,children:c.jsx(L.div,{role:"tablist","aria-orientation":a.orientation,...r,ref:t})})});rf.displayName=of;var af="TabsTrigger",sf=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...a}=e,s=ua(af,n),i=tf(n),u=uf(s.baseId,o),d=df(s.baseId,o),f=o===s.value;return c.jsx(so,{asChild:!0,...i,focusable:!r,active:f,children:c.jsx(L.button,{type:"button",role:"tab","aria-selected":f,"aria-controls":d,"data-state":f?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:u,...a,ref:t,onMouseDown:_(e.onMouseDown,m=>{!r&&m.button===0&&m.ctrlKey===!1?s.onValueChange(o):m.preventDefault()}),onKeyDown:_(e.onKeyDown,m=>{[" ","Enter"].includes(m.key)&&s.onValueChange(o)}),onFocus:_(e.onFocus,()=>{const m=s.activationMode!=="manual";!f&&!r&&m&&s.onValueChange(o)})})})});sf.displayName=af;var lf="TabsContent",cf=l.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:r,children:a,...s}=e,i=ua(lf,n),u=uf(i.baseId,o),d=df(i.baseId,o),f=o===i.value,m=l.useRef(f);return l.useEffect(()=>{const h=requestAnimationFrame(()=>m.current=!1);return()=>cancelAnimationFrame(h)},[]),c.jsx(be,{present:r||f,children:({present:h})=>c.jsx(L.div,{"data-state":f?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":u,hidden:!h,id:d,tabIndex:0,...s,ref:t,style:{...e.style,animationDuration:m.current?"0s":void 0},children:h&&a})})});cf.displayName=lf;function uf(e,t){return`${e}-trigger-${t}`}function df(e,t){return`${e}-content-${t}`}var Pw=nf,ff=rf,pf=sf,mf=cf;const Tw=Pw,gf=l.forwardRef(({className:e,...t},n)=>c.jsx(ff,{ref:n,className:R("inline-flex h-9 items-center justify-center rounded-lg bg-muted p-1 text-muted-foreground",e),...t}));gf.displayName=ff.displayName;const hf=l.forwardRef(({className:e,...t},n)=>c.jsx(pf,{ref:n,className:R("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}));hf.displayName=pf.displayName;const vf=l.forwardRef(({className:e,...t},n)=>c.jsx(mf,{ref:n,className:R("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",e),...t}));vf.displayName=mf.displayName;const bf=l.forwardRef(({className:e,...t},n)=>c.jsx("textarea",{className:R("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-sm 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:n,...t}));bf.displayName="Textarea";var Mw=e=>{switch(e){case"success":return _w;case"info":return kw;case"warning":return Iw;case"error":return jw;default:return null}},Rw=Array(12).fill(0),Aw=({visible:e,className:t})=>S.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},S.createElement("div",{className:"sonner-spinner"},Rw.map((n,o)=>S.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),_w=S.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},S.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"})),Iw=S.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},S.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"})),kw=S.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},S.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"})),jw=S.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},S.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"})),Dw=S.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"},S.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),S.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Ow=()=>{let[e,t]=S.useState(document.hidden);return S.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},da=1,Lw=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...o}=e,r=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:da++,a=this.toasts.find(i=>i.id===r),s=e.dismissible===void 0?!0:e.dismissible;return a?this.toasts=this.toasts.map(i=>i.id===r?(this.publish({...i,...e,id:r,title:n}),{...i,...e,id:r,dismissible:s,title:n}):i):this.addToast({title:n,...o,dismissible:s,id:r}),r},this.dismiss=e=>(e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let o=e instanceof Promise?e:e(),r=n!==void 0,a,s=o.then(async u=>{if(a=["resolve",u],S.isValidElement(u))r=!1,this.create({id:n,type:"default",message:u});else if($w(u)&&!u.ok){r=!1;let d=typeof t.error=="function"?await t.error(`HTTP error! status: ${u.status}`):t.error,f=typeof t.description=="function"?await t.description(`HTTP error! status: ${u.status}`):t.description;this.create({id:n,type:"error",message:d,description:f})}else if(t.success!==void 0){r=!1;let d=typeof t.success=="function"?await t.success(u):t.success,f=typeof t.description=="function"?await t.description(u):t.description;this.create({id:n,type:"success",message:d,description:f})}}).catch(async u=>{if(a=["reject",u],t.error!==void 0){r=!1;let d=typeof t.error=="function"?await t.error(u):t.error,f=typeof t.description=="function"?await t.description(u):t.description;this.create({id:n,type:"error",message:d,description:f})}}).finally(()=>{var u;r&&(this.dismiss(n),n=void 0),(u=t.finally)==null||u.call(t)}),i=()=>new Promise((u,d)=>s.then(()=>a[0]==="reject"?d(a[1]):u(a[1])).catch(d));return typeof n!="string"&&typeof n!="number"?{unwrap:i}:Object.assign(n,{unwrap:i})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||da++;return this.create({jsx:e(n),id:n,...t}),n},this.subscribers=[],this.toasts=[]}},Re=new Lw,Fw=(e,t)=>{let n=(t==null?void 0:t.id)||da++;return Re.addToast({title:e,...t,id:n}),n},$w=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Vw=Fw,Bw=()=>Re.toasts,Ww=Object.assign(Vw,{success:Re.success,info:Re.info,warning:Re.warning,error:Re.error,custom:Re.custom,message:Re.message,promise:Re.promise,dismiss:Re.dismiss,loading:Re.loading},{getHistory:Bw});function zw(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",t==="top"&&n.firstChild?n.insertBefore(o,n.firstChild):n.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}zw(`:where(html[dir="ltr"]),:where([data-sonner-toaster][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%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][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%)}:where([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:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:max(var(--offset),env(safe-area-inset-right))}:where([data-sonner-toaster][data-x-position="left"]){left:max(var(--offset),env(safe-area-inset-left))}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:max(var(--offset),env(safe-area-inset-top))}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:max(var(--offset),env(safe-area-inset-bottom))}:where([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);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([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 #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([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)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([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;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([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);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-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:0;right:0;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([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}:where([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}:where([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, 0px));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:swipe-out .2s ease-out forwards}@keyframes swipe-out{0%{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount)));opacity:1}to{transform:translateY(calc(var(--lift) * var(--offset) + var(--swipe-amount) + var(--lift) * -100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;--mobile-offset: 16px;right:var(--mobile-offset);left:var(--mobile-offset);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset)}[data-sonner-toaster][data-y-position=bottom]{bottom:20px}[data-sonner-toaster][data-y-position=top]{top:20px}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset);right:var(--mobile-offset);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--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-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-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--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, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--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-rich-colors=true][data-sonner-toast][data-type=success],[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],[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],[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],[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:nth-child(1){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)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{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%)}
197
+ `);function yo(e){return e.label!==void 0}var Gw=3,Hw="32px",yf=4e3,Uw=356,Kw=14,Yw=20,Xw=200;function qw(...e){return e.filter(Boolean).join(" ")}var Jw=e=>{var t,n,o,r,a,s,i,u,d,f,m;let{invert:h,toast:p,unstyled:b,interacting:g,setHeights:v,visibleToasts:y,heights:w,index:C,toasts:N,expanded:E,removeToast:A,defaultRichColors:M,closeButton:I,style:j,cancelButtonStyle:B,actionButtonStyle:z,className:O="",descriptionClassName:U="",duration:W,position:oe,gap:$,loadingIcon:G,expandByDefault:V,classNames:T,icons:H,closeButtonAriaLabel:Z="Close toast",pauseWhenPageIsHidden:X,cn:K}=e,[q,ce]=S.useState(!1),[fe,k]=S.useState(!1),[ae,se]=S.useState(!1),[te,re]=S.useState(!1),[ie,ye]=S.useState(!1),[Se,Ae]=S.useState(0),[ot,Fe]=S.useState(0),rt=S.useRef(p.duration||W||yf),Ye=S.useRef(null),at=S.useRef(null),x=C===0,F=C+1<=y,D=p.type,ne=p.dismissible!==!1,xe=p.className||"",de=p.descriptionClassName||"",Y=S.useMemo(()=>w.findIndex(Q=>Q.toastId===p.id)||0,[w,p.id]),$e=S.useMemo(()=>{var Q;return(Q=p.closeButton)!=null?Q:I},[p.closeButton,I]);S.useMemo(()=>p.duration||W||yf,[p.duration,W]);let Xe=S.useRef(0),me=S.useRef(0),qe=S.useRef(0),Je=S.useRef(null),[Ve,Ht]=oe.split("-"),ke=S.useMemo(()=>w.reduce((Q,le,pe)=>pe>=Y?Q:Q+le.height,0),[w,Y]),Yf=Ow(),m0=p.invert||h,xa=D==="loading";me.current=S.useMemo(()=>Y*$+ke,[Y,ke]),S.useEffect(()=>{ce(!0)},[]),S.useEffect(()=>{let Q=at.current;if(Q){let le=Q.getBoundingClientRect().height;return Fe(le),v(pe=>[{toastId:p.id,height:le,position:p.position},...pe]),()=>v(pe=>pe.filter(Be=>Be.toastId!==p.id))}},[v,p.id]),S.useLayoutEffect(()=>{if(!q)return;let Q=at.current,le=Q.style.height;Q.style.height="auto";let pe=Q.getBoundingClientRect().height;Q.style.height=le,Fe(pe),v(Be=>Be.find(Ze=>Ze.toastId===p.id)?Be.map(Ze=>Ze.toastId===p.id?{...Ze,height:pe}:Ze):[{toastId:p.id,height:pe,position:p.position},...Be])},[q,p.title,p.description,v,p.id]);let yt=S.useCallback(()=>{k(!0),Ae(me.current),v(Q=>Q.filter(le=>le.toastId!==p.id)),setTimeout(()=>{A(p)},Xw)},[p,A,v,me]);S.useEffect(()=>{if(p.promise&&D==="loading"||p.duration===1/0||p.type==="loading")return;let Q;return E||g||X&&Yf?(()=>{if(qe.current<Xe.current){let le=new Date().getTime()-Xe.current;rt.current=rt.current-le}qe.current=new Date().getTime()})():rt.current!==1/0&&(Xe.current=new Date().getTime(),Q=setTimeout(()=>{var le;(le=p.onAutoClose)==null||le.call(p,p),yt()},rt.current)),()=>clearTimeout(Q)},[E,g,p,D,X,Yf,yt]),S.useEffect(()=>{p.delete&&yt()},[yt,p.delete]);function g0(){var Q,le,pe;return H!=null&&H.loading?S.createElement("div",{className:K(T==null?void 0:T.loader,(Q=p==null?void 0:p.classNames)==null?void 0:Q.loader,"sonner-loader"),"data-visible":D==="loading"},H.loading):G?S.createElement("div",{className:K(T==null?void 0:T.loader,(le=p==null?void 0:p.classNames)==null?void 0:le.loader,"sonner-loader"),"data-visible":D==="loading"},G):S.createElement(Aw,{className:K(T==null?void 0:T.loader,(pe=p==null?void 0:p.classNames)==null?void 0:pe.loader),visible:D==="loading"})}return S.createElement("li",{tabIndex:0,ref:at,className:K(O,xe,T==null?void 0:T.toast,(t=p==null?void 0:p.classNames)==null?void 0:t.toast,T==null?void 0:T.default,T==null?void 0:T[D],(n=p==null?void 0:p.classNames)==null?void 0:n[D]),"data-sonner-toast":"","data-rich-colors":(o=p.richColors)!=null?o:M,"data-styled":!(p.jsx||p.unstyled||b),"data-mounted":q,"data-promise":!!p.promise,"data-swiped":ie,"data-removed":fe,"data-visible":F,"data-y-position":Ve,"data-x-position":Ht,"data-index":C,"data-front":x,"data-swiping":ae,"data-dismissible":ne,"data-type":D,"data-invert":m0,"data-swipe-out":te,"data-expanded":!!(E||V&&q),style:{"--index":C,"--toasts-before":C,"--z-index":N.length-C,"--offset":`${fe?Se:me.current}px`,"--initial-height":V?"auto":`${ot}px`,...j,...p.style},onPointerDown:Q=>{xa||!ne||(Ye.current=new Date,Ae(me.current),Q.target.setPointerCapture(Q.pointerId),Q.target.tagName!=="BUTTON"&&(se(!0),Je.current={x:Q.clientX,y:Q.clientY}))},onPointerUp:()=>{var Q,le,pe,Be;if(te||!ne)return;Je.current=null;let Ze=Number(((Q=at.current)==null?void 0:Q.style.getPropertyValue("--swipe-amount").replace("px",""))||0),Eo=new Date().getTime()-((le=Ye.current)==null?void 0:le.getTime()),h0=Math.abs(Ze)/Eo;if(Math.abs(Ze)>=Yw||h0>.11){Ae(me.current),(pe=p.onDismiss)==null||pe.call(p,p),yt(),re(!0),ye(!1);return}(Be=at.current)==null||Be.style.setProperty("--swipe-amount","0px"),se(!1)},onPointerMove:Q=>{var le,pe;if(!Je.current||!ne)return;let Be=Q.clientY-Je.current.y,Ze=((le=window.getSelection())==null?void 0:le.toString().length)>0,Eo=Ve==="top"?Math.min(0,Be):Math.max(0,Be);Math.abs(Eo)>0&&ye(!0),!Ze&&((pe=at.current)==null||pe.style.setProperty("--swipe-amount",`${Eo}px`))}},$e&&!p.jsx?S.createElement("button",{"aria-label":Z,"data-disabled":xa,"data-close-button":!0,onClick:xa||!ne?()=>{}:()=>{var Q;yt(),(Q=p.onDismiss)==null||Q.call(p,p)},className:K(T==null?void 0:T.closeButton,(r=p==null?void 0:p.classNames)==null?void 0:r.closeButton)},(a=H==null?void 0:H.close)!=null?a:Dw):null,p.jsx||S.isValidElement(p.title)?p.jsx?p.jsx:typeof p.title=="function"?p.title():p.title:S.createElement(S.Fragment,null,D||p.icon||p.promise?S.createElement("div",{"data-icon":"",className:K(T==null?void 0:T.icon,(s=p==null?void 0:p.classNames)==null?void 0:s.icon)},p.promise||p.type==="loading"&&!p.icon?p.icon||g0():null,p.type!=="loading"?p.icon||(H==null?void 0:H[D])||Mw(D):null):null,S.createElement("div",{"data-content":"",className:K(T==null?void 0:T.content,(i=p==null?void 0:p.classNames)==null?void 0:i.content)},S.createElement("div",{"data-title":"",className:K(T==null?void 0:T.title,(u=p==null?void 0:p.classNames)==null?void 0:u.title)},typeof p.title=="function"?p.title():p.title),p.description?S.createElement("div",{"data-description":"",className:K(U,de,T==null?void 0:T.description,(d=p==null?void 0:p.classNames)==null?void 0:d.description)},typeof p.description=="function"?p.description():p.description):null),S.isValidElement(p.cancel)?p.cancel:p.cancel&&yo(p.cancel)?S.createElement("button",{"data-button":!0,"data-cancel":!0,style:p.cancelButtonStyle||B,onClick:Q=>{var le,pe;yo(p.cancel)&&ne&&((pe=(le=p.cancel).onClick)==null||pe.call(le,Q),yt())},className:K(T==null?void 0:T.cancelButton,(f=p==null?void 0:p.classNames)==null?void 0:f.cancelButton)},p.cancel.label):null,S.isValidElement(p.action)?p.action:p.action&&yo(p.action)?S.createElement("button",{"data-button":!0,"data-action":!0,style:p.actionButtonStyle||z,onClick:Q=>{var le,pe;yo(p.action)&&((pe=(le=p.action).onClick)==null||pe.call(le,Q),!Q.defaultPrevented&&yt())},className:K(T==null?void 0:T.actionButton,(m=p==null?void 0:p.classNames)==null?void 0:m.actionButton)},p.action.label):null))};function wf(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}var Zw=S.forwardRef(function(e,t){let{invert:n,position:o="bottom-right",hotkey:r=["altKey","KeyT"],expand:a,closeButton:s,className:i,offset:u,theme:d="light",richColors:f,duration:m,style:h,visibleToasts:p=Gw,toastOptions:b,dir:g=wf(),gap:v=Kw,loadingIcon:y,icons:w,containerAriaLabel:C="Notifications",pauseWhenPageIsHidden:N,cn:E=qw}=e,[A,M]=S.useState([]),I=S.useMemo(()=>Array.from(new Set([o].concat(A.filter(X=>X.position).map(X=>X.position)))),[A,o]),[j,B]=S.useState([]),[z,O]=S.useState(!1),[U,W]=S.useState(!1),[oe,$]=S.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),G=S.useRef(null),V=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),T=S.useRef(null),H=S.useRef(!1),Z=S.useCallback(X=>{M(K=>{var q;return(q=K.find(ce=>ce.id===X.id))!=null&&q.delete||Re.dismiss(X.id),K.filter(({id:ce})=>ce!==X.id)})},[]);return S.useEffect(()=>Re.subscribe(X=>{if(X.dismiss){M(K=>K.map(q=>q.id===X.id?{...q,delete:!0}:q));return}setTimeout(()=>{En.flushSync(()=>{M(K=>{let q=K.findIndex(ce=>ce.id===X.id);return q!==-1?[...K.slice(0,q),{...K[q],...X},...K.slice(q+1)]:[X,...K]})})})}),[]),S.useEffect(()=>{if(d!=="system"){$(d);return}if(d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?$("dark"):$("light")),typeof window>"u")return;let X=window.matchMedia("(prefers-color-scheme: dark)");try{X.addEventListener("change",({matches:K})=>{$(K?"dark":"light")})}catch{X.addListener(({matches:q})=>{try{$(q?"dark":"light")}catch(ce){console.error(ce)}})}},[d]),S.useEffect(()=>{A.length<=1&&O(!1)},[A]),S.useEffect(()=>{let X=K=>{var q,ce;r.every(fe=>K[fe]||K.code===fe)&&(O(!0),(q=G.current)==null||q.focus()),K.code==="Escape"&&(document.activeElement===G.current||(ce=G.current)!=null&&ce.contains(document.activeElement))&&O(!1)};return document.addEventListener("keydown",X),()=>document.removeEventListener("keydown",X)},[r]),S.useEffect(()=>{if(G.current)return()=>{T.current&&(T.current.focus({preventScroll:!0}),T.current=null,H.current=!1)}},[G.current]),S.createElement("section",{"aria-label":`${C} ${V}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false"},I.map((X,K)=>{var q;let[ce,fe]=X.split("-");return A.length?S.createElement("ol",{key:X,dir:g==="auto"?wf():g,tabIndex:-1,ref:G,className:i,"data-sonner-toaster":!0,"data-theme":oe,"data-y-position":ce,"data-lifted":z&&A.length>1&&!a,"data-x-position":fe,style:{"--front-toast-height":`${((q=j[0])==null?void 0:q.height)||0}px`,"--offset":typeof u=="number"?`${u}px`:u||Hw,"--width":`${Uw}px`,"--gap":`${v}px`,...h},onBlur:k=>{H.current&&!k.currentTarget.contains(k.relatedTarget)&&(H.current=!1,T.current&&(T.current.focus({preventScroll:!0}),T.current=null))},onFocus:k=>{k.target instanceof HTMLElement&&k.target.dataset.dismissible==="false"||H.current||(H.current=!0,T.current=k.relatedTarget)},onMouseEnter:()=>O(!0),onMouseMove:()=>O(!0),onMouseLeave:()=>{U||O(!1)},onPointerDown:k=>{k.target instanceof HTMLElement&&k.target.dataset.dismissible==="false"||W(!0)},onPointerUp:()=>W(!1)},A.filter(k=>!k.position&&K===0||k.position===X).map((k,ae)=>{var se,te;return S.createElement(Jw,{key:k.id,icons:w,index:ae,toast:k,defaultRichColors:f,duration:(se=b==null?void 0:b.duration)!=null?se:m,className:b==null?void 0:b.className,descriptionClassName:b==null?void 0:b.descriptionClassName,invert:n,visibleToasts:p,closeButton:(te=b==null?void 0:b.closeButton)!=null?te:s,interacting:U,position:X,style:b==null?void 0:b.style,unstyled:b==null?void 0:b.unstyled,classNames:b==null?void 0:b.classNames,cancelButtonStyle:b==null?void 0:b.cancelButtonStyle,actionButtonStyle:b==null?void 0:b.actionButtonStyle,removeToast:Z,toasts:A.filter(re=>re.position==k.position),heights:j.filter(re=>re.position==k.position),setHeights:B,expandByDefault:a,gap:v,loadingIcon:y,expanded:z,pauseWhenPageIsHidden:N,cn:E})})):null}))});const Qw=({...e})=>c.jsx(Zw,{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 ex="Toggle",fa=l.forwardRef((e,t)=>{const{pressed:n,defaultPressed:o=!1,onPressedChange:r,...a}=e,[s=!1,i]=Ce({prop:n,onChange:r,defaultProp:o});return c.jsx(L.button,{type:"button","aria-pressed":s,"data-state":s?"on":"off","data-disabled":e.disabled?"":void 0,...a,ref:t,onClick:_(e.onClick,()=>{e.disabled||i(!s)})})});fa.displayName=ex;var xf=fa;const pa=Mt("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"}}),Cf=l.forwardRef(({className:e,variant:t,size:n,...o},r)=>c.jsx(xf,{ref:r,className:R(pa({variant:t,size:n,className:e})),...o}));Cf.displayName=xf.displayName;var zt="ToggleGroup",[Nf,R0]=ve(zt,[gt]),Ef=gt(),ma=S.forwardRef((e,t)=>{const{type:n,...o}=e;if(n==="single"){const r=o;return c.jsx(tx,{...r,ref:t})}if(n==="multiple"){const r=o;return c.jsx(nx,{...r,ref:t})}throw new Error(`Missing prop \`type\` expected on \`${zt}\``)});ma.displayName=zt;var[Sf,Pf]=Nf(zt),tx=S.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},...a}=e,[s,i]=Ce({prop:n,defaultProp:o,onChange:r});return c.jsx(Sf,{scope:e.__scopeToggleGroup,type:"single",value:s?[s]:[],onItemActivate:i,onItemDeactivate:S.useCallback(()=>i(""),[i]),children:c.jsx(Tf,{...a,ref:t})})}),nx=S.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},...a}=e,[s=[],i]=Ce({prop:n,defaultProp:o,onChange:r}),u=S.useCallback(f=>i((m=[])=>[...m,f]),[i]),d=S.useCallback(f=>i((m=[])=>m.filter(h=>h!==f)),[i]);return c.jsx(Sf,{scope:e.__scopeToggleGroup,type:"multiple",value:s,onItemActivate:u,onItemDeactivate:d,children:c.jsx(Tf,{...a,ref:t})})});ma.displayName=zt;var[ox,rx]=Nf(zt),Tf=S.forwardRef((e,t)=>{const{__scopeToggleGroup:n,disabled:o=!1,rovingFocus:r=!0,orientation:a,dir:s,loop:i=!0,...u}=e,d=Ef(n),f=Nt(s),m={role:"group",dir:f,...u};return c.jsx(ox,{scope:n,rovingFocus:r,disabled:o,children:r?c.jsx(ao,{asChild:!0,...d,orientation:a,dir:f,loop:i,children:c.jsx(L.div,{...m,ref:t})}):c.jsx(L.div,{...m,ref:t})})}),wo="ToggleGroupItem",Mf=S.forwardRef((e,t)=>{const n=Pf(wo,e.__scopeToggleGroup),o=rx(wo,e.__scopeToggleGroup),r=Ef(e.__scopeToggleGroup),a=n.value.includes(e.value),s=o.disabled||e.disabled,i={...e,pressed:a,disabled:s},u=S.useRef(null);return o.rovingFocus?c.jsx(so,{asChild:!0,...r,focusable:!s,active:a,ref:u,children:c.jsx(Rf,{...i,ref:t})}):c.jsx(Rf,{...i,ref:t})});Mf.displayName=wo;var Rf=S.forwardRef((e,t)=>{const{__scopeToggleGroup:n,value:o,...r}=e,a=Pf(wo,n),s={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},i=a.type==="single"?s:void 0;return c.jsx(fa,{...i,...r,ref:t,onPressedChange:u=>{u?a.onItemActivate(o):a.onItemDeactivate(o)}})}),Af=ma,_f=Mf;const If=l.createContext({size:"default",variant:"default"}),kf=l.forwardRef(({className:e,variant:t,size:n,children:o,...r},a)=>c.jsx(Af,{ref:a,className:R("flex items-center justify-center gap-1",e),...r,children:c.jsx(If.Provider,{value:{variant:t,size:n},children:o})}));kf.displayName=Af.displayName;const jf=l.forwardRef(({className:e,children:t,variant:n,size:o,...r},a)=>{const s=l.useContext(If);return c.jsx(_f,{ref:a,className:R(pa({variant:s.variant||n,size:s.size||o}),e),...r,children:t})});jf.displayName=_f.displayName;var[xo,A0]=ve("Tooltip",[ft]),Co=ft(),Df="TooltipProvider",ax=700,ga="tooltip.open",[sx,ha]=xo(Df),Of=e=>{const{__scopeTooltip:t,delayDuration:n=ax,skipDelayDuration:o=300,disableHoverableContent:r=!1,children:a}=e,[s,i]=l.useState(!0),u=l.useRef(!1),d=l.useRef(0);return l.useEffect(()=>{const f=d.current;return()=>window.clearTimeout(f)},[]),c.jsx(sx,{scope:t,isOpenDelayed:s,delayDuration:n,onOpen:l.useCallback(()=>{window.clearTimeout(d.current),i(!1)},[]),onClose:l.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>i(!0),o)},[o]),isPointerInTransitRef:u,onPointerInTransitChange:l.useCallback(f=>{u.current=f},[]),disableHoverableContent:r,children:a})};Of.displayName=Df;var No="Tooltip",[ix,xn]=xo(No),Lf=e=>{const{__scopeTooltip:t,children:n,open:o,defaultOpen:r=!1,onOpenChange:a,disableHoverableContent:s,delayDuration:i}=e,u=ha(No,e.__scopeTooltip),d=Co(t),[f,m]=l.useState(null),h=Ne(),p=l.useRef(0),b=s??u.disableHoverableContent,g=i??u.delayDuration,v=l.useRef(!1),[y=!1,w]=Ce({prop:o,defaultProp:r,onChange:M=>{M?(u.onOpen(),document.dispatchEvent(new CustomEvent(ga))):u.onClose(),a==null||a(M)}}),C=l.useMemo(()=>y?v.current?"delayed-open":"instant-open":"closed",[y]),N=l.useCallback(()=>{window.clearTimeout(p.current),p.current=0,v.current=!1,w(!0)},[w]),E=l.useCallback(()=>{window.clearTimeout(p.current),p.current=0,w(!1)},[w]),A=l.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{v.current=!0,w(!0),p.current=0},g)},[g,w]);return l.useEffect(()=>()=>{p.current&&(window.clearTimeout(p.current),p.current=0)},[]),c.jsx(rn,{...d,children:c.jsx(ix,{scope:t,contentId:h,open:y,stateAttribute:C,trigger:f,onTriggerChange:m,onTriggerEnter:l.useCallback(()=>{u.isOpenDelayed?A():N()},[u.isOpenDelayed,A,N]),onTriggerLeave:l.useCallback(()=>{b?E():(window.clearTimeout(p.current),p.current=0)},[E,b]),onOpen:N,onClose:E,disableHoverableContent:b,children:n})})};Lf.displayName=No;var va="TooltipTrigger",Ff=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=xn(va,n),a=ha(va,n),s=Co(n),i=l.useRef(null),u=J(t,i,r.onTriggerChange),d=l.useRef(!1),f=l.useRef(!1),m=l.useCallback(()=>d.current=!1,[]);return l.useEffect(()=>()=>document.removeEventListener("pointerup",m),[m]),c.jsx(an,{asChild:!0,...s,children:c.jsx(L.button,{"aria-describedby":r.open?r.contentId:void 0,"data-state":r.stateAttribute,...o,ref:u,onPointerMove:_(e.onPointerMove,h=>{h.pointerType!=="touch"&&!f.current&&!a.isPointerInTransitRef.current&&(r.onTriggerEnter(),f.current=!0)}),onPointerLeave:_(e.onPointerLeave,()=>{r.onTriggerLeave(),f.current=!1}),onPointerDown:_(e.onPointerDown,()=>{d.current=!0,document.addEventListener("pointerup",m,{once:!0})}),onFocus:_(e.onFocus,()=>{d.current||r.onOpen()}),onBlur:_(e.onBlur,r.onClose),onClick:_(e.onClick,r.onClose)})})});Ff.displayName=va;var ba="TooltipPortal",[lx,cx]=xo(ba,{forceMount:void 0}),$f=e=>{const{__scopeTooltip:t,forceMount:n,children:o,container:r}=e,a=xn(ba,t);return c.jsx(lx,{scope:t,forceMount:n,children:c.jsx(be,{present:n||a.open,children:c.jsx(Zt,{asChild:!0,container:r,children:o})})})};$f.displayName=ba;var Gt="TooltipContent",Vf=l.forwardRef((e,t)=>{const n=cx(Gt,e.__scopeTooltip),{forceMount:o=n.forceMount,side:r="top",...a}=e,s=xn(Gt,e.__scopeTooltip);return c.jsx(be,{present:o||s.open,children:s.disableHoverableContent?c.jsx(Bf,{side:r,...a,ref:t}):c.jsx(ux,{side:r,...a,ref:t})})}),ux=l.forwardRef((e,t)=>{const n=xn(Gt,e.__scopeTooltip),o=ha(Gt,e.__scopeTooltip),r=l.useRef(null),a=J(t,r),[s,i]=l.useState(null),{trigger:u,onClose:d}=n,f=r.current,{onPointerInTransitChange:m}=o,h=l.useCallback(()=>{i(null),m(!1)},[m]),p=l.useCallback((b,g)=>{const v=b.currentTarget,y={x:b.clientX,y:b.clientY},w=mx(y,v.getBoundingClientRect()),C=gx(y,w),N=hx(g.getBoundingClientRect()),E=bx([...C,...N]);i(E),m(!0)},[m]);return l.useEffect(()=>()=>h(),[h]),l.useEffect(()=>{if(u&&f){const b=v=>p(v,f),g=v=>p(v,u);return u.addEventListener("pointerleave",b),f.addEventListener("pointerleave",g),()=>{u.removeEventListener("pointerleave",b),f.removeEventListener("pointerleave",g)}}},[u,f,p,h]),l.useEffect(()=>{if(s){const b=g=>{const v=g.target,y={x:g.clientX,y:g.clientY},w=(u==null?void 0:u.contains(v))||(f==null?void 0:f.contains(v)),C=!vx(y,s);w?h():C&&(h(),d())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[u,f,s,d,h]),c.jsx(Bf,{...e,ref:a})}),[dx,fx]=xo(No,{isInside:!1}),Bf=l.forwardRef((e,t)=>{const{__scopeTooltip:n,children:o,"aria-label":r,onEscapeKeyDown:a,onPointerDownOutside:s,...i}=e,u=xn(Gt,n),d=Co(n),{onClose:f}=u;return l.useEffect(()=>(document.addEventListener(ga,f),()=>document.removeEventListener(ga,f)),[f]),l.useEffect(()=>{if(u.trigger){const m=h=>{const p=h.target;p!=null&&p.contains(u.trigger)&&f()};return window.addEventListener("scroll",m,{capture:!0}),()=>window.removeEventListener("scroll",m,{capture:!0})}},[u.trigger,f]),c.jsx(wt,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:m=>m.preventDefault(),onDismiss:f,children:c.jsxs(Zn,{"data-state":u.stateAttribute,...d,...i,ref:t,style:{...i.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:[c.jsx(Ro,{children:o}),c.jsx(dx,{scope:n,isInside:!0,children:c.jsx(Jc,{id:u.contentId,role:"tooltip",children:r||o})})]})})});Vf.displayName=Gt;var Wf="TooltipArrow",px=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=Co(n);return fx(Wf,n).isInside?null:c.jsx(Qn,{...r,...o,ref:t})});px.displayName=Wf;function mx(e,t){const n=Math.abs(t.top-e.y),o=Math.abs(t.bottom-e.y),r=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,o,r,a)){case a:return"left";case r:return"right";case n:return"top";case o:return"bottom";default:throw new Error("unreachable")}}function gx(e,t,n=5){const o=[];switch(t){case"top":o.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":o.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":o.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":o.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return o}function hx(e){const{top:t,right:n,bottom:o,left:r}=e;return[{x:r,y:t},{x:n,y:t},{x:n,y:o},{x:r,y:o}]}function vx(e,t){const{x:n,y:o}=e;let r=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a].x,u=t[a].y,d=t[s].x,f=t[s].y;u>o!=f>o&&n<(d-i)*(o-u)/(f-u)+i&&(r=!r)}return r}function bx(e){const t=e.slice();return t.sort((n,o)=>n.x<o.x?-1:n.x>o.x?1:n.y<o.y?-1:n.y>o.y?1:0),yx(t)}function yx(e){if(e.length<=1)return e.slice();const t=[];for(let o=0;o<e.length;o++){const r=e[o];for(;t.length>=2;){const a=t[t.length-1],s=t[t.length-2];if((a.x-s.x)*(r.y-s.y)>=(a.y-s.y)*(r.x-s.x))t.pop();else break}t.push(r)}t.pop();const n=[];for(let o=e.length-1;o>=0;o--){const r=e[o];for(;n.length>=2;){const a=n[n.length-1],s=n[n.length-2];if((a.x-s.x)*(r.y-s.y)>=(a.y-s.y)*(r.x-s.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var wx=Of,xx=Lf,Cx=Ff,Nx=$f,zf=Vf;const Ex=wx,Sx=xx,Px=Cx,Gf=l.forwardRef(({className:e,sideOffset:t=4,...n},o)=>c.jsx(Nx,{children:c.jsx(zf,{ref:o,sideOffset:t,className:R("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",e),...n})}));Gf.displayName=zf.displayName;function Tx(e){const{triggerElement:t,steps:n}=e,[o,r]=S.useState(!1),[a,s]=S.useState(0),i=()=>{s(d=>d<n.length-1?d+1:d)},u=()=>{s(d=>d>0?d-1:d)};return c.jsxs(hr,{open:o,onOpenChange:r,children:[c.jsx(vl,{asChild:!0,children:t}),c.jsxs(eo,{className:"sm:max-w-[425px]",children:[c.jsxs(to,{className:R(n[a].title===""&&"sr-only"),children:[c.jsx(no,{children:n[a].title}),c.jsx(oo,{className:"sr-only",children:n[a].title})]}),c.jsx("div",{children:n[a].description}),c.jsxs("div",{className:"flex items-center justify-between mt-4",children:[c.jsx(Ge,{variant:"ghost",size:"icon",onClick:u,disabled:a===0,children:c.jsx(ti,{className:"h-4 w-4"})}),c.jsx("div",{className:"flex justify-center gap-1",children:n.map((d,f)=>c.jsx("div",{className:R("h-3 w-3 rounded-full",f===a?"bg-primary":"bg-gray-200")},f))}),c.jsx(Ge,{variant:"ghost",size:"icon",onClick:i,disabled:a===n.length-1,children:c.jsx(qo,{className:"h-4 w-4"})})]})]})]})}function ya(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}function Cn(e){return(t,n)=>{const o=n!=null&&n.context?String(n.context):"standalone";let r;if(o==="formatting"&&e.formattingValues){const s=e.defaultFormattingWidth||e.defaultWidth,i=n!=null&&n.width?String(n.width):s;r=e.formattingValues[i]||e.formattingValues[s]}else{const s=e.defaultWidth,i=n!=null&&n.width?String(n.width):e.defaultWidth;r=e.values[i]||e.values[s]}const a=e.argumentCallback?e.argumentCallback(t):t;return r[a]}}function Nn(e){return(t,n={})=>{const o=n.width,r=o&&e.matchPatterns[o]||e.matchPatterns[e.defaultMatchWidth],a=t.match(r);if(!a)return null;const s=a[0],i=o&&e.parsePatterns[o]||e.parsePatterns[e.defaultParseWidth],u=Array.isArray(i)?Rx(i,m=>m.test(s)):Mx(i,m=>m.test(s));let d;d=e.valueCallback?e.valueCallback(u):u,d=n.valueCallback?n.valueCallback(d):d;const f=t.slice(s.length);return{value:d,rest:f}}}function Mx(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function Rx(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function Ax(e){return(t,n={})=>{const o=t.match(e.matchPattern);if(!o)return null;const r=o[0],a=t.match(e.parsePattern);if(!a)return null;let s=e.valueCallback?e.valueCallback(a[0]):a[0];s=n.valueCallback?n.valueCallback(s):s;const i=t.slice(r.length);return{value:s,rest:i}}}const _x={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Ix=(e,t,n)=>{let o;const r=_x[e];return typeof r=="string"?o=r:t===1?o=r.one:o=r.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+o:o+" ago":o},kx={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},jx=(e,t,n,o)=>kx[e],Dx={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Ox={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Lx={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Fx={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},$x={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},Vx={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Bx={ordinalNumber:(e,t)=>{const n=Number(e),o=n%100;if(o>20||o<10)switch(o%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:Cn({values:Dx,defaultWidth:"wide"}),quarter:Cn({values:Ox,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Cn({values:Lx,defaultWidth:"wide"}),day:Cn({values:Fx,defaultWidth:"wide"}),dayPeriod:Cn({values:$x,defaultWidth:"wide",formattingValues:Vx,defaultFormattingWidth:"wide"})},Wx=/^(\d+)(th|st|nd|rd)?/i,zx=/\d+/i,Gx={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},Hx={any:[/^b/i,/^(a|c)/i]},Ux={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Kx={any:[/1/i,/2/i,/3/i,/4/i]},Yx={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Xx={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},qx={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Jx={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Zx={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Qx={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},e0={ordinalNumber:Ax({matchPattern:Wx,parsePattern:zx,valueCallback:e=>parseInt(e,10)}),era:Nn({matchPatterns:Gx,defaultMatchWidth:"wide",parsePatterns:Hx,defaultParseWidth:"any"}),quarter:Nn({matchPatterns:Ux,defaultMatchWidth:"wide",parsePatterns:Kx,defaultParseWidth:"any",valueCallback:e=>e+1}),month:Nn({matchPatterns:Yx,defaultMatchWidth:"wide",parsePatterns:Xx,defaultParseWidth:"any"}),day:Nn({matchPatterns:qx,defaultMatchWidth:"wide",parsePatterns:Jx,defaultParseWidth:"any"}),dayPeriod:Nn({matchPatterns:Zx,defaultMatchWidth:"any",parsePatterns:Qx,defaultParseWidth:"any"})},t0={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},n0={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},o0={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},r0={date:ya({formats:t0,defaultWidth:"full"}),time:ya({formats:n0,defaultWidth:"full"}),dateTime:ya({formats:o0,defaultWidth:"full"})},a0={code:"en-US",formatDistance:Ix,formatLong:r0,formatRelative:jx,localize:Bx,match:e0,options:{weekStartsOn:0,firstWeekContainsDate:1}},s0=e=>{const{currentMonth:t,currentYear:n,onChangeMonthYear:o,locale:r=a0}=e,a=s=>{let i=t,u=n;s==="prev"?i===0?(i=11,u--):i--:i===11?(i=0,u++):i++,o(i,u)};return c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx(Ge,{variant:"ghost",size:"icon",onClick:()=>a("prev"),"aria-label":"Previous month",children:c.jsx(Ng,{className:"!h-8 !w-8"})}),c.jsxs("div",{className:"text-center",children:[c.jsx("h2",{className:"text-2xl font-bold capitalize",children:r.localize.month(t,{width:"wide"})}),c.jsx("p",{className:"text-sm text-muted-foreground",children:n})]}),c.jsx(Ge,{variant:"ghost",size:"icon",onClick:()=>a("next"),"aria-label":"Next month",children:c.jsx(Eg,{className:"!h-8 !w-8"})})]})};function i0({currentPage:e,totalPages:t,onPageChange:n}){const o=Array.from({length:t},(r,a)=>a+1);return c.jsx(Hr,{children:c.jsxs(Ur,{children:[c.jsx(vn,{children:c.jsx(Kr,{onClick:()=>n(Math.max(1,e-1)),disabled:e===1})}),o.map(r=>c.jsx(vn,{children:c.jsx(bn,{onClick:()=>n(r),isActive:e===r,children:r})},r)),c.jsx(vn,{children:c.jsx(Yr,{onClick:()=>n(Math.min(t,e+1)),disabled:e===t})})]})})}function l0(e,t=250){const[n,o]=S.useState(e);return S.useEffect(()=>{const r=setTimeout(()=>{o(e)},t);return()=>{clearTimeout(r)}},[e,t]),n}const Hf=l.createContext(void 0),Uf={sm:"sm:max-w-[425px]",md:"sm:max-w-[550px]",lg:"sm:max-w-[700px]",xl:"sm:max-w-[900px]"},Kf={info:{icon:Ig,className:"text-blue-500"},success:{icon:Tg,className:"text-green-500"},error:{icon:Mg,className:"text-red-500"},warning:{icon:Pg,className:"text-yellow-500"},confirm:{icon:ni,className:"text-blue-500"},custom:{icon:ni,className:"text-gray-500"}};function c0({children:e}){var p,b,g;const[t,n]=l.useState({isOpen:!1,options:null}),o=l.useCallback(v=>{n({isOpen:!0,options:v})},[]),r=l.useCallback(()=>{n(v=>({...v,isOpen:!1}))},[]),a=l.useCallback(v=>{o({...v,type:"info"})},[o]),s=l.useCallback(v=>{o({...v,type:"success"})},[o]),i=l.useCallback(v=>{o({...v,type:"error"})},[o]),u=l.useCallback(v=>{o({...v,type:"warning"})},[o]),d=l.useCallback(v=>{o({...v,type:"custom"})},[o]),f=l.useCallback(v=>{o({...v,type:"confirm"})},[o]),m=(v,y)=>{let w=Kf[v].icon;return y&&(w=y),c.jsx(w,{className:R("h-24 w-24",Kf[v].className)})},h=l.useMemo(()=>({open:o,close:r,info:a,success:s,error:i,warning:u,custom:d,confirm:f}),[o,r,a,s,i,u,d,f]);return c.jsxs(Hf.Provider,{value:h,children:[e,c.jsx(hr,{open:t.isOpen,onOpenChange:v=>!v&&r(),modal:!0,children:c.jsxs(eo,{className:R((p=t.options)!=null&&p.size?Uf[t.options.size]:Uf.sm,(b=t.options)==null?void 0:b.className),children:[t.options&&c.jsxs(to,{children:[c.jsx("div",{className:"mx-auto mb-6",children:m(t.options.type,t.options.icon)}),t.options.title&&c.jsx(no,{className:"text-center",children:t.options.title}),c.jsx(oo,{className:"text-center",children:t.options.message})]}),((g=t.options)==null?void 0:g.type)==="confirm"&&c.jsxs("div",{className:"flex justify-center gap-4 mt-4",children:[c.jsx(Ge,{onClick:()=>{var v,y;(y=(v=t.options)==null?void 0:v.onConfirm)==null||y.call(v),r()},children:t.options.confirmLabel||"Confirm"}),t.options.displayCancel&&c.jsx(Ge,{variant:"outline",onClick:r,children:t.options.cancelLabel||"Cancel"})]})]})})]})}function u0(){const e=l.useContext(Hf);if(e===void 0)throw new Error("useDialog must be used within a DialogProvider");return e}function d0(e){const[t,n]=S.useState(!1);return S.useEffect(()=>{const o=window.matchMedia(e);o.matches!==t&&n(o.matches);const r=()=>n(o.matches);return window.addEventListener("resize",r),()=>window.removeEventListener("resize",r)},[t,e]),t}const wa=768;function f0(){const[e,t]=l.useState(void 0);return l.useEffect(()=>{const n=window.matchMedia(`(max-width: ${wa-1}px)`),o=()=>{t(window.innerWidth<wa)};return n.addEventListener("change",o),t(window.innerWidth<wa),()=>n.removeEventListener("change",o)},[]),!!e}const p0=()=>{const[e,t]=S.useState(null),[n,o]=S.useState(!1);return S.useEffect(()=>((()=>{const s=window.matchMedia("(display-mode: standalone)").matches||window.navigator.standalone;o(s)})(),window.addEventListener("beforeinstallprompt",s=>{s.preventDefault(),t(s)}),window.addEventListener("appinstalled",()=>{o(!0)}),()=>{window.removeEventListener("appinstalled",()=>o(!0))}),[]),{isPromptReady:!!e,isInstalled:n,showInstallPrompt:()=>{e&&(e.prompt(),e.userChoice.then(a=>{console.log(`User choice: ${a.outcome}`),t(null)}))}}};P.AdaptiveInput=Mn,P.AlertDialog=bg,P.AlertDialogAction=Zs,P.AlertDialogCancel=Qs,P.AlertDialogContent=Ks,P.AlertDialogDescription=Js,P.AlertDialogFooter=Xs,P.AlertDialogHeader=Ys,P.AlertDialogOverlay=Ko,P.AlertDialogPortal=Us,P.AlertDialogTitle=qs,P.AlertDialogTrigger=yg,P.Autocomplete=Qh,P.Avatar=el,P.AvatarFallback=nl,P.AvatarImage=tl,P.Badge=ov,P.Button=Ge,P.Card=rl,P.CardContent=ll,P.CardDescription=il,P.CardFooter=cl,P.CardHeader=al,P.CardTitle=sl,P.Checkbox=gl,P.CurrencyInput=hl,P.Dialog=hr,P.DialogClose=cv,P.DialogContent=eo,P.DialogDescription=oo,P.DialogFooter=yl,P.DialogHeader=to,P.DialogOverlay=vr,P.DialogPortal=bl,P.DialogProvider=c0,P.DialogTitle=no,P.DialogTrigger=vl,P.DropdownMenu=Ab,P.DropdownMenuCheckboxItem=Mc,P.DropdownMenuContent=Pc,P.DropdownMenuGroup=Ib,P.DropdownMenuItem=Tc,P.DropdownMenuLabel=Ac,P.DropdownMenuPortal=kb,P.DropdownMenuRadioGroup=Db,P.DropdownMenuRadioItem=Rc,P.DropdownMenuSeparator=_c,P.DropdownMenuShortcut=Ic,P.DropdownMenuSub=jb,P.DropdownMenuSubContent=Sc,P.DropdownMenuSubTrigger=Ec,P.DropdownMenuTrigger=_b,P.Form=ay,P.FormControl=Yc,P.FormDescription=Xc,P.FormField=sy,P.FormItem=Uc,P.FormLabel=Kc,P.FormMessage=qc,P.HelpCarousel=Tx,P.Input=Tn,P.Label=Ir,P.MonthNavigator=s0,P.NavigationMenu=Su,P.NavigationMenuContent=Ru,P.NavigationMenuIndicator=Au,P.NavigationMenuItem=Sy,P.NavigationMenuLink=Py,P.NavigationMenuList=Pu,P.NavigationMenuTrigger=Mu,P.NavigationMenuViewport=Gr,P.Pagination=Hr,P.PaginationContent=Ur,P.PaginationControls=i0,P.PaginationEllipsis=_u,P.PaginationItem=vn,P.PaginationLink=bn,P.PaginationNext=Yr,P.PaginationPrevious=Kr,P.PasswordInput=jy,P.Popover=zi,P.PopoverAnchor=Zh,P.PopoverContent=pr,P.PopoverTrigger=Gi,P.Progress=Jr,P.RadioGroup=Zu,P.RadioGroupItem=Qu,P.Select=gw,P.SelectContent=Ld,P.SelectGroup=hw,P.SelectItem=$d,P.SelectLabel=Fd,P.SelectScrollDownButton=ia,P.SelectScrollUpButton=sa,P.SelectSeparator=Vd,P.SelectTrigger=Od,P.SelectValue=vw,P.Skeleton=bw,P.Switch=Ud,P.Table=Kd,P.TableBody=Xd,P.TableCaption=ef,P.TableCell=Qd,P.TableFooter=qd,P.TableHead=Zd,P.TableHeader=Yd,P.TableRow=Jd,P.Tabs=Tw,P.TabsContent=vf,P.TabsList=gf,P.TabsTrigger=hf,P.Textarea=bf,P.Toaster=Qw,P.Toggle=Cf,P.ToggleGroup=kf,P.ToggleGroupItem=jf,P.Tooltip=Sx,P.TooltipContent=Gf,P.TooltipProvider=Ex,P.TooltipTrigger=Px,P.badgeVariants=ol,P.buttonVariants=en,P.cn=R,P.formatCurrency=Rp,P.formatDateAndMonth=Ip,P.formatDateAndWeekday=Ap,P.formatDateAndWeekdayAndYear=_p,P.formatLongDate=kp,P.formatShortDate=jp,P.formatWeekDayAndShortDate=Op,P.getMonthYearFromISODate=Dp,P.navigationMenuTriggerStyle=Tu,P.toast=Ww,P.toggleVariants=pa,P.useDebounce=l0,P.useDialog=u0,P.useFormField=hn,P.useIsMobile=f0,P.useMediaQuery=d0,P.usePWAInstall=p0,Object.defineProperty(P,Symbol.toStringTag,{value:"Module"})});