@hot-updater/console 0.30.12 → 0.31.1

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.
Files changed (34) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/assets/BaseTanStackRouterDevtoolsPanel-Bmws3ikM-q5p5qKUx.js +486 -0
  3. package/.output/public/assets/FloatingTanStackRouterDevtools-B7vy70jP-Bzs2Gthe.js +1 -0
  4. package/.output/public/assets/clsx-CbprLf2V.js +1 -0
  5. package/.output/public/assets/dist-B5egZOkC.js +9 -0
  6. package/.output/public/assets/main-DrVuFR7r.js +10 -0
  7. package/.output/public/assets/preload-helper-C5ST2IKa.js +1 -0
  8. package/.output/public/assets/routes-C_bgs7kg.js +54 -0
  9. package/.output/public/assets/styles-DZ0tCVA1.css +2 -0
  10. package/.output/server/{__tanstack-start-server-fn-resolver-rXMsqALt.mjs → __tanstack-start-server-fn-resolver-5wPQ8bZ3.mjs} +19 -11
  11. package/.output/server/_chunks/ssr-renderer.mjs +2 -2
  12. package/.output/server/_libs/@tanstack/react-form+[...].mjs +5 -5
  13. package/.output/server/_libs/lucide-react.mjs +8 -1
  14. package/.output/server/_libs/unctx.mjs +1 -1
  15. package/.output/server/_ssr/{api-rpc-DYKuUgOh.mjs → api-rpc-BhBKhZqY.mjs} +61 -18
  16. package/.output/server/_ssr/{config.server-8YQWTTc0.mjs → config.server-xu3W-WAK.mjs} +3 -1
  17. package/.output/server/_ssr/deleteBundle-D4jF5HeY.mjs +96 -0
  18. package/.output/server/_ssr/dist-CRiLZLfa.mjs +120 -0
  19. package/.output/server/_ssr/getBundleChildren-DFqZ6XMp.mjs +58 -0
  20. package/.output/server/_ssr/{router-D-WWsYjv.mjs → router-SkApCyud.mjs} +57 -15
  21. package/.output/server/_ssr/{routes-DyUhibF4.mjs → routes-BSs-dv4D.mjs} +1120 -472
  22. package/.output/server/_ssr/{sidebar-DXng0IOP.mjs → sidebar-CgbtXkE2.mjs} +65 -85
  23. package/.output/server/_ssr/ssr.mjs +4 -4
  24. package/.output/server/_ssr/start-D0X4LIsd.mjs +4 -0
  25. package/.output/server/_ssr/storageProfile-wICk5nZZ.mjs +9 -0
  26. package/.output/server/{_tanstack-start-manifest_v-xpdCj2Ct.mjs → _tanstack-start-manifest_v-D2MqgD3d.mjs} +9 -4
  27. package/.output/server/index.mjs +70 -42
  28. package/package.json +10 -6
  29. package/.output/public/assets/dist-BKho179_.js +0 -53
  30. package/.output/public/assets/main-5MdOCmsM.js +0 -10
  31. package/.output/public/assets/routes-BmbL4goz.js +0 -10
  32. package/.output/public/assets/styles-M2W42JQb.css +0 -2
  33. package/.output/server/_ssr/deleteBundle-BiJvjt0k.mjs +0 -22
  34. package/.output/server/_ssr/start-DsRb6TkZ.mjs +0 -4
@@ -0,0 +1,9 @@
1
+ import{h as e,n as t,t as n}from"./clsx-CbprLf2V.js";var r=Object.create,i=Object.defineProperty,a=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,s=Object.getPrototypeOf,c=Object.prototype.hasOwnProperty,l=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),u=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var s=o(t),l=0,u=s.length,d;l<u;l++)d=s[l],!c.call(e,d)&&d!==n&&i(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(r=a(t,d))||r.enumerable});return e},d=(e,t,n)=>(n=e==null?{}:r(s(e)),u(t||!e||!e.__esModule?i(n,`default`,{value:e,enumerable:!0}):n,e)),f=l((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},E=Object.prototype.hasOwnProperty;function D(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function ee(e,t){return D(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function k(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var A=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?k(``+e.key):t.toString(36)}function M(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function N(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,N(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(A,`$&/`)+`/`),N(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=ee(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(A,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+j(a,u),c+=N(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+j(a,u++),c+=N(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return N(M(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function P(e,t,n){if(e==null)return e;var r=[],i=0;return N(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function F(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var I=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},te={map:P,forEach:function(e,t,n){P(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return P(e,function(){t++}),t},toArray:function(e){return P(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=te,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!E.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return D(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)E.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return D(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:F}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,I)}catch(e){I(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.4`})),p=l(((e,t)=>{t.exports=f()})),m=l((e=>{var t=p();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`)if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`)if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()},e.version=`19.2.4`})),h=l(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=m()})),g=l((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),_=l(((e,t)=>{t.exports=g()})),v=(e=>(e[e.None=0]=`None`,e[e.Mutable=1]=`Mutable`,e[e.Watching=2]=`Watching`,e[e.RecursedCheck=4]=`RecursedCheck`,e[e.Recursed=8]=`Recursed`,e[e.Dirty=16]=`Dirty`,e[e.Pending=32]=`Pending`,e))(v||{});function y({update:e,notify:t,unwatched:n}){return{link:r,unlink:i,propagate:a,checkDirty:o,shallowPropagate:s};function r(e,t,n){let r=t.depsTail;if(r!==void 0&&r.dep===e)return;let i=r===void 0?t.deps:r.nextDep;if(i!==void 0&&i.dep===e){i.version=n,t.depsTail=i;return}let a=e.subsTail;if(a!==void 0&&a.version===n&&a.sub===t)return;let o=t.depsTail=e.subsTail={version:n,dep:e,sub:t,prevDep:r,nextDep:i,prevSub:a,nextSub:void 0};i!==void 0&&(i.prevDep=o),r===void 0?t.deps=o:r.nextDep=o,a===void 0?e.subs=o:a.nextSub=o}function i(e,t=e.sub){let r=e.dep,i=e.prevDep,a=e.nextDep,o=e.nextSub,s=e.prevSub;return a===void 0?t.depsTail=i:a.prevDep=i,i===void 0?t.deps=a:i.nextDep=a,o===void 0?r.subsTail=s:o.prevSub=s,s===void 0?(r.subs=o)===void 0&&n(r):s.nextSub=o,a}function a(e){let n=e.nextSub,r;top:do{let i=e.sub,a=i.flags;if(a&60?a&12?a&4?!(a&48)&&c(e,i)?(i.flags=a|40,a&=1):a=0:i.flags=a&-9|32:a=0:i.flags=a|32,a&2&&t(i),a&1){let t=i.subs;if(t!==void 0){let i=(e=t).nextSub;i!==void 0&&(r={value:n,prev:r},n=i);continue}}if((e=n)!==void 0){n=e.nextSub;continue}for(;r!==void 0;)if(e=r.value,r=r.prev,e!==void 0){n=e.nextSub;continue top}break}while(!0)}function o(t,n){let r,i=0,a=!1;top:do{let o=t.dep,c=o.flags;if(n.flags&16)a=!0;else if((c&17)==17){if(e(o)){let e=o.subs;e.nextSub!==void 0&&s(e),a=!0}}else if((c&33)==33){(t.nextSub!==void 0||t.prevSub!==void 0)&&(r={value:t,prev:r}),t=o.deps,n=o,++i;continue}if(!a){let e=t.nextDep;if(e!==void 0){t=e;continue}}for(;i--;){let i=n.subs,o=i.nextSub!==void 0;if(o?(t=r.value,r=r.prev):t=i,a){if(e(n)){o&&s(i),n=t.sub;continue}a=!1}else n.flags&=-33;n=t.sub;let c=t.nextDep;if(c!==void 0){t=c;continue top}}return a}while(!0)}function s(e){do{let n=e.sub,r=n.flags;(r&48)==32&&(n.flags=r|16,(r&6)==2&&t(n))}while((e=e.nextSub)!==void 0)}function c(e,t){let n=t.depsTail;for(;n!==void 0;){if(n===e)return!0;n=n.prevDep}return!1}}var b=0,x=0,S=0,C=[],{link:w,unlink:E,propagate:D,checkDirty:ee,shallowPropagate:O}=y({update(e){return e.depsTail===void 0?N(e):M(e)},notify(e){let t=S,n=t;do if(C[t++]=e,e.flags&=-3,e=e.subs?.sub,e===void 0||!(e.flags&2))break;while(!0);for(S=t;n<--t;){let e=C[n];C[n++]=C[t],C[t]=e}},unwatched(e){e.flags&1?e.depsTail!==void 0&&(e.depsTail=void 0,e.flags=17,te(e)):I.call(e)}});function k(){return b}function A(){++b}function j(){--b||F()}function M(e){e.depsTail=void 0,e.flags=5;try{let t=e.value;return t!==(e.value=e.getter(t))}finally{e.flags&=-5,te(e)}}function N(e){return e.flags=1,e.currentValue!==(e.currentValue=e.pendingValue)}function P(e){let t=e.flags;if(t&16||t&32&&ee(e.deps,e)){e.depsTail=void 0,e.flags=6;try{e.fn()}finally{e.flags&=-5,te(e)}}else e.flags=2}function F(){try{for(;x<S;){let e=C[x];C[x++]=void 0,P(e)}}finally{for(;x<S;){let e=C[x];C[x++]=void 0,e.flags|=10}x=0,S=0}}function I(){this.depsTail=void 0,this.flags=0,te(this);let e=this.subs;e!==void 0&&E(e)}function te(e){let t=e.depsTail,n=t===void 0?e.deps:t.nextDep;for(;n!==void 0;)n=E(n,e)}function ne(e,t,n){let r=typeof e==`object`,i=r?e:void 0;return{next:(r?e.next:e)?.bind(i),error:(r?e.error:t)?.bind(i),complete:(r?e.complete:n)?.bind(i)}}var re=[],ie=0,{link:L,unlink:R,propagate:ae,checkDirty:oe,shallowPropagate:z}=y({update(e){return e._update()},notify(e){re[se++]=e,e.flags&=~v.Watching},unwatched(e){e.depsTail!==void 0&&(e.depsTail=void 0,e.flags=v.Mutable|v.Dirty,V(e))}}),B=0,se=0,ce;function V(e){let t=e.depsTail,n=t===void 0?e.deps:t.nextDep;for(;n!==void 0;)n=R(n,e)}function le(){if(!(k()>0)){for(;B<se;){let e=re[B];re[B++]=void 0,e.notify()}B=0,se=0}}function ue(e,t){let n=typeof e==`function`,r=e,i={_snapshot:n?void 0:e,subs:void 0,subsTail:void 0,deps:void 0,depsTail:void 0,flags:n?v.None:v.Mutable,get(){return ce!==void 0&&L(i,ce,ie),i._snapshot},subscribe(e){let t=ne(e),n={current:!1},r=de(()=>{i.get(),n.current?t.next?.(i._snapshot):n.current=!0});return{unsubscribe:()=>{r.stop()}}},_update(e){let a=ce,o=t?.compare??Object.is;if(n)ce=i,++ie,i.depsTail=void 0;else if(e===void 0)return!1;n&&(i.flags=v.Mutable|v.RecursedCheck);try{let t=i._snapshot,a=typeof e==`function`?e(t):e===void 0&&n?r(t):e;return t===void 0||!o(t,a)?(i._snapshot=a,!0):!1}finally{ce=a,n&&(i.flags&=~v.RecursedCheck),V(i)}}};return n?(i.flags=v.Mutable|v.Dirty,i.get=function(){let e=i.flags;if(e&v.Dirty||e&v.Pending&&oe(i.deps,i)){if(i._update()){let e=i.subs;e!==void 0&&z(e)}}else e&v.Pending&&(i.flags=e&~v.Pending);return ce!==void 0&&L(i,ce,ie),i._snapshot}):i.set=function(e){if(i._update(e)){let e=i.subs;e!==void 0&&(ae(e),z(e),le())}},i}function de(e){let t=()=>{let t=ce;ce=n,++ie,n.depsTail=void 0,n.flags=v.Watching|v.RecursedCheck;try{return e()}finally{ce=t,n.flags&=~v.RecursedCheck,V(n)}},n={deps:void 0,depsTail:void 0,subs:void 0,subsTail:void 0,flags:v.Watching|v.RecursedCheck,notify(){let e=this.flags;e&v.Dirty||e&v.Pending&&oe(this.deps,this)?t():this.flags=v.Watching},stop(){this.flags=v.None,this.depsTail=void 0,V(this)}};return t(),n}var fe=class{constructor(e){this.atom=ue(e)}setState(e){this.atom.set(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(ne(e))}},pe=class{constructor(e){this.atom=ue(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(ne(e))}};function me(e){return typeof e==`function`?new pe(e):new fe(e)}function he(e){try{A(),e()}finally{j(),le()}}function ge(e){return!!e?.isNotFound}function _e(e,t=String){let n=new URLSearchParams;for(let r in e){let i=e[r];i!==void 0&&n.set(r,t(i))}return n.toString()}function ve(e){return e?e===`false`?!1:e===`true`?!0:e*0==0&&+e+``===e?+e:e:``}function ye(e){let t=new URLSearchParams(e),n=Object.create(null);for(let[e,r]of t.entries()){let t=n[e];t==null?n[e]=ve(r):Array.isArray(t)?t.push(ve(r)):n[e]=[t,ve(r)]}return n}function be(e){if(e.statusCode=e.statusCode||e.code||307,!e._builtLocation&&!e.reloadDocument&&typeof e.href==`string`)try{new URL(e.href),e.reloadDocument=!0}catch{}let t=new Headers(e.headers);e.href&&t.get(`Location`)===null&&t.set(`Location`,e.href);let n=new Response(null,{status:e.statusCode,headers:t});if(n.options=e,e.throw)throw n;return n}function xe(e){return e instanceof Response&&!!e.options}function Se(e){if(typeof e==`object`&&e&&e.isSerializedRedirect)return be(e)}var Ce=(e=>(e[e.AggregateError=1]=`AggregateError`,e[e.ArrowFunction=2]=`ArrowFunction`,e[e.ErrorPrototypeStack=4]=`ErrorPrototypeStack`,e[e.ObjectAssign=8]=`ObjectAssign`,e[e.BigIntTypedArray=16]=`BigIntTypedArray`,e[e.RegExp=32]=`RegExp`,e))(Ce||{}),we=Symbol.asyncIterator,Te=Symbol.hasInstance,Ee=Symbol.isConcatSpreadable,De=Symbol.iterator,Oe=Symbol.match,ke=Symbol.matchAll,Ae=Symbol.replace,je=Symbol.search,Me=Symbol.species,Ne=Symbol.split,Pe=Symbol.toPrimitive,Fe=Symbol.toStringTag,Ie=Symbol.unscopables,Le={[we]:0,[Te]:1,[Ee]:2,[De]:3,[Oe]:4,[ke]:5,[Ae]:6,[je]:7,[Me]:8,[Ne]:9,[Pe]:10,[Fe]:11,[Ie]:12},Re={0:we,1:Te,2:Ee,3:De,4:Oe,5:ke,6:Ae,7:je,8:Me,9:Ne,10:Pe,11:Fe,12:Ie},H=void 0,ze={2:!0,3:!1,1:H,0:null,4:-0,5:1/0,6:-1/0,7:NaN},Be={0:`Error`,1:`EvalError`,2:`RangeError`,3:`ReferenceError`,4:`SyntaxError`,5:`TypeError`,6:`URIError`},Ve={0:Error,1:EvalError,2:RangeError,3:ReferenceError,4:SyntaxError,5:TypeError,6:URIError};function U(e,t,n,r,i,a,o,s,c,l,u,d){return{t:e,i:t,s:n,c:r,m:i,p:a,e:o,a:s,f:c,b:l,o:u,l:d}}function He(e){return U(2,H,e,H,H,H,H,H,H,H,H,H)}var Ue=He(2),We=He(3),Ge=He(1),Ke=He(0),qe=He(4),Je=He(5),Ye=He(6),Xe=He(7);function Ze(e){switch(e){case`"`:return`\\"`;case`\\`:return`\\\\`;case`
2
+ `:return`\\n`;case`\r`:return`\\r`;case`\b`:return`\\b`;case` `:return`\\t`;case`\f`:return`\\f`;case`<`:return`\\x3C`;case`\u2028`:return`\\u2028`;case`\u2029`:return`\\u2029`;default:return H}}function Qe(e){let t=``,n=0,r;for(let i=0,a=e.length;i<a;i++)r=Ze(e[i]),r&&(t+=e.slice(n,i)+r,n=i+1);return n===0?t=e:t+=e.slice(n),t}function $e(e){switch(e){case`\\\\`:return`\\`;case`\\"`:return`"`;case`\\n`:return`
3
+ `;case`\\r`:return`\r`;case`\\b`:return`\b`;case`\\t`:return` `;case`\\f`:return`\f`;case`\\x3C`:return`<`;case`\\u2028`:return`\u2028`;case`\\u2029`:return`\u2029`;default:return e}}function et(e){return e.replace(/(\\\\|\\"|\\n|\\r|\\b|\\t|\\f|\\u2028|\\u2029|\\x3C)/g,$e)}var tt=`__SEROVAL_REFS__`,nt=new Map,rt=new Map;function it(e){return nt.has(e)}function at(e){return rt.has(e)}function ot(e){if(it(e))return nt.get(e);throw new Jt(e)}function st(e){if(at(e))return rt.get(e);throw new Yt(e)}typeof globalThis<`u`?Object.defineProperty(globalThis,tt,{value:rt,configurable:!0,writable:!1,enumerable:!1}):typeof window<`u`?Object.defineProperty(window,tt,{value:rt,configurable:!0,writable:!1,enumerable:!1}):typeof self<`u`?Object.defineProperty(self,tt,{value:rt,configurable:!0,writable:!1,enumerable:!1}):typeof global<`u`&&Object.defineProperty(global,tt,{value:rt,configurable:!0,writable:!1,enumerable:!1});function ct(e){return e instanceof EvalError?1:e instanceof RangeError?2:e instanceof ReferenceError?3:e instanceof SyntaxError?4:e instanceof TypeError?5:e instanceof URIError?6:0}function lt(e){let t=Be[ct(e)];return e.name===t?e.constructor.name===t?{}:{name:e.constructor.name}:{name:e.name}}function ut(e,t){let n=lt(e),r=Object.getOwnPropertyNames(e);for(let i=0,a=r.length,o;i<a;i++)o=r[i],o!==`name`&&o!==`message`&&(o===`stack`?t&4&&(n||={},n[o]=e[o]):(n||={},n[o]=e[o]));return n}function dt(e){return Object.isFrozen(e)?3:Object.isSealed(e)?2:+!Object.isExtensible(e)}function ft(e){switch(e){case 1/0:return Je;case-1/0:return Ye}return e===e?Object.is(e,-0)?qe:U(0,H,e,H,H,H,H,H,H,H,H,H):Xe}function pt(e){return U(1,H,Qe(e),H,H,H,H,H,H,H,H,H)}function mt(e){return U(3,H,``+e,H,H,H,H,H,H,H,H,H)}function ht(e){return U(4,e,H,H,H,H,H,H,H,H,H,H)}function gt(e,t){let n=t.valueOf();return U(5,e,n===n?t.toISOString():``,H,H,H,H,H,H,H,H,H)}function _t(e,t){return U(6,e,H,Qe(t.source),t.flags,H,H,H,H,H,H,H)}function vt(e,t){return U(17,e,Le[t],H,H,H,H,H,H,H,H,H)}function yt(e,t){return U(18,e,Qe(ot(t)),H,H,H,H,H,H,H,H,H)}function bt(e,t,n){return U(25,e,n,Qe(t),H,H,H,H,H,H,H,H)}function xt(e,t,n){return U(9,e,H,H,H,H,H,n,H,H,dt(t),H)}function St(e,t){return U(21,e,H,H,H,H,H,H,t,H,H,H)}function Ct(e,t,n){return U(15,e,H,t.constructor.name,H,H,H,H,n,t.byteOffset,H,t.length)}function wt(e,t,n){return U(16,e,H,t.constructor.name,H,H,H,H,n,t.byteOffset,H,t.byteLength)}function Tt(e,t,n){return U(20,e,H,H,H,H,H,H,n,t.byteOffset,H,t.byteLength)}function Et(e,t,n){return U(13,e,ct(t),H,Qe(t.message),n,H,H,H,H,H,H)}function Dt(e,t,n){return U(14,e,ct(t),H,Qe(t.message),n,H,H,H,H,H,H)}function Ot(e,t){return U(7,e,H,H,H,H,H,t,H,H,H,H)}function kt(e,t){return U(28,H,H,H,H,H,H,[e,t],H,H,H,H)}function At(e,t){return U(30,H,H,H,H,H,H,[e,t],H,H,H,H)}function jt(e,t,n){return U(31,e,H,H,H,H,H,n,t,H,H,H)}function Mt(e,t){return U(32,e,H,H,H,H,H,H,t,H,H,H)}function Nt(e,t){return U(33,e,H,H,H,H,H,H,t,H,H,H)}function Pt(e,t){return U(34,e,H,H,H,H,H,H,t,H,H,H)}function Ft(e,t,n,r){return U(35,e,n,H,H,H,H,t,H,H,H,r)}var{toString:It}=Object.prototype,Lt={parsing:1,serialization:2,deserialization:3};function Rt(e){return`Seroval Error (step: ${Lt[e]})`}var zt=(e,t)=>Rt(e),Bt=class extends Error{constructor(e,t){super(zt(e,t)),this.cause=t}},Vt=class extends Bt{constructor(e){super(`parsing`,e)}},Ht=class extends Bt{constructor(e){super(`deserialization`,e)}};function Ut(e){return`Seroval Error (specific: ${e})`}var Wt=class extends Error{constructor(e){super(Ut(1)),this.value=e}},Gt=class extends Error{constructor(e){super(Ut(2))}},Kt=class extends Error{constructor(e){super(Ut(3))}},qt=class extends Error{constructor(e){super(Ut(4))}},Jt=class extends Error{constructor(e){super(Ut(5)),this.value=e}},Yt=class extends Error{constructor(e){super(Ut(6))}},Xt=class extends Error{constructor(e){super(Ut(7))}},Zt=class extends Error{constructor(e){super(Ut(8))}},Qt=class extends Error{constructor(e){super(Ut(9))}},$t=class{constructor(e,t){this.value=e,this.replacement=t}},en=()=>{let e={p:0,s:0,f:0};return e.p=new Promise((t,n)=>{e.s=t,e.f=n}),e};en.toString(),((e,t)=>{e.s(t),e.p.s=1,e.p.v=t}).toString(),((e,t)=>{e.f(t),e.p.s=2,e.p.v=t}).toString();var tn=()=>{let e=[],t=[],n=!0,r=!1,i=0,a=(e,n,r)=>{for(r=0;r<i;r++)t[r]&&t[r][n](e)},o=(t,i,a,o)=>{for(i=0,a=e.length;i<a;i++)o=e[i],!n&&i===a-1?t[r?`return`:`throw`](o):t.next(o)},s=(e,r)=>(n&&(r=i++,t[r]=e),o(e),()=>{n&&(t[r]=t[i],t[i--]=void 0)});return{__SEROVAL_STREAM__:!0,on:e=>s(e),next:t=>{n&&(e.push(t),a(t,`next`))},throw:i=>{n&&(e.push(i),a(i,`throw`),n=!1,r=!1,t.length=0)},return:i=>{n&&(e.push(i),a(i,`return`),n=!1,r=!0,t.length=0)}}};tn.toString();var nn=e=>t=>()=>{let n=0,r={[e]:()=>r,next:()=>{if(n>t.d)return{done:!0,value:void 0};let e=n++,r=t.v[e];if(e===t.t)throw r;return{done:e===t.d,value:r}}};return r};nn.toString();var rn=(e,t)=>n=>()=>{let r=0,i=-1,a=!1,o=[],s=[],c=(e=0,t=s.length)=>{for(;e<t;e++)s[e].s({done:!0,value:void 0})};n.on({next:e=>{let t=s.shift();t&&t.s({done:!1,value:e}),o.push(e)},throw:e=>{let t=s.shift();t&&t.f(e),c(),i=o.length,a=!0,o.push(e)},return:e=>{let t=s.shift();t&&t.s({done:!0,value:e}),c(),i=o.length,o.push(e)}});let l={[e]:()=>l,next:()=>{if(i===-1){let e=r++;if(e>=o.length){let e=t();return s.push(e),e.p}return{done:!1,value:o[e]}}if(r>i)return{done:!0,value:void 0};let e=r++,n=o[e];if(e!==i)return{done:!1,value:n};if(a)throw n;return{done:!0,value:n}}};return l};rn.toString();var an=e=>{let t=atob(e),n=t.length,r=new Uint8Array(n);for(let e=0;e<n;e++)r[e]=t.charCodeAt(e);return r.buffer};an.toString();function on(e){return`__SEROVAL_SEQUENCE__`in e}function sn(e,t,n){return{__SEROVAL_SEQUENCE__:!0,v:e,t,d:n}}function cn(e){let t=[],n=-1,r=-1,i=e[De]();for(;;)try{let e=i.next();if(t.push(e.value),e.done){r=t.length-1;break}}catch(e){n=t.length,t.push(e)}return sn(t,n,r)}var ln=nn(De);function un(e){return ln(e)}var dn={},fn={},pn={0:{},1:{},2:{},3:{},4:{},5:{}};function mn(e){return`__SEROVAL_STREAM__`in e}function hn(){return tn()}function gn(e){let t=hn(),n=e[we]();async function r(){try{let e=await n.next();e.done?t.return(e.value):(t.next(e.value),await r())}catch(e){t.throw(e)}}return r().catch(()=>{}),t}var _n=rn(we,en);function vn(e){return _n(e)}async function yn(e){try{return[1,await e]}catch(e){return[0,e]}}function bn(e,t){return{plugins:t.plugins,mode:e,marked:new Set,features:63^(t.disabledFeatures||0),refs:t.refs||new Map,depthLimit:t.depthLimit||1e3}}function xn(e,t){e.marked.add(t)}function Sn(e,t){let n=e.refs.size;return e.refs.set(t,n),n}function Cn(e,t){let n=e.refs.get(t);return n==null?{type:0,value:Sn(e,t)}:(xn(e,n),{type:1,value:ht(n)})}function wn(e,t){let n=Cn(e,t);return n.type===1?n:it(t)?{type:2,value:yt(n.value,t)}:n}function Tn(e,t){let n=wn(e,t);if(n.type!==0)return n.value;if(t in Le)return vt(n.value,t);throw new Wt(t)}function En(e,t){let n=Cn(e,pn[t]);return n.type===1?n.value:U(26,n.value,t,H,H,H,H,H,H,H,H,H)}function Dn(e){let t=Cn(e,dn);return t.type===1?t.value:U(27,t.value,H,H,H,H,H,H,Tn(e,De),H,H,H)}function On(e){let t=Cn(e,fn);return t.type===1?t.value:U(29,t.value,H,H,H,H,H,[En(e,1),Tn(e,we)],H,H,H,H)}function kn(e,t,n,r){return U(n?11:10,e,H,H,H,r,H,H,H,H,dt(t),H)}function An(e,t,n,r){return U(8,t,H,H,H,H,{k:n,v:r},H,En(e,0),H,H,H)}function jn(e,t,n){let r=new Uint8Array(n),i=``;for(let e=0,t=r.length;e<t;e++)i+=String.fromCharCode(r[e]);return U(19,t,Qe(btoa(i)),H,H,H,H,H,En(e,5),H,H,H)}function Mn(e,t){return{base:bn(e,t),child:void 0}}var Nn=class{constructor(e,t){this._p=e,this.depth=t}parse(e){return W(this._p,this.depth,e)}};async function Pn(e,t,n){let r=[];for(let i=0,a=n.length;i<a;i++)i in n?r[i]=await W(e,t,n[i]):r[i]=0;return r}async function Fn(e,t,n,r){return xt(n,r,await Pn(e,t,r))}async function In(e,t,n){let r=Object.entries(n),i=[],a=[];for(let n=0,o=r.length;n<o;n++)i.push(Qe(r[n][0])),a.push(await W(e,t,r[n][1]));return De in n&&(i.push(Tn(e.base,De)),a.push(kt(Dn(e.base),await W(e,t,cn(n))))),we in n&&(i.push(Tn(e.base,we)),a.push(At(On(e.base),await W(e,t,gn(n))))),Fe in n&&(i.push(Tn(e.base,Fe)),a.push(pt(n[Fe]))),Ee in n&&(i.push(Tn(e.base,Ee)),a.push(n[Ee]?Ue:We)),{k:i,v:a}}async function Ln(e,t,n,r,i){return kn(n,r,i,await In(e,t,r))}async function Rn(e,t,n,r){return St(n,await W(e,t,r.valueOf()))}async function zn(e,t,n,r){return Ct(n,r,await W(e,t,r.buffer))}async function Bn(e,t,n,r){return wt(n,r,await W(e,t,r.buffer))}async function Vn(e,t,n,r){return Tt(n,r,await W(e,t,r.buffer))}async function Hn(e,t,n,r){let i=ut(r,e.base.features);return Et(n,r,i?await In(e,t,i):H)}async function Un(e,t,n,r){let i=ut(r,e.base.features);return Dt(n,r,i?await In(e,t,i):H)}async function Wn(e,t,n,r){let i=[],a=[];for(let[n,o]of r.entries())i.push(await W(e,t,n)),a.push(await W(e,t,o));return An(e.base,n,i,a)}async function Gn(e,t,n,r){let i=[];for(let n of r.keys())i.push(await W(e,t,n));return Ot(n,i)}async function Kn(e,t,n,r){let i=e.base.plugins;if(i)for(let a=0,o=i.length;a<o;a++){let o=i[a];if(o.parse.async&&o.test(r))return bt(n,o.tag,await o.parse.async(r,new Nn(e,t),{id:n}))}return H}async function qn(e,t,n,r){let[i,a]=await yn(r);return U(12,n,i,H,H,H,H,H,await W(e,t,a),H,H,H)}function Jn(e,t,n,r,i){let a=[],o=n.on({next:n=>{xn(this.base,t),W(this,e,n).then(e=>{a.push(Mt(t,e))},e=>{i(e),o()})},throw:n=>{xn(this.base,t),W(this,e,n).then(e=>{a.push(Nt(t,e)),r(a),o()},e=>{i(e),o()})},return:n=>{xn(this.base,t),W(this,e,n).then(e=>{a.push(Pt(t,e)),r(a),o()},e=>{i(e),o()})}})}async function Yn(e,t,n,r){return jt(n,En(e.base,4),await new Promise(Jn.bind(e,t,n,r)))}async function Xn(e,t,n,r){let i=[];for(let n=0,a=r.v.length;n<a;n++)i[n]=await W(e,t,r.v[n]);return Ft(n,i,r.t,r.d)}async function Zn(e,t,n,r){if(Array.isArray(r))return Fn(e,t,n,r);if(mn(r))return Yn(e,t,n,r);if(on(r))return Xn(e,t,n,r);let i=r.constructor;if(i===$t)return W(e,t,r.replacement);let a=await Kn(e,t,n,r);if(a)return a;switch(i){case Object:return Ln(e,t,n,r,!1);case H:return Ln(e,t,n,r,!0);case Date:return gt(n,r);case Error:case EvalError:case RangeError:case ReferenceError:case SyntaxError:case TypeError:case URIError:return Hn(e,t,n,r);case Number:case Boolean:case String:case BigInt:return Rn(e,t,n,r);case ArrayBuffer:return jn(e.base,n,r);case Int8Array:case Int16Array:case Int32Array:case Uint8Array:case Uint16Array:case Uint32Array:case Uint8ClampedArray:case Float32Array:case Float64Array:return zn(e,t,n,r);case DataView:return Vn(e,t,n,r);case Map:return Wn(e,t,n,r);case Set:return Gn(e,t,n,r);default:break}if(i===Promise||r instanceof Promise)return qn(e,t,n,r);let o=e.base.features;if(o&32&&i===RegExp)return _t(n,r);if(o&16)switch(i){case BigInt64Array:case BigUint64Array:return Bn(e,t,n,r);default:break}if(o&1&&typeof AggregateError<`u`&&(i===AggregateError||r instanceof AggregateError))return Un(e,t,n,r);if(r instanceof Error)return Hn(e,t,n,r);if(De in r||we in r)return Ln(e,t,n,r,!!i);throw new Wt(r)}async function Qn(e,t,n){let r=wn(e.base,n);if(r.type!==0)return r.value;let i=await Kn(e,t,r.value,n);if(i)return i;throw new Wt(n)}async function W(e,t,n){switch(typeof n){case`boolean`:return n?Ue:We;case`undefined`:return Ge;case`string`:return pt(n);case`number`:return ft(n);case`bigint`:return mt(n);case`object`:if(n){let r=wn(e.base,n);return r.type===0?await Zn(e,t+1,r.value,n):r.value}return Ke;case`symbol`:return Tn(e.base,n);case`function`:return Qn(e,t,n);default:throw new Wt(n)}}async function $n(e,t){try{return await W(e,0,t)}catch(e){throw e instanceof Vt?e:new Vt(e)}}var er=(e=>(e[e.Vanilla=1]=`Vanilla`,e[e.Cross=2]=`Cross`,e))(er||{});function tr(e){return e}function nr(e,t){for(let n=0,r=t.length;n<r;n++){let r=t[n];e.has(r)||(e.add(r),r.extends&&nr(e,r.extends))}}function rr(e){if(e){let t=new Set;return nr(t,e),[...t]}}function ir(e){switch(e){case`Int8Array`:return Int8Array;case`Int16Array`:return Int16Array;case`Int32Array`:return Int32Array;case`Uint8Array`:return Uint8Array;case`Uint16Array`:return Uint16Array;case`Uint32Array`:return Uint32Array;case`Uint8ClampedArray`:return Uint8ClampedArray;case`Float32Array`:return Float32Array;case`Float64Array`:return Float64Array;case`BigInt64Array`:return BigInt64Array;case`BigUint64Array`:return BigUint64Array;default:throw new Xt(e)}}var ar=1e6,or=1e4,sr=2e4;function cr(e,t){switch(t){case 3:return Object.freeze(e);case 1:return Object.preventExtensions(e);case 2:return Object.seal(e);default:return e}}var lr=1e3;function ur(e,t){return{mode:e,plugins:t.plugins,refs:t.refs||new Map,features:t.features??63^(t.disabledFeatures||0),depthLimit:t.depthLimit||lr}}function dr(e){return{mode:2,base:ur(2,e),child:H}}var fr=class{constructor(e,t){this._p=e,this.depth=t}deserialize(e){return K(this._p,this.depth,e)}};function pr(e,t){if(t<0||!Number.isFinite(t)||!Number.isInteger(t))throw new Zt({t:4,i:t});if(e.refs.has(t))throw Error(`Conflicted ref id: `+t)}function mr(e,t,n){return pr(e.base,t),e.state.marked.has(t)&&e.base.refs.set(t,n),n}function hr(e,t,n){return pr(e.base,t),e.base.refs.set(t,n),n}function G(e,t,n){return e.mode===1?mr(e,t,n):hr(e,t,n)}function gr(e,t,n){if(Object.hasOwn(t,n))return t[n];throw new Zt(e)}function _r(e,t){return G(e,t.i,st(et(t.s)))}function vr(e,t,n){let r=n.a,i=r.length,a=G(e,n.i,Array(i));for(let n=0,o;n<i;n++)o=r[n],o&&(a[n]=K(e,t,o));return cr(a,n.o),a}function yr(e){switch(e){case`constructor`:case`__proto__`:case`prototype`:case`__defineGetter__`:case`__defineSetter__`:case`__lookupGetter__`:case`__lookupSetter__`:return!1;default:return!0}}function br(e){switch(e){case we:case Ee:case Fe:case De:return!0;default:return!1}}function xr(e,t,n){yr(t)?e[t]=n:Object.defineProperty(e,t,{value:n,configurable:!0,enumerable:!0,writable:!0})}function Sr(e,t,n,r,i){if(typeof r==`string`)xr(n,r,K(e,t,i));else{let a=K(e,t,r);switch(typeof a){case`string`:xr(n,a,K(e,t,i));break;case`symbol`:br(a)&&(n[a]=K(e,t,i));break;default:throw new Zt(r)}}}function Cr(e,t,n,r){let i=n.k;if(i.length>0)for(let a=0,o=n.v,s=i.length;a<s;a++)Sr(e,t,r,i[a],o[a]);return r}function wr(e,t,n){let r=G(e,n.i,n.t===10?{}:Object.create(null));return Cr(e,t,n.p,r),cr(r,n.o),r}function Tr(e,t){return G(e,t.i,new Date(t.s))}function Er(e,t){if(e.base.features&32){let n=et(t.c);if(n.length>sr)throw new Zt(t);return G(e,t.i,new RegExp(n,t.m))}throw new Gt(t)}function Dr(e,t,n){let r=G(e,n.i,new Set);for(let i=0,a=n.a,o=a.length;i<o;i++)r.add(K(e,t,a[i]));return r}function Or(e,t,n){let r=G(e,n.i,new Map);for(let i=0,a=n.e.k,o=n.e.v,s=a.length;i<s;i++)r.set(K(e,t,a[i]),K(e,t,o[i]));return r}function kr(e,t){if(t.s.length>ar)throw new Zt(t);return G(e,t.i,an(et(t.s)))}function Ar(e,t,n){let r=ir(n.c),i=K(e,t,n.f),a=n.b??0;if(a<0||a>i.byteLength)throw new Zt(n);return G(e,n.i,new r(i,a,n.l))}function jr(e,t,n){let r=K(e,t,n.f),i=n.b??0;if(i<0||i>r.byteLength)throw new Zt(n);return G(e,n.i,new DataView(r,i,n.l))}function Mr(e,t,n,r){if(n.p){let i=Cr(e,t,n.p,{});Object.defineProperties(r,Object.getOwnPropertyDescriptors(i))}return r}function Nr(e,t,n){return Mr(e,t,n,G(e,n.i,AggregateError([],et(n.m))))}function Pr(e,t,n){let r=gr(n,Ve,n.s);return Mr(e,t,n,G(e,n.i,new r(et(n.m))))}function Fr(e,t,n){let r=en(),i=G(e,n.i,r.p),a=K(e,t,n.f);return n.s?r.s(a):r.f(a),i}function Ir(e,t,n){return G(e,n.i,Object(K(e,t,n.f)))}function Lr(e,t,n){let r=e.base.plugins;if(r){let i=et(n.c);for(let a=0,o=r.length;a<o;a++){let o=r[a];if(o.tag===i)return G(e,n.i,o.deserialize(n.s,new fr(e,t),{id:n.i}))}}throw new Kt(n.c)}function Rr(e,t){return G(e,t.i,G(e,t.s,en()).p)}function zr(e,t,n){let r=e.base.refs.get(n.i);if(r)return r.s(K(e,t,n.a[1])),H;throw new qt(`Promise`)}function Br(e,t,n){let r=e.base.refs.get(n.i);if(r)return r.f(K(e,t,n.a[1])),H;throw new qt(`Promise`)}function Vr(e,t,n){return K(e,t,n.a[0]),un(K(e,t,n.a[1]))}function Hr(e,t,n){return K(e,t,n.a[0]),vn(K(e,t,n.a[1]))}function Ur(e,t,n){let r=G(e,n.i,hn()),i=n.a,a=i.length;if(a)for(let n=0;n<a;n++)K(e,t,i[n]);return r}function Wr(e,t,n){let r=e.base.refs.get(n.i);if(r&&mn(r))return r.next(K(e,t,n.f)),H;throw new qt(`Stream`)}function Gr(e,t,n){let r=e.base.refs.get(n.i);if(r&&mn(r))return r.throw(K(e,t,n.f)),H;throw new qt(`Stream`)}function Kr(e,t,n){let r=e.base.refs.get(n.i);if(r&&mn(r))return r.return(K(e,t,n.f)),H;throw new qt(`Stream`)}function qr(e,t,n){return K(e,t,n.f),H}function Jr(e,t,n){return K(e,t,n.a[1]),H}function Yr(e,t,n){let r=G(e,n.i,sn([],n.s,n.l));for(let i=0,a=n.a.length;i<a;i++)r.v[i]=K(e,t,n.a[i]);return r}function K(e,t,n){if(t>e.base.depthLimit)throw new Qt(e.base.depthLimit);switch(t+=1,n.t){case 2:return gr(n,ze,n.s);case 0:return Number(n.s);case 1:return et(String(n.s));case 3:if(String(n.s).length>or)throw new Zt(n);return BigInt(n.s);case 4:return e.base.refs.get(n.i);case 18:return _r(e,n);case 9:return vr(e,t,n);case 10:case 11:return wr(e,t,n);case 5:return Tr(e,n);case 6:return Er(e,n);case 7:return Dr(e,t,n);case 8:return Or(e,t,n);case 19:return kr(e,n);case 16:case 15:return Ar(e,t,n);case 20:return jr(e,t,n);case 14:return Nr(e,t,n);case 13:return Pr(e,t,n);case 12:return Fr(e,t,n);case 17:return gr(n,Re,n.s);case 21:return Ir(e,t,n);case 25:return Lr(e,t,n);case 22:return Rr(e,n);case 23:return zr(e,t,n);case 24:return Br(e,t,n);case 28:return Vr(e,t,n);case 30:return Hr(e,t,n);case 31:return Ur(e,t,n);case 32:return Wr(e,t,n);case 33:return Gr(e,t,n);case 34:return Kr(e,t,n);case 27:return qr(e,t,n);case 29:return Jr(e,t,n);case 35:return Yr(e,t,n);default:throw new Gt(n)}}function Xr(e,t){try{return K(e,0,t)}catch(e){throw new Ht(e)}}var Zr=(()=>T).toString();/=>/.test(Zr);function Qr(e,t){return Xr(dr({plugins:rr(t.plugins),refs:t.refs,features:t.features,disabledFeatures:t.disabledFeatures,depthLimit:t.depthLimit}),e)}async function $r(e,t={}){let n=Mn(1,{plugins:rr(t.plugins),disabledFeatures:t.disabledFeatures});return{t:await $n(n,e),f:n.base.features,m:Array.from(n.base.marked)}}function ei(e){return e}function ti(e){return tr({tag:`$TSR/t/`+e.key,test:e.test,parse:{sync(t,n){return n.parse(e.toSerializable(t))},async async(t,n){return await n.parse(e.toSerializable(t))},stream(t,n){return n.parse(e.toSerializable(t))}},serialize:void 0,deserialize(t,n){return e.fromSerializable(n.deserialize(t))}})}var ni={},ri=e=>new ReadableStream({start:t=>{e.on({next:e=>{try{t.enqueue(e)}catch{}},throw:e=>{t.error(e)},return:()=>{try{t.close()}catch{}}})}}),ii=tr({tag:`seroval-plugins/web/ReadableStreamFactory`,test(e){return e===ni},parse:{sync(){return ni},async async(){return await Promise.resolve(ni)},stream(){return ni}},serialize(){return ri.toString()},deserialize(){return ni}});function ai(e){let t=hn(),n=e.getReader();async function r(){try{let e=await n.read();e.done?t.return(e.value):(t.next(e.value),await r())}catch(e){t.throw(e)}}return r().catch(()=>{}),t}var oi=tr({tag:`seroval/plugins/web/ReadableStream`,extends:[ii],test(e){return typeof ReadableStream>`u`?!1:e instanceof ReadableStream},parse:{sync(e,t){return{factory:t.parse(ni),stream:t.parse(hn())}},async async(e,t){return{factory:await t.parse(ni),stream:await t.parse(ai(e))}},stream(e,t){return{factory:t.parse(ni),stream:t.parse(ai(e))}}},serialize(e,t){return`(`+t.serialize(e.factory)+`)(`+t.serialize(e.stream)+`)`},deserialize(e,t){return ri(t.deserialize(e.stream))}}),si=tr({tag:`$TSR/Error`,test(e){return e instanceof Error},parse:{sync(e,t){return{message:t.parse(e.message)}},async async(e,t){return{message:await t.parse(e.message)}},stream(e,t){return{message:t.parse(e.message)}}},serialize(e,t){return`new Error(`+t.serialize(e.message)+`)`},deserialize(e,t){return Error(t.deserialize(e.message))}}),ci=class{constructor(e,t){this.stream=e,this.hint=t?.hint??`binary`}},li=globalThis.Buffer,ui=!!li&&typeof li.from==`function`;function di(e){if(e.length===0)return``;if(ui)return li.from(e).toString(`base64`);let t=32768,n=[];for(let r=0;r<e.length;r+=t){let i=e.subarray(r,r+t);n.push(String.fromCharCode.apply(null,i))}return btoa(n.join(``))}function fi(e){if(e.length===0)return new Uint8Array;if(ui){let t=li.from(e,`base64`);return new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}var pi=Object.create(null),mi=Object.create(null),hi=e=>new ReadableStream({start(t){e.on({next(e){try{t.enqueue(fi(e))}catch{}},throw(e){t.error(e)},return(){try{t.close()}catch{}}})}}),gi=new TextEncoder,_i=e=>new ReadableStream({start(t){e.on({next(e){try{typeof e==`string`?t.enqueue(gi.encode(e)):t.enqueue(fi(e.$b64))}catch{}},throw(e){t.error(e)},return(){try{t.close()}catch{}}})}}),vi=`(s=>new ReadableStream({start(c){s.on({next(b){try{const d=atob(b),a=new Uint8Array(d.length);for(let i=0;i<d.length;i++)a[i]=d.charCodeAt(i);c.enqueue(a)}catch(_){}},throw(e){c.error(e)},return(){try{c.close()}catch(_){}}})}}))`,yi=`(s=>{const e=new TextEncoder();return new ReadableStream({start(c){s.on({next(v){try{if(typeof v==='string'){c.enqueue(e.encode(v))}else{const d=atob(v.$b64),a=new Uint8Array(d.length);for(let i=0;i<d.length;i++)a[i]=d.charCodeAt(i);c.enqueue(a)}}catch(_){}},throw(x){c.error(x)},return(){try{c.close()}catch(_){}}})}})})`;function bi(e){let t=hn(),n=e.getReader();return(async()=>{try{for(;;){let{done:e,value:r}=await n.read();if(e){t.return(void 0);break}t.next(di(r))}}catch(e){t.throw(e)}finally{n.releaseLock()}})(),t}function xi(e){let t=hn(),n=e.getReader(),r=new TextDecoder(`utf-8`,{fatal:!0});return(async()=>{try{for(;;){let{done:e,value:i}=await n.read();if(e){try{let e=r.decode();e.length>0&&t.next(e)}catch{}t.return(void 0);break}try{let e=r.decode(i,{stream:!0});e.length>0&&t.next(e)}catch{t.next({$b64:di(i)})}}}catch(e){t.throw(e)}finally{n.releaseLock()}})(),t}var Si=tr({tag:`tss/RawStream`,extends:[tr({tag:`tss/RawStreamFactory`,test(e){return e===pi},parse:{sync(){},async(){return Promise.resolve(void 0)},stream(){}},serialize(){return vi},deserialize(){return pi}}),tr({tag:`tss/RawStreamFactoryText`,test(e){return e===mi},parse:{sync(){},async(){return Promise.resolve(void 0)},stream(){}},serialize(){return yi},deserialize(){return mi}})],test(e){return e instanceof ci},parse:{sync(e,t){let n=e.hint===`text`?mi:pi;return{hint:e.hint,factory:t.parse(n),stream:t.parse(hn())}},async async(e,t){let n=e.hint===`text`?mi:pi,r=e.hint===`text`?xi(e.stream):bi(e.stream);return{hint:e.hint,factory:await t.parse(n),stream:await t.parse(r)}},stream(e,t){let n=e.hint===`text`?mi:pi,r=e.hint===`text`?xi(e.stream):bi(e.stream);return{hint:e.hint,factory:t.parse(n),stream:t.parse(r)}}},serialize(e,t){return`(`+t.serialize(e.factory)+`)(`+t.serialize(e.stream)+`)`},deserialize(e,t){let n=t.deserialize(e.stream);return e.hint===`text`?_i(n):hi(n)}});function Ci(e){return tr({tag:`tss/RawStream`,test:()=>!1,parse:{},serialize(){throw Error(`RawStreamDeserializePlugin.serialize should not be called. Client only deserializes.`)},deserialize(t){return e(t.streamId)}})}var wi=[si,Si,oi],q=d(p(),1),Ti=q.use,Ei=typeof window<`u`?q.useLayoutEffect:q.useEffect;function Di(e){let t=q.useRef({value:e,prev:null}),n=t.current.value;return e!==n&&(t.current={value:e,prev:n}),t.current.prev}function Oi(e,t,n={},r={}){q.useEffect(()=>{if(!e.current||r.disabled||typeof IntersectionObserver!=`function`)return;let i=new IntersectionObserver(([e])=>{t(e)},n);return i.observe(e.current),()=>{i.disconnect()}},[t,n,r.disabled,e])}function ki(e){let t=q.useRef(null);return q.useImperativeHandle(e,()=>t.current,[]),t}var Ai=!0;function ji(e,t){if(!Ai){if(e)return;var n=`Warning: `+t;typeof console<`u`&&console.warn(n);try{throw Error(n)}catch{}}}var Mi=l((e=>{var t=p();function n(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var r=typeof Object.is==`function`?Object.is:n,i=t.useState,a=t.useEffect,o=t.useLayoutEffect,s=t.useDebugValue;function c(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),c=r[0].inst,u=r[1];return o(function(){c.value=n,c.getSnapshot=t,l(c)&&u({inst:c})},[e,n,t]),a(function(){return l(c)&&u({inst:c}),e(function(){l(c)&&u({inst:c})})},[e]),s(n),n}function l(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!r(e,n)}catch{return!0}}function u(e,t){return t()}var d=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?u:c;e.useSyncExternalStore=t.useSyncExternalStore===void 0?d:t.useSyncExternalStore})),Ni=l(((e,t)=>{t.exports=Mi()})),Pi=l((e=>{var t=p(),n=Ni();function r(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var i=typeof Object.is==`function`?Object.is:r,a=n.useSyncExternalStore,o=t.useRef,s=t.useEffect,c=t.useMemo,l=t.useDebugValue;e.useSyncExternalStoreWithSelector=function(e,t,n,r,u){var d=o(null);if(d.current===null){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=c(function(){function e(e){if(!a){if(a=!0,o=e,e=r(e),u!==void 0&&f.hasValue){var t=f.value;if(u(t,e))return s=t}return s=e}if(t=s,i(o,e))return t;var n=r(e);return u!==void 0&&u(t,n)?(o=e,t):(o=e,s=n)}var a=!1,o,s,c=n===void 0?null:n;return[function(){return e(t())},c===null?void 0:function(){return e(c())}]},[t,n,r,u]);var p=a(e,d[0],d[1]);return s(function(){f.hasValue=!0,f.value=p},[p]),l(p),p}})),Fi=l(((e,t)=>{t.exports=Pi()}))();function Ii(e,t){return e===t}function Li(e,t,n=Ii){let r=(0,q.useCallback)(t=>{if(!e)return()=>{};let{unsubscribe:n}=e.subscribe(t);return n},[e]),i=(0,q.useCallback)(()=>e?.get(),[e]);return(0,Fi.useSyncExternalStoreWithSelector)(r,i,i,t,n)}var Ri=q.createContext(null);function zi(e){let t=q.useContext(Ri);return ji(!((e?.warn??!0)&&!t),`useRouter must be used inside a <RouterProvider> component!`),t}function Bi(t){let n=zi({warn:t?.router===void 0}),r=t?.router||n,i=(0,q.useRef)(void 0);return Li(r.__store,n=>{if(t?.select){if(t.structuralSharing??r.options.defaultStructuralSharing){let r=e(i.current,t.select(n));return i.current=r,r}return t.select(n)}return n})}var Vi=q.createContext(void 0),Hi=q.createContext(void 0);function Ui(e){let n=q.useContext(e.from?Hi:Vi);return Bi({select:r=>{let i=r.matches.find(t=>e.from?e.from===t.routeId:t.id===n);if(t(!((e.shouldThrow??!0)&&!i),`Could not find ${e.from?`an active match from "${e.from}"`:`a nearest match!`}`),i!==void 0)return e.select?e.select(i):i},structuralSharing:e.structuralSharing})}function Wi(e){return Ui({from:e.from,strict:e.strict,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.search):t.search})}function Gi(e){let t=zi();return q.useCallback(n=>t.navigate({...n,from:n.from??e?.from}),[e?.from,t])}var Ki=`__TSS_CONTEXT`,qi=Symbol.for(`TSS_SERVER_FUNCTION`),Ji=Symbol.for(`TSS_SERVER_FUNCTION_FACTORY`),Yi=`application/x-tss-framed`,Xi={JSON:0,CHUNK:1,END:2,ERROR:3};`${Yi}`;var Zi=/;\s*v=(\d+)/;function Qi(e){let t=e.match(Zi);return t?parseInt(t[1],10):void 0}function $i(e){let t=Qi(e);if(t!==void 0&&t!==1)throw Error(`Incompatible framed protocol version: server=${t}, client=1. Please ensure client and server are using compatible versions.`)}var ea=()=>window.__TSS_START_OPTIONS__;function ta(){return[...(ea()?.serializationAdapters)?.map(ti)??[],...wi]}var na=new TextDecoder,ra=new Uint8Array,ia=16*1024*1024,aa=32*1024*1024,oa=1024,sa=1e5;function ca(e){let t=new Map,n=new Map,r=new Set,i=!1,a=null,o=0,s,c=new ReadableStream({start(e){s=e},cancel(){i=!0;try{a?.cancel()}catch{}t.forEach(e=>{try{e.error(Error(`Framed response cancelled`))}catch{}}),t.clear(),n.clear(),r.clear()}});function l(e){let i=n.get(e);if(i)return i;if(r.has(e))return new ReadableStream({start(e){e.close()}});if(n.size>=oa)throw Error(`Too many raw streams in framed response (max ${oa})`);let a=new ReadableStream({start(n){t.set(e,n)},cancel(){r.add(e),t.delete(e),n.delete(e)}});return n.set(e,a),a}function u(e){return l(e),t.get(e)}return(async()=>{let n=e.getReader();a=n;let c=[],l=0;function d(){if(l<9)return null;let e=c[0];if(e.length>=9)return{type:e[0],streamId:(e[1]<<24|e[2]<<16|e[3]<<8|e[4])>>>0,length:(e[5]<<24|e[6]<<16|e[7]<<8|e[8])>>>0};let t=new Uint8Array(9),n=0,r=9;for(let e=0;e<c.length&&r>0;e++){let i=c[e],a=Math.min(i.length,r);t.set(i.subarray(0,a),n),n+=a,r-=a}return{type:t[0],streamId:(t[1]<<24|t[2]<<16|t[3]<<8|t[4])>>>0,length:(t[5]<<24|t[6]<<16|t[7]<<8|t[8])>>>0}}function f(e){if(e===0)return ra;let t=new Uint8Array(e),n=0,r=e;for(;r>0&&c.length>0;){let e=c[0];if(!e)break;let i=Math.min(e.length,r);t.set(e.subarray(0,i),n),n+=i,r-=i,i===e.length?c.shift():c[0]=e.subarray(i)}return l-=e,t}try{for(;;){let{done:e,value:a}=await n.read();if(i||e)break;if(a){if(l+a.length>aa)throw Error(`Framed response buffer exceeded ${aa} bytes`);for(c.push(a),l+=a.length;;){let e=d();if(!e)break;let{type:n,streamId:i,length:a}=e;if(n!==Xi.JSON&&n!==Xi.CHUNK&&n!==Xi.END&&n!==Xi.ERROR)throw Error(`Unknown frame type: ${n}`);if(n===Xi.JSON){if(i!==0)throw Error(`Invalid JSON frame streamId (expected 0)`)}else if(i===0)throw Error(`Invalid raw frame streamId (expected non-zero)`);if(a>ia)throw Error(`Frame payload too large: ${a} bytes (max ${ia})`);let c=9+a;if(l<c)break;if(++o>sa)throw Error(`Too many frames in framed response (max ${sa})`);f(9);let p=f(a);switch(n){case Xi.JSON:try{s.enqueue(na.decode(p))}catch{}break;case Xi.CHUNK:{let e=u(i);e&&e.enqueue(p);break}case Xi.END:{let e=u(i);if(r.add(i),e){try{e.close()}catch{}t.delete(i)}break}case Xi.ERROR:{let e=u(i);if(r.add(i),e){let n=na.decode(p);e.error(Error(n)),t.delete(i)}break}}}}}if(l!==0)throw Error(`Incomplete frame at end of framed response`);try{s.close()}catch{}t.forEach(e=>{try{e.close()}catch{}}),t.clear()}catch(e){try{s.error(e)}catch{}t.forEach(t=>{try{t.error(e)}catch{}}),t.clear()}finally{try{n.releaseLock()}catch{}a=null}})(),{getOrCreateStream:l,jsonChunks:c}}var la=null,ua=Object.prototype.hasOwnProperty;function da(e){for(let t in e)if(ua.call(e,t))return!0;return!1}async function fa(e,t,n){la||=ta();let r=t[0],i=r.fetch??n,a=r.data instanceof FormData?`formData`:`payload`,o=r.headers?new Headers(r.headers):new Headers;if(o.set(`x-tsr-serverFn`,`true`),a===`payload`&&o.set(`accept`,`${Yi}, application/x-ndjson, application/json`),r.method===`GET`){if(a===`formData`)throw Error(`FormData is not supported with GET requests`);let t=await pa(r);if(t!==void 0){let n=_e({payload:t});e.includes(`?`)?e+=`&${n}`:e+=`?${n}`}}let s;if(r.method===`POST`){let e=await ha(r);e?.contentType&&o.set(`content-type`,e.contentType),s=e?.body}return await ga(async()=>i(e,{method:r.method,headers:o,signal:r.signal,body:s}))}async function pa(e){let t=!1,n={};if(e.data!==void 0&&(t=!0,n.data=e.data),e.context&&da(e.context)&&(t=!0,n.context=e.context),t)return ma(n)}async function ma(e){return JSON.stringify(await Promise.resolve($r(e,{plugins:la})))}async function ha(e){if(e.data instanceof FormData){let t;return e.context&&da(e.context)&&(t=await ma(e.context)),t!==void 0&&e.data.set(Ki,t),{body:e.data}}let t=await pa(e);if(t)return{body:t,contentType:`application/json`}}async function ga(e){let n;try{n=await e()}catch(e){if(e instanceof Response)n=e;else throw console.log(e),e}if(n.headers.get(`x-tss-raw`)===`true`)return n;let r=n.headers.get(`content-type`);if(t(r,`expected content-type header to be set`),n.headers.get(`x-tss-serialized`)){let e;if(r.includes(`application/x-tss-framed`)){if($i(r),!n.body)throw Error(`No response body for framed response`);let{getOrCreateStream:t,jsonChunks:i}=ca(n.body),a=[Ci(t),...la||[]],o=new Map;e=await va({jsonStream:i,onMessage:e=>Qr(e,{refs:o,plugins:a}),onError(e,t){console.error(e,t)}})}else if(r.includes(`application/x-ndjson`)){let t=new Map;e=await _a({response:n,onMessage:e=>Qr(e,{refs:t,plugins:la}),onError(e,t){console.error(e,t)}})}else r.includes(`application/json`)&&(e=Qr(await n.json(),{plugins:la}));if(t(e,`expected result to be resolved`),e instanceof Error)throw e;return e}if(r.includes(`application/json`)){let e=await n.json(),t=Se(e);if(t)throw t;if(ge(e))throw e;return e}if(!n.ok)throw Error(await n.text());return n}async function _a({response:e,onMessage:t,onError:n}){if(!e.body)throw Error(`No response body`);let r=e.body.pipeThrough(new TextDecoderStream).getReader(),i=``,a=!1,o;for(;!a;){let{value:e,done:t}=await r.read();if(e&&(i+=e),i.length===0&&t)throw Error(`Stream ended before first object`);if(i.endsWith(`
4
+ `)){let e=i.split(`
5
+ `).filter(Boolean),t=e[0];if(!t)throw Error(`No JSON line in the first chunk`);o=JSON.parse(t),a=!0,i=e.slice(1).join(`
6
+ `)}else{let e=i.indexOf(`
7
+ `);if(e>=0){let t=i.slice(0,e).trim();i=i.slice(e+1),t.length>0&&(o=JSON.parse(t),a=!0)}}}return(async()=>{try{for(;;){let{value:e,done:a}=await r.read();e&&(i+=e);let o=i.lastIndexOf(`
8
+ `);if(o>=0){let e=i.slice(0,o);i=i.slice(o+1);let r=e.split(`
9
+ `).filter(Boolean);for(let e of r)try{t(JSON.parse(e))}catch(t){n?.(`Invalid JSON line: ${e}`,t)}}if(a)break}}catch(e){n?.(`Stream processing error:`,e)}})(),t(o)}async function va({jsonStream:e,onMessage:t,onError:n}){let r=e.getReader(),{value:i,done:a}=await r.read();if(a||!i)throw Error(`Stream ended before first object`);let o=JSON.parse(i);return(async()=>{try{for(;;){let{value:e,done:i}=await r.read();if(i)break;if(e)try{t(JSON.parse(e))}catch(t){n?.(`Invalid JSON: ${e}`,t)}}}catch(e){n?.(`Stream processing error:`,e)}})(),t(o)}function ya(e){let t=`/_serverFn/`+e;return Object.assign((...e)=>{let n=ea()?.serverFns?.fetch;return fa(t,e,n??fetch)},{url:t,serverFnMeta:{id:e},[qi]:!0})}var ba=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},xa={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},Sa=new class{#e=xa;setTimeoutProvider(e){this.#e=e}setTimeout(e,t){return this.#e.setTimeout(e,t)}clearTimeout(e){this.#e.clearTimeout(e)}setInterval(e,t){return this.#e.setInterval(e,t)}clearInterval(e){this.#e.clearInterval(e)}};function Ca(e){setTimeout(e,0)}var wa=typeof window>`u`||`Deno`in globalThis;function Ta(){}function Ea(e,t){return typeof e==`function`?e(t):e}function Da(e){return typeof e==`number`&&e>=0&&e!==1/0}function Oa(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ka(e,t){return typeof e==`function`?e(t):e}function Aa(e,t){return typeof e==`function`?e(t):e}function ja(e,t){let{type:n=`all`,exact:r,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(r){if(t.queryHash!==Na(o,t.options))return!1}else if(!Fa(t.queryKey,o))return!1}if(n!==`all`){let e=t.isActive();if(n===`active`&&!e||n===`inactive`&&e)return!1}return!(typeof s==`boolean`&&t.isStale()!==s||i&&i!==t.state.fetchStatus||a&&!a(t))}function Ma(e,t){let{exact:n,status:r,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(n){if(Pa(t.options.mutationKey)!==Pa(a))return!1}else if(!Fa(t.options.mutationKey,a))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function Na(e,t){return(t?.queryKeyHashFn||Pa)(e)}function Pa(e){return JSON.stringify(e,(e,t)=>Ba(t)?Object.keys(t).sort().reduce((e,n)=>(e[n]=t[n],e),{}):t)}function Fa(e,t){return e===t?!0:typeof e==typeof t&&e&&t&&typeof e==`object`&&typeof t==`object`?Object.keys(t).every(n=>Fa(e[n],t[n])):!1}var Ia=Object.prototype.hasOwnProperty;function La(e,t,n=0){if(e===t)return e;if(n>500)return t;let r=za(e)&&za(t);if(!r&&!(Ba(e)&&Ba(t)))return t;let i=(r?e:Object.keys(e)).length,a=r?t:Object.keys(t),o=a.length,s=r?Array(o):{},c=0;for(let l=0;l<o;l++){let o=r?l:a[l],u=e[o],d=t[o];if(u===d){s[o]=u,(r?l<i:Ia.call(e,o))&&c++;continue}if(u===null||d===null||typeof u!=`object`||typeof d!=`object`){s[o]=d;continue}let f=La(u,d,n+1);s[o]=f,f===u&&c++}return i===o&&c===i?e:s}function Ra(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e)if(e[n]!==t[n])return!1;return!0}function za(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Ba(e){if(!Va(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!Va(n)||!n.hasOwnProperty(`isPrototypeOf`)||Object.getPrototypeOf(e)!==Object.prototype)}function Va(e){return Object.prototype.toString.call(e)===`[object Object]`}function Ha(e){return new Promise(t=>{Sa.setTimeout(t,e)})}function Ua(e,t,n){return typeof n.structuralSharing==`function`?n.structuralSharing(e,t):n.structuralSharing===!1?t:La(e,t)}function Wa(e,t,n=0){let r=[...e,t];return n&&r.length>n?r.slice(1):r}function Ga(e,t,n=0){let r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Ka=Symbol();function qa(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===Ka?()=>Promise.reject(Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function Ja(e,t){return typeof e==`function`?e(...t):!!e}function Ya(e,t,n){let r=!1,i;return Object.defineProperty(e,`signal`,{enumerable:!0,get:()=>(i??=t(),r?i:(r=!0,i.aborted?n():i.addEventListener(`abort`,n,{once:!0}),i))}),e}var Xa=new class extends ba{#e;#t;#n;constructor(){super(),this.#n=e=>{if(!wa&&window.addEventListener){let t=()=>e();return window.addEventListener(`visibilitychange`,t,!1),()=>{window.removeEventListener(`visibilitychange`,t)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(e=>{typeof e==`boolean`?this.setFocused(e):this.onFocus()})}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){let e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){return typeof this.#e==`boolean`?this.#e:globalThis.document?.visibilityState!==`hidden`}};function Za(){let e,t,n=new Promise((n,r)=>{e=n,t=r});n.status=`pending`,n.catch(()=>{});function r(e){Object.assign(n,e),delete n.resolve,delete n.reject}return n.resolve=t=>{r({status:`fulfilled`,value:t}),e(t)},n.reject=e=>{r({status:`rejected`,reason:e}),t(e)},n}var Qa=Ca;function $a(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=Qa,a=r=>{t?e.push(r):i(()=>{n(r)})},o=()=>{let t=e;e=[],t.length&&i(()=>{r(()=>{t.forEach(e=>{n(e)})})})};return{batch:e=>{let n;t++;try{n=e()}finally{t--,t||o()}return n},batchCalls:e=>(...t)=>{a(()=>{e(...t)})},schedule:a,setNotifyFunction:e=>{n=e},setBatchNotifyFunction:e=>{r=e},setScheduler:e=>{i=e}}}var eo=$a(),to=new class extends ba{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(!wa&&window.addEventListener){let t=()=>e(!0),n=()=>e(!1);return window.addEventListener(`online`,t,!1),window.addEventListener(`offline`,n,!1),()=>{window.removeEventListener(`online`,t),window.removeEventListener(`offline`,n)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#n=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#e!==e&&(this.#e=e,this.listeners.forEach(t=>{t(e)}))}isOnline(){return this.#e}};function no(e){return Math.min(1e3*2**e,3e4)}function ro(e){return(e??`online`)===`online`?to.isOnline():!0}var io=class extends Error{constructor(e){super(`CancelledError`),this.revert=e?.revert,this.silent=e?.silent}};function ao(e){let t=!1,n=0,r,i=Za(),a=()=>i.status!==`pending`,o=t=>{if(!a()){let n=new io(t);f(n),e.onCancel?.(n)}},s=()=>{t=!0},c=()=>{t=!1},l=()=>Xa.isFocused()&&(e.networkMode===`always`||to.isOnline())&&e.canRun(),u=()=>ro(e.networkMode)&&e.canRun(),d=e=>{a()||(r?.(),i.resolve(e))},f=e=>{a()||(r?.(),i.reject(e))},p=()=>new Promise(t=>{r=e=>{(a()||l())&&t(e)},e.onPause?.()}).then(()=>{r=void 0,a()||e.onContinue?.()}),m=()=>{if(a())return;let r,i=n===0?e.initialPromise:void 0;try{r=i??e.fn()}catch(e){r=Promise.reject(e)}Promise.resolve(r).then(d).catch(r=>{if(a())return;let i=e.retry??(wa?0:3),o=e.retryDelay??no,s=typeof o==`function`?o(n,r):o,c=i===!0||typeof i==`number`&&n<i||typeof i==`function`&&i(n,r);if(t||!c){f(r);return}n++,e.onFail?.(n,r),Ha(s).then(()=>l()?void 0:p()).then(()=>{t?f(r):m()})})};return{promise:i,status:()=>i.status,cancel:o,continue:()=>(r?.(),i),cancelRetry:s,continueRetry:c,canStart:u,start:()=>(u()?m():p().then(m),i)}}var oo=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Da(this.gcTime)&&(this.#e=Sa.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(wa?1/0:300*1e3))}clearGcTimeout(){this.#e&&=(Sa.clearTimeout(this.#e),void 0)}},so=class extends oo{#e;#t;#n;#r;#i;#a;#o;constructor(e){super(),this.#o=!1,this.#a=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#r=e.client,this.#n=this.#r.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#e=uo(this.options),this.state=e.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#i?.promise}setOptions(e){if(this.options={...this.#a,...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){let e=uo(this.options);e.data!==void 0&&(this.setState(lo(e.data,e.dataUpdatedAt)),this.#e=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus===`idle`&&this.#n.remove(this)}setData(e,t){let n=Ua(this.state.data,e,this.options);return this.#s({data:n,type:`success`,dataUpdatedAt:t?.updatedAt,manual:t?.manual}),n}setState(e,t){this.#s({type:`setState`,state:e,setStateOptions:t})}cancel(e){let t=this.#i?.promise;return this.#i?.cancel(e),t?t.then(Ta).catch(Ta):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#e)}isActive(){return this.observers.some(e=>Aa(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Ka||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>ka(e.options.staleTime,this)===`static`):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e===`static`?!1:this.state.isInvalidated?!0:!Oa(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(e=>e.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#i?.continue()}onOnline(){this.observers.find(e=>e.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#i?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.#i&&(this.#o?this.#i.cancel({revert:!0}):this.#i.cancelRetry()),this.scheduleGc()),this.#n.notify({type:`observerRemoved`,query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.#s({type:`invalidate`})}async fetch(e,t){if(this.state.fetchStatus!==`idle`&&this.#i?.status()!==`rejected`){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#i)return this.#i.continueRetry(),this.#i.promise}if(e&&this.setOptions(e),!this.options.queryFn){let e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}let n=new AbortController,r=e=>{Object.defineProperty(e,`signal`,{enumerable:!0,get:()=>(this.#o=!0,n.signal)})},i=()=>{let e=qa(this.options,t),n=(()=>{let e={client:this.#r,queryKey:this.queryKey,meta:this.meta};return r(e),e})();return this.#o=!1,this.options.persister?this.options.persister(e,n,this):e(n)},a=(()=>{let e={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:this.#r,state:this.state,fetchFn:i};return r(e),e})();this.options.behavior?.onFetch(a,this),this.#t=this.state,(this.state.fetchStatus===`idle`||this.state.fetchMeta!==a.fetchOptions?.meta)&&this.#s({type:`fetch`,meta:a.fetchOptions?.meta}),this.#i=ao({initialPromise:t?.initialPromise,fn:a.fetchFn,onCancel:e=>{e instanceof io&&e.revert&&this.setState({...this.#t,fetchStatus:`idle`}),n.abort()},onFail:(e,t)=>{this.#s({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#s({type:`pause`})},onContinue:()=>{this.#s({type:`continue`})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0});try{let e=await this.#i.start();if(e===void 0)throw Error(`${this.queryHash} data is undefined`);return this.setData(e),this.#n.config.onSuccess?.(e,this),this.#n.config.onSettled?.(e,this.state.error,this),e}catch(e){if(e instanceof io){if(e.silent)return this.#i.promise;if(e.revert){if(this.state.data===void 0)throw e;return this.state.data}}throw this.#s({type:`error`,error:e}),this.#n.config.onError?.(e,this),this.#n.config.onSettled?.(this.state.data,e,this),e}finally{this.scheduleGc()}}#s(e){this.state=(t=>{switch(e.type){case`failed`:return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case`pause`:return{...t,fetchStatus:`paused`};case`continue`:return{...t,fetchStatus:`fetching`};case`fetch`:return{...t,...co(t.data,this.options),fetchMeta:e.meta??null};case`success`:let n={...t,...lo(e.data,e.dataUpdatedAt),dataUpdateCount:t.dataUpdateCount+1,...!e.manual&&{fetchStatus:`idle`,fetchFailureCount:0,fetchFailureReason:null}};return this.#t=e.manual?n:void 0,n;case`error`:let r=e.error;return{...t,error:r,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:r,fetchStatus:`idle`,status:`error`,isInvalidated:!0};case`invalidate`:return{...t,isInvalidated:!0};case`setState`:return{...t,...e.state}}})(this.state),eo.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),this.#n.notify({query:this,type:`updated`,action:e})})}};function co(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:ro(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}function lo(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:`success`}}function uo(e){let t=typeof e.initialData==`function`?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt==`function`?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?`success`:`pending`,fetchStatus:`idle`}}var fo=class extends oo{#e;#t;#n;#r;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||po(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(t=>t!==e),this.scheduleGc(),this.#n.notify({type:`observerRemoved`,mutation:this,observer:e})}optionalRemove(){this.#t.length||(this.state.status===`pending`?this.scheduleGc():this.#n.remove(this))}continue(){return this.#r?.continue()??this.execute(this.state.variables)}async execute(e){let t=()=>{this.#i({type:`continue`})},n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#r=ao({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(Error(`No mutationFn found`)),onFail:(e,t)=>{this.#i({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#i({type:`pause`})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});let r=this.state.status===`pending`,i=!this.#r.canStart();try{if(r)t();else{this.#i({type:`pending`,variables:e,isPaused:i}),this.#n.config.onMutate&&await this.#n.config.onMutate(e,this,n);let t=await this.options.onMutate?.(e,n);t!==this.state.context&&this.#i({type:`pending`,context:t,variables:e,isPaused:i})}let a=await this.#r.start();return await this.#n.config.onSuccess?.(a,e,this.state.context,this,n),await this.options.onSuccess?.(a,e,this.state.context,n),await this.#n.config.onSettled?.(a,null,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(a,null,e,this.state.context,n),this.#i({type:`success`,data:a}),a}catch(t){try{await this.#n.config.onError?.(t,e,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onError?.(t,e,this.state.context,n)}catch(e){Promise.reject(e)}try{await this.#n.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onSettled?.(void 0,t,e,this.state.context,n)}catch(e){Promise.reject(e)}throw this.#i({type:`error`,error:t}),t}finally{this.#n.runNext(this)}}#i(e){this.state=(t=>{switch(e.type){case`failed`:return{...t,failureCount:e.failureCount,failureReason:e.error};case`pause`:return{...t,isPaused:!0};case`continue`:return{...t,isPaused:!1};case`pending`:return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:`pending`,variables:e.variables,submittedAt:Date.now()};case`success`:return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:`success`,isPaused:!1};case`error`:return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:`error`}}})(this.state),eo.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:`updated`,action:e})})}};function po(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:`idle`,variables:void 0,submittedAt:0}}var J=_(),mo=q.createContext(void 0),ho=e=>{let t=q.useContext(mo);if(e)return e;if(!t)throw Error(`No QueryClient set, use QueryClientProvider to set one`);return t},go=({client:e,children:t})=>(q.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),(0,J.jsx)(mo.Provider,{value:e,children:t})),_o=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),vo=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),yo=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),bo=e=>{let t=yo(e);return t.charAt(0).toUpperCase()+t.slice(1)},xo={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`},So=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},Co=(0,q.forwardRef)(({color:e=`currentColor`,size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i=``,children:a,iconNode:o,...s},c)=>(0,q.createElement)(`svg`,{ref:c,...xo,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:_o(`lucide`,i),...!a&&!So(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,q.createElement)(e,t)),...Array.isArray(a)?a:[a]])),wo=(e,t)=>{let n=(0,q.forwardRef)(({className:n,...r},i)=>(0,q.createElement)(Co,{ref:i,iconNode:t,className:_o(`lucide-${vo(bo(e))}`,`lucide-${e}`,n),...r}));return n.displayName=bo(e),n},To=wo(`package`,[[`path`,{d:`M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z`,key:`1a0edw`}],[`path`,{d:`M12 22V12`,key:`d0xqtd`}],[`polyline`,{points:`3.29 7 12 12 20.71 7`,key:`ousv84`}],[`path`,{d:`m7.5 4.27 9 5.15`,key:`1c824w`}]]),Eo=wo(`panel-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}]]),Do=wo(`triangle-alert`,[[`path`,{d:`m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3`,key:`wmoenq`}],[`path`,{d:`M12 9v4`,key:`juzpu7`}],[`path`,{d:`M12 17h.01`,key:`p32p05`}]]),Oo=d(h(),1),ko=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,Ao=n,jo=(e,t)=>n=>{if(t?.variants==null)return Ao(e,n?.class,n?.className);let{variants:r,defaultVariants:i}=t,a=Object.keys(r).map(e=>{let t=n?.[e],a=i?.[e];if(t===null)return null;let o=ko(t)||ko(a);return r[e][o]}),o=n&&Object.entries(n).reduce((e,t)=>{let[n,r]=t;return r===void 0||(e[n]=r),e},{});return Ao(e,a,t?.compoundVariants?.reduce((e,t)=>{let{class:n,className:r,...a}=t;return Object.entries(a).every(e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...i,...o}[t]):{...i,...o}[t]===n})?[...e,n,r]:e},[]),n?.class,n?.className)};function Mo(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function No(...e){return t=>{let n=!1,r=e.map(e=>{let r=Mo(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():Mo(e[t],null)}}}}function Po(...e){return q.useCallback(No(...e),e)}function Fo(e){let t=Lo(e),n=q.forwardRef((e,n)=>{let{children:r,...i}=e,a=q.Children.toArray(r),o=a.find(Bo);if(o){let e=o.props.children,r=a.map(t=>t===o?q.Children.count(e)>1?q.Children.only(null):q.isValidElement(e)?e.props.children:null:t);return(0,J.jsx)(t,{...i,ref:n,children:q.isValidElement(e)?q.cloneElement(e,void 0,r):null})}return(0,J.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}var Io=Fo(`Slot`);function Lo(e){let t=q.forwardRef((e,t)=>{let{children:n,...r}=e;if(q.isValidElement(n)){let e=Ho(n),i=Vo(r,n.props);return n.type!==q.Fragment&&(i.ref=t?No(t,e):e),q.cloneElement(n,i)}return q.Children.count(n)>1?q.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ro=Symbol(`radix.slottable`);function zo(e){let t=({children:e})=>(0,J.jsx)(J.Fragment,{children:e});return t.displayName=`${e}.Slottable`,t.__radixId=Ro,t}function Bo(e){return q.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===Ro}function Vo(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function Ho(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Uo=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=Fo(`Primitive.${t}`),r=q.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,J.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Wo(e,t){e&&Oo.flushSync(()=>e.dispatchEvent(t))}var Go=Object.freeze({position:`absolute`,border:0,width:1,height:1,padding:0,margin:-1,overflow:`hidden`,clip:`rect(0, 0, 0, 0)`,whiteSpace:`nowrap`,wordWrap:`normal`}),Ko=`VisuallyHidden`,qo=q.forwardRef((e,t)=>(0,J.jsx)(Uo.span,{...e,ref:t,style:{...Go,...e.style}}));qo.displayName=Ko;var Jo=qo;function Yo(e,t){let n=q.createContext(t),r=e=>{let{children:t,...r}=e,i=q.useMemo(()=>r,Object.values(r));return(0,J.jsx)(n.Provider,{value:i,children:t})};r.displayName=e+`Provider`;function i(r){let i=q.useContext(n);if(i)return i;if(t!==void 0)return t;throw Error(`\`${r}\` must be used within \`${e}\``)}return[r,i]}function Xo(e,t=[]){let n=[];function r(t,r){let i=q.createContext(r),a=n.length;n=[...n,r];let o=t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=q.useMemo(()=>o,Object.values(o));return(0,J.jsx)(s.Provider,{value:c,children:r})};o.displayName=t+`Provider`;function s(n,o){let s=o?.[e]?.[a]||i,c=q.useContext(s);if(c)return c;if(r!==void 0)return r;throw Error(`\`${n}\` must be used within \`${t}\``)}return[o,s]}let i=()=>{let t=n.map(e=>q.createContext(e));return function(n){let r=n?.[e]||t;return q.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])}};return i.scopeName=e,[r,Zo(i,...t)]}function Zo(...e){let t=e[0];if(e.length===1)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return q.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])}};return n.scopeName=t.scopeName,n}typeof window<`u`&&window.document&&window.document.createElement;function Qo(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r.defaultPrevented)return t?.(r)}}var $o=globalThis?.document?q.useLayoutEffect:()=>{},es=q.useInsertionEffect||$o;function ts({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,o]=ns({defaultProp:t,onChange:n}),s=e!==void 0,c=s?e:i;{let t=q.useRef(e!==void 0);q.useEffect(()=>{let e=t.current;e!==s&&console.warn(`${r} is changing from ${e?`controlled`:`uncontrolled`} to ${s?`controlled`:`uncontrolled`}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),t.current=s},[s,r])}return[c,q.useCallback(t=>{if(s){let n=rs(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}function ns({defaultProp:e,onChange:t}){let[n,r]=q.useState(e),i=q.useRef(n),a=q.useRef(t);return es(()=>{a.current=t},[t]),q.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}function rs(e){return typeof e==`function`}function is(e,t){return q.useReducer((e,n)=>t[e][n]??e,e)}var as=e=>{let{present:t,children:n}=e,r=os(t),i=typeof n==`function`?n({present:r.isPresent}):q.Children.only(n),a=Po(r.ref,cs(i));return typeof n==`function`||r.isPresent?q.cloneElement(i,{ref:a}):null};as.displayName=`Presence`;function os(e){let[t,n]=q.useState(),r=q.useRef(null),i=q.useRef(e),a=q.useRef(`none`),[o,s]=is(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return q.useEffect(()=>{let e=ss(r.current);a.current=o===`mounted`?e:`none`},[o]),$o(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,o=ss(t);e?s(`MOUNT`):o===`none`||t?.display===`none`?s(`UNMOUNT`):s(n&&r!==o?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,s]),$o(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=a=>{let o=ss(r.current).includes(CSS.escape(a.animationName));if(a.target===t&&o&&(s(`ANIMATION_END`),!i.current)){let r=t.style.animationFillMode;t.style.animationFillMode=`forwards`,e=n.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=r)})}},c=e=>{e.target===t&&(a.current=ss(r.current))};return t.addEventListener(`animationstart`,c),t.addEventListener(`animationcancel`,o),t.addEventListener(`animationend`,o),()=>{n.clearTimeout(e),t.removeEventListener(`animationstart`,c),t.removeEventListener(`animationcancel`,o),t.removeEventListener(`animationend`,o)}}else s(`ANIMATION_END`)},[t,s]),{isPresent:[`mounted`,`unmountSuspended`].includes(o),ref:q.useCallback(e=>{r.current=e?getComputedStyle(e):null,n(e)},[])}}function ss(e){return e?.animationName||`none`}function cs(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var ls=q.useId||(()=>void 0),us=0;function ds(e){let[t,n]=q.useState(ls());return $o(()=>{e||n(e=>e??String(us++))},[e]),e||(t?`radix-${t}`:``)}function fs(e){let t=q.useRef(e);return q.useEffect(()=>{t.current=e}),q.useMemo(()=>(...e)=>t.current?.(...e),[])}function ps(e,t=globalThis?.document){let n=fs(e);q.useEffect(()=>{let e=e=>{e.key===`Escape`&&n(e)};return t.addEventListener(`keydown`,e,{capture:!0}),()=>t.removeEventListener(`keydown`,e,{capture:!0})},[n,t])}var ms=`DismissableLayer`,hs=`dismissableLayer.update`,gs=`dismissableLayer.pointerDownOutside`,_s=`dismissableLayer.focusOutside`,vs,ys=q.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),bs=q.forwardRef((e,t)=>{let{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:s,...c}=e,l=q.useContext(ys),[u,d]=q.useState(null),f=u?.ownerDocument??globalThis?.document,[,p]=q.useState({}),m=Po(t,e=>d(e)),h=Array.from(l.layers),[g]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),_=h.indexOf(g),v=u?h.indexOf(u):-1,y=l.layersWithOutsidePointerEventsDisabled.size>0,b=v>=_,x=Cs(e=>{let t=e.target,n=[...l.branches].some(e=>e.contains(t));!b||n||(i?.(e),o?.(e),e.defaultPrevented||s?.())},f),S=ws(e=>{let t=e.target;[...l.branches].some(e=>e.contains(t))||(a?.(e),o?.(e),e.defaultPrevented||s?.())},f);return ps(e=>{v===l.layers.size-1&&(r?.(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))},f),q.useEffect(()=>{if(u)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(vs=f.body.style.pointerEvents,f.body.style.pointerEvents=`none`),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),Ts(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=vs)}},[u,f,n,l]),q.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),Ts())},[u,l]),q.useEffect(()=>{let e=()=>p({});return document.addEventListener(hs,e),()=>document.removeEventListener(hs,e)},[]),(0,J.jsx)(Uo.div,{...c,ref:m,style:{pointerEvents:y?b?`auto`:`none`:void 0,...e.style},onFocusCapture:Qo(e.onFocusCapture,S.onFocusCapture),onBlurCapture:Qo(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:Qo(e.onPointerDownCapture,x.onPointerDownCapture)})});bs.displayName=ms;var xs=`DismissableLayerBranch`,Ss=q.forwardRef((e,t)=>{let n=q.useContext(ys),r=q.useRef(null),i=Po(t,r);return q.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,J.jsx)(Uo.div,{...e,ref:i})});Ss.displayName=xs;function Cs(e,t=globalThis?.document){let n=fs(e),r=q.useRef(!1),i=q.useRef(()=>{});return q.useEffect(()=>{let e=e=>{if(e.target&&!r.current){let r=function(){Es(gs,n,a,{discrete:!0})},a={originalEvent:e};e.pointerType===`touch`?(t.removeEventListener(`click`,i.current),i.current=r,t.addEventListener(`click`,i.current,{once:!0})):r()}else t.removeEventListener(`click`,i.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener(`pointerdown`,e)},0);return()=>{window.clearTimeout(a),t.removeEventListener(`pointerdown`,e),t.removeEventListener(`click`,i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function ws(e,t=globalThis?.document){let n=fs(e),r=q.useRef(!1);return q.useEffect(()=>{let e=e=>{e.target&&!r.current&&Es(_s,n,{originalEvent:e},{discrete:!1})};return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Ts(){let e=new CustomEvent(hs);document.dispatchEvent(e)}function Es(e,t,n,{discrete:r}){let i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?Wo(i,a):i.dispatchEvent(a)}var Ds=`Portal`,Os=q.forwardRef((e,t)=>{let{container:n,...r}=e,[i,a]=q.useState(!1);$o(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?Oo.createPortal((0,J.jsx)(Uo.div,{...r,ref:t}),o):null});Os.displayName=Ds;function ks(e){let[t,n]=q.useState(void 0);return $o(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}else n(void 0)},[e]),t}var As=[`top`,`right`,`bottom`,`left`],js=Math.min,Ms=Math.max,Ns=Math.round,Ps=Math.floor,Fs=e=>({x:e,y:e}),Is={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function Ls(e,t,n){return Ms(e,js(t,n))}function Rs(e,t){return typeof e==`function`?e(t):e}function zs(e){return e.split(`-`)[0]}function Bs(e){return e.split(`-`)[1]}function Vs(e){return e===`x`?`y`:`x`}function Hs(e){return e===`y`?`height`:`width`}function Us(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function Ws(e){return Vs(Us(e))}function Gs(e,t,n){n===void 0&&(n=!1);let r=Bs(e),i=Ws(e),a=Hs(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=ec(o)),[o,ec(o)]}function Ks(e){let t=ec(e);return[qs(e),t,qs(t)]}function qs(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var Js=[`left`,`right`],Ys=[`right`,`left`],Xs=[`top`,`bottom`],Zs=[`bottom`,`top`];function Qs(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Ys:Js:t?Js:Ys;case`left`:case`right`:return t?Xs:Zs;default:return[]}}function $s(e,t,n,r){let i=Bs(e),a=Qs(zs(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(qs)))),a}function ec(e){let t=zs(e);return Is[t]+e.slice(t.length)}function tc(e){return{top:0,right:0,bottom:0,left:0,...e}}function nc(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:tc(e)}function rc(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function ic(e,t,n){let{reference:r,floating:i}=e,a=Us(t),o=Ws(t),s=Hs(o),c=zs(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(Bs(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function ac(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=Rs(t,e),p=nc(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=rc(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=rc(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var oc=50,sc=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:ac},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=ic(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<oc&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=ic(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},cc=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=Rs(e,t)||{};if(l==null)return{};let d=nc(u),f={x:n,y:r},p=Ws(i),m=Hs(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let w=b/2-x/2,E=C/2-h[m]/2-1,D=js(d[_],E),ee=js(d[v],E),O=D,k=C-h[m]-ee,A=C/2-h[m]/2+w,j=Ls(O,A,k),M=!c.arrow&&Bs(i)!=null&&A!==j&&a.reference[m]/2-(A<O?D:ee)-h[m]/2<0,N=M?A<O?A-O:A-k:0;return{[p]:f[p]+N,data:{[p]:j,centerOffset:A-j-N,...M&&{alignmentOffset:N}},reset:M}}}),lc=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=Rs(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=zs(r),_=Us(o),v=zs(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[ec(o)]:Ks(o)),x=p!==`none`;!d&&x&&b.push(...$s(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),w=[],E=i.flip?.overflows||[];if(l&&w.push(C[g]),u){let e=Gs(r,a,y);w.push(C[e[0]],C[e[1]])}if(E=[...E,{placement:r,overflows:w}],!w.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(!(u===`alignment`&&_!==Us(t))||E.every(e=>Us(e.placement)===_?e.overflows[0]>0:!0)))return{data:{index:e,overflows:E},reset:{placement:t}};let n=E.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=E.filter(e=>{if(x){let t=Us(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function uc(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function dc(e){return As.some(t=>e[t]>=0)}var fc=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=Rs(e,t);switch(i){case`referenceHidden`:{let e=uc(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:dc(e)}}}case`escaped`:{let e=uc(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:dc(e)}}}default:return{}}}}},pc=new Set([`left`,`top`]);async function mc(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=zs(n),s=Bs(n),c=Us(n)===`y`,l=pc.has(o)?-1:1,u=a&&c?-1:1,d=Rs(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var hc=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await mc(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},gc=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=Rs(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=Us(zs(i)),p=Vs(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=Ls(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=Ls(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},_c=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=Rs(e,t),u={x:n,y:r},d=Us(i),f=Vs(d),p=u[f],m=u[d],h=Rs(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=pc.has(zs(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},vc=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=Rs(e,t),u=await o.detectOverflow(t,l),d=zs(i),f=Bs(i),p=Us(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=js(h-u[g],v),x=js(m-u[_],y),S=!t.middlewareData.shift,C=b,w=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(w=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=Ms(u.left,0),t=Ms(u.right,0),n=Ms(u.top,0),r=Ms(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:Ms(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:Ms(u.top,u.bottom))}await c({...t,availableWidth:w,availableHeight:C});let E=await o.getDimensions(s.floating);return m!==E.width||h!==E.height?{reset:{rects:!0}}:{}}}};function yc(){return typeof window<`u`}function bc(e){return Cc(e)?(e.nodeName||``).toLowerCase():`#document`}function xc(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Sc(e){return((Cc(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function Cc(e){return yc()?e instanceof Node||e instanceof xc(e).Node:!1}function wc(e){return yc()?e instanceof Element||e instanceof xc(e).Element:!1}function Tc(e){return yc()?e instanceof HTMLElement||e instanceof xc(e).HTMLElement:!1}function Ec(e){return!yc()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof xc(e).ShadowRoot}function Dc(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=Rc(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function Oc(e){return/^(table|td|th)$/.test(bc(e))}function kc(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var Ac=/transform|translate|scale|rotate|perspective|filter/,jc=/paint|layout|strict|content/,Mc=e=>!!e&&e!==`none`,Nc;function Pc(e){let t=wc(e)?Rc(e):e;return Mc(t.transform)||Mc(t.translate)||Mc(t.scale)||Mc(t.rotate)||Mc(t.perspective)||!Ic()&&(Mc(t.backdropFilter)||Mc(t.filter))||Ac.test(t.willChange||``)||jc.test(t.contain||``)}function Fc(e){let t=Bc(e);for(;Tc(t)&&!Lc(t);){if(Pc(t))return t;if(kc(t))return null;t=Bc(t)}return null}function Ic(){return Nc??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),Nc}function Lc(e){return/^(html|body|#document)$/.test(bc(e))}function Rc(e){return xc(e).getComputedStyle(e)}function zc(e){return wc(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Bc(e){if(bc(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||Ec(e)&&e.host||Sc(e);return Ec(t)?t.host:t}function Vc(e){let t=Bc(e);return Lc(t)?e.ownerDocument?e.ownerDocument.body:e.body:Tc(t)&&Dc(t)?t:Vc(t)}function Hc(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=Vc(e),i=r===e.ownerDocument?.body,a=xc(r);if(i){let e=Uc(a);return t.concat(a,a.visualViewport||[],Dc(r)?r:[],e&&n?Hc(e):[])}else return t.concat(r,Hc(r,[],n))}function Uc(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Wc(e){let t=Rc(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=Tc(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Ns(n)!==a||Ns(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function Gc(e){return wc(e)?e:e.contextElement}function Kc(e){let t=Gc(e);if(!Tc(t))return Fs(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=Wc(t),o=(a?Ns(n.width):n.width)/r,s=(a?Ns(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var qc=Fs(0);function Jc(e){let t=xc(e);return!Ic()||!t.visualViewport?qc:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Yc(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==xc(e)?!1:t}function Xc(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=Gc(e),o=Fs(1);t&&(r?wc(r)&&(o=Kc(r)):o=Kc(e));let s=Yc(a,n,r)?Jc(a):Fs(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=xc(a),t=r&&wc(r)?xc(r):r,n=e,i=Uc(n);for(;i&&r&&t!==n;){let e=Kc(i),t=i.getBoundingClientRect(),r=Rc(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=xc(i),i=Uc(n)}}return rc({width:u,height:d,x:c,y:l})}function Zc(e,t){let n=zc(e).scrollLeft;return t?t.left+n:Xc(Sc(e)).left+n}function Qc(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Zc(e,n),y:n.top+t.scrollTop}}function $c(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=Sc(r),s=t?kc(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=Fs(1),u=Fs(0),d=Tc(r);if((d||!d&&!a)&&((bc(r)!==`body`||Dc(o))&&(c=zc(r)),d)){let e=Xc(r);l=Kc(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?Qc(o,c):Fs(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function el(e){return Array.from(e.getClientRects())}function tl(e){let t=Sc(e),n=zc(e),r=e.ownerDocument.body,i=Ms(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=Ms(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+Zc(e),s=-n.scrollTop;return Rc(r).direction===`rtl`&&(o+=Ms(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var nl=25;function rl(e,t){let n=xc(e),r=Sc(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=Ic();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=Zc(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=nl&&(a-=o)}else l<=nl&&(a+=l);return{width:a,height:o,x:s,y:c}}function il(e,t){let n=Xc(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Tc(e)?Kc(e):Fs(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function al(e,t,n){let r;if(t===`viewport`)r=rl(e,n);else if(t===`document`)r=tl(Sc(e));else if(wc(t))r=il(t,n);else{let n=Jc(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return rc(r)}function ol(e,t){let n=Bc(e);return n===t||!wc(n)||Lc(n)?!1:Rc(n).position===`fixed`||ol(n,t)}function sl(e,t){let n=t.get(e);if(n)return n;let r=Hc(e,[],!1).filter(e=>wc(e)&&bc(e)!==`body`),i=null,a=Rc(e).position===`fixed`,o=a?Bc(e):e;for(;wc(o)&&!Lc(o);){let t=Rc(o),n=Pc(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||Dc(o)&&!n&&ol(e,o))?r=r.filter(e=>e!==o):i=t,o=Bc(o)}return t.set(e,r),r}function cl(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?kc(t)?[]:sl(t,this._c):[].concat(n),r],o=al(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=al(t,a[e],i);s=Ms(n.top,s),c=js(n.right,c),l=js(n.bottom,l),u=Ms(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function ll(e){let{width:t,height:n}=Wc(e);return{width:t,height:n}}function ul(e,t,n){let r=Tc(t),i=Sc(t),a=n===`fixed`,o=Xc(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=Fs(0);function l(){c.x=Zc(i)}if(r||!r&&!a)if((bc(t)!==`body`||Dc(i))&&(s=zc(t)),r){let e=Xc(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?Qc(i,s):Fs(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function dl(e){return Rc(e).position===`static`}function fl(e,t){if(!Tc(e)||Rc(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return Sc(e)===n&&(n=n.ownerDocument.body),n}function pl(e,t){let n=xc(e);if(kc(e))return n;if(!Tc(e)){let t=Bc(e);for(;t&&!Lc(t);){if(wc(t)&&!dl(t))return t;t=Bc(t)}return n}let r=fl(e,t);for(;r&&Oc(r)&&dl(r);)r=fl(r,t);return r&&Lc(r)&&dl(r)&&!Pc(r)?n:r||Fc(e)||n}var ml=async function(e){let t=this.getOffsetParent||pl,n=this.getDimensions,r=await n(e.floating);return{reference:ul(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function hl(e){return Rc(e).direction===`rtl`}var gl={convertOffsetParentRelativeRectToViewportRelativeRect:$c,getDocumentElement:Sc,getClippingRect:cl,getOffsetParent:pl,getElementRects:ml,getClientRects:el,getDimensions:ll,getScale:Kc,isElement:wc,isRTL:hl};function _l(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function vl(e,t){let n=null,r,i=Sc(e);function a(){var e;clearTimeout(r),(e=n)==null||e.disconnect(),n=null}function o(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(s||t(),!f||!p)return;let m=Ps(d),h=Ps(i.clientWidth-(u+f)),g=Ps(i.clientHeight-(d+p)),_=Ps(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:Ms(0,js(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(n!==c){if(!y)return o();n?o(!1,n):r=setTimeout(()=>{o(!1,1e-7)},1e3)}n===1&&!_l(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function yl(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=Gc(e),u=i||a?[...l?Hc(l):[],...t?Hc(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?vl(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?Xc(e):null;c&&g();function g(){let t=Xc(e);h&&!_l(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var bl=hc,xl=gc,Sl=lc,Cl=vc,wl=fc,Tl=cc,El=_c,Dl=(e,t,n)=>{let r=new Map,i={platform:gl,...n},a={...i.platform,_c:r};return sc(e,t,{...i,platform:a})},Ol=typeof document<`u`?q.useLayoutEffect:function(){};function kl(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!kl(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!kl(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function Al(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function jl(e,t){let n=Al(e);return Math.round(t*n)/n}function Ml(e){let t=q.useRef(e);return Ol(()=>{t.current=e}),t}function Nl(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=q.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=q.useState(r);kl(f,r)||p(r);let[m,h]=q.useState(null),[g,_]=q.useState(null),v=q.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=q.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=q.useRef(null),C=q.useRef(null),w=q.useRef(u),E=c!=null,D=Ml(c),ee=Ml(i),O=Ml(l),k=q.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};ee.current&&(e.platform=ee.current),Dl(S.current,C.current,e).then(e=>{let t={...e,isPositioned:O.current!==!1};A.current&&!kl(w.current,t)&&(w.current=t,Oo.flushSync(()=>{d(t)}))})},[f,t,n,ee,O]);Ol(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let A=q.useRef(!1);Ol(()=>(A.current=!0,()=>{A.current=!1}),[]),Ol(()=>{if(b&&(S.current=b),x&&(C.current=x),b&&x){if(D.current)return D.current(b,x,k);k()}},[b,x,k,D,E]);let j=q.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),M=q.useMemo(()=>({reference:b,floating:x}),[b,x]),N=q.useMemo(()=>{let e={position:n,left:0,top:0};if(!M.floating)return e;let t=jl(M.floating,u.x),r=jl(M.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...Al(M.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,M.floating,u.x,u.y]);return q.useMemo(()=>({...u,update:k,refs:j,elements:M,floatingStyles:N}),[u,k,j,M,N])}var Pl=e=>{function t(e){return{}.hasOwnProperty.call(e,`current`)}return{name:`arrow`,options:e,fn(n){let{element:r,padding:i}=typeof e==`function`?e(n):e;return r&&t(r)?r.current==null?{}:Tl({element:r.current,padding:i}).fn(n):r?Tl({element:r,padding:i}).fn(n):{}}}},Fl=(e,t)=>{let n=bl(e);return{name:n.name,fn:n.fn,options:[e,t]}},Il=(e,t)=>{let n=xl(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ll=(e,t)=>({fn:El(e).fn,options:[e,t]}),Rl=(e,t)=>{let n=Sl(e);return{name:n.name,fn:n.fn,options:[e,t]}},zl=(e,t)=>{let n=Cl(e);return{name:n.name,fn:n.fn,options:[e,t]}},Bl=(e,t)=>{let n=wl(e);return{name:n.name,fn:n.fn,options:[e,t]}},Vl=(e,t)=>{let n=Pl(e);return{name:n.name,fn:n.fn,options:[e,t]}},Hl=`Arrow`,Ul=q.forwardRef((e,t)=>{let{children:n,width:r=10,height:i=5,...a}=e;return(0,J.jsx)(Uo.svg,{...a,ref:t,width:r,height:i,viewBox:`0 0 30 10`,preserveAspectRatio:`none`,children:e.asChild?n:(0,J.jsx)(`polygon`,{points:`0,0 30,0 15,10`})})});Ul.displayName=Hl;var Wl=Ul,Gl=`Popper`,[Kl,ql]=Xo(Gl),[Jl,Yl]=Kl(Gl),Xl=e=>{let{__scopePopper:t,children:n}=e,[r,i]=q.useState(null);return(0,J.jsx)(Jl,{scope:t,anchor:r,onAnchorChange:i,children:n})};Xl.displayName=Gl;var Zl=`PopperAnchor`,Ql=q.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:r,...i}=e,a=Yl(Zl,n),o=q.useRef(null),s=Po(t,o),c=q.useRef(null);return q.useEffect(()=>{let e=c.current;c.current=r?.current||o.current,e!==c.current&&a.onAnchorChange(c.current)}),r?null:(0,J.jsx)(Uo.div,{...i,ref:s})});Ql.displayName=Zl;var $l=`PopperContent`,[eu,tu]=Kl($l),nu=q.forwardRef((e,t)=>{let{__scopePopper:n,side:r=`bottom`,sideOffset:i=0,align:a=`center`,alignOffset:o=0,arrowPadding:s=0,avoidCollisions:c=!0,collisionBoundary:l=[],collisionPadding:u=0,sticky:d=`partial`,hideWhenDetached:f=!1,updatePositionStrategy:p=`optimized`,onPlaced:m,...h}=e,g=Yl($l,n),[_,v]=q.useState(null),y=Po(t,e=>v(e)),[b,x]=q.useState(null),S=ks(b),C=S?.width??0,w=S?.height??0,E=r+(a===`center`?``:`-`+a),D=typeof u==`number`?u:{top:0,right:0,bottom:0,left:0,...u},ee=Array.isArray(l)?l:[l],O=ee.length>0,k={padding:D,boundary:ee.filter(ou),altBoundary:O},{refs:A,floatingStyles:j,placement:M,isPositioned:N,middlewareData:P}=Nl({strategy:`fixed`,placement:E,whileElementsMounted:(...e)=>yl(...e,{animationFrame:p===`always`}),elements:{reference:g.anchor},middleware:[Fl({mainAxis:i+w,alignmentAxis:o}),c&&Il({mainAxis:!0,crossAxis:!1,limiter:d===`partial`?Ll():void 0,...k}),c&&Rl({...k}),zl({...k,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{let{width:i,height:a}=t.reference,o=e.floating.style;o.setProperty(`--radix-popper-available-width`,`${n}px`),o.setProperty(`--radix-popper-available-height`,`${r}px`),o.setProperty(`--radix-popper-anchor-width`,`${i}px`),o.setProperty(`--radix-popper-anchor-height`,`${a}px`)}}),b&&Vl({element:b,padding:s}),su({arrowWidth:C,arrowHeight:w}),f&&Bl({strategy:`referenceHidden`,...k})]}),[F,I]=cu(M),te=fs(m);$o(()=>{N&&te?.()},[N,te]);let ne=P.arrow?.x,re=P.arrow?.y,ie=P.arrow?.centerOffset!==0,[L,R]=q.useState();return $o(()=>{_&&R(window.getComputedStyle(_).zIndex)},[_]),(0,J.jsx)(`div`,{ref:A.setFloating,"data-radix-popper-content-wrapper":``,style:{...j,transform:N?j.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:L,"--radix-popper-transform-origin":[P.transformOrigin?.x,P.transformOrigin?.y].join(` `),...P.hide?.referenceHidden&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,J.jsx)(eu,{scope:n,placedSide:F,onArrowChange:x,arrowX:ne,arrowY:re,shouldHideArrow:ie,children:(0,J.jsx)(Uo.div,{"data-side":F,"data-align":I,...h,ref:y,style:{...h.style,animation:N?void 0:`none`}})})})});nu.displayName=$l;var ru=`PopperArrow`,iu={top:`bottom`,right:`left`,bottom:`top`,left:`right`},au=q.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,i=tu(ru,n),a=iu[i.placedSide];return(0,J.jsx)(`span`,{ref:i.onArrowChange,style:{position:`absolute`,left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:``,right:`0 0`,bottom:`center 0`,left:`100% 0`}[i.placedSide],transform:{top:`translateY(100%)`,right:`translateY(50%) rotate(90deg) translateX(-50%)`,bottom:`rotate(180deg)`,left:`translateY(50%) rotate(-90deg) translateX(50%)`}[i.placedSide],visibility:i.shouldHideArrow?`hidden`:void 0},children:(0,J.jsx)(Wl,{...r,ref:t,style:{...r.style,display:`block`}})})});au.displayName=ru;function ou(e){return e!==null}var su=e=>({name:`transformOrigin`,options:e,fn(t){let{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,o=a?0:e.arrowWidth,s=a?0:e.arrowHeight,[c,l]=cu(n),u={start:`0%`,center:`50%`,end:`100%`}[l],d=(i.arrow?.x??0)+o/2,f=(i.arrow?.y??0)+s/2,p=``,m=``;return c===`bottom`?(p=a?u:`${d}px`,m=`${-s}px`):c===`top`?(p=a?u:`${d}px`,m=`${r.floating.height+s}px`):c===`right`?(p=`${-s}px`,m=a?u:`${f}px`):c===`left`&&(p=`${r.floating.width+s}px`,m=a?u:`${f}px`),{data:{x:p,y:m}}}});function cu(e){let[t,n=`center`]=e.split(`-`);return[t,n]}var lu=Xl,uu=Ql,du=nu,fu=au,pu=`Separator`,mu=`horizontal`,hu=[`horizontal`,`vertical`],gu=q.forwardRef((e,t)=>{let{decorative:n,orientation:r=mu,...i}=e,a=_u(r)?r:mu,o=n?{role:`none`}:{"aria-orientation":a===`vertical`?a:void 0,role:`separator`};return(0,J.jsx)(Uo.div,{"data-orientation":a,...o,...i,ref:t})});gu.displayName=pu;function _u(e){return hu.includes(e)}var vu=gu,[yu,bu]=Xo(`Tooltip`,[ql]),xu=ql(),Su=`TooltipProvider`,Cu=700,wu=`tooltip.open`,[Tu,Eu]=yu(Su),Du=e=>{let{__scopeTooltip:t,delayDuration:n=Cu,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:a}=e,o=q.useRef(!0),s=q.useRef(!1),c=q.useRef(0);return q.useEffect(()=>{let e=c.current;return()=>window.clearTimeout(e)},[]),(0,J.jsx)(Tu,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:q.useCallback(()=>{window.clearTimeout(c.current),o.current=!1},[]),onClose:q.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>o.current=!0,r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:q.useCallback(e=>{s.current=e},[]),disableHoverableContent:i,children:a})};Du.displayName=Su;var Ou=`Tooltip`,[ku,Au]=yu(Ou),ju=e=>{let{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,c=Eu(Ou,e.__scopeTooltip),l=xu(t),[u,d]=q.useState(null),f=ds(),p=q.useRef(0),m=o??c.disableHoverableContent,h=s??c.delayDuration,g=q.useRef(!1),[_,v]=ts({prop:r,defaultProp:i??!1,onChange:e=>{e?(c.onOpen(),document.dispatchEvent(new CustomEvent(wu))):c.onClose(),a?.(e)},caller:Ou}),y=q.useMemo(()=>_?g.current?`delayed-open`:`instant-open`:`closed`,[_]),b=q.useCallback(()=>{window.clearTimeout(p.current),p.current=0,g.current=!1,v(!0)},[v]),x=q.useCallback(()=>{window.clearTimeout(p.current),p.current=0,v(!1)},[v]),S=q.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{g.current=!0,v(!0),p.current=0},h)},[h,v]);return q.useEffect(()=>()=>{p.current&&=(window.clearTimeout(p.current),0)},[]),(0,J.jsx)(lu,{...l,children:(0,J.jsx)(ku,{scope:t,contentId:f,open:_,stateAttribute:y,trigger:u,onTriggerChange:d,onTriggerEnter:q.useCallback(()=>{c.isOpenDelayedRef.current?S():b()},[c.isOpenDelayedRef,S,b]),onTriggerLeave:q.useCallback(()=>{m?x():(window.clearTimeout(p.current),p.current=0)},[x,m]),onOpen:b,onClose:x,disableHoverableContent:m,children:n})})};ju.displayName=Ou;var Mu=`TooltipTrigger`,Nu=q.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=Au(Mu,n),a=Eu(Mu,n),o=xu(n),s=Po(t,q.useRef(null),i.onTriggerChange),c=q.useRef(!1),l=q.useRef(!1),u=q.useCallback(()=>c.current=!1,[]);return q.useEffect(()=>()=>document.removeEventListener(`pointerup`,u),[u]),(0,J.jsx)(uu,{asChild:!0,...o,children:(0,J.jsx)(Uo.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:s,onPointerMove:Qo(e.onPointerMove,e=>{e.pointerType!==`touch`&&!l.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),l.current=!0)}),onPointerLeave:Qo(e.onPointerLeave,()=>{i.onTriggerLeave(),l.current=!1}),onPointerDown:Qo(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener(`pointerup`,u,{once:!0})}),onFocus:Qo(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:Qo(e.onBlur,i.onClose),onClick:Qo(e.onClick,i.onClose)})})});Nu.displayName=Mu;var Pu=`TooltipPortal`,[Fu,Iu]=yu(Pu,{forceMount:void 0}),Lu=e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,a=Au(Pu,t);return(0,J.jsx)(Fu,{scope:t,forceMount:n,children:(0,J.jsx)(as,{present:n||a.open,children:(0,J.jsx)(Os,{asChild:!0,container:i,children:r})})})};Lu.displayName=Pu;var Ru=`TooltipContent`,zu=q.forwardRef((e,t)=>{let n=Iu(Ru,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i=`top`,...a}=e,o=Au(Ru,e.__scopeTooltip);return(0,J.jsx)(as,{present:r||o.open,children:o.disableHoverableContent?(0,J.jsx)(Wu,{side:i,...a,ref:t}):(0,J.jsx)(Bu,{side:i,...a,ref:t})})}),Bu=q.forwardRef((e,t)=>{let n=Au(Ru,e.__scopeTooltip),r=Eu(Ru,e.__scopeTooltip),i=q.useRef(null),a=Po(t,i),[o,s]=q.useState(null),{trigger:c,onClose:l}=n,u=i.current,{onPointerInTransitChange:d}=r,f=q.useCallback(()=>{s(null),d(!1)},[d]),p=q.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},i=Ju(r,qu(r,n.getBoundingClientRect())),a=Yu(t.getBoundingClientRect());s(Zu([...i,...a])),d(!0)},[d]);return q.useEffect(()=>()=>f(),[f]),q.useEffect(()=>{if(c&&u){let e=e=>p(e,u),t=e=>p(e,c);return c.addEventListener(`pointerleave`,e),u.addEventListener(`pointerleave`,t),()=>{c.removeEventListener(`pointerleave`,e),u.removeEventListener(`pointerleave`,t)}}},[c,u,p,f]),q.useEffect(()=>{if(o){let e=e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=c?.contains(t)||u?.contains(t),i=!Xu(n,o);r?f():i&&(f(),l())};return document.addEventListener(`pointermove`,e),()=>document.removeEventListener(`pointermove`,e)}},[c,u,o,l,f]),(0,J.jsx)(Wu,{...e,ref:a})}),[Vu,Hu]=yu(Ou,{isInside:!1}),Uu=zo(`TooltipContent`),Wu=q.forwardRef((e,t)=>{let{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:o,...s}=e,c=Au(Ru,n),l=xu(n),{onClose:u}=c;return q.useEffect(()=>(document.addEventListener(wu,u),()=>document.removeEventListener(wu,u)),[u]),q.useEffect(()=>{if(c.trigger){let e=e=>{e.target?.contains(c.trigger)&&u()};return window.addEventListener(`scroll`,e,{capture:!0}),()=>window.removeEventListener(`scroll`,e,{capture:!0})}},[c.trigger,u]),(0,J.jsx)(bs,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:e=>e.preventDefault(),onDismiss:u,children:(0,J.jsxs)(du,{"data-state":c.stateAttribute,...l,...s,ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-tooltip-content-available-width":`var(--radix-popper-available-width)`,"--radix-tooltip-content-available-height":`var(--radix-popper-available-height)`,"--radix-tooltip-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-tooltip-trigger-height":`var(--radix-popper-anchor-height)`},children:[(0,J.jsx)(Uu,{children:r}),(0,J.jsx)(Vu,{scope:n,isInside:!0,children:(0,J.jsx)(Jo,{id:c.contentId,role:`tooltip`,children:i||r})})]})})});zu.displayName=Ru;var Gu=`TooltipArrow`,Ku=q.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=xu(n);return Hu(Gu,n).isInside?null:(0,J.jsx)(fu,{...i,...r,ref:t})});Ku.displayName=Gu;function qu(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,i,a)){case a:return`left`;case i:return`right`;case n:return`top`;case r:return`bottom`;default:throw Error(`unreachable`)}}function Ju(e,t,n=5){let 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 Yu(e){let{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function Xu(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e],s=t[a],c=o.x,l=o.y,u=s.x,d=s.y;l>r!=d>r&&n<(u-c)*(r-l)/(d-l)+c&&(i=!i)}return i}function Zu(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:+(e.y>t.y)),Qu(t)}function Qu(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n<e.length;n++){let r=e[n];for(;t.length>=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.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 $u=Du,ed=ju,td=Nu,nd=Lu,rd=zu,id=Ku,ad=(e,t)=>{let n=Array(e.length+t.length);for(let t=0;t<e.length;t++)n[t]=e[t];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},od=(e,t)=>({classGroupId:e,validator:t}),sd=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),cd=`-`,ld=[],ud=`arbitrary..`,dd=e=>{let t=md(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return pd(e);let n=e.split(cd);return fd(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?ad(i,t):t:i||ld}return n[e]||ld}}},fd=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=fd(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(cd):e.slice(t).join(cd),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},pd=e=>e.slice(1,-1).indexOf(`:`)===-1?void 0:(()=>{let t=e.slice(1,-1),n=t.indexOf(`:`),r=t.slice(0,n);return r?ud+r:void 0})(),md=e=>{let{theme:t,classGroups:n}=e;return hd(n,t)},hd=(e,t)=>{let n=sd();for(let r in e){let i=e[r];gd(i,n,r,t)}return n},gd=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];_d(i,t,n,r)}},_d=(e,t,n,r)=>{if(typeof e==`string`){vd(e,t,n);return}if(typeof e==`function`){yd(e,t,n,r);return}bd(e,t,n,r)},vd=(e,t,n)=>{let r=e===``?t:xd(t,e);r.classGroupId=n},yd=(e,t,n,r)=>{if(Sd(e)){gd(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(od(n,e))},bd=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];gd(o,xd(t,a),n,r)}},xd=(e,t)=>{let n=e,r=t.split(cd),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=sd(),n.nextPart.set(t,i)),n=i}return n},Sd=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,Cd=e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null),i=(i,a)=>{n[i]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(e){let t=n[e];if(t!==void 0)return t;if((t=r[e])!==void 0)return i(e,t),t},set(e,t){e in n?n[e]=t:i(e,t)}}},wd=`!`,Td=`:`,Ed=[],Dd=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),Od=e=>{let{prefix:t,experimentalParseClassName:n}=e,r=e=>{let t=[],n=0,r=0,i=0,a,o=e.length;for(let s=0;s<o;s++){let o=e[s];if(n===0&&r===0){if(o===Td){t.push(e.slice(i,s)),i=s+1;continue}if(o===`/`){a=s;continue}}o===`[`?n++:o===`]`?n--:o===`(`?r++:o===`)`&&r--}let s=t.length===0?e:e.slice(i),c=s,l=!1;s.endsWith(wd)?(c=s.slice(0,-1),l=!0):s.startsWith(wd)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return Dd(t,l,c,u)};if(t){let e=t+Td,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):Dd(Ed,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},kd=e=>{let t=new Map;return e.orderSensitiveModifiers.forEach((e,n)=>{t.set(e,1e6+n)}),e=>{let n=[],r=[];for(let i=0;i<e.length;i++){let a=e[i],o=a[0]===`[`,s=t.has(a);o||s?(r.length>0&&(r.sort(),n.push(...r),r=[]),n.push(a)):r.push(a)}return r.length>0&&(r.sort(),n.push(...r)),n}},Ad=e=>({cache:Cd(e.cacheSize),parseClassName:Od(e),sortModifiers:kd(e),...dd(e)}),jd=/\s+/,Md=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,o=[],s=e.trim().split(jd),c=``;for(let e=s.length-1;e>=0;--e){let t=s[e],{isExternal:l,modifiers:u,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:p}=n(t);if(l){c=t+(c.length>0?` `+c:c);continue}let m=!!p,h=r(m?f.substring(0,p):f);if(!h){if(!m){c=t+(c.length>0?` `+c:c);continue}if(h=r(f),!h){c=t+(c.length>0?` `+c:c);continue}m=!1}let g=u.length===0?``:u.length===1?u[0]:a(u).join(`:`),_=d?g+wd:g,v=_+h;if(o.indexOf(v)>-1)continue;o.push(v);let y=i(h,m);for(let e=0;e<y.length;++e){let t=y[e];o.push(_+t)}c=t+(c.length>0?` `+c:c)}return c},Nd=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=Pd(n))&&(i&&(i+=` `),i+=r);return i},Pd=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=Pd(e[r]))&&(n&&(n+=` `),n+=t);return n},Fd=(e,...t)=>{let n,r,i,a,o=o=>(n=Ad(t.reduce((e,t)=>t(e),e())),r=n.cache.get,i=n.cache.set,a=s,s(o)),s=e=>{let t=r(e);if(t)return t;let a=Md(e,n);return i(e,a),a};return a=o,(...e)=>a(Nd(...e))},Id=[],Y=e=>{let t=t=>t[e]||Id;return t.isThemeGetter=!0,t},Ld=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Rd=/^\((?:(\w[\w-]*):)?(.+)\)$/i,zd=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,Bd=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Vd=/\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$/,Hd=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Ud=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Wd=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Gd=e=>zd.test(e),X=e=>!!e&&!Number.isNaN(Number(e)),Kd=e=>!!e&&Number.isInteger(Number(e)),qd=e=>e.endsWith(`%`)&&X(e.slice(0,-1)),Jd=e=>Bd.test(e),Yd=()=>!0,Xd=e=>Vd.test(e)&&!Hd.test(e),Zd=()=>!1,Qd=e=>Ud.test(e),$d=e=>Wd.test(e),ef=e=>!Z(e)&&!Q(e),tf=e=>_f(e,xf,Zd),Z=e=>Ld.test(e),nf=e=>_f(e,Sf,Xd),rf=e=>_f(e,Cf,X),af=e=>_f(e,Tf,Yd),of=e=>_f(e,wf,Zd),sf=e=>_f(e,yf,Zd),cf=e=>_f(e,bf,$d),lf=e=>_f(e,Ef,Qd),Q=e=>Rd.test(e),uf=e=>vf(e,Sf),df=e=>vf(e,wf),ff=e=>vf(e,yf),pf=e=>vf(e,xf),mf=e=>vf(e,bf),hf=e=>vf(e,Ef,!0),gf=e=>vf(e,Tf,!0),_f=(e,t,n)=>{let r=Ld.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},vf=(e,t,n=!1)=>{let r=Rd.exec(e);return r?r[1]?t(r[1]):n:!1},yf=e=>e===`position`||e===`percentage`,bf=e=>e===`image`||e===`url`,xf=e=>e===`length`||e===`size`||e===`bg-size`,Sf=e=>e===`length`,Cf=e=>e===`number`,wf=e=>e===`family-name`,Tf=e=>e===`number`||e===`weight`,Ef=e=>e===`shadow`,Df=Fd(()=>{let e=Y(`color`),t=Y(`font`),n=Y(`text`),r=Y(`font-weight`),i=Y(`tracking`),a=Y(`leading`),o=Y(`breakpoint`),s=Y(`container`),c=Y(`spacing`),l=Y(`radius`),u=Y(`shadow`),d=Y(`inset-shadow`),f=Y(`text-shadow`),p=Y(`drop-shadow`),m=Y(`blur`),h=Y(`perspective`),g=Y(`aspect`),_=Y(`ease`),v=Y(`animate`),y=()=>[`auto`,`avoid`,`all`,`avoid-page`,`page`,`left`,`right`,`column`],b=()=>[`center`,`top`,`bottom`,`left`,`right`,`top-left`,`left-top`,`top-right`,`right-top`,`bottom-right`,`right-bottom`,`bottom-left`,`left-bottom`],x=()=>[...b(),Q,Z],S=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],C=()=>[`auto`,`contain`,`none`],w=()=>[Q,Z,c],E=()=>[Gd,`full`,`auto`,...w()],D=()=>[Kd,`none`,`subgrid`,Q,Z],ee=()=>[`auto`,{span:[`full`,Kd,Q,Z]},Kd,Q,Z],O=()=>[Kd,`auto`,Q,Z],k=()=>[`auto`,`min`,`max`,`fr`,Q,Z],A=()=>[`start`,`end`,`center`,`between`,`around`,`evenly`,`stretch`,`baseline`,`center-safe`,`end-safe`],j=()=>[`start`,`end`,`center`,`stretch`,`center-safe`,`end-safe`],M=()=>[`auto`,...w()],N=()=>[Gd,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],P=()=>[Gd,`screen`,`full`,`dvw`,`lvw`,`svw`,`min`,`max`,`fit`,...w()],F=()=>[Gd,`screen`,`full`,`lh`,`dvh`,`lvh`,`svh`,`min`,`max`,`fit`,...w()],I=()=>[e,Q,Z],te=()=>[...b(),ff,sf,{position:[Q,Z]}],ne=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],re=()=>[`auto`,`cover`,`contain`,pf,tf,{size:[Q,Z]}],ie=()=>[qd,uf,nf],L=()=>[``,`none`,`full`,l,Q,Z],R=()=>[``,X,uf,nf],ae=()=>[`solid`,`dashed`,`dotted`,`double`],oe=()=>[`normal`,`multiply`,`screen`,`overlay`,`darken`,`lighten`,`color-dodge`,`color-burn`,`hard-light`,`soft-light`,`difference`,`exclusion`,`hue`,`saturation`,`color`,`luminosity`],z=()=>[X,qd,ff,sf],B=()=>[``,`none`,m,Q,Z],se=()=>[`none`,X,Q,Z],ce=()=>[`none`,X,Q,Z],V=()=>[X,Q,Z],le=()=>[Gd,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[Jd],breakpoint:[Jd],color:[Yd],container:[Jd],"drop-shadow":[Jd],ease:[`in`,`out`,`in-out`],font:[ef],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[Jd],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[Jd],shadow:[Jd],spacing:[`px`,X],text:[Jd],"text-shadow":[Jd],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,Gd,Z,Q,g]}],container:[`container`],columns:[{columns:[X,Z,Q,s]}],"break-after":[{"break-after":y()}],"break-before":[{"break-before":y()}],"break-inside":[{"break-inside":[`auto`,`avoid`,`avoid-page`,`avoid-column`]}],"box-decoration":[{"box-decoration":[`slice`,`clone`]}],box:[{box:[`border`,`content`]}],display:[`block`,`inline-block`,`inline`,`flex`,`inline-flex`,`table`,`inline-table`,`table-caption`,`table-cell`,`table-column`,`table-column-group`,`table-footer-group`,`table-header-group`,`table-row-group`,`table-row`,`flow-root`,`grid`,`inline-grid`,`contents`,`list-item`,`hidden`],sr:[`sr-only`,`not-sr-only`],float:[{float:[`right`,`left`,`none`,`start`,`end`]}],clear:[{clear:[`left`,`right`,`both`,`none`,`start`,`end`]}],isolation:[`isolate`,`isolation-auto`],"object-fit":[{object:[`contain`,`cover`,`fill`,`none`,`scale-down`]}],"object-position":[{object:x()}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:C()}],"overscroll-x":[{"overscroll-x":C()}],"overscroll-y":[{"overscroll-y":C()}],position:[`static`,`fixed`,`absolute`,`relative`,`sticky`],inset:[{inset:E()}],"inset-x":[{"inset-x":E()}],"inset-y":[{"inset-y":E()}],start:[{"inset-s":E(),start:E()}],end:[{"inset-e":E(),end:E()}],"inset-bs":[{"inset-bs":E()}],"inset-be":[{"inset-be":E()}],top:[{top:E()}],right:[{right:E()}],bottom:[{bottom:E()}],left:[{left:E()}],visibility:[`visible`,`invisible`,`collapse`],z:[{z:[Kd,`auto`,Q,Z]}],basis:[{basis:[Gd,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[X,Gd,`auto`,`initial`,`none`,Z]}],grow:[{grow:[``,X,Q,Z]}],shrink:[{shrink:[``,X,Q,Z]}],order:[{order:[Kd,`first`,`last`,`none`,Q,Z]}],"grid-cols":[{"grid-cols":D()}],"col-start-end":[{col:ee()}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":D()}],"row-start-end":[{row:ee()}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":k()}],"auto-rows":[{"auto-rows":k()}],gap:[{gap:w()}],"gap-x":[{"gap-x":w()}],"gap-y":[{"gap-y":w()}],"justify-content":[{justify:[...A(),`normal`]}],"justify-items":[{"justify-items":[...j(),`normal`]}],"justify-self":[{"justify-self":[`auto`,...j()]}],"align-content":[{content:[`normal`,...A()]}],"align-items":[{items:[...j(),{baseline:[``,`last`]}]}],"align-self":[{self:[`auto`,...j(),{baseline:[``,`last`]}]}],"place-content":[{"place-content":A()}],"place-items":[{"place-items":[...j(),`baseline`]}],"place-self":[{"place-self":[`auto`,...j()]}],p:[{p:w()}],px:[{px:w()}],py:[{py:w()}],ps:[{ps:w()}],pe:[{pe:w()}],pbs:[{pbs:w()}],pbe:[{pbe:w()}],pt:[{pt:w()}],pr:[{pr:w()}],pb:[{pb:w()}],pl:[{pl:w()}],m:[{m:M()}],mx:[{mx:M()}],my:[{my:M()}],ms:[{ms:M()}],me:[{me:M()}],mbs:[{mbs:M()}],mbe:[{mbe:M()}],mt:[{mt:M()}],mr:[{mr:M()}],mb:[{mb:M()}],ml:[{ml:M()}],"space-x":[{"space-x":w()}],"space-x-reverse":[`space-x-reverse`],"space-y":[{"space-y":w()}],"space-y-reverse":[`space-y-reverse`],size:[{size:N()}],"inline-size":[{inline:[`auto`,...P()]}],"min-inline-size":[{"min-inline":[`auto`,...P()]}],"max-inline-size":[{"max-inline":[`none`,...P()]}],"block-size":[{block:[`auto`,...F()]}],"min-block-size":[{"min-block":[`auto`,...F()]}],"max-block-size":[{"max-block":[`none`,...F()]}],w:[{w:[s,`screen`,...N()]}],"min-w":[{"min-w":[s,`screen`,`none`,...N()]}],"max-w":[{"max-w":[s,`screen`,`none`,`prose`,{screen:[o]},...N()]}],h:[{h:[`screen`,`lh`,...N()]}],"min-h":[{"min-h":[`screen`,`lh`,`none`,...N()]}],"max-h":[{"max-h":[`screen`,`lh`,...N()]}],"font-size":[{text:[`base`,n,uf,nf]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,gf,af]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,qd,Z]}],"font-family":[{font:[df,of,t]}],"font-features":[{"font-features":[Z]}],"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:[i,Q,Z]}],"line-clamp":[{"line-clamp":[X,`none`,Q,rf]}],leading:[{leading:[a,...w()]}],"list-image":[{"list-image":[`none`,Q,Z]}],"list-style-position":[{list:[`inside`,`outside`]}],"list-style-type":[{list:[`disc`,`decimal`,`none`,Q,Z]}],"text-alignment":[{text:[`left`,`center`,`right`,`justify`,`start`,`end`]}],"placeholder-color":[{placeholder:I()}],"text-color":[{text:I()}],"text-decoration":[`underline`,`overline`,`line-through`,`no-underline`],"text-decoration-style":[{decoration:[...ae(),`wavy`]}],"text-decoration-thickness":[{decoration:[X,`from-font`,`auto`,Q,nf]}],"text-decoration-color":[{decoration:I()}],"underline-offset":[{"underline-offset":[X,`auto`,Q,Z]}],"text-transform":[`uppercase`,`lowercase`,`capitalize`,`normal-case`],"text-overflow":[`truncate`,`text-ellipsis`,`text-clip`],"text-wrap":[{text:[`wrap`,`nowrap`,`balance`,`pretty`]}],indent:[{indent:w()}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,Q,Z]}],whitespace:[{whitespace:[`normal`,`nowrap`,`pre`,`pre-line`,`pre-wrap`,`break-spaces`]}],break:[{break:[`normal`,`words`,`all`,`keep`]}],wrap:[{wrap:[`break-word`,`anywhere`,`normal`]}],hyphens:[{hyphens:[`none`,`manual`,`auto`]}],content:[{content:[`none`,Q,Z]}],"bg-attachment":[{bg:[`fixed`,`local`,`scroll`]}],"bg-clip":[{"bg-clip":[`border`,`padding`,`content`,`text`]}],"bg-origin":[{"bg-origin":[`border`,`padding`,`content`]}],"bg-position":[{bg:te()}],"bg-repeat":[{bg:ne()}],"bg-size":[{bg:re()}],"bg-image":[{bg:[`none`,{linear:[{to:[`t`,`tr`,`r`,`br`,`b`,`bl`,`l`,`tl`]},Kd,Q,Z],radial:[``,Q,Z],conic:[Kd,Q,Z]},mf,cf]}],"bg-color":[{bg:I()}],"gradient-from-pos":[{from:ie()}],"gradient-via-pos":[{via:ie()}],"gradient-to-pos":[{to:ie()}],"gradient-from":[{from:I()}],"gradient-via":[{via:I()}],"gradient-to":[{to:I()}],rounded:[{rounded:L()}],"rounded-s":[{"rounded-s":L()}],"rounded-e":[{"rounded-e":L()}],"rounded-t":[{"rounded-t":L()}],"rounded-r":[{"rounded-r":L()}],"rounded-b":[{"rounded-b":L()}],"rounded-l":[{"rounded-l":L()}],"rounded-ss":[{"rounded-ss":L()}],"rounded-se":[{"rounded-se":L()}],"rounded-ee":[{"rounded-ee":L()}],"rounded-es":[{"rounded-es":L()}],"rounded-tl":[{"rounded-tl":L()}],"rounded-tr":[{"rounded-tr":L()}],"rounded-br":[{"rounded-br":L()}],"rounded-bl":[{"rounded-bl":L()}],"border-w":[{border:R()}],"border-w-x":[{"border-x":R()}],"border-w-y":[{"border-y":R()}],"border-w-s":[{"border-s":R()}],"border-w-e":[{"border-e":R()}],"border-w-bs":[{"border-bs":R()}],"border-w-be":[{"border-be":R()}],"border-w-t":[{"border-t":R()}],"border-w-r":[{"border-r":R()}],"border-w-b":[{"border-b":R()}],"border-w-l":[{"border-l":R()}],"divide-x":[{"divide-x":R()}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":R()}],"divide-y-reverse":[`divide-y-reverse`],"border-style":[{border:[...ae(),`hidden`,`none`]}],"divide-style":[{divide:[...ae(),`hidden`,`none`]}],"border-color":[{border:I()}],"border-color-x":[{"border-x":I()}],"border-color-y":[{"border-y":I()}],"border-color-s":[{"border-s":I()}],"border-color-e":[{"border-e":I()}],"border-color-bs":[{"border-bs":I()}],"border-color-be":[{"border-be":I()}],"border-color-t":[{"border-t":I()}],"border-color-r":[{"border-r":I()}],"border-color-b":[{"border-b":I()}],"border-color-l":[{"border-l":I()}],"divide-color":[{divide:I()}],"outline-style":[{outline:[...ae(),`none`,`hidden`]}],"outline-offset":[{"outline-offset":[X,Q,Z]}],"outline-w":[{outline:[``,X,uf,nf]}],"outline-color":[{outline:I()}],shadow:[{shadow:[``,`none`,u,hf,lf]}],"shadow-color":[{shadow:I()}],"inset-shadow":[{"inset-shadow":[`none`,d,hf,lf]}],"inset-shadow-color":[{"inset-shadow":I()}],"ring-w":[{ring:R()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:I()}],"ring-offset-w":[{"ring-offset":[X,nf]}],"ring-offset-color":[{"ring-offset":I()}],"inset-ring-w":[{"inset-ring":R()}],"inset-ring-color":[{"inset-ring":I()}],"text-shadow":[{"text-shadow":[`none`,f,hf,lf]}],"text-shadow-color":[{"text-shadow":I()}],opacity:[{opacity:[X,Q,Z]}],"mix-blend":[{"mix-blend":[...oe(),`plus-darker`,`plus-lighter`]}],"bg-blend":[{"bg-blend":oe()}],"mask-clip":[{"mask-clip":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]},`mask-no-clip`],"mask-composite":[{mask:[`add`,`subtract`,`intersect`,`exclude`]}],"mask-image-linear-pos":[{"mask-linear":[X]}],"mask-image-linear-from-pos":[{"mask-linear-from":z()}],"mask-image-linear-to-pos":[{"mask-linear-to":z()}],"mask-image-linear-from-color":[{"mask-linear-from":I()}],"mask-image-linear-to-color":[{"mask-linear-to":I()}],"mask-image-t-from-pos":[{"mask-t-from":z()}],"mask-image-t-to-pos":[{"mask-t-to":z()}],"mask-image-t-from-color":[{"mask-t-from":I()}],"mask-image-t-to-color":[{"mask-t-to":I()}],"mask-image-r-from-pos":[{"mask-r-from":z()}],"mask-image-r-to-pos":[{"mask-r-to":z()}],"mask-image-r-from-color":[{"mask-r-from":I()}],"mask-image-r-to-color":[{"mask-r-to":I()}],"mask-image-b-from-pos":[{"mask-b-from":z()}],"mask-image-b-to-pos":[{"mask-b-to":z()}],"mask-image-b-from-color":[{"mask-b-from":I()}],"mask-image-b-to-color":[{"mask-b-to":I()}],"mask-image-l-from-pos":[{"mask-l-from":z()}],"mask-image-l-to-pos":[{"mask-l-to":z()}],"mask-image-l-from-color":[{"mask-l-from":I()}],"mask-image-l-to-color":[{"mask-l-to":I()}],"mask-image-x-from-pos":[{"mask-x-from":z()}],"mask-image-x-to-pos":[{"mask-x-to":z()}],"mask-image-x-from-color":[{"mask-x-from":I()}],"mask-image-x-to-color":[{"mask-x-to":I()}],"mask-image-y-from-pos":[{"mask-y-from":z()}],"mask-image-y-to-pos":[{"mask-y-to":z()}],"mask-image-y-from-color":[{"mask-y-from":I()}],"mask-image-y-to-color":[{"mask-y-to":I()}],"mask-image-radial":[{"mask-radial":[Q,Z]}],"mask-image-radial-from-pos":[{"mask-radial-from":z()}],"mask-image-radial-to-pos":[{"mask-radial-to":z()}],"mask-image-radial-from-color":[{"mask-radial-from":I()}],"mask-image-radial-to-color":[{"mask-radial-to":I()}],"mask-image-radial-shape":[{"mask-radial":[`circle`,`ellipse`]}],"mask-image-radial-size":[{"mask-radial":[{closest:[`side`,`corner`],farthest:[`side`,`corner`]}]}],"mask-image-radial-pos":[{"mask-radial-at":b()}],"mask-image-conic-pos":[{"mask-conic":[X]}],"mask-image-conic-from-pos":[{"mask-conic-from":z()}],"mask-image-conic-to-pos":[{"mask-conic-to":z()}],"mask-image-conic-from-color":[{"mask-conic-from":I()}],"mask-image-conic-to-color":[{"mask-conic-to":I()}],"mask-mode":[{mask:[`alpha`,`luminance`,`match`]}],"mask-origin":[{"mask-origin":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]}],"mask-position":[{mask:te()}],"mask-repeat":[{mask:ne()}],"mask-size":[{mask:re()}],"mask-type":[{"mask-type":[`alpha`,`luminance`]}],"mask-image":[{mask:[`none`,Q,Z]}],filter:[{filter:[``,`none`,Q,Z]}],blur:[{blur:B()}],brightness:[{brightness:[X,Q,Z]}],contrast:[{contrast:[X,Q,Z]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,hf,lf]}],"drop-shadow-color":[{"drop-shadow":I()}],grayscale:[{grayscale:[``,X,Q,Z]}],"hue-rotate":[{"hue-rotate":[X,Q,Z]}],invert:[{invert:[``,X,Q,Z]}],saturate:[{saturate:[X,Q,Z]}],sepia:[{sepia:[``,X,Q,Z]}],"backdrop-filter":[{"backdrop-filter":[``,`none`,Q,Z]}],"backdrop-blur":[{"backdrop-blur":B()}],"backdrop-brightness":[{"backdrop-brightness":[X,Q,Z]}],"backdrop-contrast":[{"backdrop-contrast":[X,Q,Z]}],"backdrop-grayscale":[{"backdrop-grayscale":[``,X,Q,Z]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[X,Q,Z]}],"backdrop-invert":[{"backdrop-invert":[``,X,Q,Z]}],"backdrop-opacity":[{"backdrop-opacity":[X,Q,Z]}],"backdrop-saturate":[{"backdrop-saturate":[X,Q,Z]}],"backdrop-sepia":[{"backdrop-sepia":[``,X,Q,Z]}],"border-collapse":[{border:[`collapse`,`separate`]}],"border-spacing":[{"border-spacing":w()}],"border-spacing-x":[{"border-spacing-x":w()}],"border-spacing-y":[{"border-spacing-y":w()}],"table-layout":[{table:[`auto`,`fixed`]}],caption:[{caption:[`top`,`bottom`]}],transition:[{transition:[``,`all`,`colors`,`opacity`,`shadow`,`transform`,`none`,Q,Z]}],"transition-behavior":[{transition:[`normal`,`discrete`]}],duration:[{duration:[X,`initial`,Q,Z]}],ease:[{ease:[`linear`,`initial`,_,Q,Z]}],delay:[{delay:[X,Q,Z]}],animate:[{animate:[`none`,v,Q,Z]}],backface:[{backface:[`hidden`,`visible`]}],perspective:[{perspective:[h,Q,Z]}],"perspective-origin":[{"perspective-origin":x()}],rotate:[{rotate:se()}],"rotate-x":[{"rotate-x":se()}],"rotate-y":[{"rotate-y":se()}],"rotate-z":[{"rotate-z":se()}],scale:[{scale:ce()}],"scale-x":[{"scale-x":ce()}],"scale-y":[{"scale-y":ce()}],"scale-z":[{"scale-z":ce()}],"scale-3d":[`scale-3d`],skew:[{skew:V()}],"skew-x":[{"skew-x":V()}],"skew-y":[{"skew-y":V()}],transform:[{transform:[Q,Z,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:le()}],"translate-x":[{"translate-x":le()}],"translate-y":[{"translate-y":le()}],"translate-z":[{"translate-z":le()}],"translate-none":[`translate-none`],accent:[{accent:I()}],appearance:[{appearance:[`none`,`auto`]}],"caret-color":[{caret:I()}],"color-scheme":[{scheme:[`normal`,`dark`,`light`,`light-dark`,`only-dark`,`only-light`]}],cursor:[{cursor:[`auto`,`default`,`pointer`,`wait`,`text`,`move`,`help`,`not-allowed`,`none`,`context-menu`,`progress`,`cell`,`crosshair`,`vertical-text`,`alias`,`copy`,`no-drop`,`grab`,`grabbing`,`all-scroll`,`col-resize`,`row-resize`,`n-resize`,`e-resize`,`s-resize`,`w-resize`,`ne-resize`,`nw-resize`,`se-resize`,`sw-resize`,`ew-resize`,`ns-resize`,`nesw-resize`,`nwse-resize`,`zoom-in`,`zoom-out`,Q,Z]}],"field-sizing":[{"field-sizing":[`fixed`,`content`]}],"pointer-events":[{"pointer-events":[`auto`,`none`]}],resize:[{resize:[`none`,``,`y`,`x`]}],"scroll-behavior":[{scroll:[`auto`,`smooth`]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-me":[{"scroll-me":w()}],"scroll-mbs":[{"scroll-mbs":w()}],"scroll-mbe":[{"scroll-mbe":w()}],"scroll-mt":[{"scroll-mt":w()}],"scroll-mr":[{"scroll-mr":w()}],"scroll-mb":[{"scroll-mb":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-pe":[{"scroll-pe":w()}],"scroll-pbs":[{"scroll-pbs":w()}],"scroll-pbe":[{"scroll-pbe":w()}],"scroll-pt":[{"scroll-pt":w()}],"scroll-pr":[{"scroll-pr":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"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`,Q,Z]}],fill:[{fill:[`none`,...I()]}],"stroke-w":[{stroke:[X,uf,nf,rf]}],stroke:[{stroke:[`none`,...I()]}],"forced-color-adjust":[{"forced-color-adjust":[`auto`,`none`]}]},conflictingClassGroups:{overflow:[`overflow-x`,`overflow-y`],overscroll:[`overscroll-x`,`overscroll-y`],inset:[`inset-x`,`inset-y`,`inset-bs`,`inset-be`,`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`,`pbs`,`pbe`,`pt`,`pr`,`pb`,`pl`],px:[`pr`,`pl`],py:[`pt`,`pb`],m:[`mx`,`my`,`ms`,`me`,`mbs`,`mbe`,`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-x`,`border-w-y`,`border-w-s`,`border-w-e`,`border-w-bs`,`border-w-be`,`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-x`,`border-color-y`,`border-color-s`,`border-color-e`,`border-color-bs`,`border-color-be`,`border-color-t`,`border-color-r`,`border-color-b`,`border-color-l`],"border-color-x":[`border-color-r`,`border-color-l`],"border-color-y":[`border-color-t`,`border-color-b`],translate:[`translate-x`,`translate-y`,`translate-none`],"translate-none":[`translate`,`translate-x`,`translate-y`,`translate-z`],"scroll-m":[`scroll-mx`,`scroll-my`,`scroll-ms`,`scroll-me`,`scroll-mbs`,`scroll-mbe`,`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-pbs`,`scroll-pbe`,`scroll-pt`,`scroll-pr`,`scroll-pb`,`scroll-pl`],"scroll-px":[`scroll-pr`,`scroll-pl`],"scroll-py":[`scroll-pt`,`scroll-pb`],touch:[`touch-x`,`touch-y`,`touch-pz`],"touch-x":[`touch`],"touch-y":[`touch`],"touch-pz":[`touch`]},conflictingClassGroupModifiers:{"font-size":[`leading`]},orderSensitiveModifiers:[`*`,`**`,`after`,`backdrop`,`before`,`details-content`,`file`,`first-letter`,`first-line`,`marker`,`placeholder`,`selection`]}});function $(...e){return Df(n(e))}var Of=jo(`focus-visible:border-ring focus-visible:ring-ring/30 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 rounded-md border border-transparent bg-clip-padding text-xs/relaxed font-medium focus-visible:ring-[2px] aria-invalid:ring-[2px] [&_svg:not([class*='size-'])]:size-4 inline-flex items-center justify-center whitespace-nowrap cursor-pointer transition-all disabled:pointer-events-none disabled:opacity-50 disabled:cursor-not-allowed [&_svg]:pointer-events-none shrink-0 [&_svg]:shrink-0 outline-none group/button select-none`,{variants:{variant:{default:`bg-primary text-primary-foreground hover:bg-primary/80`,outline:`border-border dark:bg-input/30 hover:bg-input/50 hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground`,secondary:`bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground`,ghost:`hover:bg-muted hover:text-foreground dark:hover:bg-muted/50 aria-expanded:bg-muted aria-expanded:text-foreground`,destructive:`bg-destructive/10 hover:bg-destructive/20 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/20 text-destructive focus-visible:border-destructive/40 dark:hover:bg-destructive/30`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-7 gap-1 px-2 text-xs/relaxed has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5`,xs:`h-5 gap-1 rounded-sm px-2 text-[0.625rem] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-2.5`,sm:`h-6 gap-1 px-2 text-xs/relaxed has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3`,lg:`h-8 gap-1 px-2.5 text-xs/relaxed has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2 [&_svg:not([class*='size-'])]:size-4`,icon:`size-7 [&_svg:not([class*='size-'])]:size-3.5`,"icon-xs":`size-5 rounded-sm [&_svg:not([class*='size-'])]:size-2.5`,"icon-sm":`size-6 [&_svg:not([class*='size-'])]:size-3`,"icon-lg":`size-8 [&_svg:not([class*='size-'])]:size-4`}},defaultVariants:{variant:`default`,size:`default`}});function kf({className:e,variant:t=`default`,size:n=`default`,asChild:r=!1,...i}){return(0,J.jsx)(r?Io:`button`,{"data-slot":`button`,"data-variant":t,"data-size":n,className:$(Of({variant:t,size:n,className:e})),...i})}function Af({className:e,type:t,...n}){return(0,J.jsx)(`input`,{type:t,"data-slot":`input`,className:$(`bg-input/20 dark:bg-input/30 border-input focus-visible:border-ring focus-visible:ring-ring/30 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 h-7 rounded-md border px-2 py-0.5 text-sm transition-colors file:h-6 file:text-xs/relaxed file:font-medium focus-visible:ring-[2px] aria-invalid:ring-[2px] md:text-xs/relaxed file:text-foreground placeholder:text-muted-foreground w-full min-w-0 outline-none file:inline-flex file:border-0 file:bg-transparent disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,e),...n})}function jf({className:e,orientation:t=`horizontal`,decorative:n=!0,...r}){return(0,J.jsx)(vu,{"data-slot":`separator`,decorative:n,orientation:t,className:$(`bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:w-px data-[orientation=vertical]:self-stretch`,e),...r})}function Mf({className:e,...t}){return(0,J.jsx)(`div`,{"data-slot":`skeleton`,className:$(`bg-muted rounded-md animate-pulse`,e),...t})}function Nf({delayDuration:e=0,...t}){return(0,J.jsx)($u,{"data-slot":`tooltip-provider`,delayDuration:e,...t})}function Pf({...e}){return(0,J.jsx)(Nf,{children:(0,J.jsx)(ed,{"data-slot":`tooltip`,...e})})}function Ff({...e}){return(0,J.jsx)(td,{"data-slot":`tooltip-trigger`,...e})}function If({className:e,sideOffset:t=0,children:n,...r}){return(0,J.jsx)(nd,{children:(0,J.jsxs)(rd,{"data-slot":`tooltip-content`,sideOffset:t,className:$(`data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-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 rounded-md px-3 py-1.5 text-xs **:data-[slot=kbd]:rounded-md bg-foreground text-background z-50 w-fit max-w-xs origin-(--radix-tooltip-content-transform-origin)`,e),...r,children:[n,(0,J.jsx)(id,{className:`size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground z-50 translate-y-[calc(-50%_-_2px)]`})]})})}var Lf=768;function Rf(){let[e,t]=q.useState(void 0);return q.useEffect(()=>{if(typeof window>`u`)return;if(typeof window.matchMedia!=`function`){t(window.innerWidth<Lf);return}let e=window.matchMedia(`(max-width: ${Lf-1}px)`),n=()=>{t(window.innerWidth<Lf)};return e.addEventListener(`change`,n),t(window.innerWidth<Lf),()=>e.removeEventListener(`change`,n)},[]),!!e}var zf=`sidebar_state`,Bf=3600*24*7,Vf=`16rem`,Hf=`18rem`,Uf=`3rem`,Wf=`b`,Gf=q.createContext(null);function Kf(){let e=q.useContext(Gf);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function qf({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:i,children:a,...o}){let s=Rf(),[c,l]=q.useState(!1),[u,d]=q.useState(e),f=t??u,p=q.useCallback(e=>{let t=typeof e==`function`?e(f):e;n?n(t):d(t),document.cookie=`${zf}=${t}; path=/; max-age=${Bf}`},[n,f]),m=q.useCallback(()=>s?l(e=>!e):p(e=>!e),[s,p,l]);q.useEffect(()=>{let e=e=>{e.key===Wf&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),m())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[m]),q.useEffect(()=>{if(typeof window>`u`||!s)return;let e=window.document.documentElement,t=window.document.body,n=window.document.querySelector(`meta[name="theme-color"]`),r=getComputedStyle(e).getPropertyValue(`--sidebar`),i=t.style.backgroundColor,a=n?.getAttribute(`content`);c&&(t.style.backgroundColor=r,n?.setAttribute(`content`,r));let o=()=>{window.dispatchEvent(new Event(`hot-updater:refresh-theme-chrome`))},l=window.setTimeout(()=>{if(c){t.style.backgroundColor=r,n?.setAttribute(`content`,r);return}o()},180);return()=>{window.clearTimeout(l),t.style.backgroundColor=i,a&&n?.setAttribute(`content`,a),c||o()}},[s,c]);let h=f?`expanded`:`collapsed`,g=q.useMemo(()=>({state:h,open:f,setOpen:p,isMobile:s,openMobile:c,setOpenMobile:l,toggleSidebar:m}),[h,f,p,s,c,l,m]);return(0,J.jsx)(Gf.Provider,{value:g,children:(0,J.jsx)(`div`,{"data-slot":`sidebar-wrapper`,style:{"--sidebar-width":Vf,"--sidebar-width-icon":Uf,...i},className:$(`group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full`,r),...o,children:a})})}function Jf({side:e=`left`,variant:t=`sidebar`,collapsible:n=`offExamples`,className:r,children:i,...a}){let{isMobile:o,state:s,openMobile:c,setOpenMobile:l}=Kf();return n===`none`?(0,J.jsx)(`div`,{"data-slot":`sidebar`,className:$(`bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col`,r),...a,children:i}):o?c?(0,J.jsxs)(`div`,{"data-sidebar":`sidebar`,"data-slot":`sidebar`,"data-mobile":`true`,className:`fixed inset-0 z-50 md:hidden`,...a,children:[(0,J.jsx)(`button`,{type:`button`,"aria-label":`Close sidebar`,className:`absolute inset-0 bg-sidebar/55 supports-backdrop-filter:backdrop-blur-sm`,onClick:()=>l(!1)}),(0,J.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,"aria-label":`Sidebar`,className:$(`bg-sidebar text-sidebar-foreground absolute inset-y-0 z-10 flex w-(--sidebar-width) flex-col shadow-lg`,e===`left`?`left-0`:`right-0`),style:{"--sidebar-width":Hf},children:[(0,J.jsx)(`div`,{className:`pointer-events-none absolute inset-x-0 top-full h-32 bg-sidebar`}),(0,J.jsx)(`div`,{className:`flex h-full w-full flex-col overflow-y-auto bg-sidebar`,children:i})]})]}):null:(0,J.jsxs)(`div`,{className:`group peer text-sidebar-foreground hidden md:block`,"data-state":s,"data-collapsible":s===`collapsed`?n:``,"data-variant":t,"data-side":e,"data-slot":`sidebar`,children:[(0,J.jsx)(`div`,{"data-slot":`sidebar-gap`,className:$(`transition-[width] duration-200 ease-linear relative w-(--sidebar-width) bg-transparent`,`group-data-[collapsible=offExamples]:w-0`,`group-data-[side=right]:rotate-180`,t===`floating`||t===`inset`?`group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`)}),(0,J.jsx)(`div`,{"data-slot":`sidebar-container`,className:$(`fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex`,e===`left`?`left-0 group-data-[collapsible=offExamples]:left-[calc(var(--sidebar-width)*-1)]`:`right-0 group-data-[collapsible=offExamples]:right-[calc(var(--sidebar-width)*-1)]`,t===`floating`||t===`inset`?`p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l`,r),...a,children:(0,J.jsx)(`div`,{"data-sidebar":`sidebar`,"data-slot":`sidebar-inner`,className:`bg-sidebar group-data-[variant=floating]:ring-sidebar-border group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1 flex size-full flex-col`,children:i})})]})}function Yf({className:e,onClick:t,...n}){let{toggleSidebar:r}=Kf();return(0,J.jsxs)(kf,{"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,variant:`ghost`,size:`icon-sm`,className:$(e),onClick:e=>{t?.(e),r()},...n,children:[(0,J.jsx)(Eo,{}),(0,J.jsx)(`span`,{className:`sr-only`,children:`Toggle Sidebar`})]})}function Xf({className:e,...t}){return(0,J.jsx)(`main`,{"data-slot":`sidebar-inset`,className:$(`bg-background md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2 relative flex w-full flex-1 flex-col`,e),...t})}function Zf({className:e,...t}){return(0,J.jsx)(`div`,{"data-slot":`sidebar-header`,"data-sidebar":`header`,className:$(`gap-2 p-2 flex flex-col`,e),...t})}function Qf({className:e,...t}){return(0,J.jsx)(`div`,{"data-slot":`sidebar-footer`,"data-sidebar":`footer`,className:$(`gap-2 p-2 flex flex-col`,e),...t})}function $f({className:e,...t}){return(0,J.jsx)(`div`,{"data-slot":`sidebar-content`,"data-sidebar":`content`,className:$(`no-scrollbar gap-0 flex min-h-0 flex-1 flex-col overflow-auto group-data-[collapsible=icon]:overflow-hidden`,e),...t})}function ep({className:e,...t}){return(0,J.jsx)(`div`,{"data-slot":`sidebar-group`,"data-sidebar":`group`,className:$(`px-2 py-1 relative flex w-full min-w-0 flex-col`,e),...t})}function tp({className:e,asChild:t=!1,...n}){return(0,J.jsx)(t?Io:`div`,{"data-slot":`sidebar-group-label`,"data-sidebar":`group-label`,className:$(`text-sidebar-foreground/70 ring-sidebar-ring h-8 rounded-md px-2 text-xs transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 flex shrink-0 items-center outline-hidden [&>svg]:shrink-0`,e),...n})}function np({className:e,...t}){return(0,J.jsx)(`div`,{"data-slot":`sidebar-group-content`,"data-sidebar":`group-content`,className:$(`text-xs w-full`,e),...t})}function rp({className:e,...t}){return(0,J.jsx)(`ul`,{"data-slot":`sidebar-menu`,"data-sidebar":`menu`,className:$(`gap-px flex w-full min-w-0 flex-col`,e),...t})}function ip({className:e,...t}){return(0,J.jsx)(`li`,{"data-slot":`sidebar-menu-item`,"data-sidebar":`menu-item`,className:$(`group/menu-item relative`,e),...t})}var ap=jo(`ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground gap-2 rounded-[calc(var(--radius-sm)+2px)] p-2 text-left text-xs transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! focus-visible:ring-2 data-active:font-medium peer/menu-button flex w-full items-center overflow-hidden outline-hidden disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&_svg]:size-4 [&_svg]:shrink-0`,{variants:{variant:{default:`hover:bg-sidebar-accent hover:text-sidebar-accent-foreground`,outline:`bg-background hover:bg-sidebar-accent hover:text-sidebar-accent-foreground shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]`},size:{default:`h-8 text-xs`,sm:`h-7 text-xs`,lg:`h-12 text-xs group-data-[collapsible=icon]:p-0!`}},defaultVariants:{variant:`default`,size:`default`}});function op({asChild:e=!1,isActive:t=!1,variant:n=`default`,size:r=`default`,tooltip:i,className:a,...o}){let s=e?Io:`button`,{isMobile:c,state:l}=Kf(),u=(0,J.jsx)(s,{"data-slot":`sidebar-menu-button`,"data-sidebar":`menu-button`,"data-size":r,"data-active":t,className:$(ap({variant:n,size:r}),a),...o});return i?(typeof i==`string`&&(i={children:i}),(0,J.jsxs)(Pf,{children:[(0,J.jsx)(Ff,{asChild:!0,children:u}),(0,J.jsx)(If,{side:`right`,align:`center`,hidden:l!==`collapsed`||c,...i})]})):u}function sp(e){if(!e||typeof document>`u`)return;let t=document.head||document.getElementsByTagName(`head`)[0],n=document.createElement(`style`);n.type=`text/css`,t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}var cp=e=>{switch(e){case`success`:return dp;case`info`:return pp;case`warning`:return fp;case`error`:return mp;default:return null}},lp=Array(12).fill(0),up=({visible:e,className:t})=>q.createElement(`div`,{className:[`sonner-loading-wrapper`,t].filter(Boolean).join(` `),"data-visible":e},q.createElement(`div`,{className:`sonner-spinner`},lp.map((e,t)=>q.createElement(`div`,{className:`sonner-loading-bar`,key:`spinner-bar-${t}`})))),dp=q.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},q.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`})),fp=q.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 24 24`,fill:`currentColor`,height:`20`,width:`20`},q.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`})),pp=q.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},q.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`})),mp=q.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},q.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`})),hp=q.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`},q.createElement(`line`,{x1:`18`,y1:`6`,x2:`6`,y2:`18`}),q.createElement(`line`,{x1:`6`,y1:`6`,x2:`18`,y2:`18`})),gp=()=>{let[e,t]=q.useState(document.hidden);return q.useEffect(()=>{let e=()=>{t(document.hidden)};return document.addEventListener(`visibilitychange`,e),()=>window.removeEventListener(`visibilitychange`,e)},[]),e},_p=1,vp=new 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=>{let{message:t,...n}=e,r=typeof e?.id==`number`||e.id?.length>0?e.id:_p++,i=this.toasts.find(e=>e.id===r),a=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(r)&&this.dismissedToasts.delete(r),i?this.toasts=this.toasts.map(n=>n.id===r?(this.publish({...n,...e,id:r,title:t}),{...n,...e,id:r,dismissible:a,title:t}):n):this.addToast({title:t,...n,dismissible:a,id:r}),r},this.dismiss=e=>(e?(this.dismissedToasts.add(e),requestAnimationFrame(()=>this.subscribers.forEach(t=>t({id:e,dismiss:!0})))):this.toasts.forEach(e=>{this.subscribers.forEach(t=>t({id:e.id,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`?void 0:t.description}));let r=Promise.resolve(e instanceof Function?e():e),i=n!==void 0,a,o=r.then(async e=>{if(a=[`resolve`,e],q.isValidElement(e))i=!1,this.create({id:n,type:`default`,message:e});else if(bp(e)&&!e.ok){i=!1;let r=typeof t.error==`function`?await t.error(`HTTP error! status: ${e.status}`):t.error,a=typeof t.description==`function`?await t.description(`HTTP error! status: ${e.status}`):t.description,o=typeof r==`object`&&!q.isValidElement(r)?r:{message:r};this.create({id:n,type:`error`,description:a,...o})}else if(e instanceof Error){i=!1;let r=typeof t.error==`function`?await t.error(e):t.error,a=typeof t.description==`function`?await t.description(e):t.description,o=typeof r==`object`&&!q.isValidElement(r)?r:{message:r};this.create({id:n,type:`error`,description:a,...o})}else if(t.success!==void 0){i=!1;let r=typeof t.success==`function`?await t.success(e):t.success,a=typeof t.description==`function`?await t.description(e):t.description,o=typeof r==`object`&&!q.isValidElement(r)?r:{message:r};this.create({id:n,type:`success`,description:a,...o})}}).catch(async e=>{if(a=[`reject`,e],t.error!==void 0){i=!1;let r=typeof t.error==`function`?await t.error(e):t.error,a=typeof t.description==`function`?await t.description(e):t.description,o=typeof r==`object`&&!q.isValidElement(r)?r:{message:r};this.create({id:n,type:`error`,description:a,...o})}}).finally(()=>{i&&(this.dismiss(n),n=void 0),t.finally==null||t.finally.call(t)}),s=()=>new Promise((e,t)=>o.then(()=>a[0]===`reject`?t(a[1]):e(a[1])).catch(t));return typeof n!=`string`&&typeof n!=`number`?{unwrap:s}:Object.assign(n,{unwrap:s})},this.custom=(e,t)=>{let n=t?.id||_p++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},yp=(e,t)=>{let n=t?.id||_p++;return vp.addToast({title:e,...t,id:n}),n},bp=e=>e&&typeof e==`object`&&`ok`in e&&typeof e.ok==`boolean`&&`status`in e&&typeof e.status==`number`,xp=Object.assign(yp,{success:vp.success,info:vp.info,warning:vp.warning,error:vp.error,custom:vp.custom,message:vp.message,promise:vp.promise,dismiss:vp.dismiss,loading:vp.loading},{getHistory:()=>vp.toasts,getToasts:()=>vp.getActiveToasts()});sp(`[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}`);function Sp(e){return e.label!==void 0}var Cp=3,wp=`24px`,Tp=`16px`,Ep=4e3,Dp=356,Op=14,kp=45,Ap=200;function jp(...e){return e.filter(Boolean).join(` `)}function Mp(e){let[t,n]=e.split(`-`),r=[];return t&&r.push(t),n&&r.push(n),r}var Np=e=>{let{invert:t,toast:n,unstyled:r,interacting:i,setHeights:a,visibleToasts:o,heights:s,index:c,toasts:l,expanded:u,removeToast:d,defaultRichColors:f,closeButton:p,style:m,cancelButtonStyle:h,actionButtonStyle:g,className:_=``,descriptionClassName:v=``,duration:y,position:b,gap:x,expandByDefault:S,classNames:C,icons:w,closeButtonAriaLabel:E=`Close toast`}=e,[D,ee]=q.useState(null),[O,k]=q.useState(null),[A,j]=q.useState(!1),[M,N]=q.useState(!1),[P,F]=q.useState(!1),[I,te]=q.useState(!1),[ne,re]=q.useState(!1),[ie,L]=q.useState(0),[R,ae]=q.useState(0),oe=q.useRef(n.duration||y||Ep),z=q.useRef(null),B=q.useRef(null),se=c===0,ce=c+1<=o,V=n.type,le=n.dismissible!==!1,ue=n.className||``,de=n.descriptionClassName||``,fe=q.useMemo(()=>s.findIndex(e=>e.toastId===n.id)||0,[s,n.id]),pe=q.useMemo(()=>n.closeButton??p,[n.closeButton,p]),me=q.useMemo(()=>n.duration||y||Ep,[n.duration,y]),he=q.useRef(0),ge=q.useRef(0),_e=q.useRef(0),ve=q.useRef(null),[ye,be]=b.split(`-`),xe=q.useMemo(()=>s.reduce((e,t,n)=>n>=fe?e:e+t.height,0),[s,fe]),Se=gp(),Ce=n.invert||t,we=V===`loading`;ge.current=q.useMemo(()=>fe*x+xe,[fe,xe]),q.useEffect(()=>{oe.current=me},[me]),q.useEffect(()=>{j(!0)},[]),q.useEffect(()=>{let e=B.current;if(e){let t=e.getBoundingClientRect().height;return ae(t),a(e=>[{toastId:n.id,height:t,position:n.position},...e]),()=>a(e=>e.filter(e=>e.toastId!==n.id))}},[a,n.id]),q.useLayoutEffect(()=>{if(!A)return;let e=B.current,t=e.style.height;e.style.height=`auto`;let r=e.getBoundingClientRect().height;e.style.height=t,ae(r),a(e=>e.find(e=>e.toastId===n.id)?e.map(e=>e.toastId===n.id?{...e,height:r}:e):[{toastId:n.id,height:r,position:n.position},...e])},[A,n.title,n.description,a,n.id,n.jsx,n.action,n.cancel]);let Te=q.useCallback(()=>{N(!0),L(ge.current),a(e=>e.filter(e=>e.toastId!==n.id)),setTimeout(()=>{d(n)},Ap)},[n,d,a,ge]);q.useEffect(()=>{if(n.promise&&V===`loading`||n.duration===1/0||n.type===`loading`)return;let e;return u||i||Se?(()=>{if(_e.current<he.current){let e=new Date().getTime()-he.current;oe.current-=e}_e.current=new Date().getTime()})():oe.current!==1/0&&(he.current=new Date().getTime(),e=setTimeout(()=>{n.onAutoClose==null||n.onAutoClose.call(n,n),Te()},oe.current)),()=>clearTimeout(e)},[u,i,n,V,Se,Te]),q.useEffect(()=>{n.delete&&(Te(),n.onDismiss==null||n.onDismiss.call(n,n))},[Te,n.delete]);function Ee(){return w?.loading?q.createElement(`div`,{className:jp(C?.loader,n?.classNames?.loader,`sonner-loader`),"data-visible":V===`loading`},w.loading):q.createElement(up,{className:jp(C?.loader,n?.classNames?.loader),visible:V===`loading`})}let De=n.icon||w?.[V]||cp(V);return q.createElement(`li`,{tabIndex:0,ref:B,className:jp(_,ue,C?.toast,n?.classNames?.toast,C?.default,C?.[V],n?.classNames?.[V]),"data-sonner-toast":``,"data-rich-colors":n.richColors??f,"data-styled":!(n.jsx||n.unstyled||r),"data-mounted":A,"data-promise":!!n.promise,"data-swiped":ne,"data-removed":M,"data-visible":ce,"data-y-position":ye,"data-x-position":be,"data-index":c,"data-front":se,"data-swiping":P,"data-dismissible":le,"data-type":V,"data-invert":Ce,"data-swipe-out":I,"data-swipe-direction":O,"data-expanded":!!(u||S&&A),"data-testid":n.testId,style:{"--index":c,"--toasts-before":c,"--z-index":l.length-c,"--offset":`${M?ie:ge.current}px`,"--initial-height":S?`auto`:`${R}px`,...m,...n.style},onDragEnd:()=>{F(!1),ee(null),ve.current=null},onPointerDown:e=>{e.button!==2&&(we||!le||(z.current=new Date,L(ge.current),e.target.setPointerCapture(e.pointerId),e.target.tagName!==`BUTTON`&&(F(!0),ve.current={x:e.clientX,y:e.clientY})))},onPointerUp:()=>{if(I||!le)return;ve.current=null;let e=Number(B.current?.style.getPropertyValue(`--swipe-amount-x`).replace(`px`,``)||0),t=Number(B.current?.style.getPropertyValue(`--swipe-amount-y`).replace(`px`,``)||0),r=new Date().getTime()-z.current?.getTime(),i=D===`x`?e:t,a=Math.abs(i)/r;if(Math.abs(i)>=kp||a>.11){L(ge.current),n.onDismiss==null||n.onDismiss.call(n,n),k(D===`x`?e>0?`right`:`left`:t>0?`down`:`up`),Te(),te(!0);return}else{var o,s;(o=B.current)==null||o.style.setProperty(`--swipe-amount-x`,`0px`),(s=B.current)==null||s.style.setProperty(`--swipe-amount-y`,`0px`)}re(!1),F(!1),ee(null)},onPointerMove:t=>{var n,r;if(!ve.current||!le||window.getSelection()?.toString().length>0)return;let i=t.clientY-ve.current.y,a=t.clientX-ve.current.x,o=e.swipeDirections??Mp(b);!D&&(Math.abs(a)>1||Math.abs(i)>1)&&ee(Math.abs(a)>Math.abs(i)?`x`:`y`);let s={x:0,y:0},c=e=>1/(1.5+Math.abs(e)/20);if(D===`y`){if(o.includes(`top`)||o.includes(`bottom`))if(o.includes(`top`)&&i<0||o.includes(`bottom`)&&i>0)s.y=i;else{let e=i*c(i);s.y=Math.abs(e)<Math.abs(i)?e:i}}else if(D===`x`&&(o.includes(`left`)||o.includes(`right`)))if(o.includes(`left`)&&a<0||o.includes(`right`)&&a>0)s.x=a;else{let e=a*c(a);s.x=Math.abs(e)<Math.abs(a)?e:a}(Math.abs(s.x)>0||Math.abs(s.y)>0)&&re(!0),(n=B.current)==null||n.style.setProperty(`--swipe-amount-x`,`${s.x}px`),(r=B.current)==null||r.style.setProperty(`--swipe-amount-y`,`${s.y}px`)}},pe&&!n.jsx&&V!==`loading`?q.createElement(`button`,{"aria-label":E,"data-disabled":we,"data-close-button":!0,onClick:we||!le?()=>{}:()=>{Te(),n.onDismiss==null||n.onDismiss.call(n,n)},className:jp(C?.closeButton,n?.classNames?.closeButton)},w?.close??hp):null,(V||n.icon||n.promise)&&n.icon!==null&&(w?.[V]!==null||n.icon)?q.createElement(`div`,{"data-icon":``,className:jp(C?.icon,n?.classNames?.icon)},n.promise||n.type===`loading`&&!n.icon?n.icon||Ee():null,n.type===`loading`?null:De):null,q.createElement(`div`,{"data-content":``,className:jp(C?.content,n?.classNames?.content)},q.createElement(`div`,{"data-title":``,className:jp(C?.title,n?.classNames?.title)},n.jsx?n.jsx:typeof n.title==`function`?n.title():n.title),n.description?q.createElement(`div`,{"data-description":``,className:jp(v,de,C?.description,n?.classNames?.description)},typeof n.description==`function`?n.description():n.description):null),q.isValidElement(n.cancel)?n.cancel:n.cancel&&Sp(n.cancel)?q.createElement(`button`,{"data-button":!0,"data-cancel":!0,style:n.cancelButtonStyle||h,onClick:e=>{Sp(n.cancel)&&le&&(n.cancel.onClick==null||n.cancel.onClick.call(n.cancel,e),Te())},className:jp(C?.cancelButton,n?.classNames?.cancelButton)},n.cancel.label):null,q.isValidElement(n.action)?n.action:n.action&&Sp(n.action)?q.createElement(`button`,{"data-button":!0,"data-action":!0,style:n.actionButtonStyle||g,onClick:e=>{Sp(n.action)&&(n.action.onClick==null||n.action.onClick.call(n.action,e),!e.defaultPrevented&&Te())},className:jp(C?.actionButton,n?.classNames?.actionButton)},n.action.label):null)};function Pp(){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}function Fp(e,t){let n={};return[e,t].forEach((e,t)=>{let r=t===1,i=r?`--mobile-offset`:`--offset`,a=r?Tp:wp;function o(e){[`top`,`right`,`bottom`,`left`].forEach(t=>{n[`${i}-${t}`]=typeof e==`number`?`${e}px`:e})}typeof e==`number`||typeof e==`string`?o(e):typeof e==`object`?[`top`,`right`,`bottom`,`left`].forEach(t=>{e[t]===void 0?n[`${i}-${t}`]=a:n[`${i}-${t}`]=typeof e[t]==`number`?`${e[t]}px`:e[t]}):o(a)}),n}var Ip=q.forwardRef(function(e,t){let{id:n,invert:r,position:i=`bottom-right`,hotkey:a=[`altKey`,`KeyT`],expand:o,closeButton:s,className:c,offset:l,mobileOffset:u,theme:d=`light`,richColors:f,duration:p,style:m,visibleToasts:h=Cp,toastOptions:g,dir:_=Pp(),gap:v=Op,icons:y,containerAriaLabel:b=`Notifications`}=e,[x,S]=q.useState([]),C=q.useMemo(()=>n?x.filter(e=>e.toasterId===n):x.filter(e=>!e.toasterId),[x,n]),w=q.useMemo(()=>Array.from(new Set([i].concat(C.filter(e=>e.position).map(e=>e.position)))),[C,i]),[E,D]=q.useState([]),[ee,O]=q.useState(!1),[k,A]=q.useState(!1),[j,M]=q.useState(d===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`:d),N=q.useRef(null),P=a.join(`+`).replace(/Key/g,``).replace(/Digit/g,``),F=q.useRef(null),I=q.useRef(!1),te=q.useCallback(e=>{S(t=>(t.find(t=>t.id===e.id)?.delete||vp.dismiss(e.id),t.filter(({id:t})=>t!==e.id)))},[]);return q.useEffect(()=>vp.subscribe(e=>{if(e.dismiss){requestAnimationFrame(()=>{S(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t))});return}setTimeout(()=>{Oo.flushSync(()=>{S(t=>{let n=t.findIndex(t=>t.id===e.id);return n===-1?[e,...t]:[...t.slice(0,n),{...t[n],...e},...t.slice(n+1)]})})})}),[x]),q.useEffect(()=>{if(d!==`system`){M(d);return}if(d===`system`&&(window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?M(`dark`):M(`light`)),typeof window>`u`)return;let e=window.matchMedia(`(prefers-color-scheme: dark)`);try{e.addEventListener(`change`,({matches:e})=>{M(e?`dark`:`light`)})}catch{e.addListener(({matches:e})=>{try{M(e?`dark`:`light`)}catch(e){console.error(e)}})}},[d]),q.useEffect(()=>{x.length<=1&&O(!1)},[x]),q.useEffect(()=>{let e=e=>{if(a.every(t=>e[t]||e.code===t)){var t;O(!0),(t=N.current)==null||t.focus()}e.code===`Escape`&&(document.activeElement===N.current||N.current?.contains(document.activeElement))&&O(!1)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[a]),q.useEffect(()=>{if(N.current)return()=>{F.current&&(F.current.focus({preventScroll:!0}),F.current=null,I.current=!1)}},[N.current]),q.createElement(`section`,{ref:t,"aria-label":`${b} ${P}`,tabIndex:-1,"aria-live":`polite`,"aria-relevant":`additions text`,"aria-atomic":`false`,suppressHydrationWarning:!0},w.map((t,n)=>{let[i,a]=t.split(`-`);return C.length?q.createElement(`ol`,{key:t,dir:_===`auto`?Pp():_,tabIndex:-1,ref:N,className:c,"data-sonner-toaster":!0,"data-sonner-theme":j,"data-y-position":i,"data-x-position":a,style:{"--front-toast-height":`${E[0]?.height||0}px`,"--width":`${Dp}px`,"--gap":`${v}px`,...m,...Fp(l,u)},onBlur:e=>{I.current&&!e.currentTarget.contains(e.relatedTarget)&&(I.current=!1,F.current&&=(F.current.focus({preventScroll:!0}),null))},onFocus:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||I.current||(I.current=!0,F.current=e.relatedTarget)},onMouseEnter:()=>O(!0),onMouseMove:()=>O(!0),onMouseLeave:()=>{k||O(!1)},onDragEnd:()=>O(!1),onPointerDown:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||A(!0)},onPointerUp:()=>A(!1)},C.filter(e=>!e.position&&n===0||e.position===t).map((n,i)=>q.createElement(Np,{key:n.id,icons:y,index:i,toast:n,defaultRichColors:f,duration:g?.duration??p,className:g?.className,descriptionClassName:g?.descriptionClassName,invert:r,visibleToasts:h,closeButton:g?.closeButton??s,interacting:k,position:t,style:g?.style,unstyled:g?.unstyled,classNames:g?.classNames,cancelButtonStyle:g?.cancelButtonStyle,actionButtonStyle:g?.actionButtonStyle,closeButtonAriaLabel:g?.closeButtonAriaLabel,removeToast:te,toasts:C.filter(e=>e.position==n.position),heights:E.filter(e=>e.position==n.position),setHeights:D,expandByDefault:o,gap:v,expanded:ee,swipeDirections:e.swipeDirections}))):null}))});export{ho as $,_e as $t,ql as A,ya as At,Yo as B,Ri as Bt,Af as C,ka as Ct,fu as D,Oa as Dt,uu as E,Ka as Et,ds as F,Wi as Ft,Fo as G,Oi as Gt,Go as H,ji as Ht,as as I,Ui as It,jo as J,ei as Jt,zo as K,Ei as Kt,ts as L,Vi as Lt,Os as M,qi as Mt,bs as N,Ji as Nt,du as O,Sa as Ot,fs as P,Gi as Pt,go as Q,ye as Qt,$o as R,Bi as Rt,jf as S,Aa as St,$ as T,Ja as Tt,Uo as U,Ti as Ut,Xo as V,Li as Vt,Io as W,ki as Wt,To as X,Se as Xt,Do as Y,xe as Yt,wo as Z,be as Zt,Pf as _,Ma as _t,Qf as a,p as an,eo as at,Ff as b,Fa as bt,tp as c,Ya as ct,rp as d,qa as dt,ge as en,fo as et,op as f,Ea as ft,Rf as g,Da as gt,Yf as h,wa as ht,$f as i,h as in,to as it,ks as j,ea as jt,lu as k,ba as kt,Zf as l,Wa as lt,qf as m,Na as mt,xp as n,me as nn,so as nt,ep as o,l as on,Za as ot,ip as p,Pa as pt,Po as q,Di as qt,Jf as r,_ as rn,co as rt,np as s,d as sn,Xa as st,Ip as t,he as tn,po as tt,Xf as u,Ga as ut,If as v,ja as vt,kf as w,Ra as wt,Mf as x,Ua as xt,Nf as y,Ta as yt,Qo as z,zi as zt};