@hot-updater/console 0.30.1 → 0.30.3

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 (39) hide show
  1. package/.output/nitro.json +3 -3
  2. package/.output/public/assets/dist-BKho179_.js +53 -0
  3. package/.output/public/assets/main-CoPJhqkz.js +10 -0
  4. package/.output/public/assets/routes-CVEbccVq.js +10 -0
  5. package/.output/server/__tanstack-start-server-fn-resolver-DB7Vwz3A.mjs +61 -0
  6. package/.output/server/_chunks/ssr-renderer.mjs +2 -2
  7. package/.output/server/_libs/@radix-ui/react-alert-dialog+[...].mjs +3 -7
  8. package/.output/server/_libs/@radix-ui/react-select+[...].mjs +1 -1
  9. package/.output/server/_libs/@tanstack/react-form+[...].mjs +7 -7
  10. package/.output/server/_libs/@tanstack/react-router+[...].mjs +9 -12
  11. package/.output/server/_libs/@tanstack/react-table+[...].mjs +11 -1
  12. package/.output/server/_libs/h3+rou3+srvx.mjs +101 -49
  13. package/.output/server/_libs/hookable.mjs +2 -2
  14. package/.output/server/_libs/isaacs__fs-minipass+minipass.mjs +35 -1
  15. package/.output/server/_libs/jszip+[...].mjs +1 -1
  16. package/.output/server/_libs/lucide-react.mjs +7 -1
  17. package/.output/server/_libs/minizlib.mjs +25 -2
  18. package/.output/server/_libs/radix-ui__react-direction.mjs +2 -0
  19. package/.output/server/_libs/radix-ui__react-separator.mjs +1 -2
  20. package/.output/server/_libs/semver.mjs +1 -0
  21. package/.output/server/_libs/{tar.mjs → tar+yallist.mjs} +1346 -24
  22. package/.output/server/_libs/unctx.mjs +82 -0
  23. package/.output/server/_ssr/{api-rpc-Cr26KHOK.mjs → api-rpc-kX2sZt80.mjs} +14 -15
  24. package/.output/server/_ssr/{config.server-TLOyHGWx.mjs → config.server-8YQWTTc0.mjs} +1 -1
  25. package/.output/server/_ssr/createServerFn-CdeRXnVy.mjs +320 -0
  26. package/.output/server/_ssr/{deleteBundle-DWUxu9-K.mjs → deleteBundle-BiJvjt0k.mjs} +1 -1
  27. package/.output/server/_ssr/{extract-timestamp-from-uuidv7-B90UBADU.mjs → extract-timestamp-from-uuidv7-DO_lXhMa.mjs} +1 -1
  28. package/.output/server/_ssr/{promoteBundle-DtMHuubR.mjs → promoteBundle-BBOSMtwu.mjs} +3 -3
  29. package/.output/server/_ssr/{router-CdSyFCJa.mjs → router-fogqFSFT.mjs} +4 -4
  30. package/.output/server/_ssr/{routes-D8wYJKp6.mjs → routes-CgYYFBNT.mjs} +7 -6
  31. package/.output/server/_ssr/{sidebar-DXng0IOP.mjs → sidebar-B6a7DDef.mjs} +1 -1
  32. package/.output/server/_ssr/ssr.mjs +7 -380
  33. package/.output/server/_ssr/start-DsRb6TkZ.mjs +4 -0
  34. package/.output/server/{_tanstack-start-manifest_v-CKbZoQZl.mjs → _tanstack-start-manifest_v-OXy-e32b.mjs} +4 -4
  35. package/.output/server/index.mjs +59 -41
  36. package/package.json +8 -8
  37. package/.output/public/assets/main-BUiDyfP0.js +0 -61
  38. package/.output/public/assets/routes-D5XuYXnS.js +0 -10
  39. package/.output/server/_ssr/start-DQK0r85G.mjs +0 -4
@@ -1,12 +1,12 @@
1
1
  {
2
- "date": "2026-04-16T12:34:10.307Z",
2
+ "date": "2026-04-23T15:05:17.862Z",
3
3
  "preset": "node-server",
4
4
  "framework": {
5
5
  "name": "nitro",
6
- "version": "3.0.260311-beta"
6
+ "version": "3.0.260415-beta"
7
7
  },
8
8
  "versions": {
9
- "nitro": "3.0.260311-beta"
9
+ "nitro": "3.0.260415-beta"
10
10
  },
11
11
  "serverEntry": "server/index.mjs",
12
12
  "publicDir": "public",
@@ -0,0 +1,53 @@
1
+ var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),s=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},c=(n,r,a)=>(a=n==null?{}:e(i(n)),s(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),l=o((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`})),u=o(((e,t)=>{t.exports=l()})),d=o((e=>{var t=u();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`})),f=o(((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=d()})),p=o((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})),m=o(((e,t)=>{t.exports=p()})),h=(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))(h||{});function g({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 _=0,v=0,y=0,b=[],{link:x,unlink:S,propagate:C,checkDirty:w,shallowPropagate:E}=g({update(e){return e.depsTail===void 0?A(e):k(e)},notify(e){let t=y,n=t;do if(b[t++]=e,e.flags&=-3,e=e.subs?.sub,e===void 0||!(e.flags&2))break;while(!0);for(y=t;n<--t;){let e=b[n];b[n++]=b[t],b[t]=e}},unwatched(e){e.flags&1?e.depsTail!==void 0&&(e.depsTail=void 0,e.flags=17,P(e)):N.call(e)}});function D(){return _}function ee(){++_}function O(){--_||M()}function k(e){e.depsTail=void 0,e.flags=5;try{let t=e.value;return t!==(e.value=e.getter(t))}finally{e.flags&=-5,P(e)}}function A(e){return e.flags=1,e.currentValue!==(e.currentValue=e.pendingValue)}function j(e){let t=e.flags;if(t&16||t&32&&w(e.deps,e)){e.depsTail=void 0,e.flags=6;try{e.fn()}finally{e.flags&=-5,P(e)}}else e.flags=2}function M(){try{for(;v<y;){let e=b[v];b[v++]=void 0,j(e)}}finally{for(;v<y;){let e=b[v];b[v++]=void 0,e.flags|=10}v=0,y=0}}function N(){this.depsTail=void 0,this.flags=0,P(this);let e=this.subs;e!==void 0&&S(e)}function P(e){let t=e.depsTail,n=t===void 0?e.deps:t.nextDep;for(;n!==void 0;)n=S(n,e)}function F(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 I=[],te=0,{link:ne,unlink:re,propagate:ie,checkDirty:L,shallowPropagate:R}=g({update(e){return e._update()},notify(e){I[oe++]=e,e.flags&=~h.Watching},unwatched(e){e.depsTail!==void 0&&(e.depsTail=void 0,e.flags=h.Mutable|h.Dirty,se(e))}}),ae=0,oe=0,z;function se(e){let t=e.depsTail,n=t===void 0?e.deps:t.nextDep;for(;n!==void 0;)n=re(n,e)}function ce(){if(!(D()>0)){for(;ae<oe;){let e=I[ae];I[ae++]=void 0,e.notify()}ae=0,oe=0}}function le(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?h.None:h.Mutable,get(){return z!==void 0&&ne(i,z,te),i._snapshot},subscribe(e){let t=F(e),n={current:!1},r=B(()=>{i.get(),n.current?t.next?.(i._snapshot):n.current=!0});return{unsubscribe:()=>{r.stop()}}},_update(e){let a=z,o=t?.compare??Object.is;if(n)z=i,++te,i.depsTail=void 0;else if(e===void 0)return!1;n&&(i.flags=h.Mutable|h.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{z=a,n&&(i.flags&=~h.RecursedCheck),se(i)}}};return n?(i.flags=h.Mutable|h.Dirty,i.get=function(){let e=i.flags;if(e&h.Dirty||e&h.Pending&&L(i.deps,i)){if(i._update()){let e=i.subs;e!==void 0&&R(e)}}else e&h.Pending&&(i.flags=e&~h.Pending);return z!==void 0&&ne(i,z,te),i._snapshot}):i.set=function(e){if(i._update(e)){let e=i.subs;e!==void 0&&(ie(e),R(e),ce())}},i}function B(e){let t=()=>{let t=z;z=n,++te,n.depsTail=void 0,n.flags=h.Watching|h.RecursedCheck;try{return e()}finally{z=t,n.flags&=~h.RecursedCheck,se(n)}},n={deps:void 0,depsTail:void 0,subs:void 0,subsTail:void 0,flags:h.Watching|h.RecursedCheck,notify(){let e=this.flags;e&h.Dirty||e&h.Pending&&L(this.deps,this)?t():this.flags=h.Watching},stop(){this.flags=h.None,this.depsTail=void 0,se(this)}};return t(),n}var ue=class{constructor(e){this.atom=le(e)}setState(e){this.atom.set(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(F(e))}},de=class{constructor(e){this.atom=le(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(F(e))}};function fe(e){return typeof e==`function`?new de(e):new ue(e)}function pe(e){try{ee(),e()}finally{O(),ce()}}function me(e){return e[e.length-1]}function he(e){return typeof e==`function`}function ge(e,t){return he(e)?e(t):e}var _e=Object.prototype.hasOwnProperty,ve=Object.prototype.propertyIsEnumerable,ye=()=>Object.create(null),be=(e,t)=>xe(e,t,ye);function xe(e,t,n=()=>({}),r=0){if(e===t)return e;if(r>500)return t;let i=t,a=Te(e)&&Te(i);if(!a&&!(Ce(e)&&Ce(i)))return i;let o=a?e:Se(e);if(!o)return i;let s=a?i:Se(i);if(!s)return i;let c=o.length,l=s.length,u=a?Array(l):n(),d=0;for(let t=0;t<l;t++){let o=a?t:s[t],l=e[o],f=i[o];if(l===f){u[o]=l,(a?t<c:_e.call(e,o))&&d++;continue}if(l===null||f===null||typeof l!=`object`||typeof f!=`object`){u[o]=f;continue}let p=xe(l,f,n,r+1);u[o]=p,p===l&&d++}return c===l&&d===c?e:u}function Se(e){let t=Object.getOwnPropertyNames(e);for(let n of t)if(!ve.call(e,n))return!1;let n=Object.getOwnPropertySymbols(e);if(n.length===0)return t;let r=t;for(let t of n){if(!ve.call(e,t))return!1;r.push(t)}return r}function Ce(e){if(!we(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!we(n)||!n.hasOwnProperty(`isPrototypeOf`))}function we(e){return Object.prototype.toString.call(e)===`[object Object]`}function Te(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Ee(e,t,n){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return!1;for(let r=0,i=e.length;r<i;r++)if(!Ee(e[r],t[r],n))return!1;return!0}if(Ce(e)&&Ce(t)){let r=n?.ignoreUndefined??!0;if(n?.partial){for(let i in t)if((!r||t[i]!==void 0)&&!Ee(e[i],t[i],n))return!1;return!0}let i=0;if(!r)i=Object.keys(e).length;else for(let t in e)e[t]!==void 0&&i++;let a=0;for(let o in t)if((!r||t[o]!==void 0)&&(a++,a>i||!Ee(e[o],t[o],n)))return!1;return i===a}return!1}function De(e){let t,n,r=new Promise((e,r)=>{t=e,n=r});return r.status=`pending`,r.resolve=n=>{r.status=`resolved`,r.value=n,t(n),e?.(n)},r.reject=e=>{r.status=`rejected`,n(e)},r}function Oe(e){return typeof e?.message==`string`?e.message.startsWith(`Failed to fetch dynamically imported module`)||e.message.startsWith(`error loading dynamically imported module`)||e.message.startsWith(`Importing a module script failed`):!1}function ke(e){return!!(e&&typeof e==`object`&&typeof e.then==`function`)}function Ae(e){return e.replace(/[\x00-\x1f\x7f]/g,``)}function je(e){let t;try{t=decodeURI(e)}catch{t=e.replaceAll(/%[0-9A-F]{2}/gi,e=>{try{return decodeURI(e)}catch{return e}})}return Ae(t)}var Me=[`http:`,`https:`,`mailto:`,`tel:`];function Ne(e,t){if(!e)return!1;try{let n=new URL(e);return!t.has(n.protocol)}catch{return!1}}var Pe={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},Fe=/[&><\u2028\u2029]/g;function Ie(e){return e.replace(Fe,e=>Pe[e])}function Le(e){if(!e||!/[%\\\x00-\x1f\x7f]/.test(e)&&!e.startsWith(`//`))return{path:e,handledProtocolRelativeURL:!1};let t=/%25|%5C/gi,n=0,r=``,i;for(;(i=t.exec(e))!==null;)r+=je(e.slice(n,i.index))+i[0],n=t.lastIndex;r+=je(n?e.slice(n):e);let a=!1;return r.startsWith(`//`)&&(a=!0,r=`/`+r.replace(/^\/+/,``)),{path:r,handledProtocolRelativeURL:a}}function Re(e){return/\s|[^\u0000-\u007F]/.test(e)?e.replace(/\s|[^\u0000-\u007F]/gu,encodeURIComponent):e}var V=c(u(),1),ze=!0,Be=`Invariant failed`;function Ve(e,t){if(!e){if(ze)throw Error(Be);var n=typeof t==`function`?t():t,r=n?`${Be}: ${n}`:Be;throw Error(r)}}function He(e){return!!e?.isNotFound}function Ue(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 We(e){return e?e===`false`?!1:e===`true`?!0:e*0==0&&+e+``===e?+e:e:``}function Ge(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]=We(r):Array.isArray(t)?t.push(We(r)):n[e]=[t,We(r)]}return n}function Ke(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 qe(e){return e instanceof Response&&!!e.options}function Je(e){if(typeof e==`object`&&e&&e.isSerializedRedirect)return Ke(e)}var Ye=(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))(Ye||{}),Xe=Symbol.asyncIterator,Ze=Symbol.hasInstance,Qe=Symbol.isConcatSpreadable,$e=Symbol.iterator,et=Symbol.match,tt=Symbol.matchAll,nt=Symbol.replace,rt=Symbol.search,it=Symbol.species,at=Symbol.split,ot=Symbol.toPrimitive,st=Symbol.toStringTag,ct=Symbol.unscopables,lt={[Xe]:0,[Ze]:1,[Qe]:2,[$e]:3,[et]:4,[tt]:5,[nt]:6,[rt]:7,[it]:8,[at]:9,[ot]:10,[st]:11,[ct]:12},ut={0:Xe,1:Ze,2:Qe,3:$e,4:et,5:tt,6:nt,7:rt,8:it,9:at,10:ot,11:st,12:ct},H=void 0,dt={2:!0,3:!1,1:H,0:null,4:-0,5:1/0,6:-1/0,7:NaN},ft={0:`Error`,1:`EvalError`,2:`RangeError`,3:`ReferenceError`,4:`SyntaxError`,5:`TypeError`,6:`URIError`},pt={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 mt(e){return U(2,H,e,H,H,H,H,H,H,H,H,H)}var ht=mt(2),gt=mt(3),_t=mt(1),vt=mt(0),yt=mt(4),bt=mt(5),xt=mt(6),St=mt(7);function Ct(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 wt(e){let t=``,n=0,r;for(let i=0,a=e.length;i<a;i++)r=Ct(e[i]),r&&(t+=e.slice(n,i)+r,n=i+1);return n===0?t=e:t+=e.slice(n),t}function Tt(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,Tt)}var Dt=`__SEROVAL_REFS__`,Ot=new Map,kt=new Map;function At(e){return Ot.has(e)}function jt(e){return kt.has(e)}function Mt(e){if(At(e))return Ot.get(e);throw new xn(e)}function Nt(e){if(jt(e))return kt.get(e);throw new Sn(e)}typeof globalThis<`u`?Object.defineProperty(globalThis,Dt,{value:kt,configurable:!0,writable:!1,enumerable:!1}):typeof window<`u`?Object.defineProperty(window,Dt,{value:kt,configurable:!0,writable:!1,enumerable:!1}):typeof self<`u`?Object.defineProperty(self,Dt,{value:kt,configurable:!0,writable:!1,enumerable:!1}):typeof global<`u`&&Object.defineProperty(global,Dt,{value:kt,configurable:!0,writable:!1,enumerable:!1});function Pt(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 Ft(e){let t=ft[Pt(e)];return e.name===t?e.constructor.name===t?{}:{name:e.constructor.name}:{name:e.name}}function It(e,t){let n=Ft(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 Lt(e){return Object.isFrozen(e)?3:Object.isSealed(e)?2:+!Object.isExtensible(e)}function Rt(e){switch(e){case 1/0:return bt;case-1/0:return xt}return e===e?Object.is(e,-0)?yt:U(0,H,e,H,H,H,H,H,H,H,H,H):St}function zt(e){return U(1,H,wt(e),H,H,H,H,H,H,H,H,H)}function Bt(e){return U(3,H,``+e,H,H,H,H,H,H,H,H,H)}function Vt(e){return U(4,e,H,H,H,H,H,H,H,H,H,H)}function Ht(e,t){let n=t.valueOf();return U(5,e,n===n?t.toISOString():``,H,H,H,H,H,H,H,H,H)}function Ut(e,t){return U(6,e,H,wt(t.source),t.flags,H,H,H,H,H,H,H)}function Wt(e,t){return U(17,e,lt[t],H,H,H,H,H,H,H,H,H)}function Gt(e,t){return U(18,e,wt(Mt(t)),H,H,H,H,H,H,H,H,H)}function Kt(e,t,n){return U(25,e,n,wt(t),H,H,H,H,H,H,H,H)}function qt(e,t,n){return U(9,e,H,H,H,H,H,n,H,H,Lt(t),H)}function Jt(e,t){return U(21,e,H,H,H,H,H,H,t,H,H,H)}function Yt(e,t,n){return U(15,e,H,t.constructor.name,H,H,H,H,n,t.byteOffset,H,t.length)}function Xt(e,t,n){return U(16,e,H,t.constructor.name,H,H,H,H,n,t.byteOffset,H,t.byteLength)}function Zt(e,t,n){return U(20,e,H,H,H,H,H,H,n,t.byteOffset,H,t.byteLength)}function Qt(e,t,n){return U(13,e,Pt(t),H,wt(t.message),n,H,H,H,H,H,H)}function $t(e,t,n){return U(14,e,Pt(t),H,wt(t.message),n,H,H,H,H,H,H)}function en(e,t){return U(7,e,H,H,H,H,H,t,H,H,H,H)}function tn(e,t){return U(28,H,H,H,H,H,H,[e,t],H,H,H,H)}function nn(e,t){return U(30,H,H,H,H,H,H,[e,t],H,H,H,H)}function rn(e,t,n){return U(31,e,H,H,H,H,H,n,t,H,H,H)}function an(e,t){return U(32,e,H,H,H,H,H,H,t,H,H,H)}function on(e,t){return U(33,e,H,H,H,H,H,H,t,H,H,H)}function sn(e,t){return U(34,e,H,H,H,H,H,H,t,H,H,H)}function cn(e,t,n,r){return U(35,e,n,H,H,H,H,t,H,H,H,r)}var{toString:ln}=Object.prototype,un={parsing:1,serialization:2,deserialization:3};function dn(e){return`Seroval Error (step: ${un[e]})`}var fn=(e,t)=>dn(e),pn=class extends Error{constructor(e,t){super(fn(e,t)),this.cause=t}},mn=class extends pn{constructor(e){super(`parsing`,e)}},hn=class extends pn{constructor(e){super(`deserialization`,e)}};function gn(e){return`Seroval Error (specific: ${e})`}var _n=class extends Error{constructor(e){super(gn(1)),this.value=e}},vn=class extends Error{constructor(e){super(gn(2))}},yn=class extends Error{constructor(e){super(gn(3))}},bn=class extends Error{constructor(e){super(gn(4))}},xn=class extends Error{constructor(e){super(gn(5)),this.value=e}},Sn=class extends Error{constructor(e){super(gn(6))}},Cn=class extends Error{constructor(e){super(gn(7))}},wn=class extends Error{constructor(e){super(gn(8))}},Tn=class extends Error{constructor(e){super(gn(9))}},En=class{constructor(e,t){this.value=e,this.replacement=t}},Dn=()=>{let e={p:0,s:0,f:0};return e.p=new Promise((t,n)=>{e.s=t,e.f=n}),e};Dn.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 On=()=>{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)}}};On.toString();var kn=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};kn.toString();var An=(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};An.toString();var jn=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};jn.toString();function Mn(e){return`__SEROVAL_SEQUENCE__`in e}function Nn(e,t,n){return{__SEROVAL_SEQUENCE__:!0,v:e,t,d:n}}function Pn(e){let t=[],n=-1,r=-1,i=e[$e]();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 Nn(t,n,r)}var Fn=kn($e);function In(e){return Fn(e)}var Ln={},Rn={},zn={0:{},1:{},2:{},3:{},4:{},5:{}};function Bn(e){return`__SEROVAL_STREAM__`in e}function Vn(){return On()}function Hn(e){let t=Vn(),n=e[Xe]();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 Un=An(Xe,Dn);function Wn(e){return Un(e)}async function Gn(e){try{return[1,await e]}catch(e){return[0,e]}}function Kn(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 qn(e,t){e.marked.add(t)}function Jn(e,t){let n=e.refs.size;return e.refs.set(t,n),n}function Yn(e,t){let n=e.refs.get(t);return n==null?{type:0,value:Jn(e,t)}:(qn(e,n),{type:1,value:Vt(n)})}function Xn(e,t){let n=Yn(e,t);return n.type===1?n:At(t)?{type:2,value:Gt(n.value,t)}:n}function Zn(e,t){let n=Xn(e,t);if(n.type!==0)return n.value;if(t in lt)return Wt(n.value,t);throw new _n(t)}function Qn(e,t){let n=Yn(e,zn[t]);return n.type===1?n.value:U(26,n.value,t,H,H,H,H,H,H,H,H,H)}function $n(e){let t=Yn(e,Ln);return t.type===1?t.value:U(27,t.value,H,H,H,H,H,H,Zn(e,$e),H,H,H)}function er(e){let t=Yn(e,Rn);return t.type===1?t.value:U(29,t.value,H,H,H,H,H,[Qn(e,1),Zn(e,Xe)],H,H,H,H)}function tr(e,t,n,r){return U(n?11:10,e,H,H,H,r,H,H,H,H,Lt(t),H)}function nr(e,t,n,r){return U(8,t,H,H,H,H,{k:n,v:r},H,Qn(e,0),H,H,H)}function rr(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,wt(btoa(i)),H,H,H,H,H,Qn(e,5),H,H,H)}function ir(e,t){return{base:Kn(e,t),child:void 0}}var ar=class{constructor(e,t){this._p=e,this.depth=t}parse(e){return W(this._p,this.depth,e)}};async function or(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 sr(e,t,n,r){return qt(n,r,await or(e,t,r))}async function cr(e,t,n){let r=Object.entries(n),i=[],a=[];for(let n=0,o=r.length;n<o;n++)i.push(wt(r[n][0])),a.push(await W(e,t,r[n][1]));return $e in n&&(i.push(Zn(e.base,$e)),a.push(tn($n(e.base),await W(e,t,Pn(n))))),Xe in n&&(i.push(Zn(e.base,Xe)),a.push(nn(er(e.base),await W(e,t,Hn(n))))),st in n&&(i.push(Zn(e.base,st)),a.push(zt(n[st]))),Qe in n&&(i.push(Zn(e.base,Qe)),a.push(n[Qe]?ht:gt)),{k:i,v:a}}async function lr(e,t,n,r,i){return tr(n,r,i,await cr(e,t,r))}async function ur(e,t,n,r){return Jt(n,await W(e,t,r.valueOf()))}async function dr(e,t,n,r){return Yt(n,r,await W(e,t,r.buffer))}async function fr(e,t,n,r){return Xt(n,r,await W(e,t,r.buffer))}async function pr(e,t,n,r){return Zt(n,r,await W(e,t,r.buffer))}async function mr(e,t,n,r){let i=It(r,e.base.features);return Qt(n,r,i?await cr(e,t,i):H)}async function hr(e,t,n,r){let i=It(r,e.base.features);return $t(n,r,i?await cr(e,t,i):H)}async function gr(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 nr(e.base,n,i,a)}async function _r(e,t,n,r){let i=[];for(let n of r.keys())i.push(await W(e,t,n));return en(n,i)}async function vr(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 Kt(n,o.tag,await o.parse.async(r,new ar(e,t),{id:n}))}return H}async function yr(e,t,n,r){let[i,a]=await Gn(r);return U(12,n,i,H,H,H,H,H,await W(e,t,a),H,H,H)}function br(e,t,n,r,i){let a=[],o=n.on({next:n=>{qn(this.base,t),W(this,e,n).then(e=>{a.push(an(t,e))},e=>{i(e),o()})},throw:n=>{qn(this.base,t),W(this,e,n).then(e=>{a.push(on(t,e)),r(a),o()},e=>{i(e),o()})},return:n=>{qn(this.base,t),W(this,e,n).then(e=>{a.push(sn(t,e)),r(a),o()},e=>{i(e),o()})}})}async function xr(e,t,n,r){return rn(n,Qn(e.base,4),await new Promise(br.bind(e,t,n,r)))}async function Sr(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 cn(n,i,r.t,r.d)}async function Cr(e,t,n,r){if(Array.isArray(r))return sr(e,t,n,r);if(Bn(r))return xr(e,t,n,r);if(Mn(r))return Sr(e,t,n,r);let i=r.constructor;if(i===En)return W(e,t,r.replacement);let a=await vr(e,t,n,r);if(a)return a;switch(i){case Object:return lr(e,t,n,r,!1);case H:return lr(e,t,n,r,!0);case Date:return Ht(n,r);case Error:case EvalError:case RangeError:case ReferenceError:case SyntaxError:case TypeError:case URIError:return mr(e,t,n,r);case Number:case Boolean:case String:case BigInt:return ur(e,t,n,r);case ArrayBuffer:return rr(e.base,n,r);case Int8Array:case Int16Array:case Int32Array:case Uint8Array:case Uint16Array:case Uint32Array:case Uint8ClampedArray:case Float32Array:case Float64Array:return dr(e,t,n,r);case DataView:return pr(e,t,n,r);case Map:return gr(e,t,n,r);case Set:return _r(e,t,n,r);default:break}if(i===Promise||r instanceof Promise)return yr(e,t,n,r);let o=e.base.features;if(o&32&&i===RegExp)return Ut(n,r);if(o&16)switch(i){case BigInt64Array:case BigUint64Array:return fr(e,t,n,r);default:break}if(o&1&&typeof AggregateError<`u`&&(i===AggregateError||r instanceof AggregateError))return hr(e,t,n,r);if(r instanceof Error)return mr(e,t,n,r);if($e in r||Xe in r)return lr(e,t,n,r,!!i);throw new _n(r)}async function wr(e,t,n){let r=Xn(e.base,n);if(r.type!==0)return r.value;let i=await vr(e,t,r.value,n);if(i)return i;throw new _n(n)}async function W(e,t,n){switch(typeof n){case`boolean`:return n?ht:gt;case`undefined`:return _t;case`string`:return zt(n);case`number`:return Rt(n);case`bigint`:return Bt(n);case`object`:if(n){let r=Xn(e.base,n);return r.type===0?await Cr(e,t+1,r.value,n):r.value}return vt;case`symbol`:return Zn(e.base,n);case`function`:return wr(e,t,n);default:throw new _n(n)}}async function Tr(e,t){try{return await W(e,0,t)}catch(e){throw e instanceof mn?e:new mn(e)}}var Er=(e=>(e[e.Vanilla=1]=`Vanilla`,e[e.Cross=2]=`Cross`,e))(Er||{});function Dr(e){return e}function Or(e,t){for(let n=0,r=t.length;n<r;n++){let r=t[n];e.has(r)||(e.add(r),r.extends&&Or(e,r.extends))}}function kr(e){if(e){let t=new Set;return Or(t,e),[...t]}}function Ar(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 Cn(e)}}var jr=1e6,Mr=1e4,Nr=2e4;function Pr(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 Fr=1e3;function Ir(e,t){return{mode:e,plugins:t.plugins,refs:t.refs||new Map,features:t.features??63^(t.disabledFeatures||0),depthLimit:t.depthLimit||Fr}}function Lr(e){return{mode:2,base:Ir(2,e),child:H}}var Rr=class{constructor(e,t){this._p=e,this.depth=t}deserialize(e){return K(this._p,this.depth,e)}};function zr(e,t){if(t<0||!Number.isFinite(t)||!Number.isInteger(t))throw new wn({t:4,i:t});if(e.refs.has(t))throw Error(`Conflicted ref id: `+t)}function Br(e,t,n){return zr(e.base,t),e.state.marked.has(t)&&e.base.refs.set(t,n),n}function Vr(e,t,n){return zr(e.base,t),e.base.refs.set(t,n),n}function G(e,t,n){return e.mode===1?Br(e,t,n):Vr(e,t,n)}function Hr(e,t,n){if(Object.hasOwn(t,n))return t[n];throw new wn(e)}function Ur(e,t){return G(e,t.i,Nt(Et(t.s)))}function Wr(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 Pr(a,n.o),a}function Gr(e){switch(e){case`constructor`:case`__proto__`:case`prototype`:case`__defineGetter__`:case`__defineSetter__`:case`__lookupGetter__`:case`__lookupSetter__`:return!1;default:return!0}}function Kr(e){switch(e){case Xe:case Qe:case st:case $e:return!0;default:return!1}}function qr(e,t,n){Gr(t)?e[t]=n:Object.defineProperty(e,t,{value:n,configurable:!0,enumerable:!0,writable:!0})}function Jr(e,t,n,r,i){if(typeof r==`string`)qr(n,r,K(e,t,i));else{let a=K(e,t,r);switch(typeof a){case`string`:qr(n,a,K(e,t,i));break;case`symbol`:Kr(a)&&(n[a]=K(e,t,i));break;default:throw new wn(r)}}}function Yr(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++)Jr(e,t,r,i[a],o[a]);return r}function Xr(e,t,n){let r=G(e,n.i,n.t===10?{}:Object.create(null));return Yr(e,t,n.p,r),Pr(r,n.o),r}function Zr(e,t){return G(e,t.i,new Date(t.s))}function Qr(e,t){if(e.base.features&32){let n=Et(t.c);if(n.length>Nr)throw new wn(t);return G(e,t.i,new RegExp(n,t.m))}throw new vn(t)}function $r(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 ei(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 ti(e,t){if(t.s.length>jr)throw new wn(t);return G(e,t.i,jn(Et(t.s)))}function ni(e,t,n){let r=Ar(n.c),i=K(e,t,n.f),a=n.b??0;if(a<0||a>i.byteLength)throw new wn(n);return G(e,n.i,new r(i,a,n.l))}function ri(e,t,n){let r=K(e,t,n.f),i=n.b??0;if(i<0||i>r.byteLength)throw new wn(n);return G(e,n.i,new DataView(r,i,n.l))}function ii(e,t,n,r){if(n.p){let i=Yr(e,t,n.p,{});Object.defineProperties(r,Object.getOwnPropertyDescriptors(i))}return r}function ai(e,t,n){return ii(e,t,n,G(e,n.i,AggregateError([],Et(n.m))))}function oi(e,t,n){let r=Hr(n,pt,n.s);return ii(e,t,n,G(e,n.i,new r(Et(n.m))))}function si(e,t,n){let r=Dn(),i=G(e,n.i,r.p),a=K(e,t,n.f);return n.s?r.s(a):r.f(a),i}function ci(e,t,n){return G(e,n.i,Object(K(e,t,n.f)))}function li(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 Rr(e,t),{id:n.i}))}}throw new yn(n.c)}function ui(e,t){return G(e,t.i,G(e,t.s,Dn()).p)}function di(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 bn(`Promise`)}function fi(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 bn(`Promise`)}function pi(e,t,n){return K(e,t,n.a[0]),In(K(e,t,n.a[1]))}function mi(e,t,n){return K(e,t,n.a[0]),Wn(K(e,t,n.a[1]))}function hi(e,t,n){let r=G(e,n.i,Vn()),i=n.a,a=i.length;if(a)for(let n=0;n<a;n++)K(e,t,i[n]);return r}function gi(e,t,n){let r=e.base.refs.get(n.i);if(r&&Bn(r))return r.next(K(e,t,n.f)),H;throw new bn(`Stream`)}function _i(e,t,n){let r=e.base.refs.get(n.i);if(r&&Bn(r))return r.throw(K(e,t,n.f)),H;throw new bn(`Stream`)}function vi(e,t,n){let r=e.base.refs.get(n.i);if(r&&Bn(r))return r.return(K(e,t,n.f)),H;throw new bn(`Stream`)}function yi(e,t,n){return K(e,t,n.f),H}function bi(e,t,n){return K(e,t,n.a[1]),H}function xi(e,t,n){let r=G(e,n.i,Nn([],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 Tn(e.base.depthLimit);switch(t+=1,n.t){case 2:return Hr(n,dt,n.s);case 0:return Number(n.s);case 1:return Et(String(n.s));case 3:if(String(n.s).length>Mr)throw new wn(n);return BigInt(n.s);case 4:return e.base.refs.get(n.i);case 18:return Ur(e,n);case 9:return Wr(e,t,n);case 10:case 11:return Xr(e,t,n);case 5:return Zr(e,n);case 6:return Qr(e,n);case 7:return $r(e,t,n);case 8:return ei(e,t,n);case 19:return ti(e,n);case 16:case 15:return ni(e,t,n);case 20:return ri(e,t,n);case 14:return ai(e,t,n);case 13:return oi(e,t,n);case 12:return si(e,t,n);case 17:return Hr(n,ut,n.s);case 21:return ci(e,t,n);case 25:return li(e,t,n);case 22:return ui(e,n);case 23:return di(e,t,n);case 24:return fi(e,t,n);case 28:return pi(e,t,n);case 30:return mi(e,t,n);case 31:return hi(e,t,n);case 32:return gi(e,t,n);case 33:return _i(e,t,n);case 34:return vi(e,t,n);case 27:return yi(e,t,n);case 29:return bi(e,t,n);case 35:return xi(e,t,n);default:throw new vn(n)}}function Si(e,t){try{return K(e,0,t)}catch(e){throw new hn(e)}}var Ci=(()=>T).toString();/=>/.test(Ci);function wi(e,t){return Si(Lr({plugins:kr(t.plugins),refs:t.refs,features:t.features,disabledFeatures:t.disabledFeatures,depthLimit:t.depthLimit}),e)}async function Ti(e,t={}){let n=ir(1,{plugins:kr(t.plugins),disabledFeatures:t.disabledFeatures});return{t:await Tr(n,e),f:n.base.features,m:Array.from(n.base.marked)}}function Ei(e){return e}function Di(e){return Dr({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 Oi={},ki=e=>new ReadableStream({start:t=>{e.on({next:e=>{try{t.enqueue(e)}catch{}},throw:e=>{t.error(e)},return:()=>{try{t.close()}catch{}}})}}),Ai=Dr({tag:`seroval-plugins/web/ReadableStreamFactory`,test(e){return e===Oi},parse:{sync(){return Oi},async async(){return await Promise.resolve(Oi)},stream(){return Oi}},serialize(){return ki.toString()},deserialize(){return Oi}});function ji(e){let t=Vn(),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 Mi=Dr({tag:`seroval/plugins/web/ReadableStream`,extends:[Ai],test(e){return typeof ReadableStream>`u`?!1:e instanceof ReadableStream},parse:{sync(e,t){return{factory:t.parse(Oi),stream:t.parse(Vn())}},async async(e,t){return{factory:await t.parse(Oi),stream:await t.parse(ji(e))}},stream(e,t){return{factory:t.parse(Oi),stream:t.parse(ji(e))}}},serialize(e,t){return`(`+t.serialize(e.factory)+`)(`+t.serialize(e.stream)+`)`},deserialize(e,t){return ki(t.deserialize(e.stream))}}),Ni=Dr({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))}}),Pi=class{constructor(e,t){this.stream=e,this.hint=t?.hint??`binary`}},Fi=globalThis.Buffer,Ii=!!Fi&&typeof Fi.from==`function`;function Li(e){if(e.length===0)return``;if(Ii)return Fi.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 Ri(e){if(e.length===0)return new Uint8Array;if(Ii){let t=Fi.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 zi=Object.create(null),Bi=Object.create(null),Vi=e=>new ReadableStream({start(t){e.on({next(e){try{t.enqueue(Ri(e))}catch{}},throw(e){t.error(e)},return(){try{t.close()}catch{}}})}}),Hi=new TextEncoder,Ui=e=>new ReadableStream({start(t){e.on({next(e){try{typeof e==`string`?t.enqueue(Hi.encode(e)):t.enqueue(Ri(e.$b64))}catch{}},throw(e){t.error(e)},return(){try{t.close()}catch{}}})}}),Wi=`(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(_){}}})}}))`,Gi=`(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 Ki(e){let t=Vn(),n=e.getReader();return(async()=>{try{for(;;){let{done:e,value:r}=await n.read();if(e){t.return(void 0);break}t.next(Li(r))}}catch(e){t.throw(e)}finally{n.releaseLock()}})(),t}function qi(e){let t=Vn(),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:Li(i)})}}}catch(e){t.throw(e)}finally{n.releaseLock()}})(),t}var Ji=Dr({tag:`tss/RawStream`,extends:[Dr({tag:`tss/RawStreamFactory`,test(e){return e===zi},parse:{sync(){},async(){return Promise.resolve(void 0)},stream(){}},serialize(){return Wi},deserialize(){return zi}}),Dr({tag:`tss/RawStreamFactoryText`,test(e){return e===Bi},parse:{sync(){},async(){return Promise.resolve(void 0)},stream(){}},serialize(){return Gi},deserialize(){return Bi}})],test(e){return e instanceof Pi},parse:{sync(e,t){let n=e.hint===`text`?Bi:zi;return{hint:e.hint,factory:t.parse(n),stream:t.parse(Vn())}},async async(e,t){let n=e.hint===`text`?Bi:zi,r=e.hint===`text`?qi(e.stream):Ki(e.stream);return{hint:e.hint,factory:await t.parse(n),stream:await t.parse(r)}},stream(e,t){let n=e.hint===`text`?Bi:zi,r=e.hint===`text`?qi(e.stream):Ki(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`?Ui(n):Vi(n)}});function Yi(e){return Dr({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 Xi=[Ni,Ji,Mi],Zi=V.use,Qi=typeof window<`u`?V.useLayoutEffect:V.useEffect;function $i(e){let t=V.useRef({value:e,prev:null}),n=t.current.value;return e!==n&&(t.current={value:e,prev:n}),t.current.prev}function ea(e,t,n={},r={}){V.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 ta(e){let t=V.useRef(null);return V.useImperativeHandle(e,()=>t.current,[]),t}var na=!0;function ra(e,t){if(!na){if(e)return;var n=`Warning: `+t;typeof console<`u`&&console.warn(n);try{throw Error(n)}catch{}}}var ia=o((e=>{var t=u();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 d(e,t){return t()}var f=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?d:c;e.useSyncExternalStore=t.useSyncExternalStore===void 0?f:t.useSyncExternalStore})),aa=o(((e,t)=>{t.exports=ia()})),oa=o((e=>{var t=u(),n=aa();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}})),sa=o(((e,t)=>{t.exports=oa()}))();function ca(e,t){return e===t}function la(e,t,n=ca){let r=(0,V.useCallback)(t=>{if(!e)return()=>{};let{unsubscribe:n}=e.subscribe(t);return n},[e]),i=(0,V.useCallback)(()=>e?.get(),[e]);return(0,sa.useSyncExternalStoreWithSelector)(r,i,i,t,n)}var ua=V.createContext(null);function da(e){let t=V.useContext(ua);return ra(!((e?.warn??!0)&&!t),`useRouter must be used inside a <RouterProvider> component!`),t}function fa(e){let t=da({warn:e?.router===void 0}),n=e?.router||t,r=(0,V.useRef)(void 0);return la(n.__store,t=>{if(e?.select){if(e.structuralSharing??n.options.defaultStructuralSharing){let n=xe(r.current,e.select(t));return r.current=n,n}return e.select(t)}return t})}var pa=V.createContext(void 0),ma=V.createContext(void 0);function ha(e){let t=V.useContext(e.from?ma:pa);return fa({select:n=>{let r=n.matches.find(n=>e.from?e.from===n.routeId:n.id===t);if(Ve(!((e.shouldThrow??!0)&&!r),`Could not find ${e.from?`an active match from "${e.from}"`:`a nearest match!`}`),r!==void 0)return e.select?e.select(r):r},structuralSharing:e.structuralSharing})}function ga(e){return ha({from:e.from,strict:e.strict,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.search):t.search})}function _a(e){let t=da();return V.useCallback(n=>t.navigate({...n,from:n.from??e?.from}),[e?.from,t])}var va=`__TSS_CONTEXT`,ya=Symbol.for(`TSS_SERVER_FUNCTION`),ba=Symbol.for(`TSS_SERVER_FUNCTION_FACTORY`),xa=`application/x-tss-framed`,Sa={JSON:0,CHUNK:1,END:2,ERROR:3};`${xa}`;var Ca=/;\s*v=(\d+)/;function wa(e){let t=e.match(Ca);return t?parseInt(t[1],10):void 0}function Ta(e){let t=wa(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 Da(){return[...(Ea()?.serializationAdapters)?.map(Di)??[],...Xi]}var Oa=new TextDecoder,ka=new Uint8Array,Aa=16*1024*1024,ja=32*1024*1024,Ma=1024,Na=1e5;function Pa(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>=Ma)throw Error(`Too many raw streams in framed response (max ${Ma})`);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 ka;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>ja)throw Error(`Framed response buffer exceeded ${ja} bytes`);for(c.push(a),l+=a.length;;){let e=d();if(!e)break;let{type:n,streamId:i,length:a}=e;if(n!==Sa.JSON&&n!==Sa.CHUNK&&n!==Sa.END&&n!==Sa.ERROR)throw Error(`Unknown frame type: ${n}`);if(n===Sa.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>Aa)throw Error(`Frame payload too large: ${a} bytes (max ${Aa})`);let c=9+a;if(l<c)break;if(++o>Na)throw Error(`Too many frames in framed response (max ${Na})`);f(9);let p=f(a);switch(n){case Sa.JSON:try{s.enqueue(Oa.decode(p))}catch{}break;case Sa.CHUNK:{let e=u(i);e&&e.enqueue(p);break}case Sa.END:{let e=u(i);if(r.add(i),e){try{e.close()}catch{}t.delete(i)}break}case Sa.ERROR:{let e=u(i);if(r.add(i),e){let n=Oa.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 Fa=null,Ia=Object.prototype.hasOwnProperty;function La(e){for(let t in e)if(Ia.call(e,t))return!0;return!1}async function Ra(e,t,n){Fa||=Da();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`,`${xa}, application/x-ndjson, application/json`),r.method===`GET`){if(a===`formData`)throw Error(`FormData is not supported with GET requests`);let t=await za(r);if(t!==void 0){let n=Ue({payload:t});e.includes(`?`)?e+=`&${n}`:e+=`?${n}`}}let s;if(r.method===`POST`){let e=await Va(r);e?.contentType&&o.set(`content-type`,e.contentType),s=e?.body}return await Ha(async()=>i(e,{method:r.method,headers:o,signal:r.signal,body:s}))}async function za(e){let t=!1,n={};if(e.data!==void 0&&(t=!0,n.data=e.data),e.context&&La(e.context)&&(t=!0,n.context=e.context),t)return Ba(n)}async function Ba(e){return JSON.stringify(await Promise.resolve(Ti(e,{plugins:Fa})))}async function Va(e){if(e.data instanceof FormData){let t;return e.context&&La(e.context)&&(t=await Ba(e.context)),t!==void 0&&e.data.set(va,t),{body:e.data}}let t=await za(e);if(t)return{body:t,contentType:`application/json`}}async function Ha(e){let t;try{t=await e()}catch(e){if(e instanceof Response)t=e;else throw console.log(e),e}if(t.headers.get(`x-tss-raw`)===`true`)return t;let n=t.headers.get(`content-type`);if(Ve(n,`expected content-type header to be set`),t.headers.get(`x-tss-serialized`)){let e;if(n.includes(`application/x-tss-framed`)){if(Ta(n),!t.body)throw Error(`No response body for framed response`);let{getOrCreateStream:r,jsonChunks:i}=Pa(t.body),a=[Yi(r),...Fa||[]],o=new Map;e=await Wa({jsonStream:i,onMessage:e=>wi(e,{refs:o,plugins:a}),onError(e,t){console.error(e,t)}})}else if(n.includes(`application/x-ndjson`)){let n=new Map;e=await Ua({response:t,onMessage:e=>wi(e,{refs:n,plugins:Fa}),onError(e,t){console.error(e,t)}})}else n.includes(`application/json`)&&(e=wi(await t.json(),{plugins:Fa}));if(Ve(e,`expected result to be resolved`),e instanceof Error)throw e;return e}if(n.includes(`application/json`)){let e=await t.json(),n=Je(e);if(n)throw n;if(He(e))throw e;return e}if(!t.ok)throw Error(await t.text());return t}async function Ua({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 Wa({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 Ga(e){let t=`/_serverFn/`+e;return Object.assign((...e)=>{let n=Ea()?.serverFns?.fetch;return Ra(t,e,n??fetch)},{url:t,serverFnMeta:{id:e},[ya]:!0})}var Ka=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(){}},qa={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},Ja=new class{#e=qa;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 Ya(e){setTimeout(e,0)}var Xa=typeof window>`u`||`Deno`in globalThis;function Za(){}function Qa(e,t){return typeof e==`function`?e(t):e}function $a(e){return typeof e==`number`&&e>=0&&e!==1/0}function eo(e,t){return Math.max(e+(t||0)-Date.now(),0)}function to(e,t){return typeof e==`function`?e(t):e}function no(e,t){return typeof e==`function`?e(t):e}function ro(e,t){let{type:n=`all`,exact:r,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(r){if(t.queryHash!==ao(o,t.options))return!1}else if(!so(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 io(e,t){let{exact:n,status:r,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(n){if(oo(t.options.mutationKey)!==oo(a))return!1}else if(!so(t.options.mutationKey,a))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function ao(e,t){return(t?.queryKeyHashFn||oo)(e)}function oo(e){return JSON.stringify(e,(e,t)=>po(t)?Object.keys(t).sort().reduce((e,n)=>(e[n]=t[n],e),{}):t)}function so(e,t){return e===t?!0:typeof e==typeof t&&e&&t&&typeof e==`object`&&typeof t==`object`?Object.keys(t).every(n=>so(e[n],t[n])):!1}var co=Object.prototype.hasOwnProperty;function lo(e,t,n=0){if(e===t)return e;if(n>500)return t;let r=fo(e)&&fo(t);if(!r&&!(po(e)&&po(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:co.call(e,o))&&c++;continue}if(u===null||d===null||typeof u!=`object`||typeof d!=`object`){s[o]=d;continue}let f=lo(u,d,n+1);s[o]=f,f===u&&c++}return i===o&&c===i?e:s}function uo(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 fo(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function po(e){if(!mo(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!mo(n)||!n.hasOwnProperty(`isPrototypeOf`)||Object.getPrototypeOf(e)!==Object.prototype)}function mo(e){return Object.prototype.toString.call(e)===`[object Object]`}function ho(e){return new Promise(t=>{Ja.setTimeout(t,e)})}function go(e,t,n){return typeof n.structuralSharing==`function`?n.structuralSharing(e,t):n.structuralSharing===!1?t:lo(e,t)}function _o(e,t,n=0){let r=[...e,t];return n&&r.length>n?r.slice(1):r}function vo(e,t,n=0){let r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var yo=Symbol();function bo(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===yo?()=>Promise.reject(Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function xo(e,t){return typeof e==`function`?e(...t):!!e}function So(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 Co=new class extends Ka{#e;#t;#n;constructor(){super(),this.#n=e=>{if(!Xa&&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 wo(){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 To=Ya;function Eo(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=To,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 Do=Eo(),Oo=new class extends Ka{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(!Xa&&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 ko(e){return Math.min(1e3*2**e,3e4)}function Ao(e){return(e??`online`)===`online`?Oo.isOnline():!0}var jo=class extends Error{constructor(e){super(`CancelledError`),this.revert=e?.revert,this.silent=e?.silent}};function Mo(e){let t=!1,n=0,r,i=wo(),a=()=>i.status!==`pending`,o=t=>{if(!a()){let n=new jo(t);f(n),e.onCancel?.(n)}},s=()=>{t=!0},c=()=>{t=!1},l=()=>Co.isFocused()&&(e.networkMode===`always`||Oo.isOnline())&&e.canRun(),u=()=>Ao(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??(Xa?0:3),o=e.retryDelay??ko,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),ho(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 No=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),$a(this.gcTime)&&(this.#e=Ja.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Xa?1/0:300*1e3))}clearGcTimeout(){this.#e&&=(Ja.clearTimeout(this.#e),void 0)}},Po=class extends No{#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=Lo(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=Lo(this.options);e.data!==void 0&&(this.setState(Io(e.data,e.dataUpdatedAt)),this.#e=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus===`idle`&&this.#n.remove(this)}setData(e,t){let n=go(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(Za).catch(Za):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#e)}isActive(){return this.observers.some(e=>no(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===yo||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>to(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:!eo(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=bo(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=Mo({initialPromise:t?.initialPromise,fn:a.fetchFn,onCancel:e=>{e instanceof jo&&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 jo){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,...Fo(t.data,this.options),fetchMeta:e.meta??null};case`success`:let n={...t,...Io(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),Do.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),this.#n.notify({query:this,type:`updated`,action:e})})}};function Fo(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Ao(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}function Io(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:`success`}}function Lo(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 Ro=class extends No{#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||zo(),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=Mo({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),Do.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:`updated`,action:e})})}};function zo(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:`idle`,variables:void 0,submittedAt:0}}var q=m(),Bo=V.createContext(void 0),Vo=e=>{let t=V.useContext(Bo);if(e)return e;if(!t)throw Error(`No QueryClient set, use QueryClientProvider to set one`);return t},Ho=({client:e,children:t})=>(V.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),(0,q.jsx)(Bo.Provider,{value:e,children:t})),Uo=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),Wo=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),Go=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),Ko=e=>{let t=Go(e);return t.charAt(0).toUpperCase()+t.slice(1)},qo={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`},Jo=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},Yo=(0,V.forwardRef)(({color:e=`currentColor`,size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:i=``,children:a,iconNode:o,...s},c)=>(0,V.createElement)(`svg`,{ref:c,...qo,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Uo(`lucide`,i),...!a&&!Jo(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,V.createElement)(e,t)),...Array.isArray(a)?a:[a]])),Xo=(e,t)=>{let n=(0,V.forwardRef)(({className:n,...r},i)=>(0,V.createElement)(Yo,{ref:i,iconNode:t,className:Uo(`lucide-${Wo(Ko(e))}`,`lucide-${e}`,n),...r}));return n.displayName=Ko(e),n},Zo=Xo(`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`}]]),Qo=Xo(`panel-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}]]),$o=Xo(`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`}]]),es=Xo(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),ts=c(f(),1);function ns(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=ns(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n);return r}function rs(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=ns(e))&&(r&&(r+=` `),r+=t);return r}var is=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,as=rs,os=(e,t)=>n=>{if(t?.variants==null)return as(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=is(t)||is(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 as(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 ss(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function cs(...e){return t=>{let n=!1,r=e.map(e=>{let r=ss(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():ss(e[t],null)}}}}function ls(...e){return V.useCallback(cs(...e),e)}function us(e){let t=fs(e),n=V.forwardRef((e,n)=>{let{children:r,...i}=e,a=V.Children.toArray(r),o=a.find(hs);if(o){let e=o.props.children,r=a.map(t=>t===o?V.Children.count(e)>1?V.Children.only(null):V.isValidElement(e)?e.props.children:null:t);return(0,q.jsx)(t,{...i,ref:n,children:V.isValidElement(e)?V.cloneElement(e,void 0,r):null})}return(0,q.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}var ds=us(`Slot`);function fs(e){let t=V.forwardRef((e,t)=>{let{children:n,...r}=e;if(V.isValidElement(n)){let e=_s(n),i=gs(r,n.props);return n.type!==V.Fragment&&(i.ref=t?cs(t,e):e),V.cloneElement(n,i)}return V.Children.count(n)>1?V.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var ps=Symbol(`radix.slottable`);function ms(e){let t=({children:e})=>(0,q.jsx)(q.Fragment,{children:e});return t.displayName=`${e}.Slottable`,t.__radixId=ps,t}function hs(e){return V.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===ps}function gs(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 _s(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 J=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=us(`Primitive.${t}`),r=V.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,q.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function vs(e,t){e&&ts.flushSync(()=>e.dispatchEvent(t))}var ys=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`}),bs=`VisuallyHidden`,xs=V.forwardRef((e,t)=>(0,q.jsx)(J.span,{...e,ref:t,style:{...ys,...e.style}}));xs.displayName=bs;var Ss=xs;function Cs(e,t){let n=V.createContext(t),r=e=>{let{children:t,...r}=e,i=V.useMemo(()=>r,Object.values(r));return(0,q.jsx)(n.Provider,{value:i,children:t})};r.displayName=e+`Provider`;function i(r){let i=V.useContext(n);if(i)return i;if(t!==void 0)return t;throw Error(`\`${r}\` must be used within \`${e}\``)}return[r,i]}function ws(e,t=[]){let n=[];function r(t,r){let i=V.createContext(r),a=n.length;n=[...n,r];let o=t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=V.useMemo(()=>o,Object.values(o));return(0,q.jsx)(s.Provider,{value:c,children:r})};o.displayName=t+`Provider`;function s(n,o){let s=o?.[e]?.[a]||i,c=V.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=>V.createContext(e));return function(n){let r=n?.[e]||t;return V.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])}};return i.scopeName=e,[r,Ts(i,...t)]}function Ts(...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 V.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])}};return n.scopeName=t.scopeName,n}typeof window<`u`&&window.document&&window.document.createElement;function Es(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r.defaultPrevented)return t?.(r)}}var Ds=globalThis?.document?V.useLayoutEffect:()=>{},Os=V.useInsertionEffect||Ds;function ks({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,o]=As({defaultProp:t,onChange:n}),s=e!==void 0,c=s?e:i;{let t=V.useRef(e!==void 0);V.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,V.useCallback(t=>{if(s){let n=js(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}function As({defaultProp:e,onChange:t}){let[n,r]=V.useState(e),i=V.useRef(n),a=V.useRef(t);return Os(()=>{a.current=t},[t]),V.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}function js(e){return typeof e==`function`}function Ms(e,t){return V.useReducer((e,n)=>t[e][n]??e,e)}var Ns=e=>{let{present:t,children:n}=e,r=Ps(t),i=typeof n==`function`?n({present:r.isPresent}):V.Children.only(n),a=ls(r.ref,Is(i));return typeof n==`function`||r.isPresent?V.cloneElement(i,{ref:a}):null};Ns.displayName=`Presence`;function Ps(e){let[t,n]=V.useState(),r=V.useRef(null),i=V.useRef(e),a=V.useRef(`none`),[o,s]=Ms(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return V.useEffect(()=>{let e=Fs(r.current);a.current=o===`mounted`?e:`none`},[o]),Ds(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,o=Fs(t);e?s(`MOUNT`):o===`none`||t?.display===`none`?s(`UNMOUNT`):s(n&&r!==o?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,s]),Ds(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=a=>{let o=Fs(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=Fs(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:V.useCallback(e=>{r.current=e?getComputedStyle(e):null,n(e)},[])}}function Fs(e){return e?.animationName||`none`}function Is(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=V.useId||(()=>void 0),Rs=0;function zs(e){let[t,n]=V.useState(Ls());return Ds(()=>{e||n(e=>e??String(Rs++))},[e]),e||(t?`radix-${t}`:``)}function Bs(e){let t=V.useRef(e);return V.useEffect(()=>{t.current=e}),V.useMemo(()=>(...e)=>t.current?.(...e),[])}function Vs(e,t=globalThis?.document){let n=Bs(e);V.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 Hs=`DismissableLayer`,Us=`dismissableLayer.update`,Ws=`dismissableLayer.pointerDownOutside`,Gs=`dismissableLayer.focusOutside`,Ks,qs=V.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Js=V.forwardRef((e,t)=>{let{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:s,...c}=e,l=V.useContext(qs),[u,d]=V.useState(null),f=u?.ownerDocument??globalThis?.document,[,p]=V.useState({}),m=ls(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=Zs(e=>{let t=e.target,n=[...l.branches].some(e=>e.contains(t));!b||n||(i?.(e),o?.(e),e.defaultPrevented||s?.())},f),S=Qs(e=>{let t=e.target;[...l.branches].some(e=>e.contains(t))||(a?.(e),o?.(e),e.defaultPrevented||s?.())},f);return Vs(e=>{v===l.layers.size-1&&(r?.(e),!e.defaultPrevented&&s&&(e.preventDefault(),s()))},f),V.useEffect(()=>{if(u)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(Ks=f.body.style.pointerEvents,f.body.style.pointerEvents=`none`),l.layersWithOutsidePointerEventsDisabled.add(u)),l.layers.add(u),$s(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=Ks)}},[u,f,n,l]),V.useEffect(()=>()=>{u&&(l.layers.delete(u),l.layersWithOutsidePointerEventsDisabled.delete(u),$s())},[u,l]),V.useEffect(()=>{let e=()=>p({});return document.addEventListener(Us,e),()=>document.removeEventListener(Us,e)},[]),(0,q.jsx)(J.div,{...c,ref:m,style:{pointerEvents:y?b?`auto`:`none`:void 0,...e.style},onFocusCapture:Es(e.onFocusCapture,S.onFocusCapture),onBlurCapture:Es(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:Es(e.onPointerDownCapture,x.onPointerDownCapture)})});Js.displayName=Hs;var Ys=`DismissableLayerBranch`,Xs=V.forwardRef((e,t)=>{let n=V.useContext(qs),r=V.useRef(null),i=ls(t,r);return V.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,q.jsx)(J.div,{...e,ref:i})});Xs.displayName=Ys;function Zs(e,t=globalThis?.document){let n=Bs(e),r=V.useRef(!1),i=V.useRef(()=>{});return V.useEffect(()=>{let e=e=>{if(e.target&&!r.current){let r=function(){ec(Ws,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 Qs(e,t=globalThis?.document){let n=Bs(e),r=V.useRef(!1);return V.useEffect(()=>{let e=e=>{e.target&&!r.current&&ec(Gs,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 $s(){let e=new CustomEvent(Us);document.dispatchEvent(e)}function ec(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?vs(i,a):i.dispatchEvent(a)}var tc=`focusScope.autoFocusOnMount`,nc=`focusScope.autoFocusOnUnmount`,rc={bubbles:!1,cancelable:!0},ic=`FocusScope`,ac=V.forwardRef((e,t)=>{let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=V.useState(null),l=Bs(i),u=Bs(a),d=V.useRef(null),f=ls(t,e=>c(e)),p=V.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;V.useEffect(()=>{if(r){let e=function(e){if(p.paused||!s)return;let t=e.target;s.contains(t)?d.current=t:fc(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||fc(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&fc(s)};document.addEventListener(`focusin`,e),document.addEventListener(`focusout`,t);let r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener(`focusin`,e),document.removeEventListener(`focusout`,t),r.disconnect()}}},[r,s,p.paused]),V.useEffect(()=>{if(s){pc.add(p);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(tc,rc);s.addEventListener(tc,l),s.dispatchEvent(t),t.defaultPrevented||(oc(gc(cc(s)),{select:!0}),document.activeElement===e&&fc(s))}return()=>{s.removeEventListener(tc,l),setTimeout(()=>{let t=new CustomEvent(nc,rc);s.addEventListener(nc,u),s.dispatchEvent(t),t.defaultPrevented||fc(e??document.body,{select:!0}),s.removeEventListener(nc,u),pc.remove(p)},0)}}},[s,l,u,p]);let m=V.useCallback(e=>{if(!n&&!r||p.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,i=document.activeElement;if(t&&i){let t=e.currentTarget,[r,a]=sc(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&fc(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&fc(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,p.paused]);return(0,q.jsx)(J.div,{tabIndex:-1,...o,ref:f,onKeyDown:m})});ac.displayName=ic;function oc(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(fc(r,{select:t}),document.activeElement!==n)return}function sc(e){let t=cc(e);return[lc(t,e),lc(t.reverse(),e)]}function cc(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function lc(e,t){for(let n of e)if(!uc(n,{upTo:t}))return n}function uc(e,{upTo:t}){if(getComputedStyle(e).visibility===`hidden`)return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display===`none`)return!0;e=e.parentElement}return!1}function dc(e){return e instanceof HTMLInputElement&&`select`in e}function fc(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&dc(e)&&t&&e.select()}}var pc=mc();function mc(){let e=[];return{add(t){let n=e[0];t!==n&&n?.pause(),e=hc(e,t),e.unshift(t)},remove(t){e=hc(e,t),e[0]?.resume()}}}function hc(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function gc(e){return e.filter(e=>e.tagName!==`A`)}var _c=`Portal`,vc=V.forwardRef((e,t)=>{let{container:n,...r}=e,[i,a]=V.useState(!1);Ds(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?ts.createPortal((0,q.jsx)(J.div,{...r,ref:t}),o):null});vc.displayName=_c;var yc=0;function bc(){V.useEffect(()=>{let e=document.querySelectorAll(`[data-radix-focus-guard]`);return document.body.insertAdjacentElement(`afterbegin`,e[0]??xc()),document.body.insertAdjacentElement(`beforeend`,e[1]??xc()),yc++,()=>{yc===1&&document.querySelectorAll(`[data-radix-focus-guard]`).forEach(e=>e.remove()),yc--}},[])}function xc(){let e=document.createElement(`span`);return e.setAttribute(`data-radix-focus-guard`,``),e.tabIndex=0,e.style.outline=`none`,e.style.opacity=`0`,e.style.position=`fixed`,e.style.pointerEvents=`none`,e}var Sc=function(){return Sc=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Sc.apply(this,arguments)};function Cc(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function wc(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||=Array.prototype.slice.call(t,0,r),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}var Tc=`right-scroll-bar-position`,Ec=`width-before-scroll-bar`,Dc=`with-scroll-bars-hidden`,Oc=`--removed-body-scroll-bar-size`;function kc(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function Ac(e,t){var n=(0,V.useState)(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(e){var t=n.value;t!==e&&(n.value=e,n.callback(e,t))}}}})[0];return n.callback=t,n.facade}var jc=typeof window<`u`?V.useLayoutEffect:V.useEffect,Mc=new WeakMap;function Nc(e,t){var n=Ac(t||null,function(t){return e.forEach(function(e){return kc(e,t)})});return jc(function(){var t=Mc.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||kc(e,null)}),i.forEach(function(e){r.has(e)||kc(e,a)})}Mc.set(n,e)},[e]),n}function Pc(e){return e}function Fc(e,t){t===void 0&&(t=Pc);var n=[],r=!1;return{read:function(){if(r)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var i=t(e,r);return n.push(i),function(){n=n.filter(function(e){return e!==i})}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var i=n;n=[],i.forEach(e),t=n}var a=function(){var n=t;t=[],n.forEach(e)},o=function(){return Promise.resolve().then(a)};o(),n={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),n}}}}}function Ic(e){e===void 0&&(e={});var t=Fc(null);return t.options=Sc({async:!0,ssr:!1},e),t}var Lc=function(e){var t=e.sideCar,n=Cc(e,[`sideCar`]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error(`Sidecar medium not found`);return V.createElement(r,Sc({},n))};Lc.isSideCarExport=!0;function Rc(e,t){return e.useMedium(t),Lc}var zc=Ic(),Bc=function(){},Vc=V.forwardRef(function(e,t){var n=V.useRef(null),r=V.useState({onScrollCapture:Bc,onWheelCapture:Bc,onTouchMoveCapture:Bc}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,d=e.shards,f=e.sideCar,p=e.noRelative,m=e.noIsolation,h=e.inert,g=e.allowPinchZoom,_=e.as,v=_===void 0?`div`:_,y=e.gapMode,b=Cc(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),x=f,S=Nc([n,t]),C=Sc(Sc({},b),i);return V.createElement(V.Fragment,null,u&&V.createElement(x,{sideCar:zc,removeScrollBar:l,shards:d,noRelative:p,noIsolation:m,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:y}),o?V.cloneElement(V.Children.only(s),Sc(Sc({},C),{ref:S})):V.createElement(v,Sc({},C,{className:c,ref:S}),s))});Vc.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Vc.classNames={fullWidth:Ec,zeroRight:Tc};var Hc,Uc=function(){if(Hc)return Hc;if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function Wc(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=Uc();return t&&e.setAttribute(`nonce`,t),e}function Gc(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Kc(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var qc=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Wc())&&(Gc(t,n),Kc(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Jc=function(){var e=qc();return function(t,n){V.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Yc=function(){var e=Jc();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},Xc={left:0,top:0,right:0,gap:0},Zc=function(e){return parseInt(e||``,10)||0},Qc=function(e){var t=window.getComputedStyle(document.body),n=t[e===`padding`?`paddingLeft`:`marginLeft`],r=t[e===`padding`?`paddingTop`:`marginTop`],i=t[e===`padding`?`paddingRight`:`marginRight`];return[Zc(n),Zc(r),Zc(i)]},$c=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return Xc;var t=Qc(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},el=Yc(),tl=`data-scroll-locked`,nl=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n=`margin`),`
10
+ .${Dc} {
11
+ overflow: hidden ${r};
12
+ padding-right: ${s}px ${r};
13
+ }
14
+ body[${tl}] {
15
+ overflow: hidden ${r};
16
+ overscroll-behavior: contain;
17
+ ${[t&&`position: relative ${r};`,n===`margin`&&`
18
+ padding-left: ${i}px;
19
+ padding-top: ${a}px;
20
+ padding-right: ${o}px;
21
+ margin-left:0;
22
+ margin-top:0;
23
+ margin-right: ${s}px ${r};
24
+ `,n===`padding`&&`padding-right: ${s}px ${r};`].filter(Boolean).join(``)}
25
+ }
26
+
27
+ .${Tc} {
28
+ right: ${s}px ${r};
29
+ }
30
+
31
+ .${Ec} {
32
+ margin-right: ${s}px ${r};
33
+ }
34
+
35
+ .${Tc} .${Tc} {
36
+ right: 0 ${r};
37
+ }
38
+
39
+ .${Ec} .${Ec} {
40
+ margin-right: 0 ${r};
41
+ }
42
+
43
+ body[${tl}] {
44
+ ${Oc}: ${s}px;
45
+ }
46
+ `},rl=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},il=function(){V.useEffect(function(){return document.body.setAttribute(tl,(rl()+1).toString()),function(){var e=rl()-1;e<=0?document.body.removeAttribute(tl):document.body.setAttribute(tl,e.toString())}},[])},al=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;il();var a=V.useMemo(function(){return $c(i)},[i]);return V.createElement(el,{styles:nl(a,!t,i,n?``:`!important`)})},ol=!1;if(typeof window<`u`)try{var sl=Object.defineProperty({},`passive`,{get:function(){return ol=!0,!0}});window.addEventListener(`test`,sl,sl),window.removeEventListener(`test`,sl,sl)}catch{ol=!1}var cl=ol?{passive:!1}:!1,ll=function(e){return e.tagName===`TEXTAREA`},ul=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!ll(e)&&n[t]===`visible`)},dl=function(e){return ul(e,`overflowY`)},fl=function(e){return ul(e,`overflowX`)},pl=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),gl(e,r)){var i=_l(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},ml=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},hl=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},gl=function(e,t){return e===`v`?dl(t):fl(t)},_l=function(e,t){return e===`v`?ml(t):hl(t)},vl=function(e,t){return e===`h`&&t===`rtl`?-1:1},yl=function(e,t,n,r,i){var a=vl(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,c=t.contains(s),l=!1,u=o>0,d=0,f=0;do{if(!s)break;var p=_l(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&gl(e,s)&&(d+=h,f+=m);var g=s.parentNode;s=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(u&&(i&&Math.abs(d)<1||!i&&o>d)||!u&&(i&&Math.abs(f)<1||!i&&-o>f))&&(l=!0),l},bl=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},xl=function(e){return[e.deltaX,e.deltaY]},Sl=function(e){return e&&`current`in e?e.current:e},Cl=function(e,t){return e[0]===t[0]&&e[1]===t[1]},wl=function(e){return`
47
+ .block-interactivity-${e} {pointer-events: none;}
48
+ .allow-interactivity-${e} {pointer-events: all;}
49
+ `},Tl=0,El=[];function Dl(e){var t=V.useRef([]),n=V.useRef([0,0]),r=V.useRef(),i=V.useState(Tl++)[0],a=V.useState(Yc)[0],o=V.useRef(e);V.useEffect(function(){o.current=e},[e]),V.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=wc([e.lockRef.current],(e.shards||[]).map(Sl),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add(`allow-interactivity-${i}`)}),function(){document.body.classList.remove(`block-interactivity-${i}`),t.forEach(function(e){return e.classList.remove(`allow-interactivity-${i}`)})}}},[e.inert,e.lockRef.current,e.shards]);var s=V.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=bl(e),a=n.current,s=`deltaX`in e?e.deltaX:a[0]-i[0],c=`deltaY`in e?e.deltaY:a[1]-i[1],l,u=e.target,d=Math.abs(s)>Math.abs(c)?`h`:`v`;if(`touches`in e&&d===`h`&&u.type===`range`)return!1;var f=pl(d,u);if(!f)return!0;if(f?l=d:(l=d===`v`?`h`:`v`,f=pl(d,u)),!f)return!1;if(!r.current&&`changedTouches`in e&&(s||c)&&(r.current=l),!l)return!0;var p=r.current||l;return yl(p,t,e,p===`h`?s:c,!0)},[]),c=V.useCallback(function(e){var n=e;if(!(!El.length||El[El.length-1]!==a)){var r=`deltaY`in n?xl(n):bl(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&Cl(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var c=(o.current.shards||[]).map(Sl).filter(Boolean).filter(function(e){return e.contains(n.target)});(c.length>0?s(n,c[0]):!o.current.noIsolation)&&n.cancelable&&n.preventDefault()}}},[]),l=V.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:Ol(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),u=V.useCallback(function(e){n.current=bl(e),r.current=void 0},[]),d=V.useCallback(function(t){l(t.type,xl(t),t.target,s(t,e.lockRef.current))},[]),f=V.useCallback(function(t){l(t.type,bl(t),t.target,s(t,e.lockRef.current))},[]);V.useEffect(function(){return El.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener(`wheel`,c,cl),document.addEventListener(`touchmove`,c,cl),document.addEventListener(`touchstart`,u,cl),function(){El=El.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,c,cl),document.removeEventListener(`touchmove`,c,cl),document.removeEventListener(`touchstart`,u,cl)}},[]);var p=e.removeScrollBar,m=e.inert;return V.createElement(V.Fragment,null,m?V.createElement(a,{styles:wl(i)}):null,p?V.createElement(al,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Ol(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var kl=Rc(zc,Dl),Al=V.forwardRef(function(e,t){return V.createElement(Vc,Sc({},e,{ref:t,sideCar:kl}))});Al.classNames=Vc.classNames;var jl=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},Ml=new WeakMap,Nl=new WeakMap,Pl={},Fl=0,Il=function(e){return e&&(e.host||Il(e.parentNode))},Ll=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=Il(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},Rl=function(e,t,n,r){var i=Ll(t,Array.isArray(e)?e:[e]);Pl[n]||(Pl[n]=new WeakMap);var a=Pl[n],o=[],s=new Set,c=new Set(i),l=function(e){!e||s.has(e)||(s.add(e),l(e.parentNode))};i.forEach(l);var u=function(e){!e||c.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),i=t!==null&&t!==`false`,c=(Ml.get(e)||0)+1,l=(a.get(e)||0)+1;Ml.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Nl.set(e,!0),l===1&&e.setAttribute(n,`true`),i||e.setAttribute(r,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return u(t),s.clear(),Fl++,function(){o.forEach(function(e){var t=Ml.get(e)-1,i=a.get(e)-1;Ml.set(e,t),a.set(e,i),t||(Nl.has(e)||e.removeAttribute(r),Nl.delete(e)),i||e.removeAttribute(n)}),Fl--,Fl||(Ml=new WeakMap,Ml=new WeakMap,Nl=new WeakMap,Pl={})}},zl=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||jl(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),Rl(r,i,n,`aria-hidden`)):function(){return null}},Bl=`Dialog`,[Vl,Hl]=ws(Bl),[Ul,Wl]=Vl(Bl),Gl=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=V.useRef(null),c=V.useRef(null),[l,u]=ks({prop:r,defaultProp:i??!1,onChange:a,caller:Bl});return(0,q.jsx)(Ul,{scope:t,triggerRef:s,contentRef:c,contentId:zs(),titleId:zs(),descriptionId:zs(),open:l,onOpenChange:u,onOpenToggle:V.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})};Gl.displayName=Bl;var Kl=`DialogTrigger`,ql=V.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=Wl(Kl,n),a=ls(t,i.triggerRef);return(0,q.jsx)(J.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.contentId,"data-state":pu(i.open),...r,ref:a,onClick:Es(e.onClick,i.onOpenToggle)})});ql.displayName=Kl;var Jl=`DialogPortal`,[Yl,Xl]=Vl(Jl,{forceMount:void 0}),Zl=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=Wl(Jl,t);return(0,q.jsx)(Yl,{scope:t,forceMount:n,children:V.Children.map(r,e=>(0,q.jsx)(Ns,{present:n||a.open,children:(0,q.jsx)(vc,{asChild:!0,container:i,children:e})}))})};Zl.displayName=Jl;var Ql=`DialogOverlay`,$l=V.forwardRef((e,t)=>{let n=Xl(Ql,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=Wl(Ql,e.__scopeDialog);return a.modal?(0,q.jsx)(Ns,{present:r||a.open,children:(0,q.jsx)(tu,{...i,ref:t})}):null});$l.displayName=Ql;var eu=us(`DialogOverlay.RemoveScroll`),tu=V.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=Wl(Ql,n);return(0,q.jsx)(Al,{as:eu,allowPinchZoom:!0,shards:[i.contentRef],children:(0,q.jsx)(J.div,{"data-state":pu(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),nu=`DialogContent`,ru=V.forwardRef((e,t)=>{let n=Xl(nu,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=Wl(nu,e.__scopeDialog);return(0,q.jsx)(Ns,{present:r||a.open,children:a.modal?(0,q.jsx)(iu,{...i,ref:t}):(0,q.jsx)(au,{...i,ref:t})})});ru.displayName=nu;var iu=V.forwardRef((e,t)=>{let n=Wl(nu,e.__scopeDialog),r=V.useRef(null),i=ls(t,n.contentRef,r);return V.useEffect(()=>{let e=r.current;if(e)return zl(e)},[]),(0,q.jsx)(ou,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Es(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:Es(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:Es(e.onFocusOutside,e=>e.preventDefault())})}),au=V.forwardRef((e,t)=>{let n=Wl(nu,e.__scopeDialog),r=V.useRef(!1),i=V.useRef(!1);return(0,q.jsx)(ou,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),ou=V.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=Wl(nu,n),c=V.useRef(null),l=ls(t,c);return bc(),(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(ac,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,q.jsx)(Js,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":pu(s.open),...o,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),(0,q.jsxs)(q.Fragment,{children:[(0,q.jsx)(_u,{titleId:s.titleId}),(0,q.jsx)(yu,{contentRef:c,descriptionId:s.descriptionId})]})]})}),su=`DialogTitle`,cu=V.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=Wl(su,n);return(0,q.jsx)(J.h2,{id:i.titleId,...r,ref:t})});cu.displayName=su;var lu=`DialogDescription`,uu=V.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=Wl(lu,n);return(0,q.jsx)(J.p,{id:i.descriptionId,...r,ref:t})});uu.displayName=lu;var du=`DialogClose`,fu=V.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=Wl(du,n);return(0,q.jsx)(J.button,{type:`button`,...r,ref:t,onClick:Es(e.onClick,()=>i.onOpenChange(!1))})});fu.displayName=du;function pu(e){return e?`open`:`closed`}var mu=`DialogTitleWarning`,[hu,gu]=Cs(mu,{contentName:nu,titleName:su,docsSlug:`dialog`}),_u=({titleId:e})=>{let t=gu(mu),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
50
+
51
+ If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
52
+
53
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return V.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},vu=`DialogDescriptionWarning`,yu=({contentRef:e,descriptionId:t})=>{let n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${gu(vu).contentName}}.`;return V.useEffect(()=>{let r=e.current?.getAttribute(`aria-describedby`);t&&r&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},bu=Gl,xu=ql,Su=Zl,Cu=$l,wu=ru,Tu=cu,Eu=uu,Du=fu;function Ou(e){let[t,n]=V.useState(void 0);return Ds(()=>{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 ku=[`top`,`right`,`bottom`,`left`],Au=Math.min,ju=Math.max,Mu=Math.round,Nu=Math.floor,Pu=e=>({x:e,y:e}),Fu={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function Iu(e,t,n){return ju(e,Au(t,n))}function Lu(e,t){return typeof e==`function`?e(t):e}function Ru(e){return e.split(`-`)[0]}function zu(e){return e.split(`-`)[1]}function Bu(e){return e===`x`?`y`:`x`}function Vu(e){return e===`y`?`height`:`width`}function Hu(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function Uu(e){return Bu(Hu(e))}function Wu(e,t,n){n===void 0&&(n=!1);let r=zu(e),i=Uu(e),a=Vu(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=$u(o)),[o,$u(o)]}function Gu(e){let t=$u(e);return[Ku(e),t,Ku(t)]}function Ku(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var qu=[`left`,`right`],Ju=[`right`,`left`],Yu=[`top`,`bottom`],Xu=[`bottom`,`top`];function Zu(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Ju:qu:t?qu:Ju;case`left`:case`right`:return t?Yu:Xu;default:return[]}}function Qu(e,t,n,r){let i=zu(e),a=Zu(Ru(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(Ku)))),a}function $u(e){let t=Ru(e);return Fu[t]+e.slice(t.length)}function ed(e){return{top:0,right:0,bottom:0,left:0,...e}}function td(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:ed(e)}function nd(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 rd(e,t,n){let{reference:r,floating:i}=e,a=Hu(t),o=Uu(t),s=Vu(o),c=Ru(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(zu(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 id(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}=Lu(t,e),p=td(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=nd(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=nd(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 ad=50,od=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:id},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=rd(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<ad&&(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}=rd(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},sd=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}=Lu(e,t)||{};if(l==null)return{};let d=td(u),f={x:n,y:r},p=Uu(i),m=Vu(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=Au(d[_],E),ee=Au(d[v],E),O=D,k=C-h[m]-ee,A=C/2-h[m]/2+w,j=Iu(O,A,k),M=!c.arrow&&zu(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}}}),cd=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}=Lu(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=Ru(r),_=Hu(o),v=Ru(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[$u(o)]:Gu(o)),x=p!==`none`;!d&&x&&b.push(...Qu(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=Wu(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`&&_!==Hu(t))||E.every(e=>Hu(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=Hu(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 ld(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ud(e){return ku.some(t=>e[t]>=0)}var dd=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=Lu(e,t);switch(i){case`referenceHidden`:{let e=ld(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:ud(e)}}}case`escaped`:{let e=ld(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:ud(e)}}}default:return{}}}}},fd=new Set([`left`,`top`]);async function pd(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Ru(n),s=zu(n),c=Hu(n)===`y`,l=fd.has(o)?-1:1,u=a&&c?-1:1,d=Lu(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 md=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 pd(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}}}}},hd=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}=Lu(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=Hu(Ru(i)),p=Bu(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=Iu(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=Iu(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}}}}}},gd=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}=Lu(e,t),u={x:n,y:r},d=Hu(i),f=Bu(d),p=u[f],m=u[d],h=Lu(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=fd.has(Ru(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}}}},_d=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}=Lu(e,t),u=await o.detectOverflow(t,l),d=Ru(i),f=zu(i),p=Hu(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=Au(h-u[g],v),x=Au(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=ju(u.left,0),t=ju(u.right,0),n=ju(u.top,0),r=ju(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:ju(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:ju(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 vd(){return typeof window<`u`}function yd(e){return Sd(e)?(e.nodeName||``).toLowerCase():`#document`}function bd(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function xd(e){return((Sd(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function Sd(e){return vd()?e instanceof Node||e instanceof bd(e).Node:!1}function Cd(e){return vd()?e instanceof Element||e instanceof bd(e).Element:!1}function wd(e){return vd()?e instanceof HTMLElement||e instanceof bd(e).HTMLElement:!1}function Td(e){return!vd()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof bd(e).ShadowRoot}function Ed(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=Ld(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function Dd(e){return/^(table|td|th)$/.test(yd(e))}function Od(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var kd=/transform|translate|scale|rotate|perspective|filter/,Ad=/paint|layout|strict|content/,jd=e=>!!e&&e!==`none`,Md;function Nd(e){let t=Cd(e)?Ld(e):e;return jd(t.transform)||jd(t.translate)||jd(t.scale)||jd(t.rotate)||jd(t.perspective)||!Fd()&&(jd(t.backdropFilter)||jd(t.filter))||kd.test(t.willChange||``)||Ad.test(t.contain||``)}function Pd(e){let t=zd(e);for(;wd(t)&&!Id(t);){if(Nd(t))return t;if(Od(t))return null;t=zd(t)}return null}function Fd(){return Md??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),Md}function Id(e){return/^(html|body|#document)$/.test(yd(e))}function Ld(e){return bd(e).getComputedStyle(e)}function Rd(e){return Cd(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function zd(e){if(yd(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||Td(e)&&e.host||xd(e);return Td(t)?t.host:t}function Bd(e){let t=zd(e);return Id(t)?e.ownerDocument?e.ownerDocument.body:e.body:wd(t)&&Ed(t)?t:Bd(t)}function Vd(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=Bd(e),i=r===e.ownerDocument?.body,a=bd(r);if(i){let e=Hd(a);return t.concat(a,a.visualViewport||[],Ed(r)?r:[],e&&n?Vd(e):[])}else return t.concat(r,Vd(r,[],n))}function Hd(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ud(e){let t=Ld(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=wd(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Mu(n)!==a||Mu(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function Wd(e){return Cd(e)?e:e.contextElement}function Gd(e){let t=Wd(e);if(!wd(t))return Pu(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=Ud(t),o=(a?Mu(n.width):n.width)/r,s=(a?Mu(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var Kd=Pu(0);function qd(e){let t=bd(e);return!Fd()||!t.visualViewport?Kd:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Jd(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==bd(e)?!1:t}function Yd(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=Wd(e),o=Pu(1);t&&(r?Cd(r)&&(o=Gd(r)):o=Gd(e));let s=Jd(a,n,r)?qd(a):Pu(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=bd(a),t=r&&Cd(r)?bd(r):r,n=e,i=Hd(n);for(;i&&r&&t!==n;){let e=Gd(i),t=i.getBoundingClientRect(),r=Ld(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=bd(i),i=Hd(n)}}return nd({width:u,height:d,x:c,y:l})}function Xd(e,t){let n=Rd(e).scrollLeft;return t?t.left+n:Yd(xd(e)).left+n}function Zd(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Xd(e,n),y:n.top+t.scrollTop}}function Qd(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=xd(r),s=t?Od(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=Pu(1),u=Pu(0),d=wd(r);if((d||!d&&!a)&&((yd(r)!==`body`||Ed(o))&&(c=Rd(r)),d)){let e=Yd(r);l=Gd(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?Zd(o,c):Pu(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 $d(e){return Array.from(e.getClientRects())}function ef(e){let t=xd(e),n=Rd(e),r=e.ownerDocument.body,i=ju(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=ju(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+Xd(e),s=-n.scrollTop;return Ld(r).direction===`rtl`&&(o+=ju(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var tf=25;function nf(e,t){let n=bd(e),r=xd(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=Fd();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=Xd(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<=tf&&(a-=o)}else l<=tf&&(a+=l);return{width:a,height:o,x:s,y:c}}function rf(e,t){let n=Yd(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=wd(e)?Gd(e):Pu(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function af(e,t,n){let r;if(t===`viewport`)r=nf(e,n);else if(t===`document`)r=ef(xd(e));else if(Cd(t))r=rf(t,n);else{let n=qd(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return nd(r)}function of(e,t){let n=zd(e);return n===t||!Cd(n)||Id(n)?!1:Ld(n).position===`fixed`||of(n,t)}function sf(e,t){let n=t.get(e);if(n)return n;let r=Vd(e,[],!1).filter(e=>Cd(e)&&yd(e)!==`body`),i=null,a=Ld(e).position===`fixed`,o=a?zd(e):e;for(;Cd(o)&&!Id(o);){let t=Ld(o),n=Nd(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||Ed(o)&&!n&&of(e,o))?r=r.filter(e=>e!==o):i=t,o=zd(o)}return t.set(e,r),r}function cf(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?Od(t)?[]:sf(t,this._c):[].concat(n),r],o=af(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=af(t,a[e],i);s=ju(n.top,s),c=Au(n.right,c),l=Au(n.bottom,l),u=ju(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function lf(e){let{width:t,height:n}=Ud(e);return{width:t,height:n}}function uf(e,t,n){let r=wd(t),i=xd(t),a=n===`fixed`,o=Yd(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=Pu(0);function l(){c.x=Xd(i)}if(r||!r&&!a)if((yd(t)!==`body`||Ed(i))&&(s=Rd(t)),r){let e=Yd(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?Zd(i,s):Pu(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 df(e){return Ld(e).position===`static`}function ff(e,t){if(!wd(e)||Ld(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return xd(e)===n&&(n=n.ownerDocument.body),n}function pf(e,t){let n=bd(e);if(Od(e))return n;if(!wd(e)){let t=zd(e);for(;t&&!Id(t);){if(Cd(t)&&!df(t))return t;t=zd(t)}return n}let r=ff(e,t);for(;r&&Dd(r)&&df(r);)r=ff(r,t);return r&&Id(r)&&df(r)&&!Nd(r)?n:r||Pd(e)||n}var mf=async function(e){let t=this.getOffsetParent||pf,n=this.getDimensions,r=await n(e.floating);return{reference:uf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function hf(e){return Ld(e).direction===`rtl`}var gf={convertOffsetParentRelativeRectToViewportRelativeRect:Qd,getDocumentElement:xd,getClippingRect:cf,getOffsetParent:pf,getElementRects:mf,getClientRects:$d,getDimensions:lf,getScale:Gd,isElement:Cd,isRTL:hf};function _f(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function vf(e,t){let n=null,r,i=xd(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=Nu(d),h=Nu(i.clientWidth-(u+f)),g=Nu(i.clientHeight-(d+p)),_=Nu(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:ju(0,Au(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&&!_f(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 yf(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=Wd(e),u=i||a?[...l?Vd(l):[],...t?Vd(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?vf(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?Yd(e):null;c&&g();function g(){let t=Yd(e);h&&!_f(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 bf=md,xf=hd,Sf=cd,Cf=_d,wf=dd,Tf=sd,Ef=gd,Df=(e,t,n)=>{let r=new Map,i={platform:gf,...n},a={...i.platform,_c:r};return od(e,t,{...i,platform:a})},Of=typeof document<`u`?V.useLayoutEffect:function(){};function kf(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(!kf(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)&&!kf(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function Af(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function jf(e,t){let n=Af(e);return Math.round(t*n)/n}function Mf(e){let t=V.useRef(e);return Of(()=>{t.current=e}),t}function Nf(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]=V.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=V.useState(r);kf(f,r)||p(r);let[m,h]=V.useState(null),[g,_]=V.useState(null),v=V.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=V.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=V.useRef(null),C=V.useRef(null),w=V.useRef(u),E=c!=null,D=Mf(c),ee=Mf(i),O=Mf(l),k=V.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};ee.current&&(e.platform=ee.current),Df(S.current,C.current,e).then(e=>{let t={...e,isPositioned:O.current!==!1};A.current&&!kf(w.current,t)&&(w.current=t,ts.flushSync(()=>{d(t)}))})},[f,t,n,ee,O]);Of(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let A=V.useRef(!1);Of(()=>(A.current=!0,()=>{A.current=!1}),[]),Of(()=>{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=V.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),M=V.useMemo(()=>({reference:b,floating:x}),[b,x]),N=V.useMemo(()=>{let e={position:n,left:0,top:0};if(!M.floating)return e;let t=jf(M.floating,u.x),r=jf(M.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...Af(M.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,M.floating,u.x,u.y]);return V.useMemo(()=>({...u,update:k,refs:j,elements:M,floatingStyles:N}),[u,k,j,M,N])}var Pf=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?{}:Tf({element:r.current,padding:i}).fn(n):r?Tf({element:r,padding:i}).fn(n):{}}}},Ff=(e,t)=>{let n=bf(e);return{name:n.name,fn:n.fn,options:[e,t]}},If=(e,t)=>{let n=xf(e);return{name:n.name,fn:n.fn,options:[e,t]}},Lf=(e,t)=>({fn:Ef(e).fn,options:[e,t]}),Rf=(e,t)=>{let n=Sf(e);return{name:n.name,fn:n.fn,options:[e,t]}},zf=(e,t)=>{let n=Cf(e);return{name:n.name,fn:n.fn,options:[e,t]}},Bf=(e,t)=>{let n=wf(e);return{name:n.name,fn:n.fn,options:[e,t]}},Vf=(e,t)=>{let n=Pf(e);return{name:n.name,fn:n.fn,options:[e,t]}},Hf=`Arrow`,Uf=V.forwardRef((e,t)=>{let{children:n,width:r=10,height:i=5,...a}=e;return(0,q.jsx)(J.svg,{...a,ref:t,width:r,height:i,viewBox:`0 0 30 10`,preserveAspectRatio:`none`,children:e.asChild?n:(0,q.jsx)(`polygon`,{points:`0,0 30,0 15,10`})})});Uf.displayName=Hf;var Wf=Uf,Gf=`Popper`,[Kf,qf]=ws(Gf),[Jf,Yf]=Kf(Gf),Xf=e=>{let{__scopePopper:t,children:n}=e,[r,i]=V.useState(null);return(0,q.jsx)(Jf,{scope:t,anchor:r,onAnchorChange:i,children:n})};Xf.displayName=Gf;var Zf=`PopperAnchor`,Qf=V.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:r,...i}=e,a=Yf(Zf,n),o=V.useRef(null),s=ls(t,o),c=V.useRef(null);return V.useEffect(()=>{let e=c.current;c.current=r?.current||o.current,e!==c.current&&a.onAnchorChange(c.current)}),r?null:(0,q.jsx)(J.div,{...i,ref:s})});Qf.displayName=Zf;var $f=`PopperContent`,[ep,tp]=Kf($f),np=V.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=Yf($f,n),[_,v]=V.useState(null),y=ls(t,e=>v(e)),[b,x]=V.useState(null),S=Ou(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(op),altBoundary:O},{refs:A,floatingStyles:j,placement:M,isPositioned:N,middlewareData:P}=Nf({strategy:`fixed`,placement:E,whileElementsMounted:(...e)=>yf(...e,{animationFrame:p===`always`}),elements:{reference:g.anchor},middleware:[Ff({mainAxis:i+w,alignmentAxis:o}),c&&If({mainAxis:!0,crossAxis:!1,limiter:d===`partial`?Lf():void 0,...k}),c&&Rf({...k}),zf({...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&&Vf({element:b,padding:s}),sp({arrowWidth:C,arrowHeight:w}),f&&Bf({strategy:`referenceHidden`,...k})]}),[F,I]=cp(M),te=Bs(m);Ds(()=>{N&&te?.()},[N,te]);let ne=P.arrow?.x,re=P.arrow?.y,ie=P.arrow?.centerOffset!==0,[L,R]=V.useState();return Ds(()=>{_&&R(window.getComputedStyle(_).zIndex)},[_]),(0,q.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,q.jsx)(ep,{scope:n,placedSide:F,onArrowChange:x,arrowX:ne,arrowY:re,shouldHideArrow:ie,children:(0,q.jsx)(J.div,{"data-side":F,"data-align":I,...h,ref:y,style:{...h.style,animation:N?void 0:`none`}})})})});np.displayName=$f;var rp=`PopperArrow`,ip={top:`bottom`,right:`left`,bottom:`top`,left:`right`},ap=V.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,i=tp(rp,n),a=ip[i.placedSide];return(0,q.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,q.jsx)(Wf,{...r,ref:t,style:{...r.style,display:`block`}})})});ap.displayName=rp;function op(e){return e!==null}var sp=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]=cp(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 cp(e){let[t,n=`center`]=e.split(`-`);return[t,n]}var lp=Xf,up=Qf,dp=np,fp=ap,pp=`Separator`,mp=`horizontal`,hp=[`horizontal`,`vertical`],gp=V.forwardRef((e,t)=>{let{decorative:n,orientation:r=mp,...i}=e,a=_p(r)?r:mp,o=n?{role:`none`}:{"aria-orientation":a===`vertical`?a:void 0,role:`separator`};return(0,q.jsx)(J.div,{"data-orientation":a,...o,...i,ref:t})});gp.displayName=pp;function _p(e){return hp.includes(e)}var vp=gp,[yp,bp]=ws(`Tooltip`,[qf]),xp=qf(),Sp=`TooltipProvider`,Cp=700,wp=`tooltip.open`,[Tp,Ep]=yp(Sp),Dp=e=>{let{__scopeTooltip:t,delayDuration:n=Cp,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:a}=e,o=V.useRef(!0),s=V.useRef(!1),c=V.useRef(0);return V.useEffect(()=>{let e=c.current;return()=>window.clearTimeout(e)},[]),(0,q.jsx)(Tp,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:V.useCallback(()=>{window.clearTimeout(c.current),o.current=!1},[]),onClose:V.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>o.current=!0,r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:V.useCallback(e=>{s.current=e},[]),disableHoverableContent:i,children:a})};Dp.displayName=Sp;var Op=`Tooltip`,[kp,Ap]=yp(Op),jp=e=>{let{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,c=Ep(Op,e.__scopeTooltip),l=xp(t),[u,d]=V.useState(null),f=zs(),p=V.useRef(0),m=o??c.disableHoverableContent,h=s??c.delayDuration,g=V.useRef(!1),[_,v]=ks({prop:r,defaultProp:i??!1,onChange:e=>{e?(c.onOpen(),document.dispatchEvent(new CustomEvent(wp))):c.onClose(),a?.(e)},caller:Op}),y=V.useMemo(()=>_?g.current?`delayed-open`:`instant-open`:`closed`,[_]),b=V.useCallback(()=>{window.clearTimeout(p.current),p.current=0,g.current=!1,v(!0)},[v]),x=V.useCallback(()=>{window.clearTimeout(p.current),p.current=0,v(!1)},[v]),S=V.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{g.current=!0,v(!0),p.current=0},h)},[h,v]);return V.useEffect(()=>()=>{p.current&&=(window.clearTimeout(p.current),0)},[]),(0,q.jsx)(lp,{...l,children:(0,q.jsx)(kp,{scope:t,contentId:f,open:_,stateAttribute:y,trigger:u,onTriggerChange:d,onTriggerEnter:V.useCallback(()=>{c.isOpenDelayedRef.current?S():b()},[c.isOpenDelayedRef,S,b]),onTriggerLeave:V.useCallback(()=>{m?x():(window.clearTimeout(p.current),p.current=0)},[x,m]),onOpen:b,onClose:x,disableHoverableContent:m,children:n})})};jp.displayName=Op;var Mp=`TooltipTrigger`,Np=V.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=Ap(Mp,n),a=Ep(Mp,n),o=xp(n),s=ls(t,V.useRef(null),i.onTriggerChange),c=V.useRef(!1),l=V.useRef(!1),u=V.useCallback(()=>c.current=!1,[]);return V.useEffect(()=>()=>document.removeEventListener(`pointerup`,u),[u]),(0,q.jsx)(up,{asChild:!0,...o,children:(0,q.jsx)(J.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:s,onPointerMove:Es(e.onPointerMove,e=>{e.pointerType!==`touch`&&!l.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),l.current=!0)}),onPointerLeave:Es(e.onPointerLeave,()=>{i.onTriggerLeave(),l.current=!1}),onPointerDown:Es(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener(`pointerup`,u,{once:!0})}),onFocus:Es(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:Es(e.onBlur,i.onClose),onClick:Es(e.onClick,i.onClose)})})});Np.displayName=Mp;var Pp=`TooltipPortal`,[Fp,Ip]=yp(Pp,{forceMount:void 0}),Lp=e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,a=Ap(Pp,t);return(0,q.jsx)(Fp,{scope:t,forceMount:n,children:(0,q.jsx)(Ns,{present:n||a.open,children:(0,q.jsx)(vc,{asChild:!0,container:i,children:r})})})};Lp.displayName=Pp;var Rp=`TooltipContent`,zp=V.forwardRef((e,t)=>{let n=Ip(Rp,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i=`top`,...a}=e,o=Ap(Rp,e.__scopeTooltip);return(0,q.jsx)(Ns,{present:r||o.open,children:o.disableHoverableContent?(0,q.jsx)(Wp,{side:i,...a,ref:t}):(0,q.jsx)(Bp,{side:i,...a,ref:t})})}),Bp=V.forwardRef((e,t)=>{let n=Ap(Rp,e.__scopeTooltip),r=Ep(Rp,e.__scopeTooltip),i=V.useRef(null),a=ls(t,i),[o,s]=V.useState(null),{trigger:c,onClose:l}=n,u=i.current,{onPointerInTransitChange:d}=r,f=V.useCallback(()=>{s(null),d(!1)},[d]),p=V.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},i=Jp(r,qp(r,n.getBoundingClientRect())),a=Yp(t.getBoundingClientRect());s(Zp([...i,...a])),d(!0)},[d]);return V.useEffect(()=>()=>f(),[f]),V.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]),V.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=!Xp(n,o);r?f():i&&(f(),l())};return document.addEventListener(`pointermove`,e),()=>document.removeEventListener(`pointermove`,e)}},[c,u,o,l,f]),(0,q.jsx)(Wp,{...e,ref:a})}),[Vp,Hp]=yp(Op,{isInside:!1}),Up=ms(`TooltipContent`),Wp=V.forwardRef((e,t)=>{let{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:o,...s}=e,c=Ap(Rp,n),l=xp(n),{onClose:u}=c;return V.useEffect(()=>(document.addEventListener(wp,u),()=>document.removeEventListener(wp,u)),[u]),V.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,q.jsx)(Js,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:e=>e.preventDefault(),onDismiss:u,children:(0,q.jsxs)(dp,{"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,q.jsx)(Up,{children:r}),(0,q.jsx)(Vp,{scope:n,isInside:!0,children:(0,q.jsx)(Ss,{id:c.contentId,role:`tooltip`,children:i||r})})]})})});zp.displayName=Rp;var Gp=`TooltipArrow`,Kp=V.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=xp(n);return Hp(Gp,n).isInside?null:(0,q.jsx)(fp,{...i,...r,ref:t})});Kp.displayName=Gp;function qp(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 Jp(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 Yp(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 Xp(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 Zp(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)),Qp(t)}function Qp(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 $p=Dp,em=jp,tm=Np,nm=Lp,rm=zp,im=Kp,am=(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},om=(e,t)=>({classGroupId:e,validator:t}),sm=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),cm=`-`,lm=[],um=`arbitrary..`,dm=e=>{let t=mm(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return pm(e);let n=e.split(cm);return fm(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?am(i,t):t:i||lm}return n[e]||lm}}},fm=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=fm(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(cm):e.slice(t).join(cm),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},pm=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?um+r:void 0})(),mm=e=>{let{theme:t,classGroups:n}=e;return hm(n,t)},hm=(e,t)=>{let n=sm();for(let r in e){let i=e[r];gm(i,n,r,t)}return n},gm=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];_m(i,t,n,r)}},_m=(e,t,n,r)=>{if(typeof e==`string`){vm(e,t,n);return}if(typeof e==`function`){ym(e,t,n,r);return}bm(e,t,n,r)},vm=(e,t,n)=>{let r=e===``?t:xm(t,e);r.classGroupId=n},ym=(e,t,n,r)=>{if(Sm(e)){gm(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(om(n,e))},bm=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];gm(o,xm(t,a),n,r)}},xm=(e,t)=>{let n=e,r=t.split(cm),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=sm(),n.nextPart.set(t,i)),n=i}return n},Sm=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,Cm=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)}}},wm=`!`,Tm=`:`,Em=[],Dm=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),Om=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===Tm){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(wm)?(c=s.slice(0,-1),l=!0):s.startsWith(wm)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return Dm(t,l,c,u)};if(t){let e=t+Tm,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):Dm(Em,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},km=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}},Am=e=>({cache:Cm(e.cacheSize),parseClassName:Om(e),sortModifiers:km(e),...dm(e)}),jm=/\s+/,Mm=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,o=[],s=e.trim().split(jm),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+wm: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},Nm=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=Pm(n))&&(i&&(i+=` `),i+=r);return i},Pm=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=Pm(e[r]))&&(n&&(n+=` `),n+=t);return n},Fm=(e,...t)=>{let n,r,i,a,o=o=>(n=Am(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=Mm(e,n);return i(e,a),a};return a=o,(...e)=>a(Nm(...e))},Im=[],Y=e=>{let t=t=>t[e]||Im;return t.isThemeGetter=!0,t},Lm=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Rm=/^\((?:(\w[\w-]*):)?(.+)\)$/i,zm=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,Bm=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Vm=/\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$/,Hm=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Um=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Wm=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Gm=e=>zm.test(e),X=e=>!!e&&!Number.isNaN(Number(e)),Km=e=>!!e&&Number.isInteger(Number(e)),qm=e=>e.endsWith(`%`)&&X(e.slice(0,-1)),Jm=e=>Bm.test(e),Ym=()=>!0,Xm=e=>Vm.test(e)&&!Hm.test(e),Zm=()=>!1,Qm=e=>Um.test(e),$m=e=>Wm.test(e),eh=e=>!Z(e)&&!Q(e),th=e=>gh(e,bh,Zm),Z=e=>Lm.test(e),nh=e=>gh(e,xh,Xm),rh=e=>gh(e,Sh,X),ih=e=>gh(e,wh,Ym),ah=e=>gh(e,Ch,Zm),oh=e=>gh(e,vh,Zm),sh=e=>gh(e,yh,$m),ch=e=>gh(e,Th,Qm),Q=e=>Rm.test(e),lh=e=>_h(e,xh),uh=e=>_h(e,Ch),dh=e=>_h(e,vh),fh=e=>_h(e,bh),ph=e=>_h(e,yh),mh=e=>_h(e,Th,!0),hh=e=>_h(e,wh,!0),gh=(e,t,n)=>{let r=Lm.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},_h=(e,t,n=!1)=>{let r=Rm.exec(e);return r?r[1]?t(r[1]):n:!1},vh=e=>e===`position`||e===`percentage`,yh=e=>e===`image`||e===`url`,bh=e=>e===`length`||e===`size`||e===`bg-size`,xh=e=>e===`length`,Sh=e=>e===`number`,Ch=e=>e===`family-name`,wh=e=>e===`number`||e===`weight`,Th=e=>e===`shadow`,Eh=Fm(()=>{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=()=>[Gm,`full`,`auto`,...w()],D=()=>[Km,`none`,`subgrid`,Q,Z],ee=()=>[`auto`,{span:[`full`,Km,Q,Z]},Km,Q,Z],O=()=>[Km,`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=()=>[Gm,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],P=()=>[Gm,`screen`,`full`,`dvw`,`lvw`,`svw`,`min`,`max`,`fit`,...w()],F=()=>[Gm,`screen`,`full`,`lh`,`dvh`,`lvh`,`svh`,`min`,`max`,`fit`,...w()],I=()=>[e,Q,Z],te=()=>[...b(),dh,oh,{position:[Q,Z]}],ne=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],re=()=>[`auto`,`cover`,`contain`,fh,th,{size:[Q,Z]}],ie=()=>[qm,lh,nh],L=()=>[``,`none`,`full`,l,Q,Z],R=()=>[``,X,lh,nh],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,qm,dh,oh],se=()=>[``,`none`,m,Q,Z],ce=()=>[`none`,X,Q,Z],le=()=>[`none`,X,Q,Z],B=()=>[X,Q,Z],ue=()=>[Gm,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[Jm],breakpoint:[Jm],color:[Ym],container:[Jm],"drop-shadow":[Jm],ease:[`in`,`out`,`in-out`],font:[eh],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[Jm],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[Jm],shadow:[Jm],spacing:[`px`,X],text:[Jm],"text-shadow":[Jm],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,Gm,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:[Km,`auto`,Q,Z]}],basis:[{basis:[Gm,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[X,Gm,`auto`,`initial`,`none`,Z]}],grow:[{grow:[``,X,Q,Z]}],shrink:[{shrink:[``,X,Q,Z]}],order:[{order:[Km,`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,lh,nh]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,hh,ih]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,qm,Z]}],"font-family":[{font:[uh,ah,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,rh]}],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,nh]}],"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`]},Km,Q,Z],radial:[``,Q,Z],conic:[Km,Q,Z]},ph,sh]}],"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,lh,nh]}],"outline-color":[{outline:I()}],shadow:[{shadow:[``,`none`,u,mh,ch]}],"shadow-color":[{shadow:I()}],"inset-shadow":[{"inset-shadow":[`none`,d,mh,ch]}],"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,nh]}],"ring-offset-color":[{"ring-offset":I()}],"inset-ring-w":[{"inset-ring":R()}],"inset-ring-color":[{"inset-ring":I()}],"text-shadow":[{"text-shadow":[`none`,f,mh,ch]}],"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:se()}],brightness:[{brightness:[X,Q,Z]}],contrast:[{contrast:[X,Q,Z]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,mh,ch]}],"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":se()}],"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:ce()}],"rotate-x":[{"rotate-x":ce()}],"rotate-y":[{"rotate-y":ce()}],"rotate-z":[{"rotate-z":ce()}],scale:[{scale:le()}],"scale-x":[{"scale-x":le()}],"scale-y":[{"scale-y":le()}],"scale-z":[{"scale-z":le()}],"scale-3d":[`scale-3d`],skew:[{skew:B()}],"skew-x":[{"skew-x":B()}],"skew-y":[{"skew-y":B()}],transform:[{transform:[Q,Z,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:ue()}],"translate-x":[{"translate-x":ue()}],"translate-y":[{"translate-y":ue()}],"translate-z":[{"translate-z":ue()}],"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,lh,nh,rh]}],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 Eh(rs(e))}var Dh=os(`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 Oh({className:e,variant:t=`default`,size:n=`default`,asChild:r=!1,...i}){return(0,q.jsx)(r?ds:`button`,{"data-slot":`button`,"data-variant":t,"data-size":n,className:$(Dh({variant:t,size:n,className:e})),...i})}function kh({className:e,type:t,...n}){return(0,q.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 Ah({className:e,orientation:t=`horizontal`,decorative:n=!0,...r}){return(0,q.jsx)(vp,{"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 jh({...e}){return(0,q.jsx)(bu,{"data-slot":`sheet`,...e})}function Mh({...e}){return(0,q.jsx)(Su,{"data-slot":`sheet-portal`,...e})}function Nh({className:e,...t}){return(0,q.jsx)(Cu,{"data-slot":`sheet-overlay`,className:$(`data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/80 duration-100 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50`,e),...t})}function Ph({className:e,children:t,side:n=`right`,showCloseButton:r=!0,...i}){return(0,q.jsxs)(Mh,{children:[(0,q.jsx)(Nh,{}),(0,q.jsxs)(wu,{"data-slot":`sheet-content`,"data-side":n,className:$(`bg-background data-open:animate-in data-closed:animate-out data-[side=right]:data-closed:slide-out-to-right-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=top]:data-closed:slide-out-to-top-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:fade-out-0 data-open:fade-in-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=bottom]:data-open:slide-in-from-bottom-10 fixed z-50 flex flex-col bg-clip-padding text-xs/relaxed shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm`,e),...i,children:[t,r&&(0,q.jsx)(Du,{"data-slot":`sheet-close`,asChild:!0,children:(0,q.jsxs)(Oh,{variant:`ghost`,className:`absolute top-4 right-4`,size:`icon-sm`,children:[(0,q.jsx)(es,{}),(0,q.jsx)(`span`,{className:`sr-only`,children:`Close`})]})})]})]})}function Fh({className:e,...t}){return(0,q.jsx)(`div`,{"data-slot":`sheet-header`,className:$(`gap-1.5 p-6 flex flex-col`,e),...t})}function Ih({className:e,...t}){return(0,q.jsx)(Tu,{"data-slot":`sheet-title`,className:$(`text-foreground text-sm font-medium`,e),...t})}function Lh({className:e,...t}){return(0,q.jsx)(Eu,{"data-slot":`sheet-description`,className:$(`text-muted-foreground text-xs/relaxed`,e),...t})}function Rh({className:e,...t}){return(0,q.jsx)(`div`,{"data-slot":`skeleton`,className:$(`bg-muted rounded-md animate-pulse`,e),...t})}function zh({delayDuration:e=0,...t}){return(0,q.jsx)($p,{"data-slot":`tooltip-provider`,delayDuration:e,...t})}function Bh({...e}){return(0,q.jsx)(zh,{children:(0,q.jsx)(em,{"data-slot":`tooltip`,...e})})}function Vh({...e}){return(0,q.jsx)(tm,{"data-slot":`tooltip-trigger`,...e})}function Hh({className:e,sideOffset:t=0,children:n,...r}){return(0,q.jsx)(nm,{children:(0,q.jsxs)(rm,{"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,q.jsx)(im,{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 Uh=768;function Wh(){let[e,t]=V.useState(void 0);return V.useEffect(()=>{let e=window.matchMedia(`(max-width: ${Uh-1}px)`),n=()=>{t(window.innerWidth<Uh)};return e.addEventListener(`change`,n),t(window.innerWidth<Uh),()=>e.removeEventListener(`change`,n)},[]),!!e}var Gh=`sidebar_state`,Kh=3600*24*7,qh=`16rem`,Jh=`18rem`,Yh=`3rem`,Xh=`b`,Zh=V.createContext(null);function Qh(){let e=V.useContext(Zh);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function $h({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:i,children:a,...o}){let s=Wh(),[c,l]=V.useState(!1),[u,d]=V.useState(e),f=t??u,p=V.useCallback(e=>{let t=typeof e==`function`?e(f):e;n?n(t):d(t),document.cookie=`${Gh}=${t}; path=/; max-age=${Kh}`},[n,f]),m=V.useCallback(()=>s?l(e=>!e):p(e=>!e),[s,p,l]);V.useEffect(()=>{let e=e=>{e.key===Xh&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),m())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[m]);let h=f?`expanded`:`collapsed`,g=V.useMemo(()=>({state:h,open:f,setOpen:p,isMobile:s,openMobile:c,setOpenMobile:l,toggleSidebar:m}),[h,f,p,s,c,l,m]);return(0,q.jsx)(Zh.Provider,{value:g,children:(0,q.jsx)(`div`,{"data-slot":`sidebar-wrapper`,style:{"--sidebar-width":qh,"--sidebar-width-icon":Yh,...i},className:$(`group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full`,r),...o,children:a})})}function eg({side:e=`left`,variant:t=`sidebar`,collapsible:n=`offExamples`,className:r,children:i,...a}){let{isMobile:o,state:s,openMobile:c,setOpenMobile:l}=Qh();return n===`none`?(0,q.jsx)(`div`,{"data-slot":`sidebar`,className:$(`bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col`,r),...a,children:i}):o?(0,q.jsx)(jh,{open:c,onOpenChange:l,...a,children:(0,q.jsxs)(Ph,{"data-sidebar":`sidebar`,"data-slot":`sidebar`,"data-mobile":`true`,className:`bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden`,style:{"--sidebar-width":Jh},side:e,children:[(0,q.jsxs)(Fh,{className:`sr-only`,children:[(0,q.jsx)(Ih,{children:`Sidebar`}),(0,q.jsx)(Lh,{children:`Displays the mobile sidebar.`})]}),(0,q.jsx)(`div`,{className:`flex h-full w-full flex-col`,children:i})]})}):(0,q.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,q.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,q.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,q.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 tg({className:e,onClick:t,...n}){let{toggleSidebar:r}=Qh();return(0,q.jsxs)(Oh,{"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,variant:`ghost`,size:`icon-sm`,className:$(e),onClick:e=>{t?.(e),r()},...n,children:[(0,q.jsx)(Qo,{}),(0,q.jsx)(`span`,{className:`sr-only`,children:`Toggle Sidebar`})]})}function ng({className:e,...t}){return(0,q.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 rg({className:e,...t}){return(0,q.jsx)(`div`,{"data-slot":`sidebar-header`,"data-sidebar":`header`,className:$(`gap-2 p-2 flex flex-col`,e),...t})}function ig({className:e,...t}){return(0,q.jsx)(`div`,{"data-slot":`sidebar-footer`,"data-sidebar":`footer`,className:$(`gap-2 p-2 flex flex-col`,e),...t})}function ag({className:e,...t}){return(0,q.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 og({className:e,...t}){return(0,q.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 sg({className:e,asChild:t=!1,...n}){return(0,q.jsx)(t?ds:`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 cg({className:e,...t}){return(0,q.jsx)(`div`,{"data-slot":`sidebar-group-content`,"data-sidebar":`group-content`,className:$(`text-xs w-full`,e),...t})}function lg({className:e,...t}){return(0,q.jsx)(`ul`,{"data-slot":`sidebar-menu`,"data-sidebar":`menu`,className:$(`gap-px flex w-full min-w-0 flex-col`,e),...t})}function ug({className:e,...t}){return(0,q.jsx)(`li`,{"data-slot":`sidebar-menu-item`,"data-sidebar":`menu-item`,className:$(`group/menu-item relative`,e),...t})}var dg=os(`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 fg({asChild:e=!1,isActive:t=!1,variant:n=`default`,size:r=`default`,tooltip:i,className:a,...o}){let s=e?ds:`button`,{isMobile:c,state:l}=Qh(),u=(0,q.jsx)(s,{"data-slot":`sidebar-menu-button`,"data-sidebar":`menu-button`,"data-size":r,"data-active":t,className:$(dg({variant:n,size:r}),a),...o});return i?(typeof i==`string`&&(i={children:i}),(0,q.jsxs)(Bh,{children:[(0,q.jsx)(Vh,{asChild:!0,children:u}),(0,q.jsx)(Hh,{side:`right`,align:`center`,hidden:l!==`collapsed`||c,...i})]})):u}function pg(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 mg=e=>{switch(e){case`success`:return _g;case`info`:return yg;case`warning`:return vg;case`error`:return bg;default:return null}},hg=Array(12).fill(0),gg=({visible:e,className:t})=>V.createElement(`div`,{className:[`sonner-loading-wrapper`,t].filter(Boolean).join(` `),"data-visible":e},V.createElement(`div`,{className:`sonner-spinner`},hg.map((e,t)=>V.createElement(`div`,{className:`sonner-loading-bar`,key:`spinner-bar-${t}`})))),_g=V.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},V.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`})),vg=V.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 24 24`,fill:`currentColor`,height:`20`,width:`20`},V.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`})),yg=V.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},V.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`})),bg=V.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`},V.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`})),xg=V.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`},V.createElement(`line`,{x1:`18`,y1:`6`,x2:`6`,y2:`18`}),V.createElement(`line`,{x1:`6`,y1:`6`,x2:`18`,y2:`18`})),Sg=()=>{let[e,t]=V.useState(document.hidden);return V.useEffect(()=>{let e=()=>{t(document.hidden)};return document.addEventListener(`visibilitychange`,e),()=>window.removeEventListener(`visibilitychange`,e)},[]),e},Cg=1,wg=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:Cg++,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],V.isValidElement(e))i=!1,this.create({id:n,type:`default`,message:e});else if(Eg(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`&&!V.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`&&!V.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`&&!V.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`&&!V.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||Cg++;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}},Tg=(e,t)=>{let n=t?.id||Cg++;return wg.addToast({title:e,...t,id:n}),n},Eg=e=>e&&typeof e==`object`&&`ok`in e&&typeof e.ok==`boolean`&&`status`in e&&typeof e.status==`number`,Dg=Object.assign(Tg,{success:wg.success,info:wg.info,warning:wg.warning,error:wg.error,custom:wg.custom,message:wg.message,promise:wg.promise,dismiss:wg.dismiss,loading:wg.loading},{getHistory:()=>wg.toasts,getToasts:()=>wg.getActiveToasts()});pg(`[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 Og(e){return e.label!==void 0}var kg=3,Ag=`24px`,jg=`16px`,Mg=4e3,Ng=356,Pg=14,Fg=45,Ig=200;function Lg(...e){return e.filter(Boolean).join(` `)}function Rg(e){let[t,n]=e.split(`-`),r=[];return t&&r.push(t),n&&r.push(n),r}var zg=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]=V.useState(null),[O,k]=V.useState(null),[A,j]=V.useState(!1),[M,N]=V.useState(!1),[P,F]=V.useState(!1),[I,te]=V.useState(!1),[ne,re]=V.useState(!1),[ie,L]=V.useState(0),[R,ae]=V.useState(0),oe=V.useRef(n.duration||y||Mg),z=V.useRef(null),se=V.useRef(null),ce=c===0,le=c+1<=o,B=n.type,ue=n.dismissible!==!1,de=n.className||``,fe=n.descriptionClassName||``,pe=V.useMemo(()=>s.findIndex(e=>e.toastId===n.id)||0,[s,n.id]),me=V.useMemo(()=>n.closeButton??p,[n.closeButton,p]),he=V.useMemo(()=>n.duration||y||Mg,[n.duration,y]),ge=V.useRef(0),_e=V.useRef(0),ve=V.useRef(0),ye=V.useRef(null),[be,xe]=b.split(`-`),Se=V.useMemo(()=>s.reduce((e,t,n)=>n>=pe?e:e+t.height,0),[s,pe]),Ce=Sg(),we=n.invert||t,Te=B===`loading`;_e.current=V.useMemo(()=>pe*x+Se,[pe,Se]),V.useEffect(()=>{oe.current=he},[he]),V.useEffect(()=>{j(!0)},[]),V.useEffect(()=>{let e=se.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]),V.useLayoutEffect(()=>{if(!A)return;let e=se.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 Ee=V.useCallback(()=>{N(!0),L(_e.current),a(e=>e.filter(e=>e.toastId!==n.id)),setTimeout(()=>{d(n)},Ig)},[n,d,a,_e]);V.useEffect(()=>{if(n.promise&&B===`loading`||n.duration===1/0||n.type===`loading`)return;let e;return u||i||Ce?(()=>{if(ve.current<ge.current){let e=new Date().getTime()-ge.current;oe.current-=e}ve.current=new Date().getTime()})():oe.current!==1/0&&(ge.current=new Date().getTime(),e=setTimeout(()=>{n.onAutoClose==null||n.onAutoClose.call(n,n),Ee()},oe.current)),()=>clearTimeout(e)},[u,i,n,B,Ce,Ee]),V.useEffect(()=>{n.delete&&(Ee(),n.onDismiss==null||n.onDismiss.call(n,n))},[Ee,n.delete]);function De(){return w?.loading?V.createElement(`div`,{className:Lg(C?.loader,n?.classNames?.loader,`sonner-loader`),"data-visible":B===`loading`},w.loading):V.createElement(gg,{className:Lg(C?.loader,n?.classNames?.loader),visible:B===`loading`})}let Oe=n.icon||w?.[B]||mg(B);return V.createElement(`li`,{tabIndex:0,ref:se,className:Lg(_,de,C?.toast,n?.classNames?.toast,C?.default,C?.[B],n?.classNames?.[B]),"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":le,"data-y-position":be,"data-x-position":xe,"data-index":c,"data-front":ce,"data-swiping":P,"data-dismissible":ue,"data-type":B,"data-invert":we,"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:_e.current}px`,"--initial-height":S?`auto`:`${R}px`,...m,...n.style},onDragEnd:()=>{F(!1),ee(null),ye.current=null},onPointerDown:e=>{e.button!==2&&(Te||!ue||(z.current=new Date,L(_e.current),e.target.setPointerCapture(e.pointerId),e.target.tagName!==`BUTTON`&&(F(!0),ye.current={x:e.clientX,y:e.clientY})))},onPointerUp:()=>{if(I||!ue)return;ye.current=null;let e=Number(se.current?.style.getPropertyValue(`--swipe-amount-x`).replace(`px`,``)||0),t=Number(se.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)>=Fg||a>.11){L(_e.current),n.onDismiss==null||n.onDismiss.call(n,n),k(D===`x`?e>0?`right`:`left`:t>0?`down`:`up`),Ee(),te(!0);return}else{var o,s;(o=se.current)==null||o.style.setProperty(`--swipe-amount-x`,`0px`),(s=se.current)==null||s.style.setProperty(`--swipe-amount-y`,`0px`)}re(!1),F(!1),ee(null)},onPointerMove:t=>{var n,r;if(!ye.current||!ue||window.getSelection()?.toString().length>0)return;let i=t.clientY-ye.current.y,a=t.clientX-ye.current.x,o=e.swipeDirections??Rg(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=se.current)==null||n.style.setProperty(`--swipe-amount-x`,`${s.x}px`),(r=se.current)==null||r.style.setProperty(`--swipe-amount-y`,`${s.y}px`)}},me&&!n.jsx&&B!==`loading`?V.createElement(`button`,{"aria-label":E,"data-disabled":Te,"data-close-button":!0,onClick:Te||!ue?()=>{}:()=>{Ee(),n.onDismiss==null||n.onDismiss.call(n,n)},className:Lg(C?.closeButton,n?.classNames?.closeButton)},w?.close??xg):null,(B||n.icon||n.promise)&&n.icon!==null&&(w?.[B]!==null||n.icon)?V.createElement(`div`,{"data-icon":``,className:Lg(C?.icon,n?.classNames?.icon)},n.promise||n.type===`loading`&&!n.icon?n.icon||De():null,n.type===`loading`?null:Oe):null,V.createElement(`div`,{"data-content":``,className:Lg(C?.content,n?.classNames?.content)},V.createElement(`div`,{"data-title":``,className:Lg(C?.title,n?.classNames?.title)},n.jsx?n.jsx:typeof n.title==`function`?n.title():n.title),n.description?V.createElement(`div`,{"data-description":``,className:Lg(v,fe,C?.description,n?.classNames?.description)},typeof n.description==`function`?n.description():n.description):null),V.isValidElement(n.cancel)?n.cancel:n.cancel&&Og(n.cancel)?V.createElement(`button`,{"data-button":!0,"data-cancel":!0,style:n.cancelButtonStyle||h,onClick:e=>{Og(n.cancel)&&ue&&(n.cancel.onClick==null||n.cancel.onClick.call(n.cancel,e),Ee())},className:Lg(C?.cancelButton,n?.classNames?.cancelButton)},n.cancel.label):null,V.isValidElement(n.action)?n.action:n.action&&Og(n.action)?V.createElement(`button`,{"data-button":!0,"data-action":!0,style:n.actionButtonStyle||g,onClick:e=>{Og(n.action)&&(n.action.onClick==null||n.action.onClick.call(n.action,e),!e.defaultPrevented&&Ee())},className:Lg(C?.actionButton,n?.classNames?.actionButton)},n.action.label):null)};function Bg(){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 Vg(e,t){let n={};return[e,t].forEach((e,t)=>{let r=t===1,i=r?`--mobile-offset`:`--offset`,a=r?jg:Ag;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 Hg=V.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=kg,toastOptions:g,dir:_=Bg(),gap:v=Pg,icons:y,containerAriaLabel:b=`Notifications`}=e,[x,S]=V.useState([]),C=V.useMemo(()=>n?x.filter(e=>e.toasterId===n):x.filter(e=>!e.toasterId),[x,n]),w=V.useMemo(()=>Array.from(new Set([i].concat(C.filter(e=>e.position).map(e=>e.position)))),[C,i]),[E,D]=V.useState([]),[ee,O]=V.useState(!1),[k,A]=V.useState(!1),[j,M]=V.useState(d===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`:d),N=V.useRef(null),P=a.join(`+`).replace(/Key/g,``).replace(/Digit/g,``),F=V.useRef(null),I=V.useRef(!1),te=V.useCallback(e=>{S(t=>(t.find(t=>t.id===e.id)?.delete||wg.dismiss(e.id),t.filter(({id:t})=>t!==e.id)))},[]);return V.useEffect(()=>wg.subscribe(e=>{if(e.dismiss){requestAnimationFrame(()=>{S(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t))});return}setTimeout(()=>{ts.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]),V.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]),V.useEffect(()=>{x.length<=1&&O(!1)},[x]),V.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]),V.useEffect(()=>{if(N.current)return()=>{F.current&&(F.current.focus({preventScroll:!0}),F.current=null,I.current=!1)}},[N.current]),V.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?V.createElement(`ol`,{key:t,dir:_===`auto`?Bg():_,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":`${Ng}px`,"--gap":`${v}px`,...m,...Vg(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)=>V.createElement(zg,{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{zs as $,ha as $t,up as A,be as An,oo as At,Su as B,to as Bt,Lh as C,Re as Cn,wo as Ct,kh as D,Oe as Dn,vo as Dt,Ah as E,Ne as En,_o as Et,Ou as F,f as Fn,ro as Ft,Hl as G,Ja as Gt,Tu as H,xo as Ht,Du as I,u as In,Za as It,bc as J,Ea as Jt,zl as K,Ka as Kt,wu as L,o as Ln,so as Lt,dp as M,pe as Mn,Xa as Mt,lp as N,fe as Nn,$a as Nt,Oh as O,ke as On,bo as Ot,qf as P,m as Pn,io as Pt,Bs as Q,ga as Qt,Eu as R,c as Rn,go as Rt,Ph as S,Ee as Sn,Do as St,Ih as T,ge as Tn,So as Tt,xu as U,yo as Ut,bu as V,uo as Vt,hu as W,eo as Wt,ac as X,ba as Xt,vc as Y,ya as Yt,Js as Z,_a as Zt,Hh as _,He as _n,Ro as _t,ig as a,ra as an,J as at,Rh as b,De as bn,Fo as bt,sg as c,ea as cn,ms as ct,lg as d,Ei as dn,es as dt,pa as en,ks as et,fg as f,qe as fn,$o as ft,Bh as g,Ue as gn,Vo as gt,tg as h,Ge as hn,Ho as ht,ag as i,la as in,ys as it,fp as j,xe as jn,ao as jt,$ as k,me as kn,Qa as kt,rg as l,Qi as ln,ls as lt,$h as m,Ke as mn,Xo as mt,Dg as n,da as nn,Es as nt,og as o,Zi as on,ds as ot,ug as p,Je as pn,Zo as pt,Al as q,Ga as qt,eg as r,ua as rn,ws as rt,cg as s,ta as sn,us as st,Hg as t,fa as tn,Ds as tt,ng as u,$i as un,os as ut,zh as v,Ve as vn,zo as vt,Fh as w,Ie as wn,Co as wt,jh as x,Le as xn,Oo as xt,Vh as y,Me as yn,Po as yt,Cu as z,no as zt};