@aotter/mantle-admin-ui 0.1.0-alpha.6 → 0.1.0-alpha.8
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.
|
@@ -0,0 +1,54 @@
|
|
|
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),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(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},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var u=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},T=Object.prototype.hasOwnProperty;function E(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 E(e.type,t,e.props)}function D(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function O(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var k=/\/+/g;function A(e,t){return typeof e==`object`&&e&&e.key!=null?O(``+e.key):t.toString(36)}function j(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 M(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,M(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+A(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(k,`$&/`)+`/`),M(o,r,i,``,function(e){return e})):o!=null&&(D(o)&&(o=ee(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(k,`$&/`)+`/`)+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+A(a,u),c+=M(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+A(a,u++),c+=M(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return M(j(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 N(e,t,n){if(e==null)return e;var r=[],i=0;return M(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function te(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 P=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)},F={map:N,forEach:function(e,t,n){N(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return N(e,function(){t++}),t},toArray:function(e){return N(e,function(e){return e})||[]},only:function(e){if(!D(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=F,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)!T.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 E(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)T.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 E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=D,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:te}},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,P)}catch(e){P(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.8`})),d=o(((e,t)=>{t.exports=u()})),f=o((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,D());else{var t=n(l);t!==null&&A(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function ee(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&A(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}}}finally{i?D():S=!1}}}var D;if(typeof y==`function`)D=function(){y(ee)};else if(typeof MessageChannel<`u`){var O=new MessageChannel,k=O.port2;O.port1.onmessage=ee,D=function(){k.postMessage(null)}}else D=function(){_(ee,0)};function A(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,A(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,D()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),p=o(((e,t)=>{t.exports=f()})),m=o((e=>{var t=d();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.8`})),h=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=m()})),g=o((e=>{var t=p(),n=d(),r=h();function i(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 a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function u(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function f(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=f(e),t!==null)return t;e=e.sibling}return null}var m=Object.assign,g=Symbol.for(`react.element`),_=Symbol.for(`react.transitional.element`),v=Symbol.for(`react.portal`),y=Symbol.for(`react.fragment`),b=Symbol.for(`react.strict_mode`),x=Symbol.for(`react.profiler`),S=Symbol.for(`react.consumer`),C=Symbol.for(`react.context`),w=Symbol.for(`react.forward_ref`),T=Symbol.for(`react.suspense`),E=Symbol.for(`react.suspense_list`),ee=Symbol.for(`react.memo`),D=Symbol.for(`react.lazy`),O=Symbol.for(`react.activity`),k=Symbol.for(`react.memo_cache_sentinel`),A=Symbol.iterator;function j(e){return typeof e!=`object`||!e?null:(e=A&&e[A]||e[`@@iterator`],typeof e==`function`?e:null)}var M=Symbol.for(`react.client.reference`);function N(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===M?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case y:return`Fragment`;case x:return`Profiler`;case b:return`StrictMode`;case T:return`Suspense`;case E:return`SuspenseList`;case O:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case v:return`Portal`;case C:return e.displayName||`Context`;case S:return(e._context.displayName||`Context`)+`.Consumer`;case w:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case ee:return t=e.displayName||null,t===null?N(e.type)||`Memo`:t;case D:t=e._payload,e=e._init;try{return N(e(t))}catch{}}return null}var te=Array.isArray,P=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ne={pending:!1,data:null,method:null,action:null},re=[],ie=-1;function ae(e){return{current:e}}function I(e){0>ie||(e.current=re[ie],re[ie]=null,ie--)}function L(e,t){ie++,re[ie]=e.current,e.current=t}var oe=ae(null),se=ae(null),ce=ae(null),le=ae(null);function ue(e,t){switch(L(ce,t),L(se,e),L(oe,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Jd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Jd(t),e=Yd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}I(oe),L(oe,e)}function de(){I(oe),I(se),I(ce)}function fe(e){e.memoizedState!==null&&L(le,e);var t=oe.current,n=Yd(t,e.type);t!==n&&(L(se,e),L(oe,n))}function pe(e){se.current===e&&(I(oe),I(se)),le.current===e&&(I(le),ap._currentValue=ne)}var me,he;function ge(e){if(me===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);me=t&&t[1]||``,he=-1<e.stack.indexOf(`
|
|
2
|
+
at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
|
|
3
|
+
`+me+e+he}var _e=!1;function ve(e,t){if(!e||_e)return``;_e=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
|
|
4
|
+
`),l=s.split(`
|
|
5
|
+
`);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=`
|
|
6
|
+
`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{_e=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ge(n):``}function ye(e,t){switch(e.tag){case 26:case 27:case 5:return ge(e.type);case 16:return ge(`Lazy`);case 13:return e.child!==t&&t!==null?ge(`Suspense Fallback`):ge(`Suspense`);case 19:return ge(`SuspenseList`);case 0:case 15:return ve(e.type,!1);case 11:return ve(e.type.render,!1);case 1:return ve(e.type,!0);case 31:return ge(`Activity`);default:return``}}function be(e){try{var t=``,n=null;do t+=ye(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
|
|
7
|
+
Error generating stack: `+e.message+`
|
|
8
|
+
`+e.stack}}var xe=Object.prototype.hasOwnProperty,Se=t.unstable_scheduleCallback,Ce=t.unstable_cancelCallback,we=t.unstable_shouldYield,Te=t.unstable_requestPaint,Ee=t.unstable_now,De=t.unstable_getCurrentPriorityLevel,Oe=t.unstable_ImmediatePriority,ke=t.unstable_UserBlockingPriority,Ae=t.unstable_NormalPriority,je=t.unstable_LowPriority,Me=t.unstable_IdlePriority,Ne=t.log,Pe=t.unstable_setDisableYieldValue,Fe=null,Ie=null;function Le(e){if(typeof Ne==`function`&&Pe(e),Ie&&typeof Ie.setStrictMode==`function`)try{Ie.setStrictMode(Fe,e)}catch{}}var Re=Math.clz32?Math.clz32:Ve,ze=Math.log,Be=Math.LN2;function Ve(e){return e>>>=0,e===0?32:31-(ze(e)/Be|0)|0}var He=256,Ue=262144,We=4194304;function R(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function z(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=R(n))):i=R(o):i=R(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=R(n))):i=R(o)):i=R(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Ge(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ke(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function qe(){var e=We;return We<<=1,!(We&62914560)&&(We=4194304),e}function Je(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ye(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Xe(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Re(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&Ze(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Ze(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Re(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Qe(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Re(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function $e(e,t){var n=t&-t;return n=n&42?1:et(n),(n&(e.suspendedLanes|t))===0?n:0}function et(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function tt(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function nt(){var e=F.p;return e===0?(e=window.event,e===void 0?32:xp(e.type)):e}function rt(e,t){var n=F.p;try{return F.p=e,t()}finally{F.p=n}}var it=Math.random().toString(36).slice(2),at=`__reactFiber$`+it,ot=`__reactProps$`+it,st=`__reactContainer$`+it,ct=`__reactEvents$`+it,lt=`__reactListeners$`+it,ut=`__reactHandles$`+it,dt=`__reactResources$`+it,ft=`__reactMarker$`+it;function pt(e){delete e[at],delete e[ot],delete e[ct],delete e[lt],delete e[ut]}function mt(e){var t=e[at];if(t)return t;for(var n=e.parentNode;n;){if(t=n[st]||n[at]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=vf(e);e!==null;){if(n=e[at])return n;e=vf(e)}return t}e=n,n=e.parentNode}return null}function ht(e){if(e=e[at]||e[st]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function gt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function _t(e){var t=e[dt];return t||=e[dt]={hoistableStyles:new Map,hoistableScripts:new Map},t}function B(e){e[ft]=!0}var vt=new Set,yt={};function bt(e,t){xt(e,t),xt(e+`Capture`,t)}function xt(e,t){for(yt[e]=t,e=0;e<t.length;e++)vt.add(t[e])}var St=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),Ct={},wt={};function Tt(e){return xe.call(wt,e)?!0:xe.call(Ct,e)?!1:St.test(e)?wt[e]=!0:(Ct[e]=!0,!1)}function Et(e,t,n){if(Tt(t)){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}}function Dt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Ot(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function kt(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function At(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function jt(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Mt(e){if(!e._valueTracker){var t=At(e)?`checked`:`value`;e._valueTracker=jt(e,t,``+e[t])}}function Nt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=At(e)?e.checked?`true`:`false`:e.value),e=r,e!==n&&(t.setValue(e),!0)}function Pt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Ft=/[\n"\\]/g;function It(e){return e.replace(Ft,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Lt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+kt(t)):e.value!==``+kt(t)&&(e.value=``+kt(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):zt(e,o,kt(n)):zt(e,o,kt(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+kt(s):e.removeAttribute(`name`)}function Rt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){Mt(e);return}n=n==null?``:``+kt(n),t=t==null?n:``+kt(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),Mt(e)}function zt(e,t,n){t===`number`&&Pt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Bt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+kt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Vt(e,t,n){if(t!=null&&(t=``+kt(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+kt(n)}function Ht(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(te(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}n=kt(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),Mt(e)}function Ut(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Wt=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Gt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Wt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Kt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&Gt(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&Gt(e,o,t[o])}function qt(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var Jt=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),Yt=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Xt(e){return Yt.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function Zt(){}var Qt=null;function $t(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var en=null,tn=null;function nn(e){var t=ht(e);if(t&&(e=t.stateNode)){var n=e[ot]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Lt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+It(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[ot]||null;if(!a)throw Error(i(90));Lt(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Nt(r)}break a;case`textarea`:Vt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Bt(e,!!n.multiple,t,!1)}}}var rn=!1;function an(e,t,n){if(rn)return e(t,n);rn=!0;try{return e(t)}finally{if(rn=!1,(en!==null||tn!==null)&&(Tu(),en&&(t=en,e=tn,tn=en=null,nn(t),e)))for(t=0;t<e.length;t++)nn(e[t])}}function on(e,t){var n=e.stateNode;if(n===null)return null;var r=n[ot]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=e!==`button`&&e!==`input`&&e!==`select`&&e!==`textarea`),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var sn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),cn=!1;if(sn)try{var ln={};Object.defineProperty(ln,"passive",{get:function(){cn=!0}}),window.addEventListener(`test`,ln,ln),window.removeEventListener(`test`,ln,ln)}catch{cn=!1}var un=null,dn=null,fn=null;function pn(){if(fn)return fn;var e,t=dn,n=t.length,r,i=`value`in un?un.value:un.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return fn=i.slice(e,1<r?1-r:void 0)}function mn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function hn(){return!0}function gn(){return!1}function _n(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?hn:gn,this.isPropagationStopped=gn,this}return m(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=hn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=hn)},persist:function(){},isPersistent:hn}),t}var vn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},yn=_n(vn),bn=m({},vn,{view:0,detail:0}),xn=_n(bn),Sn,Cn,wn,Tn=m({},bn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:In,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==wn&&(wn&&e.type===`mousemove`?(Sn=e.screenX-wn.screenX,Cn=e.screenY-wn.screenY):Cn=Sn=0,wn=e),Sn)},movementY:function(e){return`movementY`in e?e.movementY:Cn}}),En=_n(Tn),Dn=_n(m({},Tn,{dataTransfer:0})),On=_n(m({},bn,{relatedTarget:0})),kn=_n(m({},vn,{animationName:0,elapsedTime:0,pseudoElement:0})),An=_n(m({},vn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),jn=_n(m({},vn,{data:0})),Mn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Nn={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Pn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Fn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Pn[e])?!!t[e]:!1}function In(){return Fn}var Ln=_n(m({},bn,{key:function(e){if(e.key){var t=Mn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=mn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Nn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:In,charCode:function(e){return e.type===`keypress`?mn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?mn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Rn=_n(m({},Tn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),zn=_n(m({},bn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:In})),Bn=_n(m({},vn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Vn=_n(m({},Tn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Hn=_n(m({},vn,{newState:0,oldState:0})),Un=[9,13,27,32],Wn=sn&&`CompositionEvent`in window,Gn=null;sn&&`documentMode`in document&&(Gn=document.documentMode);var Kn=sn&&`TextEvent`in window&&!Gn,qn=sn&&(!Wn||Gn&&8<Gn&&11>=Gn),Jn=` `,Yn=!1;function Xn(e,t){switch(e){case`keyup`:return Un.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Zn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var V=!1;function Qn(e,t){switch(e){case`compositionend`:return Zn(t);case`keypress`:return t.which===32?(Yn=!0,Jn):null;case`textInput`:return e=t.data,e===Jn&&Yn?null:e;default:return null}}function $n(e,t){if(V)return e===`compositionend`||!Wn&&Xn(e,t)?(e=pn(),fn=dn=un=null,V=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return qn&&t.locale!==`ko`?null:t.data;default:return null}}var er={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function tr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!er[e.type]:t===`textarea`}function nr(e,t,n,r){en?tn?tn.push(r):tn=[r]:en=r,t=Md(t,`onChange`),0<t.length&&(n=new yn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var rr=null,ir=null;function ar(e){Td(e,0)}function or(e){if(Nt(gt(e)))return e}function sr(e,t){if(e===`change`)return t}var cr=!1;if(sn){var lr;if(sn){var ur=`oninput`in document;if(!ur){var dr=document.createElement(`div`);dr.setAttribute(`oninput`,`return;`),ur=typeof dr.oninput==`function`}lr=ur}else lr=!1;cr=lr&&(!document.documentMode||9<document.documentMode)}function fr(){rr&&(rr.detachEvent(`onpropertychange`,pr),ir=rr=null)}function pr(e){if(e.propertyName===`value`&&or(ir)){var t=[];nr(t,ir,e,$t(e)),an(ar,t)}}function mr(e,t,n){e===`focusin`?(fr(),rr=t,ir=n,rr.attachEvent(`onpropertychange`,pr)):e===`focusout`&&fr()}function hr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return or(ir)}function gr(e,t){if(e===`click`)return or(t)}function H(e,t){if(e===`input`||e===`change`)return or(t)}function _r(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var vr=typeof Object.is==`function`?Object.is:_r;function yr(e,t){if(vr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!xe.call(t,i)||!vr(e[i],t[i]))return!1}return!0}function br(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function xr(e,t){var n=br(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=br(n)}}function Sr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Sr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Cr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Pt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Pt(e.document)}return t}function wr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Tr=sn&&`documentMode`in document&&11>=document.documentMode,Er=null,Dr=null,Or=null,kr=!1;function Ar(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;kr||Er==null||Er!==Pt(r)||(r=Er,`selectionStart`in r&&wr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Or&&yr(Or,r)||(Or=r,r=Md(Dr,`onSelect`),0<r.length&&(t=new yn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Er)))}function jr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Mr={animationend:jr(`Animation`,`AnimationEnd`),animationiteration:jr(`Animation`,`AnimationIteration`),animationstart:jr(`Animation`,`AnimationStart`),transitionrun:jr(`Transition`,`TransitionRun`),transitionstart:jr(`Transition`,`TransitionStart`),transitioncancel:jr(`Transition`,`TransitionCancel`),transitionend:jr(`Transition`,`TransitionEnd`)},Nr={},Pr={};sn&&(Pr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Mr.animationend.animation,delete Mr.animationiteration.animation,delete Mr.animationstart.animation),`TransitionEvent`in window||delete Mr.transitionend.transition);function Fr(e){if(Nr[e])return Nr[e];if(!Mr[e])return e;var t=Mr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Pr)return Nr[e]=t[n];return e}var Ir=Fr(`animationend`),Lr=Fr(`animationiteration`),Rr=Fr(`animationstart`),zr=Fr(`transitionrun`),Br=Fr(`transitionstart`),Vr=Fr(`transitioncancel`),Hr=Fr(`transitionend`),U=new Map,Ur=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);Ur.push(`scrollEnd`);function Wr(e,t){U.set(e,t),bt(t,[e])}var Gr=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)},Kr=[],qr=0,Jr=0;function Yr(){for(var e=qr,t=Jr=qr=0;t<e;){var n=Kr[t];Kr[t++]=null;var r=Kr[t];Kr[t++]=null;var i=Kr[t];Kr[t++]=null;var a=Kr[t];if(Kr[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&$r(n,i,a)}}function Xr(e,t,n,r){Kr[qr++]=e,Kr[qr++]=t,Kr[qr++]=n,Kr[qr++]=r,Jr|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function Zr(e,t,n,r){return Xr(e,t,n,r),ei(e)}function Qr(e,t){return Xr(e,null,null,t),ei(e)}function $r(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Re(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function ei(e){if(50<gu)throw gu=0,_u=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var ti={};function ni(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ri(e,t,n,r){return new ni(e,t,n,r)}function ii(e){return e=e.prototype,!(!e||!e.isReactComponent)}function ai(e,t){var n=e.alternate;return n===null?(n=ri(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function oi(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function si(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)ii(e)&&(s=1);else if(typeof e==`string`)s=Xf(e,n,oe.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case O:return e=ri(31,n,t,a),e.elementType=O,e.lanes=o,e;case y:return ci(n.children,a,o,t);case b:s=8,a|=24;break;case x:return e=ri(12,n,t,a|2),e.elementType=x,e.lanes=o,e;case T:return e=ri(13,n,t,a),e.elementType=T,e.lanes=o,e;case E:return e=ri(19,n,t,a),e.elementType=E,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case C:s=10;break a;case S:s=9;break a;case w:s=11;break a;case ee:s=14;break a;case D:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=ri(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function ci(e,t,n,r){return e=ri(7,e,r,t),e.lanes=n,e}function li(e,t,n){return e=ri(6,e,null,t),e.lanes=n,e}function ui(e){var t=ri(18,null,null,0);return t.stateNode=e,t}function di(e,t,n){return t=ri(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var fi=new WeakMap;function pi(e,t){if(typeof e==`object`&&e){var n=fi.get(e);return n===void 0?(t={value:e,source:t,stack:be(t)},fi.set(e,t),t):n}return{value:e,source:t,stack:be(t)}}var mi=[],hi=0,gi=null,_i=0,vi=[],yi=0,bi=null,xi=1,Si=``;function Ci(e,t){mi[hi++]=_i,mi[hi++]=gi,gi=e,_i=t}function wi(e,t,n){vi[yi++]=xi,vi[yi++]=Si,vi[yi++]=bi,bi=e;var r=xi;e=Si;var i=32-Re(r)-1;r&=~(1<<i),n+=1;var a=32-Re(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,xi=1<<32-Re(t)+i|n<<i|r,Si=a+e}else xi=1<<a|n<<i|r,Si=e}function Ti(e){e.return!==null&&(Ci(e,1),wi(e,1,0))}function Ei(e){for(;e===gi;)gi=mi[--hi],mi[hi]=null,_i=mi[--hi],mi[hi]=null;for(;e===bi;)bi=vi[--yi],vi[yi]=null,Si=vi[--yi],vi[yi]=null,xi=vi[--yi],vi[yi]=null}function Di(e,t){vi[yi++]=xi,vi[yi++]=Si,vi[yi++]=bi,xi=t.id,Si=t.overflow,bi=e}var Oi=null,ki=null,Ai=!1,ji=null,Mi=!1,Ni=Error(i(519));function Pi(e){throw Bi(pi(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Ni}function Fi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[at]=e,t[ot]=r,n){case`dialog`:K(`cancel`,t),K(`close`,t);break;case`iframe`:case`object`:case`embed`:K(`load`,t);break;case`video`:case`audio`:for(n=0;n<Cd.length;n++)K(Cd[n],t);break;case`source`:K(`error`,t);break;case`img`:case`image`:case`link`:K(`error`,t),K(`load`,t);break;case`details`:K(`toggle`,t);break;case`input`:K(`invalid`,t),Rt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:K(`invalid`,t);break;case`textarea`:K(`invalid`,t),Ht(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||Rd(t.textContent,n)?(r.popover!=null&&(K(`beforetoggle`,t),K(`toggle`,t)),r.onScroll!=null&&K(`scroll`,t),r.onScrollEnd!=null&&K(`scrollend`,t),r.onClick!=null&&(t.onclick=Zt),t=!0):t=!1,t||Pi(e,!0)}function Ii(e){for(Oi=e.return;Oi;)switch(Oi.tag){case 5:case 31:case 13:Mi=!1;return;case 27:case 3:Mi=!0;return;default:Oi=Oi.return}}function Li(e){if(e!==Oi)return!1;if(!Ai)return Ii(e),Ai=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=n===`form`||n===`button`||Xd(e.type,e.memoizedProps)),n=!n),n&&ki&&Pi(e),Ii(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));ki=_f(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));ki=_f(e)}else t===27?(t=ki,af(e.type)?(e=gf,gf=null,ki=e):ki=t):ki=Oi?hf(e.stateNode.nextSibling):null;return!0}function Ri(){ki=Oi=null,Ai=!1}function zi(){var e=ji;return e!==null&&(nu===null?nu=e:nu.push.apply(nu,e),ji=null),e}function Bi(e){ji===null?ji=[e]:ji.push(e)}var Vi=ae(null),Hi=null,Ui=null;function Wi(e,t,n){L(Vi,t._currentValue),t._currentValue=n}function Gi(e){e._currentValue=Vi.current,I(Vi)}function Ki(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function qi(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Ki(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),Ki(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function Ji(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;vr(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===le.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[ap]:e.push(ap))}a=a.return}e!==null&&qi(t,e,n,r),t.flags|=262144}function Yi(e){for(e=e.firstContext;e!==null;){if(!vr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Xi(e){Hi=e,Ui=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Zi(e){return $i(Hi,e)}function Qi(e,t){return Hi===null&&Xi(e),$i(e,t)}function $i(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Ui===null){if(e===null)throw Error(i(308));Ui=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Ui=Ui.next=t;return n}var ea=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},ta=t.unstable_scheduleCallback,na=t.unstable_NormalPriority,ra={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ia(){return{controller:new ea,data:new Map,refCount:0}}function aa(e){e.refCount--,e.refCount===0&&ta(na,function(){e.controller.abort()})}var oa=null,sa=0,ca=0,la=null;function ua(e,t){if(oa===null){var n=oa=[];sa=0,ca=_d(),la={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return sa++,t.then(da,da),t}function da(){if(--sa===0&&oa!==null){la!==null&&(la.status=`fulfilled`);var e=oa;oa=null,ca=0,la=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function fa(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var pa=P.S;P.S=function(e,t){au=Ee(),typeof t==`object`&&t&&typeof t.then==`function`&&ua(e,t),pa!==null&&pa(e,t)};var ma=ae(null);function ha(){var e=ma.current;return e===null?Vl.pooledCache:e}function ga(e,t){t===null?L(ma,ma.current):L(ma,t.pool)}function _a(){var e=ha();return e===null?null:{parent:ra._currentValue,pool:e}}var va=Error(i(460)),ya=Error(i(474)),ba=Error(i(542)),xa={then:function(){}};function Sa(e){return e=e.status,e===`fulfilled`||e===`rejected`}function Ca(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Zt,Zt),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Da(e),e;default:if(typeof t.status==`string`)t.then(Zt,Zt);else{if(e=Vl,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Da(e),e}throw Ta=t,va}}function wa(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Ta=e,va):e}}var Ta=null;function Ea(){if(Ta===null)throw Error(i(459));var e=Ta;return Ta=null,e}function Da(e){if(e===va||e===ba)throw Error(i(483))}var Oa=null,ka=0;function Aa(e){var t=ka;return ka+=1,Oa===null&&(Oa=[]),Ca(Oa,e,t)}function ja(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Ma(e,t){throw t.$$typeof===g?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Na(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=ai(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=li(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===D&&wa(i)===t.type)?(t=a(t,n.props),ja(t,n),t.return=e,t):(t=si(n.type,n.key,n.props,null,e.mode,r),ja(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=di(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=ci(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=li(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=si(t.type,t.key,t.props,null,e.mode,n),ja(n,t),n.return=e,n;case v:return t=di(t,e.mode,n),t.return=e,t;case D:return t=wa(t),f(e,t,n)}if(te(t)||j(t))return t=ci(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Aa(t),n);if(t.$$typeof===C)return f(e,Qi(e,t),n);Ma(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case _:return n.key===i?l(e,t,n,r):null;case v:return n.key===i?u(e,t,n,r):null;case D:return n=wa(n),p(e,t,n,r)}if(te(n)||j(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Aa(n),r);if(n.$$typeof===C)return p(e,t,Qi(e,n),r);Ma(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case _:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case v:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case D:return r=wa(r),m(e,t,n,r,i)}if(te(r)||j(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,Aa(r),i);if(r.$$typeof===C)return m(e,t,n,Qi(t,r),i);Ma(t,r)}return null}function h(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),Ai&&Ci(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return Ai&&Ci(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),Ai&&Ci(i,h),l}function g(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),Ai&&Ci(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return Ai&&Ci(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),Ai&&Ci(a,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===y&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case _:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===y){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===D&&wa(l)===r.type){n(e,r.sibling),c=a(r,o.props),ja(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===y?(c=ci(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=si(o.type,o.key,o.props,null,e.mode,c),ja(c,o),c.return=e,e=c)}return s(e);case v:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=di(o,e.mode,c),c.return=e,e=c}return s(e);case D:return o=wa(o),b(e,r,o,c)}if(te(o))return h(e,r,o,c);if(j(o)){if(l=j(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),g(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,Aa(o),c);if(o.$$typeof===C)return b(e,r,Qi(e,o),c);Ma(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=li(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{ka=0;var i=b(e,t,n,r);return Oa=null,i}catch(t){if(t===va||t===ba)throw t;var a=ri(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Pa=Na(!0),Fa=Na(!1),Ia=!1;function La(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ra(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function za(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ba(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Bl&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ei(e),$r(e,null,n),t}return Xr(e,r,t,n),ei(e)}function Va(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Qe(e,n)}}function Ha(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ua=!1;function Wa(){if(Ua){var e=la;if(e!==null)throw e}}function Ga(e,t,n,r){Ua=!1;var i=e.updateQueue;Ia=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(G&f)===f:(r&f)===f){f!==0&&f===ca&&(Ua=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=m({},d,f);break a;case 2:Ia=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Xl|=o,e.lanes=o,e.memoizedState=d}}function Ka(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function qa(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Ka(n[e],t)}var Ja=ae(null),Ya=ae(0);function Xa(e,t){e=Jl,L(Ya,e),L(Ja,t),Jl=e|t.baseLanes}function Za(){L(Ya,Jl),L(Ja,Ja.current)}function Qa(){Jl=Ya.current,I(Ja),I(Ya)}var $a=ae(null),eo=null;function to(e){var t=e.alternate;L(oo,oo.current&1),L($a,e),eo===null&&(t===null||Ja.current!==null||t.memoizedState!==null)&&(eo=e)}function no(e){L(oo,oo.current),L($a,e),eo===null&&(eo=e)}function ro(e){e.tag===22?(L(oo,oo.current),L($a,e),eo===null&&(eo=e)):io(e)}function io(){L(oo,oo.current),L($a,$a.current)}function ao(e){I($a),eo===e&&(eo=null),I(oo)}var oo=ae(0);function so(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||ff(n)||pf(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var co=0,W=null,lo=null,uo=null,fo=!1,po=!1,mo=!1,ho=0,go=0,_o=null,vo=0;function yo(){throw Error(i(321))}function bo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!vr(e[n],t[n]))return!1;return!0}function xo(e,t,n,r,i,a){return co=a,W=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,P.H=e===null||e.memoizedState===null?Rs:zs,mo=!1,a=n(r,i),mo=!1,po&&(a=Co(t,n,r,i)),So(e),a}function So(e){P.H=Ls;var t=lo!==null&&lo.next!==null;if(co=0,uo=lo=W=null,fo=!1,go=0,_o=null,t)throw Error(i(300));e===null||nc||(e=e.dependencies,e!==null&&Yi(e)&&(nc=!0))}function Co(e,t,n,r){W=e;var a=0;do{if(po&&(_o=null),go=0,po=!1,25<=a)throw Error(i(301));if(a+=1,uo=lo=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}P.H=Bs,o=t(n,r)}while(po);return o}function wo(){var e=P.H,t=e.useState()[0];return t=typeof t.then==`function`?jo(t):t,e=e.useState()[0],(lo===null?null:lo.memoizedState)!==e&&(W.flags|=1024),t}function To(){var e=ho!==0;return ho=0,e}function Eo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Do(e){if(fo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}fo=!1}co=0,uo=lo=W=null,po=!1,go=ho=0,_o=null}function Oo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return uo===null?W.memoizedState=uo=e:uo=uo.next=e,uo}function ko(){if(lo===null){var e=W.alternate;e=e===null?null:e.memoizedState}else e=lo.next;var t=uo===null?W.memoizedState:uo.next;if(t!==null)uo=t,lo=e;else{if(e===null)throw W.alternate===null?Error(i(467)):Error(i(310));lo=e,e={memoizedState:lo.memoizedState,baseState:lo.baseState,baseQueue:lo.baseQueue,queue:lo.queue,next:null},uo===null?W.memoizedState=uo=e:uo=uo.next=e}return uo}function Ao(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function jo(e){var t=go;return go+=1,_o===null&&(_o=[]),e=Ca(_o,e,t),t=W,(uo===null?t.memoizedState:uo.next)===null&&(t=t.alternate,P.H=t===null||t.memoizedState===null?Rs:zs),e}function Mo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return jo(e);if(e.$$typeof===C)return Zi(e)}throw Error(i(438,String(e)))}function No(e){var t=null,n=W.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=W.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Ao(),W.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=k;return t.index++,n}function Po(e,t){return typeof t==`function`?t(e):t}function Fo(e){return Io(ko(),lo,e)}function Io(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(co&f)===f:(G&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ca&&(d=!0);else if((co&p)===p){u=u.next,p===ca&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,W.lanes|=p,Xl|=p;f=u.action,mo&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,W.lanes|=f,Xl|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!vr(o,e.memoizedState)&&(nc=!0,d&&(n=la,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Lo(e){var t=ko(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);vr(o,t.memoizedState)||(nc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Ro(e,t,n){var r=W,a=ko(),o=Ai;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!vr((lo||a).memoizedState,n);if(s&&(a.memoizedState=n,nc=!0),a=a.queue,ls(Vo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||uo!==null&&uo.memoizedState.tag&1){if(r.flags|=2048,is(9,{destroy:void 0},Bo.bind(null,r,a,n,t),null),Vl===null)throw Error(i(349));o||co&127||zo(r,t,n)}return n}function zo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=W.updateQueue,t===null?(t=Ao(),W.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Bo(e,t,n,r){t.value=n,t.getSnapshot=r,Ho(t)&&Uo(e)}function Vo(e,t,n){return n(function(){Ho(t)&&Uo(e)})}function Ho(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!vr(e,n)}catch{return!0}}function Uo(e){var t=Qr(e,2);t!==null&&bu(t,e,2)}function Wo(e){var t=Oo();if(typeof e==`function`){var n=e;if(e=n(),mo){Le(!0);try{n()}finally{Le(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Po,lastRenderedState:e},t}function Go(e,t,n,r){return e.baseState=n,Io(e,lo,typeof r==`function`?r:Po)}function Ko(e,t,n,r,a){if(Ps(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};P.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,qo(t,o)):(o.next=n.next,t.pending=n.next=o)}}function qo(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=P.T,o={};P.T=o;try{var s=n(i,r),c=P.S;c!==null&&c(o,s),Jo(e,t,s)}catch(n){Xo(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),P.T=a}}else try{a=n(i,r),Jo(e,t,a)}catch(n){Xo(e,t,n)}}function Jo(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Yo(e,t,n)},function(n){return Xo(e,t,n)}):Yo(e,t,n)}function Yo(e,t,n){t.status=`fulfilled`,t.value=n,Zo(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,qo(e,n)))}function Xo(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,Zo(t),t=t.next;while(t!==r)}e.action=null}function Zo(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Qo(e,t){return t}function $o(e,t){if(Ai){var n=Vl.formState;if(n!==null){a:{var r=W;if(Ai){if(ki){b:{for(var i=ki,a=Mi;i.nodeType!==8;){if(!a){i=null;break b}if(i=hf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){ki=hf(i.nextSibling),r=i.data===`F!`;break a}}Pi(r)}r=!1}r&&(t=n[0])}}return n=Oo(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Qo,lastRenderedState:t},n.queue=r,n=js.bind(null,W,r),r.dispatch=n,r=Wo(!1),a=Ns.bind(null,W,!1,r.queue),r=Oo(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Ko.bind(null,W,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function es(e){return ts(ko(),lo,e)}function ts(e,t,n){if(t=Io(e,t,Qo)[0],e=Fo(Po)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=jo(t)}catch(e){throw e===va?ba:e}else r=t;t=ko();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(W.flags|=2048,is(9,{destroy:void 0},ns.bind(null,i,n),null)),[r,a,e]}function ns(e,t){e.action=t}function rs(e){var t=ko(),n=lo;if(n!==null)return ts(t,n,e);ko(),t=t.memoizedState,n=ko();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function is(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=W.updateQueue,t===null&&(t=Ao(),W.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function as(){return ko().memoizedState}function os(e,t,n,r){var i=Oo();W.flags|=e,i.memoizedState=is(1|t,{destroy:void 0},n,r===void 0?null:r)}function ss(e,t,n,r){var i=ko();r=r===void 0?null:r;var a=i.memoizedState.inst;lo!==null&&r!==null&&bo(r,lo.memoizedState.deps)?i.memoizedState=is(t,a,n,r):(W.flags|=e,i.memoizedState=is(1|t,a,n,r))}function cs(e,t){os(8390656,8,e,t)}function ls(e,t){ss(2048,8,e,t)}function us(e){W.flags|=4;var t=W.updateQueue;if(t===null)t=Ao(),W.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function ds(e){var t=ko().memoizedState;return us({ref:t,nextImpl:e}),function(){if(Bl&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function fs(e,t){return ss(4,2,e,t)}function ps(e,t){return ss(4,4,e,t)}function ms(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function hs(e,t,n){n=n==null?null:n.concat([e]),ss(4,4,ms.bind(null,t,e),n)}function gs(){}function _s(e,t){var n=ko();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&bo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function vs(e,t){var n=ko();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&bo(t,r[1]))return r[0];if(r=e(),mo){Le(!0);try{e()}finally{Le(!1)}}return n.memoizedState=[r,t],r}function ys(e,t,n){return n===void 0||co&1073741824&&!(G&261930)?e.memoizedState=t:(e.memoizedState=n,e=yu(),W.lanes|=e,Xl|=e,n)}function bs(e,t,n,r){return vr(n,t)?n:Ja.current===null?!(co&42)||co&1073741824&&!(G&261930)?(nc=!0,e.memoizedState=n):(e=yu(),W.lanes|=e,Xl|=e,t):(e=ys(e,n,r),vr(e,t)||(nc=!0),e)}function xs(e,t,n,r,i){var a=F.p;F.p=a!==0&&8>a?a:8;var o=P.T,s={};P.T=s,Ns(e,!1,t,n);try{var c=i(),l=P.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Ms(e,t,fa(c,r),vu(e)):Ms(e,t,r,vu(e))}catch(n){Ms(e,t,{then:function(){},status:`rejected`,reason:n},vu())}finally{F.p=a,o!==null&&s.types!==null&&(o.types=s.types),P.T=o}}function Ss(){}function Cs(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=ws(e).queue;xs(e,a,t,ne,n===null?Ss:function(){return Ts(e),n(r)})}function ws(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ne,baseState:ne,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Po,lastRenderedState:ne},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Po,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ts(e){var t=ws(e);t.next===null&&(t=e.alternate.memoizedState),Ms(e,t.next.queue,{},vu())}function Es(){return Zi(ap)}function Ds(){return ko().memoizedState}function Os(){return ko().memoizedState}function ks(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=vu();e=za(n);var r=Ba(t,e,n);r!==null&&(bu(r,t,n),Va(r,t,n)),t={cache:ia()},e.payload=t;return}t=t.return}}function As(e,t,n){var r=vu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Ps(e)?Fs(t,n):(n=Zr(e,t,n,r),n!==null&&(bu(n,e,r),Is(n,t,r)))}function js(e,t,n){Ms(e,t,n,vu())}function Ms(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ps(e))Fs(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,vr(s,o))return Xr(e,t,i,0),Vl===null&&Yr(),!1}catch{}if(n=Zr(e,t,i,r),n!==null)return bu(n,e,r),Is(n,t,r),!0}return!1}function Ns(e,t,n,r){if(r={lane:2,revertLane:_d(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Ps(e)){if(t)throw Error(i(479))}else t=Zr(e,n,r,2),t!==null&&bu(t,e,2)}function Ps(e){var t=e.alternate;return e===W||t!==null&&t===W}function Fs(e,t){po=fo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Is(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Qe(e,n)}}var Ls={readContext:Zi,use:Mo,useCallback:yo,useContext:yo,useEffect:yo,useImperativeHandle:yo,useLayoutEffect:yo,useInsertionEffect:yo,useMemo:yo,useReducer:yo,useRef:yo,useState:yo,useDebugValue:yo,useDeferredValue:yo,useTransition:yo,useSyncExternalStore:yo,useId:yo,useHostTransitionStatus:yo,useFormState:yo,useActionState:yo,useOptimistic:yo,useMemoCache:yo,useCacheRefresh:yo};Ls.useEffectEvent=yo;var Rs={readContext:Zi,use:Mo,useCallback:function(e,t){return Oo().memoizedState=[e,t===void 0?null:t],e},useContext:Zi,useEffect:cs,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),os(4194308,4,ms.bind(null,t,e),n)},useLayoutEffect:function(e,t){return os(4194308,4,e,t)},useInsertionEffect:function(e,t){os(4,2,e,t)},useMemo:function(e,t){var n=Oo();t=t===void 0?null:t;var r=e();if(mo){Le(!0);try{e()}finally{Le(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Oo();if(n!==void 0){var i=n(t);if(mo){Le(!0);try{n(t)}finally{Le(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=As.bind(null,W,e),[r.memoizedState,e]},useRef:function(e){var t=Oo();return e={current:e},t.memoizedState=e},useState:function(e){e=Wo(e);var t=e.queue,n=js.bind(null,W,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:gs,useDeferredValue:function(e,t){return ys(Oo(),e,t)},useTransition:function(){var e=Wo(!1);return e=xs.bind(null,W,e.queue,!0,!1),Oo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=W,a=Oo();if(Ai){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Vl===null)throw Error(i(349));G&127||zo(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,cs(Vo.bind(null,r,o,e),[e]),r.flags|=2048,is(9,{destroy:void 0},Bo.bind(null,r,o,n,t),null),n},useId:function(){var e=Oo(),t=Vl.identifierPrefix;if(Ai){var n=Si,r=xi;n=(r&~(1<<32-Re(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=ho++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=vo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Es,useFormState:$o,useActionState:$o,useOptimistic:function(e){var t=Oo();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Ns.bind(null,W,!0,n),n.dispatch=t,[e,t]},useMemoCache:No,useCacheRefresh:function(){return Oo().memoizedState=ks.bind(null,W)},useEffectEvent:function(e){var t=Oo(),n={impl:e};return t.memoizedState=n,function(){if(Bl&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},zs={readContext:Zi,use:Mo,useCallback:_s,useContext:Zi,useEffect:ls,useImperativeHandle:hs,useInsertionEffect:fs,useLayoutEffect:ps,useMemo:vs,useReducer:Fo,useRef:as,useState:function(){return Fo(Po)},useDebugValue:gs,useDeferredValue:function(e,t){return bs(ko(),lo.memoizedState,e,t)},useTransition:function(){var e=Fo(Po)[0],t=ko().memoizedState;return[typeof e==`boolean`?e:jo(e),t]},useSyncExternalStore:Ro,useId:Ds,useHostTransitionStatus:Es,useFormState:es,useActionState:es,useOptimistic:function(e,t){return Go(ko(),lo,e,t)},useMemoCache:No,useCacheRefresh:Os};zs.useEffectEvent=ds;var Bs={readContext:Zi,use:Mo,useCallback:_s,useContext:Zi,useEffect:ls,useImperativeHandle:hs,useInsertionEffect:fs,useLayoutEffect:ps,useMemo:vs,useReducer:Lo,useRef:as,useState:function(){return Lo(Po)},useDebugValue:gs,useDeferredValue:function(e,t){var n=ko();return lo===null?ys(n,e,t):bs(n,lo.memoizedState,e,t)},useTransition:function(){var e=Lo(Po)[0],t=ko().memoizedState;return[typeof e==`boolean`?e:jo(e),t]},useSyncExternalStore:Ro,useId:Ds,useHostTransitionStatus:Es,useFormState:rs,useActionState:rs,useOptimistic:function(e,t){var n=ko();return lo===null?(n.baseState=e,[e,n.queue.dispatch]):Go(n,lo,e,t)},useMemoCache:No,useCacheRefresh:Os};Bs.useEffectEvent=ds;function Vs(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:m({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Hs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=vu(),i=za(r);i.payload=t,n!=null&&(i.callback=n),t=Ba(e,i,r),t!==null&&(bu(t,e,r),Va(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=vu(),i=za(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ba(e,i,r),t!==null&&(bu(t,e,r),Va(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=vu(),r=za(n);r.tag=2,t!=null&&(r.callback=t),t=Ba(e,r,n),t!==null&&(bu(t,e,n),Va(t,e,n))}};function Us(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!yr(n,r)||!yr(i,a):!0}function Ws(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Hs.enqueueReplaceState(t,t.state,null)}function Gs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=m({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Ks(e){Gr(e)}function qs(e){console.error(e)}function Js(e){Gr(e)}function Ys(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Xs(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Zs(e,t,n){return n=za(n),n.tag=3,n.payload={element:null},n.callback=function(){Ys(e,t)},n}function Qs(e){return e=za(e),e.tag=3,e}function $s(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){Xs(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Xs(t,n,r),typeof i!=`function`&&(cu===null?cu=new Set([this]):cu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function ec(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&Ji(t,n,a,!0),n=$a.current,n!==null){switch(n.tag){case 31:case 13:return eo===null?Mu():n.alternate===null&&Yl===0&&(Yl=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===xa?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Zu(e,r,a)),!1;case 22:return n.flags|=65536,r===xa?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),Zu(e,r,a)),!1}throw Error(i(435,n.tag))}return Zu(e,r,a),Mu(),!1}if(Ai)return t=$a.current,t===null?(r!==Ni&&(t=Error(i(423),{cause:r}),Bi(pi(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=pi(r,n),a=Zs(e.stateNode,r,a),Ha(e,a),Yl!==4&&(Yl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==Ni&&(e=Error(i(422),{cause:r}),Bi(pi(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=pi(o,n),tu===null?tu=[o]:tu.push(o),Yl!==4&&(Yl=2),t===null)return!0;r=pi(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=Zs(n.stateNode,r,e),Ha(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(cu===null||!cu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=Qs(a),$s(a,e,n,r),Ha(n,a),!1}n=n.return}while(n!==null);return!1}var tc=Error(i(461)),nc=!1;function rc(e,t,n,r){t.child=e===null?Fa(t,null,n,r):Pa(t,e.child,n,r)}function ic(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return Xi(t),r=xo(e,t,n,o,a,i),s=To(),e!==null&&!nc?(Eo(e,t,i),Oc(e,t,i)):(Ai&&s&&Ti(t),t.flags|=1,rc(e,t,r,i),t.child)}function ac(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!ii(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,oc(e,t,a,r,i)):(e=si(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!kc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?yr:n,n(o,r)&&e.ref===t.ref)return Oc(e,t,i)}return t.flags|=1,e=ai(a,r),e.ref=t.ref,e.return=t,t.child=e}function oc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(yr(a,r)&&e.ref===t.ref){if(nc=!1,t.pendingProps=r=a,kc(e,i))e.flags&131072&&(nc=!0);else return t.lanes=e.lanes,Oc(e,t,i)}}return mc(e,t,n,r,i)}function sc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return lc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&ga(t,a===null?null:a.cachePool),a===null?Za():Xa(t,a),ro(t);else return r=t.lanes=536870912,lc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&ga(t,null),Za(),io(t)):(ga(t,a.cachePool),Xa(t,a),io(t),t.memoizedState=null);return rc(e,t,i,n),t.child}function cc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function lc(e,t,n,r,i){var a=ha();return a=a===null?null:{parent:ra._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&ga(t,null),Za(),ro(t),e!==null&&Ji(e,t,r,!0),t.childLanes=i,null}function uc(e,t){return t=Cc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function dc(e,t,n){return Pa(t,e.child,null,n),e=uc(t,t.pendingProps),e.flags|=2,ao(t),t.memoizedState=null,e}function fc(e,t,n){var r=t.pendingProps,a=!!(t.flags&128);if(t.flags&=-129,e===null){if(Ai){if(r.mode===`hidden`)return e=uc(t,r),t.lanes=536870912,cc(null,e);if(no(t),(e=ki)?(e=df(e,Mi),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:bi===null?null:{id:xi,overflow:Si},retryLane:536870912,hydrationErrors:null},n=ui(e),n.return=t,t.child=n,Oi=t,ki=null)):e=null,e===null)throw Pi(t);return t.lanes=536870912,null}return uc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(no(t),a){if(t.flags&256)t.flags&=-257,t=dc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558))}else if(nc||Ji(e,t,n,!1),a=(n&e.childLanes)!==0,nc||a){if(r=Vl,r!==null&&(s=$e(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,Qr(e,s),bu(r,e,s),tc;Mu(),t=dc(e,t,n)}else e=o.treeContext,ki=hf(s.nextSibling),Oi=t,Ai=!0,ji=null,Mi=!1,e!==null&&Di(t,e),t=uc(t,r),t.flags|=4096;return t}return e=ai(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function pc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function mc(e,t,n,r,i){return Xi(t),n=xo(e,t,n,r,void 0,i),r=To(),e!==null&&!nc?(Eo(e,t,i),Oc(e,t,i)):(Ai&&r&&Ti(t),t.flags|=1,rc(e,t,n,i),t.child)}function hc(e,t,n,r,i,a){return Xi(t),t.updateQueue=null,n=Co(t,r,n,i),So(e),r=To(),e!==null&&!nc?(Eo(e,t,a),Oc(e,t,a)):(Ai&&r&&Ti(t),t.flags|=1,rc(e,t,n,a),t.child)}function gc(e,t,n,r,i){if(Xi(t),t.stateNode===null){var a=ti,o=n.contextType;typeof o==`object`&&o&&(a=Zi(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Hs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},La(t),o=n.contextType,a.context=typeof o==`object`&&o?Zi(o):ti,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Vs(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Hs.enqueueReplaceState(a,a.state,null),Ga(t,r,a,i),Wa(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Gs(n,s);a.props=c;var l=a.context,u=n.contextType;o=ti,typeof u==`object`&&u&&(o=Zi(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Ws(t,a,r,o),Ia=!1;var f=t.memoizedState;a.state=f,Ga(t,r,a,i),Wa(),l=t.memoizedState,s||f!==l||Ia?(typeof d==`function`&&(Vs(t,n,d,r),l=t.memoizedState),(c=Ia||Us(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Ra(e,t),o=t.memoizedProps,u=Gs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ti,typeof l==`object`&&l&&(c=Zi(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Ws(t,a,r,c),Ia=!1,f=t.memoizedState,a.state=f,Ga(t,r,a,i),Wa();var p=t.memoizedState;o!==d||f!==p||Ia||e!==null&&e.dependencies!==null&&Yi(e.dependencies)?(typeof s==`function`&&(Vs(t,n,s,r),p=t.memoizedState),(u=Ia||Us(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Yi(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,pc(e,t),r=!!(t.flags&128),a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Pa(t,e.child,null,i),t.child=Pa(t,null,n,i)):rc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Oc(e,t,i),e}function _c(e,t,n,r){return Ri(),t.flags|=256,rc(e,t,n,r),t.child}var vc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function yc(e){return{baseLanes:e,cachePool:_a()}}function bc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=$l),e}function xc(e,t,n){var r=t.pendingProps,a=!1,o=!!(t.flags&128),s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:!!(oo.current&2)),s&&(a=!0,t.flags&=-129),s=!!(t.flags&32),t.flags&=-33,e===null){if(Ai){if(a?to(t):io(t),(e=ki)?(e=df(e,Mi),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:bi===null?null:{id:xi,overflow:Si},retryLane:536870912,hydrationErrors:null},n=ui(e),n.return=t,t.child=n,Oi=t,ki=null)):e=null,e===null)throw Pi(t);return pf(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(io(t),a=t.mode,c=Cc({mode:`hidden`,children:c},a),r=ci(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=yc(n),r.childLanes=bc(e,s,n),t.memoizedState=vc,cc(null,r)):(to(t),Sc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(to(t),t.flags&=-257,t=wc(e,t,n)):t.memoizedState===null?(io(t),c=r.fallback,a=t.mode,r=Cc({mode:`visible`,children:r.children},a),c=ci(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Pa(t,e.child,null,n),r=t.child,r.memoizedState=yc(n),r.childLanes=bc(e,s,n),t.memoizedState=vc,t=cc(null,r)):(io(t),t.child=e.child,t.flags|=128,t=null);else if(to(t),pf(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Bi({value:r,source:null,stack:null}),t=wc(e,t,n)}else if(nc||Ji(e,t,n,!1),s=(n&e.childLanes)!==0,nc||s){if(s=Vl,s!==null&&(r=$e(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,Qr(e,r),bu(s,e,r),tc;ff(c)||Mu(),t=wc(e,t,n)}else ff(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,ki=hf(c.nextSibling),Oi=t,Ai=!0,ji=null,Mi=!1,e!==null&&Di(t,e),t=Sc(t,r.children),t.flags|=4096);return t}return a?(io(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=ai(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=ci(c,a,n,null),c.flags|=2):c=ai(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,cc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=yc(n):(a=c.cachePool,a===null?a=_a():(l=ra._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=bc(e,s,n),t.memoizedState=vc,cc(e.child,r)):(to(t),n=e.child,e=n.sibling,n=ai(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function Sc(e,t){return t=Cc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function Cc(e,t){return e=ri(22,e,null,t),e.lanes=0,e}function wc(e,t,n){return Pa(t,e.child,null,n),e=Sc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Tc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Ki(e.return,t,n)}function Ec(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Dc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=oo.current,s=!!(o&2);if(s?(o=o&1|2,t.flags|=128):o&=1,L(oo,o),rc(e,t,r,n),r=Ai?_i:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Tc(e,n,t);else if(e.tag===19)Tc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&so(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Ec(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&so(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Ec(t,!0,n,null,a,r);break;case`together`:Ec(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Oc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Xl|=t.lanes,(n&t.childLanes)===0){if(e!==null){if(Ji(e,t,n,!1),(n&t.childLanes)===0)return null}else return null}if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=ai(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=ai(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function kc(e,t){return(e.lanes&t)!==0||(e=e.dependencies,!!(e!==null&&Yi(e)))}function Ac(e,t,n){switch(t.tag){case 3:ue(t,t.stateNode.containerInfo),Wi(t,ra,e.memoizedState.cache),Ri();break;case 27:case 5:fe(t);break;case 4:ue(t,t.stateNode.containerInfo);break;case 10:Wi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,no(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(to(t),e=Oc(e,t,n),e===null?null:e.sibling):xc(e,t,n):(to(t),t.flags|=128,null);to(t);break;case 19:var i=!!(e.flags&128);if(r=(n&t.childLanes)!==0,r||=(Ji(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Dc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),L(oo,oo.current),r)break;return null;case 22:return t.lanes=0,sc(e,t,n,t.pendingProps);case 24:Wi(t,ra,e.memoizedState.cache)}return Oc(e,t,n)}function jc(e,t,n){if(e!==null){if(e.memoizedProps!==t.pendingProps)nc=!0;else{if(!kc(e,n)&&!(t.flags&128))return nc=!1,Ac(e,t,n);nc=!!(e.flags&131072)}}else nc=!1,Ai&&t.flags&1048576&&wi(t,_i,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=wa(t.elementType),t.type=e,typeof e==`function`)ii(e)?(r=Gs(e,r),t.tag=1,t=gc(null,t,e,r,n)):(t.tag=0,t=mc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===w){t.tag=11,t=ic(null,t,e,r,n);break a}if(a===ee){t.tag=14,t=ac(null,t,e,r,n);break a}}throw t=N(e)||e,Error(i(306,t,``))}}return t;case 0:return mc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=Gs(r,t.pendingProps),gc(e,t,r,a,n);case 3:a:{if(ue(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,Ra(e,t),Ga(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Wi(t,ra,r),r!==o.cache&&qi(t,[ra],n,!0),Wa(),r=s.element,o.isDehydrated){if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=_c(e,t,r,n);break a}if(r!==a){a=pi(Error(i(424)),t),Bi(a),t=_c(e,t,r,n);break a}switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(ki=hf(e.firstChild),Oi=t,Ai=!0,ji=null,Mi=!0,n=Fa(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Ri(),r===a){t=Oc(e,t,n);break a}rc(e,t,r,n)}t=t.child}return t;case 26:return pc(e,t),e===null?(n=If(t.type,null,t.pendingProps,null))?t.memoizedState=n:Ai||(n=t.type,e=t.pendingProps,r=qd(ce.current).createElement(n),r[at]=t,r[ot]=e,Vd(r,n,e),B(r),t.stateNode=r):t.memoizedState=If(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return fe(t),e===null&&Ai&&(r=t.stateNode=yf(t.type,t.pendingProps,ce.current),Oi=t,Mi=!0,a=ki,af(t.type)?(gf=a,ki=hf(r.firstChild)):ki=a),rc(e,t,t.pendingProps.children,n),pc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Ai&&((a=r=ki)&&(r=lf(r,t.type,t.pendingProps,Mi),r===null?a=!1:(t.stateNode=r,Oi=t,ki=hf(r.firstChild),Mi=!1,a=!0)),a||Pi(t)),fe(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,Xd(a,o)?r=null:s!==null&&Xd(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=xo(e,t,wo,null,null,n),ap._currentValue=a),pc(e,t),rc(e,t,r,n),t.child;case 6:return e===null&&Ai&&((e=n=ki)&&(n=uf(n,t.pendingProps,Mi),n===null?e=!1:(t.stateNode=n,Oi=t,ki=null,e=!0)),e||Pi(t)),null;case 13:return xc(e,t,n);case 4:return ue(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Pa(t,null,r,n):rc(e,t,r,n),t.child;case 11:return ic(e,t,t.type,t.pendingProps,n);case 7:return rc(e,t,t.pendingProps,n),t.child;case 8:return rc(e,t,t.pendingProps.children,n),t.child;case 12:return rc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Wi(t,t.type,r.value),rc(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,Xi(t),a=Zi(a),r=r(a),t.flags|=1,rc(e,t,r,n),t.child;case 14:return ac(e,t,t.type,t.pendingProps,n);case 15:return oc(e,t,t.type,t.pendingProps,n);case 19:return Dc(e,t,n);case 31:return fc(e,t,n);case 22:return sc(e,t,n,t.pendingProps);case 24:return Xi(t),r=Zi(ra),e===null?(a=ha(),a===null&&(a=Vl,o=ia(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},La(t),Wi(t,ra,a)):((e.lanes&n)!==0&&(Ra(e,t),Ga(t,null,null,n),Wa()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,Wi(t,ra,r),r!==a.cache&&qi(t,[ra],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),Wi(t,ra,r))),rc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function Mc(e){e.flags|=4}function Nc(e,t,n,r,i){if((t=!!(e.mode&32))&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i){if(e.stateNode.complete)e.flags|=8192;else if(ku())e.flags|=8192;else throw Ta=xa,ya}}else e.flags&=-16777217}function Pc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!Zf(t)){if(ku())e.flags|=8192;else throw Ta=xa,ya}}function Fc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:qe(),e.lanes|=t,eu|=t)}function Ic(e,t){if(!Ai)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Lc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Rc(e,t,n){var r=t.pendingProps;switch(Ei(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Lc(t),null;case 1:return Lc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Gi(ra),de(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Li(t)?Mc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,zi())),Lc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(Mc(t),o===null?(Lc(t),Nc(t,a,null,r,n)):(Lc(t),Pc(t,o))):o?o===e.memoizedState?(Lc(t),t.flags&=-16777217):(Mc(t),Lc(t),Pc(t,o)):(e=e.memoizedProps,e!==r&&Mc(t),Lc(t),Nc(t,a,e,r,n)),null;case 27:if(pe(t),n=ce.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Mc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Lc(t),null}e=oe.current,Li(t)?Fi(t,e):(e=yf(a,r,n),t.stateNode=e,Mc(t))}return Lc(t),null;case 5:if(pe(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Mc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Lc(t),null}if(o=oe.current,Li(t))Fi(t,o);else{var s=qd(ce.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[at]=t,o[ot]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Vd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Mc(t)}}return Lc(t),Nc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Mc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=ce.current,Li(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Oi,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[at]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Rd(e.nodeValue,n)),e||Pi(t,!0)}else e=qd(e).createTextNode(r),e[at]=t,t.stateNode=e}return Lc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Li(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[at]=t}else Ri(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Lc(t),e=!1}else n=zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(ao(t),t):(ao(t),null);if(t.flags&128)throw Error(i(558))}return Lc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Li(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[at]=t}else Ri(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Lc(t),a=!1}else a=zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(ao(t),t):(ao(t),null)}return ao(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Fc(t,t.updateQueue),Lc(t),null);case 4:return de(),e===null&&Od(t.stateNode.containerInfo),Lc(t),null;case 10:return Gi(t.type),Lc(t),null;case 19:if(I(oo),r=t.memoizedState,r===null)return Lc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Ic(r,!1);else{if(Yl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=so(e),o!==null){for(t.flags|=128,Ic(r,!1),e=o.updateQueue,t.updateQueue=e,Fc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)oi(n,e),n=n.sibling;return L(oo,oo.current&1|2),Ai&&Ci(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ee()>ou&&(t.flags|=128,a=!0,Ic(r,!1),t.lanes=4194304)}}else{if(!a){if(e=so(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Fc(t,e),Ic(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!Ai)return Lc(t),null}else 2*Ee()-r.renderingStartTime>ou&&n!==536870912&&(t.flags|=128,a=!0,Ic(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Lc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ee(),e.sibling=null,n=oo.current,L(oo,a?n&1|2:n&1),Ai&&Ci(t,r.treeForkCount),e);case 22:case 23:return ao(t),Qa(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Lc(t),t.subtreeFlags&6&&(t.flags|=8192)):Lc(t),n=t.updateQueue,n!==null&&Fc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&I(ma),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Gi(ra),Lc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function zc(e,t){switch(Ei(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Gi(ra),de(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return pe(t),null;case 31:if(t.memoizedState!==null){if(ao(t),t.alternate===null)throw Error(i(340));Ri()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ao(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Ri()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return I(oo),null;case 4:return de(),null;case 10:return Gi(t.type),null;case 22:case 23:return ao(t),Qa(),e!==null&&I(ma),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Gi(ra),null;case 25:return null;default:return null}}function Bc(e,t){switch(Ei(t),t.tag){case 3:Gi(ra),de();break;case 26:case 27:case 5:pe(t);break;case 4:de();break;case 31:t.memoizedState!==null&&ao(t);break;case 13:ao(t);break;case 19:I(oo);break;case 10:Gi(t.type);break;case 22:case 23:ao(t),Qa(),e!==null&&I(ma);break;case 24:Gi(ra)}}function Vc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Xu(t,t.return,e)}}function Hc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Xu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Xu(t,t.return,e)}}function Uc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{qa(t,n)}catch(t){Xu(e,e.return,t)}}}function Wc(e,t,n){n.props=Gs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Xu(e,t,n)}}function Gc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Xu(e,t,n)}}function Kc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){Xu(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Xu(e,t,n)}else n.current=null}}function qc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Xu(e,e.return,t)}}function Jc(e,t,n){try{var r=e.stateNode;Hd(r,e.type,n,t),r[ot]=t}catch(t){Xu(e,e.return,t)}}function Yc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&af(e.type)||e.tag===4}function Xc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Yc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&af(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Zc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Zt));else if(r!==4&&(r===27&&af(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Zc(e,t,n),e=e.sibling;e!==null;)Zc(e,t,n),e=e.sibling}function Qc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&af(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Qc(e,t,n),e=e.sibling;e!==null;)Qc(e,t,n),e=e.sibling}function $c(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Vd(t,r,n),t[at]=e,t[ot]=n}catch(t){Xu(e,e.return,t)}}var el=!1,tl=!1,nl=!1,rl=typeof WeakSet==`function`?WeakSet:Set,il=null;function al(e,t){if(e=e.containerInfo,Gd=mp,e=Cr(e),wr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(Kd={focusedElem:e,selectionRange:n},mp=!1,il=t;il!==null;)if(t=il,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,il=e;else for(;il!==null;){switch(t=il,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Gs(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Xu(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)cf(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:cf(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,il=e;break}il=t.return}}function ol(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:xl(e,n),r&4&&Vc(5,n);break;case 1:if(xl(e,n),r&4){if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Xu(n,n.return,e)}else{var i=Gs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Xu(n,n.return,e)}}}r&64&&Uc(n),r&512&&Gc(n,n.return);break;case 3:if(xl(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{qa(e,t)}catch(e){Xu(n,n.return,e)}}break;case 27:t===null&&r&4&&$c(n);case 26:case 5:xl(e,n),t===null&&r&4&&qc(n),r&512&&Gc(n,n.return);break;case 12:xl(e,n);break;case 31:xl(e,n),r&4&&fl(e,n);break;case 13:xl(e,n),r&4&&pl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=ed.bind(null,n),mf(e,n))));break;case 22:if(r=n.memoizedState!==null||el,!r){t=t!==null&&t.memoizedState!==null||tl,i=el;var a=tl;el=r,(tl=t)&&!a?Cl(e,n,!!(n.subtreeFlags&8772)):xl(e,n),el=i,tl=a}break;case 30:break;default:xl(e,n)}}function sl(e){var t=e.alternate;t!==null&&(e.alternate=null,sl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&pt(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var cl=null,ll=!1;function ul(e,t,n){for(n=n.child;n!==null;)dl(e,t,n),n=n.sibling}function dl(e,t,n){if(Ie&&typeof Ie.onCommitFiberUnmount==`function`)try{Ie.onCommitFiberUnmount(Fe,n)}catch{}switch(n.tag){case 26:tl||Kc(n,t),ul(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:tl||Kc(n,t);var r=cl,i=ll;af(n.type)&&(cl=n.stateNode,ll=!1),ul(e,t,n),bf(n.stateNode),cl=r,ll=i;break;case 5:tl||Kc(n,t);case 6:if(r=cl,i=ll,cl=null,ul(e,t,n),cl=r,ll=i,cl!==null){if(ll)try{(cl.nodeType===9?cl.body:cl.nodeName===`HTML`?cl.ownerDocument.body:cl).removeChild(n.stateNode)}catch(e){Xu(n,t,e)}else try{cl.removeChild(n.stateNode)}catch(e){Xu(n,t,e)}}break;case 18:cl!==null&&(ll?(e=cl,of(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Bp(e)):of(cl,n.stateNode));break;case 4:r=cl,i=ll,cl=n.stateNode.containerInfo,ll=!0,ul(e,t,n),cl=r,ll=i;break;case 0:case 11:case 14:case 15:Hc(2,n,t),tl||Hc(4,n,t),ul(e,t,n);break;case 1:tl||(Kc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Wc(n,t,r)),ul(e,t,n);break;case 21:ul(e,t,n);break;case 22:tl=(r=tl)||n.memoizedState!==null,ul(e,t,n),tl=r;break;default:ul(e,t,n)}}function fl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Bp(e)}catch(e){Xu(t,t.return,e)}}}function pl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Bp(e)}catch(e){Xu(t,t.return,e)}}function ml(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new rl),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new rl),t;default:throw Error(i(435,e.tag))}}function hl(e,t){var n=ml(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=td.bind(null,e,t);t.then(r,r)}})}function gl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(af(c.type)){cl=c.stateNode,ll=!1;break a}break;case 5:cl=c.stateNode,ll=!1;break a;case 3:case 4:cl=c.stateNode.containerInfo,ll=!0;break a}c=c.return}if(cl===null)throw Error(i(160));dl(o,s,a),cl=null,ll=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)vl(t,e),t=t.sibling}var _l=null;function vl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:gl(t,e),yl(e),r&4&&(Hc(3,e,e.return),Vc(3,e),Hc(5,e,e.return));break;case 1:gl(t,e),yl(e),r&512&&(tl||n===null||Kc(n,n.return)),r&64&&el&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=_l;if(gl(t,e),yl(e),r&512&&(tl||n===null||Kc(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null){if(r===null){if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[ft]||o[at]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Vd(o,r,n),o[at]=e,B(o),r=o;break a;case`link`:var s=Jf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Vd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Jf(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Vd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[at]=e,B(o),r=o}e.stateNode=r}else Yf(a,e.type,e.stateNode)}else e.stateNode=Uf(a,r,e.memoizedProps)}else o===r?r===null&&e.stateNode!==null&&Jc(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Yf(a,e.type,e.stateNode):Uf(a,r,e.memoizedProps))}break;case 27:gl(t,e),yl(e),r&512&&(tl||n===null||Kc(n,n.return)),n!==null&&r&4&&Jc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(gl(t,e),yl(e),r&512&&(tl||n===null||Kc(n,n.return)),e.flags&32){a=e.stateNode;try{Ut(a,``)}catch(t){Xu(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,Jc(e,a,n===null?a:n.memoizedProps)),r&1024&&(nl=!0);break;case 6:if(gl(t,e),yl(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Xu(e,e.return,t)}}break;case 3:if(qf=null,a=_l,_l=Cf(t.containerInfo),gl(t,e),_l=a,yl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Bp(t.containerInfo)}catch(t){Xu(e,e.return,t)}nl&&(nl=!1,bl(e));break;case 4:r=_l,_l=Cf(e.stateNode.containerInfo),gl(t,e),yl(e),_l=r;break;case 12:gl(t,e),yl(e);break;case 31:gl(t,e),yl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,hl(e,r)));break;case 13:gl(t,e),yl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(iu=Ee()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,hl(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=el,d=tl;if(el=u||a,tl=d||l,gl(t,e),tl=d,el=u,yl(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||el||tl||Sl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){Xu(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){Xu(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?sf(m,!0):sf(l.stateNode,!1)}catch(e){Xu(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,hl(e,n))));break;case 19:gl(t,e),yl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,hl(e,r)));break;case 30:break;case 21:break;default:gl(t,e),yl(e)}}function yl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Yc(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;Qc(e,Xc(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Ut(o,``),n.flags&=-33),Qc(e,Xc(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;Zc(e,Xc(e),s);break;default:throw Error(i(161))}}catch(t){Xu(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function bl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;bl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function xl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)ol(e,t.alternate,t),t=t.sibling}function Sl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Hc(4,t,t.return),Sl(t);break;case 1:Kc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Wc(t,t.return,n),Sl(t);break;case 27:bf(t.stateNode);case 26:case 5:Kc(t,t.return),Sl(t);break;case 22:t.memoizedState===null&&Sl(t);break;case 30:Sl(t);break;default:Sl(t)}e=e.sibling}}function Cl(e,t,n){for(n&&=!!(t.subtreeFlags&8772),t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:Cl(i,a,n),Vc(4,a);break;case 1:if(Cl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Xu(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Ka(c[i],s)}catch(e){Xu(r,r.return,e)}}n&&o&64&&Uc(a),Gc(a,a.return);break;case 27:$c(a);case 26:case 5:Cl(i,a,n),n&&r===null&&o&4&&qc(a),Gc(a,a.return);break;case 12:Cl(i,a,n);break;case 31:Cl(i,a,n),n&&o&4&&fl(i,a);break;case 13:Cl(i,a,n),n&&o&4&&pl(i,a);break;case 22:a.memoizedState===null&&Cl(i,a,n),Gc(a,a.return);break;case 30:break;default:Cl(i,a,n)}t=t.sibling}}function wl(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&aa(n))}function Tl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&aa(e))}function El(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Dl(e,t,n,r),t=t.sibling}function Dl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:El(e,t,n,r),i&2048&&Vc(9,t);break;case 1:El(e,t,n,r);break;case 3:El(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&aa(e)));break;case 12:if(i&2048){El(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){Xu(t,t.return,e)}}else El(e,t,n,r);break;case 31:El(e,t,n,r);break;case 13:El(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?El(e,t,n,r):(a._visibility|=2,Ol(e,t,n,r,!!(t.subtreeFlags&10256)||!1)):a._visibility&2?El(e,t,n,r):kl(e,t),i&2048&&wl(o,t);break;case 24:El(e,t,n,r),i&2048&&Tl(t.alternate,t);break;default:El(e,t,n,r)}}function Ol(e,t,n,r,i){for(i&&=!!(t.subtreeFlags&10256)||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Ol(a,o,s,c,i),Vc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Ol(a,o,s,c,i)):u._visibility&2?Ol(a,o,s,c,i):kl(a,o),i&&l&2048&&wl(o.alternate,o);break;case 24:Ol(a,o,s,c,i),i&&l&2048&&Tl(o.alternate,o);break;default:Ol(a,o,s,c,i)}t=t.sibling}}function kl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:kl(n,r),i&2048&&wl(r.alternate,r);break;case 24:kl(n,r),i&2048&&Tl(r.alternate,r);break;default:kl(n,r)}t=t.sibling}}var Al=8192;function jl(e,t,n){if(e.subtreeFlags&Al)for(e=e.child;e!==null;)Ml(e,t,n),e=e.sibling}function Ml(e,t,n){switch(e.tag){case 26:jl(e,t,n),e.flags&Al&&e.memoizedState!==null&&Qf(n,_l,e.memoizedState,e.memoizedProps);break;case 5:jl(e,t,n);break;case 3:case 4:var r=_l;_l=Cf(e.stateNode.containerInfo),jl(e,t,n),_l=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Al,Al=16777216,jl(e,t,n),Al=r):jl(e,t,n));break;default:jl(e,t,n)}}function Nl(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Pl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];il=r,Ll(r,e)}Nl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Fl(e),e=e.sibling}function Fl(e){switch(e.tag){case 0:case 11:case 15:Pl(e),e.flags&2048&&Hc(9,e,e.return);break;case 3:Pl(e);break;case 12:Pl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Il(e)):Pl(e);break;default:Pl(e)}}function Il(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];il=r,Ll(r,e)}Nl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Hc(8,t,t.return),Il(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Il(t));break;default:Il(t)}e=e.sibling}}function Ll(e,t){for(;il!==null;){var n=il;switch(n.tag){case 0:case 11:case 15:Hc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:aa(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,il=r;else a:for(n=e;il!==null;){r=il;var i=r.sibling,a=r.return;if(sl(r),r===n){il=null;break a}if(i!==null){i.return=a,il=i;break a}il=a}}}var Rl={getCacheForType:function(e){var t=Zi(ra),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Zi(ra).controller.signal}},zl=typeof WeakMap==`function`?WeakMap:Map,Bl=0,Vl=null,Hl=null,G=0,Ul=0,Wl=null,Gl=!1,Kl=!1,ql=!1,Jl=0,Yl=0,Xl=0,Zl=0,Ql=0,$l=0,eu=0,tu=null,nu=null,ru=!1,iu=0,au=0,ou=1/0,su=null,cu=null,lu=0,uu=null,du=null,fu=0,pu=0,mu=null,hu=null,gu=0,_u=null;function vu(){return Bl&2&&G!==0?G&-G:P.T===null?nt():_d()}function yu(){if($l===0){if(!(G&536870912)||Ai){var e=Ue;Ue<<=1,!(Ue&3932160)&&(Ue=262144),$l=e}else $l=536870912}return e=$a.current,e!==null&&(e.flags|=32),$l}function bu(e,t,n){(e===Vl&&(Ul===2||Ul===9)||e.cancelPendingCommit!==null)&&(Du(e,0),wu(e,G,$l,!1)),Ye(e,n),(!(Bl&2)||e!==Vl)&&(e===Vl&&(!(Bl&2)&&(Zl|=n),Yl===4&&wu(e,G,$l,!1)),ld(e))}function xu(e,t,n){if(Bl&6)throw Error(i(327));var r=!n&&!(t&127)&&(t&e.expiredLanes)===0||Ge(e,t),a=r?Fu(e,t):Nu(e,t,!0),o=r;do{if(a===0){Kl&&!r&&wu(e,t,0,!1);break}if(n=e.current.alternate,o&&!Cu(n)){a=Nu(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=tu;var l=c.current.memoizedState.isDehydrated;if(l&&(Du(c,s).flags|=256),s=Nu(c,s,!1),s!==2){if(ql&&!l){c.errorRecoveryDisabledLanes|=o,Zl|=o,a=4;break a}o=nu,nu=a,o!==null&&(nu===null?nu=o:nu.push.apply(nu,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Du(e,0),wu(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:wu(r,t,$l,!Gl);break a;case 2:nu=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=iu+300-Ee(),10<a)){if(wu(r,t,$l,!Gl),z(r,0,!0)!==0)break a;fu=t,r.timeoutHandle=$d(Su.bind(null,r,n,nu,su,ru,t,$l,Zl,eu,Gl,o,`Throttled`,-0,0),a);break a}Su(r,n,nu,su,ru,t,$l,Zl,eu,Gl,o,null,-0,0)}break}while(1);ld(e)}function Su(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Zt},Ml(t,a,d);var m=(a&62914560)===a?iu-Ee():(a&4194048)===a?au-Ee():0;if(m=ep(d,m),m!==null){fu=a,e.cancelPendingCommit=m(Hu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),wu(e,a,o,!l);return}}Hu(e,t,a,n,r,i,o,s,c)}function Cu(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!vr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function wu(e,t,n,r){t&=~Ql,t&=~Zl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Re(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Ze(e,n,t)}function Tu(){return Bl&6?!0:(ud(0,!1),!1)}function Eu(){if(Hl!==null){if(Ul===0)var e=Hl.return;else e=Hl,Ui=Hi=null,Do(e),Oa=null,ka=0,e=Hl;for(;e!==null;)Bc(e.alternate,e),e=e.return;Hl=null}}function Du(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,ef(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),fu=0,Eu(),Vl=e,Hl=n=ai(e.current,null),G=t,Ul=0,Wl=null,Gl=!1,Kl=Ge(e,t),ql=!1,eu=$l=Ql=Zl=Xl=Yl=0,nu=tu=null,ru=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Re(r),a=1<<i;t|=e[i],r&=~a}return Jl=t,Yr(),n}function Ou(e,t){W=null,P.H=Ls,t===va||t===ba?(t=Ea(),Ul=3):t===ya?(t=Ea(),Ul=4):Ul=t===tc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Wl=t,Hl===null&&(Yl=1,Ys(e,pi(t,e.current)))}function ku(){var e=$a.current;return e===null?!0:(G&4194048)===G?eo===null:(G&62914560)===G||G&536870912?e===eo:!1}function Au(){var e=P.H;return P.H=Ls,e===null?Ls:e}function ju(){var e=P.A;return P.A=Rl,e}function Mu(){Yl=4,Gl||(G&4194048)!==G&&$a.current!==null||(Kl=!0),!(Xl&134217727)&&!(Zl&134217727)||Vl===null||wu(Vl,G,$l,!1)}function Nu(e,t,n){var r=Bl;Bl|=2;var i=Au(),a=ju();(Vl!==e||G!==t)&&(su=null,Du(e,t)),t=!1;var o=Yl;a:do try{if(Ul!==0&&Hl!==null){var s=Hl,c=Wl;switch(Ul){case 8:Eu(),o=6;break a;case 3:case 2:case 9:case 6:$a.current===null&&(t=!0);var l=Ul;if(Ul=0,Wl=null,zu(e,s,c,l),n&&Kl){o=0;break a}break;default:l=Ul,Ul=0,Wl=null,zu(e,s,c,l)}}Pu(),o=Yl;break}catch(t){Ou(e,t)}while(1);return t&&e.shellSuspendCounter++,Ui=Hi=null,Bl=r,P.H=i,P.A=a,Hl===null&&(Vl=null,G=0,Yr()),o}function Pu(){for(;Hl!==null;)Lu(Hl)}function Fu(e,t){var n=Bl;Bl|=2;var r=Au(),a=ju();Vl!==e||G!==t?(su=null,ou=Ee()+500,Du(e,t)):Kl=Ge(e,t);a:do try{if(Ul!==0&&Hl!==null){t=Hl;var o=Wl;b:switch(Ul){case 1:Ul=0,Wl=null,zu(e,t,o,1);break;case 2:case 9:if(Sa(o)){Ul=0,Wl=null,Ru(t);break}t=function(){Ul!==2&&Ul!==9||Vl!==e||(Ul=7),ld(e)},o.then(t,t);break a;case 3:Ul=7;break a;case 4:Ul=5;break a;case 7:Sa(o)?(Ul=0,Wl=null,Ru(t)):(Ul=0,Wl=null,zu(e,t,o,7));break;case 5:var s=null;switch(Hl.tag){case 26:s=Hl.memoizedState;case 5:case 27:var c=Hl;if(s?Zf(s):c.stateNode.complete){Ul=0,Wl=null;var l=c.sibling;if(l!==null)Hl=l;else{var u=c.return;u===null?Hl=null:(Hl=u,Bu(u))}break b}}Ul=0,Wl=null,zu(e,t,o,5);break;case 6:Ul=0,Wl=null,zu(e,t,o,6);break;case 8:Eu(),Yl=6;break a;default:throw Error(i(462))}}Iu();break}catch(t){Ou(e,t)}while(1);return Ui=Hi=null,P.H=r,P.A=a,Bl=n,Hl===null?(Vl=null,G=0,Yr(),Yl):0}function Iu(){for(;Hl!==null&&!we();)Lu(Hl)}function Lu(e){var t=jc(e.alternate,e,Jl);e.memoizedProps=e.pendingProps,t===null?Bu(e):Hl=t}function Ru(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=hc(n,t,t.pendingProps,t.type,void 0,G);break;case 11:t=hc(n,t,t.pendingProps,t.type.render,t.ref,G);break;case 5:Do(t);default:Bc(n,t),t=Hl=oi(t,Jl),t=jc(n,t,Jl)}e.memoizedProps=e.pendingProps,t===null?Bu(e):Hl=t}function zu(e,t,n,r){Ui=Hi=null,Do(t),Oa=null,ka=0;var i=t.return;try{if(ec(e,i,t,n,G)){Yl=1,Ys(e,pi(n,e.current)),Hl=null;return}}catch(t){if(i!==null)throw Hl=i,t;Yl=1,Ys(e,pi(n,e.current)),Hl=null;return}t.flags&32768?(Ai||r===1?e=!0:Kl||G&536870912?e=!1:(Gl=e=!0,(r===2||r===9||r===3||r===6)&&(r=$a.current,r!==null&&r.tag===13&&(r.flags|=16384))),Vu(t,e)):Bu(t)}function Bu(e){var t=e;do{if(t.flags&32768){Vu(t,Gl);return}e=t.return;var n=Rc(t.alternate,t,Jl);if(n!==null){Hl=n;return}if(t=t.sibling,t!==null){Hl=t;return}Hl=t=e}while(t!==null);Yl===0&&(Yl=5)}function Vu(e,t){do{var n=zc(e.alternate,e);if(n!==null){n.flags&=32767,Hl=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Hl=e;return}Hl=e=n}while(e!==null);Yl=6,Hl=null}function Hu(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do qu();while(lu!==0);if(Bl&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=Jr,Xe(e,n,o,s,c,l),e===Vl&&(Hl=Vl=null,G=0),du=t,uu=e,fu=n,pu=o,mu=a,hu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,nd(Ae,function(){return Ju(),null})):(e.callbackNode=null,e.callbackPriority=0),r=!!(t.flags&13878),t.subtreeFlags&13878||r){r=P.T,P.T=null,a=F.p,F.p=2,s=Bl,Bl|=4;try{al(e,t,n)}finally{Bl=s,F.p=a,P.T=r}}lu=1,Uu(),Wu(),Gu()}}function Uu(){if(lu===1){lu=0;var e=uu,t=du,n=!!(t.flags&13878);if(t.subtreeFlags&13878||n){n=P.T,P.T=null;var r=F.p;F.p=2;var i=Bl;Bl|=4;try{vl(t,e);var a=Kd,o=Cr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Sr(s.ownerDocument.documentElement,s)){if(c!==null&&wr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=xr(s,h),v=xr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}mp=!!Gd,Kd=Gd=null}finally{Bl=i,F.p=r,P.T=n}}e.current=t,lu=2}}function Wu(){if(lu===2){lu=0;var e=uu,t=du,n=!!(t.flags&8772);if(t.subtreeFlags&8772||n){n=P.T,P.T=null;var r=F.p;F.p=2;var i=Bl;Bl|=4;try{ol(e,t.alternate,t)}finally{Bl=i,F.p=r,P.T=n}}lu=3}}function Gu(){if(lu===4||lu===3){lu=0,Te();var e=uu,t=du,n=fu,r=hu;t.subtreeFlags&10256||t.flags&10256?lu=5:(lu=0,du=uu=null,Ku(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(cu=null),tt(n),t=t.stateNode,Ie&&typeof Ie.onCommitFiberRoot==`function`)try{Ie.onCommitFiberRoot(Fe,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=P.T,i=F.p,F.p=2,P.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{P.T=t,F.p=i}}fu&3&&qu(),ld(e),i=e.pendingLanes,n&261930&&i&42?e===_u?gu++:(gu=0,_u=e):gu=0,ud(0,!1)}}function Ku(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,aa(t)))}function qu(){return Uu(),Wu(),Gu(),Ju()}function Ju(){if(lu!==5)return!1;var e=uu,t=pu;pu=0;var n=tt(fu),r=P.T,a=F.p;try{F.p=32>n?32:n,P.T=null,n=mu,mu=null;var o=uu,s=fu;if(lu=0,du=uu=null,fu=0,Bl&6)throw Error(i(331));var c=Bl;if(Bl|=4,Fl(o.current),Dl(o,o.current,s,n),Bl=c,ud(0,!1),Ie&&typeof Ie.onPostCommitFiberRoot==`function`)try{Ie.onPostCommitFiberRoot(Fe,o)}catch{}return!0}finally{F.p=a,P.T=r,Ku(e,t)}}function Yu(e,t,n){t=pi(n,t),t=Zs(e.stateNode,t,2),e=Ba(e,t,2),e!==null&&(Ye(e,2),ld(e))}function Xu(e,t,n){if(e.tag===3)Yu(e,e,n);else for(;t!==null;){if(t.tag===3){Yu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(cu===null||!cu.has(r))){e=pi(n,e),n=Qs(2),r=Ba(t,n,2),r!==null&&($s(n,r,t,e),Ye(r,2),ld(r));break}}t=t.return}}function Zu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new zl;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(ql=!0,i.add(n),e=Qu.bind(null,e,t,n),t.then(e,e))}function Qu(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Vl===e&&(G&n)===n&&(Yl===4||Yl===3&&(G&62914560)===G&&300>Ee()-iu?!(Bl&2)&&Du(e,0):Ql|=n,eu===G&&(eu=0)),ld(e)}function $u(e,t){t===0&&(t=qe()),e=Qr(e,t),e!==null&&(Ye(e,t),ld(e))}function ed(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),$u(e,n)}function td(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),$u(e,n)}function nd(e,t){return Se(e,t)}var rd=null,id=null,ad=!1,od=!1,sd=!1,cd=0;function ld(e){e!==id&&e.next===null&&(id===null?rd=id=e:id=id.next=e),od=!0,ad||(ad=!0,gd())}function ud(e,t){if(!sd&&od){sd=!0;do for(var n=!1,r=rd;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Re(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,hd(r,a))}else a=G,a=z(r,r===Vl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Ge(r,a)||(n=!0,hd(r,a))}r=r.next}while(n);sd=!1}}function dd(){fd()}function fd(){od=ad=!1;var e=0;cd!==0&&Qd()&&(e=cd);for(var t=Ee(),n=null,r=rd;r!==null;){var i=r.next,a=pd(r,t);a===0?(r.next=null,n===null?rd=i:n.next=i,i===null&&(id=n)):(n=r,(e!==0||a&3)&&(od=!0)),r=i}lu!==0&&lu!==5||ud(e,!1),cd!==0&&(cd=0)}function pd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Re(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Ke(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Vl,n=G,n=z(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Ul===2||Ul===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&Ce(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Ge(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&Ce(r),tt(n)){case 2:case 8:n=ke;break;case 32:n=Ae;break;case 268435456:n=Me;break;default:n=Ae}return r=md.bind(null,e),n=Se(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&Ce(r),e.callbackPriority=2,e.callbackNode=null,2}function md(e,t){if(lu!==0&&lu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(qu()&&e.callbackNode!==n)return null;var r=G;return r=z(e,e===Vl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(xu(e,r,t),pd(e,Ee()),e.callbackNode!=null&&e.callbackNode===n?md.bind(null,e):null)}function hd(e,t){if(qu())return null;xu(e,t,!0)}function gd(){nf(function(){Bl&6?Se(Oe,dd):fd()})}function _d(){if(cd===0){var e=ca;e===0&&(e=He,He<<=1,!(He&261888)&&(He=256)),cd=e}return cd}function vd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:Xt(``+e)}function yd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function bd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=vd((i[ot]||null).action),o=r.submitter;o&&(t=(t=o[ot]||null)?vd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new yn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(cd!==0){var e=o?yd(i,o):new FormData(i);Cs(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?yd(i,o):new FormData(i),Cs(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var xd=0;xd<Ur.length;xd++){var Sd=Ur[xd];Wr(Sd.toLowerCase(),`on`+(Sd[0].toUpperCase()+Sd.slice(1)))}Wr(Ir,`onAnimationEnd`),Wr(Lr,`onAnimationIteration`),Wr(Rr,`onAnimationStart`),Wr(`dblclick`,`onDoubleClick`),Wr(`focusin`,`onFocus`),Wr(`focusout`,`onBlur`),Wr(zr,`onTransitionRun`),Wr(Br,`onTransitionStart`),Wr(Vr,`onTransitionCancel`),Wr(Hr,`onTransitionEnd`),xt(`onMouseEnter`,[`mouseout`,`mouseover`]),xt(`onMouseLeave`,[`mouseout`,`mouseover`]),xt(`onPointerEnter`,[`pointerout`,`pointerover`]),xt(`onPointerLeave`,[`pointerout`,`pointerover`]),bt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),bt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),bt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),bt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),bt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),bt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Cd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),wd=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Cd));function Td(e,t){t=!!(t&4);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Gr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Gr(e)}i.currentTarget=null,a=c}}}}function K(e,t){var n=t[ct];n===void 0&&(n=t[ct]=new Set);var r=e+`__bubble`;n.has(r)||(kd(t,e,2,!1),n.add(r))}function Ed(e,t,n){var r=0;t&&(r|=4),kd(n,e,r,t)}var Dd=`_reactListening`+Math.random().toString(36).slice(2);function Od(e){if(!e[Dd]){e[Dd]=!0,vt.forEach(function(t){t!==`selectionchange`&&(wd.has(t)||Ed(t,!1,e),Ed(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Dd]||(t[Dd]=!0,Ed(`selectionchange`,!1,t))}}function kd(e,t,n,r){switch(xp(t)){case 2:var i=hp;break;case 8:i=gp;break;default:i=_p}n=i.bind(null,t,n,e),i=void 0,!cn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Ad(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var c=r.stateNode.containerInfo;if(c===i)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===i)return;s=s.return}for(;c!==null;){if(s=mt(c),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){r=a=s;continue a}c=c.parentNode}}r=r.return}an(function(){var r=a,i=$t(n),s=[];a:{var c=U.get(e);if(c!==void 0){var l=yn,u=e;switch(e){case`keypress`:if(mn(n)===0)break a;case`keydown`:case`keyup`:l=Ln;break;case`focusin`:u=`focus`,l=On;break;case`focusout`:u=`blur`,l=On;break;case`beforeblur`:case`afterblur`:l=On;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=En;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=Dn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=zn;break;case Ir:case Lr:case Rr:l=kn;break;case Hr:l=Bn;break;case`scroll`:case`scrollend`:l=xn;break;case`wheel`:l=Vn;break;case`copy`:case`cut`:case`paste`:l=An;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Rn;break;case`toggle`:case`beforetoggle`:l=Hn}var d=!!(t&4),f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=on(m,p),g!=null&&d.push(jd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),s.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==Qt&&(u=n.relatedTarget||n.fromElement)&&(mt(u)||u[st]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?mt(u):null,u!==null&&(f=o(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=En,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Rn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:gt(l),h=u==null?c:gt(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,mt(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Nd,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Pd(s,c,l,d,!1),u!==null&&f!==null&&Pd(s,f,u,d,!0)}}a:{if(c=r?gt(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=sr;else if(tr(c)){if(cr)v=H;else{v=hr;var y=mr}}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&qt(r.elementType)&&(v=sr):v=gr;if(v&&=v(e,r)){nr(s,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&zt(c,`number`,c.value)}switch(y=r?gt(r):window,e){case`focusin`:(tr(y)||y.contentEditable===`true`)&&(Er=y,Dr=r,Or=null);break;case`focusout`:Or=Dr=Er=null;break;case`mousedown`:kr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:kr=!1,Ar(s,n,i);break;case`selectionchange`:if(Tr)break;case`keydown`:case`keyup`:Ar(s,n,i)}var b;if(Wn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else V?Xn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(qn&&n.locale!==`ko`&&(V||x!==`onCompositionStart`?x===`onCompositionEnd`&&V&&(b=pn()):(un=i,dn=`value`in un?un.value:un.textContent,V=!0)),y=Md(r,x),0<y.length&&(x=new jn(x,e,null,n,i),s.push({event:x,listeners:y}),b?x.data=b:(b=Zn(n),b!==null&&(x.data=b)))),(b=Kn?Qn(e,n):$n(e,n))&&(x=Md(r,`onBeforeInput`),0<x.length&&(y=new jn(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:y,listeners:x}),y.data=b)),bd(s,e,r,n,i)}Td(s,t)})}function jd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Md(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=on(e,n),i!=null&&r.unshift(jd(e,i,a)),i=on(e,t),i!=null&&r.push(jd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Nd(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Pd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=on(n,a),l!=null&&o.unshift(jd(n,l,c))):i||(l=on(n,a),l!=null&&o.push(jd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Fd=/\r\n?/g,Id=/\u0000|\uFFFD/g;function Ld(e){return(typeof e==`string`?e:``+e).replace(Fd,`
|
|
9
|
+
`).replace(Id,``)}function Rd(e,t){return t=Ld(t),Ld(e)===t}function zd(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Ut(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Ut(e,``+r);break;case`className`:Dt(e,`class`,r);break;case`tabIndex`:Dt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Dt(e,n,r);break;case`style`:Kt(e,r,o);break;case`data`:if(t!==`object`){Dt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Xt(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&zd(e,t,`name`,a.name,a,null),zd(e,t,`formEncType`,a.formEncType,a,null),zd(e,t,`formMethod`,a.formMethod,a,null),zd(e,t,`formTarget`,a.formTarget,a,null)):(zd(e,t,`encType`,a.encType,a,null),zd(e,t,`method`,a.method,a,null),zd(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=Xt(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=Zt);break;case`onScroll`:r!=null&&K(`scroll`,e);break;case`onScrollEnd`:r!=null&&K(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=Xt(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:K(`beforetoggle`,e),K(`toggle`,e),Et(e,`popover`,r);break;case`xlinkActuate`:Ot(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Ot(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Ot(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Ot(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Ot(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Ot(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Ot(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Ot(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Ot(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Et(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=Jt.get(n)||n,Et(e,n,r))}}function Bd(e,t,n,r,a,o){switch(n){case`style`:Kt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Ut(e,r):(typeof r==`number`||typeof r==`bigint`)&&Ut(e,``+r);break;case`onScroll`:r!=null&&K(`scroll`,e);break;case`onScrollEnd`:r!=null&&K(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=Zt);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!yt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[ot]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Et(e,n,r)}}}function Vd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:K(`error`,e),K(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:zd(e,t,o,s,n,null)}}a&&zd(e,t,`srcSet`,n.srcSet,n,null),r&&zd(e,t,`src`,n.src,n,null);return;case`input`:K(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:zd(e,t,r,d,n,null)}}Rt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in K(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:zd(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Bt(e,!!r,n,!0):Bt(e,!!r,t,!1);return;case`textarea`:for(s in K(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:zd(e,t,s,c,n,null)}Ht(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:zd(e,t,l,r,n,null)}return;case`dialog`:K(`beforetoggle`,e),K(`toggle`,e),K(`cancel`,e),K(`close`,e);break;case`iframe`:case`object`:K(`load`,e);break;case`video`:case`audio`:for(r=0;r<Cd.length;r++)K(Cd[r],e);break;case`image`:K(`error`,e),K(`load`,e);break;case`details`:K(`toggle`,e);break;case`embed`:case`source`:case`link`:K(`error`,e),K(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:zd(e,t,u,r,n,null)}return;default:if(qt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Bd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&zd(e,t,c,r,n,null))}function Hd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||zd(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&zd(e,t,p,m,r,f)}}Lt(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||zd(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&zd(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Bt(e,!!n,n?[]:``,!1):Bt(e,!!n,t,!0)):Bt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:zd(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&zd(e,t,s,a,r,o)}Vt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:zd(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:zd(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&zd(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:zd(e,t,u,p,r,m)}return;default:if(qt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Bd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Bd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&zd(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||zd(e,t,f,p,r,m)}function Ud(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Wd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Ud(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Ud(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Gd=null,Kd=null;function qd(e){return e.nodeType===9?e:e.ownerDocument}function Jd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function Yd(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function Xd(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Zd=null;function Qd(){var e=window.event;return e&&e.type===`popstate`?e!==Zd&&(Zd=e,!0):(Zd=null,!1)}var $d=typeof setTimeout==`function`?setTimeout:void 0,ef=typeof clearTimeout==`function`?clearTimeout:void 0,tf=typeof Promise==`function`?Promise:void 0,nf=typeof queueMicrotask==`function`?queueMicrotask:tf===void 0?$d:function(e){return tf.resolve(null).then(e).catch(rf)};function rf(e){setTimeout(function(){throw e})}function af(e){return e===`head`}function of(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Bp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)bf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,bf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[ft]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&bf(e.ownerDocument.body)}n=i}while(n);Bp(t)}function sf(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function cf(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:cf(n),pt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function lf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[ft])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=hf(e.nextSibling),e===null)break}return null}function uf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=hf(e.nextSibling),e===null))return null;return e}function df(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=hf(e.nextSibling),e===null))return null;return e}function ff(e){return e.data===`$?`||e.data===`$~`}function pf(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function mf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function hf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var gf=null;function _f(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return hf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function vf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function yf(e,t,n){switch(t=qd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function bf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);pt(e)}var xf=new Map,Sf=new Set;function Cf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var wf=F.d;F.d={f:Tf,r:Ef,D:kf,C:Af,L:jf,m:Mf,X:Pf,S:Nf,M:Ff};function Tf(){var e=wf.f(),t=Tu();return e||t}function Ef(e){var t=ht(e);t!==null&&t.tag===5&&t.type===`form`?Ts(t):wf.r(e)}var Df=typeof document>`u`?null:document;function Of(e,t,n){var r=Df;if(r&&typeof t==`string`&&t){var i=It(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),Sf.has(i)||(Sf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Vd(t,`link`,e),B(t),r.head.appendChild(t)))}}function kf(e){wf.D(e),Of(`dns-prefetch`,e,null)}function Af(e,t){wf.C(e,t),Of(`preconnect`,e,t)}function jf(e,t,n){wf.L(e,t,n);var r=Df;if(r&&e&&t){var i=`link[rel="preload"][as="`+It(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+It(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+It(n.imageSizes)+`"]`)):i+=`[href="`+It(e)+`"]`;var a=i;switch(t){case`style`:a=Lf(e);break;case`script`:a=Vf(e)}xf.has(a)||(e=m({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),xf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Rf(a))||t===`script`&&r.querySelector(Hf(a))||(t=r.createElement(`link`),Vd(t,`link`,e),B(t),r.head.appendChild(t)))}}function Mf(e,t){wf.m(e,t);var n=Df;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+It(r)+`"][href="`+It(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Vf(e)}if(!xf.has(a)&&(e=m({rel:`modulepreload`,href:e},t),xf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Hf(a)))return}r=n.createElement(`link`),Vd(r,`link`,e),B(r),n.head.appendChild(r)}}}function Nf(e,t,n){wf.S(e,t,n);var r=Df;if(r&&e){var i=_t(r).hoistableStyles,a=Lf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Rf(a)))s.loading=5;else{e=m({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=xf.get(a))&&Gf(e,n);var c=o=r.createElement(`link`);B(c),Vd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Wf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Pf(e,t){wf.X(e,t);var n=Df;if(n&&e){var r=_t(n).hoistableScripts,i=Vf(e),a=r.get(i);a||(a=n.querySelector(Hf(i)),a||(e=m({src:e,async:!0},t),(t=xf.get(i))&&Kf(e,t),a=n.createElement(`script`),B(a),Vd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Ff(e,t){wf.M(e,t);var n=Df;if(n&&e){var r=_t(n).hoistableScripts,i=Vf(e),a=r.get(i);a||(a=n.querySelector(Hf(i)),a||(e=m({src:e,async:!0,type:`module`},t),(t=xf.get(i))&&Kf(e,t),a=n.createElement(`script`),B(a),Vd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function If(e,t,n,r){var a=(a=ce.current)?Cf(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Lf(n.href),n=_t(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Lf(n.href);var o=_t(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Rf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),xf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},xf.set(e,n),o||Bf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Vf(n),n=_t(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Lf(e){return`href="`+It(e)+`"`}function Rf(e){return`link[rel="stylesheet"][`+e+`]`}function zf(e){return m({},e,{"data-precedence":e.precedence,precedence:null})}function Bf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Vd(t,`link`,n),B(t),e.head.appendChild(t))}function Vf(e){return`[src="`+It(e)+`"]`}function Hf(e){return`script[async]`+e}function Uf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+It(n.href)+`"]`);if(r)return t.instance=r,B(r),r;var a=m({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),B(r),Vd(r,`style`,a),Wf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Lf(n.href);var o=e.querySelector(Rf(a));if(o)return t.state.loading|=4,t.instance=o,B(o),o;r=zf(n),(a=xf.get(a))&&Gf(r,a),o=(e.ownerDocument||e).createElement(`link`),B(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Vd(o,`link`,r),t.state.loading|=4,Wf(o,n.precedence,e),t.instance=o;case`script`:return o=Vf(n.src),(a=e.querySelector(Hf(o)))?(t.instance=a,B(a),a):(r=n,(a=xf.get(o))&&(r=m({},n),Kf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),B(a),Vd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Wf(r,n.precedence,e));return t.instance}function Wf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Gf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Kf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var qf=null;function Jf(e,t,n){if(qf===null){var r=new Map,i=qf=new Map;i.set(n,r)}else i=qf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[ft]||a[at]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function Yf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Xf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Zf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Qf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Lf(r.href),a=t.querySelector(Rf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=tp.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,B(a);return}a=t.ownerDocument||t,r=zf(r),(i=xf.get(i))&&Gf(r,i),a=a.createElement(`link`),B(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Vd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=tp.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var $f=0;function ep(e,t){return e.stylesheets&&e.count===0&&rp(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&rp(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&$f===0&&($f=62500*Wd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&rp(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>$f?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function tp(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)rp(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var np=null;function rp(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,np=new Map,t.forEach(ip,e),np=null,tp.call(e))}function ip(e,t){if(!(t.state.loading&4)){var n=np.get(e);if(n)var r=n.get(null);else{n=new Map,np.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=tp.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var ap={$$typeof:C,Provider:null,Consumer:null,_currentValue:ne,_currentValue2:ne,_threadCount:0};function op(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Je(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Je(0),this.hiddenUpdates=Je(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function sp(e,t,n,r,i,a,o,s,c,l,u,d){return e=new op(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ri(3,null,null,t),e.current=a,a.stateNode=e,t=ia(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},La(a),e}function cp(e){return e?(e=ti,e):ti}function lp(e,t,n,r,i,a){i=cp(i),r.context===null?r.context=i:r.pendingContext=i,r=za(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ba(e,r,t),n!==null&&(bu(n,e,t),Va(n,e,t))}function up(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function dp(e,t){up(e,t),(e=e.alternate)&&up(e,t)}function fp(e){if(e.tag===13||e.tag===31){var t=Qr(e,67108864);t!==null&&bu(t,e,67108864),dp(e,67108864)}}function pp(e){if(e.tag===13||e.tag===31){var t=vu();t=et(t);var n=Qr(e,t);n!==null&&bu(n,e,t),dp(e,t)}}var mp=!0;function hp(e,t,n,r){var i=P.T;P.T=null;var a=F.p;try{F.p=2,_p(e,t,n,r)}finally{F.p=a,P.T=i}}function gp(e,t,n,r){var i=P.T;P.T=null;var a=F.p;try{F.p=8,_p(e,t,n,r)}finally{F.p=a,P.T=i}}function _p(e,t,n,r){if(mp){var i=vp(r);if(i===null)Ad(e,t,r,yp,n),Ap(e,r);else if(Mp(i,e,t,n,r))r.stopPropagation();else if(Ap(e,r),t&4&&-1<kp.indexOf(e)){for(;i!==null;){var a=ht(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=R(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Re(o);s.entanglements[1]|=c,o&=~c}ld(a),!(Bl&6)&&(ou=Ee()+500,ud(0,!1))}}break;case 31:case 13:s=Qr(a,2),s!==null&&bu(s,a,2),Tu(),dp(a,2)}if(a=vp(r),a===null&&Ad(e,t,r,yp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Ad(e,t,r,null,n)}}function vp(e){return e=$t(e),bp(e)}var yp=null;function bp(e){if(yp=null,e=mt(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return yp=e,null}function xp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(De()){case Oe:return 2;case ke:return 8;case Ae:case je:return 32;case Me:return 268435456;default:return 32}default:return 32}}var Sp=!1,Cp=null,wp=null,Tp=null,Ep=new Map,Dp=new Map,Op=[],kp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Ap(e,t){switch(e){case`focusin`:case`focusout`:Cp=null;break;case`dragenter`:case`dragleave`:wp=null;break;case`mouseover`:case`mouseout`:Tp=null;break;case`pointerover`:case`pointerout`:Ep.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:Dp.delete(t.pointerId)}}function jp(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=ht(t),t!==null&&fp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Mp(e,t,n,r,i){switch(t){case`focusin`:return Cp=jp(Cp,e,t,n,r,i),!0;case`dragenter`:return wp=jp(wp,e,t,n,r,i),!0;case`mouseover`:return Tp=jp(Tp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Ep.set(a,jp(Ep.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,Dp.set(a,jp(Dp.get(a)||null,e,t,n,r,i)),!0}return!1}function Np(e){var t=mt(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,rt(e.priority,function(){pp(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,rt(e.priority,function(){pp(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Pp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=vp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Qt=r,n.target.dispatchEvent(r),Qt=null}else return t=ht(n),t!==null&&fp(t),e.blockedOn=n,!1;t.shift()}return!0}function Fp(e,t,n){Pp(e)&&n.delete(t)}function Ip(){Sp=!1,Cp!==null&&Pp(Cp)&&(Cp=null),wp!==null&&Pp(wp)&&(wp=null),Tp!==null&&Pp(Tp)&&(Tp=null),Ep.forEach(Fp),Dp.forEach(Fp)}function Lp(e,n){e.blockedOn===n&&(e.blockedOn=null,Sp||(Sp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Ip)))}var Rp=null;function zp(e){Rp!==e&&(Rp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Rp===e&&(Rp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(bp(r||n)===null)continue;break}var a=ht(n);a!==null&&(e.splice(t,3),t-=3,Cs(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Bp(e){function t(t){return Lp(t,e)}Cp!==null&&Lp(Cp,e),wp!==null&&Lp(wp,e),Tp!==null&&Lp(Tp,e),Ep.forEach(t),Dp.forEach(t);for(var n=0;n<Op.length;n++){var r=Op[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Op.length&&(n=Op[0],n.blockedOn===null);)Np(n),n.blockedOn===null&&Op.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[ot]||null;if(typeof a==`function`)o||zp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[ot]||null)s=o.formAction;else if(bp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),zp(n)}}}function Vp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Hp(e){this._internalRoot=e}Up.prototype.render=Hp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;lp(n,vu(),e,t,null,null)},Up.prototype.unmount=Hp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;lp(e.current,2,null,e,null,null),Tu(),t[st]=null}};function Up(e){this._internalRoot=e}Up.prototype.unstable_scheduleHydration=function(e){if(e){var t=nt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Op.length&&t!==0&&t<Op[n].priority;n++);Op.splice(n,0,e),n===0&&Np(e)}};var Wp=n.version;if(Wp!==`19.2.8`)throw Error(i(527,Wp,`19.2.8`));F.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:f(e),e=e===null?null:e.stateNode,e};var Gp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:P,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Kp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Kp.isDisabled&&Kp.supportsFiber)try{Fe=Kp.inject(Gp),Ie=Kp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Ks,s=qs,c=Js;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=sp(e,1,!1,null,null,n,r,null,o,s,c,Vp),e[st]=t.current,Od(e),new Hp(t)}})),_=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=g()})),v=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(){}},y=new class extends v{#e;#t;#n;constructor(){super(),this.#n=e=>{if(typeof window<`u`&&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`}},b={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},x=new class{#e=b;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 S(e){setTimeout(e,0)}var C=typeof window>`u`||`Deno`in globalThis;function w(){}function T(e,t){return typeof e==`function`?e(t):e}function E(e){return typeof e==`number`&&e>=0&&e!==1/0}function ee(e,t){return Math.max(e+(t||0)-Date.now(),0)}function D(e,t){return typeof e==`function`?e(t):e}function O(e,t){return typeof e==`function`?e(t):e}function k(e,t){let{type:n=`all`,exact:r,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(r){if(t.queryHash!==j(o,t.options))return!1}else if(!N(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 A(e,t){let{exact:n,status:r,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(n){if(M(t.options.mutationKey)!==M(a))return!1}else if(!N(t.options.mutationKey,a))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function j(e,t){return(t?.queryKeyHashFn||M)(e)}function M(e){return JSON.stringify(e,(e,t)=>re(t)?Object.keys(t).sort().reduce((e,n)=>(e[n]=t[n],e),{}):t)}function N(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(e&&t&&typeof e==`object`&&typeof t==`object`){if(Array.isArray(e)&&Array.isArray(t)){for(let n=0;n<t.length;n++)if(!N(e[n],t[n]))return!1;return!0}let n=Object.keys(t);for(let r of n)if(!N(e[r],t[r]))return!1;return!0}return!1}var te=Object.prototype.hasOwnProperty;function P(e,t,n=0){if(e===t)return e;if(n>500)return t;let r=ne(e)&&ne(t);if(!r&&!(re(e)&&re(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:te.call(e,o))&&c++;continue}if(u===null||d===null||typeof u!=`object`||typeof d!=`object`){s[o]=d;continue}let f=P(u,d,n+1);s[o]=f,f===u&&c++}return i===o&&c===i?e:s}function F(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 ne(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function re(e){if(!ie(e))return!1;let t=e.constructor;if(t===void 0)return!0;let n=t.prototype;return!(!ie(n)||!n.hasOwnProperty(`isPrototypeOf`)||Object.getPrototypeOf(e)!==Object.prototype)}function ie(e){return Object.prototype.toString.call(e)===`[object Object]`}function ae(e){return new Promise(t=>{x.setTimeout(t,e)})}function I(e,t,n){return typeof n.structuralSharing==`function`?n.structuralSharing(e,t):n.structuralSharing===!1?t:P(e,t)}function L(e,t,n=0){let r=[...e,t];return n&&r.length>n?r.slice(1):r}function oe(e,t,n=0){let r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var se=Symbol();function ce(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===se?()=>Promise.reject(Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function le(e,t){return typeof e==`function`?e(...t):!!e}function ue(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 de=(()=>{let e=()=>C;return{isServer(){return e()},setIsServer(t){e=t}}})();function fe(){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 pe=S;function me(){let e=[],t=0,n=e=>{e()},r=e=>{e()},i=pe,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 he=me(),ge=new class extends v{#e=!0;#t;#n;constructor(){super(),this.#n=e=>{if(typeof window<`u`&&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 _e(e){return Math.min(1e3*2**e,3e4)}function ve(e){return(e??`online`)!==`online`||ge.isOnline()}var ye=class extends Error{constructor(e){super(`CancelledError`),this.revert=e?.revert,this.silent=e?.silent}};function be(e){let t=!1,n=0,r,i=fe(),a=()=>i.status!==`pending`,o=t=>{if(!a()){let n=new ye(t);f(n),e.onCancel?.(n)}},s=()=>{t=!0},c=()=>{t=!1},l=()=>y.isFocused()&&(e.networkMode===`always`||ge.isOnline())&&e.canRun(),u=()=>ve(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??(de.isServer()?0:3),o=e.retryDelay??_e,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),ae(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 xe=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),E(this.gcTime)&&(this.#e=x.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(de.isServer()?1/0:3e5))}clearGcTimeout(){this.#e!==void 0&&(x.clearTimeout(this.#e),this.#e=void 0)}};function Se(e){return{onFetch:(t,n)=>{let r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,a=t.state.data?.pages||[],o=t.state.data?.pageParams||[],s={pages:[],pageParams:[]},c=0,l=async()=>{let n=!1,l=e=>{ue(e,()=>t.signal,()=>n=!0)},u=ce(t.options,t.fetchOptions),d=async(e,r,i)=>{if(n)return Promise.reject(t.signal.reason);if(r==null&&e.pages.length)return Promise.resolve(e);let a=(()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:r,direction:i?`backward`:`forward`,meta:t.options.meta};return l(e),e})(),o=await u(a),{maxPages:s}=t.options,c=i?oe:L;return{pages:c(e.pages,o,s),pageParams:c(e.pageParams,r,s)}};if(i&&a.length){let e=i===`backward`,t=e?we:Ce,n={pages:a,pageParams:o};s=await d(n,t(r,n),e)}else{let t=e??a.length;do{let e=c===0?o[0]??r.initialPageParam:Ce(r,s);if(c>0&&e==null)break;s=await d(s,e),c++}while(c<t)}return s};t.fetchFn=t.options.persister?()=>t.options.persister?.(l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):l}}}function Ce(e,{pages:t,pageParams:n}){let r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function we(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}var Te=class extends xe{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e){super(),this.#s=!1,this.#o=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#i=e.client,this.#r=this.#i.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#t=Oe(this.options),this.state=e.state??this.#t,this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return this.#e}get promise(){return this.#a?.promise}setOptions(e){if(this.options={...this.#o,...e},e?._type&&(this.#e=e._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){let e=Oe(this.options);e.data!==void 0&&(this.setState(De(e.data,e.dataUpdatedAt)),this.#t=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus===`idle`&&this.#r.remove(this)}setData(e,t){let n=I(this.state.data,e,this.options);return this.#l({data:n,type:`success`,dataUpdatedAt:t?.updatedAt,manual:t?.manual}),n}setState(e){this.#l({type:`setState`,state:e})}cancel(e){let t=this.#a?.promise;return this.#a?.cancel(e),t?t.then(w).catch(w):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return this.#t}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(e=>O(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===se||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0&&this.observers.some(e=>D(e.options.staleTime,this)===`static`)}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:!ee(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(e=>e.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#a?.continue()}onOnline(){this.observers.find(e=>e.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#a?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#r.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.#a&&(this.#s||this.#c()?this.#a.cancel({revert:!0}):this.#a.cancelRetry()),this.scheduleGc()),this.#r.notify({type:`observerRemoved`,query:this,observer:e}))}getObserversCount(){return this.observers.length}#c(){return this.state.fetchStatus===`paused`&&this.state.status===`pending`}invalidate(){this.state.isInvalidated||this.#l({type:`invalidate`})}async fetch(e,t){if(this.state.fetchStatus!==`idle`&&this.#a?.status()!==`rejected`){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#a)return this.#a.continueRetry(),this.#a.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.#s=!0,n.signal)})},i=()=>{let e=ce(this.options,t),n=(()=>{let e={client:this.#i,queryKey:this.queryKey,meta:this.meta};return r(e),e})();return this.#s=!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.#i,state:this.state,fetchFn:i};return r(e),e})();(this.#e===`infinite`?Se(this.options.pages):this.options.behavior)?.onFetch(a,this),this.#n=this.state,(this.state.fetchStatus===`idle`||this.state.fetchMeta!==a.fetchOptions?.meta)&&this.#l({type:`fetch`,meta:a.fetchOptions?.meta}),this.#a=be({initialPromise:t?.initialPromise,fn:a.fetchFn,onCancel:e=>{e instanceof ye&&e.revert&&this.setState({...this.#n,fetchStatus:`idle`}),n.abort()},onFail:(e,t)=>{this.#l({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#l({type:`pause`})},onContinue:()=>{this.#l({type:`continue`})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0});try{let e=await this.#a.start();if(e===void 0)throw Error(`${this.queryHash} data is undefined`);return this.setData(e),this.#r.config.onSuccess?.(e,this),this.#r.config.onSettled?.(e,this.state.error,this),e}catch(e){if(e instanceof ye){if(e.silent)return this.#a.promise;if(e.revert){if(this.state.data===void 0)throw e;return this.state.data}}throw this.#l({type:`error`,error:e}),this.#r.config.onError?.(e,this),this.#r.config.onSettled?.(this.state.data,e,this),e}finally{this.scheduleGc()}}#l(e){let t=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,...Ee(t.data,this.options),fetchMeta:e.meta??null};case`success`:let n={...t,...De(e.data,e.dataUpdatedAt),dataUpdateCount:t.dataUpdateCount+1,...!e.manual&&{fetchStatus:`idle`,fetchFailureCount:0,fetchFailureReason:null}};return this.#n=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=t(this.state),he.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),this.#r.notify({query:this,type:`updated`,action:e})})}};function Ee(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:ve(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}function De(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:`success`}}function Oe(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 ke=class extends v{constructor(e,t){super(),this.options=t,this.#e=e,this.#s=null,this.#o=fe(),this.bindMethods(),this.setOptions(t)}#e;#t=void 0;#n=void 0;#r=void 0;#i;#a;#o;#s;#c;#l;#u;#d;#f;#p;#m=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),je(this.#t,this.options)?this.#h():this.updateResult(),this.#y())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Me(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Me(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#b(),this.#x(),this.#t.removeObserver(this)}setOptions(e){let t=this.options,n=this.#t;if(this.options=this.#e.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!=`boolean`&&typeof this.options.enabled!=`function`&&typeof O(this.options.enabled,this.#t)!=`boolean`)throw Error(`Expected enabled to be a boolean or a callback that returns a boolean`);this.#S(),this.#t.setOptions(this.options),t._defaulted&&!F(this.options,t)&&this.#e.getQueryCache().notify({type:`observerOptionsUpdated`,query:this.#t,observer:this});let r=this.hasListeners();r&&Ne(this.#t,n,this.options,t)&&this.#h(),this.updateResult(),r&&(this.#t!==n||O(this.options.enabled,this.#t)!==O(t.enabled,this.#t)||D(this.options.staleTime,this.#t)!==D(t.staleTime,this.#t))&&this.#g();let i=this.#_();r&&(this.#t!==n||O(this.options.enabled,this.#t)!==O(t.enabled,this.#t)||i!==this.#p)&&this.#v(i)}getOptimisticResult(e){let t=this.#e.getQueryCache().build(this.#e,e),n=this.createResult(t,e);return Fe(this,n)&&(this.#r=n,this.#a=this.options,this.#i=this.#t.state),n}getCurrentResult(){return this.#r}trackResult(e,t){return new Proxy(e,{get:(e,n)=>(this.trackProp(n),t?.(n),n===`promise`&&(this.trackProp(`data`),!this.options.experimental_prefetchInRender&&this.#o.status===`pending`&&this.#o.reject(Error(`experimental_prefetchInRender feature flag is not enabled`))),Reflect.get(e,n))})}trackProp(e){this.#m.add(e)}getCurrentQuery(){return this.#t}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){let t=this.#e.defaultQueryOptions(e),n=this.#e.getQueryCache().build(this.#e,t);return n.fetch().then(()=>this.createResult(n,t))}fetch(e){return this.#h({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#r))}#h(e){this.#S();let t=this.#t.fetch(this.options,e);return e?.throwOnError||(t=t.catch(w)),t}#g(){this.#b();let e=D(this.options.staleTime,this.#t);if(de.isServer()||this.#r.isStale||!E(e))return;let t=ee(this.#r.dataUpdatedAt,e)+1;this.#d=x.setTimeout(()=>{this.#r.isStale||this.updateResult()},t)}#_(){return(typeof this.options.refetchInterval==`function`?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(e){this.#x(),this.#p=e,!(de.isServer()||O(this.options.enabled,this.#t)===!1||!E(this.#p)||this.#p===0)&&(this.#f=x.setInterval(()=>{(this.options.refetchIntervalInBackground||y.isFocused())&&this.#h()},this.#p))}#y(){this.#g(),this.#v(this.#_())}#b(){this.#d!==void 0&&(x.clearTimeout(this.#d),this.#d=void 0)}#x(){this.#f!==void 0&&(x.clearInterval(this.#f),this.#f=void 0)}createResult(e,t){let n=this.#t,r=this.options,i=this.#r,a=this.#i,o=this.#a,s=e===n?this.#n:e.state,{state:c}=e,l={...c},u=!1,d;if(t._optimisticResults){let i=this.hasListeners(),a=!i&&je(e,t),o=i&&Ne(e,n,t,r);(a||o)&&(l={...l,...Ee(c.data,e.options)}),t._optimisticResults===`isRestoring`&&(l.fetchStatus=`idle`)}let{error:f,errorUpdatedAt:p,status:m}=l;d=l.data;let h=!1;if(t.placeholderData!==void 0&&d===void 0&&m===`pending`){let e;i?.isPlaceholderData&&t.placeholderData===o?.placeholderData?(e=i.data,h=!0):e=typeof t.placeholderData==`function`?t.placeholderData(this.#u?.state.data,this.#u):t.placeholderData,e!==void 0&&(m=`success`,d=I(i?.data,e,t),u=!0)}if(t.select&&d!==void 0&&!h){if(i&&d===a?.data&&t.select===this.#c)d=this.#l;else try{this.#c=t.select,d=t.select(d),d=I(i?.data,d,t),this.#l=d,this.#s=null}catch(e){this.#s=e}}this.#s&&(f=this.#s,d=this.#l,p=Date.now(),m=`error`);let g=l.fetchStatus===`fetching`,_=m===`pending`,v=m===`error`,y=_&&g,b=d!==void 0,x={status:m,fetchStatus:l.fetchStatus,isPending:_,isSuccess:m===`success`,isError:v,isInitialLoading:y,isLoading:y,data:d,dataUpdatedAt:l.dataUpdatedAt,error:f,errorUpdatedAt:p,failureCount:l.fetchFailureCount,failureReason:l.fetchFailureReason,errorUpdateCount:l.errorUpdateCount,isFetched:e.isFetched(),isFetchedAfterMount:l.dataUpdateCount>s.dataUpdateCount||l.errorUpdateCount>s.errorUpdateCount,isFetching:g,isRefetching:g&&!_,isLoadingError:v&&!b,isPaused:l.fetchStatus===`paused`,isPlaceholderData:u,isRefetchError:v&&b,isStale:Pe(e,t),refetch:this.refetch,promise:this.#o,isEnabled:O(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){let t=x.data!==void 0,r=x.status===`error`&&!t,i=e=>{r?e.reject(x.error):t&&e.resolve(x.data)},a=()=>{let e=this.#o=x.promise=fe();i(e)},o=this.#o;switch(o.status){case`pending`:e.queryHash===n.queryHash&&i(o);break;case`fulfilled`:(r||x.data!==o.value)&&a();break;case`rejected`:(!r||x.error!==o.reason)&&a()}}return x}updateResult(){let e=this.#r,t=this.createResult(this.#t,this.options);this.#i=this.#t.state,this.#a=this.options,this.#i.data!==void 0&&(this.#u=this.#t),!F(t,e)&&(this.#r=t,this.#C({listeners:(()=>{if(!e)return!0;let{notifyOnChangeProps:t}=this.options,n=typeof t==`function`?t():t;if(n===`all`||!n&&!this.#m.size)return!0;let r=new Set(n??this.#m);return this.options.throwOnError&&r.add(`error`),Object.keys(this.#r).some(t=>{let n=t;return this.#r[n]!==e[n]&&r.has(n)})})()}))}#S(){let e=this.#e.getQueryCache().build(this.#e,this.options);if(e===this.#t)return;let t=this.#t;this.#t=e,this.#n=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#y()}#C(e){he.batch(()=>{e.listeners&&this.listeners.forEach(e=>{e(this.#r)}),this.#e.getQueryCache().notify({query:this.#t,type:`observerResultsUpdated`})})}};function Ae(e,t){return O(t.enabled,e)!==!1&&e.state.data===void 0&&(e.state.status!==`error`||O(t.retryOnMount,e)!==!1)}function je(e,t){return Ae(e,t)||e.state.data!==void 0&&Me(e,t,t.refetchOnMount)}function Me(e,t,n){if(O(t.enabled,e)!==!1&&D(t.staleTime,e)!==`static`){let r=typeof n==`function`?n(e):n;return r===`always`||r!==!1&&Pe(e,t)}return!1}function Ne(e,t,n,r){return(e!==t||O(r.enabled,e)===!1)&&(!n.suspense||e.state.status!==`error`)&&Pe(e,n)}function Pe(e,t){return O(t.enabled,e)!==!1&&e.isStaleByTime(D(t.staleTime,e))}function Fe(e,t){return!F(e.getCurrentResult(),t)}var Ie=class extends xe{#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||Le(),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=be({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){let t=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=t(this.state),he.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:`updated`,action:e})})}};function Le(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:`idle`,variables:void 0,submittedAt:0}}var Re=class extends v{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,t,n){let r=new Ie({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){this.#e.add(e);let t=ze(e);if(typeof t==`string`){let n=this.#t.get(t);n?n.push(e):this.#t.set(t,[e])}this.notify({type:`added`,mutation:e})}remove(e){if(this.#e.delete(e)){let t=ze(e);if(typeof t==`string`){let n=this.#t.get(t);if(n){if(n.length>1){let t=n.indexOf(e);t!==-1&&n.splice(t,1)}else n[0]===e&&this.#t.delete(t)}}}this.notify({type:`removed`,mutation:e})}canRun(e){let t=ze(e);if(typeof t==`string`){let n=this.#t.get(t)?.find(e=>e.state.status===`pending`);return!n||n===e}return!0}runNext(e){let t=ze(e);return typeof t==`string`?(this.#t.get(t)?.find(t=>t!==e&&t.state.isPaused))?.continue()??Promise.resolve():Promise.resolve()}clear(){he.batch(()=>{this.#e.forEach(e=>{this.notify({type:`removed`,mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){let t={exact:!0,...e};return this.getAll().find(e=>A(t,e))}findAll(e={}){return this.getAll().filter(t=>A(e,t))}notify(e){he.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){let e=this.getAll().filter(e=>e.state.isPaused);return he.batch(()=>Promise.all(e.map(e=>e.continue().catch(w))))}};function ze(e){return e.options.scope?.id}var Be=class extends v{#e;#t=void 0;#n;#r;constructor(e,t){super(),this.#e=e,this.setOptions(t),this.bindMethods(),this.#i()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){let t=this.options;this.options=this.#e.defaultMutationOptions(e),F(this.options,t)||this.#e.getMutationCache().notify({type:`observerOptionsUpdated`,mutation:this.#n,observer:this}),t?.mutationKey&&this.options.mutationKey&&M(t.mutationKey)!==M(this.options.mutationKey)?this.reset():this.#n?.state.status===`pending`&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(e){this.#i(),this.#a(e)}getCurrentResult(){return this.#t}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#i(),this.#a()}mutate(e,t){return this.#r=t,this.#n?.removeObserver(this),this.#n=this.#e.getMutationCache().build(this.#e,this.options),this.#n.addObserver(this),this.#n.execute(e)}#i(){let e=this.#n?.state??Le();this.#t={...e,isPending:e.status===`pending`,isSuccess:e.status===`success`,isError:e.status===`error`,isIdle:e.status===`idle`,mutate:this.mutate,reset:this.reset}}#a(e){he.batch(()=>{if(this.#r&&this.hasListeners()){let t=this.#t.variables,n=this.#t.context,r={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};if(e?.type===`success`){try{this.#r.onSuccess?.(e.data,t,n,r)}catch(e){Promise.reject(e)}try{this.#r.onSettled?.(e.data,null,t,n,r)}catch(e){Promise.reject(e)}}else if(e?.type===`error`){try{this.#r.onError?.(e.error,t,n,r)}catch(e){Promise.reject(e)}try{this.#r.onSettled?.(void 0,e.error,t,n,r)}catch(e){Promise.reject(e)}}}this.listeners.forEach(e=>{e(this.#t)})})}},Ve=class extends v{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,t,n){let r=t.queryKey,i=t.queryHash??j(r,t),a=this.get(i);return a||(a=new Te({client:e,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(a)),a}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:`added`,query:e}))}remove(e){let t=this.#e.get(e.queryHash);t&&(e.destroy(),t===e&&this.#e.delete(e.queryHash),this.notify({type:`removed`,query:e}))}clear(){he.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){let t={exact:!0,...e};return this.getAll().find(e=>k(t,e))}findAll(e={}){let t=this.getAll();return Object.keys(e).length>0?t.filter(t=>k(e,t)):t}notify(e){he.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){he.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){he.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},He=class{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e={}){this.#e=e.queryCache||new Ve,this.#t=e.mutationCache||new Re,this.#n=e.defaultOptions||{},this.#r=new Map,this.#i=new Map,this.#a=0}mount(){this.#a++,this.#a===1&&(this.#o=y.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#s=ge.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#a--,this.#a===0&&(this.#o?.(),this.#o=void 0,this.#s?.(),this.#s=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:`fetching`}).length}isMutating(e){return this.#t.findAll({...e,status:`pending`}).length}getQueryData(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state.data}ensureQueryData(e){let t=this.defaultQueryOptions(e),n=this.#e.build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(D(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,n){let r=this.defaultQueryOptions({queryKey:e}),i=this.#e.get(r.queryHash)?.state.data,a=T(t,i);if(a!==void 0)return this.#e.build(this,r).setData(a,{...n,manual:!0})}setQueriesData(e,t,n){return he.batch(()=>this.#e.findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,n)]))}getQueryState(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state}removeQueries(e){let t=this.#e;he.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){let n=this.#e;return he.batch(()=>(n.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries({type:`active`,...e},t)))}cancelQueries(e,t={}){let n={revert:!0,...t},r=he.batch(()=>this.#e.findAll(e).map(e=>e.cancel(n)));return Promise.all(r).then(w).catch(w)}invalidateQueries(e,t={}){return he.batch(()=>(this.#e.findAll(e).forEach(e=>{e.invalidate()}),e?.refetchType===`none`?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??`active`},t)))}refetchQueries(e,t={}){let n={...t,cancelRefetch:t.cancelRefetch??!0},r=he.batch(()=>this.#e.findAll(e).filter(e=>!e.isDisabled()&&!e.isStatic()).map(e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(w)),e.state.fetchStatus===`paused`?Promise.resolve():t}));return Promise.all(r).then(w)}fetchQuery(e){let t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);let n=this.#e.build(this,t);return n.isStaleByTime(D(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(w).catch(w)}fetchInfiniteQuery(e){return e._type=`infinite`,this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(w).catch(w)}ensureInfiniteQueryData(e){return e._type=`infinite`,this.ensureQueryData(e)}resumePausedMutations(){return ge.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#r.set(M(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){let t=[...this.#r.values()],n={};return t.forEach(t=>{N(e,t.queryKey)&&Object.assign(n,t.defaultOptions)}),n}setMutationDefaults(e,t){this.#i.set(M(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){let t=[...this.#i.values()],n={};return t.forEach(t=>{N(e,t.mutationKey)&&Object.assign(n,t.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;let t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||=j(t.queryKey,t),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!==`always`),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode=`offlineFirst`),t.queryFn===se&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},Ue=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})),We=o(((e,t)=>{t.exports=Ue()})),R=l(d(),1),z=We(),Ge=R.createContext(void 0),Ke=e=>{let t=R.useContext(Ge);if(e)return e;if(!t)throw Error(`No QueryClient set, use QueryClientProvider to set one`);return t},qe=({client:e,children:t})=>(R.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),(0,z.jsx)(Ge.Provider,{value:e,children:t})),Je=R.createContext(!1),Ye=()=>R.useContext(Je);Je.Provider;function Xe(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var Ze=R.createContext(Xe()),Qe=()=>R.useContext(Ze),$e=(e,t,n)=>{let r=n?.state.error&&typeof e.throwOnError==`function`?le(e.throwOnError,[n.state.error,n]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||r)&&(t.isReset()||(e.retryOnMount=!1))},et=e=>{R.useEffect(()=>{e.clearReset()},[e])},tt=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(i&&e.data===void 0||le(n,[e.error,r])),nt=e=>{if(e.suspense){let t=1e3,n=e=>e===`static`?e:Math.max(e??t,t),r=e.staleTime;e.staleTime=typeof r==`function`?(...e)=>n(r(...e)):n(r),typeof e.gcTime==`number`&&(e.gcTime=Math.max(e.gcTime,t))}},rt=(e,t)=>e.isLoading&&e.isFetching&&!t,it=(e,t)=>e?.suspense&&t.isPending,at=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function ot(e,t,n){let r=Ye(),i=Qe(),a=Ke(n),o=a.defaultQueryOptions(e);a.getDefaultOptions().queries?._experimental_beforeQuery?.(o);let s=a.getQueryCache().get(o.queryHash),c=e.subscribed!==!1;o._optimisticResults=r?`isRestoring`:c?`optimistic`:void 0,nt(o),$e(o,i,s),et(i);let l=!a.getQueryCache().get(o.queryHash),[u]=R.useState(()=>new t(a,o)),d=u.getOptimisticResult(o),f=!r&&c;if(R.useSyncExternalStore(R.useCallback(e=>{let t=f?u.subscribe(he.batchCalls(e)):w;return u.updateResult(),t},[u,f]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),R.useEffect(()=>{u.setOptions(o)},[o,u]),it(o,d))throw at(o,u,i);if(tt({result:d,errorResetBoundary:i,throwOnError:o.throwOnError,query:s,suspense:o.suspense}))throw d.error;return a.getDefaultOptions().queries?._experimental_afterQuery?.(o,d),o.experimental_prefetchInRender&&!de.isServer()&&rt(d,r)&&(l?at(o,u,i):s?.promise)?.catch(w).finally(()=>{u.updateResult()}),o.notifyOnChangeProps?d:u.trackResult(d)}function st(e,t){return ot(e,ke,t)}function ct(e,t){let n=Ke(t),[r]=R.useState(()=>new Be(n,e));R.useEffect(()=>{r.setOptions(e)},[r,e]);let i=R.useSyncExternalStore(R.useCallback(e=>r.subscribe(he.batchCalls(e)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),a=R.useCallback((e,t)=>{r.mutate(e,t).catch(w)},[r]);if(i.error&&le(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:a,mutateAsync:i.mutate}}var lt=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),ut=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),dt=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),ft=e=>{let t=dt(e);return t.charAt(0).toUpperCase()+t.slice(1)},pt={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`},mt=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},ht=(0,R.createContext)({}),gt=()=>(0,R.useContext)(ht),_t=(0,R.forwardRef)(({color:e,size:t,strokeWidth:n,absoluteStrokeWidth:r,className:i=``,children:a,iconNode:o,...s},c)=>{let{size:l=24,strokeWidth:u=2,absoluteStrokeWidth:d=!1,color:f=`currentColor`,className:p=``}=gt()??{},m=r??d?Number(n??u)*24/Number(t??l):n??u;return(0,R.createElement)(`svg`,{ref:c,...pt,width:t??l??pt.width,height:t??l??pt.height,stroke:e??f,strokeWidth:m,className:lt(`lucide`,p,i),...!a&&!mt(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,R.createElement)(e,t)),...Array.isArray(a)?a:[a]])}),B=(e,t)=>{let n=(0,R.forwardRef)(({className:n,...r},i)=>(0,R.createElement)(_t,{ref:i,iconNode:t,className:lt(`lucide-${ut(ft(e))}`,`lucide-${e}`,n),...r}));return n.displayName=ft(e),n},vt=B(`arrow-down`,[[`path`,{d:`M12 5v14`,key:`s699le`}],[`path`,{d:`m19 12-7 7-7-7`,key:`1idqje`}]]),yt=B(`arrow-left`,[[`path`,{d:`m12 19-7-7 7-7`,key:`1l729n`}],[`path`,{d:`M19 12H5`,key:`x3x0zl`}]]),bt=B(`arrow-up-down`,[[`path`,{d:`m21 16-4 4-4-4`,key:`f6ql7i`}],[`path`,{d:`M17 20V4`,key:`1ejh1v`}],[`path`,{d:`m3 8 4-4 4 4`,key:`11wl7u`}],[`path`,{d:`M7 4v16`,key:`1glfcx`}]]),xt=B(`arrow-up`,[[`path`,{d:`m5 12 7-7 7 7`,key:`hav0vg`}],[`path`,{d:`M12 19V5`,key:`x0mq9r`}]]),St=B(`baseline`,[[`path`,{d:`M4 20h16`,key:`14thso`}],[`path`,{d:`m6 16 6-12 6 12`,key:`1b4byz`}],[`path`,{d:`M8 12h8`,key:`1wcyev`}]]),Ct=B(`bold`,[[`path`,{d:`M6 12h9a4 4 0 0 1 0 8H7a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h7a4 4 0 0 1 0 8`,key:`mg9rjx`}]]),wt=B(`bot`,[[`path`,{d:`M12 8V4H8`,key:`hb8ula`}],[`rect`,{width:`16`,height:`12`,x:`4`,y:`8`,rx:`2`,key:`enze0r`}],[`path`,{d:`M2 14h2`,key:`vft8re`}],[`path`,{d:`M20 14h2`,key:`4cs60a`}],[`path`,{d:`M15 13v2`,key:`1xurst`}],[`path`,{d:`M9 13v2`,key:`rq6x2g`}]]),Tt=B(`calendar`,[[`path`,{d:`M8 2v3`,key:`1ioesn`}],[`path`,{d:`M16 2v3`,key:`otl347`}],[`rect`,{x:`3`,y:`3`,width:`18`,height:`18`,rx:`2`,key:`h1oib`}],[`path`,{d:`M3 9h18`,key:`1pudct`}]]),Et=B(`chart-column`,[[`path`,{d:`M3 3v16a2 2 0 0 0 2 2h16`,key:`c24i48`}],[`path`,{d:`M18 17V9`,key:`2bz60n`}],[`path`,{d:`M13 17V5`,key:`1frdt8`}],[`path`,{d:`M8 17v-3`,key:`17ska0`}]]),Dt=B(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),Ot=B(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),kt=B(`chevron-left`,[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]),At=B(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),jt=B(`chevron-up`,[[`path`,{d:`m18 15-6-6-6 6`,key:`153udz`}]]),Mt=B(`chevrons-up-down`,[[`path`,{d:`m7 15 5 5 5-5`,key:`1hf1tw`}],[`path`,{d:`m7 9 5-5 5 5`,key:`sgt6xg`}]]),Nt=B(`circle-alert`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`line`,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,key:`1pkeuh`}],[`line`,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,key:`4dfq90`}]]),Pt=B(`circle-check`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),Ft=B(`code-xml`,[[`path`,{d:`m18 16 4-4-4-4`,key:`1inbqp`}],[`path`,{d:`m6 8-4 4 4 4`,key:`15zrgr`}],[`path`,{d:`m14.5 4-5 16`,key:`e7oirm`}]]),It=B(`contact-round`,[[`path`,{d:`M16 2v2`,key:`scm5qe`}],[`path`,{d:`M17.915 21a6 6 0 10-12 0`,key:`13n4mv`}],[`path`,{d:`M8 2v2`,key:`pbkmx`}],[`circle`,{cx:`12`,cy:`11`,r:`4`,key:`1gt34v`}],[`rect`,{x:`3`,y:`3`,width:`18`,height:`18`,rx:`2`,key:`h1oib`}]]),Lt=B(`copy`,[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),Rt=B(`database`,[[`ellipse`,{cx:`12`,cy:`5`,rx:`9`,ry:`3`,key:`msslwz`}],[`path`,{d:`M3 5V19A9 3 0 0 0 21 19V5`,key:`1wlel7`}],[`path`,{d:`M3 12A9 3 0 0 0 21 12`,key:`mv7ke4`}]]),zt=B(`download`,[[`path`,{d:`M12 15V3`,key:`m9g1x1`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}],[`path`,{d:`m7 10 5 5 5-5`,key:`brsn70`}]]),Bt=B(`ellipsis`,[[`circle`,{cx:`12`,cy:`12`,r:`1`,key:`41hilf`}],[`circle`,{cx:`19`,cy:`12`,r:`1`,key:`1wjl8i`}],[`circle`,{cx:`5`,cy:`12`,r:`1`,key:`1pcz8c`}]]),Vt=B(`external-link`,[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]),Ht=B(`eye`,[[`path`,{d:`M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0`,key:`1nclc0`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),Ut=B(`file-text`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 9H8`,key:`b1mrlr`}],[`path`,{d:`M16 13H8`,key:`t4e002`}],[`path`,{d:`M16 17H8`,key:`z1uh3a`}]]),Wt=B(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),Gt=B(`globe`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20`,key:`13o1zl`}],[`path`,{d:`M2 12h20`,key:`9i4pu4`}]]),Kt=B(`highlighter`,[[`path`,{d:`m9 11-6 6v3h9l3-3`,key:`1a3l36`}],[`path`,{d:`m22 12-4.6 4.6a2 2 0 0 1-2.8 0l-5.2-5.2a2 2 0 0 1 0-2.8L14 4`,key:`14a9rk`}]]),qt=B(`house`,[[`path`,{d:`M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8`,key:`5wwlr5`}],[`path`,{d:`M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,key:`r6nss1`}]]),Jt=B(`image-plus`,[[`path`,{d:`M16 5h6`,key:`1vod17`}],[`path`,{d:`M19 2v6`,key:`4bpg5p`}],[`path`,{d:`M21 11.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7.5`,key:`1ue2ih`}],[`path`,{d:`m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21`,key:`1xmnt7`}],[`circle`,{cx:`9`,cy:`9`,r:`2`,key:`af1f0g`}]]),Yt=B(`image`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,ry:`2`,key:`1m3agn`}],[`circle`,{cx:`9`,cy:`9`,r:`2`,key:`af1f0g`}],[`path`,{d:`m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21`,key:`1xmnt7`}]]),Xt=B(`images`,[[`path`,{d:`m22 11-1.296-1.296a2.4 2.4 0 0 0-3.408 0L11 16`,key:`9kzy35`}],[`path`,{d:`M4 8a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2`,key:`1t0f0t`}],[`circle`,{cx:`13`,cy:`7`,r:`1`,fill:`currentColor`,key:`1obus6`}],[`rect`,{x:`8`,y:`2`,width:`14`,height:`14`,rx:`2`,key:`1gvhby`}]]),Zt=B(`info`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 16v-4`,key:`1dtifu`}],[`path`,{d:`M12 8h.01`,key:`e9boi3`}]]),Qt=B(`italic`,[[`line`,{x1:`19`,x2:`10`,y1:`4`,y2:`4`,key:`15jd3p`}],[`line`,{x1:`14`,x2:`5`,y1:`20`,y2:`20`,key:`bu0au3`}],[`line`,{x1:`15`,x2:`9`,y1:`4`,y2:`20`,key:`uljnxc`}]]),$t=B(`languages`,[[`path`,{d:`m5 8 6 6`,key:`1wu5hv`}],[`path`,{d:`m4 14 6-6 2-3`,key:`1k1g8d`}],[`path`,{d:`M2 5h12`,key:`or177f`}],[`path`,{d:`M7 2h1`,key:`1t2jsx`}],[`path`,{d:`m22 22-5-10-5 10`,key:`don7ne`}],[`path`,{d:`M14 18h6`,key:`1m8k6r`}]]),en=B(`link`,[[`path`,{d:`M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71`,key:`1cjeqo`}],[`path`,{d:`M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71`,key:`19qd67`}]]),tn=B(`list-checks`,[[`path`,{d:`M13 5h8`,key:`a7qcls`}],[`path`,{d:`M13 12h8`,key:`h98zly`}],[`path`,{d:`M13 19h8`,key:`c3s6r1`}],[`path`,{d:`m3 17 2 2 4-4`,key:`1jhpwq`}],[`path`,{d:`m3 7 2 2 4-4`,key:`1obspn`}]]),nn=B(`list-indent-increase`,[[`path`,{d:`M21 5H11`,key:`us1j55`}],[`path`,{d:`M21 12H11`,key:`wd7e0v`}],[`path`,{d:`M21 19H11`,key:`saa85w`}],[`path`,{d:`m3 8 4 4-4 4`,key:`1a3j6y`}]]),rn=B(`list-ordered`,[[`path`,{d:`M11 5h10`,key:`1cz7ny`}],[`path`,{d:`M11 12h10`,key:`1438ji`}],[`path`,{d:`M11 19h10`,key:`11t30w`}],[`path`,{d:`M4 4h1v5`,key:`10yrso`}],[`path`,{d:`M4 9h2`,key:`r1h2o0`}],[`path`,{d:`M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02`,key:`xtkcd5`}]]),an=B(`list`,[[`path`,{d:`M3 5h.01`,key:`18ugdj`}],[`path`,{d:`M3 12h.01`,key:`nlz23k`}],[`path`,{d:`M3 19h.01`,key:`noohij`}],[`path`,{d:`M8 5h13`,key:`1pao27`}],[`path`,{d:`M8 12h13`,key:`1za7za`}],[`path`,{d:`M8 19h13`,key:`m83p4d`}]]),on=B(`loader-circle`,[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]]),sn=B(`lock-keyhole`,[[`circle`,{cx:`12`,cy:`16`,r:`1`,key:`1au0dj`}],[`rect`,{x:`3`,y:`10`,width:`18`,height:`12`,rx:`2`,key:`6s8ecr`}],[`path`,{d:`M7 10V7a5 5 0 0 1 10 0v3`,key:`1pqi11`}]]),cn=B(`log-out`,[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]),ln=B(`mail-warning`,[[`path`,{d:`M22 10.5V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12.5`,key:`e61zoh`}],[`path`,{d:`m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7`,key:`1ocrg3`}],[`path`,{d:`M20 14v4`,key:`1hm744`}],[`path`,{d:`M20 22v.01`,key:`12bgn6`}]]),un=B(`monitor`,[[`rect`,{width:`20`,height:`14`,x:`2`,y:`3`,rx:`2`,key:`48i651`}],[`line`,{x1:`8`,x2:`16`,y1:`21`,y2:`21`,key:`1svkeh`}],[`line`,{x1:`12`,x2:`12`,y1:`17`,y2:`21`,key:`vw1qmm`}]]),dn=B(`moon`,[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]),fn=B(`octagon-x`,[[`path`,{d:`m15 9-6 6`,key:`1uzhvr`}],[`path`,{d:`M2.586 16.726A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2h6.624a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586z`,key:`2d38gg`}],[`path`,{d:`m9 9 6 6`,key:`z0biqf`}]]),pn=B(`palette`,[[`path`,{d:`M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z`,key:`e79jfc`}],[`circle`,{cx:`13.5`,cy:`6.5`,r:`.5`,fill:`currentColor`,key:`1okk4w`}],[`circle`,{cx:`17.5`,cy:`10.5`,r:`.5`,fill:`currentColor`,key:`f64h9f`}],[`circle`,{cx:`6.5`,cy:`12.5`,r:`.5`,fill:`currentColor`,key:`qy21gx`}],[`circle`,{cx:`8.5`,cy:`7.5`,r:`.5`,fill:`currentColor`,key:`fotxhn`}]]),mn=B(`panel-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}]]),hn=B(`pencil-line`,[[`path`,{d:`M13 21h8`,key:`1jsn5i`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}],[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}]]),gn=B(`pilcrow`,[[`path`,{d:`M13 4v16`,key:`8vvj80`}],[`path`,{d:`M17 4v16`,key:`7dpous`}],[`path`,{d:`M19 4H9.5a4.5 4.5 0 0 0 0 9H13`,key:`sh4n9v`}]]),_n=B(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),vn=B(`redo-2`,[[`path`,{d:`m15 14 5-5-5-5`,key:`12vg1m`}],[`path`,{d:`M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13`,key:`6uklza`}]]),yn=B(`rotate-ccw`,[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}]]),bn=B(`save`,[[`path`,{d:`M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z`,key:`1c8476`}],[`path`,{d:`M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7`,key:`1ydtos`}],[`path`,{d:`M7 3v4a1 1 0 0 0 1 1h7`,key:`t51u73`}]]),xn=B(`search`,[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]),Sn=B(`send`,[[`path`,{d:`M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z`,key:`1ffxy3`}],[`path`,{d:`m21.854 2.147-10.94 10.939`,key:`12cjpa`}]]),Cn=B(`settings-2`,[[`path`,{d:`M14 17H5`,key:`gfn3mx`}],[`path`,{d:`M19 7h-9`,key:`6i9tg`}],[`circle`,{cx:`17`,cy:`17`,r:`3`,key:`18b49y`}],[`circle`,{cx:`7`,cy:`7`,r:`3`,key:`dfmy0x`}]]),wn=B(`settings`,[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]),Tn=B(`strikethrough`,[[`path`,{d:`M16 4H9a3 3 0 0 0-2.83 4`,key:`43sutm`}],[`path`,{d:`M14 12a4 4 0 0 1 0 8H6`,key:`nlfj13`}],[`line`,{x1:`4`,x2:`20`,y1:`12`,y2:`12`,key:`1e0a9i`}]]),En=B(`sun`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]),Dn=B(`table-2`,[[`path`,{d:`M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18`,key:`gugj83`}]]),On=B(`text-align-center`,[[`path`,{d:`M21 5H3`,key:`1fi0y6`}],[`path`,{d:`M17 12H7`,key:`16if0g`}],[`path`,{d:`M19 19H5`,key:`vjpgq2`}]]),kn=B(`text-align-end`,[[`path`,{d:`M21 5H3`,key:`1fi0y6`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M21 19H7`,key:`4cu937`}]]),An=B(`text-align-start`,[[`path`,{d:`M21 5H3`,key:`1fi0y6`}],[`path`,{d:`M15 12H3`,key:`6jk70r`}],[`path`,{d:`M17 19H3`,key:`z6ezky`}]]),jn=B(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),Mn=B(`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`}]]),Nn=B(`type`,[[`path`,{d:`M12 4v16`,key:`1654pz`}],[`path`,{d:`M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2`,key:`e0r10z`}],[`path`,{d:`M9 20h6`,key:`s66wpe`}]]),Pn=B(`underline`,[[`path`,{d:`M6 4v6a6 6 0 0 0 12 0V4`,key:`9kb039`}],[`line`,{x1:`4`,x2:`20`,y1:`20`,y2:`20`,key:`nun2al`}]]),Fn=B(`undo-2`,[[`path`,{d:`M9 14 4 9l5-5`,key:`102s5s`}],[`path`,{d:`M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11`,key:`f3b9sd`}]]),In=B(`upload`,[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]),Ln=B(`user-plus`,[[`path`,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,key:`1yyitq`}],[`circle`,{cx:`9`,cy:`7`,r:`4`,key:`nufk8`}],[`line`,{x1:`19`,x2:`19`,y1:`8`,y2:`14`,key:`1bvyxn`}],[`line`,{x1:`22`,x2:`16`,y1:`11`,y2:`11`,key:`1shjgl`}]]),Rn=B(`users`,[[`path`,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,key:`1yyitq`}],[`path`,{d:`M16 3.128a4 4 0 0 1 0 7.744`,key:`16gr8j`}],[`path`,{d:`M22 21v-2a4 4 0 0 0-3-3.87`,key:`kshegd`}],[`circle`,{cx:`9`,cy:`7`,r:`4`,key:`nufk8`}]]),zn=B(`video`,[[`path`,{d:`m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5`,key:`ftymec`}],[`rect`,{x:`2`,y:`6`,width:`14`,height:`12`,rx:`2`,key:`158x01`}]]),Bn=B(`wand-sparkles`,[[`path`,{d:`m21.64 3.64-1.28-1.28a1.21 1.21 0 0 0-1.72 0L2.36 18.64a1.21 1.21 0 0 0 0 1.72l1.28 1.28a1.2 1.2 0 0 0 1.72 0L21.64 5.36a1.2 1.2 0 0 0 0-1.72`,key:`ul74o6`}],[`path`,{d:`m14 7 3 3`,key:`1r5n42`}],[`path`,{d:`M5 6v4`,key:`ilb8ba`}],[`path`,{d:`M19 14v4`,key:`blhpug`}],[`path`,{d:`M10 2v2`,key:`7u0qdc`}],[`path`,{d:`M7 8H3`,key:`zfb6yr`}],[`path`,{d:`M21 16h-4`,key:`1cnmox`}],[`path`,{d:`M11 3H9`,key:`1obp7u`}]]),Vn=B(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),Hn=l(_(),1);function Un(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=Un(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n)}return r}function Wn(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Un(e))&&(r&&(r+=` `),r+=t);return r}var Gn=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,Kn=Wn,qn=(e,t)=>n=>{if(t?.variants==null)return Kn(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=Gn(t)||Gn(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 Kn(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)},Jn=Object.defineProperty,Yn=(e,t)=>Jn(e,`name`,{value:t,configurable:!0});function Xn(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}Yn(Xn,`setRef`);function Zn(...e){return t=>{let n=!1,r=e.map(e=>{let r=Xn(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():Xn(e[t],null)}}}}Yn(Zn,`composeRefs`);function V(...e){return R.useCallback(Zn(...e),e)}Yn(V,`useComposedRefs`);var Qn=Object.defineProperty,$n=(e,t)=>Qn(e,`name`,{value:t,configurable:!0});function er(e){let t=R.forwardRef((t,n)=>{let{children:r,...i}=t,a=null,o=!1,s=[];lr(r)&&typeof pr==`function`&&(r=pr(r._payload)),R.Children.forEach(r,e=>{if(sr(e)){o=!0;let t=e,n=`child`in t.props?t.props.child:t.props.children;lr(n)&&typeof pr==`function`&&(n=pr(n._payload)),a=ir(t,n),s.push(a?.props?.children)}else s.push(e)}),a?a=R.cloneElement(a,void 0,s):!o&&R.Children.count(r)===1&&R.isValidElement(r)&&(a=r);let c=a?or(a):void 0,l=V(n,c);if(!a){if(r||r===0)throw Error(o?fr(e):dr(e));return r}let u=ar(i,a.props??{});return a.type!==R.Fragment&&(u.ref=n?l:c),R.cloneElement(a,u)});return t.displayName=`${e}.Slot`,t}$n(er,`createSlot`);var tr=er(`Slot`),nr=Symbol.for(`radix.slottable`);function rr(e){let t=$n(e=>`child`in e?e.children(e.child):e.children,`Slottable`);return t.displayName=`${e}.Slottable`,t.__radixId=nr,t}$n(rr,`createSlottable`);var ir=$n((e,t)=>{if(`child`in e.props){let t=e.props.child;return R.isValidElement(t)?R.cloneElement(t,void 0,e.props.children(t.props.children)):null}return R.isValidElement(t)?t:null},`getSlottableElementFromSlottable`);function ar(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}}$n(ar,`mergeProps`);function or(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)}$n(or,`getElementRef`);function sr(e){return R.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===nr}$n(sr,`isSlottable`);var cr=Symbol.for(`react.lazy`);function lr(e){return typeof e==`object`&&!!e&&`$$typeof`in e&&e.$$typeof===cr&&`_payload`in e&&ur(e._payload)}$n(lr,`isLazyComponent`);function ur(e){return typeof e==`object`&&!!e&&`then`in e}$n(ur,`isPromiseLike`);var dr=$n(e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,`createSlotError`),fr=$n(e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,`createSlottableError`),pr=R.use,mr=l(h(),1),hr=Object.defineProperty,gr=(e,t)=>hr(e,`name`,{value:t,configurable:!0}),H=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=er(`Primitive.${t}`),r=R.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,z.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function _r(e,t){e&&mr.flushSync(()=>e.dispatchEvent(t))}gr(_r,`dispatchDiscreteCustomEvent`);var vr=Object.defineProperty,yr=(e,t)=>vr(e,`name`,{value:t,configurable:!0}),br=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`}),xr=R.forwardRef(yr(function(e,t){return(0,z.jsx)(H.span,{...e,ref:t,style:{...br,...e.style}})},`VisuallyHidden`)),Sr=Object.defineProperty,Cr=(e,t)=>Sr(e,`name`,{value:t,configurable:!0});function wr(e,t){let n=R.createContext(t);n.displayName=e+`Context`;let r=Cr(e=>{let{children:t,...r}=e,i=R.useMemo(()=>r,Object.values(r));return(0,z.jsx)(n.Provider,{value:i,children:t})},`Provider`);r.displayName=e+`Provider`;function i(r,i={}){let{optional:a=!1}=i,o=R.useContext(n);if(o)return o;if(t!==void 0)return t;if(!a)throw Error(`\`${r}\` must be used within \`${e}\``)}return Cr(i,`useContext`),[r,i]}Cr(wr,`createContext`);function Tr(e,t=[]){let n=[];function r(t,r){let i=R.createContext(r);i.displayName=t+`Context`;let a=n.length;n=[...n,r];let o=Cr(t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=R.useMemo(()=>o,Object.values(o));return(0,z.jsx)(s.Provider,{value:c,children:r})},`Provider`);o.displayName=t+`Provider`;function s(n,o,s={}){let{optional:c=!1}=s,l=o?.[e]?.[a]||i,u=R.useContext(l);if(u)return u;if(r!==void 0)return r;if(!c)throw Error(`\`${n}\` must be used within \`${t}\``)}return Cr(s,`useContext`),[o,s]}Cr(r,`createContext`);let i=Cr(()=>{let t=n.map(e=>R.createContext(e));return Cr(function(n){let r=n?.[e]||t;return R.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])},`useScope`)},`createScope`);return i.scopeName=e,[r,Er(i,...t)]}Cr(Tr,`createContextScope`);function Er(...e){let t=e[0];if(e.length===1)return t;let n=Cr(()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return Cr(function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return R.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])},`useComposedScopes`)},`createScope`);return n.scopeName=t.scopeName,n}Cr(Er,`composeContextScopes`);var Dr=Object.defineProperty,Or=(e,t)=>Dr(e,`name`,{value:t,configurable:!0});function kr(e){let t=e+`CollectionProvider`,[n,r]=Tr(t),[i,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=Or(e=>{let{scope:t,children:n}=e,r=R.useRef(null),a=R.useRef(new Map).current;return(0,z.jsx)(i,{scope:t,itemMap:a,collectionRef:r,children:n})},`CollectionProvider`);o.displayName=t;let s=e+`CollectionSlot`,c=er(s),l=R.forwardRef((e,t)=>{let{scope:n,children:r}=e,i=V(t,a(s,n).collectionRef);return(0,z.jsx)(c,{ref:i,children:r})});l.displayName=s;let u=e+`CollectionItemSlot`,d=`data-radix-collection-item`,f=er(u),p=R.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=R.useRef(null),s=V(t,o),c=a(u,n);return R.useEffect(()=>(c.itemMap.set(o,{ref:o,...i}),()=>void c.itemMap.delete(o))),(0,z.jsx)(f,{[d]:``,ref:s,children:r})});p.displayName=u;function m(t){let n=a(e+`CollectionConsumer`,t);return R.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${d}]`));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])}return Or(m,`useCollection`),[{Provider:o,Slot:l,ItemSlot:p},m,r]}Or(kr,`createCollection`);var Ar=new WeakMap,jr=class e extends Map{static{Or(this,`OrderedDict`)}#e;constructor(e){super(e),this.#e=[...super.keys()],Ar.set(this,!0)}set(e,t){return Ar.get(this)&&(this.has(e)?this.#e[this.#e.indexOf(e)]=e:this.#e.push(e)),super.set(e,t),this}insert(e,t,n){let r=this.has(t),i=this.#e.length,a=Pr(e),o=a>=0?a:i+a,s=o<0||o>=i?-1:o;if(s===this.size||r&&s===this.size-1||s===-1)return this.set(t,n),this;let c=this.size+ +!r;a<0&&o++;let l=[...this.#e],u,d=!1;for(let e=o;e<c;e++)if(o===e){let i=l[e];l[e]===t&&(i=l[e+1]),r&&this.delete(t),u=this.get(i),this.set(t,n)}else{!d&&l[e-1]===t&&(d=!0);let n=l[d?e:e-1],r=u;u=this.get(n),this.delete(n),this.set(n,r)}return this}with(t,n,r){let i=new e(this);return i.insert(t,n,r),i}before(e){let t=this.#e.indexOf(e)-1;if(!(t<0))return this.entryAt(t)}setBefore(e,t,n){let r=this.#e.indexOf(e);return r===-1?this:this.insert(r,t,n)}after(e){let t=this.#e.indexOf(e);if(t=t===-1||t===this.size-1?-1:t+1,t!==-1)return this.entryAt(t)}setAfter(e,t,n){let r=this.#e.indexOf(e);return r===-1?this:this.insert(r+1,t,n)}first(){return this.entryAt(0)}last(){return this.entryAt(-1)}clear(){return this.#e=[],super.clear()}delete(e){let t=super.delete(e);return t&&this.#e.splice(this.#e.indexOf(e),1),t}deleteAt(e){let t=this.keyAt(e);return t!==void 0&&this.delete(t)}at(e){let t=Mr(this.#e,e);if(t!==void 0)return this.get(t)}entryAt(e){let t=Mr(this.#e,e);if(t!==void 0)return[t,this.get(t)]}indexOf(e){return this.#e.indexOf(e)}keyAt(e){return Mr(this.#e,e)}from(e,t){let n=this.indexOf(e);if(n===-1)return;let r=n+t;return r<0&&(r=0),r>=this.size&&(r=this.size-1),this.at(r)}keyFrom(e,t){let n=this.indexOf(e);if(n===-1)return;let r=n+t;return r<0&&(r=0),r>=this.size&&(r=this.size-1),this.keyAt(r)}find(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return r;n++}}findIndex(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return n;n++}return-1}filter(t,n){let r=[],i=0;for(let e of this)Reflect.apply(t,n,[e,i,this])&&r.push(e),i++;return new e(r)}map(t,n){let r=[],i=0;for(let e of this)r.push([e[0],Reflect.apply(t,n,[e,i,this])]),i++;return new e(r)}reduce(...e){let[t,n]=e,r=0,i=n??this.at(0);for(let n of this)i=r===0&&e.length===1?n:Reflect.apply(t,this,[i,n,r,this]),r++;return i}reduceRight(...e){let[t,n]=e,r=n??this.at(-1);for(let n=this.size-1;n>=0;n--){let i=this.at(n);r=n===this.size-1&&e.length===1?i:Reflect.apply(t,this,[r,i,n,this])}return r}toSorted(t){let n=[...this.entries()].sort(t);return new e(n)}toReversed(){let t=new e;for(let e=this.size-1;e>=0;e--){let n=this.keyAt(e),r=this.get(n);t.set(n,r)}return t}toSpliced(...t){let n=[...this.entries()];return n.splice(...t),new e(n)}slice(t,n){let r=new e,i=this.size-1;if(t===void 0)return r;t<0&&(t+=this.size),n!==void 0&&n>0&&(i=n-1);for(let e=t;e<=i;e++){let t=this.keyAt(e),n=this.get(t);r.set(t,n)}return r}every(e,t){let n=0;for(let r of this){if(!Reflect.apply(e,t,[r,n,this]))return!1;n++}return!0}some(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return!0;n++}return!1}};function Mr(e,t){if(`at`in Array.prototype)return Array.prototype.at.call(e,t);let n=Nr(e,t);return n===-1?void 0:e[n]}Or(Mr,`at`);function Nr(e,t){let n=e.length,r=Pr(t),i=r>=0?r:n+r;return i<0||i>=n?-1:i}Or(Nr,`toSafeIndex`);function Pr(e){return e!==e||e===0?0:Math.trunc(e)}Or(Pr,`toSafeInteger`);function Fr(e){let t=e+`CollectionProvider`,[n,r]=Tr(t),[i,a]=n(t,{collectionElement:null,collectionRef:{current:null},collectionRefObject:{current:null},itemMap:new jr,setItemMap:Or(()=>void 0,`setItemMap`)}),o=Or(({state:e,...t})=>e?(0,z.jsx)(c,{...t,state:e}):(0,z.jsx)(s,{...t}),`CollectionProvider`);o.displayName=t;let s=Or(e=>{let t=h();return(0,z.jsx)(c,{...e,state:t})},`CollectionInit`);s.displayName=t+`Init`;let c=Or(e=>{let{scope:t,children:n,state:r}=e,a=R.useRef(null),[o,s]=R.useState(null),c=V(a,s),[l,u]=r;return R.useEffect(()=>{if(!o)return;let e=zr(()=>{});return e.observe(o,{childList:!0,subtree:!0}),()=>{e.disconnect()}},[o]),(0,z.jsx)(i,{scope:t,itemMap:l,setItemMap:u,collectionRef:c,collectionRefObject:a,collectionElement:o,children:n})},`CollectionProviderImpl`);c.displayName=t+`Impl`;let l=e+`CollectionSlot`,u=er(l),d=R.forwardRef((e,t)=>{let{scope:n,children:r}=e,i=V(t,a(l,n).collectionRef);return(0,z.jsx)(u,{ref:i,children:r})});d.displayName=l;let f=e+`CollectionItemSlot`,p=er(f),m=R.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=R.useRef(null),[s,c]=R.useState(null),l=V(t,o,c),{setItemMap:u}=a(f,n),d=R.useRef(i);Ir(d.current,i)||(d.current=i);let m=d.current;return R.useEffect(()=>{let e=m;return u(t=>s?t.has(s)?t.set(s,{...e,element:s}).toSorted(Rr):(t.set(s,{...e,element:s}),t.toSorted(Rr)):t),()=>{u(e=>!s||!e.has(s)?e:(e.delete(s),new jr(e)))}},[s,m,u]),(0,z.jsx)(p,{"data-radix-collection-item":``,ref:l,children:r})});m.displayName=f;function h(){return R.useState(new jr)}Or(h,`useInitCollection`);function g(t){let{itemMap:n}=a(e+`CollectionConsumer`,t);return n}return Or(g,`useCollection`),[{Provider:o,Slot:d,ItemSlot:m},{createCollectionScope:r,useCollection:g,useInitCollection:h}]}Or(Fr,`createCollection`);function Ir(e,t){if(e===t)return!0;if(typeof e!=`object`||typeof t!=`object`||e==null||t==null)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let r of n)if(!Object.prototype.hasOwnProperty.call(t,r)||e[r]!==t[r])return!1;return!0}Or(Ir,`shallowEqual`);function Lr(e,t){return!!(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_PRECEDING)}Or(Lr,`isElementPreceding`);function Rr(e,t){return!e[1].element||!t[1].element?0:Lr(e[1].element,t[1].element)?-1:1}Or(Rr,`sortByDocumentPosition`);function zr(e){return new MutationObserver(t=>{for(let n of t)if(n.type===`childList`){e();return}})}Or(zr,`getChildListObserver`);var Br=Object.defineProperty,Vr=(e,t)=>Br(e,`name`,{value:t,configurable:!0}),Hr=!!(typeof window<`u`&&window.document&&window.document.createElement);function U(e,t,{checkForDefaultPrevented:n=!0}={}){return Vr(function(r){if(e?.(r),n===!1||!r||!r.defaultPrevented)return t?.(r)},`handleEvent`)}Vr(U,`composeEventHandlers`);function Ur(e){if(!Hr)throw Error(`Cannot access window outside of the DOM`);return e?.ownerDocument?.defaultView??window}Vr(Ur,`getOwnerWindow`);function Wr(e){if(!Hr)throw Error(`Cannot access document outside of the DOM`);return e?.ownerDocument??document}Vr(Wr,`getOwnerDocument`);function Gr(e,t=!1){let{activeElement:n}=Wr(e);if(!n?.nodeName)return null;if(Kr(n)&&n.contentDocument)return Gr(n.contentDocument.body,t);if(t){let e=n.getAttribute(`aria-activedescendant`);if(e){let t=Wr(n).getElementById(e);if(t)return t}}return n}Vr(Gr,`getActiveElement`);function Kr(e){return e.tagName===`IFRAME`}Vr(Kr,`isFrame`);var qr=globalThis?.document?R.useLayoutEffect:()=>{},Jr=Object.defineProperty,Yr=(e,t)=>Jr(e,`name`,{value:t,configurable:!0}),Xr=R.useEffectEvent,Zr=R.useInsertionEffect;function Qr(e){if(typeof Xr==`function`)return Xr(e);let t=R.useRef(()=>{throw Error(`Cannot call an event handler while rendering.`)});return typeof Zr==`function`?Zr(()=>{t.current=e}):qr(()=>{t.current=e}),R.useMemo(()=>((...e)=>t.current?.(...e)),[])}Yr(Qr,`useEffectEvent`);var $r=Object.defineProperty,ei=(e,t)=>$r(e,`name`,{value:t,configurable:!0}),ti=R.useInsertionEffect||qr;function ni({prop:e,defaultProp:t,onChange:n=ei(()=>{},`onChange`),caller:r}){let[i,a,o]=ri({defaultProp:t,onChange:n}),s=e!==void 0;return[s?e:i,R.useCallback(t=>{if(s){let n=ii(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}ei(ni,`useControllableState`);function ri({defaultProp:e,onChange:t}){let[n,r]=R.useState(e),i=R.useRef(n),a=R.useRef(t);return ti(()=>{a.current=t},[t]),R.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}ei(ri,`useUncontrolledState`);function ii(e){return typeof e==`function`}ei(ii,`isFunction`);var ai=Symbol(`RADIX:SYNC_STATE`);function oi(e,t,n,r){let{prop:i,defaultProp:a,onChange:o,caller:s}=t,c=i!==void 0,l=Qr(o),u=[{...n,state:a}];r&&u.push(r);let[d,f]=R.useReducer((t,n)=>{if(n.type===ai)return{...t,state:n.state};let r=e(t,n);return c&&!Object.is(r.state,t.state)&&l(r.state),r},...u),p=d.state,m=R.useRef(p);R.useEffect(()=>{m.current!==p&&(m.current=p,c||l(p))},[p,m,c]);let h=R.useMemo(()=>i===void 0?d:{...d,state:i},[d,i]);return R.useEffect(()=>{c&&!Object.is(i,d.state)&&f({type:ai,state:i})},[i,d.state,c]),[h,f]}ei(oi,`useControllableStateReducer`);var si=Object.defineProperty,ci=(e,t)=>si(e,`name`,{value:t,configurable:!0});function li(e,t){return R.useReducer((e,n)=>t[e][n]??e,e)}ci(li,`useStateMachine`);var ui=ci(e=>{let{present:t,children:n}=e,r=di(t),i=typeof n==`function`?n({present:r.isPresent}):R.Children.only(n),a=pi(r.ref,hi(i));return typeof n==`function`||r.isPresent?R.cloneElement(i,{ref:a}):null},`Presence`);function di(e){let[t,n]=R.useState(),r=R.useRef(null),i=R.useRef(e),a=R.useRef(`none`),o=R.useRef(void 0),[s,c]=li(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return R.useEffect(()=>{s===`mounted`?(a.current=o.current??mi(r.current),o.current=void 0):a.current=`none`},[s]),qr(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,s=mi(t);e?(o.current=s,c(`MOUNT`)):s===`none`||t?.display===`none`?c(`UNMOUNT`):c(n&&r!==s?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,c]),qr(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=ci(a=>{let o=mi(r.current).includes(CSS.escape(a.animationName));if(a.target===t&&o&&(c(`ANIMATION_END`),!i.current)){let r=t.style.animationFillMode;t.style.animationFillMode=`forwards`,e=n.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=r)})}},`handleAnimationEnd`),s=ci(e=>{e.target===t&&(a.current=mi(r.current))},`handleAnimationStart`);return t.addEventListener(`animationstart`,s),t.addEventListener(`animationcancel`,o),t.addEventListener(`animationend`,o),()=>{n.clearTimeout(e),t.removeEventListener(`animationstart`,s),t.removeEventListener(`animationcancel`,o),t.removeEventListener(`animationend`,o)}}c(`ANIMATION_END`)},[t,c]),{isPresent:[`mounted`,`unmountSuspended`].includes(s),ref:R.useCallback(e=>{if(e){let t=getComputedStyle(e);r.current=t,o.current=mi(t)}else r.current=null;n(e)},[])}}ci(di,`usePresence`);function fi(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}ci(fi,`setRef`);function pi(...e){let t=R.useRef(e);return t.current=e,R.useCallback(e=>{let n=t.current,r=!1,i=n.map(t=>{let n=fi(t,e);return!r&&typeof n==`function`&&(r=!0),n});if(r)return()=>{for(let e=0;e<i.length;e++){let t=i[e];typeof t==`function`?t():fi(n[e],null)}}},[])}ci(pi,`useStableComposedRefs`);function mi(e){return e?.animationName||`none`}ci(mi,`getAnimationName`);function hi(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)}ci(hi,`getElementRef`);var gi=Object.defineProperty,_i=(e,t)=>gi(e,`name`,{value:t,configurable:!0}),vi=R.useId||(()=>void 0),yi=0;function bi(e){let[t,n]=R.useState(vi());return qr(()=>{e||n(e=>e??String(yi++))},[e]),e||(t?`radix-${t}`:``)}_i(bi,`useId`);var xi=Object.defineProperty,Si=(e,t)=>xi(e,`name`,{value:t,configurable:!0}),Ci=`Collapsible`,[wi,Ti]=Tr(Ci),[Ei,Di]=wi(Ci),Oi=R.forwardRef(Si(function(e,t){let{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:a,onOpenChange:o,...s}=e,[c,l]=ni({prop:r,defaultProp:i??!1,onChange:o,caller:Ci});return(0,z.jsx)(Ei,{scope:n,disabled:a,contentId:bi(),open:c,onOpenToggle:R.useCallback(()=>l(e=>!e),[l]),children:(0,z.jsx)(H.div,{"data-state":Pi(c),"data-disabled":a?``:void 0,...s,ref:t})})},`Collapsible`)),ki=`CollapsibleTrigger`,Ai=R.forwardRef(Si(function(e,t){let{__scopeCollapsible:n,...r}=e,i=Di(ki,n);return(0,z.jsx)(H.button,{type:`button`,"aria-controls":i.open?i.contentId:void 0,"aria-expanded":i.open||!1,"data-state":Pi(i.open),"data-disabled":i.disabled?``:void 0,disabled:i.disabled,...r,ref:t,onClick:U(e.onClick,i.onOpenToggle)})},`CollapsibleTrigger`)),ji=`CollapsibleContent`,Mi=R.forwardRef(Si(function(e,t){let{forceMount:n,...r}=e,i=Di(ji,e.__scopeCollapsible);return(0,z.jsx)(ui,{present:n||i.open,children:({present:e})=>(0,z.jsx)(Ni,{...r,ref:t,present:e})})},`CollapsibleContent`)),Ni=R.forwardRef(Si(function(e,t){let{__scopeCollapsible:n,present:r,children:i,...a}=e,o=Di(ji,n),[s,c]=R.useState(r),l=R.useRef(null),u=V(t,l),d=R.useRef(0),f=d.current,p=R.useRef(0),m=p.current,h=o.open||s,g=R.useRef(h),_=R.useRef(void 0);return R.useEffect(()=>{let e=requestAnimationFrame(()=>g.current=!1);return()=>cancelAnimationFrame(e)},[]),qr(()=>{let e=l.current;if(e){_.current=_.current||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration=`0s`,e.style.animationName=`none`;let t=e.getBoundingClientRect();d.current=t.height,p.current=t.width,g.current||(e.style.transitionDuration=_.current.transitionDuration,e.style.animationName=_.current.animationName),c(r)}},[o.open,r]),(0,z.jsx)(H.div,{"data-state":Pi(o.open),"data-disabled":o.disabled?``:void 0,id:o.contentId,hidden:!h,...a,ref:u,style:{"--radix-collapsible-content-height":f?`${f}px`:void 0,"--radix-collapsible-content-width":m?`${m}px`:void 0,...e.style},children:h&&i})},`CollapsibleContentImpl`));function Pi(e){return e?`open`:`closed`}Si(Pi,`getState`);var Fi=Oi,Ii=Object.defineProperty,Li=(e,t)=>Ii(e,`name`,{value:t,configurable:!0}),Ri=R.createContext(void 0);function zi(e){let t=R.useContext(Ri);return e||t||`ltr`}Li(zi,`useDirection`);var Bi=Object.defineProperty,Vi=(e,t)=>Bi(e,`name`,{value:t,configurable:!0});function Hi(e){let t=R.useRef(e);return R.useEffect(()=>{t.current=e}),R.useMemo(()=>((...e)=>t.current?.(...e)),[])}Vi(Hi,`useCallbackRef`);var Ui=Object.defineProperty,Wi=(e,t)=>Ui(e,`name`,{value:t,configurable:!0}),Gi=`dismissableLayer.update`,Ki=`dismissableLayer.pointerDownOutside`,qi=`dismissableLayer.focusOutside`,Ji,Yi=R.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),Xi=R.forwardRef(Wi(function(e,t){let{disableOutsidePointerEvents:n=!1,deferPointerDownOutside:r=!1,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:s,onDismiss:c,...l}=e,u=R.useContext(Yi),[d,f]=R.useState(null),p=d?.ownerDocument??globalThis?.document,[,m]=R.useState({}),h=V(t,f),g=Array.from(u.layers),[_]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),v=_?g.indexOf(_):-1,y=d?g.indexOf(d):-1,b=u.layersWithOutsidePointerEventsDisabled.size>0,x=y>=v,S=R.useRef(!1),C=$i(e=>{a?.(e),s?.(e),e.defaultPrevented||c?.()},{ownerDocument:p,deferPointerDownOutside:r,isDeferredPointerDownOutsideRef:S,dismissableSurfaces:u.dismissableSurfaces,shouldHandlePointerDownOutside:R.useCallback(e=>{if(!(e instanceof Node))return!1;let t=[...u.branches].some(t=>t.contains(e));return x&&!t},[u.branches,x])}),w=ea(e=>{if(r&&S.current)return;let t=e.target;[...u.branches].some(e=>e.contains(t))||(o?.(e),s?.(e),e.defaultPrevented||c?.())},p),T=d?y===g.length-1:!1,E=Hi(e=>{e.key===`Escape`&&(i?.(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))});return R.useEffect(()=>{if(T)return p.addEventListener(`keydown`,E,{capture:!0}),()=>p.removeEventListener(`keydown`,E,{capture:!0})},[p,T,E]),R.useEffect(()=>{if(d)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Ji=p.body.style.pointerEvents,p.body.style.pointerEvents=`none`),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),ta(),()=>{n&&(u.layersWithOutsidePointerEventsDisabled.delete(d),u.layersWithOutsidePointerEventsDisabled.size===0&&(p.body.style.pointerEvents=Ji))}},[d,p,n,u]),R.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),ta())},[d,u]),R.useEffect(()=>{let e=Wi(()=>m({}),`handleUpdate`);return document.addEventListener(Gi,e),()=>document.removeEventListener(Gi,e)},[]),(0,z.jsx)(H.div,{...l,ref:h,style:{pointerEvents:b?x?`auto`:`none`:void 0,...e.style},onFocusCapture:U(e.onFocusCapture,w.onFocusCapture),onBlurCapture:U(e.onBlurCapture,w.onBlurCapture),onPointerDownCapture:U(e.onPointerDownCapture,C.onPointerDownCapture)})},`DismissableLayer`));function Zi(){let e=R.useContext(Yi),[t,n]=R.useState(null);return R.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),n}Wi(Zi,`useDismissableLayerSurface`);var Qi=Wi(()=>!0,`IS_TRUE`);function $i(e,t){let{ownerDocument:n=globalThis?.document,deferPointerDownOutside:r=!1,isDeferredPointerDownOutsideRef:i,dismissableSurfaces:a,shouldHandlePointerDownOutside:o=Qi}=t,s=Hi(e),c=R.useRef(!1),l=R.useRef(!1),u=R.useRef(new Map),d=R.useRef(()=>{});return R.useEffect(()=>{function e(){l.current=!1,i.current=!1,u.current.clear()}Wi(e,`resetOutsideInteraction`);function t(){return Array.from(u.current.values()).some(Boolean)}Wi(t,`isOutsideInteractionIntercepted`);function f(e){if(!l.current)return;let t=e.target;t instanceof Node&&[...a].some(e=>e.contains(t))||u.current.set(e.type,!0),e.type===`click`&&window.setTimeout(()=>{l.current&&d.current()},0)}Wi(f,`handleInteractionCapture`);function p(e){l.current&&u.current.set(e.type,!1)}Wi(p,`handleInteractionBubble`);let m=Wi(a=>{if(a.target&&!c.current){let f=function(){n.removeEventListener(`click`,d.current);let r=t();e(),r||na(Ki,s,p,{discrete:!0})};if(Wi(f,`handleAndDispatchPointerDownOutsideEvent`),!o(a.target)){n.removeEventListener(`click`,d.current),e(),c.current=!1;return}let p={originalEvent:a};l.current=!0,i.current=r&&a.button===0,u.current.clear(),!r||a.button!==0?f():(n.removeEventListener(`click`,d.current),d.current=f,n.addEventListener(`click`,d.current,{once:!0}))}else n.removeEventListener(`click`,d.current),e();c.current=!1},`handlePointerDown`),h=[`pointerup`,`mousedown`,`mouseup`,`touchstart`,`touchend`,`click`];for(let e of h)n.addEventListener(e,f,!0),n.addEventListener(e,p);let g=window.setTimeout(()=>{n.addEventListener(`pointerdown`,m)},0);return()=>{window.clearTimeout(g),n.removeEventListener(`pointerdown`,m),n.removeEventListener(`click`,d.current);for(let e of h)n.removeEventListener(e,f,!0),n.removeEventListener(e,p)}},[n,s,r,i,a,o]),{onPointerDownCapture:Wi(()=>c.current=!0,`onPointerDownCapture`)}}Wi($i,`usePointerDownOutside`);function ea(e,t=globalThis?.document){let n=Hi(e),r=R.useRef(!1);return R.useEffect(()=>{let e=Wi(e=>{e.target&&!r.current&&na(qi,n,{originalEvent:e},{discrete:!1})},`handleFocus`);return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:Wi(()=>r.current=!0,`onFocusCapture`),onBlurCapture:Wi(()=>r.current=!1,`onBlurCapture`)}}Wi(ea,`useFocusOutside`);function ta(){let e=new CustomEvent(Gi);document.dispatchEvent(e)}Wi(ta,`dispatchUpdate`);function na(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?_r(i,a):i.dispatchEvent(a)}Wi(na,`handleAndDispatchCustomEvent`);var ra=Object.defineProperty,ia=(e,t)=>ra(e,`name`,{value:t,configurable:!0}),aa=`focusScope.autoFocusOnMount`,oa=`focusScope.autoFocusOnUnmount`,sa={bubbles:!1,cancelable:!0},ca=R.forwardRef(ia(function(e,t){let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=R.useState(null),l=Hi(i),u=Hi(a),d=R.useRef(null),f=V(t,c),p=R.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;R.useEffect(()=>{if(r){let e=function(e){if(p.paused||!s)return;let t=e.target;s.contains(t)?d.current=t:ha(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||ha(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&ha(s)};ia(e,`handleFocusIn`),ia(t,`handleFocusOut`),ia(n,`handleMutations`),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]),R.useEffect(()=>{if(s){ga.add(p);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(aa,sa);s.addEventListener(aa,l),s.dispatchEvent(t),t.defaultPrevented||(la(ya(da(s)),{select:!0}),document.activeElement===e&&ha(s))}return()=>{s.removeEventListener(aa,l),setTimeout(()=>{let t=new CustomEvent(oa,sa);s.addEventListener(oa,u),s.dispatchEvent(t),t.defaultPrevented||ha(e??document.body,{select:!0}),s.removeEventListener(oa,u),ga.remove(p)},0)}}},[s,l,u,p]);let m=R.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]=ua(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&ha(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&ha(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,p.paused]);return(0,z.jsx)(H.div,{tabIndex:-1,...o,ref:f,onKeyDown:m})},`FocusScope`));function la(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(ha(r,{select:t}),document.activeElement!==n)return}ia(la,`focusFirst`);function ua(e){let t=da(e);return[fa(t,e),fa(t.reverse(),e)]}ia(ua,`getTabbableEdges`);function da(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:ia(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},`acceptNode`)});for(;n.nextNode();)t.push(n.currentNode);return t}ia(da,`getTabbableCandidates`);function fa(e,t){let n=typeof t.checkVisibility==`function`&&t.checkVisibility({checkVisibilityCSS:!0});for(let r of e)if(!(n?!r.checkVisibility({checkVisibilityCSS:!0}):pa(r,{upTo:t})))return r}ia(fa,`findVisible`);function pa(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}ia(pa,`isHidden`);function ma(e){return e instanceof HTMLInputElement&&`select`in e}ia(ma,`isSelectableInput`);function ha(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&ma(e)&&t&&e.select()}}ia(ha,`focus`);var ga=_a();function _a(){let e=[];return{add(t){let n=e[0];t!==n&&n?.pause(),e=va(e,t),e.unshift(t)},remove(t){e=va(e,t),e[0]?.resume()}}}ia(_a,`createFocusScopesStack`);function va(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}ia(va,`arrayRemove`);function ya(e){return e.filter(e=>e.tagName!==`A`)}ia(ya,`removeLinks`);var ba=Object.defineProperty,xa=R.forwardRef(((e,t)=>ba(e,`name`,{value:t,configurable:!0}))(function(e,t){let{container:n,...r}=e,[i,a]=R.useState(!1);qr(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?mr.createPortal((0,z.jsx)(H.div,{...r,ref:t}),o):null},`Portal`)),Sa=Object.defineProperty,Ca=(e,t)=>Sa(e,`name`,{value:t,configurable:!0}),wa=0,Ta=null;function Ea(e){return Da(),e.children}Ca(Ea,`FocusGuards`);function Da(){R.useEffect(()=>{Ta||={start:Oa(),end:Oa()};let{start:e,end:t}=Ta;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement(`afterbegin`,e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement(`beforeend`,t),wa++,()=>{wa===1&&(Ta?.start.remove(),Ta?.end.remove(),Ta=null),wa=Math.max(0,wa-1)}},[])}Ca(Da,`useFocusGuards`);function Oa(){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}Ca(Oa,`createFocusGuard`);var ka=function(){return ka=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},ka.apply(this,arguments)};function Aa(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 ja(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 Ma=`right-scroll-bar-position`,Na=`width-before-scroll-bar`,Pa=`with-scroll-bars-hidden`,Fa=`--removed-body-scroll-bar-size`;function Ia(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function La(e,t){var n=(0,R.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 Ra=typeof window<`u`?R.useLayoutEffect:R.useEffect,za=new WeakMap;function Ba(e,t){var n=La(t||null,function(t){return e.forEach(function(e){return Ia(e,t)})});return Ra(function(){var t=za.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||Ia(e,null)}),i.forEach(function(e){r.has(e)||Ia(e,a)})}za.set(n,e)},[e]),n}function Va(e){return e}function Ha(e,t){t===void 0&&(t=Va);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 Ua(e){e===void 0&&(e={});var t=Ha(null);return t.options=ka({async:!0,ssr:!1},e),t}var Wa=function(e){var t=e.sideCar,n=Aa(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 R.createElement(r,ka({},n))};Wa.isSideCarExport=!0;function Ga(e,t){return e.useMedium(t),Wa}var Ka=Ua(),qa=function(){},Ja=R.forwardRef(function(e,t){var n=R.useRef(null),r=R.useState({onScrollCapture:qa,onWheelCapture:qa,onTouchMoveCapture:qa}),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=Aa(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),x=f,S=Ba([n,t]),C=ka(ka({},b),i);return R.createElement(R.Fragment,null,u&&R.createElement(x,{sideCar:Ka,removeScrollBar:l,shards:d,noRelative:p,noIsolation:m,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:y}),o?R.cloneElement(R.Children.only(s),ka(ka({},C),{ref:S})):R.createElement(v,ka({},C,{className:c,ref:S}),s))});Ja.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Ja.classNames={fullWidth:Na,zeroRight:Ma};var Ya,Xa=function(){if(Ya)return Ya;if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function Za(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=Xa();return t&&e.setAttribute(`nonce`,t),e}function Qa(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function $a(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var eo=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Za())&&(Qa(t,n),$a(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},to=function(){var e=eo();return function(t,n){R.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},no=function(){var e=to();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},ro={left:0,top:0,right:0,gap:0},io=function(e){return parseInt(e||``,10)||0},ao=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[io(n),io(r),io(i)]},oo=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return ro;var t=ao(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])}},so=no(),co=`data-scroll-locked`,W=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
|
+
.${Pa} {
|
|
11
|
+
overflow: hidden ${r};
|
|
12
|
+
padding-right: ${s}px ${r};
|
|
13
|
+
}
|
|
14
|
+
body[${co}] {
|
|
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
|
+
.${Ma} {
|
|
28
|
+
right: ${s}px ${r};
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.${Na} {
|
|
32
|
+
margin-right: ${s}px ${r};
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.${Ma} .${Ma} {
|
|
36
|
+
right: 0 ${r};
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.${Na} .${Na} {
|
|
40
|
+
margin-right: 0 ${r};
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
body[${co}] {
|
|
44
|
+
${Fa}: ${s}px;
|
|
45
|
+
}
|
|
46
|
+
`},lo=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},uo=function(){R.useEffect(function(){return document.body.setAttribute(co,(lo()+1).toString()),function(){var e=lo()-1;e<=0?document.body.removeAttribute(co):document.body.setAttribute(co,e.toString())}},[])},fo=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;uo();var a=R.useMemo(function(){return oo(i)},[i]);return R.createElement(so,{styles:W(a,!t,i,n?``:`!important`)})},po=!1;if(typeof window<`u`)try{var mo=Object.defineProperty({},"passive",{get:function(){return po=!0,!0}});window.addEventListener(`test`,mo,mo),window.removeEventListener(`test`,mo,mo)}catch{po=!1}var ho=po?{passive:!1}:!1,go=function(e){return e.tagName===`TEXTAREA`},_o=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!go(e)&&n[t]===`visible`)},vo=function(e){return _o(e,`overflowY`)},yo=function(e){return _o(e,`overflowX`)},bo=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),Co(e,r)){var i=wo(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},xo=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},So=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},Co=function(e,t){return e===`v`?vo(t):yo(t)},wo=function(e,t){return e===`v`?xo(t):So(t)},To=function(e,t){return e===`h`&&t===`rtl`?-1:1},Eo=function(e,t,n,r,i){var a=To(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=wo(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&Co(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},Do=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Oo=function(e){return[e.deltaX,e.deltaY]},ko=function(e){return e&&`current`in e?e.current:e},Ao=function(e,t){return e[0]===t[0]&&e[1]===t[1]},jo=function(e){return`
|
|
47
|
+
.block-interactivity-${e} {pointer-events: none;}
|
|
48
|
+
.allow-interactivity-${e} {pointer-events: all;}
|
|
49
|
+
`},Mo=0,No=[];function Po(e){var t=R.useRef([]),n=R.useRef([0,0]),r=R.useRef(),i=R.useState(Mo++)[0],a=R.useState(no)[0],o=R.useRef(e);R.useEffect(function(){o.current=e},[e]),R.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=ja([e.lockRef.current],(e.shards||[]).map(ko),!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=R.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=Do(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=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===u||p.contains(u)))return!1;var m=bo(d,u);if(!m)return!0;if(m?l=d:(l=d===`v`?`h`:`v`,m=bo(d,u)),!m)return!1;if(!r.current&&`changedTouches`in e&&(s||c)&&(r.current=l),!l)return!0;var h=r.current||l;return Eo(h,t,e,h===`h`?s:c,!0)},[]),c=R.useCallback(function(e){var n=e;if(!(!No.length||No[No.length-1]!==a)){var r=`deltaY`in n?Oo(n):Do(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&Ao(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var c=(o.current.shards||[]).map(ko).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=R.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:Fo(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),u=R.useCallback(function(e){n.current=Do(e),r.current=void 0},[]),d=R.useCallback(function(t){l(t.type,Oo(t),t.target,s(t,e.lockRef.current))},[]),f=R.useCallback(function(t){l(t.type,Do(t),t.target,s(t,e.lockRef.current))},[]);R.useEffect(function(){return No.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener(`wheel`,c,ho),document.addEventListener(`touchmove`,c,ho),document.addEventListener(`touchstart`,u,ho),function(){No=No.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,c,ho),document.removeEventListener(`touchmove`,c,ho),document.removeEventListener(`touchstart`,u,ho)}},[]);var p=e.removeScrollBar,m=e.inert;return R.createElement(R.Fragment,null,m?R.createElement(a,{styles:jo(i)}):null,p?R.createElement(fo,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Fo(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var Io=Ga(Ka,Po),Lo=R.forwardRef(function(e,t){return R.createElement(Ja,ka({},e,{ref:t,sideCar:Io}))});Lo.classNames=Ja.classNames;var Ro=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},zo=new WeakMap,Bo=new WeakMap,Vo={},Ho=0,Uo=function(e){return e&&(e.host||Uo(e.parentNode))},Wo=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=Uo(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})},Go=function(e,t,n,r){var i=Wo(t,Array.isArray(e)?e:[e]);Vo[n]||(Vo[n]=new WeakMap);var a=Vo[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=(zo.get(e)||0)+1,l=(a.get(e)||0)+1;zo.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Bo.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(),Ho++,function(){o.forEach(function(e){var t=zo.get(e)-1,i=a.get(e)-1;zo.set(e,t),a.set(e,i),t||(Bo.has(e)||e.removeAttribute(r),Bo.delete(e)),i||e.removeAttribute(n)}),Ho--,Ho||(zo=new WeakMap,zo=new WeakMap,Bo=new WeakMap,Vo={})}},Ko=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||Ro(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),Go(r,i,n,`aria-hidden`)):function(){return null}},qo=Object.defineProperty,Jo=(e,t)=>qo(e,`name`,{value:t,configurable:!0}),Yo=`Dialog`,[Xo,Zo]=Tr(Yo),[Qo,$o]=Xo(Yo),es=Jo(e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=R.useRef(null),c=R.useRef(null),[l,u]=ni({prop:r,defaultProp:i??!1,onChange:a,caller:Yo}),[d,f]=R.useState(0),[p,m]=R.useState(0);return(0,z.jsx)(Qo,{scope:t,triggerRef:s,contentRef:c,contentId:bi(),titleId:bi(),descriptionId:bi(),titlePresent:d>0,descriptionPresent:p>0,setTitleCount:f,setDescriptionCount:m,open:l,onOpenChange:u,onOpenToggle:R.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})},`Dialog`),ts=`DialogTrigger`,ns=R.forwardRef(Jo(function(e,t){let{__scopeDialog:n,...r}=e,i=$o(ts,n),a=V(t,i.triggerRef);return(0,z.jsx)(H.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":Ss(i.open),...r,ref:a,onClick:U(e.onClick,i.onOpenToggle)})},`DialogTrigger`)),rs=`DialogPortal`,[is,as]=Xo(rs,{forceMount:void 0}),os=Jo(e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=$o(rs,t);return(0,z.jsx)(is,{scope:t,forceMount:n,children:R.Children.map(r,e=>(0,z.jsx)(ui,{present:n||a.open,children:(0,z.jsx)(xa,{asChild:!0,container:i,children:e})}))})},`DialogPortal`),ss=`DialogOverlay`,cs=R.forwardRef(Jo(function(e,t){let n=as(ss,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=$o(ss,e.__scopeDialog);return a.modal?(0,z.jsx)(ui,{present:r||a.open,children:(0,z.jsx)(us,{...i,ref:t})}):null},`DialogOverlay`)),ls=er(`DialogOverlay.RemoveScroll`),us=R.forwardRef(Jo(function(e,t){let{__scopeDialog:n,...r}=e,i=$o(ss,n),a=V(t,Zi());return(0,z.jsx)(Lo,{as:ls,allowPinchZoom:!0,shards:[i.contentRef],children:(0,z.jsx)(H.div,{"data-state":Ss(i.open),...r,ref:a,style:{pointerEvents:`auto`,...r.style}})})},`DialogOverlayImpl`)),ds=`DialogContent`,fs=R.forwardRef(Jo(function(e,t){let n=as(ds,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=$o(ds,e.__scopeDialog);return(0,z.jsx)(ui,{present:r||a.open,children:a.modal?(0,z.jsx)(ps,{...i,ref:t}):(0,z.jsx)(ms,{...i,ref:t})})},`DialogContent`)),ps=R.forwardRef(Jo(function(e,t){let n=$o(ds,e.__scopeDialog),r=R.useRef(null),i=V(t,n.contentRef,r);return R.useEffect(()=>{let e=r.current;if(e)return Ko(e)},[]),(0,z.jsx)(hs,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,onCloseAutoFocus:U(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:U(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:U(e.onFocusOutside,e=>e.preventDefault())})},`DialogContentModal`)),ms=R.forwardRef(Jo(function(e,t){let n=$o(ds,e.__scopeDialog),r=R.useRef(!1),i=R.useRef(!1);return(0,z.jsx)(hs,{...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()}})},`DialogContentNonModal`)),hs=R.forwardRef(Jo(function(e,t){let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=$o(ds,n);return Da(),(0,z.jsx)(z.Fragment,{children:(0,z.jsx)(ca,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,z.jsx)(Xi,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionPresent?s.descriptionId:void 0,"aria-labelledby":s.titlePresent?s.titleId:void 0,"data-state":Ss(s.open),...o,ref:t,deferPointerDownOutside:!0,onDismiss:()=>s.onOpenChange(!1)})})})},`DialogContentImpl`)),gs=`DialogTitle`,_s=R.forwardRef(Jo(function(e,t){let{__scopeDialog:n,...r}=e,i=$o(gs,n),{setTitleCount:a}=i;return qr(()=>(a(e=>e+1),()=>a(e=>e-1)),[a]),(0,z.jsx)(H.h2,{id:i.titleId,...r,ref:t})},`DialogTitle`)),vs=`DialogDescription`,ys=R.forwardRef(Jo(function(e,t){let{__scopeDialog:n,...r}=e,i=$o(vs,n),{setDescriptionCount:a}=i;return qr(()=>(a(e=>e+1),()=>a(e=>e-1)),[a]),(0,z.jsx)(H.p,{id:i.descriptionId,...r,ref:t})},`DialogDescription`)),bs=`DialogClose`,xs=R.forwardRef(Jo(function(e,t){let{__scopeDialog:n,...r}=e,i=$o(bs,n);return(0,z.jsx)(H.button,{type:`button`,...r,ref:t,onClick:U(e.onClick,()=>i.onOpenChange(!1))})},`DialogClose`));function Ss(e){return e?`open`:`closed`}Jo(Ss,`getState`);var Cs=Object.defineProperty,ws=(e,t)=>Cs(e,`name`,{value:t,configurable:!0}),[Ts,Es]=Tr(`AlertDialog`,[Zo]),Ds=Zo(),Os=ws(e=>{let{__scopeAlertDialog:t,...n}=e,r=Ds(t);return(0,z.jsx)(es,{...r,...n,modal:!0})},`AlertDialog`);R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,...r}=e,i=Ds(n);return(0,z.jsx)(ns,{...i,...r,ref:t})},`AlertDialogTrigger`));var ks=ws(e=>{let{__scopeAlertDialog:t,...n}=e,r=Ds(t);return(0,z.jsx)(os,{...r,...n})},`AlertDialogPortal`),As=R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,...r}=e,i=Ds(n);return(0,z.jsx)(cs,{...i,...r,ref:t})},`AlertDialogOverlay`)),[js,Ms]=Ts(`AlertDialogContent`),Ns=R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,children:r,...i}=e,a=Ds(n),o=V(t,R.useRef(null)),s=R.useRef(null);return(0,z.jsx)(js,{scope:n,cancelRef:s,children:(0,z.jsx)(fs,{role:`alertdialog`,...a,...i,ref:o,onOpenAutoFocus:U(i.onOpenAutoFocus,e=>{e.preventDefault(),s.current?.focus({preventScroll:!0})}),onPointerDownOutside:e=>e.preventDefault(),onInteractOutside:e=>e.preventDefault(),children:r})})},`AlertDialogContent`)),Ps=R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,...r}=e,i=Ds(n);return(0,z.jsx)(_s,{...i,...r,ref:t})},`AlertDialogTitle`)),Fs=R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,...r}=e,i=Ds(n);return(0,z.jsx)(ys,{...i,...r,ref:t})},`AlertDialogDescription`)),Is=R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,...r}=e,i=Ds(n);return(0,z.jsx)(xs,{...i,...r,ref:t})},`AlertDialogAction`)),Ls=`AlertDialogCancel`,Rs=R.forwardRef(ws(function(e,t){let{__scopeAlertDialog:n,...r}=e,{cancelRef:i}=Ms(Ls,n),a=Ds(n),o=V(t,i);return(0,z.jsx)(xs,{...a,...r,ref:o})},`AlertDialogCancel`)),zs=Os,Bs=ks,Vs=As,Hs=Ns,Us=Is,Ws=Rs,Gs=Ps,Ks=Fs,qs=Object.defineProperty,Js=(e,t)=>qs(e,`name`,{value:t,configurable:!0}),Ys=`Avatar`,[Xs,Zs]=Tr(Ys),Qs=[0,()=>void 0],[$s,ec]=Xs(Ys),tc=R.forwardRef(Js(function(e,t){let{__scopeAvatar:n,...r}=e,[i,a]=R.useState(`idle`),[o,s]=cc();return(0,z.jsx)($s,{scope:n,imageLoadingStatus:i,setImageLoadingStatus:a,imageCount:o,setImageCount:s,children:(0,z.jsx)(H.span,{...r,ref:t})})},`Avatar`)),nc=`AvatarImage`,rc=R.forwardRef(Js(function(e,t){let{__scopeAvatar:n,src:r,onLoadingStatusChange:i,...a}=e,o=ec(nc,n);o.setImageCount;let s=oc(r,{referrerPolicy:a.referrerPolicy,crossOrigin:a.crossOrigin,loadingStatus:o.imageLoadingStatus,setLoadingStatus:o.setImageLoadingStatus}),c=Hi(e=>{i?.(e)}),l=R.useRef(s);return qr(()=>{let e=l.current;l.current=s,s!==e&&c(s)},[s,c]),s===`loaded`?(0,z.jsx)(H.img,{...a,ref:t,src:r}):null},`AvatarImage`)),ic=`AvatarFallback`,ac=R.forwardRef(Js(function(e,t){let{__scopeAvatar:n,delayMs:r,...i}=e,a=ec(ic,n),[o,s]=R.useState(r===void 0);return R.useEffect(()=>{if(r!==void 0){let e=window.setTimeout(()=>s(!0),r);return()=>window.clearTimeout(e)}},[r]),o&&a.imageLoadingStatus!==`loaded`?(0,z.jsx)(H.span,{...i,ref:t}):null},`AvatarFallback`));function oc(e,{loadingStatus:t,setLoadingStatus:n,referrerPolicy:r,crossOrigin:i}){return qr(()=>{if(!e){n(`error`);return}let t=new window.Image,a=Js(e=>{let t=e.currentTarget;n(sc(t))},`handleLoad`),o=Js(()=>n(`error`),`handleError`);return t.addEventListener(`load`,a),t.addEventListener(`error`,o),r&&(t.referrerPolicy=r),t.crossOrigin=i??null,t.src=e,n(sc(t)),()=>{t.removeEventListener(`load`,a),t.removeEventListener(`error`,o),n(`idle`)}},[e,i,r,n]),t}Js(oc,`useImageLoadingStatus`);function sc(e){return e.complete?e.naturalWidth>0?`loaded`:`error`:`loading`}Js(sc,`getImageLoadingStatus`);function cc(){return Qs}Js(cc,`useImageCount`);function lc(e){}Js(lc,`useUpdateImageCount`);var uc=Object.defineProperty,dc=(e,t)=>uc(e,`name`,{value:t,configurable:!0});function fc(e){let[t,n]=R.useState(void 0);return qr(()=>{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)}n(void 0)},[e]),t}dc(fc,`useSize`);var pc=Object.defineProperty,mc=(e,t)=>pc(e,`name`,{value:t,configurable:!0}),hc=`Checkbox`,[gc,_c]=Tr(hc),[vc,yc]=gc(hc);function bc(e){let{__scopeCheckbox:t,checked:n,children:r,defaultChecked:i,disabled:a,form:o,name:s,onCheckedChange:c,required:l,value:u=`on`,internal_do_not_use_render:d}=e,[f,p]=ni({prop:n,defaultProp:i??!1,onChange:c,caller:hc}),[m,h]=R.useState(null),[g,_]=R.useState(null),v=R.useRef(!1),[y,b]=R.useReducer(e=>e+1,0),x=!m||!!o||!!m.closest(`form`),S={checked:f,disabled:a,setChecked:p,control:m,setControl:h,name:s,form:o,value:u,hasConsumerStoppedPropagationRef:v,userInteractionCount:y,onUserInteraction:b,required:l,defaultChecked:!kc(i)&&i,isFormControl:x,bubbleInput:g,setBubbleInput:_};return(0,z.jsx)(vc,{scope:t,...S,children:Oc(d)?d(S):r})}mc(bc,`CheckboxProvider`);var xc=`CheckboxTrigger`,Sc=R.forwardRef(mc(function({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},i){let{control:a,value:o,disabled:s,checked:c,required:l,setControl:u,setChecked:d,hasConsumerStoppedPropagationRef:f,onUserInteraction:p,isFormControl:m,bubbleInput:h}=yc(xc,e),g=V(i,u),_=R.useRef(c);return R.useEffect(()=>{let e=a?.form;if(e){let t=mc(()=>d(_.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[a,d]),(0,z.jsx)(H.button,{type:`button`,role:`checkbox`,"aria-checked":kc(c)?`mixed`:c,"aria-required":l,"data-state":Ac(c),"data-disabled":s?``:void 0,disabled:s,value:o,...r,ref:g,onKeyDown:U(t,e=>{e.key===`Enter`&&e.preventDefault()}),onClick:U(n,e=>{p(),d(e=>kc(e)?!0:!e),h&&m&&(f.current=e.isPropagationStopped(),f.current||e.stopPropagation())})})},`CheckboxTrigger`)),Cc=R.forwardRef(mc(function(e,t){let{__scopeCheckbox:n,name:r,checked:i,defaultChecked:a,required:o,disabled:s,value:c,onCheckedChange:l,form:u,...d}=e;return(0,z.jsx)(bc,{__scopeCheckbox:n,checked:i,defaultChecked:a,disabled:s,required:o,onCheckedChange:l,name:r,form:u,value:c,internal_do_not_use_render:({isFormControl:e})=>(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(Sc,{...d,ref:t,__scopeCheckbox:n}),e&&(0,z.jsx)(Dc,{__scopeCheckbox:n})]})})},`Checkbox`)),wc=`CheckboxIndicator`,Tc=R.forwardRef(mc(function(e,t){let{__scopeCheckbox:n,forceMount:r,...i}=e,a=yc(wc,n);return(0,z.jsx)(ui,{present:r||kc(a.checked)||a.checked===!0,children:(0,z.jsx)(H.span,{"data-state":Ac(a.checked),"data-disabled":a.disabled?``:void 0,...i,ref:t,style:{pointerEvents:`none`,...e.style}})})},`CheckboxIndicator`)),Ec=`CheckboxBubbleInput`,Dc=R.forwardRef(mc(function({__scopeCheckbox:e,onClick:t,...n},r){let{control:i,hasConsumerStoppedPropagationRef:a,userInteractionCount:o,checked:s,defaultChecked:c,required:l,disabled:u,name:d,value:f,form:p,bubbleInput:m,setBubbleInput:h}=yc(Ec,e),g=V(r,h),_=fc(i),v=R.useRef(!1),y=R.useRef(s),b=R.useRef(o);R.useEffect(()=>{let e=m;if(!e)return;let t=window.HTMLInputElement.prototype,n=Object.getOwnPropertyDescriptor(t,`checked`).set,r=o!==b.current;b.current=o;let i=y.current!==s;y.current=s;let c=!(r&&a.current);if(i&&n){v.current=!r;let t=new Event(`click`,{bubbles:c});e.indeterminate=kc(s),n.call(e,!kc(s)&&s),e.dispatchEvent(t),v.current=!1}},[m,s,a,o]);let x=R.useRef(!kc(s)&&s);return(0,z.jsx)(H.input,{type:`checkbox`,"aria-hidden":!0,defaultChecked:c??x.current,required:l,disabled:u,name:d,value:f,form:p,...n,tabIndex:-1,ref:g,onClick:U(t,e=>{v.current&&e.stopPropagation()}),style:{...n.style,..._,position:`absolute`,pointerEvents:`none`,opacity:0,margin:0,transform:`translateX(-100%)`}})},`CheckboxBubbleInput`));function Oc(e){return typeof e==`function`}mc(Oc,`isFunction`);function kc(e){return e===`indeterminate`}mc(kc,`isIndeterminate`);function Ac(e){return kc(e)?`indeterminate`:e?`checked`:`unchecked`}mc(Ac,`getState`);var jc=[`top`,`right`,`bottom`,`left`],Mc=Math.min,Nc=Math.max,Pc=Math.round,Fc=Math.floor,Ic=e=>({x:e,y:e}),Lc={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function Rc(e,t,n){return Nc(e,Mc(t,n))}function zc(e,t){return typeof e==`function`?e(t):e}function Bc(e){return e.split(`-`)[0]}function Vc(e){return e.split(`-`)[1]}function Hc(e){return e===`x`?`y`:`x`}function Uc(e){return e===`y`?`height`:`width`}function Wc(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function Gc(e){return Hc(Wc(e))}function Kc(e,t,n){n===void 0&&(n=!1);let r=Vc(e),i=Gc(e),a=Uc(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=tl(o)),[o,tl(o)]}function qc(e){let t=tl(e);return[Jc(e),t,Jc(t)]}function Jc(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var Yc=[`left`,`right`],Xc=[`right`,`left`],Zc=[`top`,`bottom`],Qc=[`bottom`,`top`];function $c(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Xc:Yc:t?Yc:Xc;case`left`:case`right`:return t?Zc:Qc;default:return[]}}function el(e,t,n,r){let i=Vc(e),a=$c(Bc(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(Jc)))),a}function tl(e){let t=Bc(e);return Lc[t]+e.slice(t.length)}function nl(e){return{top:e.top??0,right:e.right??0,bottom:e.bottom??0,left:e.left??0}}function rl(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:nl(e)}function il(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 al(e,t,n){let{reference:r,floating:i}=e,a=Wc(t),o=Gc(t),s=Uc(o),c=Bc(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}}let m=Vc(t);return m&&(p[o]+=f*(m===`end`?1:-1)*(n&&l?-1:1)),p}async function ol(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}=zc(t,e),p=rl(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=il(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=il(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 sl=50,cl=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:ol},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=al(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<sl&&(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}=al(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},ll=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}=zc(e,t)||{};if(l==null)return{};let d=rl(u),f={x:n,y:r},p=Gc(i),m=Uc(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,T=C/2-h[m]/2-1,E=Mc(d[_],T),ee=Mc(d[v],T),D=C-h[m]-ee,O=C/2-h[m]/2+w,k=Rc(E,O,D),A=!c.arrow&&Vc(i)!=null&&O!==k&&a.reference[m]/2-(O<E?E:ee)-h[m]/2<0,j=A?O<E?O-E:O-D:0;return{[p]:f[p]+j,data:{[p]:k,centerOffset:O-k-j,...A&&{alignmentOffset:j}},reset:A}}}),ul=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}=zc(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=Bc(r),_=Wc(o),v=Bc(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[tl(o)]:qc(o)),x=p!==`none`;!d&&x&&b.push(...el(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),w=[],T=i.flip?.overflows||[];if(l&&w.push(C[g]),u){let e=Kc(r,a,y);w.push(C[e[0]],C[e[1]])}if(T=[...T,{placement:r,overflows:w}],!w.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(u!==`alignment`||_===Wc(t)||T.every(e=>Wc(e.placement)!==_||e.overflows[0]>0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.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=T.filter(e=>{if(x){let t=Wc(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}if(r!==n)return{reset:{placement:n}}}return{}}}};function dl(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function fl(e){return jc.some(t=>e[t]>=0)}var pl=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=zc(e,t);switch(i){case`referenceHidden`:{let e=dl(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:fl(e)}}}case`escaped`:{let e=dl(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:fl(e)}}}default:return{}}}}},ml=new Set([`left`,`top`]);async function hl(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Bc(n),s=Vc(n),c=Wc(n)===`y`,l=ml.has(o)?-1:1,u=a&&c?-1:1,d=zc(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 gl=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 hl(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}}}}},_l=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}=zc(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=Wc(i),p=Hc(f),m=u[p],h=u[f],g=(e,t)=>Rc(t+d[e===`y`?`top`:`left`],t,t-d[e===`y`?`bottom`:`right`]);o&&(m=g(p,m)),s&&(h=g(f,h));let _=c.fn({...t,[p]:m,[f]:h});return{..._,data:{x:_.x-n,y:_.y-r,enabled:{[p]:o,[f]:s}}}}}},vl=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}=zc(e,t),u={x:n,y:r},d=Wc(i),f=Hc(d),p=u[f],m=u[d],h=zc(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:h.mainAxis??0,crossAxis:h.crossAxis??0};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=ml.has(Bc(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}}}},yl=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){let{placement:n,rects:r,platform:i,elements:a}=t,{apply:o=()=>{},...s}=zc(e,t),c=await i.detectOverflow(t,s),l=Bc(n),u=Vc(n),d=Wc(n)===`y`,{width:f,height:p}=r.floating,m,h;l===`top`||l===`bottom`?(m=l,h=u===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?`start`:`end`)?`left`:`right`):(h=l,m=u===`end`?`top`:`bottom`);let g=p-c.top-c.bottom,_=f-c.left-c.right,v=Mc(p-c[m],g),y=Mc(f-c[h],_),b=t.middlewareData.shift,x=!b,S=v,C=y;b!=null&&b.enabled.x&&(C=_),b!=null&&b.enabled.y&&(S=g),x&&!u&&(d?C=f-2*Nc(c.left,c.right):S=p-2*Nc(c.top,c.bottom)),await o({...t,availableWidth:C,availableHeight:S});let w=await i.getDimensions(a.floating);return f!==w.width||p!==w.height?{reset:{rects:!0}}:{}}}};function bl(){return typeof window<`u`}function xl(e){return wl(e)?(e.nodeName||``).toLowerCase():`#document`}function Sl(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Cl(e){return((wl(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function wl(e){return bl()?e instanceof Node||e instanceof Sl(e).Node:!1}function Tl(e){return bl()?e instanceof Element||e instanceof Sl(e).Element:!1}function El(e){return bl()?e instanceof HTMLElement||e instanceof Sl(e).HTMLElement:!1}function Dl(e){return!bl()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof Sl(e).ShadowRoot}function Ol(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=zl(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function kl(e){return/^(table|td|th)$/.test(xl(e))}function Al(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var jl=/transform|translate|scale|rotate|perspective|filter/,Ml=/paint|layout|strict|content/,Nl=e=>!!e&&e!==`none`,Pl;function Fl(e){let t=Tl(e)?zl(e):e;return Nl(t.transform)||Nl(t.translate)||Nl(t.scale)||Nl(t.rotate)||Nl(t.perspective)||!Ll()&&(Nl(t.backdropFilter)||Nl(t.filter))||jl.test(t.willChange||``)||Ml.test(t.contain||``)}function Il(e){let t=Vl(e);for(;El(t)&&!Rl(t);){if(Fl(t))return t;if(Al(t))return null;t=Vl(t)}return null}function Ll(){return Pl??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),Pl}function Rl(e){return/^(html|body|#document)$/.test(xl(e))}function zl(e){return Sl(e).getComputedStyle(e)}function Bl(e){return Tl(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Vl(e){if(xl(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||Dl(e)&&e.host||Cl(e);return Dl(t)?t.host:t}function Hl(e){let t=Vl(e);return Rl(t)?(e.ownerDocument||e).body:El(t)&&Ol(t)?t:Hl(t)}function G(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=Hl(e),i=r===e.ownerDocument?.body,a=Sl(r);if(i){let e=Ul(a);return t.concat(a,a.visualViewport||[],Ol(r)?r:[],e&&n?G(e):[])}return t.concat(r,G(r,[],n))}function Ul(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Wl(e){let t=zl(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=El(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Pc(n)!==a||Pc(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function Gl(e){return Tl(e)?e:e.contextElement}function Kl(e){let t=Gl(e);if(!El(t))return Ic(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=Wl(t),o=(a?Pc(n.width):n.width)/r,s=(a?Pc(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var ql=Ic(0);function Jl(e){let t=Sl(e);return!Ll()||!t.visualViewport?ql:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Yl(e,t,n){return t===void 0&&(t=!1),!!n&&t&&n===Sl(e)}function Xl(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=Gl(e),o=Ic(1);t&&(r?Tl(r)&&(o=Kl(r)):o=Kl(e));let s=Yl(a,n,r)?Jl(a):Ic(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&&r){let e=Sl(a),t=Tl(r)?Sl(r):r,n=e,i=Ul(n);for(;i&&t!==n;){let e=Kl(i),t=i.getBoundingClientRect(),r=zl(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=Sl(i),i=Ul(n)}}return il({width:u,height:d,x:c,y:l})}function Zl(e,t){let n=Bl(e).scrollLeft;return t?t.left+n:Xl(Cl(e)).left+n}function Ql(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Zl(e,n),y:n.top+t.scrollTop}}function $l(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=Cl(r),s=t?Al(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=Ic(1),u=Ic(0),d=El(r);if((d||!a)&&((xl(r)!==`body`||Ol(o))&&(c=Bl(r)),d)){let e=Xl(r);l=Kl(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?Ql(o,c):Ic(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 eu(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function tu(e){let t=Bl(e),n=e.ownerDocument.body,r=Nc(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=Nc(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),a=-t.scrollLeft+Zl(e),o=-t.scrollTop;return zl(n).direction===`rtl`&&(a+=Nc(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:a,y:o}}var nu=25;function ru(e,t,n){n===void 0&&(n=`viewport`);let r=n===`layoutViewport`,i=Sl(e),a=Cl(e),o=i.visualViewport,s=a.clientWidth,c=a.clientHeight,l=0,u=0;if(o){let e=!Ll()||t===`fixed`;r?e||(l=-o.offsetLeft,u=-o.offsetTop):(s=o.width,c=o.height,e&&(l=o.offsetLeft,u=o.offsetTop))}if(Zl(a)<=0){let e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r),o=getComputedStyle(a).scrollbarGutter===`stable both-edges`?i/2:i;o<=nu&&(s-=o)}return{width:s,height:c,x:l,y:u}}function iu(e,t){let n=Xl(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Kl(e);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function au(e,t,n){let r;if(t===`viewport`||t===`layoutViewport`)r=ru(e,n,t);else if(t===`document`)r=tu(Cl(e));else if(Tl(t))r=iu(t,n);else{let n=Jl(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return il(r)}function ou(e,t){let n=t.get(e);if(n)return n;let r=G(e,[],!1).filter(e=>Tl(e)&&xl(e)!==`body`),i=null,a=zl(e).position===`fixed`,o=a?Vl(e):e;for(;Tl(o)&&!Rl(o);){let e=zl(o),t=Fl(o),n=i?i.position:a?`fixed`:``;!t&&(n===`fixed`||n===`absolute`&&e.position===`static`)?r=r.filter(e=>e!==o):i=e,o=Vl(o)}return t.set(e,r),r}function su(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?Al(t)?[]:ou(t,this._c):[].concat(n),r],o=au(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=au(t,a[e],i);s=Nc(n.top,s),c=Mc(n.right,c),l=Mc(n.bottom,l),u=Nc(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function cu(e){let{width:t,height:n}=Wl(e);return{width:t,height:n}}function lu(e,t,n){let r=El(t),i=Cl(t),a=n===`fixed`,o=Xl(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=Ic(0);if((r||!a)&&((xl(t)!==`body`||Ol(i))&&(s=Bl(t)),r)){let e=Xl(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}!r&&i&&(c.x=Zl(i));let l=i&&!r&&!a?Ql(i,s):Ic(0);return{x:o.left+s.scrollLeft-c.x-l.x,y:o.top+s.scrollTop-c.y-l.y,width:o.width,height:o.height}}function uu(e){return zl(e).position===`static`}function du(e,t){if(!El(e)||zl(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return Cl(e)===n&&(n=n.ownerDocument.body),n}function fu(e,t){let n=Sl(e);if(Al(e))return n;if(!El(e)){let t=Vl(e);for(;t&&!Rl(t);){if(Tl(t)&&!uu(t))return t;t=Vl(t)}return n}let r=du(e,t);for(;r&&kl(r)&&uu(r);)r=du(r,t);return r&&Rl(r)&&uu(r)&&!Fl(r)?n:r||Il(e)||n}var pu=async function(e){let t=this.getOffsetParent||fu,n=this.getDimensions,r=await n(e.floating);return{reference:lu(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function mu(e){return zl(e).direction===`rtl`}var hu={convertOffsetParentRelativeRectToViewportRelativeRect:$l,getDocumentElement:Cl,getClippingRect:su,getOffsetParent:fu,getElementRects:pu,getClientRects:eu,getDimensions:cu,getScale:Kl,isElement:Tl,isRTL:mu};function gu(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function _u(e,t,n){let r=null,i,a=Cl(e);function o(){var e;clearTimeout(i),(e=r)==null||e.disconnect(),r=null}function s(n,c){n===void 0&&(n=!1),c===void 0&&(c=1),o();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(n||t(),!f||!p)return;let m=Fc(d),h=Fc(a.clientWidth-(u+f)),g=Fc(a.clientHeight-(d+p)),_=Fc(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:Nc(0,Mc(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(!gu(l,e.getBoundingClientRect()))return s();if(n!==c){if(!y)return s();n?s(!1,n):i=setTimeout(()=>{s(!1,1e-7)},1e3)}y=!1}try{r=new IntersectionObserver(b,{...v,root:a.ownerDocument})}catch{r=new IntersectionObserver(b,v)}r.observe(e)}let c=Sl(e),l=()=>s(n);return c.addEventListener(`resize`,l),s(!0),()=>{c.removeEventListener(`resize`,l),o()}}function vu(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=Gl(e),u=i||a?[...l?G(l):[],...t?G(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n),a&&e.addEventListener(`resize`,n)});let d=l&&s?_u(l,n,a):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?Xl(e):null;c&&g();function g(){let t=Xl(e);h&&!gu(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 yu=gl,bu=_l,xu=ul,Su=yl,Cu=pl,wu=ll,Tu=vl,Eu=(e,t,n)=>{let r=new Map,i=n??{},a={...hu,...i.platform,_c:r};return cl(e,t,{...i,platform:a})},Du=typeof document<`u`?R.useLayoutEffect:function(){};function Ou(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(!Ou(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)&&!Ou(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function ku(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Au(e,t){let n=ku(e);return Math.round(t*n)/n}function ju(e){let t=R.useRef(e);return Du(()=>{t.current=e}),t}function Mu(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]=R.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=R.useState(r);Ou(f,r)||p(r);let[m,h]=R.useState(null),[g,_]=R.useState(null),v=R.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=R.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=R.useRef(null),C=R.useRef(null),w=R.useRef(u),T=c!=null,E=ju(c),ee=ju(i),D=ju(l),O=R.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};ee.current&&(e.platform=ee.current),Eu(S.current,C.current,e).then(e=>{let t={...e,isPositioned:D.current!==!1};k.current&&!Ou(w.current,t)&&(w.current=t,mr.flushSync(()=>{d(t)}))})},[f,t,n,ee,D]);Du(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let k=R.useRef(!1);Du(()=>(k.current=!0,()=>{k.current=!1}),[]),Du(()=>{if(b&&(S.current=b),x&&(C.current=x),b&&x){if(E.current)return E.current(b,x,O);O()}},[b,x,O,E,T]);let A=R.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),j=R.useMemo(()=>({reference:b,floating:x}),[b,x]),M=R.useMemo(()=>{let e={position:n,left:0,top:0};if(!j.floating)return e;let t=Au(j.floating,u.x),r=Au(j.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...ku(j.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,j.floating,u.x,u.y]);return R.useMemo(()=>({...u,update:O,refs:A,elements:j,floatingStyles:M}),[u,O,A,j,M])}var Nu=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?{}:wu({element:r.current,padding:i}).fn(n):r?wu({element:r,padding:i}).fn(n):{}}}},Pu=(e,t)=>{let n=yu(e);return{name:n.name,fn:n.fn,options:[e,t]}},Fu=(e,t)=>{let n=bu(e);return{name:n.name,fn:n.fn,options:[e,t]}},Iu=(e,t)=>({fn:Tu(e).fn,options:[e,t]}),Lu=(e,t)=>{let n=xu(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ru=(e,t)=>{let n=Su(e);return{name:n.name,fn:n.fn,options:[e,t]}},zu=(e,t)=>{let n=Cu(e);return{name:n.name,fn:n.fn,options:[e,t]}},Bu=(e,t)=>{let n=Nu(e);return{name:n.name,fn:n.fn,options:[e,t]}},Vu=Object.defineProperty,Hu=R.forwardRef(((e,t)=>Vu(e,`name`,{value:t,configurable:!0}))(function(e,t){let{children:n,width:r=10,height:i=5,...a}=e;return(0,z.jsx)(H.svg,{...a,ref:t,width:r,height:i,viewBox:`0 0 30 10`,preserveAspectRatio:`none`,children:e.asChild?n:(0,z.jsx)(`polygon`,{points:`0,0 30,0 15,10`})})},`Arrow`)),Uu=Object.defineProperty,Wu=(e,t)=>Uu(e,`name`,{value:t,configurable:!0}),Gu=`Popper`,[Ku,qu]=Tr(Gu),[Ju,Yu]=Ku(Gu),Xu=Wu(e=>{let{__scopePopper:t,children:n}=e,[r,i]=R.useState(null),[a,o]=R.useState(void 0);return(0,z.jsx)(Ju,{scope:t,anchor:r,onAnchorChange:i,placementState:a,setPlacementState:o,children:n})},`Popper`),Zu=`PopperAnchor`,Qu=R.forwardRef(Wu(function(e,t){let{__scopePopper:n,virtualRef:r,...i}=e,a=Yu(Zu,n),o=R.useRef(null),s=a.onAnchorChange,c=V(t,R.useCallback(e=>{o.current=e,e&&s(e)},[s])),l=R.useRef(null);R.useEffect(()=>{if(!r)return;let e=l.current;l.current=r.current,e!==l.current&&s(l.current)});let u=a.placementState&&cd(a.placementState),d=u?.[0],f=u?.[1];return r?null:(0,z.jsx)(H.div,{"data-radix-popper-side":d,"data-radix-popper-align":f,...i,ref:c})},`PopperAnchor`)),$u=`PopperContent`,[ed,td]=Ku($u),nd=R.forwardRef(Wu(function(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=Yu($u,n),[_,v]=R.useState(null),y=V(t,v),[b,x]=R.useState(null),S=fc(b),C=S?.width??0,w=S?.height??0,T=r+(a===`center`?``:`-`+a),E=typeof u==`number`?u:{top:0,right:0,bottom:0,left:0,...u},ee=Array.isArray(l)?l:[l],D=ee.length>0,O={padding:E,boundary:ee.filter(od),altBoundary:D},{refs:k,floatingStyles:A,placement:j,isPositioned:M,middlewareData:N}=Mu({strategy:`fixed`,placement:T,whileElementsMounted:Wu((...e)=>vu(...e,{animationFrame:p===`always`}),`whileElementsMounted`),elements:{reference:g.anchor},middleware:[Pu({mainAxis:i+w,alignmentAxis:o}),c&&Fu({mainAxis:!0,crossAxis:!1,limiter:d===`partial`?Iu():void 0,...O}),c&&Lu({...O}),Ru({...O,apply:Wu(({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`)},`apply`)}),b&&Bu({element:b,padding:s}),sd({arrowWidth:C,arrowHeight:w}),f&&zu({strategy:`referenceHidden`,...O,boundary:D?O.boundary:void 0})]}),te=g.setPlacementState;qr(()=>(te(j),()=>{te(void 0)}),[j,te]);let[P,F]=cd(j),ne=Hi(m);qr(()=>{M&&ne?.()},[M,ne]);let re=N.arrow?.x,ie=N.arrow?.y,ae=N.arrow?.centerOffset!==0,[I,L]=R.useState();return qr(()=>{_&&L(window.getComputedStyle(_).zIndex)},[_]),(0,z.jsx)(`div`,{ref:k.setFloating,"data-radix-popper-content-wrapper":``,style:{...A,transform:M?A.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:I,"--radix-popper-transform-origin":[N.transformOrigin?.x,N.transformOrigin?.y].join(` `),...N.hide?.referenceHidden&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,z.jsx)(ed,{scope:n,placedSide:P,placedAlign:F,onArrowChange:x,arrowX:re,arrowY:ie,shouldHideArrow:ae,children:(0,z.jsx)(H.div,{"data-side":P,"data-align":F,...h,ref:y,style:{...h.style,animation:M?h.style?.animation:`none`}})})})},`PopperContent`)),rd=`PopperArrow`,id={top:`bottom`,right:`left`,bottom:`top`,left:`right`},ad=R.forwardRef(Wu(function(e,t){let{__scopePopper:n,...r}=e,i=td(rd,n),a=id[i.placedSide];return(0,z.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,z.jsx)(Hu,{...r,ref:t,style:{...r.style,display:`block`}})})},`PopperArrow`));function od(e){return e!==null}Wu(od,`isNotNull`);var sd=Wu(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]=cd(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}}}}),`transformOrigin`);function cd(e){let[t,n=`center`]=e.split(`-`);return[t,n]}Wu(cd,`getSideAndAlignFromPlacement`);var ld=Xu,ud=Qu,dd=nd,fd=ad,pd=Object.defineProperty,md=(e,t)=>pd(e,`name`,{value:t,configurable:!0}),hd=!1;function gd(){let[e,t]=R.useState(hd);return R.useEffect(()=>{hd||(hd=!0,t(!0))},[]),e}md(gd,`useIsHydrated`);var _d=R.useSyncExternalStore;function vd(){return()=>{}}md(vd,`subscribe`);function yd(){return _d(vd,()=>!0,()=>!1)}md(yd,`useIsHydratedModern`);var bd=typeof _d==`function`?yd:gd,xd=Object.defineProperty,Sd=(e,t)=>xd(e,`name`,{value:t,configurable:!0}),Cd=`rovingFocusGroup.onEntryFocus`,wd={bubbles:!1,cancelable:!0},Td=`RovingFocusGroup`,[K,Ed,Dd]=kr(Td),[Od,kd]=Tr(Td,[Dd]),[Ad,jd]=Od(Td),Md=R.forwardRef(Sd(function(e,t){return(0,z.jsx)(K.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,z.jsx)(K.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,z.jsx)(Nd,{...e,ref:t})})})},`RovingFocusGroup`)),Nd=R.forwardRef(Sd(function(e,t){let{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:a,currentTabStopId:o,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:c,onEntryFocus:l,preventScrollOnEntryFocus:u=!1,...d}=e,f=R.useRef(null),p=V(t,f),m=zi(a),[h,g]=ni({prop:o,defaultProp:s??null,onChange:c,caller:Td}),[_,v]=R.useState(!1),y=Hi(l),b=Ed(n),x=R.useRef(!1),[S,C]=R.useState(0);return R.useEffect(()=>{let e=f.current;if(e)return e.addEventListener(Cd,y),()=>e.removeEventListener(Cd,y)},[y]),(0,z.jsx)(Ad,{scope:n,orientation:r,dir:m,loop:i,currentTabStopId:h,onItemFocus:R.useCallback(e=>g(e),[g]),onItemShiftTab:R.useCallback(()=>v(!0),[]),onFocusableItemAdd:R.useCallback(()=>C(e=>e+1),[]),onFocusableItemRemove:R.useCallback(()=>C(e=>e-1),[]),children:(0,z.jsx)(H.div,{tabIndex:_||S===0?-1:0,"data-orientation":r,...d,ref:p,style:{outline:`none`,...e.style},onMouseDown:U(e.onMouseDown,()=>{x.current=!0}),onFocus:U(e.onFocus,e=>{let t=!x.current;if(e.target===e.currentTarget&&t&&!_){let t=new CustomEvent(Cd,wd);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=b().filter(e=>e.focusable);zd([e.find(e=>e.active),e.find(e=>e.id===h),...e].filter(Boolean).map(e=>e.ref.current),u)}}x.current=!1}),onBlur:U(e.onBlur,()=>v(!1))})})},`RovingFocusGroupImpl`)),Pd=`RovingFocusGroupItem`,Fd=R.forwardRef(Sd(function(e,t){let{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,children:o,...s}=e,c=bi(),l=a||c,u=jd(Pd,n),d=u.currentTabStopId===l,f=Ed(n),{onFocusableItemAdd:p,onFocusableItemRemove:m,currentTabStopId:h}=u,g=bd();return qr(()=>{if(!(!g||!r))return p(),()=>m()},[g,r,p,m]),R.useEffect(()=>{if(!(g||!r))return p(),()=>m()},[g,r,p,m]),(0,z.jsx)(K.ItemSlot,{scope:n,id:l,focusable:r,active:i,children:(0,z.jsx)(H.span,{tabIndex:d?0:-1,"data-orientation":u.orientation,...s,ref:t,onMouseDown:U(e.onMouseDown,e=>{r?u.onItemFocus(l):e.preventDefault()}),onFocus:U(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:U(e.onKeyDown,e=>{if(e.key===`Tab`&&e.shiftKey){u.onItemShiftTab();return}if(e.target!==e.currentTarget)return;let t=Rd(e,u.orientation,u.dir);if(t!==void 0){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let n=f().filter(e=>e.focusable).map(e=>e.ref.current);if(t===`last`)n.reverse();else if(t===`prev`||t===`next`){t===`prev`&&n.reverse();let r=n.indexOf(e.currentTarget);n=u.loop?Bd(n,r+1):n.slice(r+1)}setTimeout(()=>zd(n))}}),children:typeof o==`function`?o({isCurrentTabStop:d,hasTabStop:h!=null}):o})})},`RovingFocusGroupItem`)),Id={ArrowLeft:`prev`,ArrowUp:`prev`,ArrowRight:`next`,ArrowDown:`next`,PageUp:`first`,Home:`first`,PageDown:`last`,End:`last`};function Ld(e,t){return t===`rtl`?e===`ArrowLeft`?`ArrowRight`:e===`ArrowRight`?`ArrowLeft`:e:e}Sd(Ld,`getDirectionAwareKey`);function Rd(e,t,n){let r=Ld(e.key,n);if(!(t===`vertical`&&[`ArrowLeft`,`ArrowRight`].includes(r))&&!(t===`horizontal`&&[`ArrowUp`,`ArrowDown`].includes(r)))return Id[r]}Sd(Rd,`getFocusIntent`);function zd(e,t=!1){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}Sd(zd,`focusFirst`);function Bd(e,t){return e.map((n,r)=>e[(t+r)%e.length])}Sd(Bd,`wrapArray`);var Vd=Md,Hd=Fd,Ud=Object.defineProperty,Wd=(e,t)=>Ud(e,`name`,{value:t,configurable:!0}),Gd=[`Enter`,` `],Kd=[`ArrowDown`,`PageUp`,`Home`],qd=[`ArrowUp`,`PageDown`,`End`],Jd=[...Kd,...qd];[...Gd],[...Gd];var Yd=`Menu`,[Xd,Zd,Qd]=kr(Yd),[$d,ef]=Tr(Yd,[Qd,qu,kd]),tf=qu(),nf=kd(),[rf,af]=$d(Yd),[of,sf]=$d(Yd),cf=Wd(e=>{let{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:a,modal:o=!0}=e,s=tf(t),[c,l]=R.useState(null),u=R.useRef(!1),d=Hi(a),f=zi(i);return R.useEffect(()=>{let e=Wd(()=>{u.current=!0,document.addEventListener(`pointerdown`,t,{capture:!0,once:!0}),document.addEventListener(`pointermove`,t,{capture:!0,once:!0})},`handleKeyDown`),t=Wd(()=>u.current=!1,`handlePointer`);return document.addEventListener(`keydown`,e,{capture:!0}),()=>{document.removeEventListener(`keydown`,e,{capture:!0}),document.removeEventListener(`pointerdown`,t,{capture:!0}),document.removeEventListener(`pointermove`,t,{capture:!0})}},[]),R.useEffect(()=>{if(!n)return;let e=Wd(()=>d(!1),`handleBlur`);return window.addEventListener(`blur`,e),()=>window.removeEventListener(`blur`,e)},[n,d]),(0,z.jsx)(ld,{...s,children:(0,z.jsx)(rf,{scope:t,open:n,onOpenChange:d,content:c,onContentChange:l,children:(0,z.jsx)(of,{scope:t,onClose:R.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:u,dir:f,modal:o,children:r})})})},`Menu`),lf=R.forwardRef(Wd(function(e,t){let{__scopeMenu:n,...r}=e,i=tf(n);return(0,z.jsx)(ud,{...i,...r,ref:t})},`MenuAnchor`)),uf=`MenuPortal`,[df,ff]=$d(uf,{forceMount:void 0}),pf=Wd(e=>{let{__scopeMenu:t,forceMount:n,children:r,container:i}=e,a=af(uf,t);return(0,z.jsx)(df,{scope:t,forceMount:n,children:(0,z.jsx)(ui,{present:n||a.open,children:(0,z.jsx)(xa,{asChild:!0,container:i,children:r})})})},`MenuPortal`),mf=`MenuContent`,[hf,gf]=$d(mf),_f=R.forwardRef(Wd(function(e,t){let n=ff(mf,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=af(mf,e.__scopeMenu),o=sf(mf,e.__scopeMenu);return(0,z.jsx)(Xd.Provider,{scope:e.__scopeMenu,children:(0,z.jsx)(ui,{present:r||a.open,children:(0,z.jsx)(Xd.Slot,{scope:e.__scopeMenu,children:o.modal?(0,z.jsx)(vf,{...i,ref:t}):(0,z.jsx)(yf,{...i,ref:t})})})})},`MenuContent`)),vf=R.forwardRef(Wd(function(e,t){let n=af(mf,e.__scopeMenu),r=R.useRef(null),i=V(t,r);return R.useEffect(()=>{let e=r.current;if(e)return Ko(e)},[]),(0,z.jsx)(xf,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:U(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})},`MenuRootContentModal`)),yf=R.forwardRef(Wd(function(e,t){let n=af(mf,e.__scopeMenu);return(0,z.jsx)(xf,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})},`MenuRootContentNonModal`)),bf=er(`MenuContent.ScrollLock`),xf=R.forwardRef(Wd(function(e,t){let{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:c,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:m,...h}=e,g=af(mf,n),_=sf(mf,n),v=tf(n),y=nf(n),b=Zd(n),[x,S]=R.useState(null),C=R.useRef(null),w=V(t,C,g.onContentChange),T=R.useRef(0),E=R.useRef(``),ee=R.useRef(0),D=R.useRef(null),O=R.useRef(`right`),k=R.useRef(0),A=m?Lo:R.Fragment,j=m?{as:bf,allowPinchZoom:!0}:void 0,M=Wd(e=>{let t=E.current+e,n=b().filter(e=>!e.disabled),r=document.activeElement,i=n.find(e=>e.ref.current===r)?.textValue,a=zf(n.map(e=>e.textValue),t,i),o=n.find(e=>e.textValue===a)?.ref.current;Wd((function e(t){E.current=t,window.clearTimeout(T.current),t!==``&&(T.current=window.setTimeout(()=>e(``),1e3))}),`updateSearch`)(t),o&&setTimeout(()=>o.focus())},`handleTypeaheadSearch`);R.useEffect(()=>()=>window.clearTimeout(T.current),[]),Da();let N=R.useCallback(e=>O.current===D.current?.side&&Vf(e,D.current?.area),[]);return(0,z.jsx)(hf,{scope:n,searchRef:E,onItemEnter:R.useCallback(e=>{N(e)&&e.preventDefault()},[N]),onItemLeave:R.useCallback(e=>{N(e)||(C.current?.focus(),S(null))},[N]),onTriggerLeave:R.useCallback(e=>{N(e)&&e.preventDefault()},[N]),pointerGraceTimerRef:ee,onPointerGraceIntentChange:R.useCallback(e=>{D.current=e},[]),children:(0,z.jsx)(A,{...j,children:(0,z.jsx)(ca,{asChild:!0,trapped:i,onMountAutoFocus:U(a,e=>{e.preventDefault(),C.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:(0,z.jsx)(Xi,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,children:(0,z.jsx)(Vd,{asChild:!0,...y,dir:_.dir,orientation:`vertical`,loop:r,currentTabStopId:x,onCurrentTabStopIdChange:S,onEntryFocus:U(c,e=>{_.isUsingKeyboardRef.current||e.preventDefault()}),preventScrollOnEntryFocus:!0,children:(0,z.jsx)(dd,{role:`menu`,"aria-orientation":`vertical`,"data-state":Pf(g.open),"data-radix-menu-content":``,dir:_.dir,...v,...h,ref:w,style:{outline:`none`,...h.style},onKeyDown:U(h.onKeyDown,e=>{let t=e.target.closest(`[data-radix-menu-content]`)===e.currentTarget,n=e.ctrlKey||e.altKey||e.metaKey,r=e.key.length===1;t&&(e.key===`Tab`&&e.preventDefault(),!n&&r&&M(e.key));let i=C.current;if(e.target!==i||!Jd.includes(e.key))return;e.preventDefault();let a=b().filter(e=>!e.disabled).map(e=>e.ref.current);qd.includes(e.key)&&a.reverse(),Lf(a)}),onBlur:U(e.onBlur,e=>{e.currentTarget.contains(e.target)||(window.clearTimeout(T.current),E.current=``)}),onPointerMove:U(e.onPointerMove,Hf(e=>{let t=e.target,n=k.current!==e.clientX;if(e.currentTarget.contains(t)&&n){let t=e.clientX>k.current?`right`:`left`;O.current=t,k.current=e.clientX}}))})})})})})})},`MenuContentImpl`)),Sf=R.forwardRef(Wd(function(e,t){let{__scopeMenu:n,...r}=e;return(0,z.jsx)(H.div,{...r,ref:t})},`MenuLabel`)),Cf=`MenuItem`,wf=`menu.itemSelect`,Tf=R.forwardRef(Wd(function(e,t){let{disabled:n=!1,onSelect:r,...i}=e,a=R.useRef(null),o=sf(Cf,e.__scopeMenu),s=gf(Cf,e.__scopeMenu),c=V(t,a),l=R.useRef(!1),u=Wd(()=>{let e=a.current;if(!n&&e){let t=new CustomEvent(wf,{bubbles:!0,cancelable:!0});e.addEventListener(wf,e=>r?.(e),{once:!0}),_r(e,t),t.defaultPrevented?l.current=!1:o.onClose()}},`handleSelect`);return(0,z.jsx)(Ef,{...i,ref:c,disabled:n,onClick:U(e.onClick,u),onPointerDown:t=>{e.onPointerDown?.(t),l.current=!0},onPointerUp:U(e.onPointerUp,e=>{l.current||e.currentTarget?.click()}),onKeyDown:U(e.onKeyDown,e=>{n||e.target!==e.currentTarget||(s.searchRef.current===``||e.key!==` `)&&Gd.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())})})},`MenuItem`)),Ef=R.forwardRef(Wd(function(e,t){let{__scopeMenu:n,disabled:r=!1,textValue:i,...a}=e,o=gf(Cf,n),s=nf(n),c=R.useRef(null),l=V(t,c),[u,d]=R.useState(!1),[f,p]=R.useState(``);return R.useEffect(()=>{let e=c.current;e&&p((e.textContent??``).trim())},[a.children]),(0,z.jsx)(Xd.ItemSlot,{scope:n,disabled:r,textValue:i??f,children:(0,z.jsx)(Hd,{asChild:!0,...s,focusable:!r,children:(0,z.jsx)(H.div,{role:`menuitem`,"data-highlighted":u?``:void 0,"aria-disabled":r||void 0,"data-disabled":r?``:void 0,...a,ref:l,onPointerMove:U(e.onPointerMove,Hf(e=>{r?o.onItemLeave(e):(o.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:U(e.onPointerLeave,Hf(e=>o.onItemLeave(e))),onFocus:U(e.onFocus,()=>d(!0)),onBlur:U(e.onBlur,()=>d(!1))})})})},`MenuItemImpl`)),[Df,Of]=$d(`MenuRadioGroup`,{value:void 0,onValueChange:Wd(()=>{},`onValueChange`)}),[kf,Af]=$d(`MenuItemIndicator`,{checked:!1}),jf=R.forwardRef(Wd(function(e,t){let{__scopeMenu:n,...r}=e;return(0,z.jsx)(H.div,{role:`separator`,"aria-orientation":`horizontal`,...r,ref:t})},`MenuSeparator`)),[Mf,Nf]=$d(`MenuSub`);function Pf(e){return e?`open`:`closed`}Wd(Pf,`getOpenState`);function Ff(e){return e===`indeterminate`}Wd(Ff,`isIndeterminate`);function If(e){return Ff(e)?`indeterminate`:e?`checked`:`unchecked`}Wd(If,`getCheckedState`);function Lf(e){let t=document.activeElement;for(let n of e)if(n===t||(n.focus(),document.activeElement!==t))return}Wd(Lf,`focusFirst`);function Rf(e,t){return e.map((n,r)=>e[(t+r)%e.length])}Wd(Rf,`wrapArray`);function zf(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=Rf(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}Wd(zf,`getNextMatch`);function Bf(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}Wd(Bf,`isPointInPolygon`);function Vf(e,t){return t?Bf({x:e.clientX,y:e.clientY},t):!1}Wd(Vf,`isPointerInGraceArea`);function Hf(e){return t=>t.pointerType===`mouse`?e(t):void 0}Wd(Hf,`whenMouse`);var Uf=cf,Wf=lf,Gf=pf,Kf=_f,qf=Sf,Jf=Tf,Yf=jf,Xf=Object.defineProperty,Zf=(e,t)=>Xf(e,`name`,{value:t,configurable:!0}),Qf=`DropdownMenu`,[$f,ep]=Tr(Qf,[ef]),tp=ef(),[np,rp]=$f(Qf),ip=Zf(e=>{let{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=e,c=tp(t),l=R.useRef(null),[u,d]=ni({prop:i,defaultProp:a??!1,onChange:o,caller:Qf});return(0,z.jsx)(np,{scope:t,triggerId:bi(),triggerRef:l,contentId:bi(),open:u,onOpenChange:d,onOpenToggle:R.useCallback(()=>d(e=>!e),[d]),modal:s,children:(0,z.jsx)(Uf,{...c,open:u,onOpenChange:d,dir:r,modal:s,children:n})})},`DropdownMenu`),ap=`DropdownMenuTrigger`,op=R.forwardRef(Zf(function(e,t){let{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,a=rp(ap,n),o=tp(n),s=V(t,a.triggerRef);return(0,z.jsx)(Wf,{asChild:!0,...o,children:(0,z.jsx)(H.button,{type:`button`,id:a.triggerId,"aria-haspopup":`menu`,"aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?`open`:`closed`,"data-disabled":r?``:void 0,disabled:r,...i,ref:s,onPointerDown:U(e.onPointerDown,e=>{!r&&e.button===0&&e.ctrlKey===!1&&(a.onOpenToggle(),a.open||e.preventDefault())}),onKeyDown:U(e.onKeyDown,e=>{r||([`Enter`,` `].includes(e.key)&&a.onOpenToggle(),e.key===`ArrowDown`&&a.onOpenChange(!0),[`Enter`,` `,`ArrowDown`].includes(e.key)&&e.preventDefault())})})})},`DropdownMenuTrigger`)),sp=Zf(e=>{let{__scopeDropdownMenu:t,...n}=e,r=tp(t);return(0,z.jsx)(Gf,{...r,...n})},`DropdownMenuPortal`),cp=`DropdownMenuContent`,lp=R.forwardRef(Zf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=rp(cp,n),a=tp(n),o=R.useRef(!1);return(0,z.jsx)(Kf,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...r,ref:t,onCloseAutoFocus:U(e.onCloseAutoFocus,e=>{o.current||i.triggerRef.current?.focus(),o.current=!1,e.preventDefault()}),onInteractOutside:U(e.onInteractOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0,r=t.button===2||n;(!i.modal||r)&&(o.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-dropdown-menu-content-available-width":`var(--radix-popper-available-width)`,"--radix-dropdown-menu-content-available-height":`var(--radix-popper-available-height)`,"--radix-dropdown-menu-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-dropdown-menu-trigger-height":`var(--radix-popper-anchor-height)`}})},`DropdownMenuContent`)),up=R.forwardRef(Zf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=tp(n);return(0,z.jsx)(qf,{...i,...r,ref:t})},`DropdownMenuLabel`)),dp=R.forwardRef(Zf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=tp(n);return(0,z.jsx)(Jf,{...i,...r,ref:t})},`DropdownMenuItem`)),fp=R.forwardRef(Zf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=tp(n);return(0,z.jsx)(Yf,{...i,...r,ref:t})},`DropdownMenuSeparator`)),pp=ip,mp=op,hp=sp,gp=lp,_p=up,vp=dp,yp=fp,bp=Object.defineProperty,xp=R.forwardRef(((e,t)=>bp(e,`name`,{value:t,configurable:!0}))(function(e,t){return(0,z.jsx)(H.label,{...e,ref:t,onMouseDown:t=>{t.target.closest(`button, input, select, textarea`)||(e.onMouseDown?.(t),!t.defaultPrevented&&t.detail>1&&t.preventDefault())}})},`Label`)),Sp=Object.defineProperty,Cp=(e,t)=>Sp(e,`name`,{value:t,configurable:!0});function wp(e){let t=R.useRef({value:e,previous:e});return R.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}Cp(wp,`usePrevious`);var Tp=Object.defineProperty,Ep=(e,t)=>Tp(e,`name`,{value:t,configurable:!0});function Dp(e,[t,n]){return Math.min(n,Math.max(t,e))}Ep(Dp,`clamp`);var Op=Object.defineProperty,kp=(e,t)=>Op(e,`name`,{value:t,configurable:!0}),Ap=`Popover`,[jp,Mp]=Tr(Ap,[qu]),Np=qu(),[Pp,Fp]=jp(Ap),Ip=kp(e=>{let{__scopePopover:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!1}=e,s=Np(t),c=R.useRef(null),[l,u]=R.useState(!1),[d,f]=ni({prop:r,defaultProp:i??!1,onChange:a,caller:Ap});return(0,z.jsx)(ld,{...s,children:(0,z.jsx)(Pp,{scope:t,contentId:bi(),triggerRef:c,open:d,onOpenChange:f,onOpenToggle:R.useCallback(()=>f(e=>!e),[f]),hasCustomAnchor:l,onCustomAnchorAdd:R.useCallback(()=>u(!0),[]),onCustomAnchorRemove:R.useCallback(()=>u(!1),[]),modal:o,children:n})})},`Popover`),Lp=`PopoverTrigger`,Rp=R.forwardRef(kp(function(e,t){let{__scopePopover:n,...r}=e,i=Fp(Lp,n),a=Np(n),o=V(t,i.triggerRef),s=(0,z.jsx)(H.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":Yp(i.open),...r,ref:o,onClick:U(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?s:(0,z.jsx)(ud,{asChild:!0,...a,children:s})},`PopoverTrigger`)),zp=`PopoverPortal`,[Bp,Vp]=jp(zp,{forceMount:void 0}),Hp=kp(e=>{let{__scopePopover:t,forceMount:n,children:r,container:i}=e,a=Fp(zp,t);return(0,z.jsx)(Bp,{scope:t,forceMount:n,children:(0,z.jsx)(ui,{present:n||a.open,children:(0,z.jsx)(xa,{asChild:!0,container:i,children:r})})})},`PopoverPortal`),Up=`PopoverContent`,Wp=R.forwardRef(kp(function(e,t){let n=Vp(Up,e.__scopePopover),{forceMount:r=n.forceMount,...i}=e,a=Fp(Up,e.__scopePopover);return(0,z.jsx)(ui,{present:r||a.open,children:a.modal?(0,z.jsx)(Kp,{...i,ref:t}):(0,z.jsx)(qp,{...i,ref:t})})},`PopoverContent`)),Gp=er(`PopoverContent.RemoveScroll`),Kp=R.forwardRef(kp(function(e,t){let n=Fp(Up,e.__scopePopover),r=R.useRef(null),i=V(t,r),a=R.useRef(!1);return R.useEffect(()=>{let e=r.current;if(e)return Ko(e)},[]),(0,z.jsx)(Lo,{as:Gp,allowPinchZoom:!0,children:(0,z.jsx)(Jp,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:U(e.onCloseAutoFocus,e=>{e.preventDefault(),a.current||n.triggerRef.current?.focus()}),onPointerDownOutside:U(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0,r=t.button===2||n;a.current=r},{checkForDefaultPrevented:!1}),onFocusOutside:U(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1})})})},`PopoverContentModal`)),qp=R.forwardRef(kp(function(e,t){let n=Fp(Up,e.__scopePopover),r=R.useRef(!1),i=R.useRef(!1);return(0,z.jsx)(Jp,{...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()}})},`PopoverContentNonModal`)),Jp=R.forwardRef(kp(function(e,t){let{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onInteractOutside:u,...d}=e,f=Fp(Up,n),p=Np(n);return Da(),(0,z.jsx)(ca,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,z.jsx)(Xi,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:u,onEscapeKeyDown:s,onPointerDownOutside:c,onFocusOutside:l,onDismiss:()=>f.onOpenChange(!1),deferPointerDownOutside:!0,children:(0,z.jsx)(dd,{"data-state":Yp(f.open),role:`dialog`,id:f.contentId,...p,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-popover-content-available-width":`var(--radix-popper-available-width)`,"--radix-popover-content-available-height":`var(--radix-popper-available-height)`,"--radix-popover-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-popover-trigger-height":`var(--radix-popper-anchor-height)`}})})})},`PopoverContentImpl`));function Yp(e){return e?`open`:`closed`}kp(Yp,`getState`);var Xp=Ip,Zp=Rp,Qp=Hp,$p=Wp,em=Object.defineProperty,tm=(e,t)=>em(e,`name`,{value:t,configurable:!0}),nm=[` `,`Enter`,`ArrowUp`,`ArrowDown`],rm=[` `,`Enter`],im=`Select`,[am,om,sm]=kr(im),[cm,lm]=Tr(im,[sm,qu]),um=qu(),[dm,fm]=cm(im),[pm,mm]=cm(im);function hm(e){let{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:a,value:o,defaultValue:s,onValueChange:c,dir:l,name:u,autoComplete:d,disabled:f,required:p,form:m,internal_do_not_use_render:h}=e,g=um(t),[_,v]=R.useState(null),[y,b]=R.useState(null),[x,S]=R.useState(!1),C=zi(l),[w,T]=ni({prop:r,defaultProp:i??!1,onChange:a,caller:im}),[E,ee]=ni({prop:o,defaultProp:s,onChange:c,caller:im}),D=R.useRef(null),O=R.useRef(E);R.useEffect(()=>{let e=m?_?.ownerDocument.getElementById(m):_?.form;if(e instanceof HTMLFormElement){let t=tm(()=>ee(O.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[m,_,ee]);let k=!_||!!m||!!_.closest(`form`),[A,j]=R.useState(new Set),M=bi(),N=Array.from(A).map(e=>e.props.value).join(`;`),te=R.useCallback(e=>{j(t=>new Set(t).add(e))},[]),P=R.useCallback(e=>{j(t=>{let n=new Set(t);return n.delete(e),n})},[]),F={required:p,trigger:_,onTriggerChange:v,valueNode:y,onValueNodeChange:b,valueNodeHasChildren:x,onValueNodeHasChildrenChange:S,contentId:M,value:E,onValueChange:ee,open:w,onOpenChange:T,dir:C,triggerPointerDownPosRef:D,disabled:f,name:u,autoComplete:d,form:m,nativeOptions:A,nativeSelectKey:N,isFormControl:k};return(0,z.jsx)(ld,{...g,children:(0,z.jsx)(dm,{scope:t,...F,children:(0,z.jsx)(am.Provider,{scope:t,children:(0,z.jsx)(pm,{scope:t,onNativeOptionAdd:te,onNativeOptionRemove:P,children:nh(h)?h(F):n})})})})}tm(hm,`SelectProvider`);var gm=tm(e=>{let{__scopeSelect:t,children:n,...r}=e;return(0,z.jsx)(hm,{__scopeSelect:t,...r,internal_do_not_use_render:({isFormControl:e})=>(0,z.jsxs)(z.Fragment,{children:[n,e?(0,z.jsx)(th,{__scopeSelect:t}):null]})})},`Select`),_m=`SelectTrigger`,vm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,disabled:r=!1,...i}=e,a=um(n),o=fm(_m,n),s=o.disabled||r,c=V(t,o.onTriggerChange),l=om(n),u=R.useRef(`touch`),[d,f,p]=ih(e=>{let t=l().filter(e=>!e.disabled),n=ah(t,e,t.find(e=>e.value===o.value));n!==void 0&&o.onValueChange(n.value)}),m=tm(e=>{s||(o.onOpenChange(!0),p()),e&&(o.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})},`handleOpen`);return(0,z.jsx)(ud,{asChild:!0,...a,children:(0,z.jsx)(H.button,{type:`button`,role:`combobox`,"aria-controls":o.open?o.contentId:void 0,"aria-expanded":o.open,"aria-required":o.required,"aria-autocomplete":`none`,dir:o.dir,"data-state":o.open?`open`:`closed`,disabled:s,"data-disabled":s?``:void 0,"data-placeholder":rh(o.value)?``:void 0,...i,ref:c,onClick:U(i.onClick,e=>{e.currentTarget.focus(),u.current!==`mouse`&&m(e)}),onPointerDown:U(i.onPointerDown,e=>{u.current=e.pointerType;let t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),e.button===0&&e.ctrlKey===!1&&e.pointerType===`mouse`&&(m(e),e.preventDefault())}),onKeyDown:U(i.onKeyDown,e=>{let t=d.current!==``;!(e.ctrlKey||e.altKey||e.metaKey)&&e.key.length===1&&f(e.key),!(t&&e.key===` `)&&nm.includes(e.key)&&(m(),e.preventDefault())})})})},`SelectTrigger`)),ym=`SelectValue`,bm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,className:r,style:i,children:a,placeholder:o=``,...s}=e,c=fm(ym,n),{onValueNodeHasChildrenChange:l}=c,u=a!==void 0,d=V(t,c.onValueNodeChange);qr(()=>{l(u)},[l,u]);let f=rh(c.value);return(0,z.jsx)(H.span,{...s,asChild:!f&&s.asChild,ref:d,style:{pointerEvents:`none`},children:(0,z.jsx)(R.Fragment,{children:f?o:a},f?`placeholder`:`value`)})},`SelectValue`)),xm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,children:r,...i}=e;return(0,z.jsx)(H.span,{"aria-hidden":!0,...i,ref:t,children:r||`▼`})},`SelectIcon`)),[Sm,Cm]=cm(`SelectPortal`,{forceMount:void 0}),wm=tm(e=>{let{__scopeSelect:t,forceMount:n,...r}=e;return(0,z.jsx)(Sm,{scope:e.__scopeSelect,forceMount:n,children:(0,z.jsx)(xa,{asChild:!0,...r})})},`SelectPortal`),Tm=`SelectContent`,Em=R.forwardRef(tm(function(e,t){let n=Cm(Tm,e.__scopeSelect),{forceMount:r=n.forceMount,...i}=e,a=fm(Tm,e.__scopeSelect),[o,s]=R.useState();return qr(()=>{s(new DocumentFragment)},[]),(0,z.jsx)(ui,{present:r||a.open,children:({present:e})=>e?(0,z.jsx)(Mm,{...i,ref:t}):(0,z.jsx)(Dm,{...i,fragment:o})})},`SelectContent`)),Dm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,children:r,fragment:i}=e;return i?mr.createPortal((0,z.jsx)(km,{scope:n,children:(0,z.jsx)(am.Slot,{scope:n,children:(0,z.jsx)(`div`,{ref:t,children:r})})}),i):null},`SelectContentFragment`)),Om=10,[km,Am]=cm(Tm),jm=er(`SelectContent.RemoveScroll`),Mm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n}=e,{position:r=`item-aligned`,onCloseAutoFocus:i,onEscapeKeyDown:a,onPointerDownOutside:o,side:s,sideOffset:c,align:l,alignOffset:u,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:m,hideWhenDetached:h,avoidCollisions:g,..._}=e,v=fm(Tm,n),[y,b]=R.useState(null),[x,S]=R.useState(null),C=V(t,b),[w,T]=R.useState(null),[E,ee]=R.useState(null),D=om(n),[O,k]=R.useState(!1),A=R.useRef(!1);R.useEffect(()=>{if(y)return Ko(y)},[y]),Da();let j=R.useCallback(e=>{let[t,...n]=D().map(e=>e.ref.current),[r]=n.slice(-1),i=document.activeElement;for(let n of e)if(n===i||(n?.scrollIntoView({block:`nearest`}),n===t&&x&&(x.scrollTop=0),n===r&&x&&(x.scrollTop=x.scrollHeight),n?.focus(),document.activeElement!==i))return},[D,x]),M=R.useCallback(()=>j([w,y]),[j,w,y]);R.useEffect(()=>{O&&M()},[O,M]);let{onOpenChange:N,triggerPointerDownPosRef:te}=v;R.useEffect(()=>{if(y){let e={x:0,y:0},t=tm(t=>{e={x:Math.abs(Math.round(t.pageX)-(te.current?.x??0)),y:Math.abs(Math.round(t.pageY)-(te.current?.y??0))}},`handlePointerMove`),n=tm(n=>{e.x<=10&&e.y<=10?n.preventDefault():n.composedPath().includes(y)||N(!1),document.removeEventListener(`pointermove`,t),te.current=null},`handlePointerUp`);return te.current!==null&&(document.addEventListener(`pointermove`,t),document.addEventListener(`pointerup`,n,{capture:!0,once:!0})),()=>{document.removeEventListener(`pointermove`,t),document.removeEventListener(`pointerup`,n,{capture:!0})}}},[y,N,te]),R.useEffect(()=>{let e=tm(()=>N(!1),`close`);return window.addEventListener(`blur`,e),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`blur`,e),window.removeEventListener(`resize`,e)}},[N]);let[P,F]=ih(e=>{let t=D().filter(e=>!e.disabled),n=ah(t,e,t.find(e=>e.ref.current===document.activeElement));n&&setTimeout(()=>n.ref.current?.focus())}),ne=R.useCallback((e,t,n)=>{let r=!A.current&&!n;(v.value!==void 0&&v.value===t||r)&&(T(e),r&&(A.current=!0))},[v.value]),re=R.useCallback(()=>y?.focus(),[y]),ie=R.useCallback((e,t,n)=>{let r=!A.current&&!n;(v.value!==void 0&&v.value===t||r)&&ee(e)},[v.value]),ae=r===`popper`?Pm:Nm,I=ae===Pm?{side:s,sideOffset:c,align:l,alignOffset:u,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:m,hideWhenDetached:h,avoidCollisions:g}:{};return(0,z.jsx)(km,{scope:n,content:y,viewport:x,onViewportChange:S,itemRefCallback:ne,selectedItem:w,onItemLeave:re,itemTextRefCallback:ie,focusSelectedItem:M,selectedItemText:E,position:r,isPositioned:O,searchRef:P,children:(0,z.jsx)(Lo,{as:jm,allowPinchZoom:!0,children:(0,z.jsx)(ca,{asChild:!0,trapped:v.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:U(i,e=>{v.trigger?.focus({preventScroll:!0}),e.preventDefault()}),children:(0,z.jsx)(Xi,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>v.onOpenChange(!1),children:(0,z.jsx)(ae,{role:`listbox`,id:v.contentId,"data-state":v.open?`open`:`closed`,dir:v.dir,onContextMenu:e=>e.preventDefault(),..._,...I,onPlaced:()=>k(!0),ref:C,style:{display:`flex`,flexDirection:`column`,outline:`none`,..._.style},onKeyDown:U(_.onKeyDown,e=>{let t=e.ctrlKey||e.altKey||e.metaKey;if(e.key===`Tab`&&e.preventDefault(),!t&&e.key.length===1&&F(e.key),[`ArrowUp`,`ArrowDown`,`Home`,`End`].includes(e.key)){let t=D().filter(e=>!e.disabled).map(e=>e.ref.current);if([`ArrowUp`,`End`].includes(e.key)&&(t=t.slice().reverse()),[`ArrowUp`,`ArrowDown`].includes(e.key)){let n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout(()=>j(t)),e.preventDefault()}})})})})})})},`SelectContentImpl`)),Nm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,onPlaced:r,...i}=e,a=fm(Tm,n),o=Am(Tm,n),[s,c]=R.useState(null),[l,u]=R.useState(null),d=V(t,u),f=om(n),p=R.useRef(!1),m=R.useRef(!0),{viewport:h,selectedItem:g,selectedItemText:_,focusSelectedItem:v}=o,y=R.useCallback(()=>{if(a.trigger&&a.valueNode&&s&&l&&h&&g&&_){let e=a.trigger.getBoundingClientRect(),t=l.getBoundingClientRect(),n=a.valueNode.getBoundingClientRect(),i=_.getBoundingClientRect();if(a.dir!==`rtl`){let r=i.left-t.left,a=n.left-r,o=e.left-a,c=e.width+o,l=Math.max(c,t.width),u=window.innerWidth-Om,d=Dp(a,[Om,Math.max(Om,u-l)]);s.style.minWidth=c+`px`,s.style.left=d+`px`}else{let r=t.right-i.right,a=window.innerWidth-n.right-r,o=window.innerWidth-e.right-a,c=e.width+o,l=Math.max(c,t.width),u=window.innerWidth-Om,d=Dp(a,[Om,Math.max(Om,u-l)]);s.style.minWidth=c+`px`,s.style.right=d+`px`}let o=f(),c=window.innerHeight-Om*2,u=h.scrollHeight,d=window.getComputedStyle(l),m=parseInt(d.borderTopWidth,10),v=parseInt(d.paddingTop,10),y=parseInt(d.borderBottomWidth,10),b=parseInt(d.paddingBottom,10),x=m+v+u+b+y,S=Math.min(g.offsetHeight*5,x),C=window.getComputedStyle(h),w=parseInt(C.paddingTop,10),T=parseInt(C.paddingBottom,10),E=e.top+e.height/2-Om,ee=c-E,D=g.offsetHeight/2,O=g.offsetTop+D,k=m+v+O,A=x-k;if(k<=E){let e=o.length>0&&g===o[o.length-1].ref.current;s.style.bottom=`0px`;let t=l.clientHeight-h.offsetTop-h.offsetHeight,n=k+Math.max(ee,D+(e?T:0)+t+y);s.style.height=n+`px`}else{let e=o.length>0&&g===o[0].ref.current;s.style.top=`0px`;let t=Math.max(E,m+h.offsetTop+(e?w:0)+D)+A;s.style.height=t+`px`,h.scrollTop=k-E+h.offsetTop}s.style.margin=`${Om}px 0`,s.style.minHeight=S+`px`,s.style.maxHeight=c+`px`,r?.(),requestAnimationFrame(()=>p.current=!0)}},[f,a.trigger,a.valueNode,s,l,h,g,_,a.dir,r]);qr(()=>y(),[y]);let[b,x]=R.useState();qr(()=>{l&&x(window.getComputedStyle(l).zIndex)},[l]);let S=R.useCallback(e=>{e&&m.current===!0&&(y(),v?.(),m.current=!1)},[y,v]);return(0,z.jsx)(Fm,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:p,onScrollButtonChange:S,children:(0,z.jsx)(`div`,{ref:c,style:{display:`flex`,flexDirection:`column`,position:`fixed`,zIndex:b},children:(0,z.jsx)(H.div,{...i,ref:d,style:{boxSizing:`border-box`,maxHeight:`100%`,...i.style}})})})},`SelectItemAlignedPosition`)),Pm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,align:r=`start`,collisionPadding:i=Om,...a}=e,o=um(n);return(0,z.jsx)(dd,{...o,...a,ref:t,align:r,collisionPadding:i,style:{boxSizing:`border-box`,...a.style,"--radix-select-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-select-content-available-width":`var(--radix-popper-available-width)`,"--radix-select-content-available-height":`var(--radix-popper-available-height)`,"--radix-select-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-select-trigger-height":`var(--radix-popper-anchor-height)`}})},`SelectPopperPosition`)),[Fm,Im]=cm(Tm,{}),Lm=`SelectViewport`,Rm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,nonce:r,...i}=e,a=Am(Lm,n),o=Im(Lm,n),s=V(t,a.onViewportChange),c=R.useRef(0);return(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`style`,{dangerouslySetInnerHTML:{__html:`[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}`},nonce:r}),(0,z.jsx)(am.Slot,{scope:n,children:(0,z.jsx)(H.div,{"data-radix-select-viewport":``,role:`presentation`,...i,ref:s,style:{position:`relative`,flex:1,overflow:`hidden auto`,...i.style},onScroll:U(i.onScroll,e=>{let t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=o;if(r?.current&&n){let e=Math.abs(c.current-t.scrollTop);if(e>0){let r=window.innerHeight-Om*2,i=parseFloat(n.style.minHeight),a=parseFloat(n.style.height),o=Math.max(i,a);if(o<r){let i=o+e,a=Math.min(r,i),s=i-a;n.style.height=a+`px`,n.style.bottom===`0px`&&(t.scrollTop=s>0?s:0,n.style.justifyContent=`flex-end`)}}}c.current=t.scrollTop})})})]})},`SelectViewport`)),[zm,Bm]=cm(`SelectGroup`),Vm=`SelectItem`,[Hm,Um]=cm(Vm),Wm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,value:r,disabled:i=!1,textValue:a,...o}=e,s=fm(Vm,n),c=Am(Vm,n),l=s.value===r,[u,d]=R.useState(a??``),[f,p]=R.useState(!1),m=V(t,Hi(e=>c.itemRefCallback?.(e,r,i))),h=bi(),g=R.useRef(`touch`),_=tm(()=>{i||(s.onValueChange(r),s.onOpenChange(!1))},`handleSelect`);return(0,z.jsx)(Hm,{scope:n,value:r,disabled:i,textId:h,isSelected:l,onItemTextChange:R.useCallback(e=>{d(t=>t||(e?.textContent??``).trim())},[]),children:(0,z.jsx)(am.ItemSlot,{scope:n,value:r,disabled:i,textValue:u,children:(0,z.jsx)(H.div,{role:`option`,"aria-labelledby":h,"data-highlighted":f?``:void 0,"aria-selected":l&&f,"data-state":l?`checked`:`unchecked`,"aria-disabled":i||void 0,"data-disabled":i?``:void 0,tabIndex:i?void 0:-1,...o,ref:m,onFocus:U(o.onFocus,()=>p(!0)),onBlur:U(o.onBlur,()=>p(!1)),onClick:U(o.onClick,()=>{g.current!==`mouse`&&_()}),onPointerUp:U(o.onPointerUp,()=>{g.current===`mouse`&&_()}),onPointerDown:U(o.onPointerDown,e=>{g.current=e.pointerType}),onPointerMove:U(o.onPointerMove,e=>{g.current=e.pointerType,i?c.onItemLeave?.():g.current===`mouse`&&e.currentTarget.focus({preventScroll:!0})}),onPointerLeave:U(o.onPointerLeave,e=>{e.currentTarget===document.activeElement&&c.onItemLeave?.()}),onKeyDown:U(o.onKeyDown,e=>{i||e.target!==e.currentTarget||(c.searchRef?.current===``||e.key!==` `)&&(rm.includes(e.key)&&_(),e.key===` `&&e.preventDefault())})})})})},`SelectItem`)),Gm=`SelectItemText`,Km=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,className:r,style:i,...a}=e,o=fm(Gm,n),s=Am(Gm,n),c=Um(Gm,n),l=mm(Gm,n),[u,d]=R.useState(null),f=Hi(e=>s.itemTextRefCallback?.(e,c.value,c.disabled)),p=V(t,d,c.onItemTextChange,f),m=u?.textContent,h=R.useMemo(()=>(0,z.jsx)(`option`,{value:c.value,disabled:c.disabled,children:m},c.value),[c.disabled,c.value,m]),{onNativeOptionAdd:g,onNativeOptionRemove:_}=l;return qr(()=>(g(h),()=>_(h)),[g,_,h]),(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(H.span,{id:c.textId,...a,ref:p}),c.isSelected&&o.valueNode&&!o.valueNodeHasChildren&&!rh(o.value)?mr.createPortal(a.children,o.valueNode):null]})},`SelectItemText`)),qm=`SelectItemIndicator`,Jm=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,...r}=e;return Um(qm,n).isSelected?(0,z.jsx)(H.span,{"aria-hidden":!0,...r,ref:t}):null},`SelectItemIndicator`)),Ym=`SelectScrollUpButton`,Xm=R.forwardRef(tm(function(e,t){let n=Am(Ym,e.__scopeSelect),r=Im(Ym,e.__scopeSelect),[i,a]=R.useState(!1),o=V(t,r.onScrollButtonChange);return qr(()=>{if(n.viewport&&n.isPositioned){let e=function(){let e=t.scrollTop>0;a(e)};tm(e,`handleScroll`);let t=n.viewport;return e(),t.addEventListener(`scroll`,e),()=>t.removeEventListener(`scroll`,e)}},[n.viewport,n.isPositioned]),i?(0,z.jsx)($m,{...e,ref:o,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop-=t.offsetHeight)}}):null},`SelectScrollUpButton`)),Zm=`SelectScrollDownButton`,Qm=R.forwardRef(tm(function(e,t){let n=Am(Zm,e.__scopeSelect),r=Im(Zm,e.__scopeSelect),[i,a]=R.useState(!1),o=V(t,r.onScrollButtonChange);return qr(()=>{if(n.viewport&&n.isPositioned){let e=function(){let e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;a(n)};tm(e,`handleScroll`);let t=n.viewport;return e(),t.addEventListener(`scroll`,e),()=>t.removeEventListener(`scroll`,e)}},[n.viewport,n.isPositioned]),i?(0,z.jsx)($m,{...e,ref:o,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop+=t.offsetHeight)}}):null},`SelectScrollDownButton`)),$m=R.forwardRef(tm(function(e,t){let{__scopeSelect:n,onAutoScroll:r,...i}=e,a=Am(`SelectScrollButton`,n),o=R.useRef(null),s=om(n),c=R.useCallback(()=>{o.current!==null&&(window.clearInterval(o.current),o.current=null)},[]);return R.useEffect(()=>()=>c(),[c]),qr(()=>{s().find(e=>e.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:`nearest`})},[s]),(0,z.jsx)(H.div,{"aria-hidden":!0,...i,ref:t,style:{flexShrink:0,...i.style},onPointerDown:U(i.onPointerDown,()=>{o.current===null&&(o.current=window.setInterval(r,50))}),onPointerMove:U(i.onPointerMove,()=>{a.onItemLeave?.(),o.current===null&&(o.current=window.setInterval(r,50))}),onPointerLeave:U(i.onPointerLeave,()=>{c()})})},`SelectScrollButtonImpl`)),eh=`SelectBubbleInput`,th=R.forwardRef(tm(function({__scopeSelect:e,...t},n){let r=fm(eh,e),{value:i,onValueChange:a,required:o,disabled:s,name:c,autoComplete:l,form:u}=r,{nativeOptions:d,nativeSelectKey:f}=r,p=R.useRef(null),m=V(n,p),h=i??``,g=wp(h),_=Array.from(d).some(e=>(e.props.value??``)===``);return R.useEffect(()=>{let e=p.current;if(!e)return;let t=window.HTMLSelectElement.prototype,n=Object.getOwnPropertyDescriptor(t,`value`).set;if(g!==h&&n){let t=new Event(`change`,{bubbles:!0});n.call(e,h),e.dispatchEvent(t)}},[g,h]),(0,z.jsxs)(H.select,{"aria-hidden":!0,required:o,tabIndex:-1,name:c,autoComplete:l,disabled:s,form:u,onChange:e=>a(e.target.value),...t,style:{...br,...t.style},ref:m,defaultValue:h,children:[rh(i)&&!_?(0,z.jsx)(`option`,{value:``}):null,Array.from(d)]},f)},`SelectBubbleInput`));function nh(e){return typeof e==`function`}tm(nh,`isFunction`);function rh(e){return e===``||e===void 0}tm(rh,`shouldShowPlaceholder`);function ih(e){let t=Hi(e),n=R.useRef(``),r=R.useRef(0),i=R.useCallback(e=>{let i=n.current+e;t(i),tm((function e(t){n.current=t,window.clearTimeout(r.current),t!==``&&(r.current=window.setTimeout(()=>e(``),1e3))}),`updateSearch`)(i)},[t]),a=R.useCallback(()=>{n.current=``,window.clearTimeout(r.current)},[]);return R.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,a]}tm(ih,`useTypeaheadSearch`);function ah(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=oh(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.textValue.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}tm(ah,`findNextItem`);function oh(e,t){return e.map((n,r)=>e[(t+r)%e.length])}tm(oh,`wrapArray`);var sh=Object.defineProperty,ch=(e,t)=>sh(e,`name`,{value:t,configurable:!0}),lh=`horizontal`,uh=[`horizontal`,`vertical`],dh=R.forwardRef(ch(function(e,t){let{decorative:n,orientation:r=lh,...i}=e,a=fh(r)?r:lh,o=n?{role:`none`}:{"aria-orientation":a===`vertical`?a:void 0,role:`separator`};return(0,z.jsx)(H.div,{"data-orientation":a,...o,...i,ref:t})},`Separator`));function fh(e){return uh.includes(e)}ch(fh,`isValidOrientation`);var ph=dh,mh=Object.defineProperty,hh=(e,t)=>mh(e,`name`,{value:t,configurable:!0}),[gh,_h]=Tr(`Tooltip`,[qu]),vh=qu(),yh=`TooltipProvider`,bh=700,xh=`tooltip.open`,[Sh,Ch]=gh(yh),wh=hh(e=>{let{__scopeTooltip:t,delayDuration:n=bh,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:a}=e,o=R.useRef(!0),s=R.useRef(!1),c=R.useRef(0);return R.useEffect(()=>{let e=c.current;return()=>window.clearTimeout(e)},[]),(0,z.jsx)(Sh,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:R.useCallback(()=>{r<=0||(window.clearTimeout(c.current),o.current=!1)},[r]),onClose:R.useCallback(()=>{r<=0||(window.clearTimeout(c.current),c.current=window.setTimeout(()=>o.current=!0,r))},[r]),isPointerInTransitRef:s,onPointerInTransitChange:R.useCallback(e=>{s.current=e},[]),disableHoverableContent:i,children:a})},`TooltipProvider`),Th=`Tooltip`,[Eh,Dh]=gh(Th),Oh=hh(e=>{let{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,c=Ch(Th,e.__scopeTooltip),l=vh(t),[u,d]=R.useState(null),[f,p]=R.useState(void 0),m=bi(),h=R.useRef(0),g=o??c.disableHoverableContent,_=s??c.delayDuration,v=R.useRef(!1),[y,b]=ni({prop:r,defaultProp:i??!1,onChange:hh(e=>{e?(c.onOpen(),document.dispatchEvent(new CustomEvent(xh))):c.onClose(),a?.(e)},`onChange`),caller:Th}),x=R.useMemo(()=>y?v.current?`delayed-open`:`instant-open`:`closed`,[y]),S=R.useCallback(()=>{window.clearTimeout(h.current),h.current=0,v.current=!1,b(!0)},[b]),C=R.useCallback(()=>{window.clearTimeout(h.current),h.current=0,b(!1)},[b]),w=R.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{v.current=!0,b(!0),h.current=0},_)},[_,b]);R.useEffect(()=>()=>{h.current&&=(window.clearTimeout(h.current),0)},[]);let T=f??m;return(0,z.jsx)(ld,{...l,children:(0,z.jsx)(Eh,{scope:t,contentId:T,setContentId:p,open:y,stateAttribute:x,trigger:u,onTriggerChange:d,onTriggerEnter:R.useCallback(()=>{c.isOpenDelayedRef.current?w():S()},[c.isOpenDelayedRef,w,S]),onTriggerLeave:R.useCallback(()=>{g?C():(window.clearTimeout(h.current),h.current=0)},[C,g]),onOpen:S,onClose:C,disableHoverableContent:g,children:n})})},`Tooltip`),kh=`TooltipTrigger`,Ah=R.forwardRef(hh(function(e,t){let{__scopeTooltip:n,...r}=e,i=Dh(kh,n),a=Ch(kh,n),o=vh(n),s=V(t,R.useRef(null),i.onTriggerChange),c=R.useRef(!1),l=R.useRef(!1),u=R.useCallback(()=>c.current=!1,[]);return R.useEffect(()=>()=>document.removeEventListener(`pointerup`,u),[u]),(0,z.jsx)(ud,{asChild:!0,...o,children:(0,z.jsx)(H.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:s,onPointerMove:U(e.onPointerMove,e=>{e.pointerType!==`touch`&&!l.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),l.current=!0)}),onPointerLeave:U(e.onPointerLeave,()=>{i.onTriggerLeave(),l.current=!1}),onPointerDown:U(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener(`pointerup`,u,{once:!0})}),onFocus:U(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:U(e.onBlur,i.onClose),onClick:U(e.onClick,i.onClose)})})},`TooltipTrigger`)),jh=`TooltipPortal`,[Mh,Nh]=gh(jh,{forceMount:void 0}),Ph=hh(e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,a=Dh(jh,t);return(0,z.jsx)(Mh,{scope:t,forceMount:n,children:(0,z.jsx)(ui,{present:n||a.open,children:(0,z.jsx)(xa,{asChild:!0,container:i,children:r})})})},`TooltipPortal`),Fh=`TooltipContent`,Ih=R.forwardRef(hh(function(e,t){let n=Nh(Fh,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i=`top`,...a}=e,o=Dh(Fh,e.__scopeTooltip);return(0,z.jsx)(ui,{present:r||o.open,children:o.disableHoverableContent?(0,z.jsx)(zh,{side:i,...a,ref:t}):(0,z.jsx)(Lh,{side:i,...a,ref:t})})},`TooltipContent`)),Lh=R.forwardRef(hh(function(e,t){let n=Dh(Fh,e.__scopeTooltip),r=Ch(Fh,e.__scopeTooltip),i=R.useRef(null),a=V(t,i),[o,s]=R.useState(null),{trigger:c,onClose:l}=n,u=i.current,{onPointerInTransitChange:d}=r,f=R.useCallback(()=>{s(null),d(!1)},[d]),p=R.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},i=Hh(r,Vh(r,n.getBoundingClientRect())),a=Uh(t.getBoundingClientRect()),o=Gh([...i,...a]);s(o),d(!0)},[d]);return R.useEffect(()=>()=>f(),[f]),R.useEffect(()=>{if(c&&u){let e=hh(e=>p(e,u),`handleTriggerLeave`),t=hh(e=>p(e,c),`handleContentLeave`);return c.addEventListener(`pointerleave`,e),u.addEventListener(`pointerleave`,t),()=>{c.removeEventListener(`pointerleave`,e),u.removeEventListener(`pointerleave`,t)}}},[c,u,p,f]),R.useEffect(()=>{if(o){let e=hh(e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=c?.contains(t)||u?.contains(t),i=!Wh(n,o);r?f():i&&(f(),l())},`handleTrackPointerGrace`);return document.addEventListener(`pointermove`,e),()=>document.removeEventListener(`pointermove`,e)}},[c,u,o,l,f]),(0,z.jsx)(zh,{...e,ref:a})},`TooltipContentHoverable`)),Rh=rr(`TooltipContent`),zh=R.forwardRef(hh(function(e,t){let{__scopeTooltip:n,children:r,"aria-label":i,id:a,onEscapeKeyDown:o,onPointerDownOutside:s,...c}=e,l=Dh(Fh,n),u=vh(n),{onClose:d}=l;R.useEffect(()=>(document.addEventListener(xh,d),()=>document.removeEventListener(xh,d)),[d]),R.useEffect(()=>{if(l.trigger){let e=hh(e=>{e.target instanceof Node&&e.target.contains(l.trigger)&&d()},`handleScroll`);return window.addEventListener(`scroll`,e,{capture:!0}),()=>window.removeEventListener(`scroll`,e,{capture:!0})}},[l.trigger,d]);let{setContentId:f}=l;return qr(()=>(f(a),()=>{f(void 0)}),[a,f]),(0,z.jsx)(Xi,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:e=>e.preventDefault(),onDismiss:d,children:(0,z.jsxs)(dd,{"data-state":l.stateAttribute,role:i?void 0:`tooltip`,id:i?void 0:l.contentId,...u,...c,ref:t,style:{...c.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,z.jsx)(Rh,{children:r}),i?(0,z.jsx)(xr,{id:l.contentId,role:`tooltip`,children:i}):null]})})},`TooltipContentImpl`)),Bh=R.forwardRef(hh(function(e,t){let{__scopeTooltip:n,...r}=e,i=vh(n);return(0,z.jsx)(fd,{...i,...r,ref:t})},`TooltipArrow`));function Vh(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`)}}hh(Vh,`getExitSideFromRect`);function Hh(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})}return r}hh(Hh,`getPaddedExitPoints`);function Uh(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}]}hh(Uh,`getPointsFromRect`);function Wh(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}hh(Wh,`isPointInPolygon`);function Gh(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)),Kh(t)}hh(Gh,`getHull`);function Kh(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)}hh(Kh,`getHullPresorted`);var qh=wh,Jh=Oh,Yh=Ah,Xh=Ph,Zh=Ih,Qh=Bh,$h=768;function eg(){let[e,t]=R.useState(void 0);return R.useEffect(()=>{let e=window.matchMedia(`(max-width: 767px)`),n=()=>{t(window.innerWidth<$h)};return e.addEventListener(`change`,n),t(window.innerWidth<$h),()=>e.removeEventListener(`change`,n)},[]),!!e}var tg=(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},ng=(e,t)=>({classGroupId:e,validator:t}),rg=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),ig=`-`,ag=[],og=`arbitrary..`,sg=e=>{let t=ug(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return lg(e);let n=e.split(ig);return cg(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?tg(i,t):t:i||ag}return n[e]||ag}}},cg=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=cg(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(ig):e.slice(t).join(ig),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},lg=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?og+r:void 0})(),ug=e=>{let{theme:t,classGroups:n}=e;return dg(n,t)},dg=(e,t)=>{let n=rg();for(let r in e){let i=e[r];fg(i,n,r,t)}return n},fg=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];pg(i,t,n,r)}},pg=(e,t,n,r)=>{if(typeof e==`string`){mg(e,t,n);return}if(typeof e==`function`){hg(e,t,n,r);return}gg(e,t,n,r)},mg=(e,t,n)=>{let r=e===``?t:_g(t,e);r.classGroupId=n},hg=(e,t,n,r)=>{if(vg(e)){fg(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(ng(n,e))},gg=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];fg(o,_g(t,a),n,r)}},_g=(e,t)=>{let n=e,r=t.split(ig),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=rg(),n.nextPart.set(t,i)),n=i}return n},vg=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,yg=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)}}},bg=`!`,xg=`:`,Sg=[],Cg=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),wg=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===xg){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(bg)?(c=s.slice(0,-1),l=!0):s.startsWith(bg)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return Cg(t,l,c,u)};if(t){let e=t+xg,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):Cg(Sg,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},Tg=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}},Eg=e=>({cache:yg(e.cacheSize),parseClassName:wg(e),sortModifiers:Tg(e),postfixLookupClassGroupIds:Dg(e),...sg(e)}),Dg=e=>{let t=Object.create(null),n=e.postfixLookupClassGroups;if(n)for(let e=0;e<n.length;e++)t[n[e]]=!0;return t},Og=/\s+/,kg=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a,postfixLookupClassGroupIds:o}=t,s=[],c=e.trim().split(Og),l=``;for(let e=c.length-1;e>=0;--e){let t=c[e],{isExternal:u,modifiers:d,hasImportantModifier:f,baseClassName:p,maybePostfixModifierPosition:m}=n(t);if(u){l=t+(l.length>0?` `+l:l);continue}let h=!!m,g;if(h){g=r(p.substring(0,m));let e=g&&o[g]?r(p):void 0;e&&e!==g&&(g=e,h=!1)}else g=r(p);if(!g){if(!h){l=t+(l.length>0?` `+l:l);continue}if(g=r(p),!g){l=t+(l.length>0?` `+l:l);continue}h=!1}let _=d.length===0?``:d.length===1?d[0]:a(d).join(`:`),v=f?_+bg:_,y=v+g;if(s.indexOf(y)>-1)continue;s.push(y);let b=i(g,h);for(let e=0;e<b.length;++e){let t=b[e];s.push(v+t)}l=t+(l.length>0?` `+l:l)}return l},Ag=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=jg(n))&&(i&&(i+=` `),i+=r);return i},jg=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=jg(e[r]))&&(n&&(n+=` `),n+=t);return n},Mg=(e,...t)=>{let n,r,i,a,o=o=>(n=Eg(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=kg(e,n);return i(e,a),a};return a=o,(...e)=>a(Ag(...e))},Ng=[],Pg=e=>{let t=t=>t[e]||Ng;return t.isThemeGetter=!0,t},Fg=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Ig=/^\((?:(\w[\w-]*):)?(.+)\)$/i,Lg=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,Rg=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,zg=/\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$/,Bg=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Vg=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Hg=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ug=e=>Lg.test(e),Wg=e=>!!e&&!Number.isNaN(Number(e)),Gg=e=>!!e&&Number.isInteger(Number(e)),Kg=e=>e.endsWith(`%`)&&Wg(e.slice(0,-1)),qg=e=>Rg.test(e),Jg=()=>!0,Yg=e=>zg.test(e)&&!Bg.test(e),Xg=()=>!1,Zg=e=>Vg.test(e),Qg=e=>Hg.test(e),$g=e=>!q(e)&&!J(e),e_=e=>e.startsWith(`@container`)&&(e[10]===`/`&&e[11]!==void 0||e[11]===`s`&&e[16]!==void 0&&e.startsWith(`-size/`,10)||e[11]===`n`&&e[18]!==void 0&&e.startsWith(`-normal/`,10)),t_=e=>g_(e,b_,Xg),q=e=>Fg.test(e),n_=e=>g_(e,x_,Yg),r_=e=>g_(e,S_,Wg),i_=e=>g_(e,w_,Jg),a_=e=>g_(e,C_,Xg),o_=e=>g_(e,v_,Xg),s_=e=>g_(e,y_,Qg),c_=e=>g_(e,T_,Zg),J=e=>Ig.test(e),l_=e=>__(e,x_),u_=e=>__(e,C_),d_=e=>__(e,v_),f_=e=>__(e,b_),p_=e=>__(e,y_),m_=e=>__(e,T_,!0),h_=e=>__(e,w_,!0),g_=(e,t,n)=>{let r=Fg.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},__=(e,t,n=!1)=>{let r=Ig.exec(e);return r?r[1]?t(r[1]):n:!1},v_=e=>e===`position`||e===`percentage`,y_=e=>e===`image`||e===`url`,b_=e=>e===`length`||e===`size`||e===`bg-size`,x_=e=>e===`length`,S_=e=>e===`number`,C_=e=>e===`family-name`,w_=e=>e===`number`||e===`weight`,T_=e=>e===`shadow`,E_=Mg(()=>{let e=Pg(`color`),t=Pg(`font`),n=Pg(`text`),r=Pg(`font-weight`),i=Pg(`tracking`),a=Pg(`leading`),o=Pg(`breakpoint`),s=Pg(`container`),c=Pg(`spacing`),l=Pg(`radius`),u=Pg(`shadow`),d=Pg(`inset-shadow`),f=Pg(`text-shadow`),p=Pg(`drop-shadow`),m=Pg(`blur`),h=Pg(`perspective`),g=Pg(`aspect`),_=Pg(`ease`),v=Pg(`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(),J,q],S=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],C=()=>[`auto`,`contain`,`none`],w=()=>[J,q,c],T=()=>[Ug,`full`,`auto`,...w()],E=()=>[Gg,`none`,`subgrid`,J,q],ee=()=>[`auto`,{span:[`full`,Gg,J,q]},Gg,J,q],D=()=>[Gg,`auto`,J,q],O=()=>[`auto`,`min`,`max`,`fr`,J,q],k=()=>[`start`,`end`,`center`,`between`,`around`,`evenly`,`stretch`,`baseline`,`center-safe`,`end-safe`],A=()=>[`start`,`end`,`center`,`stretch`,`center-safe`,`end-safe`],j=()=>[`auto`,...w()],M=()=>[Ug,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],N=()=>[Ug,`screen`,`full`,`dvw`,`lvw`,`svw`,`min`,`max`,`fit`,...w()],te=()=>[Ug,`screen`,`full`,`lh`,`dvh`,`lvh`,`svh`,`min`,`max`,`fit`,...w()],P=()=>[e,J,q],F=()=>[...b(),d_,o_,{position:[J,q]}],ne=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],re=()=>[`auto`,`cover`,`contain`,f_,t_,{size:[J,q]}],ie=()=>[Kg,l_,n_],ae=()=>[``,`none`,`full`,l,J,q],I=()=>[``,Wg,l_,n_],L=()=>[`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`],se=()=>[Wg,Kg,d_,o_],ce=()=>[``,`none`,m,J,q],le=()=>[`none`,Wg,J,q],ue=()=>[`none`,Wg,J,q],de=()=>[Wg,J,q],fe=()=>[Ug,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[qg],breakpoint:[qg],color:[Jg],container:[qg],"drop-shadow":[qg],ease:[`in`,`out`,`in-out`],font:[$g],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[qg],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[qg],shadow:[qg],spacing:[`px`,Wg],text:[qg],"text-shadow":[qg],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,Ug,q,J,g]}],container:[`container`],"container-type":[{"@container":[``,`normal`,`size`,J,q]}],"container-named":[e_],columns:[{columns:[Wg,q,J,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:T()}],"inset-x":[{"inset-x":T()}],"inset-y":[{"inset-y":T()}],start:[{"inset-s":T(),start:T()}],end:[{"inset-e":T(),end:T()}],"inset-bs":[{"inset-bs":T()}],"inset-be":[{"inset-be":T()}],top:[{top:T()}],right:[{right:T()}],bottom:[{bottom:T()}],left:[{left:T()}],visibility:[`visible`,`invisible`,`collapse`],z:[{z:[Gg,`auto`,J,q]}],basis:[{basis:[Ug,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[Wg,Ug,`auto`,`initial`,`none`,q]}],grow:[{grow:[``,Wg,J,q]}],shrink:[{shrink:[``,Wg,J,q]}],order:[{order:[Gg,`first`,`last`,`none`,J,q]}],"grid-cols":[{"grid-cols":E()}],"col-start-end":[{col:ee()}],"col-start":[{"col-start":D()}],"col-end":[{"col-end":D()}],"grid-rows":[{"grid-rows":E()}],"row-start-end":[{row:ee()}],"row-start":[{"row-start":D()}],"row-end":[{"row-end":D()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":O()}],"auto-rows":[{"auto-rows":O()}],gap:[{gap:w()}],"gap-x":[{"gap-x":w()}],"gap-y":[{"gap-y":w()}],"justify-content":[{justify:[...k(),`normal`]}],"justify-items":[{"justify-items":[...A(),`normal`]}],"justify-self":[{"justify-self":[`auto`,...A()]}],"align-content":[{content:[`normal`,...k()]}],"align-items":[{items:[...A(),{baseline:[``,`last`]}]}],"align-self":[{self:[`auto`,...A(),{baseline:[``,`last`]}]}],"place-content":[{"place-content":k()}],"place-items":[{"place-items":[...A(),`baseline`]}],"place-self":[{"place-self":[`auto`,...A()]}],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:j()}],mx:[{mx:j()}],my:[{my:j()}],ms:[{ms:j()}],me:[{me:j()}],mbs:[{mbs:j()}],mbe:[{mbe:j()}],mt:[{mt:j()}],mr:[{mr:j()}],mb:[{mb:j()}],ml:[{ml:j()}],"space-x":[{"space-x":w()}],"space-x-reverse":[`space-x-reverse`],"space-y":[{"space-y":w()}],"space-y-reverse":[`space-y-reverse`],size:[{size:M()}],"inline-size":[{inline:[`auto`,...N()]}],"min-inline-size":[{"min-inline":[`auto`,...N()]}],"max-inline-size":[{"max-inline":[`none`,...N()]}],"block-size":[{block:[`auto`,...te()]}],"min-block-size":[{"min-block":[`auto`,...te()]}],"max-block-size":[{"max-block":[`none`,...te()]}],w:[{w:[s,`screen`,...M()]}],"min-w":[{"min-w":[s,`screen`,`none`,...M()]}],"max-w":[{"max-w":[s,`screen`,`none`,`prose`,{screen:[o]},...M()]}],h:[{h:[`screen`,`lh`,...M()]}],"min-h":[{"min-h":[`screen`,`lh`,`none`,...M()]}],"max-h":[{"max-h":[`screen`,`lh`,...M()]}],"font-size":[{text:[`base`,n,l_,n_]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,h_,i_]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,Kg,q]}],"font-family":[{font:[u_,a_,t]}],"font-features":[{"font-features":[q]}],"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,J,q]}],"line-clamp":[{"line-clamp":[Wg,`none`,J,r_]}],leading:[{leading:[a,...w()]}],"list-image":[{"list-image":[`none`,J,q]}],"list-style-position":[{list:[`inside`,`outside`]}],"list-style-type":[{list:[`disc`,`decimal`,`none`,J,q]}],"text-alignment":[{text:[`left`,`center`,`right`,`justify`,`start`,`end`]}],"placeholder-color":[{placeholder:P()}],"text-color":[{text:P()}],"text-decoration":[`underline`,`overline`,`line-through`,`no-underline`],"text-decoration-style":[{decoration:[...L(),`wavy`]}],"text-decoration-thickness":[{decoration:[Wg,`from-font`,`auto`,J,n_]}],"text-decoration-color":[{decoration:P()}],"underline-offset":[{"underline-offset":[Wg,`auto`,J,q]}],"text-transform":[`uppercase`,`lowercase`,`capitalize`,`normal-case`],"text-overflow":[`truncate`,`text-ellipsis`,`text-clip`],"text-wrap":[{text:[`wrap`,`nowrap`,`balance`,`pretty`]}],indent:[{indent:w()}],"tab-size":[{tab:[Gg,J,q]}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,J,q]}],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`,J,q]}],"bg-attachment":[{bg:[`fixed`,`local`,`scroll`]}],"bg-clip":[{"bg-clip":[`border`,`padding`,`content`,`text`]}],"bg-origin":[{"bg-origin":[`border`,`padding`,`content`]}],"bg-position":[{bg:F()}],"bg-repeat":[{bg:ne()}],"bg-size":[{bg:re()}],"bg-image":[{bg:[`none`,{linear:[{to:[`t`,`tr`,`r`,`br`,`b`,`bl`,`l`,`tl`]},Gg,J,q],radial:[``,J,q],conic:[Gg,J,q]},p_,s_]}],"bg-color":[{bg:P()}],"gradient-from-pos":[{from:ie()}],"gradient-via-pos":[{via:ie()}],"gradient-to-pos":[{to:ie()}],"gradient-from":[{from:P()}],"gradient-via":[{via:P()}],"gradient-to":[{to:P()}],rounded:[{rounded:ae()}],"rounded-s":[{"rounded-s":ae()}],"rounded-e":[{"rounded-e":ae()}],"rounded-t":[{"rounded-t":ae()}],"rounded-r":[{"rounded-r":ae()}],"rounded-b":[{"rounded-b":ae()}],"rounded-l":[{"rounded-l":ae()}],"rounded-ss":[{"rounded-ss":ae()}],"rounded-se":[{"rounded-se":ae()}],"rounded-ee":[{"rounded-ee":ae()}],"rounded-es":[{"rounded-es":ae()}],"rounded-tl":[{"rounded-tl":ae()}],"rounded-tr":[{"rounded-tr":ae()}],"rounded-br":[{"rounded-br":ae()}],"rounded-bl":[{"rounded-bl":ae()}],"border-w":[{border:I()}],"border-w-x":[{"border-x":I()}],"border-w-y":[{"border-y":I()}],"border-w-s":[{"border-s":I()}],"border-w-e":[{"border-e":I()}],"border-w-bs":[{"border-bs":I()}],"border-w-be":[{"border-be":I()}],"border-w-t":[{"border-t":I()}],"border-w-r":[{"border-r":I()}],"border-w-b":[{"border-b":I()}],"border-w-l":[{"border-l":I()}],"divide-x":[{"divide-x":I()}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":I()}],"divide-y-reverse":[`divide-y-reverse`],"border-style":[{border:[...L(),`hidden`,`none`]}],"divide-style":[{divide:[...L(),`hidden`,`none`]}],"border-color":[{border:P()}],"border-color-x":[{"border-x":P()}],"border-color-y":[{"border-y":P()}],"border-color-s":[{"border-s":P()}],"border-color-e":[{"border-e":P()}],"border-color-bs":[{"border-bs":P()}],"border-color-be":[{"border-be":P()}],"border-color-t":[{"border-t":P()}],"border-color-r":[{"border-r":P()}],"border-color-b":[{"border-b":P()}],"border-color-l":[{"border-l":P()}],"divide-color":[{divide:P()}],"outline-style":[{outline:[...L(),`none`,`hidden`]}],"outline-offset":[{"outline-offset":[Wg,J,q]}],"outline-w":[{outline:[``,Wg,l_,n_]}],"outline-color":[{outline:P()}],shadow:[{shadow:[``,`none`,u,m_,c_]}],"shadow-color":[{shadow:P()}],"inset-shadow":[{"inset-shadow":[`none`,d,m_,c_]}],"inset-shadow-color":[{"inset-shadow":P()}],"ring-w":[{ring:I()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:P()}],"ring-offset-w":[{"ring-offset":[Wg,n_]}],"ring-offset-color":[{"ring-offset":P()}],"inset-ring-w":[{"inset-ring":I()}],"inset-ring-color":[{"inset-ring":P()}],"text-shadow":[{"text-shadow":[`none`,f,m_,c_]}],"text-shadow-color":[{"text-shadow":P()}],opacity:[{opacity:[Wg,J,q]}],"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":[Wg]}],"mask-image-linear-from-pos":[{"mask-linear-from":se()}],"mask-image-linear-to-pos":[{"mask-linear-to":se()}],"mask-image-linear-from-color":[{"mask-linear-from":P()}],"mask-image-linear-to-color":[{"mask-linear-to":P()}],"mask-image-t-from-pos":[{"mask-t-from":se()}],"mask-image-t-to-pos":[{"mask-t-to":se()}],"mask-image-t-from-color":[{"mask-t-from":P()}],"mask-image-t-to-color":[{"mask-t-to":P()}],"mask-image-r-from-pos":[{"mask-r-from":se()}],"mask-image-r-to-pos":[{"mask-r-to":se()}],"mask-image-r-from-color":[{"mask-r-from":P()}],"mask-image-r-to-color":[{"mask-r-to":P()}],"mask-image-b-from-pos":[{"mask-b-from":se()}],"mask-image-b-to-pos":[{"mask-b-to":se()}],"mask-image-b-from-color":[{"mask-b-from":P()}],"mask-image-b-to-color":[{"mask-b-to":P()}],"mask-image-l-from-pos":[{"mask-l-from":se()}],"mask-image-l-to-pos":[{"mask-l-to":se()}],"mask-image-l-from-color":[{"mask-l-from":P()}],"mask-image-l-to-color":[{"mask-l-to":P()}],"mask-image-x-from-pos":[{"mask-x-from":se()}],"mask-image-x-to-pos":[{"mask-x-to":se()}],"mask-image-x-from-color":[{"mask-x-from":P()}],"mask-image-x-to-color":[{"mask-x-to":P()}],"mask-image-y-from-pos":[{"mask-y-from":se()}],"mask-image-y-to-pos":[{"mask-y-to":se()}],"mask-image-y-from-color":[{"mask-y-from":P()}],"mask-image-y-to-color":[{"mask-y-to":P()}],"mask-image-radial":[{"mask-radial":[J,q]}],"mask-image-radial-from-pos":[{"mask-radial-from":se()}],"mask-image-radial-to-pos":[{"mask-radial-to":se()}],"mask-image-radial-from-color":[{"mask-radial-from":P()}],"mask-image-radial-to-color":[{"mask-radial-to":P()}],"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":[Wg]}],"mask-image-conic-from-pos":[{"mask-conic-from":se()}],"mask-image-conic-to-pos":[{"mask-conic-to":se()}],"mask-image-conic-from-color":[{"mask-conic-from":P()}],"mask-image-conic-to-color":[{"mask-conic-to":P()}],"mask-mode":[{mask:[`alpha`,`luminance`,`match`]}],"mask-origin":[{"mask-origin":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]}],"mask-position":[{mask:F()}],"mask-repeat":[{mask:ne()}],"mask-size":[{mask:re()}],"mask-type":[{"mask-type":[`alpha`,`luminance`]}],"mask-image":[{mask:[`none`,J,q]}],filter:[{filter:[``,`none`,J,q]}],blur:[{blur:ce()}],brightness:[{brightness:[Wg,J,q]}],contrast:[{contrast:[Wg,J,q]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,m_,c_]}],"drop-shadow-color":[{"drop-shadow":P()}],grayscale:[{grayscale:[``,Wg,J,q]}],"hue-rotate":[{"hue-rotate":[Wg,J,q]}],invert:[{invert:[``,Wg,J,q]}],saturate:[{saturate:[Wg,J,q]}],sepia:[{sepia:[``,Wg,J,q]}],"backdrop-filter":[{"backdrop-filter":[``,`none`,J,q]}],"backdrop-blur":[{"backdrop-blur":ce()}],"backdrop-brightness":[{"backdrop-brightness":[Wg,J,q]}],"backdrop-contrast":[{"backdrop-contrast":[Wg,J,q]}],"backdrop-grayscale":[{"backdrop-grayscale":[``,Wg,J,q]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Wg,J,q]}],"backdrop-invert":[{"backdrop-invert":[``,Wg,J,q]}],"backdrop-opacity":[{"backdrop-opacity":[Wg,J,q]}],"backdrop-saturate":[{"backdrop-saturate":[Wg,J,q]}],"backdrop-sepia":[{"backdrop-sepia":[``,Wg,J,q]}],"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`,J,q]}],"transition-behavior":[{transition:[`normal`,`discrete`]}],duration:[{duration:[Wg,`initial`,J,q]}],ease:[{ease:[`linear`,`initial`,_,J,q]}],delay:[{delay:[Wg,J,q]}],animate:[{animate:[`none`,v,J,q]}],backface:[{backface:[`hidden`,`visible`]}],perspective:[{perspective:[h,J,q]}],"perspective-origin":[{"perspective-origin":x()}],rotate:[{rotate:le()}],"rotate-x":[{"rotate-x":le()}],"rotate-y":[{"rotate-y":le()}],"rotate-z":[{"rotate-z":le()}],scale:[{scale:ue()}],"scale-x":[{"scale-x":ue()}],"scale-y":[{"scale-y":ue()}],"scale-z":[{"scale-z":ue()}],"scale-3d":[`scale-3d`],skew:[{skew:de()}],"skew-x":[{"skew-x":de()}],"skew-y":[{"skew-y":de()}],transform:[{transform:[J,q,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:fe()}],"translate-x":[{"translate-x":fe()}],"translate-y":[{"translate-y":fe()}],"translate-z":[{"translate-z":fe()}],"translate-none":[`translate-none`],zoom:[{zoom:[Gg,J,q]}],accent:[{accent:P()}],appearance:[{appearance:[`none`,`auto`]}],"caret-color":[{caret:P()}],"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`,J,q]}],"field-sizing":[{"field-sizing":[`fixed`,`content`]}],"pointer-events":[{"pointer-events":[`auto`,`none`]}],resize:[{resize:[`none`,``,`y`,`x`]}],"scroll-behavior":[{scroll:[`auto`,`smooth`]}],"scrollbar-thumb-color":[{"scrollbar-thumb":P()}],"scrollbar-track-color":[{"scrollbar-track":P()}],"scrollbar-gutter":[{"scrollbar-gutter":[`auto`,`stable`,`both`]}],"scrollbar-w":[{scrollbar:[`auto`,`thin`,`none`]}],"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`,J,q]}],fill:[{fill:[`none`,...P()]}],"stroke-w":[{stroke:[Wg,l_,n_,r_]}],stroke:[{stroke:[`none`,...P()]}],"forced-color-adjust":[{"forced-color-adjust":[`auto`,`none`]}]},conflictingClassGroups:{"container-named":[`container-type`],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`]},postfixLookupClassGroups:[`container-type`],orderSensitiveModifiers:[`*`,`**`,`after`,`backdrop`,`before`,`details-content`,`file`,`first-letter`,`first-line`,`marker`,`placeholder`,`selection`]}});function Y(...e){return E_(Wn(e))}var D_=qn(`group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-primary text-primary-foreground hover:bg-primary/80`,outline:`border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50`,secondary:`bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground`,ghost:`hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50`,destructive:`bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2`,xs:`h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 [&_svg:not([class*='size-'])]:size-3`,sm:`h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 [&_svg:not([class*='size-'])]:size-3.5`,lg:`h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pe-2 has-data-[icon=inline-start]:ps-2`,icon:`size-8`,"icon-xs":`size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3`,"icon-sm":`size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg`,"icon-lg":`size-9`}},defaultVariants:{variant:`default`,size:`default`}});function X({className:e,variant:t=`default`,size:n=`default`,asChild:r=!1,...i}){let a=r?tr:`button`;return(0,z.jsx)(a,{"data-slot":`button`,"data-variant":t,"data-size":n,className:Y(D_({variant:t,size:n,className:e})),...i})}function O_({className:e,type:t,...n}){return(0,z.jsx)(`input`,{type:t,"data-slot":`input`,className:Y(`h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground/70 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40`,e),...n})}function k_({className:e,orientation:t=`horizontal`,decorative:n=!0,...r}){return(0,z.jsx)(ph,{"data-slot":`separator`,decorative:n,orientation:t,className:Y(`shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch`,e),...r})}function A_({...e}){return(0,z.jsx)(es,{"data-slot":`sheet`,...e})}function j_({...e}){return(0,z.jsx)(os,{"data-slot":`sheet-portal`,...e})}function M_({className:e,...t}){return(0,z.jsx)(cs,{"data-slot":`sheet-overlay`,className:Y(`fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...t})}function N_({className:e,children:t,side:n=`right`,showCloseButton:r=!0,closeLabel:i,...a}){return(0,z.jsxs)(j_,{children:[(0,z.jsx)(M_,{}),(0,z.jsxs)(fs,{"data-slot":`sheet-content`,"data-side":n,className:Y(`fixed z-50 flex flex-col gap-4 bg-popover bg-clip-padding text-sm text-popover-foreground 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-e 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-s 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 data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10`,e),...a,children:[t,r&&(0,z.jsx)(xs,{"data-slot":`sheet-close`,asChild:!0,children:(0,z.jsxs)(X,{variant:`ghost`,className:`absolute top-3 end-3`,size:`icon-sm`,children:[(0,z.jsx)(Vn,{}),(0,z.jsx)(`span`,{className:`sr-only`,children:i})]})})]})]})}function P_({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`sheet-header`,className:Y(`flex flex-col gap-0.5 p-4`,e),...t})}function F_({className:e,...t}){return(0,z.jsx)(_s,{"data-slot":`sheet-title`,className:Y(`font-heading text-base font-medium text-foreground`,e),...t})}function I_({className:e,...t}){return(0,z.jsx)(ys,{"data-slot":`sheet-description`,className:Y(`text-sm text-muted-foreground`,e),...t})}function L_({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`skeleton`,className:Y(`animate-pulse rounded-md bg-muted`,e),...t})}function R_({delayDuration:e=0,...t}){return(0,z.jsx)(qh,{"data-slot":`tooltip-provider`,delayDuration:e,...t})}function z_({...e}){return(0,z.jsx)(Jh,{"data-slot":`tooltip`,...e})}function B_({...e}){return(0,z.jsx)(Yh,{"data-slot":`tooltip-trigger`,...e})}function V_({className:e,sideOffset:t=0,children:n,...r}){return(0,z.jsx)(Xh,{children:(0,z.jsxs)(Zh,{"data-slot":`tooltip-content`,sideOffset:t,className:Y(`z-50 inline-flex w-fit max-w-xs origin-(--radix-tooltip-content-transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pe-1.5 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 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,e),...r,children:[n,(0,z.jsx)(Qh,{className:`z-50 fill-foreground`})]})})}var H_=`sidebar_state`,U_=604800,W_=`16rem`,G_=`18rem`,K_=`3rem`,q_=`b`,J_=R.createContext(null);function Y_(){let e=R.useContext(J_);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function X_({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:i,children:a,...o}){let s=eg(),[c,l]=R.useState(!1),[u,d]=R.useState(e),f=t??u,p=R.useCallback(e=>{let t=typeof e==`function`?e(f):e;n?n(t):d(t),document.cookie=`${H_}=${t}; path=/; max-age=${U_}`},[n,f]),m=R.useCallback(()=>s?l(e=>!e):p(e=>!e),[s,p,l]);R.useEffect(()=>{let e=e=>{e.key===q_&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),m())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[m]);let h=f?`expanded`:`collapsed`,g=R.useMemo(()=>({state:h,open:f,setOpen:p,isMobile:s,openMobile:c,setOpenMobile:l,toggleSidebar:m}),[h,f,p,s,c,l,m]);return(0,z.jsx)(J_.Provider,{value:g,children:(0,z.jsx)(`div`,{"data-slot":`sidebar-wrapper`,style:{"--sidebar-width":W_,"--sidebar-width-icon":K_,...i},className:Y(`group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-sidebar`,r),...o,children:a})})}function Z_({side:e=`left`,variant:t=`sidebar`,collapsible:n=`offcanvas`,className:r,children:i,dir:a,mobileTitle:o,mobileDescription:s,closeLabel:c,...l}){let{isMobile:u,state:d,openMobile:f,setOpenMobile:p}=Y_();return n===`none`?(0,z.jsx)(`div`,{"data-slot":`sidebar`,className:Y(`flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground`,r),...l,children:i}):u?(0,z.jsx)(A_,{open:f,onOpenChange:p,...l,children:(0,z.jsxs)(N_,{dir:a,"data-sidebar":`sidebar`,"data-slot":`sidebar`,"data-mobile":`true`,className:`w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden`,style:{"--sidebar-width":G_},side:e,closeLabel:c,children:[(0,z.jsxs)(P_,{className:`sr-only`,children:[(0,z.jsx)(F_,{children:o}),(0,z.jsx)(I_,{children:s})]}),(0,z.jsx)(`div`,{className:`flex h-full w-full flex-col`,children:i})]})}):(0,z.jsxs)(`div`,{className:`group peer hidden text-sidebar-foreground md:block`,"data-state":d,"data-collapsible":d===`collapsed`?n:``,"data-variant":t,"data-side":e,"data-slot":`sidebar`,children:[(0,z.jsx)(`div`,{"data-slot":`sidebar-gap`,className:Y(`relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear`,`group-data-[collapsible=offcanvas]:w-0`,`group-data-[side=right]:rotate-180`,t===`floating`||t===`inset`?`group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`)}),(0,z.jsx)(`div`,{"data-slot":`sidebar-container`,"data-side":e,className:Y(`fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear data-[side=left]:left-0 data-[side=left]:group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)] data-[side=right]:right-0 data-[side=right]:group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)] md:flex`,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-e group-data-[side=right]:border-s`,r),...l,children:(0,z.jsx)(`div`,{"data-sidebar":`sidebar`,"data-slot":`sidebar-inner`,className:`flex size-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1 group-data-[variant=floating]:ring-sidebar-border`,children:i})})]})}function Q_({className:e,onClick:t,"aria-label":n,...r}){let{toggleSidebar:i}=Y_();return(0,z.jsx)(X,{"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,variant:`ghost`,size:`icon-sm`,"aria-label":n,className:Y(e),onClick:e=>{t?.(e),i()},...r,children:(0,z.jsx)(mn,{className:`rtl:rotate-180`})})}function $_({className:e,"aria-label":t,...n}){let{toggleSidebar:r}=Y_();return(0,z.jsx)(`button`,{"data-sidebar":`rail`,"data-slot":`sidebar-rail`,"aria-label":t,tabIndex:-1,onClick:r,title:t,className:Y(`absolute inset-y-0 z-20 hidden w-4 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:start-1/2 after:w-[2px] hover:after:bg-sidebar-border sm:flex ltr:-translate-x-1/2 rtl:-translate-x-1/2`,`in-data-[side=left]:cursor-w-resize rtl:in-data-[side=left]:cursor-e-resize in-data-[side=right]:cursor-e-resize rtl:in-data-[side=right]:cursor-w-resize`,`[[data-side=left][data-state=collapsed]_&]:cursor-e-resize rtl:[[data-side=left][data-state=collapsed]_&]:cursor-w-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize rtl:[[data-side=right][data-state=collapsed]_&]:cursor-e-resize`,`group-data-[collapsible=offcanvas]:translate-x-0 rtl:group-data-[collapsible=offcanvas]:-translate-x-0 group-data-[collapsible=offcanvas]:after:start-full hover:group-data-[collapsible=offcanvas]:bg-sidebar`,`[[data-side=left][data-collapsible=offcanvas]_&]:-end-2`,`[[data-side=right][data-collapsible=offcanvas]_&]:-start-2`,e),...n})}function ev({className:e,...t}){return(0,z.jsx)(`main`,{"data-slot":`sidebar-inset`,className:Y(`relative flex w-full flex-1 flex-col bg-background md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ms-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ms-2`,e),...t})}function tv({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`sidebar-header`,"data-sidebar":`header`,className:Y(`flex flex-col gap-2 p-2`,e),...t})}function nv({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`sidebar-footer`,"data-sidebar":`footer`,className:Y(`flex flex-col gap-2 p-2`,e),...t})}function rv({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`sidebar-content`,"data-sidebar":`content`,className:Y(`no-scrollbar flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden`,e),...t})}function iv({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`sidebar-group`,"data-sidebar":`group`,className:Y(`relative flex w-full min-w-0 flex-col p-2`,e),...t})}function av({className:e,asChild:t=!1,...n}){let r=t?tr:`div`;return(0,z.jsx)(r,{"data-slot":`sidebar-group-label`,"data-sidebar":`group-label`,className:Y(`flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 ring-sidebar-ring outline-hidden 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 [&>svg]:shrink-0`,e),...n})}function ov({className:e,...t}){return(0,z.jsx)(`ul`,{"data-slot":`sidebar-menu`,"data-sidebar":`menu`,className:Y(`flex w-full min-w-0 flex-col gap-0`,e),...t})}function sv({className:e,...t}){return(0,z.jsx)(`li`,{"data-slot":`sidebar-menu-item`,"data-sidebar":`menu-item`,className:Y(`group/menu-item relative`,e),...t})}var cv=qn(`peer/menu-button group/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-start text-sm ring-sidebar-ring outline-hidden transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pe-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:font-medium data-active:text-sidebar-accent-foreground [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate`,{variants:{variant:{default:`hover:bg-sidebar-accent hover:text-sidebar-accent-foreground`,outline:`bg-background shadow-[0_0_0_1px_var(--sidebar-border)] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_var(--sidebar-accent)]`},size:{default:`h-8 text-sm`,sm:`h-7 text-xs`,lg:`h-12 text-sm group-data-[collapsible=icon]:p-0!`}},defaultVariants:{variant:`default`,size:`default`}});function lv({asChild:e=!1,isActive:t=!1,variant:n=`default`,size:r=`default`,tooltip:i,className:a,...o}){let s=e?tr:`button`,{isMobile:c,state:l}=Y_(),u=(0,z.jsx)(s,{"data-slot":`sidebar-menu-button`,"data-sidebar":`menu-button`,"data-size":r,"data-active":t,className:Y(cv({variant:n,size:r}),a),...o});return i?(typeof i==`string`&&(i={children:i}),(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:u}),(0,z.jsx)(V_,{side:`right`,align:`center`,hidden:l!==`collapsed`||c,...i})]})):u}function uv({className:e,...t}){return(0,z.jsx)(`ul`,{"data-slot":`sidebar-menu-sub`,"data-sidebar":`menu-sub`,className:Y(`mx-3.5 flex min-w-0 translate-x-px rtl:-translate-x-px flex-col gap-1 border-s border-sidebar-border px-2.5 py-0.5 group-data-[collapsible=icon]:hidden`,e),...t})}function dv({className:e,...t}){return(0,z.jsx)(`li`,{"data-slot":`sidebar-menu-sub-item`,"data-sidebar":`menu-sub-item`,className:Y(`group/menu-sub-item relative`,e),...t})}function fv({asChild:e=!1,size:t=`md`,isActive:n=!1,className:r,...i}){let a=e?tr:`a`;return(0,z.jsx)(a,{"data-slot":`sidebar-menu-sub-button`,"data-sidebar":`menu-sub-button`,"data-size":t,"data-active":n,className:Y(`flex h-7 min-w-0 -translate-x-px rtl:translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 text-sidebar-foreground ring-sidebar-ring outline-hidden group-data-[collapsible=icon]:hidden hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[size=md]:text-sm data-[size=sm]:text-xs data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0 [&>svg]:text-sidebar-accent-foreground`,r),...i})}var pv=`/admin/api`,mv=class extends Error{status;body;constructor(e,t,n){super(e),this.status=t,this.body=n,this.name=`ApiError`}};async function hv(e,t){let n=await fetch(`${pv}${e}`,{credentials:`same-origin`,...t,headers:{Accept:`application/json`,...t?.headers??{}}}),r=await n.text(),i=null;if(r)try{i=JSON.parse(r)}catch{i=r}if(!n.ok)throw new mv(`${n.status} ${n.statusText}`,n.status,i);return i}var Z={get:e=>hv(e),post:(e,t)=>hv(e,gv(`POST`,t)),patch:(e,t)=>hv(e,gv(`PATCH`,t)),delete:e=>hv(e,{method:`DELETE`})};function gv(e,t){return{method:e,headers:{"Content-Type":`application/json`},body:t===void 0?void 0:JSON.stringify(t)}}function _v(e,t,n){if(e==null)return null;if(typeof e==`string`)return e;if(Object.prototype.hasOwnProperty.call(e,t))return e[t];if(n&&Object.prototype.hasOwnProperty.call(e,n))return e[n];let r=Object.keys(e)[0];return r===void 0?null:e[r]}function vv(e){return e.replace(/([a-z0-9])([A-Z])/g,`$1 $2`).replace(/[_-]+/g,` `).replace(/\b\w/g,e=>e.toUpperCase())}function yv(e,t,n,r){return _v(t?.title,n,r)??vv(e)}function bv(e,t,n){return _v(e?.description,t,n)??void 0}function xv(){return{queryKey:[`auth-methods`],queryFn:async()=>{let e=await fetch(`/api/auth/methods`,{credentials:`include`});if(!e.ok)throw Error(`HTTP ${e.status}`);return(await e.json()).methods??[]},retry:!1}}function Sv(){return{queryKey:[`views-manifest`],queryFn:async()=>(await Z.get(`/views-manifest`)).views}}function Cv(){return{queryKey:[`operations`],queryFn:async()=>(await Z.get(`/operations`)).operations}}var wv=[`draft`,`published`,`archived`],Tv=R.createContext(null);function Ev(){return typeof window>`u`?{pathname:`/admin`,search:``}:{pathname:window.location.pathname,search:window.location.search}}function Dv(e){if(typeof window>`u`)return!1;let t=new URL(e,window.location.href);return!(t.origin!==window.location.origin||!t.pathname.startsWith(`/admin`)||t.pathname.startsWith(`/admin/api/`)||t.pathname.startsWith(`/admin/auth/`))}function Ov({children:e}){let[t,n]=R.useState(Ev),r=R.useCallback((e,t={})=>{if(typeof window>`u`)return;let r=new URL(e,window.location.href),i=`${r.pathname}${r.search}${r.hash}`;i!==`${window.location.pathname}${window.location.search}${window.location.hash}`&&(t.replace?window.history.replaceState(null,``,i):window.history.pushState(null,``,i));let a={pathname:r.pathname,search:r.search};(0,mr.flushSync)(()=>n(a))},[]);R.useEffect(()=>{let e=()=>n(Ev());return window.addEventListener(`popstate`,e),()=>window.removeEventListener(`popstate`,e)},[]),R.useEffect(()=>{let e=e=>{if(e.defaultPrevented||e.button!==0||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey)return;let t=e.target;if(!(t instanceof Element))return;let n=t.closest(`a[href]`);n instanceof HTMLAnchorElement&&(n.target&&n.target!==`_self`||n.hasAttribute(`download`)||Dv(n.href)&&(e.preventDefault(),r(n.href)))};return document.addEventListener(`click`,e,{capture:!0}),()=>document.removeEventListener(`click`,e,{capture:!0})},[r]);let i=R.useMemo(()=>({location:t,navigate:r}),[t,r]);return(0,z.jsx)(Tv.Provider,{value:i,children:e})}function kv(){let e=R.useContext(Tv);if(!e)throw Error(`useAdminRouter must be used inside AdminRouterProvider.`);return e}function Av(){return kv().location}var jv=[{value:`en`,label:`English`,nativeLabel:`English`,htmlLang:`en`,direction:`ltr`},{value:`de`,label:`German`,nativeLabel:`Deutsch`,htmlLang:`de`,direction:`ltr`},{value:`es`,label:`Spanish`,nativeLabel:`Español`,htmlLang:`es`,direction:`ltr`},{value:`fr`,label:`French`,nativeLabel:`Français`,htmlLang:`fr`,direction:`ltr`},{value:`it`,label:`Italian`,nativeLabel:`Italiano`,htmlLang:`it`,direction:`ltr`},{value:`ja`,label:`Japanese`,nativeLabel:`日本語`,htmlLang:`ja`,direction:`ltr`},{value:`ko`,label:`Korean`,nativeLabel:`한국어`,htmlLang:`ko`,direction:`ltr`},{value:`pt-BR`,label:`Portuguese (Brazil)`,nativeLabel:`Português (BR)`,htmlLang:`pt-BR`,direction:`ltr`},{value:`ru`,label:`Russian`,nativeLabel:`Русский`,htmlLang:`ru`,direction:`ltr`},{value:`zh-CN`,label:`Simplified Chinese`,nativeLabel:`简体中文`,htmlLang:`zh-Hans-CN`,direction:`ltr`},{value:`zh-TW`,label:`Traditional Chinese`,nativeLabel:`繁體中文`,htmlLang:`zh-Hant-TW`,direction:`ltr`},{value:`id`,label:`Indonesian`,nativeLabel:`Bahasa Indonesia`,htmlLang:`id`,direction:`ltr`},{value:`nl`,label:`Dutch`,nativeLabel:`Nederlands`,htmlLang:`nl`,direction:`ltr`},{value:`pl`,label:`Polish`,nativeLabel:`Polski`,htmlLang:`pl`,direction:`ltr`},{value:`tr`,label:`Turkish`,nativeLabel:`Türkçe`,htmlLang:`tr`,direction:`ltr`},{value:`vi`,label:`Vietnamese`,nativeLabel:`Tiếng Việt`,htmlLang:`vi`,direction:`ltr`},{value:`cs`,label:`Czech`,nativeLabel:`Čeština`,htmlLang:`cs`,direction:`ltr`},{value:`uk`,label:`Ukrainian`,nativeLabel:`Українська`,htmlLang:`uk`,direction:`ltr`},{value:`ar`,label:`Arabic`,nativeLabel:`العربية`,htmlLang:`ar`,direction:`rtl`},{value:`he`,label:`Hebrew`,nativeLabel:`עברית`,htmlLang:`he`,direction:`rtl`},{value:`fa`,label:`Persian`,nativeLabel:`فارسی`,htmlLang:`fa`,direction:`rtl`},{value:`th`,label:`Thai`,nativeLabel:`ไทย`,htmlLang:`th`,direction:`ltr`}],Mv=`cms.preference.language`,Nv=`cms.preference.theme`,Pv=R.createContext(null);function Fv({children:e}){let[t,n]=R.useState(Lv),r=Uv(t),[i,a]=R.useState(Rv),o=R.useCallback(e=>{Bv(Mv,e),n(e)},[]),s=R.useCallback(e=>{Bv(Nv,e),a(e)},[]);R.useEffect(()=>{document.documentElement.lang=jv.find(e=>e.value===t)?.htmlLang??`en`,document.documentElement.dir=r},[t,r]),R.useEffect(()=>{let e=()=>{let e=typeof matchMedia<`u`&&matchMedia(`(prefers-color-scheme: dark)`).matches;document.documentElement.classList.toggle(`dark`,i===`dark`||i===`system`&&e)};if(e(),i!==`system`||typeof matchMedia>`u`)return;let t=matchMedia(`(prefers-color-scheme: dark)`);return t.addEventListener(`change`,e),()=>t.removeEventListener(`change`,e)},[i]);let c=R.useMemo(()=>({language:t,direction:r,theme:i,setLanguage:o,setTheme:s}),[t,r,i,o,s]);return(0,z.jsx)(Pv.Provider,{value:c,children:e})}function Iv(){let e=R.useContext(Pv);if(!e)throw Error(`usePreferences must be used inside PreferencesProvider.`);return e}function Lv(){let e=zv(Mv);if(Vv(e))return e;if(typeof navigator>`u`)return`en`;for(let e of navigator.languages??[]){let t=Hv(e);if(t!==`en`||e.toLowerCase().startsWith(`en`))return t}return Hv(navigator.language)}function Rv(){let e=zv(Nv);return e===`light`||e===`dark`||e===`system`?e:`system`}function zv(e){try{return localStorage.getItem(e)}catch{return null}}function Bv(e,t){try{localStorage.setItem(e,t)}catch{}}function Vv(e){return jv.some(t=>t.value===e)}function Hv(e){let t=(e??``).toLowerCase();if(t===`zh-tw`||t===`zh-hant`||t.startsWith(`zh-hant`))return`zh-TW`;if(t===`zh-cn`||t===`zh-hans`||t.startsWith(`zh-hans`))return`zh-CN`;if(t.startsWith(`pt-br`)||t===`pt`)return`pt-BR`;let n=t.split(`-`)[0];return n===`ar`?`ar`:n===`cs`?`cs`:n===`de`?`de`:n===`es`?`es`:n===`fa`?`fa`:n===`fr`?`fr`:n===`he`||n===`iw`?`he`:n===`id`?`id`:n===`it`?`it`:n===`ja`?`ja`:n===`ko`?`ko`:n===`nl`?`nl`:n===`pl`?`pl`:n===`pt`?`pt-BR`:n===`ru`?`ru`:n===`th`?`th`:n===`tr`?`tr`:n===`uk`?`uk`:n===`vi`?`vi`:n===`zh`?`zh-TW`:`en`}function Uv(e){return jv.find(t=>t.value===e)?.direction??`ltr`}var Wv={en:{"admin.consoleTitle":`Admin console`,"auth.accessDenied.title":`Access denied`,"auth.accessDenied.noStaff":`You're signed in, but this account doesn't have access to the admin console.`,"auth.accessDenied.askOwner":`Ask a site owner to add you to the team, or sign out to try a different account.`,"auth.error.title":`Something went wrong`,"auth.signIn.eyebrow":`Admin console`,"auth.signIn.title":`Sign in`,"auth.signIn.methodsLoadFailed":`Couldn't load sign-in methods. Try refreshing.`,"auth.signIn.startFailed":`Couldn't start sign-in. Try again.`,"auth.signIn.requestFailed":`Something went wrong. Try again.`,"auth.signIn.noMethods":`No sign-in methods are configured for this site.`,"auth.signIn.unknownMethod":`Unsupported sign-in method: {kind}.`,"auth.signIn.method.social.button":`Continue with {provider}`,"auth.signIn.method.oauth.button":`Continue with {provider}`,"auth.signIn.method.email-otp.body":`Sign in with a one-time code sent to your email.`,"auth.signIn.method.email-otp.emailLabel":`Email address`,"auth.signIn.method.email-otp.emailPlaceholder":`you@example.com`,"auth.signIn.method.email-otp.sendButton":`Send code`,"auth.signIn.method.email-otp.sendFailed":`Couldn't send the code. Check the email and try again.`,"auth.signIn.method.email-otp.sentTo":`We sent a code to {email}.`,"auth.signIn.method.email-otp.otpLabel":`One-time code`,"auth.signIn.method.email-otp.otpPlaceholder":`Enter the 6-digit code`,"auth.signIn.method.email-otp.verifyButton":`Verify and sign in`,"auth.signIn.method.email-otp.verifyFailed":`That code didn't match. Try again.`,"auth.signIn.method.email-otp.back":`Use a different email`,"auth.signIn.method.magic-link.body":`We'll email you a one-tap sign-in link.`,"auth.signIn.method.magic-link.emailLabel":`Email address`,"auth.signIn.method.magic-link.emailPlaceholder":`you@example.com`,"auth.signIn.method.magic-link.sendButton":`Send sign-in link`,"auth.signIn.method.magic-link.sendFailed":`Couldn't send the link. Check the email and try again.`,"auth.signIn.method.magic-link.sentTo":`We sent a sign-in link to {email}.`,"auth.signIn.method.magic-link.clickHint":`Click the link in the email to finish signing in. The link expires shortly.`,"auth.signIn.method.magic-link.anotherEmail":`Use a different email`,"common.signOut":`Sign out`,"common.viewSite":`View site`,"common.copy":`Copy`,"common.open":`Open`,"common.failedToLoad":`Failed to load`,"common.unknownError":`Unknown error`,"common.signedIn":`Signed in`,"common.close":`Close`,"common.skipToMain":`Skip to main content`,"common.breadcrumb":`Breadcrumb`,"common.toggleSidebar":`Toggle sidebar`,"common.mobileSidebar":`Navigation`,"common.mobileSidebarDescription":`Site administration navigation`,"common.saved":`Saved`,"common.unsavedChanges":`Unsaved changes`,"console.eyebrow":`Site administration`,"console.description":`Manage {title}'s content and operations here. MCP-capable agents can work alongside you.`,"console.descriptionFallback":`Manage this site's content and operations here. MCP-capable agents can work alongside you.`,"console.connector.title":`Connect Claude to the admin console`,"console.connector.body":`Authorize Claude to help manage this site's content and operations.`,"console.connector.step1.title":`Copy the management connection URL`,"console.connector.step1.body":`You'll paste this URL into Claude in the next step.`,"console.connector.step1.label":`Management connection URL`,"console.connector.step2.title":`Add a custom connector`,"console.connector.step2.body":`Open Claude Customize, name the connector, and paste the URL.`,"console.connector.step2.action":`Open Claude Customize`,"console.connector.step3.title":`Sign in and start`,"console.connector.step3.body":`Sign in with a site administrator account, then ask Claude to help manage this site.`,"console.connector.step3.action":`Open Claude`,"console.collections.title":`Data collections`,"console.collections.emptyTitle":`No collections defined yet`,"console.collections.emptyBody":`No data collections yet. Start from a template, or ask your agent to create the first one.`,"collection.breadcrumb":`Collections`,"collection.create":`New entry`,"collection.availableLanguage":`Has {language} ({locale})`,"collection.missingLanguage":`Missing {language} ({locale})`,"collection.moreLanguages":`{count} more`,"collection.schemaDetails":`Schema notes`,"collection.searchPlaceholder":`Search id or searchable fields...`,"collection.search":`Search`,"collection.pagination":`Collection pages`,"collection.previousPage":`Previous`,"collection.nextPage":`Next`,"collection.filter.all":`All`,"collection.empty.title":`No data yet`,"collection.empty.search":`No entries matched “{search}”.`,"collection.empty.withStatus":`No {status} data in {collection}.`,"collection.empty.all":`{collection} has no data yet.`,"collection.refreshing":`Updating the list...`,"collection.export":`Export CSV`,"collection.copyId":`Copy full ID`,"collection.table.id":`ID`,"collection.table.title":`Title`,"collection.table.status":`Status`,"collection.table.locale":`Locale`,"collection.table.version":`Version`,"collection.table.updated":`Updated`,"collection.table.actions":`Actions`,"collection.table.selectAll":`Select all rows on this page`,"collection.table.selectRow":`Select {name}`,"rowActions.menuLabel":`Row operations`,"rowActions.cancel":`Cancel`,"collection.untitled":`(untitled)`,"collection.bulk.selectedCount":`{count} selected`,"collection.bulk.publish":`Publish`,"collection.bulk.unpublish":`Unpublish`,"collection.bulk.delete":`Delete`,"collection.bulk.deleteConfirm":`Delete {count} selected entries? This cannot be undone.`,"crud.editTooltip":`Edit {name}.`,"crud.viewTooltip":`View {name}.`,"crud.deleteTooltip":`Delete {name}.`,"crud.saveTitle":`Save title`,"crud.cancelTitle":`Cancel editing`,"crud.deleteConfirm":`Delete {name}? This cannot be undone.`,"crud.saving":`Saving...`,"entryEdit.back":`Back to {name}`,"entryEdit.body":`Edit this {name} entry. Related records show up alongside automatically.`,"entryEdit.parent":`Parent: {name}`,"entryEdit.save":`Save changes`,"entryEdit.saveTooltip":`Save this entry.`,"entryEdit.fields":`Entry fields`,"entryEdit.meta":`Entry details`,"entryEdit.noChildEntries":`No child entries match this entry yet.`,"entryEdit.relationship":`Joined by {child} from parent {parent}.`,"entryEdit.addItem":`Add item`,"entryEdit.removeItem":`Remove item`,"entryEdit.emptyOption":`No value`,"entryEdit.boolean":`Enabled`,"entryEdit.operationalHint":`System-written record — edits may be overwritten by the next sync.`,"entryEdit.unlockOperational":`Unlock editing`,"entryEdit.readOnlyHint":`Procedure-managed record — use the available row actions to make changes.`,"entryEdit.contentLanguage":`Content language`,"entryEdit.selectLanguage":`Select language`,"entryEdit.languageLocked":`A saved entry's language cannot be changed. Open or create another translation instead.`,"entryEdit.languageTabs":`Content languages`,"entryEdit.sharedFields":`Shared fields`,"entryEdit.saveSharedFirst":`Save the shared fields before adding a translation.`,"entryEdit.publish":`Publish`,"entryEdit.publishing":`Publishing...`,"entryEdit.publishTooltip":`Publish this draft.`,"entryEdit.publishDisabledDirty":`Save changes before publishing.`,"entryEdit.publishMissingRequired":`Complete the required fields before publishing.`,"entryEdit.unpublish":`Unpublish`,"entryEdit.unpublishing":`Unpublishing...`,"entryEdit.unpublishTooltip":`Move this entry back to draft so it can be edited.`,"entryEdit.uploadMedia":`Upload`,"entryEdit.uploadingMedia":`Uploading...`,"entryEdit.noMediaPurpose":`No media upload purpose is configured.`,"settings.page.title":`Site settings`,"settings.page.body":`Manage the Admin name, default site metadata, and visitor analytics.`,"settings.tabsLabel":`Site settings sections`,"settings.tab.brand":`General`,"settings.tab.tracking":`Analytics`,"settings.brandSection":`Site identity`,"settings.brandSectionBody":`These defaults identify the site in Admin and generated public pages.`,"settings.siteBrand":`Admin name`,"settings.siteBrandHelp":`Shown in the Admin sidebar and sign-in screen. It does not replace the public page title.`,"settings.siteTitle":`Default page title`,"settings.siteTitleHelp":`Used when a page has no title of its own and as the default SEO site name.`,"settings.siteDescription":`Default site description`,"settings.siteDescriptionHelp":`Used as the SEO and sharing summary when a page has no description of its own.`,"settings.trackingSection":`Visitor analytics`,"settings.trackingSectionBody":`Optional. Mantle injects standard provider scripts into generated public HTML after you save a valid ID.`,"settings.notConfigured":`Not configured`,"settings.ga4MeasurementId":`GA4 Measurement ID`,"settings.ga4MeasurementIdHelp":`Leave blank to disable. Enter only an ID such as G-XXXXXXXXXX, not the whole gtag script.`,"settings.facebookPixelId":`Facebook Pixel ID`,"settings.facebookPixelIdHelp":`Leave blank to disable. Enter only the numeric Pixel ID; Mantle generates the base code.`,"nav.home":`Home`,"nav.content":`Content`,"nav.operations":`Records`,"nav.media":`Media library`,"nav.more":`More`,"nav.settings":`Settings`,"nav.staff":`Admin users`,"nav.members":`Members`,"nav.reports":`Reports`,"nav.localizedContent":`Contains localized content`,"ops.run":`Run`,"ops.running":`Running...`,"views.page.body":`A read-only report over {schema}.`,"views.params.title":`Parameters`,"views.run":`Query`,"views.running":`Querying...`,"views.empty.title":`No rows`,"views.empty.body":`No data under the current filters.`,"views.notFound.title":`View not found`,"staff.page.title":`Admin users`,"staff.page.body":`Invite by email, or ask a user to sign in first and grant them Admin access from Members. Only site owners can make changes here.`,"staff.invite.title":`Invite a teammate`,"staff.invite.emailLabel":`Email address`,"staff.invite.emailPlaceholder":`teammate@example.com`,"staff.invite.roleLabel":`Role`,"staff.invite.button":`Invite`,"staff.invite.sending":`Inviting…`,"staff.invite.revoke":`Revoke`,"staff.invite.hint":`Your teammate joins after signing in with the same email address.`,"staff.emailSetup.title":`Email sign-in is not enabled`,"staff.emailSetup.body":`To enable email sign-in, give the setup instructions to your coding agent to connect a transactional email service and redeploy the site.`,"staff.emailSetup.copy":`Copy setup steps`,"staff.emailSetup.copied":`Copied`,"staff.emailSetup.guide":`Cloudflare guide`,"staff.table.name":`Name`,"staff.table.email":`Email`,"staff.table.status":`Status / sign-in`,"staff.table.role":`Role`,"staff.role.owner":`Owner`,"staff.role.owner.help":`Everything, including settings and team access.`,"staff.role.editor":`Editor`,"staff.role.editor.help":`Content, publishing, operations, and media.`,"staff.role.contributor":`Contributor`,"staff.role.contributor.help":`Create and edit drafts only.`,"staff.role.none":`No role`,"staff.badge.invited":`Invited`,"staff.status.emailSignIn":`Email sign-in`,"staff.self":`you`,"members.page.title":`Members`,"members.page.body":`People who have signed in to this site and do not have admin access.`,"members.searchPlaceholder":`Search name or email...`,"members.search":`Search`,"members.table.name":`Name`,"members.table.email":`Email`,"members.table.status":`Status`,"members.table.joined":`Joined`,"members.table.teamAccess":`Team access`,"members.promote":`Grant Admin access`,"members.verified":`Verified`,"members.unverified":`Unverified`,"members.empty.title":`No members yet`,"members.empty.body":`People appear here after they sign in to the site.`,"members.emptySearch.title":`No matching members`,"members.emptySearch.body":`Try a different name or email.`,"members.pagination":`Member pages`,"members.previousPage":`Previous`,"members.nextPage":`Next`,"status.draft":`Drafts`,"status.published":`Published`,"status.archived":`Archived`,"preferences.heading":`Preferences`,"preferences.language":`Admin language`,"preferences.language.search":`Search languages...`,"preferences.language.noResults":`No languages found.`,"preferences.direction":`Text direction`,"preferences.direction.auto":`Text direction follows the selected language.`,"preferences.appearance":`Appearance`,"preferences.light":`Light`,"preferences.dark":`Dark`,"preferences.system":`System`,"preferences.ltr":`Left to right`,"preferences.rtl":`Right to left`,"preferences.page.title":`Personal preferences`,"preferences.page.body":`These preferences stay on this browser. They change the admin console only and do not modify site settings.`,"preferences.page.languageBody":`Choose the language used by system pages and admin chrome.`,"preferences.page.appearanceBody":`Choose light, dark, or follow your operating system.`,"preferences.page.open":`Preferences`,"system.notFound.title":`Not found`,"system.notFound.body":`No view registered for`,"system.notFound.back":`Back to home`,"editor.page.title":`Content editor`,"editor.page.body":`Draft copy in Markdown, HTML, or rich text before handing it to an agent or publishing workflow.`,"editor.mode.markdown":`Markdown`,"editor.mode.html":`HTML`,"editor.mode.rich":`Rich editor`,"editor.titleLabel":`Title`,"editor.slugLabel":`Slug`,"editor.bodyLabel":`Body`,"editor.preview":`Preview`,"editor.saveDraft":`Save draft`,"editor.markdownHint":`Supports headings, lists, links, and fenced code blocks.`,"editor.htmlHint":`Edit trusted HTML fragments with a plain source view.`,"editor.richHint":`Format sections, callouts, and copy without touching markup.`,"editor.toolbar":`Rich editor toolbar`,"editor.undo":`Undo`,"editor.redo":`Redo`,"editor.aiClean":`Insert callout`,"editor.uploadImage":`Upload image`,"editor.uploading":`Uploading image...`,"editor.textStyle":`Text style`,"editor.paragraph":`Paragraph`,"editor.quote":`Quote`,"editor.code":`Code`,"editor.headingPlaceholder":`Heading`,"editor.selectedText":`selected text`,"editor.bold":`Bold`,"editor.italic":`Italic`,"editor.underline":`Underline`,"editor.strike":`Strikethrough`,"editor.inlineCode":`Inline code`,"editor.textColor":`Text color`,"editor.highlight":`Highlight`,"editor.palette":`Brand color`,"editor.alignLeft":`Align left`,"editor.alignCenter":`Align center`,"editor.alignRight":`Align right`,"editor.bulletList":`Bullet list`,"editor.numberList":`Numbered list`,"editor.checkList":`Checklist`,"editor.indent":`Indent`,"editor.link":`Link`,"editor.linkText":`link text`,"editor.table":`Table`,"editor.mediaLibrary":`Media library`,"editor.imageUrl":`Image URL`,"editor.insertImage":`Insert image`,"editor.videoUrl":`YouTube / Dailymotion URL`,"editor.insertVideo":`Insert video`,"media.alt":`Alt text`,"media.title":`Media library`,"media.description":`Every image uploaded to this site. Reuse one in an entry, tidy up its alt text, or remove it.`,"media.upload":`Upload`,"media.uploading":`Uploading...`,"media.dropHere":`Drop images here to upload`,"media.searchPlaceholder":`Search alt text, caption, or id`,"media.empty.title":`No images yet`,"media.empty.all":`Upload an image to start building the library.`,"media.empty.search":`No images match “{search}”.`,"media.noPurpose":`No upload purpose is configured for this site, so uploads are disabled.`,"media.setup.title":`Media storage isn't enabled`,"media.setup.body":`Ask your coding agent to connect storage for this deployment, then redeploy the site.`,"media.setup.cloudflare":`Cloudflare deployments use R2. Enabling R2 may require billing details.`,"media.setup.copy":`Copy setup instructions`,"media.setup.copied":`Instructions copied`,"media.setup.guide":`Cloudflare R2 setup`,"media.caption":`Caption`,"media.altPlaceholder":`Describe this image`,"media.captionPlaceholder":`Optional caption`,"media.save":`Save`,"media.saving":`Saving...`,"media.saved":`Saved`,"media.delete":`Delete`,"media.deleteConfirm":`Delete this image? It will be removed everywhere it is used.`,"media.open":`Open original`,"media.copyId":`Copy id`,"media.uploaded":`Uploaded {date}`,"media.pick":`Choose from library`,"media.pickTitle":`Choose an image`,"media.pickDescription":`Pick an existing image to reuse, or upload a new one.`,"media.use":`Use this image`,"media.loadMore":`Load more`,"media.uploadFailed":`{count} of {total} uploads failed.`,"media.capabilityMissing":`The upload could not be prepared for {mime}.`,"media.variantUploadFailed":`The {mime} upload failed. Try again.`,"media.rasterOnly":`Upload a JPEG, PNG, WebP, AVIF, or GIF image.`,"media.noRequiredVariants":`The media policy has no required image variants.`,"media.prepareFailed":`The image could not be prepared for upload.`,"media.encoderUnsupported":`This site's media policy requires an image format this browser cannot produce ({mime}). Contact the site developer to update the policy.`,"ops.error.executionFailed":`The operation ran but failed to complete.`,"ops.error.detailsLabel":`Show details`,"ops.success":`{name} completed.`,"confirm.title":`Are you sure?`,"confirm.cancel":`Cancel`,"confirm.confirm":`Confirm`,"collection.schemaSummary.lifecycleAndI18n":`Manage items, publishing state, and localized content for {name}.`,"collection.schemaSummary.lifecycleOnly":`Manage items and publishing state for {name}.`,"collection.schemaSummary.i18nOnly":`Manage items and localized content for {name}.`,"collection.schemaSummary.plain":`Manage items for {name}.`,"entryEdit.mediaMissing":`This image is missing or was deleted.`,"entryEdit.dateTime.select":`Select date and time`,"entryEdit.dateTime.time":`Time`},"zh-TW":{"admin.consoleTitle":`管理後台`,"auth.accessDenied.title":`無法存取`,"auth.accessDenied.noStaff":`你已登入,但這個帳號沒有管理後台權限。`,"auth.accessDenied.askOwner":`請網站擁有者將你加入團隊,或登出改用其他帳號。`,"auth.error.title":`發生錯誤`,"auth.signIn.eyebrow":`管理後台`,"auth.signIn.title":`登入`,"auth.signIn.methodsLoadFailed":`讀取登入方式失敗,請重新整理頁面。`,"auth.signIn.startFailed":`無法開始登入,請再試一次。`,"auth.signIn.requestFailed":`發生錯誤,請再試一次。`,"auth.signIn.noMethods":`這個站台還沒設定任何登入方式。`,"auth.signIn.unknownMethod":`不支援的登入方式:{kind}。`,"auth.signIn.method.social.button":`使用 {provider} 繼續`,"auth.signIn.method.oauth.button":`使用 {provider} 繼續`,"auth.signIn.method.email-otp.body":`輸入 email,我們會寄一次性驗證碼給你。`,"auth.signIn.method.email-otp.emailLabel":`電子郵件`,"auth.signIn.method.email-otp.emailPlaceholder":`you@example.com`,"auth.signIn.method.email-otp.sendButton":`寄送驗證碼`,"auth.signIn.method.email-otp.sendFailed":`驗證碼寄送失敗,請確認 email 後重試。`,"auth.signIn.method.email-otp.sentTo":`已寄驗證碼到 {email}。`,"auth.signIn.method.email-otp.otpLabel":`驗證碼`,"auth.signIn.method.email-otp.otpPlaceholder":`輸入 6 位驗證碼`,"auth.signIn.method.email-otp.verifyButton":`驗證並登入`,"auth.signIn.method.email-otp.verifyFailed":`驗證碼錯誤,請再試一次。`,"auth.signIn.method.email-otp.back":`用其他 email`,"auth.signIn.method.magic-link.body":`我們會寄一個一鍵登入連結給你。`,"auth.signIn.method.magic-link.emailLabel":`電子郵件`,"auth.signIn.method.magic-link.emailPlaceholder":`you@example.com`,"auth.signIn.method.magic-link.sendButton":`寄送登入連結`,"auth.signIn.method.magic-link.sendFailed":`連結寄送失敗,請確認 email 後重試。`,"auth.signIn.method.magic-link.sentTo":`已將登入連結寄到 {email}。`,"auth.signIn.method.magic-link.clickHint":`請點 email 裡的連結完成登入。連結很快會過期。`,"auth.signIn.method.magic-link.anotherEmail":`用其他 email`,"common.signOut":`登出`,"common.viewSite":`查看網站`,"common.copy":`複製`,"common.open":`開啟`,"common.failedToLoad":`載入失敗`,"common.unknownError":`發生未知錯誤`,"common.signedIn":`已登入`,"common.close":`關閉`,"common.skipToMain":`跳到主要內容`,"common.breadcrumb":`導覽路徑`,"common.toggleSidebar":`切換側邊欄`,"common.mobileSidebar":`網站導覽`,"common.mobileSidebarDescription":`網站管理導覽`,"common.saved":`已儲存`,"common.unsavedChanges":`尚未儲存的變更`,"console.eyebrow":`網站管理`,"console.description":`在這裡管理 {title} 的內容與營運資料。支援 MCP 的 agent 也能與你並行協作。`,"console.descriptionFallback":`在這裡管理這個網站的內容與營運資料。支援 MCP 的 agent 也能與你並行協作。`,"console.connector.title":`把 Claude 連接到管理後台`,"console.connector.body":`授權 Claude 協助管理這個網站的內容與營運資料。`,"console.connector.step1.title":`複製管理連線網址`,"console.connector.step1.body":`下一步會把這個網址貼到 Claude。`,"console.connector.step1.label":`管理連線網址`,"console.connector.step2.title":`新增自訂 connector`,"console.connector.step2.body":`開啟 Claude Customize,命名 connector,再貼上網址。`,"console.connector.step2.action":`開啟 Claude Customize`,"console.connector.step3.title":`登入並開始使用`,"console.connector.step3.body":`使用網站管理員帳號完成授權,之後即可請 Claude 協助管理這個網站。`,"console.connector.step3.action":`前往 Claude`,"console.collections.title":`資料集合`,"console.collections.emptyTitle":`尚未定義 collections`,"console.collections.emptyBody":`還沒有任何資料集合。可以從範本開始,或請你的 agent 建立第一個。`,"collection.breadcrumb":`內容清單`,"collection.create":`新增`,"collection.availableLanguage":`已有 {language}({locale})`,"collection.missingLanguage":`缺少 {language}({locale})`,"collection.moreLanguages":`{count} 個`,"collection.schemaDetails":`Schema 說明`,"collection.searchPlaceholder":`搜尋 ID 或可搜尋欄位...`,"collection.search":`搜尋`,"collection.pagination":`資料分頁`,"collection.previousPage":`上一頁`,"collection.nextPage":`下一頁`,"collection.filter.all":`全部`,"collection.empty.title":`目前沒有資料`,"collection.empty.search":`沒有符合「{search}」的資料。`,"collection.empty.withStatus":`{collection} 目前沒有 {status} 資料。`,"collection.empty.all":`{collection} 目前沒有資料。`,"collection.refreshing":`清單更新中...`,"collection.export":`匯出 CSV`,"collection.copyId":`複製完整 ID`,"collection.table.id":`ID`,"collection.table.title":`標題`,"collection.table.status":`狀態`,"collection.table.locale":`語言`,"collection.table.version":`版本`,"collection.table.updated":`更新時間`,"collection.table.actions":`操作`,"collection.table.selectAll":`選取這一頁的所有項目`,"collection.table.selectRow":`選取 {name}`,"rowActions.menuLabel":`資料列操作`,"rowActions.cancel":`取消`,"collection.untitled":`(未命名)`,"collection.bulk.selectedCount":`已選取 {count} 筆`,"collection.bulk.publish":`發布`,"collection.bulk.unpublish":`下架`,"collection.bulk.delete":`刪除`,"collection.bulk.deleteConfirm":`刪除已選取的 {count} 筆資料?這個動作無法復原。`,"crud.editTooltip":`編輯{name}。`,"crud.viewTooltip":`查看{name}。`,"crud.deleteTooltip":`刪除{name}。`,"crud.saveTitle":`儲存標題`,"crud.cancelTitle":`取消編輯`,"crud.deleteConfirm":`確定要刪除{name}?這個動作無法復原。`,"crud.saving":`儲存中...`,"entryEdit.back":`回到 {name}`,"entryEdit.body":`編輯 {name} 的內容,相關資料會自動帶出。`,"entryEdit.parent":`父層:{name}`,"entryEdit.save":`儲存變更`,"entryEdit.saveTooltip":`儲存這筆資料。`,"entryEdit.fields":`資料欄位`,"entryEdit.meta":`資料資訊`,"entryEdit.noChildEntries":`目前沒有符合這筆資料的子資料。`,"entryEdit.relationship":`透過子欄位 {child} 對應父欄位 {parent}。`,"entryEdit.addItem":`新增項目`,"entryEdit.removeItem":`移除項目`,"entryEdit.emptyOption":`無值`,"entryEdit.boolean":`啟用`,"entryEdit.operationalHint":`系統寫入的資料——手動修改可能在下次同步時被覆蓋。`,"entryEdit.unlockOperational":`解鎖編輯`,"entryEdit.readOnlyHint":`此資料由程序管理,請使用列上的可用操作進行變更。`,"entryEdit.contentLanguage":`內容語言`,"entryEdit.selectLanguage":`選擇語言`,"entryEdit.languageLocked":`儲存後不能直接更改語言,請開啟或建立另一筆翻譯。`,"entryEdit.languageTabs":`內容語言`,"entryEdit.sharedFields":`共用欄位`,"entryEdit.saveSharedFirst":`請先儲存共用欄位,再新增翻譯。`,"settings.page.title":`網站設定`,"settings.page.body":`管理後台名稱、網站預設資訊與訪客分析。`,"settings.tabsLabel":`網站設定分頁`,"settings.tab.brand":`一般`,"settings.tab.tracking":`分析`,"settings.brandSection":`網站識別`,"settings.brandSectionBody":`這些預設值會用於管理後台與 Mantle 產生的前台頁面。`,"settings.siteBrand":`後台名稱`,"settings.siteBrandHelp":`顯示在管理後台側欄與登入畫面,不會取代公開頁面的標題。`,"settings.siteTitle":`預設頁面標題`,"settings.siteTitleHelp":`頁面沒有自己的標題時使用,也是預設的 SEO 網站名稱。`,"settings.siteDescription":`預設網站描述`,"settings.siteDescriptionHelp":`頁面沒有自己的描述時,作為 SEO 與分享摘要。`,"settings.trackingSection":`訪客分析`,"settings.trackingSectionBody":`選填。儲存有效 ID 後,Mantle 會在產生的前台 HTML 自動加入標準追蹤碼。`,"settings.notConfigured":`尚未設定`,"settings.ga4MeasurementId":`GA4 Measurement ID`,"settings.ga4MeasurementIdHelp":`留空即停用。只填入 G-XXXXXXXXXX 形式的 ID,不要貼整段 gtag script。`,"settings.facebookPixelId":`Facebook Pixel ID`,"settings.facebookPixelIdHelp":`留空即停用。只填入數字 Pixel ID,Mantle 會產生標準 base code。`,"nav.home":`首頁`,"nav.content":`內容`,"nav.operations":`營運資料`,"nav.media":`媒體庫`,"nav.more":`更多`,"nav.settings":`設定`,"nav.staff":`後台使用者`,"nav.members":`會員管理`,"nav.reports":`報表`,"nav.localizedContent":`包含多語內容`,"ops.run":`執行`,"ops.running":`執行中...`,"views.page.body":`{schema} 的唯讀報表。`,"views.params.title":`查詢參數`,"views.run":`查詢`,"views.running":`查詢中...`,"views.empty.title":`沒有資料`,"views.empty.body":`目前的條件下沒有資料。`,"views.notFound.title":`找不到這個 View`,"staff.page.title":`後台使用者`,"staff.page.body":`可使用 Email 邀請,或請使用者先登入網站,再到「會員管理」授予後台權限。只有網站擁有者可以變更權限。`,"staff.invite.title":`邀請協作者`,"staff.invite.emailLabel":`Email`,"staff.invite.emailPlaceholder":`teammate@example.com`,"staff.invite.roleLabel":`角色`,"staff.invite.button":`建立邀請`,"staff.invite.sending":`邀請中…`,"staff.invite.revoke":`撤銷`,"staff.invite.hint":`對方使用相同 Email 登入後,就會加入團隊。`,"staff.emailSetup.title":`尚未開啟 Email 登入`,"staff.emailSetup.body":`若要開啟 Email 登入,請將設定指引交給 coding agent,連接交易型寄信服務並重新部署網站。`,"staff.emailSetup.copy":`複製設定步驟`,"staff.emailSetup.copied":`已複製`,"staff.emailSetup.guide":`Cloudflare 指南`,"staff.table.name":`姓名`,"staff.table.email":`Email`,"staff.table.status":`狀態/登入方式`,"staff.table.role":`角色`,"staff.role.owner":`擁有者`,"staff.role.owner.help":`可管理所有功能,包含設定與團隊權限。`,"staff.role.editor":`編輯者`,"staff.role.editor.help":`可管理內容、發布、站務操作與媒體。`,"staff.role.contributor":`協作者`,"staff.role.contributor.help":`只能建立與編輯草稿。`,"staff.role.none":`無角色`,"staff.badge.invited":`邀請中`,"staff.status.emailSignIn":`Email 登入`,"staff.self":`你自己`,"members.page.title":`會員管理`,"members.page.body":`曾登入網站且沒有管理後台權限的會員。`,"members.searchPlaceholder":`搜尋姓名或 Email...`,"members.search":`搜尋`,"members.table.name":`姓名`,"members.table.email":`Email`,"members.table.status":`狀態`,"members.table.joined":`加入時間`,"members.table.teamAccess":`團隊權限`,"members.promote":`授予後台權限`,"members.verified":`已驗證`,"members.unverified":`未驗證`,"members.empty.title":`目前沒有會員`,"members.empty.body":`使用者登入網站後會顯示在這裡。`,"members.emptySearch.title":`找不到相符會員`,"members.emptySearch.body":`請改用其他姓名或 Email 搜尋。`,"members.pagination":`會員分頁`,"members.previousPage":`上一頁`,"members.nextPage":`下一頁`,"status.draft":`草稿`,"status.published":`已發布`,"status.archived":`已封存`,"preferences.heading":`偏好設定`,"preferences.language":`後台語言`,"preferences.language.search":`搜尋語言...`,"preferences.language.noResults":`找不到語言。`,"preferences.direction":`文字方向`,"preferences.direction.auto":`文字方向會跟隨選擇的語言。`,"preferences.appearance":`外觀`,"preferences.light":`淺色`,"preferences.dark":`深色`,"preferences.system":`跟隨系統`,"preferences.ltr":`左到右`,"preferences.rtl":`右到左`,"preferences.page.title":`個人偏好`,"preferences.page.body":`這些偏好只保存在這個瀏覽器,只影響 admin console,不會改動站台設定。`,"preferences.page.languageBody":`選擇系統頁與 admin chrome 使用的語言。`,"preferences.page.appearanceBody":`選擇淺色、深色,或跟隨作業系統。`,"preferences.page.open":`個人偏好`,"system.notFound.title":`找不到頁面`,"system.notFound.body":`沒有 view 註冊在`,"system.notFound.back":`回首頁`,"editor.page.title":`內容編輯器`,"editor.page.body":`在交給 agent 或發布流程之前,先用 Markdown、HTML 或 Rich Editor 編輯內容草稿。`,"editor.mode.markdown":`Markdown`,"editor.mode.html":`HTML`,"editor.mode.rich":`Rich Editor`,"editor.titleLabel":`標題`,"editor.slugLabel":`Slug`,"editor.bodyLabel":`本文`,"editor.preview":`預覽`,"editor.saveDraft":`儲存草稿`,"editor.markdownHint":`支援標題、清單、連結與 fenced code blocks。`,"editor.htmlHint":`用原始碼模式編輯可信任的 HTML 片段。`,"editor.richHint":`不碰 markup 也能整理段落、提示框與內文。`,"editor.toolbar":`Rich Editor 工具列`,"editor.undo":`復原`,"editor.redo":`重做`,"editor.aiClean":`插入提示區塊`,"editor.uploadImage":`上傳圖片`,"editor.uploading":`圖片上傳中...`,"editor.textStyle":`文字樣式`,"editor.paragraph":`段落`,"editor.quote":`引言`,"editor.code":`程式碼`,"editor.headingPlaceholder":`標題`,"editor.selectedText":`選取文字`,"editor.bold":`粗體`,"editor.italic":`斜體`,"editor.underline":`底線`,"editor.strike":`刪除線`,"editor.inlineCode":`行內程式碼`,"editor.textColor":`文字顏色`,"editor.highlight":`螢光標記`,"editor.palette":`品牌色`,"editor.alignLeft":`靠左對齊`,"editor.alignCenter":`置中對齊`,"editor.alignRight":`靠右對齊`,"editor.bulletList":`項目清單`,"editor.numberList":`編號清單`,"editor.checkList":`待辦清單`,"editor.indent":`縮排`,"editor.link":`連結`,"editor.linkText":`連結文字`,"editor.table":`表格`,"editor.mediaLibrary":`媒體庫`,"editor.imageUrl":`圖片網址`,"editor.insertImage":`插入圖片`,"editor.videoUrl":`YouTube / Dailymotion 連結`,"editor.insertVideo":`插入影片`,"media.alt":`替代文字`,"media.title":`媒體庫`,"media.description":`這個網站上傳過的所有圖片。可以在內容中重複使用、整理替代文字,或刪除不需要的圖片。`,"media.upload":`上傳`,"media.uploading":`上傳中...`,"media.dropHere":`把圖片拖曳到這裡上傳`,"media.searchPlaceholder":`搜尋替代文字、說明或 id`,"media.empty.title":`還沒有圖片`,"media.empty.all":`上傳一張圖片,開始建立媒體庫。`,"media.empty.search":`沒有符合「{search}」的圖片。`,"media.noPurpose":`這個網站沒有設定上傳用途,無法上傳。`,"media.setup.title":`媒體儲存尚未啟用`,"media.setup.body":`請將設定指引交給 coding agent,為這個部署連接儲存空間並重新部署網站。`,"media.setup.cloudflare":`Cloudflare 部署使用 R2;啟用 R2 可能需要先設定帳務資料。`,"media.setup.copy":`複製設定指引`,"media.setup.copied":`已複製指引`,"media.setup.guide":`Cloudflare R2 設定`,"media.caption":`說明文字`,"media.altPlaceholder":`描述這張圖片`,"media.captionPlaceholder":`選填說明`,"media.save":`儲存`,"media.saving":`儲存中...`,"media.saved":`已儲存`,"media.delete":`刪除`,"media.deleteConfirm":`確定要刪除這張圖片嗎?所有使用到的地方都會一併移除。`,"media.open":`開啟原圖`,"media.copyId":`複製 id`,"media.uploaded":`上傳於 {date}`,"media.pick":`從媒體庫選擇`,"media.pickTitle":`選擇圖片`,"media.pickDescription":`挑一張現有圖片重複使用,或上傳新圖片。`,"media.use":`使用這張圖片`,"media.loadMore":`載入更多`,"media.uploadFailed":`{total} 張圖片中有 {count} 張上傳失敗。`,"media.capabilityMissing":`無法準備 {mime} 上傳。`,"media.variantUploadFailed":`{mime} 上傳失敗,請再試一次。`,"media.rasterOnly":`請上傳 JPEG、PNG、WebP、AVIF 或 GIF 圖片。`,"media.noRequiredVariants":`媒體政策尚未設定必要的圖片格式。`,"media.prepareFailed":`無法準備圖片上傳。`,"media.encoderUnsupported":`這個網站的媒體政策要求此瀏覽器無法產生的圖片格式({mime})。請聯絡網站開發者調整政策。`,"entryEdit.publish":`發布`,"entryEdit.publishing":`發布中...`,"entryEdit.publishTooltip":`發布這筆草稿。`,"entryEdit.publishDisabledDirty":`請先儲存變更才能發布。`,"entryEdit.publishMissingRequired":`請先完成必填欄位才能發布。`,"entryEdit.unpublish":`取消發布`,"entryEdit.unpublishing":`取消發布中...`,"entryEdit.unpublishTooltip":`將這筆資料改回草稿以便編輯。`,"ops.error.executionFailed":`操作已執行,但未能完成。`,"ops.error.detailsLabel":`顯示詳細資訊`,"ops.success":`{name} 已完成。`,"confirm.title":`確定要這麼做嗎?`,"confirm.cancel":`取消`,"confirm.confirm":`確定`,"collection.schemaSummary.lifecycleAndI18n":`管理 {name} 的項目、發布狀態與多語內容。`,"collection.schemaSummary.lifecycleOnly":`管理 {name} 的項目與發布狀態。`,"collection.schemaSummary.i18nOnly":`管理 {name} 的項目與多語內容。`,"collection.schemaSummary.plain":`管理 {name} 的項目。`,"entryEdit.mediaMissing":`這張圖片已遺失或已被刪除。`,"entryEdit.dateTime.select":`選擇日期與時間`,"entryEdit.dateTime.time":`時間`},"zh-CN":{"admin.consoleTitle":`管理后台`,"auth.accessDenied.noStaff":`你已登录,但这个账号没有管理后台权限。`,"auth.accessDenied.askOwner":`请网站所有者将你加入团队,或登出改用其他账号。`,"auth.signIn.title":`登录`,"common.signOut":`登出`,"common.viewSite":`查看网站`,"common.copy":`复制`,"common.open":`打开`,"common.failedToLoad":`加载失败`,"common.unknownError":`发生未知错误`,"common.signedIn":`已登录`,"common.close":`关闭`,"common.skipToMain":`跳到主要内容`,"common.breadcrumb":`导航路径`,"common.toggleSidebar":`切换侧边栏`,"common.mobileSidebar":`网站导航`,"common.mobileSidebarDescription":`网站管理导航`,"common.saved":`已保存`,"common.unsavedChanges":`尚未保存的变更`,"console.eyebrow":`网站管理`,"console.description":`在这里管理 {title} 的内容与运营数据。支持 MCP 的 agent 也能与你并行协作。`,"console.descriptionFallback":`在这里管理这个网站的内容与运营数据。支持 MCP 的 agent 也能与你并行协作。`,"console.connector.title":`把 Claude 连接到管理后台`,"console.connector.body":`授权 Claude 协助管理这个网站的内容与运营数据。`,"console.connector.step1.title":`复制管理连接网址`,"console.connector.step1.body":`下一步会把这个网址粘贴到 Claude。`,"console.connector.step1.label":`管理连接网址`,"console.connector.step2.title":`添加自定义 connector`,"console.connector.step2.body":`打开 Claude Customize,命名 connector,再粘贴网址。`,"console.connector.step2.action":`打开 Claude Customize`,"console.connector.step3.title":`登录并开始使用`,"console.connector.step3.body":`使用网站管理员账号完成授权,之后即可请 Claude 协助管理这个网站。`,"console.connector.step3.action":`前往 Claude`,"console.collections.title":`数据集合`,"collection.breadcrumb":`内容清单`,"collection.create":`新增`,"collection.availableLanguage":`已有 {language}({locale})`,"collection.missingLanguage":`缺少 {language}({locale})`,"collection.moreLanguages":`{count} 个`,"collection.filter.all":`全部`,"collection.table.title":`标题`,"collection.table.status":`状态`,"collection.table.locale":`语言`,"collection.table.version":`版本`,"collection.table.updated":`更新时间`,"collection.table.actions":`操作`,"rowActions.menuLabel":`数据行操作`,"rowActions.cancel":`取消`,"collection.untitled":`(未命名)`,"collection.searchPlaceholder":`搜索 ID 或可搜索字段...`,"collection.search":`搜索`,"collection.pagination":`资料分页`,"collection.previousPage":`上一页`,"collection.nextPage":`下一页`,"collection.empty.title":`目前没有资料`,"collection.empty.search":`没有符合“{search}”的资料。`,"collection.empty.withStatus":`{collection} 目前没有 {status} 资料。`,"collection.empty.all":`{collection} 目前没有资料。`,"collection.refreshing":`列表更新中...`,"collection.export":`导出 CSV`,"collection.copyId":`复制完整 ID`,"collection.table.id":`ID`,"collection.table.selectAll":`选取本页所有项目`,"collection.table.selectRow":`选取 {name}`,"collection.bulk.selectedCount":`已选取 {count} 笔`,"collection.bulk.publish":`发布`,"collection.bulk.unpublish":`下架`,"collection.bulk.delete":`删除`,"collection.bulk.deleteConfirm":`删除已选取的 {count} 笔资料?这个动作无法复原。`,"crud.editTooltip":`编辑{name}。`,"crud.viewTooltip":`查看{name}。`,"crud.deleteTooltip":`删除{name}。`,"crud.saveTitle":`保存标题`,"crud.cancelTitle":`取消编辑`,"crud.deleteConfirm":`确定要删除{name}?这个动作无法复原。`,"crud.saving":`保存中...`,"entryEdit.back":`回到 {name}`,"entryEdit.body":`编辑 {name} 的内容,相关资料会自动带出。`,"entryEdit.parent":`父层:{name}`,"entryEdit.save":`保存变更`,"entryEdit.saveTooltip":`保存这笔资料。`,"entryEdit.fields":`资料字段`,"entryEdit.meta":`资料信息`,"entryEdit.noChildEntries":`目前没有符合这笔资料的子资料。`,"entryEdit.relationship":`透过子字段 {child} 对应父字段 {parent}。`,"entryEdit.addItem":`新增项目`,"entryEdit.removeItem":`移除项目`,"entryEdit.emptyOption":`无值`,"entryEdit.boolean":`启用`,"entryEdit.operationalHint":`系统写入的资料——手动修改可能在下次同步时被覆盖。`,"entryEdit.unlockOperational":`解锁编辑`,"entryEdit.readOnlyHint":`此资料由程序管理,请使用行上的可用操作进行变更。`,"entryEdit.contentLanguage":`内容语言`,"entryEdit.selectLanguage":`选择语言`,"entryEdit.languageLocked":`保存后不能直接更改语言,请打开或创建另一笔翻译。`,"entryEdit.languageTabs":`内容语言`,"entryEdit.sharedFields":`共用字段`,"entryEdit.saveSharedFirst":`请先保存共用字段,再新增翻译。`,"settings.page.title":`网站设置`,"settings.page.body":`管理后台名称、网站默认信息与访客分析。`,"settings.tabsLabel":`网站设置分页`,"settings.tab.brand":`一般`,"settings.tab.tracking":`分析`,"settings.brandSection":`网站识别`,"settings.brandSectionBody":`这些默认值会用于管理后台与 Mantle 生成的前台页面。`,"settings.siteBrand":`后台名称`,"settings.siteBrandHelp":`显示在管理后台侧栏与登录页面,不会取代公开页面标题。`,"settings.siteTitle":`默认页面标题`,"settings.siteTitleHelp":`页面没有自己的标题时使用,也是默认 SEO 网站名称。`,"settings.siteDescription":`默认网站描述`,"settings.siteDescriptionHelp":`页面没有自己的描述时,作为 SEO 与分享摘要。`,"settings.trackingSection":`访客分析`,"settings.trackingSectionBody":`选填。保存有效 ID 后,Mantle 会在生成的前台 HTML 自动加入标准追踪码。`,"settings.notConfigured":`尚未设置`,"settings.ga4MeasurementId":`GA4 Measurement ID`,"settings.ga4MeasurementIdHelp":`留空即停用。只填入 G-XXXXXXXXXX 形式的 ID,不要贴整段 gtag script。`,"settings.facebookPixelId":`Facebook Pixel ID`,"settings.facebookPixelIdHelp":`留空即停用。只填入数字 Pixel ID,Mantle 会生成标准 base code。`,"nav.home":`首页`,"nav.content":`内容`,"nav.operations":`运营数据`,"nav.media":`媒体库`,"nav.more":`更多`,"nav.settings":`设置`,"nav.staff":`后台用户`,"nav.reports":`报表`,"nav.localizedContent":`包含多语言内容`,"ops.run":`执行`,"ops.running":`执行中...`,"views.page.body":`{schema} 的只读报表。`,"views.params.title":`查询参数`,"views.run":`查询`,"views.running":`查询中...`,"views.empty.title":`没有数据`,"views.empty.body":`当前条件下没有数据。`,"views.notFound.title":`找不到这个 View`,"staff.page.title":`后台用户`,"staff.page.body":`可使用 Email 邀请,或请用户先登录网站,再到“会员管理”授予后台权限。只有网站所有者可以更改权限。`,"staff.invite.title":`邀请协作者`,"staff.invite.hint":`对方使用相同 Email 登录后,就会加入团队。`,"staff.emailSetup.title":`尚未开启 Email 登录`,"staff.emailSetup.body":`若要开启 Email 登录,请将设置指引交给 coding agent,连接事务型邮件服务并重新部署网站。`,"staff.emailSetup.copy":`复制设置步骤`,"staff.emailSetup.copied":`已复制`,"staff.emailSetup.guide":`Cloudflare 指南`,"staff.role.owner":`所有者`,"staff.role.owner.help":`可管理所有功能,包括设置与团队权限。`,"staff.role.editor":`编辑者`,"staff.role.editor.help":`可管理内容、发布、站务操作与媒体。`,"staff.role.contributor":`协作者`,"staff.role.contributor.help":`只能创建和编辑草稿。`,"members.table.teamAccess":`团队权限`,"members.promote":`授予后台权限`,"status.draft":`草稿`,"status.published":`已发布`,"status.archived":`已归档`,"preferences.heading":`偏好设置`,"preferences.language":`后台语言`,"preferences.language.search":`搜索语言...`,"preferences.language.noResults":`找不到语言。`,"preferences.direction":`文字方向`,"preferences.direction.auto":`文字方向会跟随选择的语言。`,"preferences.appearance":`外观`,"preferences.light":`浅色`,"preferences.dark":`深色`,"preferences.system":`跟随系统`,"preferences.ltr":`从左到右`,"preferences.rtl":`从右到左`,"preferences.page.open":`个人偏好`,"preferences.page.title":`个人偏好`,"preferences.page.body":`这些偏好只保存在此浏览器,只影响 admin console,不会修改站点设置。`,"preferences.page.languageBody":`选择系统页面和 admin chrome 使用的语言。`,"preferences.page.appearanceBody":`选择浅色、深色,或跟随操作系统。`,"editor.page.title":`内容编辑器`,"editor.page.body":`在交给 agent 或发布流程前,先用 Markdown、HTML 或 Rich Editor 编辑内容草稿。`,"editor.mode.markdown":`Markdown`,"editor.mode.html":`HTML`,"editor.mode.rich":`Rich Editor`,"editor.titleLabel":`标题`,"editor.slugLabel":`Slug`,"editor.bodyLabel":`正文`,"editor.preview":`预览`,"editor.saveDraft":`保存草稿`,"editor.markdownHint":`支持标题、列表、链接与 fenced code blocks。`,"editor.htmlHint":`用源码模式编辑可信任的 HTML 片段。`,"editor.richHint":`不用碰 markup 也能整理段落、提示框与内文。`,"editor.toolbar":`Rich Editor 工具栏`,"editor.undo":`撤销`,"editor.redo":`重做`,"editor.aiClean":`插入提示区块`,"editor.uploadImage":`上传图片`,"editor.uploading":`图片上传中...`,"editor.textStyle":`文字样式`,"editor.paragraph":`段落`,"editor.quote":`引用`,"editor.code":`代码`,"editor.headingPlaceholder":`标题`,"editor.selectedText":`选取文字`,"editor.bold":`粗体`,"editor.italic":`斜体`,"editor.underline":`下划线`,"editor.strike":`删除线`,"editor.inlineCode":`行内代码`,"editor.textColor":`文字颜色`,"editor.highlight":`高亮标记`,"editor.palette":`品牌色`,"editor.alignLeft":`左对齐`,"editor.alignCenter":`居中对齐`,"editor.alignRight":`右对齐`,"editor.bulletList":`项目列表`,"editor.numberList":`编号列表`,"editor.checkList":`待办列表`,"editor.indent":`缩进`,"editor.link":`链接`,"editor.linkText":`链接文字`,"editor.table":`表格`,"editor.mediaLibrary":`媒体库`,"editor.imageUrl":`图片网址`,"editor.insertImage":`插入图片`,"editor.videoUrl":`YouTube / Dailymotion 链接`,"editor.insertVideo":`插入视频`,"media.alt":`替代文字`,"media.title":`媒体库`,"media.description":`这个网站上传过的所有图片。可以在内容中重复使用、整理替代文字,或删除不需要的图片。`,"media.upload":`上传`,"media.uploading":`上传中...`,"media.dropHere":`把图片拖到这里上传`,"media.searchPlaceholder":`搜索替代文字、说明或 id`,"media.empty.title":`还没有图片`,"media.empty.all":`上传一张图片,开始建立媒体库。`,"media.empty.search":`没有符合“{search}”的图片。`,"media.noPurpose":`这个网站没有设置上传用途,无法上传。`,"media.setup.title":`媒体存储尚未启用`,"media.setup.body":`请将设置指引交给 coding agent,为这个部署连接存储空间并重新部署网站。`,"media.setup.cloudflare":`Cloudflare 部署使用 R2;启用 R2 可能需要先设置账务信息。`,"media.setup.copy":`复制设置指引`,"media.setup.copied":`已复制指引`,"media.setup.guide":`Cloudflare R2 设置`,"media.caption":`说明文字`,"media.altPlaceholder":`描述这张图片`,"media.captionPlaceholder":`选填说明`,"media.save":`保存`,"media.saving":`保存中...`,"media.saved":`已保存`,"media.delete":`删除`,"media.deleteConfirm":`确定要删除这张图片吗?所有使用到的地方都会一并移除。`,"media.open":`打开原图`,"media.copyId":`复制 id`,"media.uploaded":`上传于 {date}`,"media.pick":`从媒体库选择`,"media.pickTitle":`选择图片`,"media.pickDescription":`挑一张现有图片重复使用,或上传新图片。`,"media.use":`使用这张图片`,"media.loadMore":`加载更多`,"media.uploadFailed":`{total} 张图片中有 {count} 张上传失败。`,"media.capabilityMissing":`无法准备 {mime} 上传。`,"media.variantUploadFailed":`{mime} 上传失败,请重试。`,"media.rasterOnly":`请上传 JPEG、PNG、WebP、AVIF 或 GIF 图片。`,"media.noRequiredVariants":`媒体策略尚未设置必要的图片格式。`,"media.prepareFailed":`无法准备图片上传。`,"media.encoderUnsupported":`这个网站的媒体政策要求此浏览器无法生成的图片格式({mime})。请联系网站开发者调整政策。`,"entryEdit.publish":`发布`,"entryEdit.publishing":`发布中...`,"entryEdit.publishTooltip":`发布这笔草稿。`,"entryEdit.publishDisabledDirty":`请先保存变更才能发布。`,"entryEdit.publishMissingRequired":`请先完成必填字段才能发布。`,"entryEdit.unpublish":`取消发布`,"entryEdit.unpublishing":`取消发布中...`,"entryEdit.unpublishTooltip":`将这笔资料改回草稿以便编辑。`,"ops.error.executionFailed":`操作已执行,但未能完成。`,"ops.error.detailsLabel":`显示详细信息`,"ops.success":`{name} 已完成。`,"confirm.title":`确定要这么做吗?`,"confirm.cancel":`取消`,"confirm.confirm":`确定`,"collection.schemaSummary.lifecycleAndI18n":`管理 {name} 的项目、发布状态与多语内容。`,"collection.schemaSummary.lifecycleOnly":`管理 {name} 的项目与发布状态。`,"collection.schemaSummary.i18nOnly":`管理 {name} 的项目与多语内容。`,"collection.schemaSummary.plain":`管理 {name} 的项目。`,"entryEdit.mediaMissing":`这张图片已丢失或已被删除。`,"entryEdit.dateTime.select":`选择日期与时间`,"entryEdit.dateTime.time":`时间`},de:{"auth.signIn.title":`Anmelden`,"common.signOut":`Abmelden`,"common.viewSite":`Website ansehen`,"common.copy":`Kopieren`,"common.open":`Öffnen`,"common.failedToLoad":`Laden fehlgeschlagen`,"common.signedIn":`Angemeldet`,"collection.filter.all":`Alle`,"nav.home":`Start`,"nav.content":`Inhalte`,"nav.more":`Mehr`,"nav.settings":`Einstellungen`,"status.draft":`Entwürfe`,"status.published":`Veröffentlicht`,"status.archived":`Archiviert`,"preferences.heading":`Präferenzen`,"preferences.language":`Admin-Sprache`,"preferences.language.search":`Sprachen suchen...`,"preferences.language.noResults":`Keine Sprachen gefunden.`,"preferences.direction":`Textrichtung`,"preferences.direction.auto":`Die Textrichtung folgt der gewählten Sprache.`,"preferences.appearance":`Darstellung`,"preferences.light":`Hell`,"preferences.dark":`Dunkel`,"preferences.system":`System`,"preferences.ltr":`Links nach rechts`,"preferences.rtl":`Rechts nach links`,"preferences.page.open":`Präferenzen`,"preferences.page.title":`Persönliche Präferenzen`,"preferences.page.body":`Diese Präferenzen bleiben in diesem Browser. Sie ändern nur die Admin-Konsole und keine Website-Einstellungen.`,"preferences.page.languageBody":`Wähle die Sprache für Systemseiten und Admin-Chrome.`,"preferences.page.appearanceBody":`Wähle hell, dunkel oder dein Betriebssystem.`},es:{"auth.signIn.title":`Iniciar sesión`,"common.signOut":`Cerrar sesión`,"common.viewSite":`Ver sitio`,"common.copy":`Copiar`,"common.open":`Abrir`,"common.failedToLoad":`Error al cargar`,"common.signedIn":`Sesión iniciada`,"collection.filter.all":`Todo`,"nav.home":`Inicio`,"nav.content":`Contenido`,"nav.more":`Más`,"nav.settings":`Configuración`,"status.draft":`Borradores`,"status.published":`Publicado`,"status.archived":`Archivado`,"preferences.heading":`Preferencias`,"preferences.language":`Idioma del admin`,"preferences.language.search":`Buscar idiomas...`,"preferences.language.noResults":`No se encontraron idiomas.`,"preferences.direction":`Dirección del texto`,"preferences.direction.auto":`La dirección del texto sigue el idioma seleccionado.`,"preferences.appearance":`Apariencia`,"preferences.light":`Claro`,"preferences.dark":`Oscuro`,"preferences.system":`Sistema`,"preferences.ltr":`Izquierda a derecha`,"preferences.rtl":`Derecha a izquierda`,"preferences.page.open":`Preferencias`,"preferences.page.title":`Preferencias personales`,"preferences.page.body":`Estas preferencias se guardan en este navegador. Solo cambian la consola de administración y no modifican la configuración del sitio.`,"preferences.page.languageBody":`Elige el idioma de las páginas del sistema y la interfaz de administración.`,"preferences.page.appearanceBody":`Elige claro, oscuro o seguir el sistema operativo.`},fr:{"auth.signIn.title":`Se connecter`,"common.signOut":`Se déconnecter`,"common.viewSite":`Voir le site`,"common.copy":`Copier`,"common.open":`Ouvrir`,"common.failedToLoad":`Échec du chargement`,"common.signedIn":`Connecté`,"collection.filter.all":`Tout`,"nav.home":`Accueil`,"nav.content":`Contenu`,"nav.more":`Plus`,"nav.settings":`Paramètres`,"status.draft":`Brouillons`,"status.published":`Publié`,"status.archived":`Archivé`,"preferences.heading":`Préférences`,"preferences.language":`Langue admin`,"preferences.language.search":`Rechercher une langue...`,"preferences.language.noResults":`Aucune langue trouvée.`,"preferences.direction":`Direction du texte`,"preferences.direction.auto":`La direction du texte suit la langue sélectionnée.`,"preferences.appearance":`Apparence`,"preferences.light":`Clair`,"preferences.dark":`Sombre`,"preferences.system":`Système`,"preferences.ltr":`Gauche à droite`,"preferences.rtl":`Droite à gauche`,"preferences.page.open":`Préférences`,"preferences.page.title":`Préférences personnelles`,"preferences.page.body":`Ces préférences restent dans ce navigateur. Elles modifient seulement la console admin, pas les paramètres du site.`,"preferences.page.languageBody":`Choisissez la langue des pages système et de l'interface admin.`,"preferences.page.appearanceBody":`Choisissez clair, sombre ou le thème du système.`},it:{"auth.signIn.title":`Accedi`,"common.signOut":`Esci`,"common.viewSite":`Vedi sito`,"common.copy":`Copia`,"common.open":`Apri`,"common.failedToLoad":`Caricamento non riuscito`,"common.signedIn":`Accesso effettuato`,"collection.filter.all":`Tutto`,"nav.home":`Home`,"nav.content":`Contenuti`,"nav.more":`Altro`,"nav.settings":`Impostazioni`,"status.draft":`Bozze`,"status.published":`Pubblicato`,"status.archived":`Archiviato`,"preferences.heading":`Preferenze`,"preferences.language":`Lingua admin`,"preferences.language.search":`Cerca lingue...`,"preferences.language.noResults":`Nessuna lingua trovata.`,"preferences.direction":`Direzione testo`,"preferences.direction.auto":`La direzione del testo segue la lingua selezionata.`,"preferences.appearance":`Aspetto`,"preferences.light":`Chiaro`,"preferences.dark":`Scuro`,"preferences.system":`Sistema`,"preferences.ltr":`Da sinistra a destra`,"preferences.rtl":`Da destra a sinistra`,"preferences.page.open":`Preferenze`,"preferences.page.title":`Preferenze personali`,"preferences.page.body":`Queste preferenze restano in questo browser. Modificano solo la console admin e non le impostazioni del sito.`,"preferences.page.languageBody":`Scegli la lingua delle pagine di sistema e dell'interfaccia admin.`,"preferences.page.appearanceBody":`Scegli chiaro, scuro o segui il sistema operativo.`},ja:{"auth.signIn.title":`サインイン`,"auth.signIn.methodsLoadFailed":`サインイン方法を読み込めませんでした。再読み込みしてください。`,"auth.signIn.noMethods":`このサイトにはサインイン方法が設定されていません。`,"auth.signIn.unknownMethod":`未対応のサインイン方法: {kind}`,"auth.signIn.method.social.button":`{provider} でサインイン`,"auth.signIn.method.email-otp.body":`メールに届くワンタイムコードでサインインします。`,"auth.signIn.method.email-otp.emailLabel":`メールアドレス`,"auth.signIn.method.email-otp.emailPlaceholder":`you@example.com`,"auth.signIn.method.email-otp.sendButton":`コードを送信`,"auth.signIn.method.email-otp.sendFailed":`コードの送信に失敗しました。メールを確認してもう一度お試しください。`,"auth.signIn.method.email-otp.sentTo":`{email} にコードを送信しました。`,"auth.signIn.method.email-otp.otpLabel":`ワンタイムコード`,"auth.signIn.method.email-otp.otpPlaceholder":`6 桁のコードを入力`,"auth.signIn.method.email-otp.verifyButton":`コードを確認してサインイン`,"auth.signIn.method.email-otp.verifyFailed":`コードが一致しません。もう一度入力してください。`,"auth.signIn.method.email-otp.back":`別のメールアドレスを使う`,"auth.signIn.method.magic-link.body":`ワンタップでサインインできるリンクをメールでお送りします。`,"auth.signIn.method.magic-link.emailLabel":`メールアドレス`,"auth.signIn.method.magic-link.emailPlaceholder":`you@example.com`,"auth.signIn.method.magic-link.sendButton":`サインインリンクを送信`,"auth.signIn.method.magic-link.sendFailed":`リンクの送信に失敗しました。メールを確認してもう一度お試しください。`,"auth.signIn.method.magic-link.sentTo":`{email} にサインインリンクを送信しました。`,"auth.signIn.method.magic-link.clickHint":`メール内のリンクをクリックしてサインインを完了してください。リンクはまもなく失効します。`,"auth.signIn.method.magic-link.anotherEmail":`別のメールアドレスを使う`,"common.signOut":`サインアウト`,"common.viewSite":`サイトを見る`,"common.copy":`コピー`,"common.open":`開く`,"common.failedToLoad":`読み込みに失敗しました`,"common.signedIn":`サインイン済み`,"collection.filter.all":`すべて`,"nav.home":`ホーム`,"nav.content":`コンテンツ`,"nav.more":`その他`,"nav.settings":`設定`,"status.draft":`下書き`,"status.published":`公開済み`,"status.archived":`アーカイブ済み`,"preferences.heading":`環境設定`,"preferences.language":`管理画面の言語`,"preferences.language.search":`言語を検索...`,"preferences.language.noResults":`言語が見つかりません。`,"preferences.direction":`文字方向`,"preferences.direction.auto":`文字方向は選択した言語に従います。`,"preferences.appearance":`外観`,"preferences.light":`ライト`,"preferences.dark":`ダーク`,"preferences.system":`システム`,"preferences.ltr":`左から右`,"preferences.rtl":`右から左`,"preferences.page.open":`環境設定`,"preferences.page.title":`個人設定`,"preferences.page.body":`これらの設定はこのブラウザにのみ保存されます。管理コンソールだけに影響し、サイト設定は変更しません。`,"preferences.page.languageBody":`システムページと管理 UI で使う言語を選びます。`,"preferences.page.appearanceBody":`ライト、ダーク、またはシステム設定に合わせます。`},ko:{"auth.signIn.title":`로그인`,"common.signOut":`로그아웃`,"common.viewSite":`사이트 보기`,"common.copy":`복사`,"common.open":`열기`,"common.failedToLoad":`로드 실패`,"common.signedIn":`로그인됨`,"collection.filter.all":`전체`,"nav.home":`홈`,"nav.content":`콘텐츠`,"nav.more":`더보기`,"nav.settings":`설정`,"status.draft":`초안`,"status.published":`게시됨`,"status.archived":`보관됨`,"preferences.heading":`환경설정`,"preferences.language":`관리 언어`,"preferences.language.search":`언어 검색...`,"preferences.language.noResults":`언어를 찾을 수 없습니다.`,"preferences.direction":`텍스트 방향`,"preferences.direction.auto":`텍스트 방향은 선택한 언어를 따릅니다.`,"preferences.appearance":`화면 모드`,"preferences.light":`라이트`,"preferences.dark":`다크`,"preferences.system":`시스템`,"preferences.ltr":`왼쪽에서 오른쪽`,"preferences.rtl":`오른쪽에서 왼쪽`,"preferences.page.open":`환경설정`,"preferences.page.title":`개인 환경설정`,"preferences.page.body":`이 설정은 이 브라우저에만 저장됩니다. 관리 콘솔에만 적용되며 사이트 설정은 변경하지 않습니다.`,"preferences.page.languageBody":`시스템 페이지와 관리 UI에 사용할 언어를 선택합니다.`,"preferences.page.appearanceBody":`라이트, 다크 또는 운영체제 설정을 따르도록 선택합니다.`},"pt-BR":{"auth.signIn.title":`Entrar`,"common.signOut":`Sair`,"common.viewSite":`Ver site`,"common.copy":`Copiar`,"common.open":`Abrir`,"common.failedToLoad":`Falha ao carregar`,"common.signedIn":`Conectado`,"collection.filter.all":`Todos`,"nav.home":`Início`,"nav.content":`Conteúdo`,"nav.more":`Mais`,"nav.settings":`Configurações`,"status.draft":`Rascunhos`,"status.published":`Publicado`,"status.archived":`Arquivado`,"preferences.heading":`Preferências`,"preferences.language":`Idioma do admin`,"preferences.language.search":`Pesquisar idiomas...`,"preferences.language.noResults":`Nenhum idioma encontrado.`,"preferences.direction":`Direção do texto`,"preferences.direction.auto":`A direção do texto segue o idioma selecionado.`,"preferences.appearance":`Aparência`,"preferences.light":`Claro`,"preferences.dark":`Escuro`,"preferences.system":`Sistema`,"preferences.ltr":`Esquerda para direita`,"preferences.rtl":`Direita para esquerda`,"preferences.page.open":`Preferências`,"preferences.page.title":`Preferências pessoais`,"preferences.page.body":`Estas preferências ficam neste navegador. Elas mudam apenas o console admin e não alteram as configurações do site.`,"preferences.page.languageBody":`Escolha o idioma das páginas do sistema e da interface admin.`,"preferences.page.appearanceBody":`Escolha claro, escuro ou seguir o sistema operacional.`},ru:{"auth.signIn.title":`Войти`,"common.signOut":`Выйти`,"common.viewSite":`Открыть сайт`,"common.copy":`Копировать`,"common.open":`Открыть`,"common.failedToLoad":`Не удалось загрузить`,"common.signedIn":`Вы вошли`,"collection.filter.all":`Все`,"nav.home":`Главная`,"nav.content":`Контент`,"nav.more":`Еще`,"nav.settings":`Настройки`,"status.draft":`Черновики`,"status.published":`Опубликовано`,"status.archived":`Архив`,"preferences.heading":`Предпочтения`,"preferences.language":`Язык админки`,"preferences.language.search":`Поиск языков...`,"preferences.language.noResults":`Языки не найдены.`,"preferences.direction":`Направление текста`,"preferences.direction.auto":`Направление текста следует выбранному языку.`,"preferences.appearance":`Внешний вид`,"preferences.light":`Светлая`,"preferences.dark":`Темная`,"preferences.system":`Система`,"preferences.ltr":`Слева направо`,"preferences.rtl":`Справа налево`,"preferences.page.open":`Предпочтения`,"preferences.page.title":`Личные предпочтения`,"preferences.page.body":`Эти предпочтения хранятся в этом браузере. Они меняют только админ-консоль и не изменяют настройки сайта.`,"preferences.page.languageBody":`Выберите язык системных страниц и интерфейса админки.`,"preferences.page.appearanceBody":`Выберите светлую, темную тему или тему системы.`},nl:{"auth.signIn.title":`Inloggen`,"common.signOut":`Uitloggen`,"common.viewSite":`Site bekijken`,"common.copy":`Kopiëren`,"common.open":`Openen`,"common.failedToLoad":`Laden mislukt`,"common.signedIn":`Ingelogd`,"collection.filter.all":`Alles`,"nav.home":`Home`,"nav.content":`Content`,"nav.more":`Meer`,"nav.settings":`Instellingen`,"status.draft":`Concepten`,"status.published":`Gepubliceerd`,"status.archived":`Gearchiveerd`,"preferences.heading":`Voorkeuren`,"preferences.language":`Beheertaal`,"preferences.language.search":`Talen zoeken...`,"preferences.language.noResults":`Geen talen gevonden.`,"preferences.direction":`Tekstrichting`,"preferences.direction.auto":`De tekstrichting volgt de gekozen taal.`,"preferences.appearance":`Weergave`,"preferences.light":`Licht`,"preferences.dark":`Donker`,"preferences.system":`Systeem`,"preferences.ltr":`Links naar rechts`,"preferences.rtl":`Rechts naar links`,"preferences.page.open":`Voorkeuren`,"preferences.page.title":`Persoonlijke voorkeuren`,"preferences.page.body":`Deze voorkeuren blijven in deze browser. Ze wijzigen alleen de adminconsole en niet de site-instellingen.`,"preferences.page.languageBody":`Kies de taal voor systeempagina's en de admininterface.`,"preferences.page.appearanceBody":`Kies licht, donker of volg het besturingssysteem.`},pl:{"auth.signIn.title":`Zaloguj się`,"common.signOut":`Wyloguj się`,"common.viewSite":`Zobacz stronę`,"common.copy":`Kopiuj`,"common.open":`Otwórz`,"common.failedToLoad":`Nie udało się załadować`,"common.signedIn":`Zalogowano`,"collection.filter.all":`Wszystkie`,"nav.home":`Start`,"nav.content":`Treści`,"nav.more":`Więcej`,"nav.settings":`Ustawienia`,"status.draft":`Szkice`,"status.published":`Opublikowane`,"status.archived":`Zarchiwizowane`,"preferences.heading":`Preferencje`,"preferences.language":`Język panelu`,"preferences.language.search":`Szukaj języków...`,"preferences.language.noResults":`Nie znaleziono języków.`,"preferences.direction":`Kierunek tekstu`,"preferences.direction.auto":`Kierunek tekstu wynika z wybranego języka.`,"preferences.appearance":`Wygląd`,"preferences.light":`Jasny`,"preferences.dark":`Ciemny`,"preferences.system":`System`,"preferences.ltr":`Od lewej do prawej`,"preferences.rtl":`Od prawej do lewej`,"preferences.page.open":`Preferencje`,"preferences.page.title":`Preferencje osobiste`,"preferences.page.body":`Te preferencje są zapisane w tej przeglądarce. Zmieniają tylko konsolę administracyjną, nie ustawienia strony.`,"preferences.page.languageBody":`Wybierz język stron systemowych i interfejsu admina.`,"preferences.page.appearanceBody":`Wybierz jasny, ciemny lub zgodny z systemem.`},tr:{"auth.signIn.title":`Oturum aç`,"common.signOut":`Çıkış yap`,"common.viewSite":`Siteyi görüntüle`,"common.copy":`Kopyala`,"common.open":`Aç`,"common.failedToLoad":`Yüklenemedi`,"common.signedIn":`Oturum açık`,"collection.filter.all":`Tümü`,"nav.home":`Ana sayfa`,"nav.content":`İçerik`,"nav.more":`Daha fazla`,"nav.settings":`Ayarlar`,"status.draft":`Taslaklar`,"status.published":`Yayında`,"status.archived":`Arşivlendi`,"preferences.heading":`Tercihler`,"preferences.language":`Yönetici dili`,"preferences.language.search":`Dil ara...`,"preferences.language.noResults":`Dil bulunamadı.`,"preferences.direction":`Metin yönü`,"preferences.direction.auto":`Metin yönü seçilen dili izler.`,"preferences.appearance":`Görünüm`,"preferences.light":`Açık`,"preferences.dark":`Koyu`,"preferences.system":`Sistem`,"preferences.ltr":`Soldan sağa`,"preferences.rtl":`Sağdan sola`,"preferences.page.open":`Tercihler`,"preferences.page.title":`Kişisel tercihler`,"preferences.page.body":`Bu tercihler bu tarayıcıda kalır. Yalnızca yönetim konsolunu değiştirir, site ayarlarını değiştirmez.`,"preferences.page.languageBody":`Sistem sayfaları ve yönetim arayüzü için dili seçin.`,"preferences.page.appearanceBody":`Açık, koyu veya işletim sistemini takip et seçeneğini seçin.`},vi:{"auth.signIn.title":`Đăng nhập`,"common.signOut":`Đăng xuất`,"common.viewSite":`Xem trang`,"common.copy":`Sao chép`,"common.open":`Mở`,"common.failedToLoad":`Tải thất bại`,"common.signedIn":`Đã đăng nhập`,"collection.filter.all":`Tất cả`,"nav.home":`Trang chủ`,"nav.content":`Nội dung`,"nav.more":`Thêm`,"nav.settings":`Cài đặt`,"status.draft":`Bản nháp`,"status.published":`Đã xuất bản`,"status.archived":`Đã lưu trữ`,"preferences.heading":`Tùy chọn`,"preferences.language":`Ngôn ngữ quản trị`,"preferences.language.search":`Tìm ngôn ngữ...`,"preferences.language.noResults":`Không tìm thấy ngôn ngữ.`,"preferences.direction":`Hướng văn bản`,"preferences.direction.auto":`Hướng văn bản theo ngôn ngữ đã chọn.`,"preferences.appearance":`Giao diện`,"preferences.light":`Sáng`,"preferences.dark":`Tối`,"preferences.system":`Hệ thống`,"preferences.ltr":`Trái sang phải`,"preferences.rtl":`Phải sang trái`,"preferences.page.open":`Tùy chọn`,"preferences.page.title":`Tùy chọn cá nhân`,"preferences.page.body":`Các tùy chọn này chỉ lưu trong trình duyệt này. Chúng chỉ thay đổi admin console và không sửa cài đặt trang.`,"preferences.page.languageBody":`Chọn ngôn ngữ cho trang hệ thống và giao diện quản trị.`,"preferences.page.appearanceBody":`Chọn sáng, tối hoặc theo hệ điều hành.`},cs:{"auth.signIn.title":`Přihlásit se`,"common.signOut":`Odhlásit se`,"common.viewSite":`Zobrazit web`,"common.copy":`Kopírovat`,"common.open":`Otevřít`,"common.failedToLoad":`Načtení selhalo`,"common.signedIn":`Přihlášeno`,"collection.filter.all":`Vše`,"nav.home":`Domů`,"nav.content":`Obsah`,"nav.more":`Více`,"nav.settings":`Nastavení`,"status.draft":`Koncepty`,"status.published":`Publikováno`,"status.archived":`Archivováno`,"preferences.heading":`Předvolby`,"preferences.language":`Jazyk administrace`,"preferences.language.search":`Hledat jazyky...`,"preferences.language.noResults":`Nenalezeny žádné jazyky.`,"preferences.direction":`Směr textu`,"preferences.direction.auto":`Směr textu se řídí vybraným jazykem.`,"preferences.appearance":`Vzhled`,"preferences.light":`Světlý`,"preferences.dark":`Tmavý`,"preferences.system":`Systém`,"preferences.ltr":`Zleva doprava`,"preferences.rtl":`Zprava doleva`,"preferences.page.open":`Předvolby`,"preferences.page.title":`Osobní předvolby`,"preferences.page.body":`Tyto předvolby zůstávají v tomto prohlížeči. Mění jen administrační konzoli, ne nastavení webu.`,"preferences.page.languageBody":`Vyberte jazyk systémových stránek a administračního rozhraní.`,"preferences.page.appearanceBody":`Vyberte světlý, tmavý nebo systémový režim.`},uk:{"auth.signIn.title":`Увійти`,"common.signOut":`Вийти`,"common.viewSite":`Переглянути сайт`,"common.copy":`Копіювати`,"common.open":`Відкрити`,"common.failedToLoad":`Не вдалося завантажити`,"common.signedIn":`Ви увійшли`,"collection.filter.all":`Усі`,"nav.home":`Головна`,"nav.content":`Контент`,"nav.more":`Більше`,"nav.settings":`Налаштування`,"status.draft":`Чернетки`,"status.published":`Опубліковано`,"status.archived":`Архівовано`,"preferences.heading":`Параметри`,"preferences.language":`Мова адмінки`,"preferences.language.search":`Пошук мов...`,"preferences.language.noResults":`Мови не знайдено.`,"preferences.direction":`Напрям тексту`,"preferences.direction.auto":`Напрям тексту відповідає вибраній мові.`,"preferences.appearance":`Вигляд`,"preferences.light":`Світла`,"preferences.dark":`Темна`,"preferences.system":`Система`,"preferences.ltr":`Зліва направо`,"preferences.rtl":`Справа наліво`,"preferences.page.open":`Параметри`,"preferences.page.title":`Особисті параметри`,"preferences.page.body":`Ці параметри зберігаються в цьому браузері. Вони змінюють лише адмін-консоль, а не налаштування сайту.`,"preferences.page.languageBody":`Виберіть мову системних сторінок та адмін-інтерфейсу.`,"preferences.page.appearanceBody":`Виберіть світлу, темну тему або тему системи.`},ar:{"auth.signIn.title":`تسجيل الدخول`,"common.signOut":`تسجيل الخروج`,"common.viewSite":`عرض الموقع`,"common.copy":`نسخ`,"common.open":`فتح`,"common.failedToLoad":`فشل التحميل`,"common.signedIn":`تم تسجيل الدخول`,"collection.filter.all":`الكل`,"nav.home":`الرئيسية`,"nav.content":`المحتوى`,"nav.more":`المزيد`,"nav.settings":`الإعدادات`,"status.draft":`مسودات`,"status.published":`منشور`,"status.archived":`مؤرشف`,"preferences.heading":`التفضيلات`,"preferences.language":`لغة الإدارة`,"preferences.language.search":`ابحث عن اللغات...`,"preferences.language.noResults":`لم يتم العثور على لغات.`,"preferences.direction":`اتجاه النص`,"preferences.direction.auto":`يتبع اتجاه النص اللغة المحددة.`,"preferences.appearance":`المظهر`,"preferences.light":`فاتح`,"preferences.dark":`داكن`,"preferences.system":`النظام`,"preferences.ltr":`من اليسار إلى اليمين`,"preferences.rtl":`من اليمين إلى اليسار`,"preferences.page.open":`التفضيلات`,"preferences.page.title":`التفضيلات الشخصية`,"preferences.page.body":`تبقى هذه التفضيلات في هذا المتصفح. إنها تغيّر وحدة الإدارة فقط ولا تعدّل إعدادات الموقع.`,"preferences.page.languageBody":`اختر لغة صفحات النظام وواجهة الإدارة.`,"preferences.page.appearanceBody":`اختر الوضع الفاتح أو الداكن أو اتبع نظام التشغيل.`},he:{"auth.signIn.title":`כניסה`,"common.signOut":`יציאה`,"common.viewSite":`הצג אתר`,"common.copy":`העתק`,"common.open":`פתח`,"common.failedToLoad":`הטעינה נכשלה`,"common.signedIn":`מחובר`,"collection.filter.all":`הכול`,"nav.home":`בית`,"nav.content":`תוכן`,"nav.more":`עוד`,"nav.settings":`הגדרות`,"status.draft":`טיוטות`,"status.published":`פורסם`,"status.archived":`בארכיון`,"preferences.heading":`העדפות`,"preferences.language":`שפת ניהול`,"preferences.language.search":`חפש שפות...`,"preferences.language.noResults":`לא נמצאו שפות.`,"preferences.direction":`כיוון טקסט`,"preferences.direction.auto":`כיוון הטקסט נקבע לפי השפה שנבחרה.`,"preferences.appearance":`מראה`,"preferences.light":`בהיר`,"preferences.dark":`כהה`,"preferences.system":`מערכת`,"preferences.ltr":`משמאל לימין`,"preferences.rtl":`מימין לשמאל`,"preferences.page.open":`העדפות`,"preferences.page.title":`העדפות אישיות`,"preferences.page.body":`העדפות אלה נשמרות בדפדפן הזה. הן משנות רק את מסוף הניהול ולא את הגדרות האתר.`,"preferences.page.languageBody":`בחר את שפת דפי המערכת וממשק הניהול.`,"preferences.page.appearanceBody":`בחר בהיר, כהה או לפי מערכת ההפעלה.`},fa:{"auth.signIn.title":`ورود`,"common.signOut":`خروج`,"common.viewSite":`مشاهده سایت`,"common.copy":`کپی`,"common.open":`باز کردن`,"common.failedToLoad":`بارگذاری ناموفق بود`,"common.signedIn":`وارد شدهاید`,"collection.filter.all":`همه`,"nav.home":`خانه`,"nav.content":`محتوا`,"nav.more":`بیشتر`,"nav.settings":`تنظیمات`,"status.draft":`پیشنویسها`,"status.published":`منتشر شده`,"status.archived":`بایگانی شده`,"preferences.heading":`ترجیحات`,"preferences.language":`زبان مدیریت`,"preferences.language.search":`جستجوی زبانها...`,"preferences.language.noResults":`زبانی پیدا نشد.`,"preferences.direction":`جهت متن`,"preferences.direction.auto":`جهت متن از زبان انتخابشده پیروی میکند.`,"preferences.appearance":`ظاهر`,"preferences.light":`روشن`,"preferences.dark":`تیره`,"preferences.system":`سیستم`,"preferences.ltr":`چپ به راست`,"preferences.rtl":`راست به چپ`,"preferences.page.open":`ترجیحات`,"preferences.page.title":`ترجیحات شخصی`,"preferences.page.body":`این ترجیحات در همین مرورگر ذخیره میشود. فقط کنسول مدیریت را تغییر میدهد و تنظیمات سایت را تغییر نمیدهد.`,"preferences.page.languageBody":`زبان صفحات سیستمی و رابط مدیریت را انتخاب کنید.`,"preferences.page.appearanceBody":`روشن، تیره یا پیروی از سیستمعامل را انتخاب کنید.`},th:{"auth.signIn.title":`เข้าสู่ระบบ`,"common.signOut":`ออกจากระบบ`,"common.viewSite":`ดูเว็บไซต์`,"common.copy":`คัดลอก`,"common.open":`เปิด`,"common.failedToLoad":`โหลดไม่สำเร็จ`,"common.signedIn":`เข้าสู่ระบบแล้ว`,"collection.filter.all":`ทั้งหมด`,"nav.home":`หน้าแรก`,"nav.content":`เนื้อหา`,"nav.more":`เพิ่มเติม`,"nav.settings":`การตั้งค่า`,"status.draft":`ฉบับร่าง`,"status.published":`เผยแพร่แล้ว`,"status.archived":`เก็บถาวร`,"preferences.heading":`ค่ากำหนด`,"preferences.language":`ภาษาผู้ดูแล`,"preferences.language.search":`ค้นหาภาษา...`,"preferences.language.noResults":`ไม่พบภาษา`,"preferences.direction":`ทิศทางข้อความ`,"preferences.direction.auto":`ทิศทางข้อความจะตามภาษาที่เลือก`,"preferences.appearance":`รูปลักษณ์`,"preferences.light":`สว่าง`,"preferences.dark":`มืด`,"preferences.system":`ระบบ`,"preferences.ltr":`ซ้ายไปขวา`,"preferences.rtl":`ขวาไปซ้าย`,"preferences.page.open":`ค่ากำหนด`,"preferences.page.title":`ค่ากำหนดส่วนตัว`,"preferences.page.body":`ค่ากำหนดเหล่านี้จะอยู่ในเบราว์เซอร์นี้เท่านั้น และมีผลกับ admin console โดยไม่แก้การตั้งค่าเว็บไซต์`,"preferences.page.languageBody":`เลือกภาษาสำหรับหน้าระบบและส่วนติดต่อผู้ดูแล`,"preferences.page.appearanceBody":`เลือกสว่าง มืด หรือใช้ตามระบบปฏิบัติการ`},id:{"auth.signIn.title":`Masuk`,"common.signOut":`Keluar`,"common.viewSite":`Lihat situs`,"common.copy":`Salin`,"common.open":`Buka`,"common.failedToLoad":`Gagal memuat`,"common.signedIn":`Sudah masuk`,"collection.filter.all":`Semua`,"nav.home":`Beranda`,"nav.content":`Konten`,"nav.more":`Lainnya`,"nav.settings":`Pengaturan`,"status.draft":`Draf`,"status.published":`Terbit`,"status.archived":`Arsip`,"preferences.heading":`Preferensi`,"preferences.language":`Bahasa admin`,"preferences.language.search":`Cari bahasa...`,"preferences.language.noResults":`Bahasa tidak ditemukan.`,"preferences.direction":`Arah teks`,"preferences.direction.auto":`Arah teks mengikuti bahasa yang dipilih.`,"preferences.appearance":`Tampilan`,"preferences.light":`Terang`,"preferences.dark":`Gelap`,"preferences.system":`Sistem`,"preferences.ltr":`Kiri ke kanan`,"preferences.rtl":`Kanan ke kiri`,"preferences.page.open":`Preferensi`,"preferences.page.title":`Preferensi pribadi`,"preferences.page.body":`Preferensi ini tetap di browser ini. Preferensi hanya mengubah konsol admin dan tidak mengubah pengaturan situs.`,"preferences.page.languageBody":`Pilih bahasa untuk halaman sistem dan antarmuka admin.`,"preferences.page.appearanceBody":`Pilih terang, gelap, atau ikuti sistem operasi.`}};function Q(e,t,n={}){let r=Wv[e]?.[t]??Wv.en[t];for(let[e,t]of Object.entries(n))r=r.split(`{${e}}`).join(t);return r}function Gv({className:e,size:t=`default`,...n}){return(0,z.jsx)(tc,{"data-slot":`avatar`,"data-size":t,className:Y(`group/avatar relative flex size-8 shrink-0 rounded-full select-none after:absolute after:inset-0 after:rounded-full after:border after:border-border after:mix-blend-darken data-[size=lg]:size-10 data-[size=sm]:size-6 dark:after:mix-blend-lighten`,e),...n})}function Kv({className:e,...t}){return(0,z.jsx)(rc,{"data-slot":`avatar-image`,className:Y(`aspect-square size-full rounded-full object-cover`,e),...t})}function qv({className:e,...t}){return(0,z.jsx)(ac,{"data-slot":`avatar-fallback`,className:Y(`flex size-full items-center justify-center rounded-full bg-muted text-sm text-muted-foreground group-data-[size=sm]/avatar:text-xs`,e),...t})}function Jv(e){let t=e?.trim().split(/[\s._-]+/).filter(Boolean)??[];return(t.length>1?`${t[0]?.[0]??``}${t[t.length-1]?.[0]??``}`:(t[0]??`?`).slice(0,2)).toUpperCase()}function Yv({brand:e}){let{setOpenMobile:t}=Y_(),n=e.href??`/admin`;return(0,z.jsx)(ov,{className:`min-w-0 flex-1 group-data-[collapsible=icon]:hidden`,children:(0,z.jsx)(sv,{children:(0,z.jsx)(lv,{asChild:!0,className:`p-1`,children:(0,z.jsxs)(`a`,{href:n,onClick:()=>t(!1),children:[(0,z.jsxs)(Gv,{className:`size-7 rounded-md`,children:[e.image?(0,z.jsx)(Kv,{src:e.image,alt:``}):null,(0,z.jsx)(qv,{className:`rounded-md text-xs`,children:Jv(e.title)})]}),(0,z.jsx)(`span`,{className:`truncate font-semibold`,children:e.title})]})})})})}function Xv({...e}){return(0,z.jsx)(Fi,{"data-slot":`collapsible`,...e})}function Zv({...e}){return(0,z.jsx)(Ai,{"data-slot":`collapsible-trigger`,...e})}function Qv({...e}){return(0,z.jsx)(Mi,{"data-slot":`collapsible-content`,...e})}function $v({...e}){return(0,z.jsx)(pp,{"data-slot":`dropdown-menu`,...e})}function ey({...e}){return(0,z.jsx)(mp,{"data-slot":`dropdown-menu-trigger`,...e})}function ty({className:e,align:t=`start`,sideOffset:n=4,...r}){return(0,z.jsx)(hp,{children:(0,z.jsx)(gp,{"data-slot":`dropdown-menu-content`,sideOffset:n,align:t,className:Y(`z-50 max-h-(--radix-dropdown-menu-content-available-height) w-(--radix-dropdown-menu-trigger-width) min-w-32 origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 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 data-[state=closed]:overflow-hidden data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,e),...r})})}function ny({className:e,inset:t,variant:n=`default`,...r}){return(0,z.jsx)(vp,{"data-slot":`dropdown-menu-item`,"data-inset":t,"data-variant":n,className:Y(`group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:ps-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive`,e),...r})}function ry({className:e,inset:t,...n}){return(0,z.jsx)(_p,{"data-slot":`dropdown-menu-label`,"data-inset":t,className:Y(`px-1.5 py-1 text-xs font-medium text-muted-foreground data-inset:ps-7`,e),...n})}function iy({className:e,...t}){return(0,z.jsx)(yp,{"data-slot":`dropdown-menu-separator`,className:Y(`-mx-1 my-1 h-px bg-border`,e),...t})}function ay(e){return Array.isArray(e.items)}function oy({group:e,pathname:t,search:n}){return(0,z.jsxs)(iv,{children:[e.title&&(0,z.jsx)(av,{title:e.title,children:e.title}),(0,z.jsx)(ov,{children:e.items.map(e=>(0,z.jsx)(cy,{item:e,pathname:t,search:n},sy(e)))})]})}function sy(e){return ay(e)?`g:${e.title}`:`l:${e.url}`}function cy({item:e,pathname:t,search:n}){let{state:r,isMobile:i}=Y_();return ay(e)?r===`collapsed`&&!i?(0,z.jsx)(fy,{item:e,pathname:t,search:n}):(0,z.jsx)(uy,{item:e,pathname:t,search:n}):(0,z.jsx)(ly,{item:e,pathname:t,search:n})}function ly({item:e,pathname:t,search:n}){let{setOpenMobile:r}=Y_(),i=my(e,t,n);return(0,z.jsx)(sv,{children:(0,z.jsx)(lv,{asChild:!0,isActive:i,children:(0,z.jsxs)(`a`,{href:e.url,title:e.title,onClick:()=>r(!1),...e.external?{target:`_blank`,rel:`noreferrer`}:null,children:[e.icon&&(0,z.jsx)(e.icon,{"aria-hidden":!0}),(0,z.jsx)(`span`,{"data-sidebar-label":!0,className:`flex-1 truncate`,children:e.title}),(0,z.jsx)(py,{item:e})]})})})}function uy({item:e,pathname:t,search:n}){let r=gy(e,t,n);return(0,z.jsx)(Xv,{defaultOpen:r,className:`group/collapsible`,asChild:!0,children:(0,z.jsxs)(sv,{children:[(0,z.jsx)(Zv,{asChild:!0,children:(0,z.jsxs)(lv,{isActive:r,children:[e.icon&&(0,z.jsx)(e.icon,{"aria-hidden":!0}),(0,z.jsx)(`span`,{"data-sidebar-label":!0,className:`flex-1 truncate`,title:e.title,children:e.title}),(0,z.jsx)(py,{item:e}),(0,z.jsx)(At,{"aria-hidden":!0,"data-sidebar-label":!0,className:`transition-transform duration-200 group-data-[state=open]/collapsible:rotate-90 rtl:rotate-180 rtl:group-data-[state=open]/collapsible:-rotate-90`})]})}),(0,z.jsx)(Qv,{children:(0,z.jsx)(uv,{children:e.items.map(r=>(0,z.jsx)(dy,{link:r,siblings:e.items,pathname:t,search:n},r.url))})})]})})}function dy({link:e,siblings:t,pathname:n,search:r}){let{setOpenMobile:i}=Y_(),a=hy(e,t,n,r);return(0,z.jsx)(dv,{children:(0,z.jsx)(fv,{asChild:!0,isActive:a,children:(0,z.jsxs)(`a`,{href:e.url,title:e.title,onClick:()=>i(!1),children:[e.icon&&(0,z.jsx)(e.icon,{"aria-hidden":!0}),(0,z.jsx)(`span`,{children:e.title})]})})})}function fy({item:e,pathname:t,search:n}){let r=gy(e,t,n),{direction:i}=Iv();return(0,z.jsx)(sv,{children:(0,z.jsxs)($v,{children:[(0,z.jsx)(ey,{asChild:!0,children:(0,z.jsxs)(lv,{isActive:r,tooltip:e.markerLabel?`${e.title} · ${e.markerLabel}`:e.title,children:[e.icon&&(0,z.jsx)(e.icon,{"aria-hidden":!0}),(0,z.jsx)(`span`,{"data-sidebar-label":!0,title:e.title,children:e.title}),(0,z.jsx)(At,{"aria-hidden":!0,"data-sidebar-label":!0,className:`ms-auto`})]})}),(0,z.jsxs)(ty,{side:i===`rtl`?`left`:`right`,align:`start`,sideOffset:4,children:[(0,z.jsx)(ry,{children:e.title}),(0,z.jsx)(iy,{}),e.items.map(r=>(0,z.jsx)(ny,{asChild:!0,children:(0,z.jsx)(`a`,{href:r.url,className:Y(hy(r,e.items,t,n)&&`font-medium`),children:r.title})},r.url))]})]})})}function py({item:e}){if(!e.marker)return null;let t=e.marker,n=(0,z.jsx)(`span`,{"data-sidebar-label":!0,className:`inline-flex text-primary group-data-[active=true]/menu-button:text-sidebar-accent-foreground`,children:(0,z.jsx)(t,{"aria-hidden":!0,className:`size-3.5`})});return e.markerLabel?(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:n}),(0,z.jsx)(V_,{side:`right`,children:e.markerLabel})]}):n}function my(e,t,n){let r=new URL(e.url,`http://x`);if(r.pathname!==t)return!1;if(!r.search)return!0;let i=new URLSearchParams(r.search),a=new URLSearchParams(n);for(let[e,t]of i.entries())if(a.get(e)!==t)return!1;return!0}function hy(e,t,n,r){return my(e,n,r)?new URL(e.url,`http://x`).search?!0:!t.some(t=>t.url===e.url||!new URL(t.url,`http://x`).search?!1:my(t,n,r)):!1}function gy(e,t,n){return e.items.some(e=>my(e,t,n))?!0:e.items.some(e=>new URL(e.url,`http://x`).pathname===t)}function _y(){fetch(`/api/auth/sign-out`,{method:`POST`,credentials:`include`}).then(()=>{window.location.href=`/admin/sign-in`})}function vy({login:e,image:t,role:n}){let{isMobile:r}=Y_(),{language:i}=Iv(),a=Jv(e);return(0,z.jsx)(ov,{children:(0,z.jsx)(sv,{children:(0,z.jsxs)($v,{children:[(0,z.jsx)(ey,{asChild:!0,children:(0,z.jsxs)(lv,{size:`lg`,className:`data-[state=open]:bg-sidebar-accent`,children:[(0,z.jsx)(yy,{src:t,fallback:a}),(0,z.jsxs)(`div`,{className:`grid min-w-0 flex-1 text-start text-sm leading-tight`,children:[(0,z.jsx)(`span`,{className:`truncate font-medium`,children:e??Q(i,`common.signedIn`)}),(0,z.jsx)(`span`,{className:`truncate text-xs text-muted-foreground`,children:n??Q(i,`common.signedIn`)})]}),(0,z.jsx)(Mt,{className:`ms-auto`,"aria-hidden":!0})]})}),(0,z.jsxs)(ty,{align:`end`,side:r?`bottom`:`right`,sideOffset:4,className:`w-(--radix-dropdown-menu-trigger-width) min-w-56`,children:[(0,z.jsxs)(ry,{className:`flex items-center gap-2`,children:[(0,z.jsx)(yy,{src:t,fallback:a}),(0,z.jsxs)(`div`,{className:`grid min-w-0 flex-1 leading-tight`,children:[(0,z.jsx)(`span`,{className:`truncate font-medium`,children:e??Q(i,`common.signedIn`)}),(0,z.jsx)(`span`,{className:`truncate text-xs text-muted-foreground`,children:n??Q(i,`common.signedIn`)})]})]}),(0,z.jsx)(iy,{}),(0,z.jsx)(ny,{asChild:!0,children:(0,z.jsxs)(`a`,{href:`/admin/preferences`,children:[(0,z.jsx)(wn,{"aria-hidden":!0}),Q(i,`preferences.page.open`)]})}),(0,z.jsxs)(ny,{variant:`destructive`,onSelect:()=>_y(),children:[(0,z.jsx)(cn,{"aria-hidden":!0}),Q(i,`common.signOut`)]})]})]})})})}function yy({src:e,fallback:t}){return(0,z.jsxs)(Gv,{className:`size-8 rounded-lg`,children:[e?(0,z.jsx)(Kv,{src:e,alt:``}):null,(0,z.jsx)(qv,{className:`rounded-lg`,children:t})]})}function by({brand:e,groups:t,pathname:n,search:r,user:i}){let{direction:a,language:o}=Iv();return(0,z.jsxs)(Z_,{side:a===`rtl`?`right`:`left`,collapsible:`icon`,dir:a,mobileTitle:Q(o,`common.mobileSidebar`),mobileDescription:Q(o,`common.mobileSidebarDescription`),closeLabel:Q(o,`common.close`),children:[(0,z.jsx)(tv,{className:`h-14 justify-center border-b border-sidebar-border px-2 py-0`,children:(0,z.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1`,children:[(0,z.jsx)(Yv,{brand:e}),(0,z.jsx)(Q_,{className:`shrink-0 group-data-[collapsible=icon]:mx-auto`,"aria-label":Q(o,`common.toggleSidebar`)})]})}),(0,z.jsx)(rv,{children:t.map((e,t)=>(0,z.jsx)(oy,{group:e,pathname:n,search:r},e.title??`g-${t}`))}),(0,z.jsx)(nv,{className:`border-t border-sidebar-border`,children:(0,z.jsx)(vy,{login:i.login,image:i.image,role:i.role})}),(0,z.jsx)($_,{"aria-label":Q(o,`common.toggleSidebar`)})]})}function xy({className:e,...t}){return(0,z.jsx)(`nav`,{"data-slot":`breadcrumb`,className:Y(e),...t})}function Sy({className:e,...t}){return(0,z.jsx)(`ol`,{"data-slot":`breadcrumb-list`,className:Y(`flex flex-wrap items-center gap-1.5 text-sm wrap-break-word text-muted-foreground`,e),...t})}function Cy({className:e,...t}){return(0,z.jsx)(`li`,{"data-slot":`breadcrumb-item`,className:Y(`inline-flex items-center gap-1`,e),...t})}function wy({asChild:e,className:t,...n}){let r=e?tr:`a`;return(0,z.jsx)(r,{"data-slot":`breadcrumb-link`,className:Y(`transition-colors hover:text-foreground`,t),...n})}function Ty({className:e,...t}){return(0,z.jsx)(`span`,{"data-slot":`breadcrumb-page`,role:`link`,"aria-disabled":`true`,"aria-current":`page`,className:Y(`font-normal text-foreground`,e),...t})}function Ey({children:e,className:t,...n}){return(0,z.jsx)(`li`,{"data-slot":`breadcrumb-separator`,role:`presentation`,"aria-hidden":`true`,className:Y(`[&>svg]:size-3.5`,t),...n,children:e??(0,z.jsx)(At,{className:`rtl:rotate-180`})})}function Dy({compact:e=!1}){let{language:t,setLanguage:n}=Iv(),r=jv.find(e=>e.value===t)??jv[0];return(0,z.jsxs)($v,{children:[(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:(0,z.jsx)(`span`,{className:`inline-flex`,children:(0,z.jsx)(ey,{asChild:!0,children:(0,z.jsxs)(X,{type:`button`,variant:`ghost`,size:e?`icon-sm`:`sm`,"aria-label":Q(t,`preferences.language`),children:[(0,z.jsx)($t,{"aria-hidden":!0}),(0,z.jsx)(`span`,{className:e?`sr-only`:`hidden text-xs font-medium sm:inline`,children:r.nativeLabel})]})})})}),(0,z.jsx)(V_,{children:Q(t,`preferences.language`)})]}),(0,z.jsxs)(ty,{align:`end`,className:`max-h-[min(28rem,80vh)] w-52 overflow-y-auto`,children:[(0,z.jsx)(ry,{children:Q(t,`preferences.language`)}),jv.map(e=>(0,z.jsxs)(ny,{onSelect:()=>n(e.value),className:`justify-between`,children:[(0,z.jsx)(`span`,{children:e.nativeLabel}),(0,z.jsx)(Dt,{"aria-hidden":!0,className:Y(`size-4 text-primary`,e.value===t?`opacity-100`:`opacity-0`)})]},e.value))]})]})}function Oy({compact:e=!1}){let{language:t,theme:n,setTheme:r}=Iv(),i=ky(t).find(e=>e.value===n),a=i?.icon??un;return(0,z.jsxs)($v,{children:[(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:(0,z.jsx)(`span`,{className:`inline-flex`,children:(0,z.jsx)(ey,{asChild:!0,children:(0,z.jsxs)(X,{type:`button`,variant:`ghost`,size:e?`icon-sm`:`sm`,"aria-label":Q(t,`preferences.appearance`),children:[(0,z.jsx)(a,{"aria-hidden":!0}),(0,z.jsx)(`span`,{className:e?`sr-only`:`hidden text-xs font-medium sm:inline`,children:i?.label??Q(t,`preferences.system`)})]})})})}),(0,z.jsx)(V_,{children:Q(t,`preferences.appearance`)})]}),(0,z.jsxs)(ty,{align:`end`,className:`w-44`,children:[(0,z.jsx)(ry,{children:Q(t,`preferences.appearance`)}),ky(t).map(e=>{let t=e.icon;return(0,z.jsxs)(ny,{onSelect:()=>r(e.value),className:`justify-between`,children:[(0,z.jsxs)(`span`,{className:`flex items-center gap-2`,children:[(0,z.jsx)(t,{className:`size-4`,"aria-hidden":!0}),e.label]}),(0,z.jsx)(Dt,{"aria-hidden":!0,className:Y(`size-4 text-primary`,e.value===n?`opacity-100`:`opacity-0`)})]},e.value)})]})]})}function ky(e){return[{value:`light`,label:Q(e,`preferences.light`),icon:En},{value:`dark`,label:Q(e,`preferences.dark`),icon:dn},{value:`system`,label:Q(e,`preferences.system`),icon:un}]}function Ay({className:e,site:t,publicUrl:n,pageTitle:r}){let{pathname:i}=Av(),{language:a}=Iv(),o=r??jy(i,a);return(0,z.jsxs)(`header`,{"data-slot":`app-header`,className:Y(`flex h-14 shrink-0 items-center gap-2 border-b px-4`,e),children:[(0,z.jsx)(Q_,{className:`-ms-1 md:hidden`,"aria-label":Q(a,`common.toggleSidebar`)}),(0,z.jsx)(xy,{className:`min-w-0`,"aria-label":Q(a,`common.breadcrumb`),children:(0,z.jsxs)(Sy,{className:`flex-nowrap`,children:[(0,z.jsx)(Cy,{className:`hidden sm:block`,children:(0,z.jsx)(wy,{href:`/admin`,children:t?.title??Q(a,`admin.consoleTitle`)})}),o?(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(Ey,{className:`hidden sm:block`}),(0,z.jsx)(Cy,{className:`min-w-0`,children:(0,z.jsx)(Ty,{className:`truncate`,children:o})})]}):null]})}),(0,z.jsxs)(`div`,{className:`ms-auto flex shrink-0 items-center gap-1`,children:[n?(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:(0,z.jsx)(X,{asChild:!0,variant:`ghost`,size:`icon-sm`,children:(0,z.jsx)(`a`,{href:n,target:`_blank`,rel:`noreferrer`,"aria-label":Q(a,`common.viewSite`),children:(0,z.jsx)(Vt,{"aria-hidden":!0})})})}),(0,z.jsx)(V_,{children:Q(a,`common.viewSite`)})]}):null,(0,z.jsx)(Dy,{compact:!0}),(0,z.jsx)(Oy,{compact:!0})]})]})}function jy(e,t){if(e===`/admin`||e===`/admin/`)return null;let n=e.match(/^\/admin\/c\/([^/]+)/);if(n)return vv(decodeURIComponent(n[1]));let r=e.split(`/`).filter(Boolean),i=decodeURIComponent(r[r.length-1]??``);return e===`/admin/media`?Q(t,`nav.media`):e===`/admin/settings`?Q(t,`nav.settings`):e===`/admin/staff`?Q(t,`nav.staff`):e===`/admin/members`?Q(t,`nav.members`):i?vv(i):null}var My=`content`;function Ny({className:e}){let{language:t}=Iv();return(0,z.jsx)(`a`,{href:`#${My}`,className:Y(`fixed inset-inline-start-3 top-3 z-[999]`,`-translate-y-52 rounded-md bg-primary px-3 py-2 text-sm font-medium`,`text-primary-foreground shadow`,`focus-visible:translate-y-0 transition-transform`,`outline-2 outline-offset-2 outline-ring/40`,e),children:Q(t,`common.skipToMain`)})}function Py({className:e,children:t}){return(0,z.jsx)(`div`,{id:My,className:Y(`@container/content`,`mx-auto w-full max-w-[1440px] flex-1 px-4 py-6 sm:px-6`,e),children:t})}function Fy(e,t){switch(t){case`draft`:return Q(e,`status.draft`);case`published`:return Q(e,`status.published`);case`archived`:return Q(e,`status.archived`)}}function Iy({className:e,size:t=`default`,...n}){return(0,z.jsx)(`div`,{"data-slot":`card`,"data-size":t,className:Y(`group/card flex flex-col gap-(--card-spacing) overflow-hidden rounded-xl bg-card py-(--card-spacing) text-sm text-card-foreground ring-1 ring-foreground/10 [--card-spacing:--spacing(4)] has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:[--card-spacing:--spacing(3)] data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl`,e),...n})}function Ly({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`card-header`,className:Y(`group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-(--card-spacing) has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-(--card-spacing)`,e),...t})}function Ry({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`card-title`,className:Y(`font-heading text-base leading-snug font-medium group-data-[size=sm]/card:text-sm`,e),...t})}function zy({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`card-description`,className:Y(`text-sm text-muted-foreground`,e),...t})}function By({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`card-content`,className:Y(`px-(--card-spacing)`,e),...t})}var Vy=R.createContext(null);function Hy({eyebrow:e,title:t,description:n,actions:r}){return(0,z.jsxs)(`div`,{className:`mb-6 flex flex-wrap items-end justify-between gap-4`,children:[(0,z.jsxs)(`div`,{className:`min-w-0`,children:[e?(0,z.jsx)(`div`,{className:`mb-1 text-sm text-muted-foreground`,children:e}):null,(0,z.jsx)(`h1`,{className:`text-2xl font-semibold tracking-tight`,children:t}),n?(0,z.jsx)(`div`,{className:`mt-1 max-w-3xl text-sm text-muted-foreground`,children:n}):null]}),r?(0,z.jsx)(`div`,{className:`flex shrink-0 items-center gap-2`,children:r}):null]})}function Uy({id:e,className:t,children:n}){return(0,z.jsx)(Iy,{id:e,className:Y(`p-5`,t),children:n})}function Wy({status:e,children:t}){let n=R.useContext(Vy);return n?(0,mr.createPortal)((0,z.jsxs)(`div`,{"data-slot":`form-action-bar`,className:`flex w-full flex-wrap items-center justify-between gap-3`,children:[(0,z.jsx)(`div`,{className:`min-h-5 min-w-0 text-sm text-muted-foreground`,"aria-live":`polite`,children:e}),(0,z.jsx)(`div`,{className:`ms-auto flex shrink-0 items-center gap-2`,children:t})]}),n):(0,z.jsx)(z.Fragment,{})}function Gy({icon:e=Nt,title:t,description:n,action:r}){return(0,z.jsxs)(`div`,{className:`rounded-lg border border-dashed border-border p-8 text-center`,children:[(0,z.jsx)(`div`,{className:`mx-auto mb-3 inline-flex size-10 items-center justify-center rounded-full bg-accent text-accent-foreground`,children:(0,z.jsx)(e,{className:`size-5`,"aria-hidden":!0})}),(0,z.jsx)(`h2`,{className:`text-lg`,children:t}),n?(0,z.jsx)(`p`,{className:`mx-auto mt-1 max-w-xl text-sm text-muted-foreground`,children:n}):null,r?(0,z.jsx)(`div`,{className:`mt-4`,children:r}):null]})}function Ky({error:e}){let{language:t}=Iv();if(Jy(e))return null;let n=e instanceof Error?e.message:Q(t,`common.unknownError`);return(0,z.jsxs)(`div`,{className:`rounded-lg border border-destructive/30 bg-destructive/5 p-4 text-sm text-destructive`,children:[Q(t,`common.failedToLoad`),`: `,n]})}function qy({error:e}){let{language:t}=Iv();if(Jy(e))return null;let n=e instanceof Error?e.message:String(e);return(0,z.jsxs)(`div`,{className:`rounded-lg border border-destructive/30 bg-destructive/5 p-4 text-sm text-destructive`,children:[(0,z.jsx)(`p`,{children:Q(t,`ops.error.executionFailed`)}),(0,z.jsxs)(`details`,{className:`group mt-2`,children:[(0,z.jsx)(`summary`,{className:`inline-flex cursor-pointer list-none items-center rounded-md border border-destructive/30 bg-card/40 px-2.5 py-1 text-xs font-semibold text-destructive/80 transition hover:bg-destructive/10`,children:Q(t,`ops.error.detailsLabel`)}),(0,z.jsx)(`p`,{className:`mt-2 max-w-3xl whitespace-pre-wrap break-words rounded-md border border-destructive/20 bg-card/30 p-3 font-mono text-xs leading-relaxed text-destructive/90`,children:n})]})]})}function Jy(e){let t=e instanceof mv&&e.status===401;return R.useEffect(()=>{if(!t||typeof window>`u`)return;let e=window.location.pathname+window.location.search;window.location.href=`/admin/sign-in?return=${encodeURIComponent(e)}`},[t]),t}function Yy({description:e,summaryLabel:t,collapsedIntro:n}){return Xy(e)?(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsx)(`p`,{children:n}),(0,z.jsxs)(`details`,{className:`group`,children:[(0,z.jsx)(`summary`,{className:`inline-flex cursor-pointer list-none items-center rounded-md border border-border bg-card/70 px-2.5 py-1 text-xs font-semibold text-foreground/70 transition hover:bg-accent hover:text-accent-foreground`,children:t}),(0,z.jsx)(`p`,{className:`mt-2 max-w-3xl rounded-md border border-border bg-card/55 p-3 text-xs leading-relaxed text-muted-foreground`,children:e})]})]}):(0,z.jsx)(z.Fragment,{children:e})}function Xy(e){return e.length>180||e.includes("`")}function Zy({label:e,value:t,href:n}){let{language:r}=Iv(),[i,a]=R.useState(!1);async function o(){try{await navigator.clipboard.writeText(t),a(!0),window.setTimeout(()=>a(!1),1400)}catch{a(!1)}}return(0,z.jsxs)(`div`,{className:`rounded-lg border bg-muted/30 p-3`,children:[(0,z.jsxs)(`div`,{className:`mb-1 flex items-center justify-between gap-3`,children:[(0,z.jsx)(`span`,{className:`text-xs font-medium text-muted-foreground`,children:e}),(0,z.jsxs)(`div`,{className:`flex items-center gap-1`,children:[n?(0,z.jsx)(X,{asChild:!0,variant:`ghost`,size:`icon`,className:`size-7`,children:(0,z.jsx)(`a`,{href:n,target:`_blank`,rel:`noreferrer`,"aria-label":`${Q(r,`common.open`)} ${e}`,children:(0,z.jsx)(Vt,{className:`size-3.5`,"aria-hidden":!0})})}):null,(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon`,className:`size-7`,onClick:o,"aria-label":`${Q(r,`common.copy`)} ${e}`,children:i?(0,z.jsx)(Dt,{className:`size-3.5 text-[color:var(--success)]`,"aria-hidden":!0}):(0,z.jsx)(Lt,{className:`size-3.5`,"aria-hidden":!0})})]})]}),(0,z.jsx)(`code`,{className:`block truncate font-mono text-xs text-foreground`,children:t})]})}function Qy({children:e}){let[t,n]=R.useState(null),{pathname:r,search:i}=Av(),{language:a}=Iv(),o=st({queryKey:[`me`],queryFn:()=>Z.get(`/me`),retry:!1}),s=st({queryKey:[`collections`],queryFn:async()=>(await Z.get(`/collections`)).collections}),c=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}),l=st(Sv());R.useEffect(()=>{if(c.data?.icons.length){document.querySelectorAll(`link[rel~='icon']`).forEach(e=>e.remove());for(let e of c.data.icons){let t=document.createElement(`link`);t.rel=`icon`,t.href=e.src,e.mimeType&&(t.type=e.mimeType),e.sizes&&t.sizes.add(...e.sizes),e.theme&&(t.media=`(prefers-color-scheme: ${e.theme})`),document.head.append(t)}}},[c.data?.icons]);let u=R.useMemo(()=>({title:c.data?.brand??Q(a,`admin.consoleTitle`),href:`/admin`,image:$y(c.data?.icons)}),[a,c.data]),d=c.data?.canonicalLocale??null,f=R.useMemo(()=>eb(s.data??[],l.data??[],a,d,o.data?.role??null),[s.data,l.data,a,d,o.data?.role]),p=r.match(/^\/admin\/c\/([^/]+)/)?.[1],m=r.match(/^\/admin\/views\/([^/]+)/)?.[1],h=p?s.data?.find(e=>e.name===decodeURIComponent(p)):l.data?.find(e=>e.name===decodeURIComponent(m??``)),g=h?_v(h.title,a,d)??vv(h.name):void 0;return(0,z.jsx)(Vy.Provider,{value:t,children:(0,z.jsxs)(X_,{className:`h-svh min-h-0 overflow-hidden`,children:[(0,z.jsx)(Ny,{}),(0,z.jsx)(by,{brand:u,groups:f,pathname:r,search:i,user:{login:o.data?.login??null,image:o.data?.image??null,role:o.data?.role??null}}),(0,z.jsxs)(ev,{className:`min-h-0 overflow-hidden`,children:[(0,z.jsx)(Ay,{className:`absolute inset-x-0 top-0 z-30`,site:u,publicUrl:c.data?.publicUrl,pageTitle:g}),(0,z.jsx)(Py,{className:`min-h-0 overflow-y-auto overscroll-contain pt-20 pb-20`,children:e}),(0,z.jsxs)(`footer`,{"data-slot":`status-bar`,className:`absolute inset-x-0 bottom-0 z-30 flex min-h-16 items-center border-t px-4 py-3 sm:px-6`,children:[(0,z.jsx)(`div`,{ref:n,"data-slot":`status-bar-action-host`,className:`contents`}),(0,z.jsx)(`div`,{"data-slot":`status-bar-meta`,className:`ms-auto flex items-center justify-end`,children:(0,z.jsxs)(`a`,{href:`https://www.npmjs.com/package/@aotter/mantle/v/0.1.0-alpha.8`,target:`_blank`,rel:`noreferrer`,className:`rounded-md px-2 py-1 font-mono text-xs text-muted-foreground transition-colors hover:bg-accent hover:text-accent-foreground`,children:[`@aotter/mantle-`,`0.1.0-alpha.8`]})})]})]})]})})}function $y(e){return e?.find(e=>e.sizes?.includes(`64x64`)&&!e.theme)?.src??e?.find(e=>!e.theme)?.src??e?.[0]?.src}function eb(e,t,n,r,i){let a=e.filter(e=>!e.parent),o=a.filter(e=>e.lifecycle!==`operational`),s=a.filter(e=>e.lifecycle===`operational`),c={items:[{title:Q(n,`nav.home`),url:`/admin`,icon:qt}]},l={title:Q(n,`nav.content`),items:o.map(e=>tb(e,n,r))},u=s.length>0?{title:Q(n,`nav.operations`),items:s.map(e=>tb(e,n,r))}:null,d=t.length>0?{title:Q(n,`nav.reports`),items:t.map(e=>({title:_v(e.title,n,r)??vv(e.name),icon:Et,url:`/admin/views/${encodeURIComponent(e.name)}`}))}:null,f={title:Q(n,`nav.more`),items:[...i===`owner`||i===`editor`?[{title:Q(n,`nav.media`),url:`/admin/media`,icon:Xt},{title:Q(n,`nav.members`),url:`/admin/members`,icon:It}]:[],...i===`owner`?[{title:Q(n,`nav.settings`),url:`/admin/settings`,icon:wn},{title:Q(n,`nav.staff`),url:`/admin/staff`,icon:Rn}]:[]]};return[c,l,...u?[u]:[],...d?[d]:[],...f.items.length>0?[f]:[]]}function tb(e,t,n){let r=e.localized||e.hasTranslations,i={title:_v(e.title,t,n)??vv(e.name),icon:Wt,marker:r?Gt:void 0,markerLabel:r?Q(t,`nav.localizedContent`):void 0};if(e.lifecycle===`operational`&&e.filter)return{...i,items:[{title:Q(t,`collection.filter.all`),url:`/admin/c/${e.name}`},...e.filter.values.map(t=>({title:vv(t),url:`/admin/c/${e.name}?filter_field=${encodeURIComponent(e.filter.field)}&filter_value=${encodeURIComponent(t)}`}))]};let a=nb(e);return a.length===0?{...i,url:`/admin/c/${e.name}`}:{...i,items:[{title:Q(t,`collection.filter.all`),url:`/admin/c/${e.name}`},...a.map(n=>({title:Fy(t,n),url:`/admin/c/${e.name}?status=${n}`}))]}}function nb(e){return e.lifecycle===`operational`?[]:wv}function rb({children:e,wide:t=!1}){return(0,z.jsx)(`main`,{className:`flex min-h-svh items-center justify-center p-6`,children:(0,z.jsx)(Iy,{className:t?`w-full max-w-md`:`w-full max-w-sm`,children:e})})}function ib(){return(0,z.jsxs)(rb,{children:[(0,z.jsx)(Ly,{children:(0,z.jsx)(L_,{className:`h-4 w-24`})}),(0,z.jsxs)(By,{className:`space-y-2`,"aria-busy":`true`,children:[(0,z.jsx)(L_,{className:`h-3 w-full`}),(0,z.jsx)(L_,{className:`h-3 w-2/3`})]})]})}function ab({error:e}){let{language:t}=Iv(),n=e instanceof Error?e.message:Q(t,`common.unknownError`);return(0,z.jsx)(rb,{children:(0,z.jsxs)(Ly,{className:`text-center`,children:[(0,z.jsx)(Ry,{className:`text-xl`,children:(0,z.jsx)(`h1`,{children:Q(t,`auth.error.title`)})}),(0,z.jsx)(zy,{role:`alert`,children:n})]})})}function ob({login:e}){let{language:t}=Iv();return(0,z.jsxs)(rb,{wide:!0,children:[(0,z.jsxs)(Ly,{className:`text-center`,children:[(0,z.jsx)(`div`,{className:`mx-auto mb-3 inline-flex size-10 items-center justify-center rounded-full bg-destructive/10 text-destructive`,children:(0,z.jsx)(Mn,{className:`size-5`,"aria-hidden":!0})}),(0,z.jsx)(Ry,{className:`text-xl`,children:(0,z.jsx)(`h1`,{children:Q(t,`auth.accessDenied.title`)})}),e?(0,z.jsxs)(zy,{className:`font-medium text-foreground`,children:[`GitHub: `,e]}):null]}),(0,z.jsxs)(By,{className:`text-center`,children:[(0,z.jsx)(`p`,{className:`mb-1 text-sm text-muted-foreground`,children:Q(t,`auth.accessDenied.noStaff`)}),(0,z.jsx)(`p`,{className:`mb-6 text-sm text-muted-foreground`,children:Q(t,`auth.accessDenied.askOwner`)}),(0,z.jsxs)(X,{variant:`outline`,className:`w-full`,onClick:_y,children:[(0,z.jsx)(cn,{className:`me-2 size-4`,"aria-hidden":!0}),Q(t,`common.signOut`)]})]})]})}var sb=`first:mt-0 mt-4`,cb=`first:mt-0 first:border-t-0 first:pt-0 mt-6 border-t border-border pt-4`;function lb(e){if(!e?.startsWith(`/`))return`/admin`;try{let t=`https://mantle.invalid`,n=new URL(e,t);return n.origin===t?`${n.pathname}${n.search}${n.hash}`:`/admin`}catch{return`/admin`}}function ub(e){let t=new URLSearchParams(e);if(!t.has(`sig`))return;let n=new Set(t.getAll(`ba_param`));if(n.size===0)return;let r=new URLSearchParams;for(let[e,i]of t)(e===`sig`||e===`ba_param`||n.has(e))&&r.append(e,i);return r.toString()}function db({busy:e,children:t,disabled:n,...r}){return(0,z.jsxs)(X,{...r,disabled:e||n,"aria-busy":e||void 0,children:[e?(0,z.jsx)(on,{className:`animate-spin`,"aria-hidden":!0}):null,t]})}function fb(){let{language:e}=Iv(),t=lb(new URLSearchParams(window.location.search).get(`return`)),n=ub(window.location.search),r=st(xv());return(0,z.jsxs)(rb,{children:[(0,z.jsxs)(Ly,{children:[(0,z.jsx)(zy,{children:Q(e,`auth.signIn.eyebrow`)}),(0,z.jsx)(Ry,{className:`text-xl`,children:(0,z.jsx)(`h1`,{children:Q(e,`auth.signIn.title`)})})]}),(0,z.jsxs)(By,{children:[r.isError?(0,z.jsx)(`p`,{className:`mb-4 text-sm text-destructive`,role:`alert`,children:Q(e,`auth.signIn.methodsLoadFailed`)}):null,r.isLoading?(0,z.jsx)(L_,{className:`h-9 w-full`}):null,r.data?.length===0?(0,z.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:Q(e,`auth.signIn.noMethods`)}):null,r.data&&r.data.length>0?(0,z.jsx)(`div`,{children:r.data.map(e=>(0,z.jsx)(pb,{method:e,returnTo:t,oauthQuery:n},e.kind===`social`?`social:${e.provider}`:e.kind===`oauth`?`oauth:${e.providerId}`:e.kind))}):null]})]})}function pb({method:e,returnTo:t,oauthQuery:n}){switch(e.kind){case`social`:return(0,z.jsx)(hb,{endpoint:`/api/auth/sign-in/social`,body:{provider:e.provider,callbackURL:t,...n?{oauth_query:n}:{}},buttonKey:`auth.signIn.method.social.button`,displayName:mb[e.provider]??e.provider});case`oauth`:return(0,z.jsx)(hb,{endpoint:`/api/auth/sign-in/social`,body:{provider:e.providerId,callbackURL:t,...n?{oauth_query:n}:{}},buttonKey:`auth.signIn.method.oauth.button`,displayName:e.displayName??e.providerId});case`email-otp`:return(0,z.jsx)(gb,{returnTo:t,oauthQuery:n});case`magic-link`:return(0,z.jsx)(_b,{returnTo:t,oauthQuery:n});default:return(0,z.jsx)(vb,{kind:e.kind})}}var mb={github:`GitHub`,google:`Google`,apple:`Apple`,"microsoft-entra-id":`Microsoft`,facebook:`Facebook`,discord:`Discord`,twitter:`Twitter / X`,linkedin:`LinkedIn`,spotify:`Spotify`,twitch:`Twitch`,gitlab:`GitLab`,tiktok:`TikTok`,reddit:`Reddit`,kick:`Kick`,vk:`VK`,naver:`Naver`,kakao:`Kakao`,line:`LINE`,slack:`Slack`,atlassian:`Atlassian`,zoom:`Zoom`,notion:`Notion`,figma:`Figma`,linear:`Linear`,vercel:`Vercel`,paypal:`PayPal`,huggingface:`Hugging Face`,cognito:`Cognito`,salesforce:`Salesforce`,polar:`Polar`,railway:`Railway`,roblox:`Roblox`,paybin:`Paybin`,wechat:`WeChat`,dropbox:`Dropbox`};function hb({endpoint:e,body:t,buttonKey:n,displayName:r}){let{language:i}=Iv(),[a,o]=R.useState(!1),[s,c]=R.useState(null),l=async()=>{o(!0),c(null);try{let n=await fetch(e,{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/json`},body:JSON.stringify(t)});if(!n.ok)throw Error(`HTTP ${n.status}`);let r=await n.json();if(!r.url)throw Error(`Missing sign-in URL`);window.location.assign(r.url)}catch{c(Q(i,`auth.signIn.startFailed`)),o(!1)}};return(0,z.jsxs)(`div`,{className:sb,children:[(0,z.jsx)(db,{busy:a,onClick:()=>void l(),className:`w-full`,children:Q(i,n,{provider:r})}),s?(0,z.jsx)(`p`,{className:`mt-2 text-xs text-destructive`,role:`alert`,children:s}):null]})}function gb({returnTo:e,oauthQuery:t}){let{language:n}=Iv(),[r,i]=R.useState(`email`),[a,o]=R.useState(``),[s,c]=R.useState(``),[l,u]=R.useState(!1),[d,f]=R.useState(null),p=async e=>{u(!0),f(null);try{await e()}catch{f(Q(n,`auth.signIn.requestFailed`))}finally{u(!1)}};return(0,z.jsxs)(`div`,{className:cb,children:[(0,z.jsx)(`p`,{className:`mb-2 text-sm text-muted-foreground`,children:Q(n,`auth.signIn.method.email-otp.body`)}),r===`email`?(0,z.jsxs)(`form`,{onSubmit:e=>{e.preventDefault(),a&&p(async()=>{if(!(await fetch(`/api/auth/email-otp/send-verification-otp`,{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/json`},body:JSON.stringify({email:a,type:`sign-in`,...t?{oauth_query:t}:{}})})).ok){f(Q(n,`auth.signIn.method.email-otp.sendFailed`));return}i(`otp`)})},className:`space-y-2`,children:[(0,z.jsx)(`label`,{htmlFor:`signin-email`,className:`sr-only`,children:Q(n,`auth.signIn.method.email-otp.emailLabel`)}),(0,z.jsx)(O_,{id:`signin-email`,type:`email`,value:a,onChange:e=>o(e.currentTarget.value),placeholder:Q(n,`auth.signIn.method.email-otp.emailPlaceholder`),required:!0,autoComplete:`email`}),(0,z.jsx)(db,{type:`submit`,className:`w-full`,busy:l,disabled:!a,children:Q(n,`auth.signIn.method.email-otp.sendButton`)})]}):(0,z.jsxs)(`form`,{onSubmit:r=>{r.preventDefault(),s&&p(async()=>{let r=await fetch(`/api/auth/sign-in/email-otp`,{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/json`},body:JSON.stringify({email:a,otp:s,...t?{oauth_query:t}:{}})});if(!r.ok){f(Q(n,`auth.signIn.method.email-otp.verifyFailed`));return}let i=await r.json();window.location.assign(i.url??e)})},className:`space-y-2`,children:[(0,z.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:Q(n,`auth.signIn.method.email-otp.sentTo`,{email:a})}),(0,z.jsx)(`label`,{htmlFor:`signin-otp`,className:`sr-only`,children:Q(n,`auth.signIn.method.email-otp.otpLabel`)}),(0,z.jsx)(O_,{id:`signin-otp`,type:`text`,inputMode:`numeric`,autoComplete:`one-time-code`,value:s,onChange:e=>c(e.currentTarget.value),placeholder:Q(n,`auth.signIn.method.email-otp.otpPlaceholder`),required:!0}),(0,z.jsx)(db,{type:`submit`,className:`w-full`,busy:l,disabled:!s,children:Q(n,`auth.signIn.method.email-otp.verifyButton`)}),(0,z.jsx)(`button`,{type:`button`,onClick:()=>i(`email`),className:`text-xs text-muted-foreground underline-offset-2 hover:underline`,children:Q(n,`auth.signIn.method.email-otp.back`)})]}),d?(0,z.jsx)(`p`,{className:`mt-2 text-xs text-destructive`,role:`alert`,children:d}):null]})}function _b({returnTo:e,oauthQuery:t}){let{language:n}=Iv(),[r,i]=R.useState(``),[a,o]=R.useState(!1),[s,c]=R.useState(!1),[l,u]=R.useState(null),d=async e=>{o(!0),u(null);try{await e()}catch{u(Q(n,`auth.signIn.requestFailed`))}finally{o(!1)}};return(0,z.jsxs)(`div`,{className:cb,children:[(0,z.jsx)(`p`,{className:`mb-2 text-sm text-muted-foreground`,children:Q(n,`auth.signIn.method.magic-link.body`)}),s?(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsx)(`p`,{className:`text-sm text-foreground`,children:Q(n,`auth.signIn.method.magic-link.sentTo`,{email:r})}),(0,z.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:Q(n,`auth.signIn.method.magic-link.clickHint`)}),(0,z.jsx)(`button`,{type:`button`,onClick:()=>{c(!1),i(``)},className:`text-xs text-muted-foreground underline-offset-2 hover:underline`,children:Q(n,`auth.signIn.method.magic-link.anotherEmail`)})]}):(0,z.jsxs)(`form`,{onSubmit:i=>{i.preventDefault(),r&&d(async()=>{if(!(await fetch(`/api/auth/sign-in/magic-link`,{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/json`},body:JSON.stringify({email:r,callbackURL:e,...t?{oauth_query:t}:{}})})).ok){u(Q(n,`auth.signIn.method.magic-link.sendFailed`));return}c(!0)})},className:`space-y-2`,children:[(0,z.jsx)(`label`,{htmlFor:`signin-mlink-email`,className:`sr-only`,children:Q(n,`auth.signIn.method.magic-link.emailLabel`)}),(0,z.jsx)(O_,{id:`signin-mlink-email`,type:`email`,value:r,onChange:e=>i(e.currentTarget.value),placeholder:Q(n,`auth.signIn.method.magic-link.emailPlaceholder`),required:!0,autoComplete:`email`}),(0,z.jsx)(db,{type:`submit`,className:`w-full`,busy:a,disabled:!r,children:Q(n,`auth.signIn.method.magic-link.sendButton`)})]}),l?(0,z.jsx)(`p`,{className:`mt-2 text-xs text-destructive`,role:`alert`,children:l}):null]})}function vb({kind:e}){let{language:t}=Iv();return(0,z.jsx)(`p`,{className:`mt-4 text-xs text-muted-foreground`,children:Q(t,`auth.signIn.unknownMethod`,{kind:e})})}var yb=qn(`group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pe-1.5 has-data-[icon=inline-start]:ps-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!`,{variants:{variant:{default:`bg-primary text-primary-foreground [a]:hover:bg-primary/80`,secondary:`bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80`,destructive:`bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20`,outline:`border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground`,ghost:`hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50`,link:`text-primary underline-offset-4 hover:underline`}},defaultVariants:{variant:`default`}});function bb({className:e,variant:t=`default`,asChild:n=!1,...r}){let i=n?tr:`span`;return(0,z.jsx)(i,{"data-slot":`badge`,"data-variant":t,className:Y(yb({variant:t}),e),...r})}var xb=`https://claude.ai/customize/connectors?modal=add-custom-connector`,Sb=`https://claude.ai/new`;function Cb(){let{language:e}=Iv(),t=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}),n=st({queryKey:[`collections`],queryFn:async()=>(await Z.get(`/collections`)).collections}),r=(n.data??[]).filter(e=>!e.parent),i=[{title:Q(e,`nav.content`),items:r.filter(e=>e.lifecycle!==`operational`)},{title:Q(e,`nav.operations`),items:r.filter(e=>e.lifecycle===`operational`)}].filter(e=>e.items.length>0),a=t.data,o=a?.canonicalLocale??null;return(0,z.jsxs)(`div`,{className:`space-y-6`,children:[(0,z.jsx)(Hy,{eyebrow:Q(e,`console.eyebrow`),title:a?.brand??Q(e,`admin.consoleTitle`),description:a?Q(e,`console.description`,{title:a.title}):Q(e,`console.descriptionFallback`),actions:a?.publicUrl?(0,z.jsx)(X,{asChild:!0,variant:`outline`,children:(0,z.jsxs)(`a`,{href:a.publicUrl,target:`_blank`,rel:`noreferrer`,children:[(0,z.jsx)(Gt,{className:`size-4`,"aria-hidden":!0}),Q(e,`common.viewSite`)]})}):null}),t.isLoading?(0,z.jsx)(L_,{className:`h-72 w-full`}):t.isError?(0,z.jsx)(Ky,{error:t.error}):a?(0,z.jsxs)(Uy,{className:`overflow-hidden p-0`,children:[(0,z.jsxs)(`div`,{className:`flex flex-wrap items-start justify-between gap-4 border-b border-border/70 p-5`,children:[(0,z.jsxs)(`div`,{className:`flex items-start gap-3`,children:[(0,z.jsx)(`div`,{className:`rounded-xl bg-primary/15 p-2 text-primary`,children:(0,z.jsx)(wt,{className:`size-5`,"aria-hidden":!0})}),(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h2`,{className:`text-lg`,children:Q(e,`console.connector.title`)}),(0,z.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:Q(e,`console.connector.body`)})]})]}),(0,z.jsxs)(`div`,{className:`flex gap-2`,children:[(0,z.jsx)(bb,{children:`Claude`}),(0,z.jsx)(bb,{variant:`secondary`,children:`MCP`})]})]}),(0,z.jsxs)(`div`,{className:`grid divide-y divide-border/70 md:grid-cols-3 md:divide-x md:divide-y-0`,children:[(0,z.jsxs)(`div`,{className:`flex min-w-0 flex-col gap-4 p-5`,children:[(0,z.jsx)(wb,{children:`1`}),(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h3`,{children:Q(e,`console.connector.step1.title`)}),(0,z.jsx)(`p`,{className:`mt-1 text-sm text-muted-foreground`,children:Q(e,`console.connector.step1.body`)})]}),(0,z.jsx)(`div`,{className:`mt-auto`,children:(0,z.jsx)(Zy,{label:Q(e,`console.connector.step1.label`),value:a.mcpUrl})})]}),(0,z.jsxs)(`div`,{className:`flex min-w-0 flex-col gap-4 p-5`,children:[(0,z.jsx)(wb,{children:`2`}),(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h3`,{children:Q(e,`console.connector.step2.title`)}),(0,z.jsx)(`p`,{className:`mt-1 text-sm text-muted-foreground`,children:Q(e,`console.connector.step2.body`)})]}),(0,z.jsx)(`div`,{className:`mt-auto`,children:(0,z.jsx)(X,{asChild:!0,variant:`outline`,children:(0,z.jsxs)(`a`,{href:xb,target:`_blank`,rel:`noreferrer`,children:[(0,z.jsx)(Vt,{className:`size-4`,"aria-hidden":!0}),Q(e,`console.connector.step2.action`)]})})})]}),(0,z.jsxs)(`div`,{className:`flex min-w-0 flex-col gap-4 p-5`,children:[(0,z.jsx)(wb,{children:`3`}),(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h3`,{children:Q(e,`console.connector.step3.title`)}),(0,z.jsx)(`p`,{className:`mt-1 text-sm text-muted-foreground`,children:Q(e,`console.connector.step3.body`)})]}),(0,z.jsx)(`div`,{className:`mt-auto`,children:(0,z.jsx)(X,{asChild:!0,children:(0,z.jsxs)(`a`,{href:Sb,target:`_blank`,rel:`noreferrer`,children:[Q(e,`console.connector.step3.action`),(0,z.jsx)(Vt,{className:`size-4`,"aria-hidden":!0})]})})})]})]})]}):null,(0,z.jsxs)(`section`,{"aria-labelledby":`collections-heading`,children:[(0,z.jsx)(`h2`,{id:`collections-heading`,className:`mb-4 text-xl font-semibold`,children:Q(e,`console.collections.title`)}),n.isLoading&&(0,z.jsx)(`div`,{className:`space-y-2`,children:[0,1,2].map(e=>(0,z.jsx)(L_,{className:`h-16 w-full`},e))}),n.isError&&(0,z.jsx)(Ky,{error:n.error}),n.data&&r.length===0&&(0,z.jsx)(Gy,{icon:Rt,title:Q(e,`console.collections.emptyTitle`),description:Q(e,`console.collections.emptyBody`)}),r.length>0&&(0,z.jsx)(Uy,{className:`overflow-hidden p-0`,children:i.map((t,n)=>(0,z.jsxs)(`div`,{className:n>0?`border-t`:void 0,children:[(0,z.jsx)(`h3`,{className:`border-b bg-muted/30 px-4 py-2 text-xs font-medium text-muted-foreground`,children:t.title}),(0,z.jsx)(`div`,{className:`divide-y`,children:t.items.map(t=>{let n=_v(t.title,e,o)??vv(t.name),r=_v(t.description,e,o),i=n.toLocaleLowerCase()!==vv(t.name).toLocaleLowerCase();return(0,z.jsxs)(`a`,{href:`/admin/c/${encodeURIComponent(t.name)}`,className:`grid min-h-16 grid-cols-[minmax(0,1fr)_auto] items-center gap-3 px-4 py-3 transition-colors hover:bg-muted/50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset`,children:[(0,z.jsxs)(`div`,{className:`min-w-0`,children:[(0,z.jsxs)(`div`,{className:`flex min-w-0 flex-wrap items-baseline gap-x-2`,children:[(0,z.jsx)(`span`,{className:`truncate font-medium`,children:n}),i?(0,z.jsx)(`span`,{className:`font-mono text-xs text-muted-foreground`,children:t.name}):null]}),r?(0,z.jsx)(`p`,{className:`truncate text-sm text-muted-foreground`,children:r}):null]}),(0,z.jsx)(`div`,{className:`flex shrink-0 items-center gap-2`,children:(0,z.jsx)(At,{className:`size-4 text-muted-foreground`,"aria-hidden":!0})})]},t.name)})})]},t.title))})]})]})}function wb({children:e}){return(0,z.jsx)(`span`,{className:`inline-flex size-6 items-center justify-center rounded-full bg-foreground/10 text-xs font-semibold text-foreground`,children:e})}function Tb({className:e,...t}){return(0,z.jsx)(Cc,{"data-slot":`checkbox`,className:Y(`peer relative flex size-4 shrink-0 items-center justify-center rounded-[4px] border border-input transition-colors outline-none group-has-disabled/field:opacity-50 after:absolute after:-inset-x-3 after:-inset-y-2 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 aria-invalid:aria-checked:border-primary dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 data-checked:border-primary data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary`,e),...t,children:(0,z.jsx)(Tc,{"data-slot":`checkbox-indicator`,className:`grid place-content-center text-current transition-none [&>svg]:size-3.5`,children:(0,z.jsx)(Dt,{})})})}function Eb({className:e,...t}){return(0,z.jsx)(`nav`,{role:`navigation`,"data-slot":`pagination`,className:Y(`mx-auto flex w-full justify-center`,e),...t})}function Db({className:e,...t}){return(0,z.jsx)(`ul`,{"data-slot":`pagination-content`,className:Y(`flex items-center gap-0.5`,e),...t})}function Ob({...e}){return(0,z.jsx)(`li`,{"data-slot":`pagination-item`,...e})}function kb({className:e,isActive:t,size:n=`icon`,...r}){return(0,z.jsx)(X,{asChild:!0,variant:t?`outline`:`ghost`,size:n,className:Y(e),children:(0,z.jsx)(`a`,{"aria-current":t?`page`:void 0,"data-slot":`pagination-link`,"data-active":t,...r})})}function Ab({className:e,text:t,...n}){return(0,z.jsxs)(kb,{size:`default`,className:Y(`ps-1.5!`,e),...n,children:[(0,z.jsx)(kt,{"data-icon":`inline-start`,className:`rtl:rotate-180`}),(0,z.jsx)(`span`,{className:`hidden sm:block`,children:t})]})}function jb({className:e,text:t,...n}){return(0,z.jsxs)(kb,{size:`default`,className:Y(`pe-1.5!`,e),...n,children:[(0,z.jsx)(`span`,{className:`hidden sm:block`,children:t}),(0,z.jsx)(At,{"data-icon":`inline-end`,className:`rtl:rotate-180`})]})}function Mb({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`table-container`,className:`relative w-full overflow-x-auto`,children:(0,z.jsx)(`table`,{"data-slot":`table`,className:Y(`w-full caption-bottom text-sm`,e),...t})})}function Nb({className:e,...t}){return(0,z.jsx)(`thead`,{"data-slot":`table-header`,className:Y(`[&_tr]:border-b`,e),...t})}function Pb({className:e,...t}){return(0,z.jsx)(`tbody`,{"data-slot":`table-body`,className:Y(`[&_tr:last-child]:border-0`,e),...t})}function Fb({className:e,...t}){return(0,z.jsx)(`tr`,{"data-slot":`table-row`,className:Y(`border-b transition-colors hover:bg-muted/50 has-aria-expanded:bg-muted/50 data-[state=selected]:bg-muted`,e),...t})}function Ib({className:e,...t}){return(0,z.jsx)(`th`,{"data-slot":`table-head`,className:Y(`h-10 px-2 text-start align-middle font-medium whitespace-nowrap text-foreground [&:has([role=checkbox])]:pe-0`,e),...t})}function Lb({className:e,...t}){return(0,z.jsx)(`td`,{"data-slot":`table-cell`,className:Y(`p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pe-0`,e),...t})}function Rb({...e}){return(0,z.jsx)(zs,{"data-slot":`alert-dialog`,...e})}function zb({...e}){return(0,z.jsx)(Bs,{"data-slot":`alert-dialog-portal`,...e})}function Bb({className:e,...t}){return(0,z.jsx)(Vs,{"data-slot":`alert-dialog-overlay`,className:Y(`fixed inset-0 z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...t})}function Vb({className:e,size:t=`default`,...n}){return(0,z.jsxs)(zb,{children:[(0,z.jsx)(Bb,{}),(0,z.jsx)(Hs,{"data-slot":`alert-dialog-content`,"data-size":t,className:Y(`group/alert-dialog-content fixed top-1/2 start-1/2 z-50 grid w-full -translate-x-1/2 rtl:translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none data-[size=default]:max-w-xs data-[size=sm]:max-w-xs data-[size=default]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,e),...n})]})}function Hb({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`alert-dialog-header`,className:Y(`grid grid-rows-[auto_1fr] place-items-center gap-1.5 text-center has-data-[slot=alert-dialog-media]:grid-rows-[auto_auto_1fr] has-data-[slot=alert-dialog-media]:gap-x-4 sm:group-data-[size=default]/alert-dialog-content:place-items-start sm:group-data-[size=default]/alert-dialog-content:text-start sm:group-data-[size=default]/alert-dialog-content:has-data-[slot=alert-dialog-media]:grid-rows-[auto_1fr]`,e),...t})}function Ub({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`alert-dialog-footer`,className:Y(`-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/alert-dialog-content:grid group-data-[size=sm]/alert-dialog-content:grid-cols-2 sm:flex-row sm:justify-end`,e),...t})}function Wb({className:e,...t}){return(0,z.jsx)(Gs,{"data-slot":`alert-dialog-title`,className:Y(`font-heading text-base font-medium sm:group-data-[size=default]/alert-dialog-content:group-has-data-[slot=alert-dialog-media]/alert-dialog-content:col-start-2`,e),...t})}function Gb({className:e,...t}){return(0,z.jsx)(Ks,{"data-slot":`alert-dialog-description`,className:Y(`text-sm text-balance text-muted-foreground md:text-pretty *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,e),...t})}function Kb({className:e,variant:t=`default`,size:n=`default`,...r}){return(0,z.jsx)(X,{variant:t,size:n,asChild:!0,children:(0,z.jsx)(Us,{"data-slot":`alert-dialog-action`,className:Y(e),...r})})}function qb({className:e,variant:t=`outline`,size:n=`default`,...r}){return(0,z.jsx)(X,{variant:t,size:n,asChild:!0,children:(0,z.jsx)(Ws,{"data-slot":`alert-dialog-cancel`,className:Y(e),...r})})}var Jb=R.createContext(null);function Yb({children:e}){let{language:t}=Iv(),[n,r]=R.useState(null),i=R.useCallback(e=>new Promise(t=>r({...e,resolve:t})),[]),a=e=>{n?.resolve(e),r(null)};return(0,z.jsxs)(Jb.Provider,{value:i,children:[e,(0,z.jsx)(Rb,{open:n!=null,onOpenChange:e=>!e&&a(!1),children:(0,z.jsxs)(Vb,{children:[(0,z.jsxs)(Hb,{children:[(0,z.jsx)(Wb,{children:Q(t,`confirm.title`)}),(0,z.jsx)(Gb,{children:n?.description})]}),(0,z.jsxs)(Ub,{children:[(0,z.jsx)(qb,{onClick:()=>a(!1),children:Q(t,`confirm.cancel`)}),(0,z.jsx)(Kb,{variant:`destructive`,onClick:()=>a(!0),children:Q(t,`confirm.confirm`)})]})]})})]})}function Xb(){let e=R.useContext(Jb);if(!e)throw Error(`useConfirm() must be used within <ConfirmProvider>.`);return e}var Zb={draft:`bg-muted text-muted-foreground`,published:`bg-[color-mix(in_srgb,var(--success)_18%,transparent)] text-[color:var(--success)]`,archived:`bg-secondary text-muted-foreground`},Qb={draft:`status.draft`,published:`status.published`,archived:`status.archived`};function $b({status:e,className:t}){let{language:n}=Iv(),r=ex(e),i=Qb[e];return(0,z.jsx)(bb,{variant:`secondary`,className:Y(r?Zb[e]:`bg-accent text-accent-foreground`,t),children:i?Q(n,i):e})}function ex(e){return e in Zb}var tx=new Intl.DateTimeFormat(void 0,{dateStyle:`short`,timeStyle:`short`});function nx(e){return e?.[`x-mcp-hint`]===`money-minor`}function rx(e){return e?.[`x-mcp-hint`]===`timestamp-ms`}function ix(e,t){if(typeof e!=`number`||!Number.isFinite(e))return null;let n=e/100;if(typeof t==`string`&&t)try{return new Intl.NumberFormat(void 0,{style:`currency`,currency:t}).format(n)}catch{}return new Intl.NumberFormat().format(n)}function ax(e){if(typeof e!=`number`||!Number.isFinite(e))return null;try{return tx.format(new Date(e))}catch{return null}}function ox(e){if(typeof e!=`number`&&typeof e!=`string`)return;let t=new Date(e);return Number.isNaN(t.getTime())?void 0:t}function sx(e,t=8){return e.length<=t?e:e.slice(-t)}function cx(e){if(e instanceof mv){let t=e.body?.diagnostic?.message;if(t)return Error(t)}return e}function lx(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 ux=e=>{switch(e){case`success`:return px;case`info`:return hx;case`warning`:return mx;case`error`:return gx;default:return null}},dx=Array(12).fill(0),fx=({visible:e,className:t})=>R.createElement(`div`,{className:[`sonner-loading-wrapper`,t].filter(Boolean).join(` `),"data-visible":e},R.createElement(`div`,{className:`sonner-spinner`},dx.map((e,t)=>R.createElement(`div`,{className:`sonner-loading-bar`,key:`spinner-bar-${t}`})))),px=R.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},R.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`})),mx=R.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 24 24`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},R.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`})),hx=R.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},R.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`})),gx=R.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},R.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`})),_x=R.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`,"aria-hidden":`true`},R.createElement(`line`,{x1:`18`,y1:`6`,x2:`6`,y2:`18`}),R.createElement(`line`,{x1:`6`,y1:`6`,x2:`18`,y2:`18`})),vx=()=>{let[e,t]=R.useState(document.hidden);return R.useEffect(()=>{let e=()=>{t(document.hidden)};return document.addEventListener(`visibilitychange`,e),()=>document.removeEventListener(`visibilitychange`,e)},[]),e},yx=1,bx=100,xx=e=>typeof e?.id==`number`||e?.id?.length>0?e.id:yx++,Sx=new class{constructor(){this.subscribe=e=>(this.subscribers.push(e),this.getActiveToasts().forEach(t=>e(t)),()=>{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.trimHistory()},this.trimHistory=()=>{let e=this.toasts.length-bx;e<=0||(this.toasts=this.toasts.filter(t=>e>0&&this.dismissedToasts.has(t.id)?(this.dismissedToasts.delete(t.id),e--,!1):!0))},this.create=e=>{let{message:t,...n}=e,r=xx(e),i=this.pendingDismissals.get(r);i!==void 0&&(cancelAnimationFrame(i),this.pendingDismissals.delete(r),this.dismissedToasts.delete(r));let a=this.dismissedToasts.has(r),o=e.dismissible===void 0||e.dismissible;return a&&(this.dismissedToasts.delete(r),this.toasts=this.toasts.filter(e=>e.id!==r)),!a&&this.toasts.find(e=>e.id===r)?this.toasts=this.toasts.map(n=>n.id===r?(this.publish({...n,...e,id:r,title:t}),{...n,...e,id:r,dismissible:o,title:t}):n):this.addToast({title:t,...n,dismissible:o,id:r}),r},this.dismiss=e=>{if(e==null)return this.getActiveToasts().forEach(e=>{this.dismissedToasts.add(e.id),this.subscribers.forEach(t=>t({id:e.id,dismiss:!0}))}),e;this.dismissedToasts.add(e);let t=this.pendingDismissals.get(e);return t!==void 0&&cancelAnimationFrame(t),this.pendingDismissals.set(e,requestAnimationFrame(()=>{this.pendingDismissals.delete(e),this.subscribers.forEach(t=>t({id:e,dismiss:!0}))})),e},this.message=(e,t)=>this.create({...t,message:e,type:void 0}),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],R.isValidElement(e))i=!1,this.create({id:n,type:`default`,message:e});else if(wx(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`&&!R.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`&&!R.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`&&!R.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`&&!R.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=xx(t);return this.create({...t,jsx:e(n),id:n,type:void 0}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set,this.pendingDismissals=new Map}},Cx=(e,t)=>Sx.message(e,t),wx=e=>e&&typeof e==`object`&&`ok`in e&&typeof e.ok==`boolean`&&`status`in e&&typeof e.status==`number`,Tx=Object.assign(Cx,{success:Sx.success,info:Sx.info,warning:Sx.warning,error:Sx.error,custom:Sx.custom,message:Sx.message,promise:Sx.promise,dismiss:Sx.dismiss,loading:Sx.loading},{getHistory:()=>Sx.toasts,getToasts:()=>Sx.getActiveToasts()});lx(`[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;flex:1;min-width:0}[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(--normal-text);background:var(--normal-bg);border:1px solid var(--normal-border);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]{-webkit-user-select:none;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 Ex(e){return e.label!==void 0}var Dx=3,Ox=`24px`,kx=`16px`,Ax=4e3,jx=356,Mx=14,Nx=45,Px=200;function Fx(...e){return e.filter(Boolean).join(` `)}function Ix(e){let[t,n]=e.split(`-`),r=[];return t&&r.push(t),n&&r.push(n),r}var Lx=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:T=`Close toast`}=e,[E,ee]=R.useState(null),[D,O]=R.useState(null),[k,A]=R.useState(!1),[j,M]=R.useState(!1),[N,te]=R.useState(!1),[P,F]=R.useState(!1),[ne,re]=R.useState(!1),[ie,ae]=R.useState(0),[I,L]=R.useState(0),oe=R.useRef(n.duration||y||Ax),se=R.useRef(null),ce=R.useRef(null),le=c===0,ue=c+1<=o,de=n.type,fe=de??`default`,pe=n.dismissible!==!1,me=n.className||``,he=n.descriptionClassName||``,ge=R.useMemo(()=>s.findIndex(e=>e.toastId===n.id)||0,[s,n.id]),_e=R.useMemo(()=>n.closeButton??p,[n.closeButton,p]),ve=R.useMemo(()=>n.duration||y||Ax,[n.duration,y]),ye=R.useRef(0),be=R.useRef(0),xe=R.useRef(0),Se=R.useRef(null),[Ce,we]=b.split(`-`),Te=R.useMemo(()=>s.reduce((e,t,n)=>n>=ge?e:e+t.height,0),[s,ge]),Ee=vx(),De=R.useMemo(()=>e.swipeDirections??Ix(b),[e.swipeDirections,b]),Oe=n.invert||t,ke=de===`loading`;be.current=R.useMemo(()=>ge*x+Te,[ge,Te]),R.useEffect(()=>{oe.current=ve},[ve]),R.useEffect(()=>{A(!0)},[]),R.useEffect(()=>{let e=ce.current;if(e){let t=e.getBoundingClientRect().height;return L(t),a(e=>[{toastId:n.id,height:t,position:n.position},...e]),()=>a(e=>e.filter(e=>e.toastId!==n.id))}},[a,n.id]),R.useLayoutEffect(()=>{if(!k)return;let e=ce.current,t=e.style.height;e.style.height=`auto`;let r=e.getBoundingClientRect().height;e.style.height=t,L(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])},[k,n.title,n.description,a,n.id,n.jsx,n.action,n.cancel]);let Ae=R.useCallback(()=>{M(!0),ae(be.current),a(e=>e.filter(e=>e.toastId!==n.id)),setTimeout(()=>{d(n)},Px)},[n,d,a,be]);R.useEffect(()=>{if(n.promise&&de===`loading`||n.duration===1/0||n.type===`loading`)return;let e;return u||i||Ee?(()=>{if(xe.current<ye.current){let e=new Date().getTime()-ye.current;oe.current-=e}xe.current=new Date().getTime()})():oe.current!==1/0&&(ye.current=new Date().getTime(),e=setTimeout(()=>{n.onAutoClose==null||n.onAutoClose.call(n,n),Ae()},oe.current)),()=>clearTimeout(e)},[u,i,n,de,Ee,Ae]),R.useEffect(()=>{n.delete&&(Ae(),n.onDismiss==null||n.onDismiss.call(n,n))},[Ae,n.delete]);function je(){return w?.loading?R.createElement(`div`,{className:Fx(C?.loader,n?.classNames?.loader,`sonner-loader`),"data-visible":de===`loading`},w.loading):R.createElement(fx,{className:Fx(C?.loader,n?.classNames?.loader),visible:de===`loading`})}let Me=n.icon||w?.[de]||ux(de);return R.createElement(`li`,{tabIndex:0,ref:ce,className:Fx(_,me,C?.toast,n?.classNames?.toast,C?.[fe],n?.classNames?.[fe]),"data-sonner-toast":``,"data-rich-colors":n.richColors??f,"data-styled":!(n.jsx||n.unstyled||r),"data-mounted":k,"data-promise":!!n.promise,"data-swiped":ne,"data-removed":j,"data-visible":ue,"data-y-position":Ce,"data-x-position":we,"data-index":c,"data-front":le,"data-swiping":N,"data-dismissible":pe,"data-type":de,"data-invert":Oe,"data-swipe-out":P,"data-swipe-direction":D,"data-expanded":!!(u||S&&k),"data-testid":n.testId,style:{"--index":c,"--toasts-before":c,"--z-index":l.length-c,"--offset":`${j?ie:be.current}px`,"--initial-height":S?`auto`:`${I}px`,...m,...n.style},onDragEnd:()=>{te(!1),ee(null),Se.current=null},onPointerDown:e=>{e.button!==2&&(ke||!pe||(se.current=new Date,ae(be.current),e.target.setPointerCapture(e.pointerId),e.target.tagName!==`BUTTON`&&(te(!0),Se.current={x:e.clientX,y:e.clientY})))},onPointerUp:()=>{if(P||!pe)return;Se.current=null;let e=Number(ce.current?.style.getPropertyValue(`--swipe-amount-x`).replace(`px`,``)||0),t=Number(ce.current?.style.getPropertyValue(`--swipe-amount-y`).replace(`px`,``)||0),r=new Date().getTime()-se.current?.getTime(),i=E===`x`?e:t,a=Math.abs(i)/r;if((E===`x`?De.includes(e>0?`right`:`left`):De.includes(t>0?`bottom`:`top`))&&(Math.abs(i)>=Nx||a>.11)){ae(be.current),n.onDismiss==null||n.onDismiss.call(n,n),O(E===`x`?e>0?`right`:`left`:t>0?`down`:`up`),Ae(),F(!0);return}var o,s;(o=ce.current)==null||o.style.setProperty(`--swipe-amount-x`,`0px`),(s=ce.current)==null||s.style.setProperty(`--swipe-amount-y`,`0px`),re(!1),te(!1),ee(null)},onPointerMove:e=>{var t,n;if(!Se.current||!pe||window.getSelection()?.toString().length>0)return;let r=e.clientY-Se.current.y,i=e.clientX-Se.current.x;!E&&(Math.abs(i)>1||Math.abs(r)>1)&&ee(Math.abs(i)>Math.abs(r)?`x`:`y`);let a={x:0,y:0},o=e=>1/(1.5+Math.abs(e)/20);if(E===`y`){if(De.includes(`top`)||De.includes(`bottom`)){if(De.includes(`top`)&&r<0||De.includes(`bottom`)&&r>0)a.y=r;else{let e=r*o(r);a.y=Math.abs(e)<Math.abs(r)?e:r}}}else if(E===`x`&&(De.includes(`left`)||De.includes(`right`))){if(De.includes(`left`)&&i<0||De.includes(`right`)&&i>0)a.x=i;else{let e=i*o(i);a.x=Math.abs(e)<Math.abs(i)?e:i}}(Math.abs(a.x)>0||Math.abs(a.y)>0)&&re(!0),(t=ce.current)==null||t.style.setProperty(`--swipe-amount-x`,`${a.x}px`),(n=ce.current)==null||n.style.setProperty(`--swipe-amount-y`,`${a.y}px`)}},_e&&!n.jsx&&de!==`loading`?R.createElement(`button`,{"aria-label":T,"data-disabled":ke,"data-close-button":!0,onClick:ke||!pe?()=>{}:()=>{Ae(),n.onDismiss==null||n.onDismiss.call(n,n)},className:Fx(C?.closeButton,n?.classNames?.closeButton)},w?.close??_x):null,(de||n.icon||n.promise)&&n.icon!==null&&(w?.[de]!==null||n.icon)?R.createElement(`div`,{"data-icon":``,className:Fx(C?.icon,n?.classNames?.icon)},de===`loading`?n.icon||je():n.promise?je():null,de===`loading`?null:Me):null,R.createElement(`div`,{"data-content":``,className:Fx(C?.content,n?.classNames?.content)},R.createElement(`div`,{"data-title":``,className:Fx(C?.title,n?.classNames?.title)},n.jsx?n.jsx:typeof n.title==`function`?n.title():n.title),n.description?R.createElement(`div`,{"data-description":``,className:Fx(v,he,C?.description,n?.classNames?.description)},typeof n.description==`function`?n.description():n.description):null),R.isValidElement(n.cancel)?n.cancel:n.cancel&&Ex(n.cancel)?R.createElement(`button`,{"data-button":!0,"data-cancel":!0,style:n.cancelButtonStyle||h,onClick:e=>{Ex(n.cancel)&&pe&&(n.cancel.onClick==null||n.cancel.onClick.call(n.cancel,e),Ae())},className:Fx(C?.cancelButton,n?.classNames?.cancelButton)},n.cancel.label):null,R.isValidElement(n.action)?n.action:n.action&&Ex(n.action)?R.createElement(`button`,{"data-button":!0,"data-action":!0,style:n.actionButtonStyle||g,onClick:e=>{Ex(n.action)&&(n.action.onClick==null||n.action.onClick.call(n.action,e),!e.defaultPrevented&&Ae())},className:Fx(C?.actionButton,n?.classNames?.actionButton)},n.action.label):null)};function Rx(){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 zx(e,t){let n={};return[e,t].forEach((e,t)=>{let r=t===1,i=r?`--mobile-offset`:`--offset`,a=r?kx:Ox;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 Bx=R.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=Dx,toastOptions:g,dir:_=Rx(),gap:v=Mx,icons:y,customAriaLabel:b,containerAriaLabel:x=`Notifications`}=e,[S,C]=R.useState([]),w=R.useMemo(()=>n?S.filter(e=>e.toasterId===n):S.filter(e=>!e.toasterId),[S,n]),T=R.useMemo(()=>Array.from(new Set([i].concat(w.filter(e=>e.position).map(e=>e.position)))),[w,i]),[E,ee]=R.useState([]),[D,O]=R.useState(!1),[k,A]=R.useState(!1),[j,M]=R.useState(d===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`:d),N=R.useRef(null),te=a.join(`+`).replace(/Key/g,``).replace(/Digit/g,``),P=R.useRef(null),F=R.useRef(!1),ne=R.useCallback(e=>{C(t=>(t.find(t=>t.id===e.id)?.delete||Sx.dismiss(e.id),t.filter(({id:t})=>t!==e.id)))},[]);return R.useEffect(()=>Sx.subscribe(e=>{if(e.dismiss){requestAnimationFrame(()=>{C(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t))});return}setTimeout(()=>{mr.flushSync(()=>{C(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)]})})})}),[]),R.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]),R.useEffect(()=>{S.length<=1&&O(!1)},[S]),R.useEffect(()=>{let e=e=>{if(a.length>0&&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]),R.useEffect(()=>{if(N.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,F.current=!1)}},[N.current]),R.createElement(`section`,{ref:t,"aria-label":b??`${x} ${te}`,tabIndex:-1,"aria-live":`polite`,"aria-relevant":`additions text`,"aria-atomic":`false`,suppressHydrationWarning:!0,"data-react-aria-top-layer":!0},T.map((t,n)=>{let[i,a]=t.split(`-`);return w.length?R.createElement(`ol`,{key:t,dir:_===`auto`?Rx():_,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":`${jx}px`,"--gap":`${v}px`,...m,...zx(l,u)},onBlur:e=>{F.current&&!e.currentTarget.contains(e.relatedTarget)&&(F.current=!1,P.current&&=(P.current.focus({preventScroll:!0}),null))},onFocus:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||F.current||(F.current=!0,P.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)},w.filter(e=>!e.position&&n===0||e.position===t).map((n,i)=>R.createElement(Lx,{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:ne,toasts:w.filter(e=>e.position==n.position),heights:E.filter(e=>e.position==n.position),setHeights:ee,expandByDefault:o,gap:v,expanded:D,swipeDirections:e.swipeDirections}))):null}))});function Vx({...e}){return(0,z.jsx)(es,{"data-slot":`dialog`,...e})}function Hx({...e}){return(0,z.jsx)(os,{"data-slot":`dialog-portal`,...e})}function Ux({className:e,...t}){return(0,z.jsx)(cs,{"data-slot":`dialog-overlay`,className:Y(`fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...t})}function Wx({className:e,children:t,showCloseButton:n=!0,closeLabel:r,...i}){return(0,z.jsxs)(Hx,{children:[(0,z.jsx)(Ux,{}),(0,z.jsxs)(fs,{"data-slot":`dialog-content`,className:Y(`fixed top-1/2 start-1/2 z-50 grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 rtl:translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl bg-popover p-4 text-sm text-popover-foreground ring-1 ring-foreground/10 duration-100 outline-none sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,e),...i,children:[t,n&&(0,z.jsx)(xs,{"data-slot":`dialog-close`,asChild:!0,children:(0,z.jsxs)(X,{variant:`ghost`,className:`absolute top-2 end-2`,size:`icon-sm`,children:[(0,z.jsx)(Vn,{}),(0,z.jsx)(`span`,{className:`sr-only`,children:r})]})})]})]})}function Gx({className:e,...t}){return(0,z.jsx)(`div`,{"data-slot":`dialog-header`,className:Y(`flex flex-col gap-2`,e),...t})}function Kx({className:e,children:t,...n}){return(0,z.jsx)(`div`,{"data-slot":`dialog-footer`,className:Y(`-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end`,e),...n,children:t})}function qx({className:e,...t}){return(0,z.jsx)(_s,{"data-slot":`dialog-title`,className:Y(`font-heading text-base leading-none font-medium`,e),...t})}function Jx({className:e,...t}){return(0,z.jsx)(ys,{"data-slot":`dialog-description`,className:Y(`text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,e),...t})}function Yx(e,t,n=`long`){return new Intl.DateTimeFormat(`en-US`,{hour:`numeric`,timeZone:e,timeZoneName:n}).format(t).split(/\s/g).slice(2).join(` `)}var Xx={},Zx={};function Qx(e,t){try{let n=(Xx[e]||=new Intl.DateTimeFormat(`en-US`,{timeZone:e,timeZoneName:`longOffset`}).format)(t).split(`GMT`)[1];return n in Zx?Zx[n]:eS(n,n.split(`:`))}catch{if(e in Zx)return Zx[e];let t=e?.match($x);return t?eS(e,t.slice(1)):NaN}}var $x=/([+-]\d\d):?(\d\d)?/;function eS(e,t){let n=+(t[0]||0),r=+(t[1]||0),i=(t[2]||0)/60;return Zx[e]=n*60+r>0?n*60+r+i:n*60-r-i}var tS=class e extends Date{constructor(...e){super(),e.length>1&&typeof e[e.length-1]==`string`&&(this.timeZone=e.pop()),this.internal=new Date,isNaN(Qx(this.timeZone,this))?this.setTime(NaN):e.length?typeof e[0]==`number`&&(e.length===1||e.length===2&&typeof e[1]!=`number`)?this.setTime(e[0]):typeof e[0]==`string`?this.setTime(+new Date(e[0])):e[0]instanceof Date?this.setTime(+e[0]):(this.setTime(+new Date(...e)),aS(this,e)):this.setTime(Date.now())}static tz(t,...n){return n.length?new e(...n,t):new e(Date.now(),t)}withTimeZone(t){return new e(+this,t)}getTimezoneOffset(){let e=-Qx(this.timeZone,this);return e>0?Math.floor(e):Math.ceil(e)}setTime(e){return Date.prototype.setTime.apply(this,arguments),rS(this),+this}[Symbol.for(`constructDateFrom`)](t){return new e(+new Date(t),this.timeZone)}},nS=/^(get|set)(?!UTC)/;Object.getOwnPropertyNames(Date.prototype).forEach(e=>{if(!nS.test(e))return;let t=e.replace(nS,`$1UTC`);tS.prototype[t]&&(e.startsWith(`get`)?tS.prototype[e]=function(){return this.internal[t]()}:(tS.prototype[e]=function(){return Date.prototype[t].apply(this.internal,arguments),iS(this),+this},tS.prototype[t]=function(){return Date.prototype[t].apply(this,arguments),rS(this),+this}))});function rS(e){e.internal.setTime(+e),e.internal.setUTCSeconds(e.internal.getUTCSeconds()-Math.round(-Qx(e.timeZone,e)*60))}function iS(e){Date.prototype.setFullYear.call(e,e.internal.getUTCFullYear(),e.internal.getUTCMonth(),e.internal.getUTCDate()),Date.prototype.setHours.call(e,e.internal.getUTCHours(),e.internal.getUTCMinutes(),e.internal.getUTCSeconds(),e.internal.getUTCMilliseconds()),aS(e)}function aS(e,t){let n=Array.isArray(t)?oS(t):+e.internal,r=Qx(e.timeZone,e),i=r>0?Math.floor(r):Math.ceil(r),a=new Date(+e);a.setUTCHours(a.getUTCHours()-1);let o=-new Date(+e).getTimezoneOffset(),s=-new Date(+a).getTimezoneOffset(),c=o-s,l=o;if(c&&o!==i&&Date.prototype.getHours.apply(e)!==(Array.isArray(t)?t[3]||0:e.internal.getUTCHours())){let t=new Date(+e),n=o-i;n&&t.setUTCMinutes(t.getUTCMinutes()+n);let r=Qx(e.timeZone,t);(r>0?Math.floor(r):Math.ceil(r))===i&&(l=s)}let u=l-i;u&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+u);let d=new Date(+e);d.setUTCSeconds(0);let f=o>0?d.getSeconds():(d.getSeconds()-60)%60,p=Math.round(-(Qx(e.timeZone,e)*60))%60;(p||f)&&Date.prototype.setUTCSeconds.call(e,Date.prototype.getUTCSeconds.call(e)+p+f);let m=Qx(e.timeZone,e),h=m>0?Math.floor(m):Math.ceil(m),g=-new Date(+e).getTimezoneOffset()-h,_=h!==i,v=g-u,y=h-i,b=n-h*60*1e3,x=y>0&&sS(e)-n===y*60*1e3&&sS(e,b)!==n;if(_&&v&&!x){Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+v);let t=Qx(e.timeZone,e),n=h-(t>0?Math.floor(t):Math.ceil(t));n&&v<0&&Date.prototype.setUTCMinutes.call(e,Date.prototype.getUTCMinutes.call(e)+n)}rS(e);let S=(t?n:n+p*1e3)-+e.internal;S&&Math.abs(S)<18e5&&(Date.prototype.setTime.call(e,+e+S),rS(e))}function oS(e){return Date.UTC(e[0],e.length>1?e[1]:0,e.length>2?e[2]:1,...e.slice(3))}function sS(e,t){let n=new Date(t??+e);return n.setUTCSeconds(n.getUTCSeconds()-Math.round(-Qx(e.timeZone,n)*60)),+n}var cS=class e extends tS{static tz(t,...n){return n.length?new e(...n,t):new e(Date.now(),t)}toISOString(){let[e,t,n]=this.tzComponents(),r=`${e}${t}:${n}`;return this.internal.toISOString().slice(0,-1)+r}toString(){return`${this.toDateString()} ${this.toTimeString()}`}toDateString(){let[e,t,n,r]=this.internal.toUTCString().split(` `);return`${e?.slice(0,-1)} ${n} ${t} ${r}`}toTimeString(){let e=this.internal.toUTCString().split(` `)[4],[t,n,r]=this.tzComponents();return`${e} GMT${t}${n}${r} (${Yx(this.timeZone,this)})`}toLocaleString(e,t){return Date.prototype.toLocaleString.call(this,e,{...t,timeZone:t?.timeZone||this.timeZone})}toLocaleDateString(e,t){return Date.prototype.toLocaleDateString.call(this,e,{...t,timeZone:t?.timeZone||this.timeZone})}toLocaleTimeString(e,t){return Date.prototype.toLocaleTimeString.call(this,e,{...t,timeZone:t?.timeZone||this.timeZone})}tzComponents(){let e=this.getTimezoneOffset();return[e>0?`-`:`+`,String(Math.floor(Math.abs(e)/60)).padStart(2,`0`),String(Math.abs(e)%60).padStart(2,`0`)]}withTimeZone(t){return new e(+this,t)}[Symbol.for(`constructDateFrom`)](t){return new e(+new Date(t),this.timeZone)}},lS=365.2425,uS=6048e5,dS=864e5,fS=86400;fS*7,fS*lS/12*3;var pS=Symbol.for(`constructDateFrom`);function mS(e,t){return typeof e==`function`?e(t):e&&typeof e==`object`&&pS in e?e[pS](t):e instanceof Date?new e.constructor(t):new Date(t)}function hS(e,t){return mS(t||e,e)}function gS(e,t,n){let r=hS(e,n?.in);return isNaN(t)?mS(n?.in||e,NaN):(t&&r.setDate(r.getDate()+t),r)}function _S(e,t,n){let r=hS(e,n?.in);if(isNaN(t))return mS(n?.in||e,NaN);if(!t)return r;let i=r.getDate(),a=mS(n?.in||e,r.getTime());return a.setMonth(r.getMonth()+t+1,0),i>=a.getDate()?a:(r.setFullYear(a.getFullYear(),a.getMonth(),i),r)}var vS={};function yS(){return vS}function bS(e,t){let n=yS(),r=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,i=hS(e,t?.in),a=i.getDay(),o=(a<r?7:0)+a-r;return i.setDate(i.getDate()-o),i.setHours(0,0,0,0),i}function xS(e,t){return bS(e,{...t,weekStartsOn:1})}function SS(e,t){let n=hS(e,t?.in),r=n.getFullYear(),i=mS(n,0);i.setFullYear(r+1,0,4),i.setHours(0,0,0,0);let a=xS(i),o=mS(n,0);o.setFullYear(r,0,4),o.setHours(0,0,0,0);let s=xS(o);return n.getTime()>=a.getTime()?r+1:n.getTime()>=s.getTime()?r:r-1}function CS(e){let t=hS(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),e-+n}function wS(e,...t){let n=mS.bind(null,e||t.find(e=>typeof e==`object`));return t.map(n)}function TS(e,t){let n=hS(e,t?.in);return n.setHours(0,0,0,0),n}function ES(e,t,n){let[r,i]=wS(n?.in,e,t),a=TS(r),o=TS(i),s=+a-CS(a),c=+o-CS(o);return Math.round((s-c)/dS)}function DS(e,t){let n=SS(e,t),r=mS(t?.in||e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),xS(r)}function OS(e,t,n){return gS(e,t*7,n)}function kS(e,t,n){return _S(e,t*12,n)}function AS(e,t){let n,r=t?.in;return e.forEach(e=>{!r&&typeof e==`object`&&(r=mS.bind(null,e));let t=hS(e,r);(!n||n<t||isNaN(+t))&&(n=t)}),mS(r,n||NaN)}function jS(e,t){let n,r=t?.in;return e.forEach(e=>{!r&&typeof e==`object`&&(r=mS.bind(null,e));let t=hS(e,r);(!n||n>t||isNaN(+t))&&(n=t)}),mS(r,n||NaN)}function MS(e,t,n){let[r,i]=wS(n?.in,e,t);return+TS(r)==+TS(i)}function NS(e){return e instanceof Date||typeof e==`object`&&Object.prototype.toString.call(e)===`[object Date]`}function PS(e){return!(!NS(e)&&typeof e!=`number`||isNaN(+hS(e)))}function FS(e,t,n){let[r,i]=wS(n?.in,e,t),a=r.getFullYear()-i.getFullYear(),o=r.getMonth()-i.getMonth();return a*12+o}function IS(e,t){let n=hS(e,t?.in),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function LS(e,t){let[n,r]=wS(e,t.start,t.end);return{start:n,end:r}}function RS(e,t){let{start:n,end:r}=LS(t?.in,e),i=+n>+r,a=i?+n:+r,o=i?r:n;o.setHours(0,0,0,0),o.setDate(1);let s=t?.step??1;if(!s)return[];s<0&&(s=-s,i=!i);let c=[];for(;+o<=a;)c.push(mS(n,o)),o.setMonth(o.getMonth()+s);return i?c.reverse():c}function zS(e,t){let n=hS(e,t?.in);return n.setDate(1),n.setHours(0,0,0,0),n}function BS(e,t){let n=hS(e,t?.in),r=n.getFullYear();return n.setFullYear(r+1,0,0),n.setHours(23,59,59,999),n}function VS(e,t){let n=hS(e,t?.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function HS(e,t){let{start:n,end:r}=LS(t?.in,e),i=+n>+r,a=i?+n:+r,o=i?r:n;o.setHours(0,0,0,0),o.setMonth(0,1);let s=t?.step??1;if(!s)return[];s<0&&(s=-s,i=!i);let c=[];for(;+o<=a;)c.push(mS(n,o)),o.setFullYear(o.getFullYear()+s);return i?c.reverse():c}function US(e,t){let n=yS(),r=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,i=hS(e,t?.in),a=i.getDay(),o=(a<r?-7:0)+6-(a-r);return i.setDate(i.getDate()+o),i.setHours(23,59,59,999),i}function WS(e,t){return US(e,{...t,weekStartsOn:1})}var GS={lessThanXSeconds:{one:`less than a second`,other:`less than {{count}} seconds`},xSeconds:{one:`1 second`,other:`{{count}} seconds`},halfAMinute:`half a minute`,lessThanXMinutes:{one:`less than a minute`,other:`less than {{count}} minutes`},xMinutes:{one:`1 minute`,other:`{{count}} minutes`},aboutXHours:{one:`about 1 hour`,other:`about {{count}} hours`},xHours:{one:`1 hour`,other:`{{count}} hours`},xDays:{one:`1 day`,other:`{{count}} days`},aboutXWeeks:{one:`about 1 week`,other:`about {{count}} weeks`},xWeeks:{one:`1 week`,other:`{{count}} weeks`},aboutXMonths:{one:`about 1 month`,other:`about {{count}} months`},xMonths:{one:`1 month`,other:`{{count}} months`},aboutXYears:{one:`about 1 year`,other:`about {{count}} years`},xYears:{one:`1 year`,other:`{{count}} years`},overXYears:{one:`over 1 year`,other:`over {{count}} years`},almostXYears:{one:`almost 1 year`,other:`almost {{count}} years`}},KS=(e,t,n)=>{let r,i=GS[e];return r=typeof i==`string`?i:t===1?i.one:i.other.replace(`{{count}}`,t.toString()),n?.addSuffix?n.comparison&&n.comparison>0?`in `+r:r+` ago`:r};function qS(e){return(t={})=>{let n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}var JS={date:qS({formats:{full:`EEEE, MMMM do, y`,long:`MMMM do, y`,medium:`MMM d, y`,short:`MM/dd/yyyy`},defaultWidth:`full`}),time:qS({formats:{full:`h:mm:ss a zzzz`,long:`h:mm:ss a z`,medium:`h:mm:ss a`,short:`h:mm a`},defaultWidth:`full`}),dateTime:qS({formats:{full:`{{date}} 'at' {{time}}`,long:`{{date}} 'at' {{time}}`,medium:`{{date}}, {{time}}`,short:`{{date}}, {{time}}`},defaultWidth:`full`})},YS={lastWeek:`'last' eeee 'at' p`,yesterday:`'yesterday at' p`,today:`'today at' p`,tomorrow:`'tomorrow at' p`,nextWeek:`eeee 'at' p`,other:`P`},XS=(e,t,n,r)=>YS[e];function ZS(e){return(t,n)=>{let r=n?.context?String(n.context):`standalone`,i;if(r===`formatting`&&e.formattingValues){let t=e.defaultFormattingWidth||e.defaultWidth,r=n?.width?String(n.width):t;i=e.formattingValues[r]||e.formattingValues[t]}else{let t=e.defaultWidth,r=n?.width?String(n.width):e.defaultWidth;i=e.values[r]||e.values[t]}let a=e.argumentCallback?e.argumentCallback(t):t;return i[a]}}var QS={ordinalNumber:(e,t)=>{let n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+`st`;case 2:return n+`nd`;case 3:return n+`rd`}return n+`th`},era:ZS({values:{narrow:[`B`,`A`],abbreviated:[`BC`,`AD`],wide:[`Before Christ`,`Anno Domini`]},defaultWidth:`wide`}),quarter:ZS({values:{narrow:[`1`,`2`,`3`,`4`],abbreviated:[`Q1`,`Q2`,`Q3`,`Q4`],wide:[`1st quarter`,`2nd quarter`,`3rd quarter`,`4th quarter`]},defaultWidth:`wide`,argumentCallback:e=>e-1}),month:ZS({values:{narrow:[`J`,`F`,`M`,`A`,`M`,`J`,`J`,`A`,`S`,`O`,`N`,`D`],abbreviated:[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`],wide:[`January`,`February`,`March`,`April`,`May`,`June`,`July`,`August`,`September`,`October`,`November`,`December`]},defaultWidth:`wide`}),day:ZS({values:{narrow:[`S`,`M`,`T`,`W`,`T`,`F`,`S`],short:[`Su`,`Mo`,`Tu`,`We`,`Th`,`Fr`,`Sa`],abbreviated:[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`],wide:[`Sunday`,`Monday`,`Tuesday`,`Wednesday`,`Thursday`,`Friday`,`Saturday`]},defaultWidth:`wide`}),dayPeriod:ZS({values:{narrow:{am:`a`,pm:`p`,midnight:`mi`,noon:`n`,morning:`morning`,afternoon:`afternoon`,evening:`evening`,night:`night`},abbreviated:{am:`AM`,pm:`PM`,midnight:`midnight`,noon:`noon`,morning:`morning`,afternoon:`afternoon`,evening:`evening`,night:`night`},wide:{am:`a.m.`,pm:`p.m.`,midnight:`midnight`,noon:`noon`,morning:`morning`,afternoon:`afternoon`,evening:`evening`,night:`night`}},defaultWidth:`wide`,formattingValues:{narrow:{am:`a`,pm:`p`,midnight:`mi`,noon:`n`,morning:`in the morning`,afternoon:`in the afternoon`,evening:`in the evening`,night:`at night`},abbreviated:{am:`AM`,pm:`PM`,midnight:`midnight`,noon:`noon`,morning:`in the morning`,afternoon:`in the afternoon`,evening:`in the evening`,night:`at night`},wide:{am:`a.m.`,pm:`p.m.`,midnight:`midnight`,noon:`noon`,morning:`in the morning`,afternoon:`in the afternoon`,evening:`in the evening`,night:`at night`}},defaultFormattingWidth:`wide`})};function $S(e){return(t,n={})=>{let r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],a=t.match(i);if(!a)return null;let o=a[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(s)?tC(s,e=>e.test(o)):eC(s,e=>e.test(o)),l;l=e.valueCallback?e.valueCallback(c):c,l=n.valueCallback?n.valueCallback(l):l;let u=t.slice(o.length);return{value:l,rest:u}}}function eC(e,t){for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function tC(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function nC(e){return(t,n={})=>{let r=t.match(e.matchPattern);if(!r)return null;let i=r[0],a=t.match(e.parsePattern);if(!a)return null;let o=e.valueCallback?e.valueCallback(a[0]):a[0];o=n.valueCallback?n.valueCallback(o):o;let s=t.slice(i.length);return{value:o,rest:s}}}var rC={code:`en-US`,formatDistance:KS,formatLong:JS,formatRelative:XS,localize:QS,match:{ordinalNumber:nC({matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:e=>parseInt(e,10)}),era:$S({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:`wide`,parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:`any`}),quarter:$S({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:`wide`,parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:`any`,valueCallback:e=>e+1}),month:$S({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:`wide`,parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:`any`}),day:$S({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:`wide`,parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:`any`}),dayPeriod:$S({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:`any`,parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:`any`})},options:{weekStartsOn:0,firstWeekContainsDate:1}};function iC(e,t){let n=hS(e,t?.in);return ES(n,VS(n))+1}function aC(e,t){let n=hS(e,t?.in),r=xS(n)-+DS(n);return Math.round(r/uS)+1}function oC(e,t){let n=hS(e,t?.in),r=n.getFullYear(),i=yS(),a=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??i.firstWeekContainsDate??i.locale?.options?.firstWeekContainsDate??1,o=mS(t?.in||e,0);o.setFullYear(r+1,0,a),o.setHours(0,0,0,0);let s=bS(o,t),c=mS(t?.in||e,0);c.setFullYear(r,0,a),c.setHours(0,0,0,0);let l=bS(c,t);return+n>=+s?r+1:+n>=+l?r:r-1}function sC(e,t){let n=yS(),r=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??n.firstWeekContainsDate??n.locale?.options?.firstWeekContainsDate??1,i=oC(e,t),a=mS(t?.in||e,0);return a.setFullYear(i,0,r),a.setHours(0,0,0,0),bS(a,t)}function cC(e,t){let n=hS(e,t?.in),r=bS(n,t)-+sC(n,t);return Math.round(r/uS)+1}function lC(e,t){return(e<0?`-`:``)+Math.abs(e).toString().padStart(t,`0`)}var uC={y(e,t){let n=e.getFullYear(),r=n>0?n:1-n;return lC(t===`yy`?r%100:r,t.length)},M(e,t){let n=e.getMonth();return t===`M`?String(n+1):lC(n+1,2)},d(e,t){return lC(e.getDate(),t.length)},a(e,t){let n=e.getHours()/12>=1?`pm`:`am`;switch(t){case`a`:case`aa`:return n.toUpperCase();case`aaa`:return n;case`aaaaa`:return n[0];default:return n===`am`?`a.m.`:`p.m.`}},h(e,t){return lC(e.getHours()%12||12,t.length)},H(e,t){return lC(e.getHours(),t.length)},m(e,t){return lC(e.getMinutes(),t.length)},s(e,t){return lC(e.getSeconds(),t.length)},S(e,t){let n=t.length,r=e.getMilliseconds();return lC(Math.trunc(r*10**(n-3)),t.length)}},dC={am:`am`,pm:`pm`,midnight:`midnight`,noon:`noon`,morning:`morning`,afternoon:`afternoon`,evening:`evening`,night:`night`},fC={G:function(e,t,n){let r=+(e.getFullYear()>0);switch(t){case`G`:case`GG`:case`GGG`:return n.era(r,{width:`abbreviated`});case`GGGGG`:return n.era(r,{width:`narrow`});default:return n.era(r,{width:`wide`})}},y:function(e,t,n){if(t===`yo`){let t=e.getFullYear(),r=t>0?t:1-t;return n.ordinalNumber(r,{unit:`year`})}return uC.y(e,t)},Y:function(e,t,n,r){let i=oC(e,r),a=i>0?i:1-i;return t===`YY`?lC(a%100,2):t===`Yo`?n.ordinalNumber(a,{unit:`year`}):lC(a,t.length)},R:function(e,t){return lC(SS(e),t.length)},u:function(e,t){return lC(e.getFullYear(),t.length)},Q:function(e,t,n){let r=Math.ceil((e.getMonth()+1)/3);switch(t){case`Q`:return String(r);case`QQ`:return lC(r,2);case`Qo`:return n.ordinalNumber(r,{unit:`quarter`});case`QQQ`:return n.quarter(r,{width:`abbreviated`,context:`formatting`});case`QQQQQ`:return n.quarter(r,{width:`narrow`,context:`formatting`});default:return n.quarter(r,{width:`wide`,context:`formatting`})}},q:function(e,t,n){let r=Math.ceil((e.getMonth()+1)/3);switch(t){case`q`:return String(r);case`qq`:return lC(r,2);case`qo`:return n.ordinalNumber(r,{unit:`quarter`});case`qqq`:return n.quarter(r,{width:`abbreviated`,context:`standalone`});case`qqqqq`:return n.quarter(r,{width:`narrow`,context:`standalone`});default:return n.quarter(r,{width:`wide`,context:`standalone`})}},M:function(e,t,n){let r=e.getMonth();switch(t){case`M`:case`MM`:return uC.M(e,t);case`Mo`:return n.ordinalNumber(r+1,{unit:`month`});case`MMM`:return n.month(r,{width:`abbreviated`,context:`formatting`});case`MMMMM`:return n.month(r,{width:`narrow`,context:`formatting`});default:return n.month(r,{width:`wide`,context:`formatting`})}},L:function(e,t,n){let r=e.getMonth();switch(t){case`L`:return String(r+1);case`LL`:return lC(r+1,2);case`Lo`:return n.ordinalNumber(r+1,{unit:`month`});case`LLL`:return n.month(r,{width:`abbreviated`,context:`standalone`});case`LLLLL`:return n.month(r,{width:`narrow`,context:`standalone`});default:return n.month(r,{width:`wide`,context:`standalone`})}},w:function(e,t,n,r){let i=cC(e,r);return t===`wo`?n.ordinalNumber(i,{unit:`week`}):lC(i,t.length)},I:function(e,t,n){let r=aC(e);return t===`Io`?n.ordinalNumber(r,{unit:`week`}):lC(r,t.length)},d:function(e,t,n){return t===`do`?n.ordinalNumber(e.getDate(),{unit:`date`}):uC.d(e,t)},D:function(e,t,n){let r=iC(e);return t===`Do`?n.ordinalNumber(r,{unit:`dayOfYear`}):lC(r,t.length)},E:function(e,t,n){let r=e.getDay();switch(t){case`E`:case`EE`:case`EEE`:return n.day(r,{width:`abbreviated`,context:`formatting`});case`EEEEE`:return n.day(r,{width:`narrow`,context:`formatting`});case`EEEEEE`:return n.day(r,{width:`short`,context:`formatting`});default:return n.day(r,{width:`wide`,context:`formatting`})}},e:function(e,t,n,r){let i=e.getDay(),a=(i-r.weekStartsOn+8)%7||7;switch(t){case`e`:return String(a);case`ee`:return lC(a,2);case`eo`:return n.ordinalNumber(a,{unit:`day`});case`eee`:return n.day(i,{width:`abbreviated`,context:`formatting`});case`eeeee`:return n.day(i,{width:`narrow`,context:`formatting`});case`eeeeee`:return n.day(i,{width:`short`,context:`formatting`});default:return n.day(i,{width:`wide`,context:`formatting`})}},c:function(e,t,n,r){let i=e.getDay(),a=(i-r.weekStartsOn+8)%7||7;switch(t){case`c`:return String(a);case`cc`:return lC(a,t.length);case`co`:return n.ordinalNumber(a,{unit:`day`});case`ccc`:return n.day(i,{width:`abbreviated`,context:`standalone`});case`ccccc`:return n.day(i,{width:`narrow`,context:`standalone`});case`cccccc`:return n.day(i,{width:`short`,context:`standalone`});default:return n.day(i,{width:`wide`,context:`standalone`})}},i:function(e,t,n){let r=e.getDay(),i=r===0?7:r;switch(t){case`i`:return String(i);case`ii`:return lC(i,t.length);case`io`:return n.ordinalNumber(i,{unit:`day`});case`iii`:return n.day(r,{width:`abbreviated`,context:`formatting`});case`iiiii`:return n.day(r,{width:`narrow`,context:`formatting`});case`iiiiii`:return n.day(r,{width:`short`,context:`formatting`});default:return n.day(r,{width:`wide`,context:`formatting`})}},a:function(e,t,n){let r=e.getHours()/12>=1?`pm`:`am`;switch(t){case`a`:case`aa`:return n.dayPeriod(r,{width:`abbreviated`,context:`formatting`});case`aaa`:return n.dayPeriod(r,{width:`abbreviated`,context:`formatting`}).toLowerCase();case`aaaaa`:return n.dayPeriod(r,{width:`narrow`,context:`formatting`});default:return n.dayPeriod(r,{width:`wide`,context:`formatting`})}},b:function(e,t,n){let r=e.getHours(),i;switch(i=r===12?dC.noon:r===0?dC.midnight:r/12>=1?`pm`:`am`,t){case`b`:case`bb`:return n.dayPeriod(i,{width:`abbreviated`,context:`formatting`});case`bbb`:return n.dayPeriod(i,{width:`abbreviated`,context:`formatting`}).toLowerCase();case`bbbbb`:return n.dayPeriod(i,{width:`narrow`,context:`formatting`});default:return n.dayPeriod(i,{width:`wide`,context:`formatting`})}},B:function(e,t,n){let r=e.getHours(),i;switch(i=r>=17?dC.evening:r>=12?dC.afternoon:r>=4?dC.morning:dC.night,t){case`B`:case`BB`:case`BBB`:return n.dayPeriod(i,{width:`abbreviated`,context:`formatting`});case`BBBBB`:return n.dayPeriod(i,{width:`narrow`,context:`formatting`});default:return n.dayPeriod(i,{width:`wide`,context:`formatting`})}},h:function(e,t,n){if(t===`ho`){let t=e.getHours()%12;return t===0&&(t=12),n.ordinalNumber(t,{unit:`hour`})}return uC.h(e,t)},H:function(e,t,n){return t===`Ho`?n.ordinalNumber(e.getHours(),{unit:`hour`}):uC.H(e,t)},K:function(e,t,n){let r=e.getHours()%12;return t===`Ko`?n.ordinalNumber(r,{unit:`hour`}):lC(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t===`ko`?n.ordinalNumber(r,{unit:`hour`}):lC(r,t.length)},m:function(e,t,n){return t===`mo`?n.ordinalNumber(e.getMinutes(),{unit:`minute`}):uC.m(e,t)},s:function(e,t,n){return t===`so`?n.ordinalNumber(e.getSeconds(),{unit:`second`}):uC.s(e,t)},S:function(e,t){return uC.S(e,t)},X:function(e,t,n){let r=e.getTimezoneOffset();if(r===0)return`Z`;switch(t){case`X`:return mC(r);case`XXXX`:case`XX`:return hC(r);default:return hC(r,`:`)}},x:function(e,t,n){let r=e.getTimezoneOffset();switch(t){case`x`:return mC(r);case`xxxx`:case`xx`:return hC(r);default:return hC(r,`:`)}},O:function(e,t,n){let r=e.getTimezoneOffset();switch(t){case`O`:case`OO`:case`OOO`:return`GMT`+pC(r,`:`);default:return`GMT`+hC(r,`:`)}},z:function(e,t,n){let r=e.getTimezoneOffset();switch(t){case`z`:case`zz`:case`zzz`:return`GMT`+pC(r,`:`);default:return`GMT`+hC(r,`:`)}},t:function(e,t,n){return lC(Math.trunc(e/1e3),t.length)},T:function(e,t,n){return lC(+e,t.length)}};function pC(e,t=``){let n=e>0?`-`:`+`,r=Math.abs(e),i=Math.trunc(r/60),a=r%60;return a===0?n+String(i):n+String(i)+t+lC(a,2)}function mC(e,t){return e%60==0?(e>0?`-`:`+`)+lC(Math.abs(e)/60,2):hC(e,t)}function hC(e,t=``){let n=e>0?`-`:`+`,r=Math.abs(e),i=lC(Math.trunc(r/60),2),a=lC(r%60,2);return n+i+t+a}var gC=(e,t)=>{switch(e){case`P`:return t.date({width:`short`});case`PP`:return t.date({width:`medium`});case`PPP`:return t.date({width:`long`});default:return t.date({width:`full`})}},_C=(e,t)=>{switch(e){case`p`:return t.time({width:`short`});case`pp`:return t.time({width:`medium`});case`ppp`:return t.time({width:`long`});default:return t.time({width:`full`})}},vC={p:_C,P:(e,t)=>{let n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return gC(e,t);let a;switch(r){case`P`:a=t.dateTime({width:`short`});break;case`PP`:a=t.dateTime({width:`medium`});break;case`PPP`:a=t.dateTime({width:`long`});break;default:a=t.dateTime({width:`full`})}return a.replace(`{{date}}`,gC(r,t)).replace(`{{time}}`,_C(i,t))}},yC=/^D+$/,bC=/^Y+$/,xC=[`D`,`DD`,`YY`,`YYYY`];function SC(e){return yC.test(e)}function CC(e){return bC.test(e)}function wC(e,t,n){let r=TC(e,t,n);if(console.warn(r),xC.includes(e))throw RangeError(r)}function TC(e,t,n){let r=e[0]===`Y`?`years`:`days of the month`;return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}var EC=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,DC=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,OC=/^'([^]*?)'?$/,kC=/''/g,AC=/[a-zA-Z]/;function jC(e,t,n){let r=yS(),i=n?.locale??r.locale??rC,a=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,o=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,s=hS(e,n?.in);if(!PS(s))throw RangeError(`Invalid time value`);let c=t.match(DC).map(e=>{let t=e[0];if(t===`p`||t===`P`){let n=vC[t];return n(e,i.formatLong)}return e}).join(``).match(EC).map(e=>{if(e===`''`)return{isToken:!1,value:`'`};let t=e[0];if(t===`'`)return{isToken:!1,value:MC(e)};if(fC[t])return{isToken:!0,value:e};if(t.match(AC))throw RangeError("Format string contains an unescaped latin alphabet character `"+t+"`");return{isToken:!1,value:e}});i.localize.preprocessor&&(c=i.localize.preprocessor(s,c));let l={firstWeekContainsDate:a,weekStartsOn:o,locale:i};return c.map(r=>{if(!r.isToken)return r.value;let a=r.value;(!n?.useAdditionalWeekYearTokens&&CC(a)||!n?.useAdditionalDayOfYearTokens&&SC(a))&&wC(a,t,String(e));let o=fC[a[0]];return o(s,a,i.localize,l)}).join(``)}function MC(e){let t=e.match(OC);return t?t[1].replace(kC,`'`):e}function NC(e,t){let n=hS(e,t?.in),r=n.getFullYear(),i=n.getMonth(),a=mS(n,0);return a.setFullYear(r,i+1,0),a.setHours(0,0,0,0),a.getDate()}function PC(e,t){return hS(e,t?.in).getMonth()}function FC(e,t){return hS(e,t?.in).getFullYear()}function IC(e,t){return+hS(e)>+hS(t)}function LC(e,t){return+hS(e)<+hS(t)}function RC(e,t,n){let[r,i]=wS(n?.in,e,t);return r.getFullYear()===i.getFullYear()&&r.getMonth()===i.getMonth()}function zC(e,t,n){let[r,i]=wS(n?.in,e,t);return r.getFullYear()===i.getFullYear()}function BC(e,t,n){let r=hS(e,n?.in),i=r.getFullYear(),a=r.getDate(),o=mS(n?.in||e,0);o.setFullYear(i,t,15),o.setHours(0,0,0,0);let s=NC(o);return r.setMonth(t,Math.min(a,s)),r}function VC(e,t,n){let r=hS(e,n?.in);return isNaN(+r)?mS(n?.in||e,NaN):(r.setFullYear(t),r)}var HC=5,UC=4;function WC(e,t){let n=t.startOfMonth(e),r=n.getDay()>0?n.getDay():7,i=t.addDays(e,-r+1),a=t.addDays(i,34);return t.getMonth(e)===t.getMonth(a)?HC:UC}function GC(e,t){let n=t.startOfMonth(e),r=n.getDay();return r===1?n:r===0?t.addDays(n,-6):t.addDays(n,-1*(r-1))}function KC(e,t){let n=GC(e,t),r=WC(e,t);return t.addDays(n,r*7-1)}var qC={...rC,labels:{labelDayButton:(e,t,n,r)=>{let i;i=r&&typeof r.format==`function`?r.format.bind(r):(e,t)=>jC(e,t,{locale:rC,...n});let a=i(e,`PPPP`);return t.today&&(a=`Today, ${a}`),t.selected&&(a=`${a}, selected`),a},labelMonthDropdown:`Choose the Month`,labelNext:`Go to the Next Month`,labelPrevious:`Go to the Previous Month`,labelWeekNumber:e=>`Week ${e}`,labelYearDropdown:`Choose the Year`,labelGrid:(e,t,n)=>{let r;return r=n&&typeof n.format==`function`?n.format.bind(n):(e,n)=>jC(e,n,{locale:rC,...t}),r(e,`LLLL yyyy`)},labelGridcell:(e,t,n,r)=>{let i;i=r&&typeof r.format==`function`?r.format.bind(r):(e,t)=>jC(e,t,{locale:rC,...n});let a=i(e,`PPPP`);return t?.today&&(a=`Today, ${a}`),a},labelNav:`Navigation bar`,labelWeekNumberHeader:`Week Number`,labelWeekday:(e,t,n)=>{let r;return r=n&&typeof n.format==`function`?n.format.bind(n):(e,n)=>jC(e,n,{locale:rC,...t}),r(e,`cccc`)}}},JC=class e{constructor(e,t){this.today=()=>this.overrides?.today?this.overrides.today():this.options.timeZone?cS.tz(this.options.timeZone):new(this.options.Date??Date),this.newDate=(e,t,n)=>this.overrides?.newDate?this.overrides.newDate(e,t,n):this.options.timeZone?new cS(e,t,n,this.options.timeZone):new Date(e,t,n),this.addDays=(e,t)=>this.overrides?.addDays?this.overrides.addDays(e,t):gS(e,t),this.addMonths=(e,t)=>this.overrides?.addMonths?this.overrides.addMonths(e,t):_S(e,t),this.addWeeks=(e,t)=>this.overrides?.addWeeks?this.overrides.addWeeks(e,t):OS(e,t),this.addYears=(e,t)=>this.overrides?.addYears?this.overrides.addYears(e,t):kS(e,t),this.differenceInCalendarDays=(e,t)=>this.overrides?.differenceInCalendarDays?this.overrides.differenceInCalendarDays(e,t):ES(e,t),this.differenceInCalendarMonths=(e,t)=>this.overrides?.differenceInCalendarMonths?this.overrides.differenceInCalendarMonths(e,t):FS(e,t),this.eachMonthOfInterval=e=>this.overrides?.eachMonthOfInterval?this.overrides.eachMonthOfInterval(e):RS(e),this.eachYearOfInterval=e=>{let t=this.overrides?.eachYearOfInterval?this.overrides.eachYearOfInterval(e):HS(e),n=new Set(t.map(e=>this.getYear(e)));if(n.size===t.length)return t;let r=[];return n.forEach(e=>{r.push(new Date(e,0,1))}),r},this.endOfBroadcastWeek=e=>this.overrides?.endOfBroadcastWeek?this.overrides.endOfBroadcastWeek(e):KC(e,this),this.endOfISOWeek=e=>this.overrides?.endOfISOWeek?this.overrides.endOfISOWeek(e):WS(e),this.endOfMonth=e=>this.overrides?.endOfMonth?this.overrides.endOfMonth(e):IS(e),this.endOfWeek=(e,t)=>this.overrides?.endOfWeek?this.overrides.endOfWeek(e,t):US(e,this.options),this.endOfYear=e=>this.overrides?.endOfYear?this.overrides.endOfYear(e):BS(e),this.format=(e,t,n)=>{let r=this.overrides?.format?this.overrides.format(e,t,this.options):jC(e,t,this.options);return this.options.numerals&&this.options.numerals!==`latn`?this.replaceDigits(r):r},this.getISOWeek=e=>this.overrides?.getISOWeek?this.overrides.getISOWeek(e):aC(e),this.getMonth=(e,t)=>this.overrides?.getMonth?this.overrides.getMonth(e,this.options):PC(e,this.options),this.getYear=(e,t)=>this.overrides?.getYear?this.overrides.getYear(e,this.options):FC(e,this.options),this.getWeek=(e,t)=>this.overrides?.getWeek?this.overrides.getWeek(e,this.options):cC(e,this.options),this.isAfter=(e,t)=>this.overrides?.isAfter?this.overrides.isAfter(e,t):IC(e,t),this.isBefore=(e,t)=>this.overrides?.isBefore?this.overrides.isBefore(e,t):LC(e,t),this.isDate=e=>this.overrides?.isDate?this.overrides.isDate(e):NS(e),this.isSameDay=(e,t)=>this.overrides?.isSameDay?this.overrides.isSameDay(e,t):MS(e,t),this.isSameMonth=(e,t)=>this.overrides?.isSameMonth?this.overrides.isSameMonth(e,t):RC(e,t),this.isSameYear=(e,t)=>this.overrides?.isSameYear?this.overrides.isSameYear(e,t):zC(e,t),this.max=e=>this.overrides?.max?this.overrides.max(e):AS(e),this.min=e=>this.overrides?.min?this.overrides.min(e):jS(e),this.setMonth=(e,t)=>this.overrides?.setMonth?this.overrides.setMonth(e,t):BC(e,t),this.setYear=(e,t)=>this.overrides?.setYear?this.overrides.setYear(e,t):VC(e,t),this.startOfBroadcastWeek=(e,t)=>this.overrides?.startOfBroadcastWeek?this.overrides.startOfBroadcastWeek(e,this):GC(e,this),this.startOfDay=e=>this.overrides?.startOfDay?this.overrides.startOfDay(e):TS(e),this.startOfISOWeek=e=>this.overrides?.startOfISOWeek?this.overrides.startOfISOWeek(e):xS(e),this.startOfMonth=e=>this.overrides?.startOfMonth?this.overrides.startOfMonth(e):zS(e),this.startOfWeek=(e,t)=>this.overrides?.startOfWeek?this.overrides.startOfWeek(e,this.options):bS(e,this.options),this.startOfYear=e=>this.overrides?.startOfYear?this.overrides.startOfYear(e):VS(e),this.options={locale:qC,...e},this.overrides=t}getDigitMap(){let{numerals:e=`latn`}=this.options,t=new Intl.NumberFormat(`en-US`,{numberingSystem:e}),n={};for(let e=0;e<10;e++)n[e.toString()]=t.format(e);return n}replaceDigits(e){let t=this.getDigitMap();return e.replace(/\d/g,e=>t[e]||e)}formatNumber(e){return this.replaceDigits(e.toString())}getMonthYearOrder(){let t=this.options.locale?.code;return t&&e.yearFirstLocales.has(t)?`year-first`:`month-first`}formatMonthYear(t){let{locale:n,timeZone:r,numerals:i}=this.options,a=n?.code;if(a&&e.yearFirstLocales.has(a))try{return new Intl.DateTimeFormat(a,{month:`long`,year:`numeric`,timeZone:r,numberingSystem:i}).format(t)}catch{}let o=this.getMonthYearOrder()===`year-first`?`y LLLL`:`LLLL y`;return this.format(t,o)}};JC.yearFirstLocales=new Set([`eu`,`hu`,`ja`,`ja-Hira`,`ja-JP`,`ko`,`ko-KR`,`lt`,`lt-LT`,`lv`,`lv-LV`,`mn`,`mn-MN`,`zh`,`zh-CN`,`zh-HK`,`zh-TW`]);var YC=new JC,XC=class{constructor(e,t,n=YC){this.date=e,this.displayMonth=t,this.outside=!!(t&&!n.isSameMonth(e,t)),this.dateLib=n,this.isoDate=n.format(e,`yyyy-MM-dd`),this.displayMonthId=n.format(t,`yyyy-MM`),this.dateMonthId=n.format(e,`yyyy-MM`)}isEqualTo(e){return this.dateLib.isSameDay(e.date,this.date)&&this.dateLib.isSameMonth(e.displayMonth,this.displayMonth)}},ZC=class{constructor(e,t){this.date=e,this.weeks=t}},QC=class{constructor(e,t){this.days=t,this.weekNumber=e}};function $C(e){return R.createElement(`span`,{...e})}function ew(e){let{size:t=24,orientation:n=`left`,className:r,style:i}=e;return R.createElement(`svg`,{className:r,style:i,width:t,height:t,viewBox:`0 0 24 24`},n===`up`&&R.createElement(`polygon`,{points:`6.77 17 12.5 11.43 18.24 17 20 15.28 12.5 8 5 15.28`}),n===`down`&&R.createElement(`polygon`,{points:`6.77 8 12.5 13.57 18.24 8 20 9.72 12.5 17 5 9.72`}),n===`left`&&R.createElement(`polygon`,{points:`16 18.112 9.81111111 12 16 5.87733333 14.0888889 4 6 12 14.0888889 20`}),n===`right`&&R.createElement(`polygon`,{points:`8 18.112 14.18888889 12 8 5.87733333 9.91111111 4 18 12 9.91111111 20`}))}function tw(e){let{day:t,modifiers:n,...r}=e;return R.createElement(`td`,{...r})}function nw(e){let{day:t,modifiers:n,...r}=e,i=R.useRef(null);return R.useEffect(()=>{n.focused&&i.current?.focus()},[n.focused]),R.createElement(`button`,{ref:i,...r})}var $;(function(e){e.Root=`root`,e.Chevron=`chevron`,e.Day=`day`,e.DayButton=`day_button`,e.CaptionLabel=`caption_label`,e.Dropdowns=`dropdowns`,e.Dropdown=`dropdown`,e.DropdownRoot=`dropdown_root`,e.Footer=`footer`,e.MonthGrid=`month_grid`,e.MonthCaption=`month_caption`,e.MonthsDropdown=`months_dropdown`,e.Month=`month`,e.Months=`months`,e.Nav=`nav`,e.NextMonthButton=`button_next`,e.PreviousMonthButton=`button_previous`,e.Week=`week`,e.Weeks=`weeks`,e.Weekday=`weekday`,e.Weekdays=`weekdays`,e.WeekNumber=`week_number`,e.WeekNumberHeader=`week_number_header`,e.YearsDropdown=`years_dropdown`})($||={});var rw;(function(e){e.disabled=`disabled`,e.hidden=`hidden`,e.outside=`outside`,e.focused=`focused`,e.today=`today`})(rw||={});var iw;(function(e){e.range_end=`range_end`,e.range_middle=`range_middle`,e.range_start=`range_start`,e.selected=`selected`})(iw||={});var aw;(function(e){e.weeks_before_enter=`weeks_before_enter`,e.weeks_before_exit=`weeks_before_exit`,e.weeks_after_enter=`weeks_after_enter`,e.weeks_after_exit=`weeks_after_exit`,e.caption_after_enter=`caption_after_enter`,e.caption_after_exit=`caption_after_exit`,e.caption_before_enter=`caption_before_enter`,e.caption_before_exit=`caption_before_exit`})(aw||={});var ow=(0,R.createContext)(void 0);function sw(){let e=(0,R.useContext)(ow);if(e===void 0)throw Error(`useDayPicker() must be used within a custom component.`);return e}function cw(e){let{options:t,className:n,...r}=e,{classNames:i,components:a,styles:o}=sw(),s=[i[$.Dropdown],n].join(` `),c=t?.find(({value:e})=>e===r.value);return R.createElement(`span`,{"data-disabled":r.disabled,className:i[$.DropdownRoot],style:o?.[$.DropdownRoot]},R.createElement(a.Select,{className:s,...r},t?.map(({value:e,label:t,disabled:n})=>R.createElement(a.Option,{key:e,value:e,disabled:n},t))),R.createElement(`span`,{className:i[$.CaptionLabel],style:o?.[$.CaptionLabel],"aria-hidden":!0},c?.label,R.createElement(a.Chevron,{orientation:`down`,size:18,className:i[$.Chevron],style:o?.[$.Chevron]})))}function lw(e){return R.createElement(`div`,{...e})}function uw(e){return R.createElement(`div`,{...e})}function dw(e){let{calendarMonth:t,displayIndex:n,...r}=e;return R.createElement(`div`,{...r},e.children)}function fw(e){let{calendarMonth:t,displayIndex:n,...r}=e;return R.createElement(`div`,{...r})}function pw(e){return R.createElement(`table`,{...e})}function mw(e){return R.createElement(`div`,{...e})}function hw(e){let{components:t}=sw();return R.createElement(t.Dropdown,{...e})}function gw(e){let{onPreviousClick:t,onNextClick:n,previousMonth:r,nextMonth:i,...a}=e,{components:o,classNames:s,styles:c,labels:{labelPrevious:l,labelNext:u}}=sw(),d=(0,R.useCallback)(e=>{i&&n?.(e)},[i,n]),f=(0,R.useCallback)(e=>{r&&t?.(e)},[r,t]);return R.createElement(`nav`,{...a},R.createElement(o.PreviousMonthButton,{type:`button`,className:s[$.PreviousMonthButton],style:c?.[$.PreviousMonthButton],tabIndex:r?void 0:-1,"aria-disabled":!r||void 0,"aria-label":l(r),onClick:f},R.createElement(o.Chevron,{disabled:!r||void 0,className:s[$.Chevron],style:c?.[$.Chevron],orientation:`left`})),R.createElement(o.NextMonthButton,{type:`button`,className:s[$.NextMonthButton],style:c?.[$.NextMonthButton],tabIndex:i?void 0:-1,"aria-disabled":!i||void 0,"aria-label":u(i),onClick:d},R.createElement(o.Chevron,{disabled:!i||void 0,orientation:`right`,className:s[$.Chevron],style:c?.[$.Chevron]})))}function _w(e){return R.createElement(`button`,{...e})}function vw(e){return R.createElement(`option`,{...e})}function yw(e){return R.createElement(`button`,{...e})}function bw(e){let{rootRef:t,...n}=e;return R.createElement(`div`,{...n,ref:t})}function xw(e){return R.createElement(`select`,{...e})}function Sw(e){let{week:t,...n}=e;return R.createElement(`tr`,{...n})}function Cw(e){return R.createElement(`th`,{...e})}function ww(e){return R.createElement(`thead`,{"aria-hidden":!0},R.createElement(`tr`,{...e}))}function Tw(e){let{week:t,...n}=e;return R.createElement(`th`,{...n})}function Ew(e){return R.createElement(`th`,{...e})}function Dw(e){return R.createElement(`tbody`,{...e})}function Ow(e){let{components:t}=sw();return R.createElement(t.Dropdown,{...e})}var kw=s({CaptionLabel:()=>$C,Chevron:()=>ew,Day:()=>tw,DayButton:()=>nw,Dropdown:()=>cw,DropdownNav:()=>lw,Footer:()=>uw,Month:()=>dw,MonthCaption:()=>fw,MonthGrid:()=>pw,Months:()=>mw,MonthsDropdown:()=>hw,Nav:()=>gw,NextMonthButton:()=>_w,Option:()=>vw,PreviousMonthButton:()=>yw,Root:()=>bw,Select:()=>xw,Week:()=>Sw,WeekNumber:()=>Tw,WeekNumberHeader:()=>Ew,Weekday:()=>Cw,Weekdays:()=>ww,Weeks:()=>Dw,YearsDropdown:()=>Ow});function Aw(e,t,n=!1,r=YC){let{from:i,to:a}=e,{differenceInCalendarDays:o,isSameDay:s}=r;return i&&a?(o(a,i)<0&&([i,a]=[a,i]),o(t,i)>=+!!n&&o(a,t)>=+!!n):!n&&a?s(a,t):!n&&i?s(i,t):!1}function jw(e){return!!(e&&typeof e==`object`&&`before`in e&&`after`in e)}function Mw(e){return!!(e&&typeof e==`object`&&`from`in e)}function Nw(e){return!!(e&&typeof e==`object`&&`after`in e)}function Pw(e){return!!(e&&typeof e==`object`&&`before`in e)}function Fw(e){return!!(e&&typeof e==`object`&&`dayOfWeek`in e)}function Iw(e,t){return Array.isArray(e)&&e.every(t.isDate)}function Lw(e,t,n=YC){let r=Array.isArray(t)?t:[t],{isSameDay:i,differenceInCalendarDays:a,isAfter:o}=n;return r.some(t=>{if(typeof t==`boolean`)return t;if(n.isDate(t))return i(e,t);if(Iw(t,n))return t.some(t=>i(e,t));if(Mw(t))return Aw(t,e,!1,n);if(Fw(t))return Array.isArray(t.dayOfWeek)?t.dayOfWeek.includes(e.getDay()):t.dayOfWeek===e.getDay();if(jw(t)){let n=a(t.before,e),r=a(t.after,e),i=n>0,s=r<0;return o(t.before,t.after)?s&&i:i||s}return Nw(t)?a(e,t.after)>0:Pw(t)?a(t.before,e)>0:typeof t==`function`&&t(e)})}function Rw(e,t,n,r,i){let{disabled:a,hidden:o,modifiers:s,showOutsideDays:c,broadcastCalendar:l,today:u=i.today()}=t,{isSameDay:d,isSameMonth:f,startOfMonth:p,isBefore:m,endOfMonth:h,isAfter:g}=i,_=n&&p(n),v=r&&h(r),y={[rw.focused]:[],[rw.outside]:[],[rw.disabled]:[],[rw.hidden]:[],[rw.today]:[]},b={};for(let t of e){let{date:e,displayMonth:n}=t,r=!!(n&&!f(e,n)),p=!!(_&&m(e,_)),h=!!(v&&g(e,v)),x=!!(a&&Lw(e,a,i)),S=!!(o&&Lw(e,o,i))||p||h||!l&&!c&&r||l&&c===!1&&r,C=d(e,u);r&&y.outside.push(t),x&&y.disabled.push(t),S&&y.hidden.push(t),C&&y.today.push(t),s&&Object.keys(s).forEach(n=>{let r=s?.[n];r&&Lw(e,r,i)&&(b[n]?b[n].push(t):b[n]=[t])})}return e=>{let t={[rw.focused]:!1,[rw.disabled]:!1,[rw.hidden]:!1,[rw.outside]:!1,[rw.today]:!1},n={};for(let n in y)t[n]=y[n].some(t=>t===e);for(let t in b)n[t]=b[t].some(t=>t===e);return{...t,...n}}}function zw(e,t,n={}){return Object.entries(e).filter(([,e])=>e===!0).reduce((e,[r])=>(n[r]?e.push(n[r]):t[rw[r]]?e.push(t[rw[r]]):t[iw[r]]&&e.push(t[iw[r]]),e),[t[$.Day]])}function Bw(e){return{...kw,...e}}function Vw(e){let t={"data-mode":e.mode??void 0,"data-required":`required`in e?e.required:void 0,"data-multiple-months":e.numberOfMonths&&e.numberOfMonths>1||void 0,"data-week-numbers":e.showWeekNumber||void 0,"data-broadcast-calendar":e.broadcastCalendar||void 0,"data-nav-layout":e.navLayout||void 0};return Object.entries(e).forEach(([e,n])=>{e.startsWith(`data-`)&&(t[e]=n)}),t}function Hw(){let e={};for(let t in $)e[$[t]]=`rdp-${$[t]}`;for(let t in rw)e[rw[t]]=`rdp-${rw[t]}`;for(let t in iw)e[iw[t]]=`rdp-${iw[t]}`;for(let t in aw)e[aw[t]]=`rdp-${aw[t]}`;return e}function Uw(e,t,n){return(n??new JC(t)).formatMonthYear(e)}function Ww(e,t,n){return(n??new JC(t)).format(e,`d`)}function Gw(e,t=YC){return t.format(e,`LLLL`)}function Kw(e,t,n){return(n??new JC(t)).format(e,`cccccc`)}function qw(e,t=YC){return e<10?t.formatNumber(`0${e.toLocaleString()}`):t.formatNumber(`${e.toLocaleString()}`)}function Jw(){return``}function Yw(e,t=YC){return t.format(e,`yyyy`)}var Xw=s({formatCaption:()=>Uw,formatDay:()=>Ww,formatMonthDropdown:()=>Gw,formatWeekNumber:()=>qw,formatWeekNumberHeader:()=>Jw,formatWeekdayName:()=>Kw,formatYearDropdown:()=>Yw});function Zw(e){return{...Xw,...e}}function Qw(e,t,n,r){let i=(r??new JC(n)).format(e,`PPPP`);return t.today&&(i=`Today, ${i}`),t.selected&&(i=`${i}, selected`),i}function $w(e,t,n){return(n??new JC(t)).formatMonthYear(e)}function eT(e,t,n,r){let i=(r??new JC(n)).format(e,`PPPP`);return t?.today&&(i=`Today, ${i}`),i}function tT(e){return`Choose the Month`}function nT(){return``}var rT=`Go to the Next Month`;function iT(e,t){return rT}function aT(e){return`Go to the Previous Month`}function oT(e,t,n){return(n??new JC(t)).format(e,`cccc`)}function sT(e,t){return`Week ${e}`}function cT(e){return`Week Number`}function lT(e){return`Choose the Year`}var uT=s({labelDayButton:()=>Qw,labelGrid:()=>$w,labelGridcell:()=>eT,labelMonthDropdown:()=>tT,labelNav:()=>nT,labelNext:()=>iT,labelPrevious:()=>aT,labelWeekNumber:()=>sT,labelWeekNumberHeader:()=>cT,labelWeekday:()=>oT,labelYearDropdown:()=>lT}),dT=(e,t,n)=>t||(n?typeof n==`function`?n:(...e)=>n:e);function fT(e,t){let n=t.locale?.labels??{};return{...uT,...e??{},labelDayButton:dT(Qw,e?.labelDayButton,n.labelDayButton),labelMonthDropdown:dT(tT,e?.labelMonthDropdown,n.labelMonthDropdown),labelNext:dT(iT,e?.labelNext,n.labelNext),labelPrevious:dT(aT,e?.labelPrevious,n.labelPrevious),labelWeekNumber:dT(sT,e?.labelWeekNumber,n.labelWeekNumber),labelYearDropdown:dT(lT,e?.labelYearDropdown,n.labelYearDropdown),labelGrid:dT($w,e?.labelGrid,n.labelGrid),labelGridcell:dT(eT,e?.labelGridcell,n.labelGridcell),labelNav:dT(nT,e?.labelNav,n.labelNav),labelWeekNumberHeader:dT(cT,e?.labelWeekNumberHeader,n.labelWeekNumberHeader),labelWeekday:dT(oT,e?.labelWeekday,n.labelWeekday)}}function pT(e,t,n,r,i){let{startOfMonth:a,startOfYear:o,endOfYear:s,eachMonthOfInterval:c,getMonth:l}=i;return c({start:o(e),end:s(e)}).map(e=>{let o=r.formatMonthDropdown(e,i);return{value:l(e),label:o,disabled:t&&e<a(t)||n&&e>a(n)||!1}})}function mT(e,t={},n={}){let r={...t?.[$.Day]};return Object.entries(e).filter(([,e])=>e===!0).forEach(([e])=>{r={...r,...n?.[e]}}),r}function hT(e,t,n,r){let i=r??e.today(),a=n?e.startOfBroadcastWeek(i,e):t?e.startOfISOWeek(i):e.startOfWeek(i),o=[];for(let t=0;t<7;t++){let n=e.addDays(a,t);o.push(n)}return o}function gT(e,t,n,r,i=!1){if(!e||!t)return;let{startOfYear:a,endOfYear:o,eachYearOfInterval:s,getYear:c}=r,l=s({start:a(e),end:o(t)});return i&&l.reverse(),l.map(e=>{let t=n.formatYearDropdown(e,r);return{value:c(e),label:t,disabled:!1}})}function _T(e,t={}){let{weekStartsOn:n,locale:r}=t,i=n??r?.options?.weekStartsOn??0,a=t=>{let n=typeof t==`number`||typeof t==`string`?new Date(t):t;return new cS(n.getFullYear(),n.getMonth(),n.getDate(),12,0,0,e)},o=e=>{let t=a(e);return new Date(t.getFullYear(),t.getMonth(),t.getDate(),0,0,0,0)};return{today:()=>a(cS.tz(e)),newDate:(t,n,r)=>new cS(t,n,r,12,0,0,e),startOfDay:e=>a(e),startOfWeek:(e,t)=>{let n=a(e),r=t?.weekStartsOn??i,o=(n.getDay()-r+7)%7;return n.setDate(n.getDate()-o),n},startOfISOWeek:e=>{let t=a(e),n=(t.getDay()-1+7)%7;return t.setDate(t.getDate()-n),t},startOfMonth:e=>{let t=a(e);return t.setDate(1),t},startOfYear:e=>{let t=a(e);return t.setMonth(0,1),t},endOfWeek:(e,t)=>{let n=a(e),r=(((t?.weekStartsOn??i)+6)%7-n.getDay()+7)%7;return n.setDate(n.getDate()+r),n},endOfISOWeek:e=>{let t=a(e),n=(7-t.getDay())%7;return t.setDate(t.getDate()+n),t},endOfMonth:e=>{let t=a(e);return t.setMonth(t.getMonth()+1,0),t},endOfYear:e=>{let t=a(e);return t.setMonth(11,31),t},eachMonthOfInterval:t=>{let n=a(t.start),r=a(t.end),i=[],o=new cS(n.getFullYear(),n.getMonth(),1,12,0,0,e),s=r.getFullYear()*12+r.getMonth();for(;o.getFullYear()*12+o.getMonth()<=s;)i.push(new cS(o,e)),o.setMonth(o.getMonth()+1,1);return i},addDays:(e,t)=>{let n=a(e);return n.setDate(n.getDate()+t),n},addWeeks:(e,t)=>{let n=a(e);return n.setDate(n.getDate()+t*7),n},addMonths:(e,t)=>{let n=a(e);return n.setMonth(n.getMonth()+t),n},addYears:(e,t)=>{let n=a(e);return n.setFullYear(n.getFullYear()+t),n},eachYearOfInterval:t=>{let n=a(t.start),r=a(t.end),i=[],o=new cS(n.getFullYear(),0,1,12,0,0,e);for(;o.getFullYear()<=r.getFullYear();)i.push(new cS(o,e)),o.setFullYear(o.getFullYear()+1,0,1);return i},getWeek:(e,t)=>cC(o(e),{weekStartsOn:t?.weekStartsOn??i,firstWeekContainsDate:t?.firstWeekContainsDate??r?.options?.firstWeekContainsDate??1}),getISOWeek:e=>aC(o(e)),differenceInCalendarDays:(e,t)=>ES(o(e),o(t)),differenceInCalendarMonths:(e,t)=>FS(o(e),o(t))}}var vT=e=>e instanceof HTMLElement?e:null,yT=e=>[...e.querySelectorAll(`[data-animated-month]`)??[]],bT=e=>vT(e.querySelector(`[data-animated-month]`)),xT=e=>vT(e.querySelector(`[data-animated-caption]`)),ST=e=>vT(e.querySelector(`[data-animated-weeks]`)),CT=e=>vT(e.querySelector(`[data-animated-nav]`)),wT=e=>vT(e.querySelector(`[data-animated-weekdays]`));function TT(e,t,{classNames:n,months:r,focused:i,dateLib:a}){let o=(0,R.useRef)(null),s=(0,R.useRef)(r),c=(0,R.useRef)(!1);(0,R.useLayoutEffect)(()=>{let l=s.current;if(s.current=r,!t||!e.current||!(e.current instanceof HTMLElement)||r.length===0||l.length===0||r.length!==l.length)return;let u=a.isSameMonth(r[0].date,l[0].date),d=a.isAfter(r[0].date,l[0].date),f=d?n[aw.caption_after_enter]:n[aw.caption_before_enter],p=d?n[aw.weeks_after_enter]:n[aw.weeks_before_enter],m=o.current,h=e.current.cloneNode(!0);if(h instanceof HTMLElement?(yT(h).forEach(e=>{if(!(e instanceof HTMLElement))return;let t=bT(e);t&&e.contains(t)&&e.removeChild(t);let n=xT(e);n&&n.classList.remove(f);let r=ST(e);r&&r.classList.remove(p)}),o.current=h):o.current=null,c.current||u||i)return;let g=m instanceof HTMLElement?yT(m):[],_=yT(e.current);if(_?.every(e=>e instanceof HTMLElement)&&g?.every(e=>e instanceof HTMLElement)){c.current=!0;let t=[];e.current.style.isolation=`isolate`;let r=CT(e.current);r&&(r.style.zIndex=`1`),_.forEach((i,a)=>{let o=g[a];if(!o)return;i.style.position=`relative`,i.style.overflow=`hidden`;let s=xT(i);s&&s.classList.add(f);let l=ST(i);l&&l.classList.add(p);let u=()=>{c.current=!1,e.current&&(e.current.style.isolation=``),r&&(r.style.zIndex=``),s&&s.classList.remove(f),l&&l.classList.remove(p),i.style.position=``,i.style.overflow=``,i.contains(o)&&i.removeChild(o)};t.push(u),o.style.pointerEvents=`none`,o.style.position=`absolute`,o.style.overflow=`hidden`,o.setAttribute(`aria-hidden`,`true`);let m=wT(o);m&&(m.style.opacity=`0`);let h=xT(o);h&&(h.classList.add(d?n[aw.caption_before_exit]:n[aw.caption_after_exit]),h.addEventListener(`animationend`,u));let _=ST(o);_&&_.classList.add(d?n[aw.weeks_before_exit]:n[aw.weeks_after_exit]),i.insertBefore(o,i.firstChild)})}})}function ET(e,t,n,r){let i=e[0],a=e[e.length-1],{ISOWeek:o,fixedWeeks:s,broadcastCalendar:c}=n??{},{addDays:l,differenceInCalendarDays:u,differenceInCalendarMonths:d,endOfBroadcastWeek:f,endOfISOWeek:p,endOfMonth:m,endOfWeek:h,isAfter:g,startOfBroadcastWeek:_,startOfISOWeek:v,startOfWeek:y}=r,b=c?_(i,r):o?v(i):y(i),x=c?f(a):o?p(m(a)):h(m(a)),S=t&&(c?f(t):o?p(t):h(t)),C=u(S&&g(x,S)?S:x,b),w=d(a,i)+1,T=[];for(let e=0;e<=C;e++){let t=l(b,e);T.push(t)}let E=(c?35:42)*w;if(s&&T.length<E){let e=E-T.length;for(let t=0;t<e;t++){let e=l(T[T.length-1],1);T.push(e)}}return T}function DT(e){let t=[];return e.reduce((e,n)=>{let r=n.weeks.reduce((e,t)=>e.concat(t.days.slice()),t.slice());return e.concat(r.slice())},t.slice())}function OT(e,t,n,r){let{numberOfMonths:i=1}=n,a=[];for(let n=0;n<i;n++){let i=r.addMonths(e,n);if(t&&i>t)break;a.push(i)}return a}function kT(e,t,n,r){let{month:i,defaultMonth:a,today:o=r.today(),numberOfMonths:s=1}=e,c=i||a||o,{differenceInCalendarMonths:l,addMonths:u,startOfMonth:d}=r;return n&&l(n,c)<s-1&&(c=u(n,-1*(s-1))),t&&l(c,t)<0&&(c=t),d(c)}function AT(e,t,n,r){let{addDays:i,endOfBroadcastWeek:a,endOfISOWeek:o,endOfMonth:s,endOfWeek:c,getISOWeek:l,getWeek:u,startOfBroadcastWeek:d,startOfISOWeek:f,startOfWeek:p}=r,m=e.reduce((e,m)=>{let h=n.broadcastCalendar?d(m,r):n.ISOWeek?f(m):p(m),g=n.broadcastCalendar?a(m):n.ISOWeek?o(s(m)):c(s(m)),_=t.filter(e=>e>=h&&e<=g),v=n.broadcastCalendar?35:42;if(n.fixedWeeks&&_.length<v){let e=t.filter(e=>{let t=v-_.length;return e>g&&e<=i(g,t)});_.push(...e)}let y=new ZC(m,_.reduce((e,t)=>{let i=n.ISOWeek?l(t):u(t),a=e.find(e=>e.weekNumber===i),o=new XC(t,m,r);return a?a.days.push(o):e.push(new QC(i,[o])),e},[]));return e.push(y),e},[]);return n.reverseMonths?m.reverse():m}function jT(e,t){let{startMonth:n,endMonth:r}=e,{startOfYear:i,startOfDay:a,startOfMonth:o,endOfMonth:s,addYears:c,endOfYear:l,today:u}=t,d=e.captionLayout===`dropdown`||e.captionLayout===`dropdown-years`;return n?n=o(n):!n&&d&&(n=i(c(e.today??u(),-100))),r?r=s(r):!r&&d&&(r=l(e.today??u())),[n&&a(n),r&&a(r)]}function MT(e,t,n,r){if(n.disableNavigation)return;let{pagedNavigation:i,numberOfMonths:a=1}=n,{startOfMonth:o,addMonths:s,differenceInCalendarMonths:c}=r,l=i?a:1,u=o(e);if(!t||!(c(t,e)<a))return s(u,l)}function NT(e,t,n,r){if(n.disableNavigation)return;let{pagedNavigation:i,numberOfMonths:a}=n,{startOfMonth:o,addMonths:s,differenceInCalendarMonths:c}=r,l=i?a??1:1,u=o(e);if(!t||!(c(u,t)<=0))return s(u,-l)}function PT(e){return e.reduce((e,t)=>e.concat(t.weeks.slice()),[].slice())}function FT(e,t){let[n,r]=(0,R.useState)(e);return[t===void 0?n:t,r]}function IT(e,t){let[n,r]=jT(e,t),{startOfMonth:i,endOfMonth:a}=t,o=kT(e,n,r,t),[s,c]=FT(o,e.month?o:void 0);(0,R.useEffect)(()=>{let i=kT(e,n,r,t);c(i)},[e.timeZone]);let{months:l,weeks:u,days:d,previousMonth:f,nextMonth:p}=(0,R.useMemo)(()=>{let i=OT(s,r,{numberOfMonths:e.numberOfMonths},t),o=AT(i,ET(i,e.endMonth?a(e.endMonth):void 0,{ISOWeek:e.ISOWeek,fixedWeeks:e.fixedWeeks,broadcastCalendar:e.broadcastCalendar},t),{broadcastCalendar:e.broadcastCalendar,fixedWeeks:e.fixedWeeks,ISOWeek:e.ISOWeek,reverseMonths:e.reverseMonths},t);return{months:o,weeks:PT(o),days:DT(o),previousMonth:NT(s,n,e,t),nextMonth:MT(s,r,e,t)}},[t,s.getTime(),r?.getTime(),n?.getTime(),e.disableNavigation,e.broadcastCalendar,e.endMonth?.getTime(),e.fixedWeeks,e.ISOWeek,e.numberOfMonths,e.pagedNavigation,e.reverseMonths]),{disableNavigation:m,onMonthChange:h}=e,g=e=>u.some(t=>t.days.some(t=>t.isEqualTo(e))),_=e=>{if(m)return;let t=i(e);n&&t<i(n)&&(t=i(n)),r&&t>i(r)&&(t=i(r)),c(t),h?.(t)};return{months:l,weeks:u,days:d,navStart:n,navEnd:r,previousMonth:f,nextMonth:p,goToMonth:_,goToDay:e=>{g(e)||_(e.date)}}}var LT;(function(e){e[e.Today=0]=`Today`,e[e.Selected=1]=`Selected`,e[e.LastFocused=2]=`LastFocused`,e[e.FocusedModifier=3]=`FocusedModifier`})(LT||={});function RT(e){return!e[rw.disabled]&&!e[rw.hidden]&&!e[rw.outside]}function zT(e,t,n,r){let i,a=-1;for(let o of e){let e=t(o);RT(e)&&(e[rw.focused]&&a<LT.FocusedModifier?(i=o,a=LT.FocusedModifier):r?.isEqualTo(o)&&a<LT.LastFocused?(i=o,a=LT.LastFocused):n(o.date)&&a<LT.Selected?(i=o,a=LT.Selected):e[rw.today]&&a<LT.Today&&(i=o,a=LT.Today))}return i||=e.find(e=>RT(t(e))),i}function BT(e,t,n,r,i,a,o){let{ISOWeek:s,broadcastCalendar:c}=a,{addDays:l,addMonths:u,addWeeks:d,addYears:f,endOfBroadcastWeek:p,endOfISOWeek:m,endOfWeek:h,max:g,min:_,startOfBroadcastWeek:v,startOfISOWeek:y,startOfWeek:b}=o,x={day:l,week:d,month:u,year:f,startOfWeek:e=>c?v(e,o):s?y(e):b(e),endOfWeek:e=>c?p(e):s?m(e):h(e)}[e](n,t===`after`?1:-1);return t===`before`&&r?x=g([r,x]):t===`after`&&i&&(x=_([i,x])),x}function VT(e,t,n,r,i,a,o,s=0){if(s>365)return;let c=BT(e,t,n.date,r,i,a,o),l=!!(a.disabled&&Lw(c,a.disabled,o)),u=!!(a.hidden&&Lw(c,a.hidden,o)),d=new XC(c,c,o);return!l&&!u?d:VT(e,t,d,r,i,a,o,s+1)}function HT(e,t,n,r,i){let{autoFocus:a}=e,[o,s]=(0,R.useState)(),c=zT(t.days,n,r||(()=>!1),o),[l,u]=(0,R.useState)(a?c:void 0);return{isFocusTarget:e=>!!c?.isEqualTo(e),setFocused:u,focused:l,blur:()=>{s(l),u(void 0)},moveFocus:(n,r)=>{if(!l)return;let a=VT(n,r,l,t.navStart,t.navEnd,e,i);a&&(e.disableNavigation&&!t.days.some(e=>e.isEqualTo(a))||(t.goToDay(a),u(a)))}}}function UT(e,t){let{selected:n,required:r,onSelect:i}=e,[a,o]=FT(n,i?n:void 0),s=i?n:a,{isSameDay:c}=t,l=e=>s?.some(t=>c(t,e))??!1,{min:u,max:d}=e;return{selected:s,select:(e,t,n)=>{let a=[...s??[]];if(l(e)){if(s?.length===u||r&&s?.length===1)return;a=s?.filter(t=>!c(t,e))}else a=s?.length===d?[e]:[...a,e];return i||o(a),i?.(a,e,t,n),a},isSelected:l}}function WT(e,t,n=0,r=0,i=!1,a=YC){let{from:o,to:s}=t||{},{isSameDay:c,isAfter:l,isBefore:u}=a,d;if(!o&&!s)d={from:e,to:n>0?void 0:e};else if(o&&!s)d=c(o,e)?n===0?{from:o,to:e}:i?{from:o,to:void 0}:void 0:u(e,o)?{from:e,to:o}:{from:o,to:e};else if(o&&s){if(c(o,e)&&c(s,e))d=i?{from:o,to:s}:void 0;else if(c(o,e))d={from:o,to:n>0?void 0:e};else if(c(s,e))d={from:e,to:n>0?void 0:e};else if(u(e,o))d={from:e,to:s};else if(l(e,o))d={from:o,to:e};else if(l(e,s))d={from:o,to:e};else throw Error(`Invalid range`)}if(d?.from&&d?.to){let t=a.differenceInCalendarDays(d.to,d.from);(r>0&&t>r||n>1&&t<n)&&(d={from:e,to:void 0})}return d}function GT(e,t,n=YC){let r=Array.isArray(t)?t:[t],i=e.from,a=n.differenceInCalendarDays(e.to,e.from),o=Math.min(a,6);for(let e=0;e<=o;e++){if(r.includes(i.getDay()))return!0;i=n.addDays(i,1)}return!1}function KT(e,t,n=YC){return Aw(e,t.from,!1,n)||Aw(e,t.to,!1,n)||Aw(t,e.from,!1,n)||Aw(t,e.to,!1,n)}function qT(e,t,n=YC){let r=Array.isArray(t)?t:[t];if(r.filter(e=>typeof e!=`function`).some(t=>typeof t==`boolean`?t:n.isDate(t)?Aw(e,t,!1,n):Iw(t,n)?t.some(t=>Aw(e,t,!1,n)):Mw(t)?t.from&&t.to?KT(e,{from:t.from,to:t.to},n):!1:Fw(t)?GT(e,t.dayOfWeek,n):jw(t)?n.isAfter(t.before,t.after)?KT(e,{from:n.addDays(t.after,1),to:n.addDays(t.before,-1)},n):Lw(e.from,t,n)||Lw(e.to,t,n):Nw(t)||Pw(t)?Lw(e.from,t,n)||Lw(e.to,t,n):!1))return!0;let i=r.filter(e=>typeof e==`function`);if(i.length){let t=e.from,r=n.differenceInCalendarDays(e.to,e.from);for(let e=0;e<=r;e++){if(i.some(e=>e(t)))return!0;t=n.addDays(t,1)}}return!1}function JT(e,t){let{disabled:n,excludeDisabled:r,resetOnSelect:i,selected:a,required:o,onSelect:s}=e,[c,l]=FT(a,s?a:void 0),u=s?a:c;return{selected:u,select:(a,c,d)=>{let{min:f,max:p}=e,m;if(a){let e=u?.from,n=u?.to,r=!!e&&!!n,s=!!e&&!!n&&t.isSameDay(e,n)&&t.isSameDay(a,e);m=i&&(r||!u?.from)?!o&&s?void 0:{from:a,to:void 0}:WT(a,u,f,p,o,t)}return r&&n&&m?.from&&m.to&&qT({from:m.from,to:m.to},n,t)&&(m.from=a,m.to=void 0),s||l(m),s?.(m,a,c,d),m},isSelected:e=>u&&Aw(u,e,!1,t)}}function YT(e,t){let{selected:n,required:r,onSelect:i}=e,[a,o]=FT(n,i?n:void 0),s=i?n:a,{isSameDay:c}=t;return{selected:s,select:(e,t,n)=>{let a=e;return!r&&s&&s&&c(e,s)&&(a=void 0),i||o(a),i?.(a,e,t,n),a},isSelected:e=>s?c(s,e):!1}}function XT(e,t){let n=YT(e,t),r=UT(e,t),i=JT(e,t);switch(e.mode){case`single`:return n;case`multiple`:return r;case`range`:return i;default:return}}function ZT(e,t){return e instanceof cS&&e.timeZone===t?e:new cS(e,t)}function QT(e,t,n){if(!n)return ZT(e,t);let r=ZT(e,t),i=new cS(r.getFullYear(),r.getMonth(),r.getDate(),12,0,0,t);return new Date(i.getTime())}function $T(e,t,n){return typeof e==`boolean`||typeof e==`function`?e:e instanceof Date?QT(e,t,n):Array.isArray(e)?e.map(e=>e instanceof Date?QT(e,t,n):e):Mw(e)?{...e,from:e.from?ZT(e.from,t):e.from,to:e.to?ZT(e.to,t):e.to}:jw(e)?{before:QT(e.before,t,n),after:QT(e.after,t,n)}:Nw(e)?{after:QT(e.after,t,n)}:Pw(e)?{before:QT(e.before,t,n)}:e}function eE(e,t,n){return e&&(Array.isArray(e)?e.map(e=>$T(e,t,n)):$T(e,t,n))}function tE(e){let t=e,n=t.timeZone;if(n&&(t={...e,timeZone:n},t.today&&(t.today=ZT(t.today,n)),t.month&&(t.month=ZT(t.month,n)),t.defaultMonth&&(t.defaultMonth=ZT(t.defaultMonth,n)),t.startMonth&&(t.startMonth=ZT(t.startMonth,n)),t.endMonth&&(t.endMonth=ZT(t.endMonth,n)),t.mode===`single`&&t.selected?t.selected=ZT(t.selected,n):t.mode===`multiple`&&t.selected?t.selected=t.selected?.map(e=>ZT(e,n)):t.mode===`range`&&t.selected&&(t.selected={from:t.selected.from?ZT(t.selected.from,n):t.selected.from,to:t.selected.to?ZT(t.selected.to,n):t.selected.to}),t.disabled!==void 0&&(t.disabled=eE(t.disabled,n)),t.hidden!==void 0&&(t.hidden=eE(t.hidden,n)),t.modifiers)){let e={};Object.keys(t.modifiers).forEach(r=>{e[r]=eE(t.modifiers?.[r],n)}),t.modifiers=e}let{components:r,formatters:i,labels:a,dateLib:o,locale:s,classNames:c}=(0,R.useMemo)(()=>{let e={...qC,...t.locale},n=t.broadcastCalendar?1:t.weekStartsOn,r=t.noonSafe&&t.timeZone?_T(t.timeZone,{weekStartsOn:n,locale:e}):void 0,i=t.dateLib&&r?{...r,...t.dateLib}:t.dateLib??r,a=new JC({locale:e,weekStartsOn:n,firstWeekContainsDate:t.firstWeekContainsDate,useAdditionalWeekYearTokens:t.useAdditionalWeekYearTokens,useAdditionalDayOfYearTokens:t.useAdditionalDayOfYearTokens,timeZone:t.timeZone,numerals:t.numerals},i);return{dateLib:a,components:Bw(t.components),formatters:Zw(t.formatters),labels:fT(t.labels,a.options),locale:e,classNames:{...Hw(),...t.classNames}}},[t.locale,t.broadcastCalendar,t.weekStartsOn,t.firstWeekContainsDate,t.useAdditionalWeekYearTokens,t.useAdditionalDayOfYearTokens,t.timeZone,t.numerals,t.dateLib,t.noonSafe,t.components,t.formatters,t.labels,t.classNames]);t.today||(t={...t,today:o.today()});let{captionLayout:l,mode:u,navLayout:d,numberOfMonths:f=1,onDayBlur:p,onDayClick:m,onDayFocus:h,onDayKeyDown:g,onDayMouseEnter:_,onDayMouseLeave:v,onNextClick:y,onPrevClick:b,showWeekNumber:x,styles:S}=t,{formatCaption:C,formatDay:w,formatMonthDropdown:T,formatWeekNumber:E,formatWeekNumberHeader:ee,formatWeekdayName:D,formatYearDropdown:O}=i,k=IT(t,o),{days:A,months:j,navStart:M,navEnd:N,previousMonth:te,nextMonth:P,goToMonth:F}=k,ne=Rw(A,t,M,N,o),{isSelected:re,select:ie,selected:ae}=XT(t,o)??{},{blur:I,focused:L,isFocusTarget:oe,moveFocus:se,setFocused:ce}=HT(t,k,ne,re??(()=>!1),o),{labelDayButton:le,labelGridcell:ue,labelGrid:de,labelMonthDropdown:fe,labelNav:pe,labelPrevious:me,labelNext:he,labelWeekday:ge,labelWeekNumber:_e,labelWeekNumberHeader:ve,labelYearDropdown:ye}=a,be=(0,R.useMemo)(()=>hT(o,t.ISOWeek,t.broadcastCalendar,t.today),[o,t.ISOWeek,t.broadcastCalendar,t.today]),xe=u!==void 0||m!==void 0,Se=(0,R.useCallback)(()=>{te&&(F(te),b?.(te))},[te,F,b]),Ce=(0,R.useCallback)(()=>{P&&(F(P),y?.(P))},[F,P,y]),we=(0,R.useCallback)((e,t)=>n=>{n.preventDefault(),n.stopPropagation(),ce(e),!t.disabled&&(ie?.(e.date,t,n),m?.(e.date,t,n))},[ie,m,ce]),Te=(0,R.useCallback)((e,t)=>n=>{ce(e),h?.(e.date,t,n)},[h,ce]),Ee=(0,R.useCallback)((e,t)=>n=>{I(),p?.(e.date,t,n)},[I,p]),De=(0,R.useCallback)((e,n)=>r=>{let i={ArrowLeft:[r.shiftKey?`month`:`day`,t.dir===`rtl`?`after`:`before`],ArrowRight:[r.shiftKey?`month`:`day`,t.dir===`rtl`?`before`:`after`],ArrowDown:[r.shiftKey?`year`:`week`,`after`],ArrowUp:[r.shiftKey?`year`:`week`,`before`],PageUp:[r.shiftKey?`year`:`month`,`before`],PageDown:[r.shiftKey?`year`:`month`,`after`],Home:[`startOfWeek`,`before`],End:[`endOfWeek`,`after`]};if(i[r.key]){r.preventDefault(),r.stopPropagation();let[e,t]=i[r.key];se(e,t)}g?.(e.date,n,r)},[se,g,t.dir]),Oe=(0,R.useCallback)((e,t)=>n=>{_?.(e.date,t,n)},[_]),ke=(0,R.useCallback)((e,t)=>n=>{v?.(e.date,t,n)},[v]),Ae=(0,R.useCallback)((e,t)=>n=>{let r=Number(n.target.value),i=o.setMonth(o.startOfMonth(e),r);F(o.addMonths(i,-t))},[o,F]),je=(0,R.useCallback)((e,t)=>n=>{let r=Number(n.target.value),i=o.setYear(o.startOfMonth(e),r);F(o.addMonths(i,-t))},[o,F]),{className:Me,style:Ne}=(0,R.useMemo)(()=>({className:[c[$.Root],t.className].filter(Boolean).join(` `),style:{...S?.[$.Root],...t.style}}),[c,t.className,t.style,S]),Pe=Vw(t),Fe=e=>{let t=S?.[$.Dropdown],n=S?.[e];if(!(!t&&!n))return{...t,...n}},Ie=(0,R.useRef)(null);TT(Ie,!!t.animate,{classNames:c,months:j,focused:L,dateLib:o});let Le={dayPickerProps:t,selected:ae,select:ie,isSelected:re,months:j,nextMonth:P,previousMonth:te,goToMonth:F,getModifiers:ne,components:r,classNames:c,styles:S,labels:a,formatters:i};return R.createElement(ow.Provider,{value:Le},R.createElement(r.Root,{rootRef:t.animate?Ie:void 0,className:Me,style:Ne,dir:t.dir,id:t.id,lang:t.lang??s.code,nonce:t.nonce,title:t.title,role:t.role,"aria-label":t[`aria-label`],"aria-labelledby":t[`aria-labelledby`],...Pe},R.createElement(r.Months,{className:c[$.Months],style:S?.[$.Months]},!t.hideNavigation&&!d&&R.createElement(r.Nav,{"data-animated-nav":t.animate?`true`:void 0,className:c[$.Nav],style:S?.[$.Nav],"aria-label":pe(),onPreviousClick:Se,onNextClick:Ce,previousMonth:te,nextMonth:P}),j.map((e,n)=>{let a=t.reverseMonths?j.length-1-n:n;return R.createElement(r.Month,{"data-animated-month":t.animate?`true`:void 0,className:c[$.Month],style:S?.[$.Month],key:n,displayIndex:n,calendarMonth:e},d===`around`&&!t.hideNavigation&&n===0&&R.createElement(r.PreviousMonthButton,{type:`button`,className:c[$.PreviousMonthButton],style:S?.[$.PreviousMonthButton],tabIndex:te?void 0:-1,"aria-disabled":!te||void 0,"aria-label":me(te),onClick:Se,"data-animated-button":t.animate?`true`:void 0},R.createElement(r.Chevron,{disabled:!te||void 0,className:c[$.Chevron],style:S?.[$.Chevron],orientation:t.dir===`rtl`?`right`:`left`})),R.createElement(r.MonthCaption,{"data-animated-caption":t.animate?`true`:void 0,className:c[$.MonthCaption],style:S?.[$.MonthCaption],calendarMonth:e,displayIndex:n},l?.startsWith(`dropdown`)?R.createElement(r.DropdownNav,{className:c[$.Dropdowns],style:S?.[$.Dropdowns]},(()=>{let n=l===`dropdown`||l===`dropdown-months`?R.createElement(r.MonthsDropdown,{key:`month`,className:c[$.MonthsDropdown],"aria-label":fe(),disabled:!!t.disableNavigation,onChange:Ae(e.date,a),options:pT(e.date,M,N,i,o),style:Fe($.MonthsDropdown),value:o.getMonth(e.date)}):R.createElement(`span`,{key:`month`},T(e.date,o)),s=l===`dropdown`||l===`dropdown-years`?R.createElement(r.YearsDropdown,{key:`year`,className:c[$.YearsDropdown],"aria-label":ye(o.options),disabled:!!t.disableNavigation,onChange:je(e.date,a),options:gT(M,N,i,o,!!t.reverseYears),style:Fe($.YearsDropdown),value:o.getYear(e.date)}):R.createElement(`span`,{key:`year`},O(e.date,o));return o.getMonthYearOrder()===`year-first`?[s,n]:[n,s]})(),R.createElement(`span`,{role:`status`,"aria-live":`polite`,style:{border:0,clip:`rect(0 0 0 0)`,height:`1px`,margin:`-1px`,overflow:`hidden`,padding:0,position:`absolute`,width:`1px`,whiteSpace:`nowrap`,wordWrap:`normal`}},C(e.date,o.options,o))):R.createElement(r.CaptionLabel,{className:c[$.CaptionLabel],style:S?.[$.CaptionLabel],role:`status`,"aria-live":`polite`},C(e.date,o.options,o))),d===`around`&&!t.hideNavigation&&n===f-1&&R.createElement(r.NextMonthButton,{type:`button`,className:c[$.NextMonthButton],style:S?.[$.NextMonthButton],tabIndex:P?void 0:-1,"aria-disabled":!P||void 0,"aria-label":he(P),onClick:Ce,"data-animated-button":t.animate?`true`:void 0},R.createElement(r.Chevron,{disabled:!P||void 0,className:c[$.Chevron],style:S?.[$.Chevron],orientation:t.dir===`rtl`?`left`:`right`})),n===f-1&&d===`after`&&!t.hideNavigation&&R.createElement(r.Nav,{"data-animated-nav":t.animate?`true`:void 0,className:c[$.Nav],style:S?.[$.Nav],"aria-label":pe(),onPreviousClick:Se,onNextClick:Ce,previousMonth:te,nextMonth:P}),R.createElement(r.MonthGrid,{role:`grid`,"aria-multiselectable":u===`multiple`||u===`range`,"aria-label":de(e.date,o.options,o)||void 0,className:c[$.MonthGrid],style:S?.[$.MonthGrid]},!t.hideWeekdays&&R.createElement(r.Weekdays,{"data-animated-weekdays":t.animate?`true`:void 0,className:c[$.Weekdays],style:S?.[$.Weekdays]},x&&R.createElement(r.WeekNumberHeader,{"aria-label":ve(o.options),className:c[$.WeekNumberHeader],style:S?.[$.WeekNumberHeader],scope:`col`},ee()),be.map(e=>R.createElement(r.Weekday,{"aria-label":ge(e,o.options,o),className:c[$.Weekday],key:String(e),style:S?.[$.Weekday],scope:`col`},D(e,o.options,o)))),R.createElement(r.Weeks,{"data-animated-weeks":t.animate?`true`:void 0,className:c[$.Weeks],style:S?.[$.Weeks]},e.weeks.map(e=>R.createElement(r.Week,{className:c[$.Week],key:e.weekNumber,style:S?.[$.Week],week:e},x&&R.createElement(r.WeekNumber,{week:e,style:S?.[$.WeekNumber],"aria-label":_e(e.weekNumber,{locale:s}),className:c[$.WeekNumber],scope:`row`,role:`rowheader`},E(e.weekNumber,o)),e.days.map(e=>{let{date:n}=e,i=ne(e);if(i[rw.focused]=!i.hidden&&!!L?.isEqualTo(e),i[iw.selected]=re?.(n)||i.selected,Mw(ae)){let{from:e,to:t}=ae;i[iw.range_start]=!!(e&&t&&o.isSameDay(n,e)),i[iw.range_end]=!!(e&&t&&o.isSameDay(n,t)),i[iw.range_middle]=Aw(ae,n,!0,o)}let a=mT(i,S,t.modifiersStyles),s=zw(i,c,t.modifiersClassNames),l=!xe&&!i.hidden?ue(n,i,o.options,o):void 0;return R.createElement(r.Day,{key:`${e.isoDate}_${e.displayMonthId}`,day:e,modifiers:i,className:s.join(` `),style:a,role:`gridcell`,"aria-selected":i.selected||void 0,"aria-label":l,"data-day":e.isoDate,"data-month":e.outside?e.dateMonthId:void 0,"data-selected":i.selected||void 0,"data-disabled":i.disabled||void 0,"data-hidden":i.hidden||void 0,"data-outside":e.outside||void 0,"data-focused":i.focused||void 0,"data-today":i.today||void 0},!i.hidden&&xe?R.createElement(r.DayButton,{className:c[$.DayButton],style:S?.[$.DayButton],type:`button`,day:e,modifiers:i,disabled:!i.focused&&i.disabled||void 0,"aria-disabled":i.focused&&i.disabled||void 0,tabIndex:oe(e)?0:-1,"aria-label":le(n,i,o.options,o),onClick:we(e,i),onBlur:Ee(e,i),onFocus:Te(e,i),onKeyDown:De(e,i),onMouseEnter:Oe(e,i),onMouseLeave:ke(e,i)},w(n,o.options,o)):!i.hidden&&w(e.date,o.options,o))}))))))})),t.footer&&R.createElement(r.Footer,{className:c[$.Footer],style:S?.[$.Footer],role:`status`,"aria-live":`polite`},t.footer)))}function nE({className:e,classNames:t,showOutsideDays:n=!0,captionLayout:r=`label`,buttonVariant:i=`ghost`,locale:a,formatters:o,components:s,...c}){let l=Hw();return(0,z.jsx)(tE,{showOutsideDays:n,className:Y(`group/calendar bg-background p-2 [--cell-radius:var(--radius-md)] [--cell-size:--spacing(7)] in-data-[slot=card-content]:bg-transparent in-data-[slot=popover-content]:bg-transparent`,String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`,String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`,e),captionLayout:r,locale:a,formatters:{formatMonthDropdown:e=>e.toLocaleString(a?.code,{month:`short`}),...o},classNames:{root:Y(`w-fit`,l.root),months:Y(`relative flex flex-col gap-4 md:flex-row`,l.months),month:Y(`flex w-full flex-col gap-4`,l.month),nav:Y(`absolute inset-x-0 top-0 flex w-full items-center justify-between gap-1`,l.nav),button_previous:Y(D_({variant:i}),`size-(--cell-size) p-0 select-none aria-disabled:opacity-50`,l.button_previous),button_next:Y(D_({variant:i}),`size-(--cell-size) p-0 select-none aria-disabled:opacity-50`,l.button_next),month_caption:Y(`flex h-(--cell-size) w-full items-center justify-center px-(--cell-size)`,l.month_caption),dropdowns:Y(`flex h-(--cell-size) w-full items-center justify-center gap-1.5 text-sm font-medium`,l.dropdowns),dropdown_root:Y(`relative rounded-(--cell-radius)`,l.dropdown_root),dropdown:Y(`absolute inset-0 bg-popover opacity-0`,l.dropdown),caption_label:Y(`font-medium select-none`,r===`label`?`text-sm`:`flex items-center gap-1 rounded-(--cell-radius) text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground`,l.caption_label),month_grid:Y(`w-full border-collapse`,l.month_grid),weekdays:Y(`flex`,l.weekdays),weekday:Y(`flex-1 rounded-(--cell-radius) text-[0.8rem] font-normal text-muted-foreground select-none`,l.weekday),week:Y(`mt-2 flex w-full`,l.week),week_number_header:Y(`w-(--cell-size) select-none`,l.week_number_header),week_number:Y(`text-[0.8rem] text-muted-foreground select-none`,l.week_number),day:Y(`group/day relative aspect-square h-full w-full rounded-(--cell-radius) p-0 text-center select-none [&:last-child[data-selected=true]_button]:rounded-e-(--cell-radius)`,c.showWeekNumber?`[&:nth-child(2)[data-selected=true]_button]:rounded-s-(--cell-radius)`:`[&:first-child[data-selected=true]_button]:rounded-s-(--cell-radius)`,l.day),range_start:Y(`relative isolate z-0 rounded-s-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:end-0 after:w-4 after:bg-muted`,l.range_start),range_middle:Y(`rounded-none`,l.range_middle),range_end:Y(`relative isolate z-0 rounded-e-(--cell-radius) bg-muted after:absolute after:inset-y-0 after:start-0 after:w-4 after:bg-muted`,l.range_end),today:Y(`rounded-(--cell-radius) bg-muted text-foreground data-[selected=true]:rounded-none`,l.today),outside:Y(`text-muted-foreground aria-selected:text-muted-foreground`,l.outside),disabled:Y(`text-muted-foreground opacity-50`,l.disabled),hidden:Y(`invisible`,l.hidden),...t},components:{Root:({className:e,rootRef:t,...n})=>(0,z.jsx)(`div`,{"data-slot":`calendar`,ref:t,className:Y(e),...n}),Chevron:({className:e,orientation:t,...n})=>t===`left`?(0,z.jsx)(kt,{className:Y(`rtl:rotate-180 size-4`,e),...n}):t===`right`?(0,z.jsx)(At,{className:Y(`rtl:rotate-180 size-4`,e),...n}):(0,z.jsx)(Ot,{className:Y(`size-4`,e),...n}),DayButton:({...e})=>(0,z.jsx)(rE,{locale:a,...e}),WeekNumber:({children:e,...t})=>(0,z.jsx)(`td`,{...t,children:(0,z.jsx)(`div`,{className:`flex size-(--cell-size) items-center justify-center text-center`,children:e})}),...s},...c})}function rE({className:e,day:t,modifiers:n,locale:r,...i}){let a=Hw(),o=R.useRef(null);return R.useEffect(()=>{n.focused&&o.current?.focus()},[n.focused]),(0,z.jsx)(X,{ref:o,variant:`ghost`,size:`icon`,"data-day":t.date.toLocaleDateString(r?.code),"data-selected-single":n.selected&&!n.range_start&&!n.range_end&&!n.range_middle,"data-range-start":n.range_start,"data-range-end":n.range_end,"data-range-middle":n.range_middle,className:Y(`relative isolate z-10 flex aspect-square size-auto w-full min-w-(--cell-size) flex-col gap-1 border-0 leading-none font-normal group-data-[focused=true]/day:relative group-data-[focused=true]/day:z-10 group-data-[focused=true]/day:border-ring group-data-[focused=true]/day:ring-[3px] group-data-[focused=true]/day:ring-ring/50 data-[range-end=true]:rounded-(--cell-radius) data-[range-end=true]:rounded-e-(--cell-radius) data-[range-end=true]:bg-primary data-[range-end=true]:text-primary-foreground data-[range-middle=true]:rounded-none data-[range-middle=true]:bg-muted data-[range-middle=true]:text-foreground data-[range-start=true]:rounded-(--cell-radius) data-[range-start=true]:rounded-s-(--cell-radius) data-[range-start=true]:bg-primary data-[range-start=true]:text-primary-foreground data-[selected-single=true]:bg-primary data-[selected-single=true]:text-primary-foreground dark:hover:text-foreground [&>span]:text-xs [&>span]:opacity-70`,a.day,e),...i})}function iE({...e}){return(0,z.jsx)(Xp,{"data-slot":`popover`,...e})}function aE({...e}){return(0,z.jsx)(Zp,{"data-slot":`popover-trigger`,...e})}function oE({className:e,align:t=`center`,sideOffset:n=4,...r}){return(0,z.jsx)(Qp,{children:(0,z.jsx)($p,{"data-slot":`popover-content`,align:t,sideOffset:n,className:Y(`z-50 flex w-72 origin-(--radix-popover-content-transform-origin) flex-col gap-2.5 rounded-lg bg-popover p-2.5 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10 outline-hidden duration-100 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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,e),...r})})}function sE({...e}){return(0,z.jsx)(gm,{"data-slot":`select`,...e})}function cE({...e}){return(0,z.jsx)(bm,{"data-slot":`select-value`,...e})}function lE({className:e,size:t=`default`,children:n,...r}){return(0,z.jsxs)(vm,{"data-slot":`select-trigger`,"data-size":t,className:Y(`flex w-fit items-center justify-between gap-1.5 rounded-lg border border-input bg-transparent py-2 pe-2 ps-2.5 text-sm whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground/70 data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),...r,children:[n,(0,z.jsx)(xm,{asChild:!0,children:(0,z.jsx)(Ot,{className:`pointer-events-none size-4 text-muted-foreground`})})]})}function uE({className:e,children:t,position:n=`item-aligned`,align:r=`center`,...i}){return(0,z.jsx)(wm,{children:(0,z.jsxs)(Em,{"data-slot":`select-content`,"data-align-trigger":n===`item-aligned`,className:Y(`relative z-50 max-h-(--radix-select-content-available-height) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none 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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,n===`popper`&&`data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 rtl:data-[side=left]:translate-x-1 data-[side=right]:translate-x-1 rtl:data-[side=right]:-translate-x-1 data-[side=top]:-translate-y-1`,e),position:n,align:r,...i,children:[(0,z.jsx)(fE,{}),(0,z.jsx)(Rm,{"data-position":n,className:Y(`data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)`,n===`popper`&&``),children:t}),(0,z.jsx)(pE,{})]})})}function dE({className:e,children:t,...n}){return(0,z.jsxs)(Wm,{"data-slot":`select-item`,className:Y(`relative flex w-full cursor-default items-center gap-1.5 rounded-md py-1 pe-8 ps-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2`,e),...n,children:[(0,z.jsx)(`span`,{className:`pointer-events-none absolute end-2 flex size-4 items-center justify-center`,children:(0,z.jsx)(Jm,{children:(0,z.jsx)(Dt,{className:`pointer-events-none`})})}),(0,z.jsx)(Km,{children:t})]})}function fE({className:e,...t}){return(0,z.jsx)(Xm,{"data-slot":`select-scroll-up-button`,className:Y(`z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4`,e),...t,children:(0,z.jsx)(jt,{})})}function pE({className:e,...t}){return(0,z.jsx)(Qm,{"data-slot":`select-scroll-down-button`,className:Y(`z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4`,e),...t,children:(0,z.jsx)(Ot,{})})}function mE({className:e,...t}){return(0,z.jsx)(`textarea`,{"data-slot":`textarea`,className:Y(`flex field-sizing-content min-h-16 w-full rounded-lg border border-input bg-transparent px-2.5 py-2 text-base transition-colors outline-none placeholder:text-muted-foreground/70 focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40`,e),...t})}function hE({className:e,...t}){return(0,z.jsx)(xp,{"data-slot":`label`,className:Y(`flex items-center gap-2 text-sm leading-none font-medium select-none group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50`,e),...t})}async function gE(e){let t=e.language??`en`,n=_E(e.purposes,e.preferredPurpose);if(!n)throw Error(Q(t,`media.noPurpose`));let r=await bE(e.file,n,t),i=await Z.post(`/media/uploads`,{filename:e.file.name,purpose:n.name,variants:r.map(e=>({mimeType:e.mimeType,byteSize:e.blob.size,role:e.role})),alt:e.alt??AE(e.file),caption:e.caption});for(let e of r){let n=i.capabilities.find(t=>t.mimeType===e.mimeType&&t.role===e.role);if(!n)throw Error(Q(t,`media.capabilityMissing`,{mime:e.mimeType}));if(!(await fetch(n.uploadUrl,{method:n.method,headers:n.requiredHeaders??{"Content-Type":e.mimeType},body:e.blob})).ok)throw Error(Q(t,`media.variantUploadFailed`,{mime:e.mimeType}))}return Z.post(`/media/uploads/${encodeURIComponent(i.uploadGroupId)}/commit`,{alt:e.alt??AE(e.file),caption:e.caption})}function _E(e,t){if(t){let n=e.find(e=>e.name===t);if(n)return n}return e.find(e=>e.name===`content`)??e[0]??null}function vE(e,t,n){let r=n[n.length-1]??``,i=kE(t.replace(/-translations$/,``)),a=[];/cover/i.test(r)&&a.push(`${i}-cover`),/image|asset|media/i.test(r)&&(a.push(`${i}-image`),a.push(`${i}-media`)),a.push(`content`);for(let t of a)if(e.some(e=>e.name===t))return t;return e[0]?.name}function yE(e){return(e.variants.find(e=>e.role===`primary`)??e.variants[0])?.publicUrl??null}async function bE(e,t,n){if(!e.type.startsWith(`image/`)||e.type===`image/svg+xml`)throw Error(Q(n,`media.rasterOnly`));let r=xE(t.required);if(r.length===0)throw Error(Q(n,`media.noRequiredVariants`));let i=await createImageBitmap(e);try{let e=await Promise.all(r.map(e=>TE(e,t,n))),a=e.find(OE)??e[0],o=[];for(let r of e){let e=t.maxBytes[r]??2**53-1;o.push({mimeType:r,role:r===a?`primary`:`alternate`,blob:await EE(i,r,e,n)})}return o}finally{i.close?.()}}function xE(e){return e.map(e=>e.split(`,`).map(SE).filter(e=>!!e)).filter(e=>e.length>0)}function SE(e){let t=e.trim().toLowerCase();return t?t===`jpg`||t===`jpeg`||t===`image/jpg`?`image/jpeg`:t===`png`?`image/png`:t===`webp`?`image/webp`:t===`avif`?`image/avif`:t===`gif`?`image/gif`:t.includes(`/`)?t:null:null}var CE=new Map;function wE(e){let t=CE.get(e);return t||(t=(async()=>{try{let t=document.createElement(`canvas`);return t.width=1,t.height=1,(await new Promise(n=>t.toBlob(n,e)))?.type===e}catch{return!0}})(),CE.set(e,t)),t}async function TE(e,t,n){for(let n of e)if(n.startsWith(`image/`)&&t.maxBytes[n]!=null&&await wE(n))return n;let r=e.find(e=>e.startsWith(`image/`)&&t.maxBytes[e]!=null);throw Error(Q(n,`media.encoderUnsupported`,{mime:r??e[0]??`?`}))}async function EE(e,t,n,r){let i=1,a=t===`image/jpeg`?[.88,.78,.68,.58]:[.78,.68,.58,.48],o=null;for(let s=0;s<6;s+=1){for(let c of a){let a=await DE(e,t,i,c,r);if(a.type!==t){if(s===0&&o===null)throw Error(Q(r,`media.encoderUnsupported`,{mime:t}));continue}if(o=a,a.size<=n)return a}i*=.82}if(o)return o;throw Error(Q(r,`media.encoderUnsupported`,{mime:t}))}async function DE(e,t,n,r,i){let a=document.createElement(`canvas`);a.width=Math.max(1,Math.round(e.width*n)),a.height=Math.max(1,Math.round(e.height*n));let o=a.getContext(`2d`);if(!o)throw Error(Q(i,`media.prepareFailed`));o.drawImage(e,0,0,a.width,a.height);let s=await new Promise(e=>a.toBlob(e,t,r));if(!s)throw Error(Q(i,`media.encoderUnsupported`,{mime:t}));return s}function OE(e){return e===`image/jpeg`||e===`image/png`||e===`image/gif`}function kE(e){return e.endsWith(`ies`)?`${e.slice(0,-3)}y`:e.endsWith(`ses`)?e.slice(0,-2):e.endsWith(`s`)&&e.length>1?e.slice(0,-1):e}function AE(e){return e.name.replace(/\.[^.]+$/,``)}function jE({value:e,onChange:t,compact:n=!1}){let{language:r}=Iv(),i=R.useRef(null),a=R.useRef(null),[o,s]=R.useState(!1),[c,l]=R.useState(!1),[u,d]=R.useState(!1),[f,p]=R.useState(null),m=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}),h=R.useCallback((n,r=``,a=``)=>{let o=i.current;if(!o){t(`${e}${n}${a}${r}`);return}let s=o.selectionStart,c=o.selectionEnd,l=e.slice(s,c)||a;t(`${e.slice(0,s)}${n}${l}${r}${e.slice(c)}`),window.requestAnimationFrame(()=>{o.focus();let e=s+n.length,t=e+l.length;o.setSelectionRange(e,t)})},[t,e]),g=R.useCallback(t=>{let n=e.endsWith(`
|
|
50
|
+
`)||e.length===0?``:`
|
|
51
|
+
|
|
52
|
+
`;h(`${n}${t}`,``,``)},[h,e]);async function _(e){d(!0),p(null);try{let t=await gE({file:e,purposes:m.data?.media?.purposes??[],preferredPurpose:`content`,language:r}),n=yE(t);if(!n)throw Error(Q(r,`common.unknownError`));v(n,t.alt??e.name)}catch(e){p(e instanceof Error?e.message:String(e))}finally{d(!1),a.current&&(a.current.value=``)}}function v(e,t){g(``)}function y(e){let t=LE(e);g(t),l(!1)}function b(e){if(e!==`paragraph`){if(/^h[1-6]$/.test(e)){let t=Number(e.slice(1));h(`${`#`.repeat(t)} `,``,Q(r,`editor.headingPlaceholder`));return}e===`quote`&&g(`> `),e===`code`&&h("```\n","\n```")}}return(0,z.jsxs)(`div`,{children:[(0,z.jsxs)(`div`,{className:`flex flex-wrap items-center gap-1 rounded-t-lg border bg-muted/30 p-1`,"aria-label":Q(r,`editor.toolbar`),children:[(0,z.jsx)(ME,{title:Q(r,`editor.undo`),onClick:()=>IE(`undo`,i.current),children:(0,z.jsx)(Fn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.redo`),onClick:()=>IE(`redo`,i.current),children:(0,z.jsx)(vn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(NE,{}),(0,z.jsx)(ME,{title:Q(r,`editor.aiClean`),onClick:()=>g(`> `),children:(0,z.jsx)(Bn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.uploadImage`),onClick:()=>a.current?.click(),disabled:u,children:(0,z.jsx)(In,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(`input`,{ref:a,type:`file`,accept:`image/*`,className:`hidden`,onChange:e=>{let t=e.currentTarget.files?.[0];t&&_(t)}}),(0,z.jsx)(NE,{}),(0,z.jsxs)(`label`,{className:`flex h-8 items-center gap-1 rounded-md px-2 text-sm text-muted-foreground hover:bg-accent hover:text-accent-foreground`,title:Q(r,`editor.textStyle`),children:[(0,z.jsx)(Nn,{className:`size-4`,"aria-hidden":!0}),(0,z.jsxs)(`select`,{className:`bg-transparent text-sm outline-none`,onChange:e=>{b(e.target.value),e.target.value=`paragraph`},defaultValue:`paragraph`,children:[(0,z.jsx)(`option`,{value:`paragraph`,children:Q(r,`editor.paragraph`)}),(0,z.jsx)(`option`,{value:`h1`,children:`H1`}),(0,z.jsx)(`option`,{value:`h2`,children:`H2`}),(0,z.jsx)(`option`,{value:`h3`,children:`H3`}),(0,z.jsx)(`option`,{value:`h4`,children:`H4`}),(0,z.jsx)(`option`,{value:`h5`,children:`H5`}),(0,z.jsx)(`option`,{value:`h6`,children:`H6`}),(0,z.jsx)(`option`,{value:`quote`,children:Q(r,`editor.quote`)}),(0,z.jsx)(`option`,{value:`code`,children:Q(r,`editor.code`)})]})]}),(0,z.jsx)(NE,{}),(0,z.jsx)(ME,{title:Q(r,`editor.bold`),onClick:()=>h(`**`,`**`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(Ct,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.italic`),onClick:()=>h(`_`,`_`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(Qt,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.underline`),onClick:()=>h(`<u>`,`</u>`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(Pn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.strike`),onClick:()=>h(`~~`,`~~`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(Tn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.inlineCode`),onClick:()=>h("`","`"),children:(0,z.jsx)(Ft,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.textColor`),onClick:()=>h(`<span class="text-accent">`,`</span>`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(St,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.highlight`),onClick:()=>h(`<mark>`,`</mark>`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(Kt,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.palette`),onClick:()=>h(`<span class="brand-tone">`,`</span>`,Q(r,`editor.selectedText`)),children:(0,z.jsx)(pn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(NE,{}),(0,z.jsx)(ME,{title:Q(r,`editor.alignLeft`),onClick:()=>g(`<p style="text-align:left"></p>`),children:(0,z.jsx)(An,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.alignCenter`),onClick:()=>g(`<p style="text-align:center"></p>`),children:(0,z.jsx)(On,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.alignRight`),onClick:()=>g(`<p style="text-align:right"></p>`),children:(0,z.jsx)(kn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.bulletList`),onClick:()=>g(`- `),children:(0,z.jsx)(an,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.numberList`),onClick:()=>g(`1. `),children:(0,z.jsx)(rn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.checkList`),onClick:()=>g(`- [ ] `),children:(0,z.jsx)(tn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.indent`),onClick:()=>h(` `,``,``),children:(0,z.jsx)(nn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(NE,{}),(0,z.jsx)(ME,{title:Q(r,`editor.link`),onClick:()=>h(`[`,`](https://)`,Q(r,`editor.linkText`)),children:(0,z.jsx)(en,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.table`),onClick:()=>g(`| | |
|
|
53
|
+
| --- | --- |
|
|
54
|
+
| | |`),children:(0,z.jsx)(Dn,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.mediaLibrary`),onClick:()=>s(!0),children:(0,z.jsx)(Xt,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.imageUrl`),onClick:()=>s(!0),children:(0,z.jsx)(Yt,{className:`size-4`,"aria-hidden":!0})}),(0,z.jsx)(ME,{title:Q(r,`editor.videoUrl`),onClick:()=>l(!0),children:(0,z.jsx)(zn,{className:`size-4`,"aria-hidden":!0})})]}),(0,z.jsx)(mE,{ref:i,className:`${n?`min-h-32`:`min-h-64`} rounded-t-none border-t-0 resize-y font-mono`,value:e,onChange:e=>t(e.target.value)}),f?(0,z.jsx)(`p`,{className:`mt-2 text-xs text-destructive`,children:f}):null,u?(0,z.jsx)(`p`,{className:`mt-2 text-xs text-muted-foreground`,children:Q(r,`editor.uploading`)}):null,o?(0,z.jsx)(PE,{language:r,onClose:()=>s(!1),onInsert:(e,t)=>{v(e,t),s(!1)}}):null,c?(0,z.jsx)(FE,{language:r,onClose:()=>l(!1),onInsert:y}):null]})}function ME({title:e,onClick:t,disabled:n,children:r}){return(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:e,"aria-label":e,onClick:t,disabled:n,children:r})}function NE(){return(0,z.jsx)(k_,{orientation:`vertical`,className:`mx-1 h-5`,"aria-hidden":!0})}function PE({language:e,onClose:t,onInsert:n}){let[r,i]=R.useState(``),[a,o]=R.useState(``);return(0,z.jsx)(Vx,{open:!0,onOpenChange:e=>{e||t()},children:(0,z.jsxs)(Wx,{closeLabel:Q(e,`common.close`),children:[(0,z.jsxs)(Gx,{children:[(0,z.jsx)(qx,{children:Q(e,`editor.insertImage`)}),(0,z.jsx)(Jx,{className:`sr-only`,children:Q(e,`editor.mediaLibrary`)})]}),(0,z.jsxs)(`div`,{className:`grid gap-4`,children:[(0,z.jsxs)(`div`,{className:`grid gap-2`,children:[(0,z.jsx)(hE,{htmlFor:`rich-editor-image-url`,children:Q(e,`editor.imageUrl`)}),(0,z.jsx)(O_,{id:`rich-editor-image-url`,value:r,onChange:e=>i(e.target.value),placeholder:`https://...`})]}),(0,z.jsxs)(`div`,{className:`grid gap-2`,children:[(0,z.jsx)(hE,{htmlFor:`rich-editor-image-alt`,children:Q(e,`media.alt`)}),(0,z.jsx)(O_,{id:`rich-editor-image-alt`,value:a,onChange:e=>o(e.target.value)})]})]}),(0,z.jsx)(Kx,{children:(0,z.jsxs)(X,{type:`button`,disabled:!r.trim(),onClick:()=>n(r.trim(),a.trim()),children:[(0,z.jsx)(Dt,{className:`size-4`,"aria-hidden":!0}),Q(e,`editor.insertImage`)]})})]})})}function FE({language:e,onClose:t,onInsert:n}){let[r,i]=R.useState(``);return(0,z.jsx)(Vx,{open:!0,onOpenChange:e=>{e||t()},children:(0,z.jsxs)(Wx,{closeLabel:Q(e,`common.close`),children:[(0,z.jsxs)(Gx,{children:[(0,z.jsx)(qx,{children:Q(e,`editor.insertVideo`)}),(0,z.jsx)(Jx,{className:`sr-only`,children:Q(e,`editor.videoUrl`)})]}),(0,z.jsxs)(`div`,{className:`grid gap-2`,children:[(0,z.jsx)(hE,{htmlFor:`rich-editor-video-url`,children:Q(e,`editor.videoUrl`)}),(0,z.jsx)(O_,{id:`rich-editor-video-url`,value:r,onChange:e=>i(e.target.value),placeholder:Q(e,`editor.videoUrl`)})]}),(0,z.jsx)(Kx,{children:(0,z.jsxs)(X,{type:`button`,disabled:!r.trim(),onClick:()=>n(r.trim()),children:[(0,z.jsx)(zn,{className:`size-4`,"aria-hidden":!0}),Q(e,`editor.insertVideo`)]})})]})})}function IE(e,t){t?.focus(),document.execCommand(e)}function LE(e){let t=RE(e);if(!t)return`<a href="${HE(e)}">${VE(e)}</a>`;let n=zE(t);if(n)return`<iframe src="https://www.youtube.com/embed/${n}" title="YouTube" loading="lazy" allowfullscreen></iframe>`;let r=BE(t);return r?`<iframe src="https://www.dailymotion.com/embed/video/${r}" title="Dailymotion" loading="lazy" allowfullscreen></iframe>`:`<a href="${HE(t.toString())}">${VE(t.toString())}</a>`}function RE(e){try{return new URL(e)}catch{return null}}function zE(e){return e.hostname===`youtu.be`?e.pathname.split(`/`).filter(Boolean)[0]??null:e.hostname.includes(`youtube.com`)?e.pathname.startsWith(`/shorts/`)?e.pathname.split(`/`).filter(Boolean)[1]??null:e.searchParams.get(`v`):null}function BE(e){if(e.hostname===`dai.ly`)return e.pathname.split(`/`).filter(Boolean)[0]??null;if(!e.hostname.includes(`dailymotion.com`))return null;let t=e.pathname.split(`/`).filter(Boolean),n=t.indexOf(`video`);return n>=0?t[n+1]??null:null}function VE(e){return e.replace(/[&<>"']/g,e=>{switch(e){case`&`:return`&`;case`<`:return`<`;case`>`:return`>`;case`"`:return`"`;default:return`'`}})}function HE(e){return VE(e).replace(/`/g,```)}function UE(e,t){let[n,r]=R.useState([]),[i,a]=R.useState(),[o,s]=R.useState(!1),[c,l]=R.useState(null),u=t.resetOnPageChange?e:null;R.useEffect(()=>{r([]),a(void 0),l(null)},[t.resetKey,u]);let d=i===void 0?e?.next_cursor??null:i;return{items:R.useMemo(()=>[...e?.items??[],...n],[e,n]),nextCursor:d,isLoadingMore:o,loadMoreError:c,loadMore:R.useCallback(async()=>{if(d){s(!0),l(null);try{let e=await t.loadPage(d);r(t=>[...t,...e.items]),a(e.next_cursor)}catch(e){l(e)}finally{s(!1)}}},[d,t.loadPage])}}var WE=`https://developers.cloudflare.com/r2/get-started/workers-api/`,GE=`Enable Mantle media storage for this site using the runtime's supported storage adapter. If this is a Cloudflare deployment, follow node_modules/@aotter/mantle/docs/media-uploads.md: create and bind an R2 bucket, configure its S3 credentials and public URL, wire mediaStorage, validate, deploy, and verify /admin/media.`;function KE(){let{language:e}=Iv(),t=Av(),n=new URLSearchParams(t.search).get(`search`)?.trim()??``,r=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}).data?.media?.purposes??[];return(0,z.jsxs)(`div`,{children:[(0,z.jsx)(Hy,{eyebrow:Q(e,`nav.media`),title:Q(e,`media.title`),description:Q(e,`media.description`)}),(0,z.jsx)(qE,{language:e,purposes:r,searchTerm:n,emptyIcon:Xt,showSearch:!0})]})}function qE({language:e,purposes:t,searchTerm:n,emptyIcon:r,onPick:i,showSearch:a=!1}){let o=Ke(),s=st({queryKey:[`media`,n],queryFn:()=>{let e=new URLSearchParams({limit:`60`});return n&&e.set(`search`,n),Z.get(`/media?${e.toString()}`)}}),c=R.useCallback(async e=>{let t=new URLSearchParams({limit:`60`,cursor:e});return n&&t.set(`search`,n),Z.get(`/media?${t.toString()}`)},[n]),l=UE(s.data,{resetKey:n,resetOnPageChange:!1,loadPage:c}),u=l.items,d=YE(s.error),[f,p]=R.useState(!1),[m,h]=R.useState(null),[g,_]=R.useState(!1),v=R.useRef(null),y=t.length>0&&!f,b=R.useCallback(()=>{o.invalidateQueries({queryKey:[`media`]})},[o]);async function x(n){let r=Array.from(n).filter(e=>e.type.startsWith(`image/`));if(r.length!==0){p(!0),h(null);try{let n=await Promise.allSettled(r.map(n=>gE({file:n,purposes:t,language:e}))),i=n.filter(e=>e.status===`fulfilled`).length,a=n.filter(e=>e.status===`rejected`);if(i>0&&b(),a.length>0){let t=a[0]?.reason,n=t instanceof Error?t.message:String(t);h(`${Q(e,`media.uploadFailed`,{count:String(a.length),total:String(r.length)})} ${n}`.trim())}}finally{p(!1),v.current&&(v.current.value=``)}}}return d?(0,z.jsx)(JE,{language:e}):(0,z.jsxs)(z.Fragment,{children:[a?(0,z.jsx)(ZE,{searchTerm:n,language:e}):null,(0,z.jsxs)(`div`,{onDragOver:e=>{y&&(e.preventDefault(),_(!0))},onDragLeave:()=>_(!1),onDrop:e=>{y&&(e.preventDefault(),_(!1),x(e.dataTransfer.files))},className:Y(`rounded-xl border border-dashed p-4 transition-colors`,g?`border-primary bg-accent/40`:`border-transparent`),children:[(0,z.jsxs)(`div`,{className:`mb-4 flex flex-wrap items-center gap-2`,children:[(0,z.jsxs)(X,{type:`button`,variant:`default`,onClick:()=>v.current?.click(),disabled:!y,title:t.length===0?Q(e,`media.noPurpose`):void 0,children:[(0,z.jsx)(In,{className:`size-4`,"aria-hidden":!0}),f?Q(e,`media.uploading`):Q(e,`media.upload`)]}),(0,z.jsx)(`span`,{className:`text-xs text-muted-foreground`,children:Q(e,`media.dropHere`)}),(0,z.jsx)(`input`,{ref:v,type:`file`,accept:`image/*`,multiple:!0,className:`hidden`,onChange:e=>{e.currentTarget.files&&x(e.currentTarget.files)}})]}),m?(0,z.jsx)(`p`,{className:`mb-3 text-xs text-destructive`,children:m}):null,s.isError?(0,z.jsx)(Ky,{error:s.error}):null,s.isLoading?(0,z.jsx)(QE,{}):u.length===0?(0,z.jsx)(Gy,{icon:r,title:Q(e,`media.empty.title`),description:n?Q(e,`media.empty.search`,{search:n}):Q(e,`media.empty.all`)}):(0,z.jsx)(`div`,{className:`grid grid-cols-2 gap-4 sm:grid-cols-3 lg:grid-cols-4`,children:u.map(t=>(0,z.jsx)(XE,{item:t,language:e,onChanged:b,onPick:i},t.id))}),l.loadMoreError?(0,z.jsx)(Ky,{error:l.loadMoreError}):null,l.nextCursor?(0,z.jsx)(`div`,{className:`mt-4`,children:(0,z.jsx)(X,{type:`button`,variant:`secondary`,onClick:()=>void l.loadMore(),disabled:l.isLoadingMore,children:l.isLoadingMore?Q(e,`media.saving`):Q(e,`media.loadMore`)})}):null]})]})}function JE({language:e}){let[t,n]=R.useState(!1);async function r(){try{await navigator.clipboard.writeText(GE),n(!0),window.setTimeout(()=>n(!1),1400)}catch{n(!1)}}return(0,z.jsx)(Gy,{icon:Xt,title:Q(e,`media.setup.title`),description:(0,z.jsxs)(z.Fragment,{children:[Q(e,`media.setup.body`),(0,z.jsx)(`span`,{className:`mt-2 block`,children:Q(e,`media.setup.cloudflare`)})]}),action:(0,z.jsxs)(`div`,{className:`flex flex-wrap justify-center gap-2`,children:[(0,z.jsxs)(X,{type:`button`,onClick:()=>void r(),children:[t?(0,z.jsx)(Dt,{"aria-hidden":!0}):(0,z.jsx)(Lt,{"aria-hidden":!0}),Q(e,t?`media.setup.copied`:`media.setup.copy`)]}),(0,z.jsx)(X,{asChild:!0,variant:`outline`,children:(0,z.jsxs)(`a`,{href:WE,target:`_blank`,rel:`noreferrer`,children:[(0,z.jsx)(Vt,{"aria-hidden":!0}),Q(e,`media.setup.guide`)]})})]})})}function YE(e){return!(e instanceof mv)||e.status!==501?!1:e.body?.diagnostic?.code===`MEDIA_NOT_CONFIGURED`}function XE({item:e,language:t,onChanged:n,onPick:r}){let[i,a]=R.useState(e.alt??``),[o,s]=R.useState(e.caption??``),[c,l]=R.useState(!1),u=i!==(e.alt??``)||o!==(e.caption??``),d=ct({mutationFn:()=>Z.patch(`/media/${encodeURIComponent(e.id)}`,{alt:i,caption:o}),onSuccess:n}),f=ct({mutationFn:()=>Z.delete(`/media/${encodeURIComponent(e.id)}`),onSuccess:n}),p=Xb();async function m(){await p({description:Q(t,`media.deleteConfirm`)})&&f.mutate()}async function h(){try{await navigator.clipboard.writeText(e.id),l(!0),window.setTimeout(()=>l(!1),1400)}catch{l(!1)}}return(0,z.jsxs)(`div`,{className:`flex flex-col overflow-hidden rounded-lg border bg-card`,children:[(0,z.jsxs)(`div`,{className:`relative aspect-square bg-muted/40`,children:[e.primaryUrl?(0,z.jsx)(`img`,{src:e.primaryUrl,alt:e.alt??``,loading:`lazy`,className:`size-full object-cover`}):(0,z.jsx)(`div`,{className:`flex size-full items-center justify-center text-muted-foreground`,children:(0,z.jsx)(Xt,{className:`size-6`,"aria-hidden":!0})}),r?(0,z.jsx)(`button`,{type:`button`,className:`absolute inset-0 flex items-end justify-center bg-black/0 p-2 opacity-0 transition hover:bg-black/40 hover:opacity-100`,onClick:()=>r(e),children:(0,z.jsx)(`span`,{className:`rounded-md bg-primary px-3 py-1 text-xs font-semibold text-primary-foreground`,children:Q(t,`media.use`)})}):null]}),(0,z.jsxs)(`div`,{className:`flex flex-1 flex-col gap-2 p-3`,children:[(0,z.jsxs)(`div`,{className:`flex items-center justify-between gap-2 text-xs text-muted-foreground`,children:[(0,z.jsxs)(`button`,{type:`button`,className:`group inline-flex items-center gap-1 font-mono hover:text-foreground`,title:Q(t,`media.copyId`),onClick:()=>void h(),children:[e.id.slice(0,8),c?(0,z.jsx)(Dt,{className:`size-3 text-[color:var(--success)]`,"aria-hidden":!0}):(0,z.jsx)(Lt,{className:`size-3 opacity-40 transition-opacity group-hover:opacity-80`,"aria-hidden":!0})]}),(0,z.jsx)(`span`,{children:$E(e.byteSize)})]}),r?null:(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(O_,{value:i,placeholder:Q(t,`media.altPlaceholder`),"aria-label":Q(t,`media.alt`),onChange:e=>a(e.target.value)}),(0,z.jsx)(O_,{value:o,placeholder:Q(t,`media.captionPlaceholder`),"aria-label":Q(t,`media.caption`),onChange:e=>s(e.target.value)}),(0,z.jsxs)(`div`,{className:`mt-1 flex items-center justify-between gap-2`,children:[(0,z.jsxs)(`div`,{className:`flex items-center gap-1`,children:[e.primaryUrl?(0,z.jsx)(X,{asChild:!0,variant:`ghost`,size:`icon-sm`,children:(0,z.jsx)(`a`,{href:e.primaryUrl,target:`_blank`,rel:`noreferrer`,title:Q(t,`media.open`),"aria-label":Q(t,`media.open`),children:(0,z.jsx)(Vt,{className:`size-3.5`,"aria-hidden":!0})})}):null,(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:Q(t,`media.delete`),"aria-label":Q(t,`media.delete`),disabled:f.isPending,onClick:()=>void m(),children:(0,z.jsx)(jn,{className:`size-3.5`,"aria-hidden":!0})})]}),(0,z.jsx)(X,{type:`button`,size:`sm`,variant:`secondary`,disabled:!u||d.isPending,onClick:()=>d.mutate(),children:d.isPending?Q(t,`media.saving`):d.isSuccess&&!u?Q(t,`media.saved`):Q(t,`media.save`)})]}),d.isError?(0,z.jsx)(Ky,{error:d.error}):null,f.isError?(0,z.jsx)(Ky,{error:f.error}):null]}),(0,z.jsx)(`p`,{className:`text-[11px] text-muted-foreground`,children:Q(t,`media.uploaded`,{date:ax(e.createdAt)??`-`})})]})]})}function ZE({searchTerm:e,language:t}){let{navigate:n}=kv(),[r,i]=R.useState(e);return R.useEffect(()=>i(e),[e]),(0,z.jsx)(`form`,{className:`mb-4 max-w-xl`,role:`search`,onSubmit:e=>{e.preventDefault();let t=r.trim(),i=new URLSearchParams;t&&i.set(`search`,t);let a=i.toString();n(`/admin/media${a?`?${a}`:``}`)},children:(0,z.jsxs)(`label`,{className:`relative block`,children:[(0,z.jsx)(xn,{className:`pointer-events-none absolute left-3 top-1/2 size-4 -translate-y-1/2 text-muted-foreground`,"aria-hidden":!0}),(0,z.jsx)(O_,{className:`pl-9`,value:r,onChange:e=>i(e.target.value),placeholder:Q(t,`media.searchPlaceholder`)})]})})}function QE(){return(0,z.jsx)(`div`,{className:`grid grid-cols-2 gap-4 sm:grid-cols-3 lg:grid-cols-4`,children:[0,1,2,3,4,5,6,7].map(e=>(0,z.jsxs)(`div`,{className:`overflow-hidden rounded-lg border`,children:[(0,z.jsx)(L_,{className:`aspect-square rounded-none`}),(0,z.jsxs)(`div`,{className:`space-y-2 p-3`,children:[(0,z.jsx)(L_,{className:`h-3 w-1/2`}),(0,z.jsx)(L_,{className:`h-8`})]})]},e))})}function $E(e){return e==null||!Number.isFinite(e)?``:e<1024?`${e} B`:e<1048576?`${Math.round(e/1024)} KB`:`${(e/1048576).toFixed(1)} MB`}function eD({locale:e}){return e?(0,z.jsxs)(bb,{variant:`outline`,title:e,children:[(0,z.jsx)(Gt,{"aria-hidden":!0}),tD(e),(0,z.jsx)(`span`,{className:`font-mono text-[0.625rem] text-muted-foreground`,children:e})]}):(0,z.jsx)(`span`,{className:`text-muted-foreground`,children:`-`})}function tD(e){try{return new Intl.DisplayNames([e],{type:`language`}).of(e)??e}catch{return e}}function nD({locales:e,available:t,language:n}){let[r,i]=R.useState(!1);if(e.length===0)return null;let a=new Set(t),[o,s]=aD(e),c=s.every(e=>a.has(e));return(0,z.jsxs)(`div`,{className:`flex flex-wrap gap-1`,children:[o.map(e=>(0,z.jsx)(rD,{locale:e,available:a.has(e),language:n,showTooltip:!r},e)),s.length>0?(0,z.jsxs)(iE,{open:r,onOpenChange:i,children:[(0,z.jsx)(aE,{asChild:!0,children:(0,z.jsx)(bb,{asChild:!0,variant:c?`secondary`:`outline`,className:c?void 0:`border-dashed text-muted-foreground opacity-60`,children:(0,z.jsxs)(`button`,{type:`button`,"aria-label":Q(n,`collection.moreLanguages`,{count:String(s.length)}),children:[c?(0,z.jsx)(Dt,{className:`text-[color:var(--success)]`,"aria-hidden":!0}):null,`…`,Q(n,`collection.moreLanguages`,{count:String(s.length)})]})})}),(0,z.jsx)(oE,{align:`end`,className:`w-56 max-w-[calc(100vw-2rem)] p-1.5`,children:(0,z.jsx)(`ul`,{className:`grid gap-0.5`,children:s.map(e=>{let t=a.has(e),r=iD(e,t,n);return(0,z.jsxs)(`li`,{"aria-label":r,className:t?`flex items-center gap-2 rounded-md px-2 py-1.5 text-xs`:`flex items-center gap-2 rounded-md px-2 py-1.5 text-xs text-muted-foreground opacity-60`,children:[t?(0,z.jsx)(Dt,{className:`size-3 text-[color:var(--success)]`,"aria-hidden":!0}):(0,z.jsx)(`span`,{className:`size-3`,"aria-hidden":!0}),(0,z.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:tD(e)}),(0,z.jsx)(`span`,{className:`font-mono text-[0.625rem] text-muted-foreground`,children:e})]},e)})})})]}):null]})}function rD({locale:e,available:t,language:n,showTooltip:r=!0}){let i=iD(e,t,n),a=(0,z.jsxs)(bb,{variant:t?`secondary`:`outline`,className:t?void 0:`border-dashed text-muted-foreground opacity-60`,"aria-label":i,children:[t?(0,z.jsx)(Dt,{className:`text-[color:var(--success)]`,"aria-hidden":!0}):null,e]});return r?(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:a}),(0,z.jsx)(V_,{className:`bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 [&>svg]:fill-popover!`,children:i})]}):a}function iD(e,t,n){return Q(n,t?`collection.availableLanguage`:`collection.missingLanguage`,{language:tD(e),locale:e})}function aD(e){return e.length<=3?[[...e],[]]:[e.slice(0,2),e.slice(2)]}function oD(e,t,n=``){let r=e?.properties?.locale?.enum?.filter(e=>typeof e==`string`)??[];return[...new Set([...t??[],...r,...n?[n]:[]])]}function sD({collectionName:e,entryId:t}){let{language:n}=Iv(),r=Ke(),i=R.useMemo(()=>[`entry-editor`,e,t],[e,t]),a=st({queryKey:i,queryFn:()=>Z.get(`/entries/${encodeURIComponent(t)}`)}),o=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}),s=st({queryKey:[`me`],queryFn:()=>Z.get(`/me`),retry:!1}),c=st(Cv()),l=R.useMemo(()=>BD(c.data,e),[c.data,e]),[u,d]=R.useState(null),[f,p]=R.useState(!1);R.useEffect(()=>p(!1),[e,t]),R.useEffect(()=>{a.data&&d(a.data.entry.data)},[a.data]);let m=R.useCallback(e=>{d(e.entry.data),r.setQueryData(i,e)},[r,i]),h=ct({mutationFn:e=>Z.patch(`/entries/${encodeURIComponent(t)}`,{data:e,expectedVersion:a.data?.entry.version}),onSuccess:m}),g=ct({mutationFn:()=>Z.post(`/entries/${encodeURIComponent(t)}/publish`,{}),onSuccess:m}),_=ct({mutationFn:()=>Z.post(`/entries/${encodeURIComponent(t)}/unpublish`,{}),onSuccess:m}),v=ct({mutationFn:({section:e,locale:t})=>Z.post(`/entries`,{collection:e.collection.name,data:{[e.relationship.childField]:e.relationship.parentValue,locale:t}}),onSuccess:e=>{window.location.href=`/admin/c/${encodeURIComponent(e.entry.collection)}/${encodeURIComponent(e.entry.id)}`}});if(a.isLoading)return(0,z.jsx)(cD,{});if(a.isError)return(0,z.jsx)(Ky,{error:a.error});if(!a.data||!u)return(0,z.jsx)(Ky,{error:Error(Q(n,`common.unknownError`))});let y=a.data,b=o.data?.canonicalLocale??null,x=ED(u,Q(n,`collection.untitled`),y.collection,y.entry.id),S=_v(y.collection.title,n,b)??y.collection.name,C=y.collection.translates?.parent??e,w=y.collection.translates?.parent??S,T=_v(y.collection.description,n,b),E=JSON.stringify(u)!==JSON.stringify(y.entry.data),ee=y.collection.lifecycle===`operational`,D=y.collection.schema.readOnly===!0,O=y.entry.status===`draft`,k=DD(u,y.collection.schema),A=s.data?.role===`owner`||s.data?.role===`editor`,j=pD({role:s.data?.role,isReadOnly:D,isOperational:ee,isDraft:O,operationalEditUnlocked:f}),M=j&&E&&(O||ee),N=h.isPending||g.isPending||_.isPending,te=o.data?.media?.purposes??[],P=wD(y.collection,u,y.parentEntryId),F=y.related.filter(e=>e.relationship.kind===`translation`),ne=y.related.filter(TD),re=typeof u.locale==`string`?u.locale:``,ie=oD(y.collection.schema,o.data?.locales,re),ae=fD(y.collection);return(0,z.jsxs)(`div`,{className:`flex min-h-full flex-col gap-6`,children:[(0,z.jsx)(Hy,{eyebrow:(0,z.jsxs)(`span`,{className:`inline-flex flex-wrap items-center gap-x-2 gap-y-1`,children:[(0,z.jsxs)(`a`,{href:`/admin/c/${encodeURIComponent(C)}`,className:`inline-flex items-center gap-2 hover:underline`,children:[(0,z.jsx)(yt,{className:`size-3.5`,"aria-hidden":!0}),Q(n,`entryEdit.back`,{name:w})]}),P?(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`span`,{className:`text-foreground/30`,children:`/`}),(0,z.jsx)(`a`,{href:P.href,className:`hover:underline`,children:Q(n,`entryEdit.parent`,{name:P.label})})]}):null]}),title:x,description:Q(n,`entryEdit.body`,{name:S}),actions:(0,z.jsxs)(z.Fragment,{children:[y.collection.localized&&!y.collection.translates?(0,z.jsx)(CD,{language:n,locale:re,locales:ie,disabled:!j||y.entry.locale!==null,onChange:e=>d({...u,locale:e})}):null,!ee&&(0,z.jsx)($b,{status:y.entry.status}),(0,z.jsx)(WD,{row:y.entry,operations:l,language:n,canonical:b,onSuccess:()=>void r.invalidateQueries({queryKey:i}),trigger:(0,z.jsxs)(X,{type:`button`,variant:`secondary`,children:[(0,z.jsx)(Bt,{className:`size-4`,"aria-hidden":!0}),Q(n,`rowActions.menuLabel`)]})})]})}),F.map(e=>(0,z.jsx)(SD,{section:e,currentCollection:y.collection.name,currentEntryId:y.entry.id,sharedHref:P?.href,language:n,siteLocales:o.data?.locales,canCreate:!!s.data?.role,pending:v.isPending&&v.variables?.section.collection.name===e.collection.name,onCreate:t=>v.mutate({section:e,locale:t})},`${e.collection.name}:${e.relationship.childField}`)),D?(0,z.jsx)(`p`,{className:`-mt-4 text-sm text-muted-foreground`,children:Q(n,`entryEdit.readOnlyHint`)}):ee?(0,z.jsxs)(`div`,{className:`-mt-4 flex flex-wrap items-center gap-3 text-sm text-muted-foreground`,children:[(0,z.jsx)(`p`,{children:Q(n,`entryEdit.operationalHint`)}),A&&!f?(0,z.jsxs)(X,{type:`button`,variant:`outline`,size:`sm`,onClick:()=>p(!0),children:[(0,z.jsx)(sn,{className:`size-4`,"aria-hidden":!0}),Q(n,`entryEdit.unlockOperational`)]}):null]}):null,h.isError?(0,z.jsx)(qy,{error:h.error}):null,g.isError?(0,z.jsx)(qy,{error:g.error}):null,_.isError?(0,z.jsx)(qy,{error:_.error}):null,v.isError?(0,z.jsx)(qy,{error:v.error}):null,(0,z.jsxs)(`div`,{className:`grid gap-5 lg:grid-cols-[minmax(0,1fr)_22rem]`,children:[(0,z.jsxs)(`div`,{className:`space-y-5`,children:[(0,z.jsxs)(Uy,{children:[(0,z.jsx)(lD,{title:Q(n,`entryEdit.fields`),body:T?(0,z.jsx)(Yy,{description:T,summaryLabel:Q(n,`collection.schemaDetails`),collapsedIntro:Q(n,rO(y.collection),{name:S})}):void 0}),(0,z.jsx)(`fieldset`,{disabled:!j,className:j?void 0:`pointer-events-none opacity-70`,children:(0,z.jsx)(dD,{schema:y.collection.schema,uiSchema:y.collection.uiSchema,value:u,path:[],onChange:d,language:n,canonical:b,collectionName:y.collection.name,mediaPurposes:te,hiddenRootFields:ae})})]}),ne.length>0?(0,z.jsx)(xD,{sections:ne,language:n,canonical:b,operations:c.data,onOperationSuccess:()=>void r.invalidateQueries({queryKey:i})}):null]}),(0,z.jsx)(`div`,{className:`space-y-4`,children:(0,z.jsxs)(Uy,{children:[(0,z.jsx)(lD,{title:Q(n,`entryEdit.meta`),body:`${y.entry.collection} / ${y.entry.id}`}),(0,z.jsxs)(`dl`,{className:`space-y-3 text-sm`,children:[!ee&&(0,z.jsx)(uD,{label:Q(n,`collection.table.status`),value:(0,z.jsx)($b,{status:y.entry.status})}),(0,z.jsx)(uD,{label:Q(n,`collection.table.version`),value:`v${y.entry.version}`})]})]})})]}),j||A&&!ee?(0,z.jsxs)(Wy,{status:h.isPending?Q(n,`crud.saving`):g.isPending?Q(n,`entryEdit.publishing`):_.isPending?Q(n,`entryEdit.unpublishing`):E?Q(n,`common.unsavedChanges`):O&&!ee&&k?Q(n,`entryEdit.publishMissingRequired`):h.isSuccess?Q(n,`common.saved`):void 0,children:[A&&!ee&&(O?(0,z.jsxs)(X,{type:`button`,variant:`secondary`,onClick:()=>g.mutate(),disabled:N||E||k,title:E?Q(n,`entryEdit.publishDisabledDirty`):k?Q(n,`entryEdit.publishMissingRequired`):Q(n,`entryEdit.publishTooltip`),children:[(0,z.jsx)(Sn,{className:`size-4`,"aria-hidden":!0}),g.isPending?Q(n,`entryEdit.publishing`):Q(n,`entryEdit.publish`)]}):(0,z.jsxs)(X,{type:`button`,variant:`secondary`,onClick:()=>_.mutate(),disabled:N,title:Q(n,`entryEdit.unpublishTooltip`),children:[(0,z.jsx)(yn,{className:`size-4`,"aria-hidden":!0}),_.isPending?Q(n,`entryEdit.unpublishing`):Q(n,`entryEdit.unpublish`)]})),j?(0,z.jsxs)(X,{type:`button`,onClick:()=>h.mutate(u),disabled:N||!M,title:Q(n,`entryEdit.saveTooltip`),children:[(0,z.jsx)(bn,{className:`size-4`,"aria-hidden":!0}),h.isPending?Q(n,`crud.saving`):Q(n,`entryEdit.save`)]}):null]}):null]})}function cD(){return(0,z.jsxs)(`div`,{className:`flex min-h-full flex-col gap-6`,"aria-busy":`true`,children:[(0,z.jsxs)(`div`,{className:`space-y-2`,"aria-hidden":!0,children:[(0,z.jsx)(L_,{className:`h-4 w-32`}),(0,z.jsx)(L_,{className:`h-8 w-56 max-w-full`}),(0,z.jsx)(L_,{className:`h-4 w-80 max-w-full`})]}),(0,z.jsxs)(`div`,{className:`grid gap-5 lg:grid-cols-[minmax(0,1fr)_22rem]`,"aria-hidden":!0,children:[(0,z.jsxs)(Uy,{children:[(0,z.jsxs)(`div`,{className:`mb-6 space-y-2`,children:[(0,z.jsx)(L_,{className:`h-6 w-28`}),(0,z.jsx)(L_,{className:`h-4 w-2/3`})]}),(0,z.jsx)(`div`,{className:`space-y-5`,children:[`w-24`,`w-36`,`w-20`,`w-32`,`w-24`].map((e,t)=>(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsx)(L_,{className:`h-4 ${e}`}),(0,z.jsx)(L_,{className:t===2?`h-24 w-full`:`h-9 w-full`})]},t))})]}),(0,z.jsxs)(Uy,{className:`h-fit`,children:[(0,z.jsxs)(`div`,{className:`mb-5 space-y-2`,children:[(0,z.jsx)(L_,{className:`h-6 w-24`}),(0,z.jsx)(L_,{className:`h-4 w-48 max-w-full`})]}),(0,z.jsx)(`div`,{className:`space-y-4`,children:[`w-20`,`w-28`,`w-24`].map((e,t)=>(0,z.jsxs)(`div`,{className:`flex items-center justify-between gap-4`,children:[(0,z.jsx)(L_,{className:`h-4 ${e}`}),(0,z.jsx)(L_,{className:`h-4 w-16`})]},t))})]})]}),(0,z.jsx)(Wy,{status:(0,z.jsx)(L_,{className:`h-4 w-28`}),children:(0,z.jsx)(L_,{className:`h-9 w-24`})})]})}function lD({title:e,body:t}){return(0,z.jsxs)(`div`,{className:`mb-4`,children:[(0,z.jsx)(`h2`,{className:`text-lg font-semibold`,children:e}),t?(0,z.jsx)(`div`,{className:`mt-1 text-sm leading-6 text-muted-foreground`,children:t}):null]})}function uD({label:e,value:t}){return(0,z.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,z.jsx)(`dt`,{className:`text-muted-foreground`,children:e}),(0,z.jsx)(`dd`,{className:`min-w-0 text-right font-medium`,children:t})]})}function dD({schema:e,uiSchema:t=null,value:n,path:r,onChange:i,language:a,canonical:o=null,collectionName:s,mediaPurposes:c,hiddenRootFields:l=[]}){let u=e.properties??{},d=new Set(e.required??[]);return(0,z.jsx)(`div`,{className:`space-y-5`,children:Object.entries(u).filter(([e])=>r.length>0||!l.includes(e)).map(([e,l])=>(0,z.jsx)(mD,{name:e,schema:l,widget:r.length===0?AD(t,e):null,required:d.has(e),value:ID(n,[...r,e]),path:[...r,e],rootValue:n,onChange:i,language:a,canonical:o,collectionName:s,mediaPurposes:c},[...r,e].join(`.`)))})}function fD(e){return[...e.localized?[`locale`]:[],...e.translates?[e.translates.on]:[]]}function pD({role:e,isReadOnly:t,isOperational:n,isDraft:r,operationalEditUnlocked:i}){return t?!1:e===`owner`||e===`editor`?!n||i:e===`contributor`&&!n&&r}function mD({name:e,schema:t,widget:n,required:r,value:i,path:a,rootValue:o,onChange:s,language:c,canonical:l=null,collectionName:u,mediaPurposes:d}){let f=OD(t),p=yv(e,t,c,l),m=bv(t,c,l),h=e=>s(LD(o,a,e)),g=MD(t);return(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsxs)(`label`,{className:`flex items-center gap-1.5 text-sm font-semibold text-foreground`,children:[p,r&&!g?(0,z.jsx)(`span`,{className:`text-destructive`,children:`*`}):null]}),m?(0,z.jsx)(`p`,{className:`text-xs leading-5 text-muted-foreground`,children:m}):null,g?(0,z.jsxs)(`p`,{role:`textbox`,"aria-readonly":`true`,className:`flex min-h-9 cursor-not-allowed items-center justify-between gap-3 rounded-lg border border-transparent bg-muted px-3 py-2 text-sm text-muted-foreground`,children:[(0,z.jsx)(`span`,{children:(rx(t)?ax(i):ND(i))||Q(c,`entryEdit.emptyOption`)}),(0,z.jsx)(sn,{className:`size-4 shrink-0`,"aria-hidden":`true`})]}):t.enum?(0,z.jsxs)(sE,{value:ND(i)||`__empty__`,onValueChange:e=>h(e===`__empty__`?``:e),children:[(0,z.jsx)(lE,{className:`w-full`,"aria-label":p,children:(0,z.jsx)(cE,{})}),(0,z.jsxs)(uE,{children:[(0,z.jsx)(dE,{value:`__empty__`,children:Q(c,`entryEdit.emptyOption`)}),t.enum.map(e=>(0,z.jsx)(dE,{value:String(e),children:String(e)},String(e)))]})]}):f===`boolean`?(0,z.jsxs)(`label`,{className:`inline-flex items-center gap-2 text-sm text-muted-foreground`,children:[(0,z.jsx)(Tb,{checked:!!i,onCheckedChange:e=>h(e===!0)}),Q(c,`entryEdit.boolean`)]}):f===`number`||f===`integer`?(0,z.jsxs)(`div`,{className:`space-y-1`,children:[rx(t)?(0,z.jsx)(hD,{label:p,language:c,value:i,onChange:e=>h(e?.getTime()??null)}):(0,z.jsx)(O_,{type:`number`,"aria-label":p,value:PD(i),min:t.minimum,max:t.maximum,onChange:e=>{let t=e.target.value;h(t===``?null:Number(t))}}),(0,z.jsx)(gD,{schema:t,value:i,rootValue:o})]}):f===`object`?(0,z.jsx)(`div`,{className:`rounded-lg border bg-muted/20 p-4`,children:t.properties?(0,z.jsx)(dD,{schema:t,value:o,path:a,onChange:s,language:c,canonical:l,collectionName:u,mediaPurposes:d}):(0,z.jsx)(bD,{value:i,onChange:h})}):jD(t)?(0,z.jsx)(vD,{value:i,path:a,collectionName:u,mediaPurposes:d,language:c,onChange:h}):f===`array`?(0,z.jsx)(_D,{schema:t,value:Array.isArray(i)?i:[],path:a,rootValue:o,onChange:s,language:c,canonical:l,collectionName:u,mediaPurposes:d}):kD(t,n)===`richtext`?(0,z.jsx)(jE,{compact:!0,value:ND(i),onChange:h}):kD(t,n)===`textarea`?(0,z.jsx)(mE,{"aria-label":p,className:`min-h-24`,value:ND(i),maxLength:t.maxLength,onChange:e=>h(e.target.value)}):t.format===`date-time`?(0,z.jsx)(hD,{label:p,language:c,value:i,onChange:e=>h(e?.toISOString()??``)}):(0,z.jsx)(O_,{type:`text`,"aria-label":p,value:ND(i),onChange:e=>h(e.target.value)})]})}function hD({label:e,language:t,value:n,onChange:r}){let i=ox(n),a=R.useId();return(0,z.jsxs)(iE,{children:[(0,z.jsx)(aE,{asChild:!0,children:(0,z.jsxs)(X,{type:`button`,variant:`outline`,className:`w-full justify-start font-normal`,"aria-label":e,children:[(0,z.jsx)(Tt,{}),i?ax(i.getTime()):Q(t,`entryEdit.dateTime.select`)]})}),(0,z.jsxs)(oE,{className:`w-auto p-0`,align:`start`,children:[(0,z.jsx)(nE,{mode:`single`,selected:i,defaultMonth:i,onSelect:e=>{if(!e)return;let t=new Date(e);t.setHours(i?.getHours()??0,i?.getMinutes()??0,0,0),r(t)}}),(0,z.jsxs)(`div`,{className:`flex items-center gap-3 border-t p-3`,children:[(0,z.jsx)(`label`,{className:`text-sm font-medium`,htmlFor:a,children:Q(t,`entryEdit.dateTime.time`)}),(0,z.jsx)(O_,{id:a,type:`time`,className:`w-32`,disabled:!i,value:i?`${String(i.getHours()).padStart(2,`0`)}:${String(i.getMinutes()).padStart(2,`0`)}`:``,onChange:e=>{if(!i)return;let[t,n]=e.target.value.split(`:`).map(Number),a=new Date(i);a.setHours(t,n,0,0),r(a)}})]})]})]})}function gD({schema:e,value:t,rootValue:n}){if(nx(e)){let e=ix(t,n.currency);return e?(0,z.jsxs)(`p`,{className:`text-xs text-muted-foreground`,children:[`= `,e]}):null}if(rx(e)){let e=ax(t);return e?(0,z.jsxs)(`p`,{className:`text-xs text-muted-foreground`,children:[`= `,e]}):null}return null}function _D({schema:e,value:t,path:n,rootValue:r,onChange:i,language:a,canonical:o=null,collectionName:s,mediaPurposes:c}){let l=e.items??{},u=e=>i(LD(r,n,e));return(0,z.jsxs)(`div`,{className:`space-y-3 rounded-lg border bg-muted/20 p-3`,children:[t.map((e,d)=>(0,z.jsxs)(`div`,{className:`rounded-lg border border-border/70 bg-card/50 p-3`,children:[(0,z.jsxs)(`div`,{className:`mb-3 flex items-center justify-between gap-2`,children:[(0,z.jsxs)(`span`,{className:`text-xs font-semibold text-muted-foreground`,children:[`#`,d+1]}),(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:Q(a,`entryEdit.removeItem`),"aria-label":Q(a,`entryEdit.removeItem`),onClick:()=>u(t.filter((e,t)=>t!==d)),children:(0,z.jsx)(jn,{className:`size-3.5`,"aria-hidden":!0})})]}),OD(l)===`object`&&l.properties?(0,z.jsx)(dD,{schema:l,value:r,path:[...n,String(d)],onChange:i,language:a,canonical:o,collectionName:s,mediaPurposes:c}):(0,z.jsx)(O_,{value:ND(e),onChange:e=>{let n=[...t];n[d]=e.target.value,u(n)}})]},d)),(0,z.jsxs)(X,{type:`button`,variant:`secondary`,size:`sm`,onClick:()=>u([...t,FD(l)]),children:[(0,z.jsx)(_n,{className:`size-3.5`,"aria-hidden":!0}),Q(a,`entryEdit.addItem`)]})]})}function vD({value:e,path:t,collectionName:n,mediaPurposes:r,language:i,onChange:a}){let o=R.useRef(null),[s,c]=R.useState(!1),[l,u]=R.useState(null),[d,f]=R.useState(null),[p,m]=R.useState(!1),h=vE(r,n,t),g=typeof e==`string`?e:``,_=st({queryKey:[`media-asset`,g],queryFn:()=>Z.get(`/media/${encodeURIComponent(g)}`),enabled:g.length>0,retry:!1});async function v(e){c(!0),u(null);try{let t=await gE({file:e,purposes:r,preferredPurpose:h,language:i});a(t.id),f(yE(t))}catch(e){u(e instanceof Error?e.message:String(e))}finally{c(!1),o.current&&(o.current.value=``)}}return(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsxs)(`div`,{className:`flex flex-wrap items-center gap-2`,children:[(0,z.jsx)(yD,{assetId:g,asset:_.data,isError:_.isError,language:i}),(0,z.jsx)(O_,{className:`min-w-0 flex-1`,value:ND(e),onChange:e=>a(e.target.value)}),(0,z.jsxs)(X,{type:`button`,variant:`secondary`,onClick:()=>m(!0),children:[(0,z.jsx)(Xt,{className:`size-4`,"aria-hidden":!0}),Q(i,`media.pick`)]}),(0,z.jsxs)(X,{type:`button`,variant:`secondary`,onClick:()=>o.current?.click(),disabled:s||r.length===0,title:h??Q(i,`entryEdit.noMediaPurpose`),children:[(0,z.jsx)(Jt,{className:`size-4`,"aria-hidden":!0}),s?Q(i,`entryEdit.uploadingMedia`):Q(i,`entryEdit.uploadMedia`)]})]}),(0,z.jsx)(`input`,{ref:o,type:`file`,accept:`image/*`,className:`hidden`,onChange:e=>{let t=e.currentTarget.files?.[0];t&&v(t)}}),h?(0,z.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:h}):null,d?(0,z.jsx)(`a`,{className:`text-xs text-primary hover:underline`,href:d,target:`_blank`,rel:`noreferrer`,children:d}):null,l?(0,z.jsx)(`p`,{className:`text-xs text-destructive`,children:l}):null,(0,z.jsx)(Vx,{open:p,onOpenChange:m,children:(0,z.jsxs)(Wx,{closeLabel:Q(i,`common.close`),className:`max-h-[85vh] w-full max-w-3xl overflow-y-auto`,children:[(0,z.jsxs)(Gx,{children:[(0,z.jsx)(qx,{children:Q(i,`media.pickTitle`)}),(0,z.jsx)(Jx,{children:Q(i,`media.pickDescription`)})]}),(0,z.jsx)(qE,{language:i,purposes:r,searchTerm:``,emptyIcon:Xt,onPick:e=>{a(e.id),f(e.primaryUrl),m(!1)}})]})})]})}function yD({assetId:e,asset:t,isError:n,language:r}){return e?(0,z.jsx)(`div`,{className:`flex size-9 shrink-0 items-center justify-center overflow-hidden rounded-md border bg-muted/40`,title:n?Q(r,`entryEdit.mediaMissing`):e,children:t?.primaryUrl?(0,z.jsx)(`img`,{src:t.primaryUrl,alt:``,className:`size-full object-cover`}):(0,z.jsx)(Xt,{className:`size-4 text-muted-foreground`,"aria-hidden":!0})}):null}function bD({value:e,onChange:t}){let[n,r]=R.useState(JSON.stringify(e??{},null,2)),[i,a]=R.useState(null);return R.useEffect(()=>{r(JSON.stringify(e??{},null,2))},[e]),(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsx)(mE,{className:`min-h-32 font-mono`,value:n,onChange:e=>{let n=e.target.value;r(n);try{t(JSON.parse(n)),a(null)}catch(e){a(e instanceof Error?e.message:String(e))}}}),i?(0,z.jsx)(`p`,{className:`text-xs text-destructive`,children:i}):null]})}function xD({sections:e,language:t,canonical:n,operations:r,onOperationSuccess:i}){return(0,z.jsx)(z.Fragment,{children:e.map(e=>{let a=BD(r,e.collection.name);return(0,z.jsxs)(Uy,{children:[(0,z.jsx)(lD,{title:_v(e.collection.title,t,n)??e.collection.name,body:Q(t,`entryEdit.relationship`,{child:e.relationship.childField,parent:e.relationship.parentField})}),(0,z.jsx)(`div`,{className:`space-y-2`,children:e.entries.length===0?(0,z.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:Q(t,`entryEdit.noChildEntries`)}):e.entries.map(r=>(0,z.jsxs)(`div`,{className:`flex items-center justify-between gap-3 rounded-lg border bg-card p-3 text-sm text-foreground transition-colors hover:bg-accent`,children:[(0,z.jsxs)(`a`,{href:`/admin/c/${encodeURIComponent(r.collection)}/${encodeURIComponent(r.id)}`,className:`flex min-w-0 flex-1 items-center gap-3`,children:[(0,z.jsxs)(`span`,{className:`min-w-0`,children:[(0,z.jsx)(`span`,{className:`block truncate font-semibold`,children:ED(r.data,Q(t,`collection.untitled`),e.collection,r.id)}),(0,z.jsxs)(`span`,{className:`mt-1 flex flex-wrap items-center gap-2 text-xs text-muted-foreground`,children:[r.collection,(0,z.jsx)($b,{status:r.status}),(0,z.jsxs)(`span`,{children:[`v`,r.version]})]})]}),(0,z.jsx)(Vt,{className:`size-4 shrink-0 text-muted-foreground`,"aria-hidden":!0})]}),(0,z.jsx)(WD,{row:r,operations:a,language:t,canonical:n,onSuccess:i})]},r.id))})]},`${e.collection.name}:${e.relationship.childField}`)})})}function SD({section:e,currentCollection:t,currentEntryId:n,sharedHref:r,language:i,siteLocales:a,canCreate:o,pending:s,onCreate:c}){let l=oD(e.collection.schema,a),u=t!==e.collection.name;return(0,z.jsx)(`nav`,{"aria-label":Q(i,`entryEdit.languageTabs`),className:`-mt-2 border-b`,children:(0,z.jsxs)(`div`,{role:`tablist`,className:`flex max-w-full gap-1 overflow-x-auto pb-2`,children:[u?(0,z.jsx)(`span`,{role:`tab`,"aria-selected":`true`,className:D_({variant:`secondary`,size:`sm`}),children:Q(i,`entryEdit.sharedFields`)}):r?(0,z.jsx)(`a`,{role:`tab`,"aria-selected":`false`,href:r,className:D_({variant:`ghost`,size:`sm`}),children:Q(i,`entryEdit.sharedFields`)}):null,l.map(t=>{let r=e.entries.find(e=>e.locale===t),a=r?.id===n,l=`${tD(t)} · ${t}`;if(r)return(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:(0,z.jsxs)(`a`,{role:`tab`,"aria-selected":a,"aria-current":a?`page`:void 0,href:`/admin/c/${encodeURIComponent(r.collection)}/${encodeURIComponent(r.id)}`,className:D_({variant:a?`secondary`:`ghost`,size:`sm`}),children:[(0,z.jsx)(Gt,{"aria-hidden":!0}),(0,z.jsx)(`span`,{className:`max-w-40 truncate`,children:tD(t)}),(0,z.jsx)(`span`,{className:`font-mono text-[0.625rem] text-muted-foreground`,children:t})]})}),(0,z.jsx)(V_,{children:l})]},t);let u=!o||s||e.relationship.parentValue===null,d=(0,z.jsxs)(X,{type:`button`,role:`tab`,"aria-selected":`false`,variant:`outline`,size:`sm`,className:`border-dashed`,disabled:u,onClick:()=>c(t),children:[(0,z.jsx)(_n,{"aria-hidden":!0}),(0,z.jsx)(`span`,{className:`max-w-40 truncate`,children:tD(t)}),(0,z.jsx)(`span`,{className:`font-mono text-[0.625rem] text-muted-foreground`,children:t})]});return e.relationship.parentValue===null?(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:(0,z.jsx)(`span`,{className:`inline-flex`,children:d})}),(0,z.jsx)(V_,{children:Q(i,`entryEdit.saveSharedFirst`)})]},t):(0,z.jsx)(R.Fragment,{children:d},t)})]})})}function CD({language:e,locale:t,locales:n,disabled:r,onChange:i}){return r?(0,z.jsxs)(z_,{children:[(0,z.jsx)(B_,{asChild:!0,children:(0,z.jsx)(`span`,{className:`inline-flex cursor-default`,children:(0,z.jsx)(eD,{locale:t||null})})}),(0,z.jsx)(V_,{children:Q(e,`entryEdit.languageLocked`)})]}):(0,z.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,z.jsx)(Gt,{className:`size-4 text-primary`,"aria-hidden":!0}),(0,z.jsx)(`span`,{className:`sr-only`,children:Q(e,`entryEdit.contentLanguage`)}),(0,z.jsxs)(sE,{value:t||void 0,onValueChange:i,children:[(0,z.jsx)(lE,{size:`sm`,"aria-label":Q(e,`entryEdit.contentLanguage`),children:(0,z.jsx)(cE,{placeholder:Q(e,`entryEdit.selectLanguage`)})}),(0,z.jsx)(uE,{children:n.map(e=>(0,z.jsxs)(dE,{value:e,children:[tD(e),` · `,e]},e))})]})]})}function wD(e,t,n){if(!e.parent||!n)return null;let r=t[e.parent.childField];return typeof r!=`string`&&typeof r!=`number`&&typeof r!=`boolean`?null:{href:`/admin/c/${encodeURIComponent(e.parent.collection)}/${encodeURIComponent(n)}`,label:`${e.parent.collection} / ${String(r)}`}}function TD(e){return e.relationship.kind===`field`}function ED(e,t,n,r){if(n?.lifecycle===`operational`){let i=n.list?.primaryField,a=i?e[i]:void 0;return typeof a==`string`&&a.trim()?a:typeof a==`number`||typeof a==`boolean`?String(a):r||t}for(let t of[`title`,`name`,`slug`,`id`]){let n=e[t];if(typeof n==`string`&&n.trim())return n}if(n?.schema){let t=n.schema.properties??{};for(let r of n.schema.required??[]){let n=t[r];if(!n||OD(n)!==`string`)continue;let i=e[r];if(typeof i==`string`&&i.trim())return i}}return t}function DD(e,t){return(t.required??[]).some(t=>{let n=e[t];return n==null||n===``||Array.isArray(n)&&n.length===0})}function OD(e){return(Array.isArray(e.type)?e.type.find(e=>e!==`null`):e.type)||(e.properties?`object`:e.items?`array`:`string`)}function kD(e,t){let n=typeof e[`x-mcp-hint`]==`string`?e[`x-mcp-hint`]:``;return n===`markdown`||n===`html`||n===`richtext`?`richtext`:t??`input`}function AD(e,t){let n=e?.fields;if(!n||typeof n!=`object`||Array.isArray(n))return null;let r=n[t];return!r||typeof r!=`object`||Array.isArray(r)?null:r.widget===`textarea`?`textarea`:null}function jD(e){return e[`x-mantle-ref`]===`media_assets`}function MD(e){return typeof e[`x-mantle-bind`]==`string`}function ND(e){return e==null?``:typeof e==`string`?e:typeof e==`number`||typeof e==`boolean`?String(e):JSON.stringify(e)}function PD(e){return typeof e==`number`&&Number.isFinite(e)||typeof e==`string`?e:``}function FD(e){if(e.default!==void 0)return e.default;let t=OD(e);return t===`object`?{}:t===`array`?[]:t===`boolean`?!1:t===`number`||t===`integer`?0:``}function ID(e,t){let n=e;for(let e of t)if(Array.isArray(n))n=n[Number(e)];else if(typeof n==`object`&&n)n=n[e];else return;return n}function LD(e,t,n){if(t.length===0)return RD(n);let r=structuredClone(e),i=r;for(let e=0;e<t.length-1;e+=1){let n=t[e],r=t[e+1];if(Array.isArray(i)){let e=Number(n);i[e]=i[e]??(zD(r)?[]:{}),i=i[e]}else if(typeof i==`object`&&i){let e=i;e[n]=e[n]??(zD(r)?[]:{}),i=e[n]}}let a=t[t.length-1];return Array.isArray(i)?i[Number(a)]=n:typeof i==`object`&&i&&(i[a]=n),r}function RD(e){return typeof e==`object`&&e&&!Array.isArray(e)?e:{}}function zD(e){return/^\d+$/.test(e)}function BD(e,t){return(e??[]).filter(e=>e.rowBindings.some(e=>e.collection===t))}function VD(e,t){return(e??[]).filter(e=>e.uiSchema?.collectionAction===t)}function HD(e){return Object.entries(e.properties??{}).filter(([,e])=>e[`x-mcp-hint`]===`idempotency-key`).map(([e])=>e)}function UD(e,t){let n=new Set(t),r={...e.properties??{}};for(let e of n)delete r[e];return{...e,properties:r,required:(e.required??[]).filter(e=>!n.has(e))}}function WD({row:e,operations:t,language:n,canonical:r,onSuccess:i,trigger:a}){let[o,s]=R.useState(null);return t.length===0?null:(0,z.jsxs)(z.Fragment,{children:[(0,z.jsxs)($v,{children:[(0,z.jsx)(ey,{asChild:!0,children:a??(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:Q(n,`rowActions.menuLabel`),"aria-label":Q(n,`rowActions.menuLabel`),children:(0,z.jsx)(Bt,{className:`size-3.5`,"aria-hidden":!0})})}),(0,z.jsx)(ty,{align:`end`,children:t.map(e=>(0,z.jsx)(ny,{onSelect:()=>s(e),children:_v(e.title,n,r)??vv(e.name)},e.name))})]}),o?(0,z.jsx)(KD,{operation:o,binding:o.rowBindings.find(t=>t.collection===e.collection),row:e,language:n,canonical:r,onClose:()=>s(null),onSuccess:()=>{s(null),i()}}):null]})}function GD({operations:e,language:t,canonical:n,onSuccess:r}){let[i,a]=R.useState(null);return e.length===0?null:(0,z.jsxs)(z.Fragment,{children:[e.map(e=>(0,z.jsxs)(X,{type:`button`,onClick:()=>a(e),children:[(0,z.jsx)(_n,{className:`size-4`,"aria-hidden":!0}),_v(e.title,t,n)??vv(e.name)]},e.name)),i?(0,z.jsx)(KD,{operation:i,language:t,canonical:n,onClose:()=>a(null),onSuccess:()=>{a(null),r()}}):null]})}function KD({operation:e,binding:t,row:n,language:r,canonical:i,onClose:a,onSuccess:o}){let s=_v(e.title,r,i)??vv(e.name),c=_v(e.description,r,i),l=t?.rowField??`id`,u=t?.inputField,d=st({queryKey:[`entry-editor`,n?.collection??``,n?.id??``],queryFn:()=>{if(!n)throw Error(`row operation is missing its row`);return Z.get(`/entries/${encodeURIComponent(n.id)}`)},enabled:!!n}),f=R.useMemo(()=>{if(n)return l===`id`?n.id:d.data?.entry.data[l]??void 0},[d.data,n,l]),p=R.useMemo(()=>HD(e.input),[e.input]),[m,h]=R.useState(()=>Object.fromEntries(p.map(e=>[e,crypto.randomUUID()])));R.useEffect(()=>{f===void 0||!u||h(e=>({...e,[u]:f}))},[f,u]);let g=R.useMemo(()=>UD(e.input,[...u?[u]:[],...p]),[p,e.input,u]),_=u?e.input.properties?.[u]:void 0,v=u?_v(_?.title,r,i)??_v(_?.description,r,i)??vv(u):null,y=ct({mutationFn:t=>Z.post(`/operations/${encodeURIComponent(e.name)}`,t),onSuccess:()=>{Tx.success(Q(r,`ops.success`,{name:s})),o()}}),b=!u||f!==void 0;return(0,z.jsx)(Vx,{open:!0,onOpenChange:e=>{e||a()},children:(0,z.jsxs)(Wx,{closeLabel:Q(r,`common.close`),children:[(0,z.jsxs)(Gx,{children:[(0,z.jsx)(qx,{children:s}),c?(0,z.jsx)(Jx,{children:c}):null]}),n&&d.isLoading?(0,z.jsx)(L_,{className:`h-24 w-full`}):(0,z.jsxs)(`div`,{className:`space-y-5`,children:[u?(0,z.jsxs)(`div`,{className:`space-y-2`,children:[(0,z.jsx)(`label`,{className:`text-sm font-semibold text-foreground`,children:v}),(0,z.jsx)(`p`,{className:`min-h-8 rounded-md border bg-muted/40 px-3 py-1.5 text-sm text-muted-foreground`,children:qD(f)})]}):null,(0,z.jsx)(dD,{schema:g,uiSchema:e.uiSchema,value:m,path:[],onChange:h,language:r,canonical:i,collectionName:e.name,mediaPurposes:[]})]}),n&&d.isError?(0,z.jsx)(Ky,{error:d.error}):null,y.isError?(0,z.jsx)(qy,{error:cx(y.error)}):null,(0,z.jsxs)(Kx,{children:[(0,z.jsx)(X,{type:`button`,variant:`secondary`,onClick:a,disabled:y.isPending,children:Q(r,`rowActions.cancel`)}),(0,z.jsx)(X,{type:`button`,onClick:()=>y.mutate(m),disabled:y.isPending||!b,children:y.isPending?Q(r,`ops.running`):Q(r,`ops.run`)})]})]})})}function qD(e){return e==null?``:typeof e==`string`||typeof e==`number`||typeof e==`boolean`?String(e):JSON.stringify(e)}function JD(e,t){if(nx(e)){let e=ix(t,void 0);if(e)return e}if(rx(e)){let e=ax(t);if(e)return e}return t==null||t===``?(0,z.jsx)(`span`,{className:`text-muted-foreground`,children:`-`}):typeof t==`string`||typeof t==`number`||typeof t==`boolean`?String(t):(0,z.jsx)(`span`,{className:`font-mono text-xs`,children:JSON.stringify(t)})}function YD(e,t){return typeof e==`string`&&e?e:e==null||e===``?Q(t,`collection.untitled`):JSON.stringify(e)}function XD({language:e,searchable:t=!0,searchValue:n=``,filters:r=[],onSubmit:i}){let a=r.filter(e=>e.options),o=r.filter(e=>!e.options);return(0,z.jsxs)(`form`,{className:Y(`space-y-3`,a.length>0?`mb-5`:`mb-3`),role:`search`,onSubmit:e=>{e.preventDefault();let t=new FormData(e.currentTarget);i({search:String(t.get(`search`)??``).trim(),filters:Object.fromEntries(r.map(({name:e})=>[e,String(t.get(`filter.${e}`)??``).trim()]))})},children:[t?(0,z.jsxs)(`div`,{className:`flex max-w-xl gap-2`,children:[(0,z.jsxs)(`label`,{className:`relative block flex-1`,"aria-label":Q(e,`collection.searchPlaceholder`),children:[(0,z.jsx)(xn,{className:`pointer-events-none absolute left-3 top-1/2 size-4 -translate-y-1/2 text-muted-foreground`,"aria-hidden":!0}),(0,z.jsx)(O_,{name:`search`,className:`h-9 ps-9`,defaultValue:n,placeholder:Q(e,`collection.searchPlaceholder`)})]}),(0,z.jsx)(QD,{language:e})]}):null,o.length>0?(0,z.jsxs)(`div`,{className:`flex flex-wrap items-end gap-3`,children:[o.map(e=>(0,z.jsxs)(`label`,{className:`grid gap-1.5 text-sm font-medium`,children:[(0,z.jsx)(`span`,{children:e.label}),(0,z.jsx)(O_,{name:`filter.${e.name}`,className:`h-9 w-48`,defaultValue:e.value??``})]},e.name)),t?null:(0,z.jsx)(QD,{language:e})]}):null,a.map(t=>(0,z.jsxs)(`div`,{className:`flex gap-2 overflow-x-auto pb-1`,"aria-label":t.label,children:[(0,z.jsx)(`input`,{type:`hidden`,name:`filter.${t.name}`,value:t.value??``}),(0,z.jsx)(ZD,{href:t.allHref??`#`,active:!t.value,children:Q(e,`collection.filter.all`)}),t.options?.map(e=>(0,z.jsx)(ZD,{href:e.href,active:t.value===e.value,children:e.label},e.value))]},t.name))]})}function ZD({href:e,active:t,children:n}){return(0,z.jsx)(`a`,{href:e,"aria-current":t?`page`:void 0,className:Y(`inline-flex h-8 shrink-0 items-center justify-center rounded-lg border px-3 text-xs font-medium`,`transition-colors duration-100 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring`,t?`border-border bg-secondary text-secondary-foreground`:`border-transparent text-muted-foreground hover:bg-accent hover:text-accent-foreground`),children:n})}function QD({language:e}){return(0,z.jsxs)(X,{type:`submit`,variant:`secondary`,size:`sm`,className:`h-9`,children:[(0,z.jsx)(xn,{className:`size-4`,"aria-hidden":!0}),Q(e,`collection.search`)]})}var $D=50;function eO({collectionName:e}){let{language:t}=Iv(),n=Av(),r=Ke(),i=new URLSearchParams(n.search),a=i.get(`status`)??void 0,o=i.get(`search`)?.trim()??``,s=i.get(`filter_field`)??void 0,c=i.get(`filter_value`)??void 0,l=i.get(`sort`)||`updatedAt`,u=i.get(`direction`)===`asc`?`asc`:`desc`,d=i.get(`cursor`)||void 0,f=i.get(`cursor_direction`)===`backward`?`backward`:`forward`,p=st({queryKey:[`collections`],queryFn:async()=>(await Z.get(`/collections`)).collections}),m=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}),h=st({queryKey:[`me`],queryFn:()=>Z.get(`/me`),retry:!1}),g=m.data?.canonicalLocale??null,_=st(Cv()),v=R.useMemo(()=>BD(_.data,e),[_.data,e]),y=R.useMemo(()=>VD(_.data,e),[_.data,e]),b=st({queryKey:[`entries`,e,a??`all`,o,s??`no-filter`,c??`no-value`,l,u,d??`first`,f],queryFn:()=>{let t=new URLSearchParams({collection:e,limit:String($D),sort:l,direction:u});return a&&t.set(`status`,a),o&&t.set(`search`,o),s&&c&&(t.set(`filter_field`,s),t.set(`filter_value`,c)),d&&t.set(`cursor`,d),f===`backward`&&t.set(`cursor_direction`,`backward`),Z.get(`/entries?${t.toString()}`)}}),[x,S]=R.useState(null);R.useEffect(()=>{b.data&&S(b.data)},[b.data]);let C=b.data??x,w=b.isLoading&&!C,[T,E]=R.useState(new Set),ee=R.useCallback(()=>E(new Set),[]),D=p.data?.find(t=>t.name===e),O=D?_v(D.title,t,g)??D.name:e,k=D?.lifecycle===`operational`,A=D?.schema?.readOnly===!0,j=h.data?.role===`owner`||h.data?.role===`editor`,M=!!h.data?.role&&!k&&!A,N=j&&!A,te=k?D?.list?.columns??[]:[],P=k?D?.filter??null:null,F=P?{name:P.field,label:yv(P.field,D?.schema?.properties?.[P.field],t,g),value:s===P.field?c:``,allHref:iO(e,{searchTerm:o,sortField:l,sortDirection:u}),options:P.values.map(t=>({value:t,label:vv(t),href:iO(e,{searchTerm:o,filterField:P.field,filterValue:t,sortField:l,sortDirection:u})}))}:D&&!k?{name:`status`,label:Q(t,`collection.table.status`),value:a,allHref:iO(D.name,{searchTerm:o,sortField:l,sortDirection:u}),options:wv.map(e=>({value:e,label:Fy(t,e),href:iO(D.name,{status:e,searchTerm:o,sortField:l,sortDirection:u})}))}:null,ne=k?D?.list?.primaryField??null:null,re=ne?yv(ne,D?.schema?.properties?.[ne],t,g):Q(t,`collection.table.title`),ie=R.useCallback(()=>{ee(),r.invalidateQueries({queryKey:[`entries`,e]})},[e,r,ee]),ae=ct({mutationFn:({id:e,title:t,version:n})=>Z.patch(`/entries/${encodeURIComponent(e)}`,{data:{title:t},expectedVersion:n}),onSuccess:ie}),I=ct({mutationFn:e=>Z.delete(`/entries/${encodeURIComponent(e)}`),onSuccess:ie}),L=ct({mutationFn:()=>Z.post(`/entries`,{collection:e,data:{}}),onSuccess:t=>{window.location.href=`/admin/c/${encodeURIComponent(e)}/${encodeURIComponent(t.entry.id)}`}});return(0,z.jsxs)(`div`,{children:[(0,z.jsx)(Hy,{eyebrow:(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(`a`,{href:`/admin`,className:`hover:underline`,children:Q(t,`collection.breadcrumb`)}),(0,z.jsx)(`span`,{className:`mx-2 text-foreground/30`,children:`/`}),(0,z.jsx)(`span`,{className:`text-foreground/70`,children:O})]}),title:O,description:nO(D,t,g),actions:(0,z.jsxs)(`div`,{className:`flex flex-wrap items-center justify-end gap-2`,children:[(0,z.jsxs)(X,{type:`button`,variant:`secondary`,onClick:()=>{let t=new URLSearchParams({collection:e});a&&t.set(`status`,a),o&&t.set(`search`,o),s&&c&&(t.set(`filter_field`,s),t.set(`filter_value`,c)),t.set(`sort`,l),t.set(`direction`,u),window.location.href=`/admin/api/entries/export?${t.toString()}`},children:[(0,z.jsx)(zt,{className:`size-4`,"aria-hidden":!0}),Q(t,`collection.export`)]}),D&&M?(0,z.jsxs)(X,{type:`button`,onClick:()=>L.mutate(),disabled:L.isPending,children:[(0,z.jsx)(_n,{className:`size-4`,"aria-hidden":!0}),L.isPending?Q(t,`crud.saving`):Q(t,`collection.create`)]}):null,(0,z.jsx)(GD,{operations:y,language:t,canonical:g,onSuccess:ie})]})}),L.isError?(0,z.jsx)(Ky,{error:L.error}):null,D?(0,z.jsx)(XD,{language:t,searchValue:o,filters:F?[F]:[],onSubmit:({search:e,filters:t})=>{let n=P?t[P.field]:void 0;window.location.href=iO(D.name,{status:k?a:t.status||void 0,searchTerm:e,filterField:n?P?.field:void 0,filterValue:n||void 0,sortField:l,sortDirection:u})}},n.search):null,w&&(0,z.jsx)(cO,{}),b.isError&&!C&&(0,z.jsx)(Ky,{error:b.error}),C&&C.items.length===0&&(0,z.jsx)(Gy,{icon:Ut,title:Q(t,`collection.empty.title`),description:o?Q(t,`collection.empty.search`,{search:o}):c?Q(t,`collection.empty.withStatus`,{collection:O,status:vv(c)}):a?Q(t,`collection.empty.withStatus`,{collection:O,status:a}):Q(t,`collection.empty.all`,{collection:O})}),C&&C.items.length>0&&(0,z.jsxs)(z.Fragment,{children:[T.size>0&&j&&!A?(0,z.jsx)(tO,{language:t,collection:D,selectedIds:[...T],onDone:ie,onClear:ee}):null,(0,z.jsxs)(Mb,{children:[(0,z.jsx)(Nb,{children:(0,z.jsxs)(Fb,{children:[N?(0,z.jsx)(Ib,{className:`w-10`,children:(0,z.jsx)(Tb,{"aria-label":Q(t,`collection.table.selectAll`),checked:C.items.every(e=>T.has(e.id))?!0:C.items.some(e=>T.has(e.id))?`indeterminate`:!1,onCheckedChange:e=>{E(t=>{let n=new Set(t);for(let t of C.items)e===!0?n.add(t.id):n.delete(t.id);return n})}})}):null,(0,z.jsx)(oO,{className:`hidden md:table-cell`,label:Q(t,`collection.table.id`),field:`id`,activeField:l,direction:u,href:aO(e,a,o,`id`,l,u,s,c)}),!k||ne?ne&&D?.sortableFields?.includes(ne)?(0,z.jsx)(oO,{label:re,field:ne,activeField:l,direction:u,href:aO(e,a,o,ne,l,u,s,c)}):(0,z.jsx)(Ib,{children:re}):null,k?te.map(n=>D?.sortableFields?.includes(n)?(0,z.jsx)(oO,{label:yv(n,D?.schema?.properties?.[n],t,g),field:n,activeField:l,direction:u,href:aO(e,a,o,n,l,u,s,c)},n):(0,z.jsx)(Ib,{children:yv(n,D?.schema?.properties?.[n],t,g)},n)):(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(oO,{className:`hidden md:table-cell`,label:Q(t,`collection.table.status`),field:`status`,activeField:l,direction:u,href:aO(e,a,o,`status`,l,u,s,c)}),D&&(D.localized||D.hasTranslations)?(0,z.jsx)(Ib,{children:(0,z.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,z.jsx)(Gt,{className:`size-3.5`,"aria-hidden":!0}),Q(t,`collection.table.locale`)]})}):null,(0,z.jsx)(Ib,{className:`hidden md:table-cell`,children:Q(t,`collection.table.version`)})]}),(0,z.jsx)(oO,{className:`hidden md:table-cell`,label:Q(t,`collection.table.updated`),field:`updatedAt`,activeField:l,direction:u,href:aO(e,a,o,`updatedAt`,l,u,s,c)}),(0,z.jsx)(Ib,{children:Q(t,`collection.table.actions`)})]})}),(0,z.jsx)(Pb,{children:C.items.map(e=>(0,z.jsx)(uO,{row:e,language:t,canonical:g,collection:D,siteLocales:m.data?.locales??[],dataColumns:k?te:null,primaryField:k?ne:null,boundOperations:v,onOperationSuccess:ie,selected:T.has(e.id),onToggleSelect:t=>{E(n=>{let r=new Set(n);return t?r.add(e.id):r.delete(e.id),r})},onRename:t=>ae.mutateAsync({id:e.id,title:t,version:e.version}),onDelete:()=>I.mutateAsync(e.id),busy:ae.isPending&&ae.variables?.id===e.id||I.isPending&&I.variables===e.id,canEdit:!A&&(j||h.data?.role===`contributor`&&!k&&e.status===`draft`),canDelete:j&&!A},e.id))})]}),b.isFetching&&!b.data?(0,z.jsx)(`p`,{className:`mt-3 text-xs text-muted-foreground`,children:Q(t,`collection.refreshing`)}):null,(0,z.jsx)(sO,{collectionName:e,status:a,searchTerm:o,filterField:s,filterValue:c,sortField:l,sortDirection:u,previousCursor:C.previous_cursor,nextCursor:C.next_cursor,language:t})]})]})}function tO({language:e,collection:t,selectedIds:n,onDone:r,onClear:i}){let[a,o]=R.useState(!1),[s,c]=R.useState([]),l=t&&t.lifecycle!==`operational`,u=Xb();async function d(e){o(!0),c([]);let t=[];for(let r of n)try{await e(r)}catch(e){t.push(e)}o(!1),c(t),r()}async function f(){await u({description:Q(e,`collection.bulk.deleteConfirm`,{count:String(n.length)})})&&d(e=>Z.delete(`/entries/${encodeURIComponent(e)}`))}return(0,z.jsxs)(`div`,{className:`mb-3 flex flex-wrap items-center gap-2 rounded-lg border bg-muted/40 px-3 py-2`,children:[(0,z.jsx)(`span`,{className:`text-sm font-medium`,children:Q(e,`collection.bulk.selectedCount`,{count:String(n.length)})}),(0,z.jsxs)(`div`,{className:`ml-auto flex items-center gap-2`,children:[l?(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(X,{type:`button`,variant:`secondary`,size:`sm`,disabled:a,onClick:()=>void d(e=>Z.post(`/entries/${encodeURIComponent(e)}/publish`,{})),children:Q(e,`collection.bulk.publish`)}),(0,z.jsx)(X,{type:`button`,variant:`secondary`,size:`sm`,disabled:a,onClick:()=>void d(e=>Z.post(`/entries/${encodeURIComponent(e)}/unpublish`,{})),children:Q(e,`collection.bulk.unpublish`)})]}):null,(0,z.jsx)(X,{type:`button`,variant:`destructive`,size:`sm`,disabled:a,onClick:()=>void f(),children:Q(e,`collection.bulk.delete`)}),(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`sm`,onClick:i,children:(0,z.jsx)(Vn,{className:`size-3.5`,"aria-hidden":!0})})]}),s.length>0?(0,z.jsx)(`div`,{className:`w-full space-y-1`,children:s.map((e,t)=>(0,z.jsx)(Ky,{error:e},t))}):null]})}function nO(e,t,n){let r=e?_v(e.title,t,n)??e.name:``,i=_v(e?.description,t,n)?.trim(),a=rO(e);return i?(0,z.jsx)(Yy,{description:i,summaryLabel:Q(t,`collection.schemaDetails`),collapsedIntro:Q(t,a,{name:r})}):Q(t,a,{name:r})}function rO(e){let t=!e||e.lifecycle!==`operational`,n=e?e.localized||e.hasTranslations:!1;return t&&n?`collection.schemaSummary.lifecycleAndI18n`:t?`collection.schemaSummary.lifecycleOnly`:n?`collection.schemaSummary.i18nOnly`:`collection.schemaSummary.plain`}function iO(e,t){let n=new URLSearchParams;t.status&&n.set(`status`,t.status),t.searchTerm&&n.set(`search`,t.searchTerm),t.filterField&&t.filterValue&&(n.set(`filter_field`,t.filterField),n.set(`filter_value`,t.filterValue)),t.sortField&&t.sortField!==`updatedAt`&&n.set(`sort`,t.sortField),t.sortDirection&&t.sortDirection!==`desc`&&n.set(`direction`,t.sortDirection),t.cursor&&n.set(`cursor`,t.cursor),t.cursorDirection===`backward`&&n.set(`cursor_direction`,`backward`);let r=n.toString();return`/admin/c/${encodeURIComponent(e)}${r?`?${r}`:``}`}function aO(e,t,n,r,i,a,o,s){return iO(e,{status:t,searchTerm:n,filterField:o,filterValue:s,sortField:r,sortDirection:i===r?a===`asc`?`desc`:`asc`:r===`updatedAt`?`desc`:`asc`})}function oO({className:e,label:t,field:n,activeField:r,direction:i,href:a}){return(0,z.jsx)(Ib,{className:e,children:(0,z.jsxs)(`a`,{href:a,className:`inline-flex items-center gap-1.5 font-medium hover:text-foreground`,children:[t,(0,z.jsx)(r===n?i===`asc`?xt:vt:bt,{className:Y(`size-3.5`,r===n?`opacity-100`:`opacity-35`),"aria-hidden":!0})]})})}function sO({collectionName:e,status:t,searchTerm:n,filterField:r,filterValue:i,sortField:a,sortDirection:o,previousCursor:s,nextCursor:c,language:l}){if(!s&&!c)return null;let u={status:t,searchTerm:n,filterField:r,filterValue:i,sortField:a,sortDirection:o};return(0,z.jsx)(Eb,{className:`mt-4 justify-end`,"aria-label":Q(l,`collection.pagination`),children:(0,z.jsxs)(Db,{children:[(0,z.jsx)(Ob,{children:(0,z.jsx)(Ab,{href:s?iO(e,{...u,cursor:s,cursorDirection:`backward`}):void 0,text:Q(l,`collection.previousPage`),"aria-label":Q(l,`collection.previousPage`),"aria-disabled":!s||void 0,tabIndex:s?void 0:-1,className:Y(!s&&`pointer-events-none opacity-50`)})}),(0,z.jsx)(Ob,{children:(0,z.jsx)(jb,{href:c?iO(e,{...u,cursor:c,cursorDirection:`forward`}):void 0,text:Q(l,`collection.nextPage`),"aria-label":Q(l,`collection.nextPage`),"aria-disabled":!c||void 0,tabIndex:c?void 0:-1,className:Y(!c&&`pointer-events-none opacity-50`)})})]})})}function cO(){return(0,z.jsx)(`div`,{className:`overflow-hidden rounded-lg border`,children:[0,1,2,3,4].map(e=>(0,z.jsxs)(`div`,{className:`flex items-center gap-4 border-b p-3 last:border-b-0`,children:[(0,z.jsx)(L_,{className:`h-3 w-16`}),(0,z.jsx)(L_,{className:`h-3 flex-1`}),(0,z.jsx)(L_,{className:`h-6 w-20 rounded-full`})]},e))})}function lO({id:e,language:t}){let[n,r]=R.useState(!1);async function i(){try{await navigator.clipboard.writeText(e),r(!0),window.setTimeout(()=>r(!1),1400)}catch{r(!1)}}return(0,z.jsxs)(`button`,{type:`button`,className:`group inline-flex items-center gap-1 hover:text-foreground`,title:`${e} — ${Q(t,`collection.copyId`)}`,onClick:()=>void i(),children:[sx(e),n?(0,z.jsx)(Dt,{className:`size-3 text-[color:var(--success)]`,"aria-hidden":!0}):(0,z.jsx)(Lt,{className:`size-3 opacity-40 transition-opacity group-hover:opacity-80`,"aria-hidden":!0})]})}function uO({row:e,language:t,canonical:n,collection:r,siteLocales:i,dataColumns:a,primaryField:o,boundOperations:s,onOperationSuccess:c,selected:l,onToggleSelect:u,onRename:d,onDelete:f,busy:p,canEdit:m,canDelete:h}){let g=a!==null,_=YD(g?o?e.data_preview?.[o]:e.id:e.title,t),[v,y]=R.useState(!1),[b,x]=R.useState(_),[S,C]=R.useState(null),w=Xb();R.useEffect(()=>{v||x(_)},[v,_]);async function T(){let e=b.trim();if(!e||e===_){y(!1),x(_);return}C(null);try{await d(e),y(!1)}catch(e){C(e instanceof Error?e.message:String(e))}}async function E(){if(await w({description:Q(t,`crud.deleteConfirm`,{name:_})})){C(null);try{await f()}catch(e){C(e instanceof Error?e.message:String(e))}}}return(0,z.jsxs)(Fb,{children:[h?(0,z.jsx)(Lb,{children:(0,z.jsx)(Tb,{"aria-label":Q(t,`collection.table.selectRow`,{name:_}),checked:l,onCheckedChange:e=>u(e===!0)})}):null,(0,z.jsx)(Lb,{className:`hidden font-mono text-xs text-muted-foreground md:table-cell`,children:(0,z.jsx)(lO,{id:String(e.id),language:t})}),!g||o?(0,z.jsx)(Lb,{className:`max-w-[28rem]`,children:(0,z.jsxs)(`div`,{className:`min-w-44 md:min-w-64`,children:[g?(0,z.jsx)(`a`,{href:`/admin/c/${encodeURIComponent(e.collection)}/${encodeURIComponent(e.id)}`,className:`block truncate font-medium hover:underline`,title:_,children:JD(r?.schema?.properties?.[o??``],e.data_preview?.[o??``])}):v?(0,z.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,z.jsx)(O_,{className:`h-8 min-w-0 flex-1`,value:b,autoFocus:!0,disabled:p,onChange:e=>x(e.target.value),onBlur:()=>void T(),onKeyDown:e=>{e.key===`Enter`&&T(),e.key===`Escape`&&(x(_),y(!1))}}),(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:Q(t,`crud.saveTitle`),disabled:p,onMouseDown:e=>e.preventDefault(),onClick:()=>void T(),children:(0,z.jsx)(Dt,{className:`size-3.5`,"aria-hidden":!0})}),(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:Q(t,`crud.cancelTitle`),disabled:p,onMouseDown:e=>e.preventDefault(),onClick:()=>{x(_),y(!1)},children:(0,z.jsx)(Vn,{className:`size-3.5`,"aria-hidden":!0})})]}):m?(0,z.jsxs)(`button`,{type:`button`,className:`group inline-flex max-w-full items-center gap-2 text-left`,onClick:()=>y(!0),title:_,children:[(0,z.jsx)(`span`,{className:`truncate`,children:dO(e.title,t)}),(0,z.jsx)(hn,{className:`size-3 shrink-0 opacity-0 transition-opacity group-hover:opacity-60`,"aria-hidden":!0})]}):(0,z.jsx)(`a`,{href:`/admin/c/${encodeURIComponent(e.collection)}/${encodeURIComponent(e.id)}`,className:`block truncate font-medium hover:underline`,title:_,children:dO(e.title,t)}),S?(0,z.jsx)(`p`,{className:`mt-1 text-xs text-destructive`,children:S}):null]})}):null,a?a.map(t=>(0,z.jsx)(Lb,{className:`text-muted-foreground`,children:JD(r?.schema?.properties?.[t],e.data_preview?.[t])},t)):(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(Lb,{className:`hidden md:table-cell`,children:(0,z.jsx)($b,{status:e.status})}),r&&(r.localized||r.hasTranslations)?(0,z.jsx)(Lb,{children:r.hasTranslations?(0,z.jsx)(nD,{locales:i,available:e.translation_locales,language:t}):(0,z.jsx)(eD,{locale:e.locale})}):null,(0,z.jsxs)(Lb,{className:`hidden font-mono text-xs text-muted-foreground md:table-cell`,children:[`v`,e.version]})]}),(0,z.jsx)(Lb,{className:`hidden text-muted-foreground md:table-cell`,children:ax(e.updated_at)??`-`}),(0,z.jsxs)(Lb,{children:[(0,z.jsxs)(`div`,{className:`flex items-center gap-1`,children:[m?(0,z.jsx)(X,{asChild:!0,variant:`ghost`,size:`icon-sm`,children:(0,z.jsx)(`a`,{title:Q(t,`crud.editTooltip`,{name:_}),"aria-label":Q(t,`crud.editTooltip`,{name:_}),href:`/admin/c/${encodeURIComponent(e.collection)}/${encodeURIComponent(e.id)}`,children:(0,z.jsx)(hn,{className:`size-3.5`,"aria-hidden":!0})})}):(0,z.jsx)(X,{asChild:!0,variant:`ghost`,size:`icon-sm`,children:(0,z.jsx)(`a`,{title:Q(t,`crud.viewTooltip`,{name:_}),"aria-label":Q(t,`crud.viewTooltip`,{name:_}),href:`/admin/c/${encodeURIComponent(e.collection)}/${encodeURIComponent(e.id)}`,children:(0,z.jsx)(Ht,{className:`size-3.5`,"aria-hidden":!0})})}),h?(0,z.jsx)(X,{type:`button`,variant:`ghost`,size:`icon-sm`,title:Q(t,`crud.deleteTooltip`,{name:_}),disabled:p,onClick:()=>void E(),children:(0,z.jsx)(jn,{className:`size-3.5`,"aria-hidden":!0})}):null,(0,z.jsx)(WD,{row:e,operations:s,language:t,canonical:n,onSuccess:c})]}),(0,z.jsx)(`span`,{className:`sr-only`,children:r?_v(r.title,t,n)??r.name:``})]})]})}function dO(e,t){return e==null||e===``?(0,z.jsx)(`span`,{className:`text-muted-foreground`,children:Q(t,`collection.untitled`)}):typeof e==`string`?e:(0,z.jsx)(`span`,{className:`font-mono text-xs`,children:JSON.stringify(e)})}var fO=50;async function pO(e,t){let n=new URLSearchParams;for(let[e,r]of Object.entries(t))r!=null&&r!==``&&n.set(e,String(r));let r=n.toString(),i=await fetch(`/admin/api/views/${encodeURIComponent(e)}${r?`?${r}`:``}`,{credentials:`same-origin`,headers:{Accept:`application/json`}}),a=await i.json();if(!i.ok||!a.ok){let e=`diagnostic`in a?a.diagnostic.message:`${i.status} ${i.statusText}`;throw Error(e)}return a}function mO({name:e}){let{language:t}=Iv(),n=Av(),r=R.useMemo(()=>new URLSearchParams(n.search),[n.search]),i=CO(r.get(`page`))??1,a=st(Sv()),o=st({queryKey:[`collections`],queryFn:async()=>(await Z.get(`/collections`)).collections}),s=st({queryKey:[`site`],queryFn:()=>Z.get(`/site`)}).data?.canonicalLocale??null,c=a.data?.find(t=>t.name===e),l=o.data?.find(e=>e.name===c?.from)?.schema,[u,d]=R.useState({});R.useEffect(()=>{d(gO(c?.params,r))},[c?.name,c?.params,n.search]);let f=_O(c?.params,r),p=st({queryKey:[`view`,e,n.search],queryFn:()=>pO(e,{...Object.fromEntries(r),page:i,show:fO}),enabled:!!c&&f});if(a.isLoading||o.isLoading)return(0,z.jsx)(L_,{className:`h-64 w-full`});if(a.isError)return(0,z.jsx)(Ky,{error:a.error});if(!c)return(0,z.jsx)(`div`,{className:`space-y-6`,children:(0,z.jsx)(Hy,{title:Q(t,`views.notFound.title`)})});let m=p.data?.data.rows??[],h=wO(c,m),g=_v(c.title,t,s)??vv(c.name),_=bO(e,r);return(0,z.jsxs)(`div`,{className:`space-y-6`,children:[(0,z.jsx)(Hy,{title:g,description:Q(t,`views.page.body`,{schema:c.from??c.name}),actions:(0,z.jsxs)(X,{type:`button`,variant:`secondary`,disabled:!f,onClick:()=>{window.location.href=_},children:[(0,z.jsx)(zt,{className:`size-4`,"aria-hidden":!0}),Q(t,`collection.export`)]})}),c.params?(0,z.jsxs)(Uy,{className:`space-y-4`,children:[(0,z.jsx)(`h2`,{className:`text-sm font-semibold`,children:Q(t,`views.params.title`)}),(0,z.jsx)(dD,{schema:c.params,value:u,path:[],onChange:d,language:t,canonical:s,collectionName:c.name,mediaPurposes:[]}),(0,z.jsxs)(X,{type:`button`,onClick:()=>{window.location.href=vO(e,r,c.params,u)},disabled:p.isFetching,children:[(0,z.jsx)(xn,{className:`size-4`,"aria-hidden":!0}),p.isFetching?Q(t,`views.running`):Q(t,`views.run`)]})]}):null,c.list.searchFields.length>0||c.list.filterFields.length>0?(0,z.jsx)(XD,{language:t,searchable:c.list.searchFields.length>0,searchValue:r.get(`search`)??``,filters:c.list.filterFields.map(e=>({name:e,label:vv(e),value:r.get(`filter.${e}`)??``})),onSubmit:({search:t,filters:n})=>{let i=new URLSearchParams(r);SO(i,`search`,t);for(let e of c.list.filterFields)SO(i,`filter.${e}`,n[e]??``);i.delete(`page`),i.delete(`show`),window.location.href=xO(e,i)}},n.search):null,p.isError?(0,z.jsx)(Ky,{error:p.error}):null,p.isLoading?(0,z.jsx)(L_,{className:`h-48 w-full`}):null,p.data&&m.length===0?(0,z.jsx)(Gy,{title:Q(t,`views.empty.title`),description:Q(t,`views.empty.body`)}):null,m.length>0?(0,z.jsxs)(Mb,{children:[(0,z.jsx)(Nb,{children:(0,z.jsx)(Fb,{children:h.map(e=>(0,z.jsx)(Ib,{children:yv(e,l?.properties?.[e],t,s)},e))})}),(0,z.jsx)(Pb,{children:m.map((e,t)=>(0,z.jsx)(Fb,{children:h.map(t=>(0,z.jsx)(Lb,{className:`text-muted-foreground`,children:JD(l?.properties?.[t],e[t])},t))},t))})]}):null,p.data?(0,z.jsx)(hO,{name:e,query:r,page:p.data.data.page,hasMore:p.data.data.hasMore,language:t}):null]})}function hO({name:e,query:t,page:n,hasMore:r,language:i}){if(n<=1&&!r)return null;let a=n>1?yO(e,t,n-1):void 0,o=r?yO(e,t,n+1):void 0;return(0,z.jsx)(Eb,{className:`mt-4 justify-end`,"aria-label":Q(i,`collection.pagination`),children:(0,z.jsxs)(Db,{children:[(0,z.jsx)(Ob,{children:(0,z.jsx)(Ab,{href:a,text:Q(i,`collection.previousPage`),"aria-label":Q(i,`collection.previousPage`),"aria-disabled":!a||void 0,tabIndex:a?void 0:-1,className:Y(!a&&`pointer-events-none opacity-50`)})}),(0,z.jsx)(Ob,{children:(0,z.jsx)(jb,{href:o,text:Q(i,`collection.nextPage`),"aria-label":Q(i,`collection.nextPage`),"aria-disabled":!o||void 0,tabIndex:o?void 0:-1,className:Y(!o&&`pointer-events-none opacity-50`)})})]})})}function gO(e,t){let n={};for(let[r,i]of Object.entries(e?.properties??{})){let e=t.get(r);e!==null&&(n[r]=i.type===`integer`||i.type===`number`?Number(e):i.type===`boolean`?e===`true`:e)}return n}function _O(e,t){return(e?.required??[]).every(e=>t.has(e))}function vO(e,t,n,r){let i=new URLSearchParams(t);for(let e of Object.keys(n.properties??{})){i.delete(e);let t=r[e];t!=null&&t!==``&&i.set(e,String(t))}return i.delete(`page`),i.delete(`show`),xO(e,i)}function yO(e,t,n){let r=new URLSearchParams(t);return n>1?r.set(`page`,String(n)):r.delete(`page`),r.delete(`show`),xO(e,r)}function bO(e,t){let n=new URLSearchParams(t);n.delete(`page`),n.delete(`show`);let r=n.toString();return`/admin/api/views/${encodeURIComponent(e)}/export${r?`?${r}`:``}`}function xO(e,t){let n=t.toString();return`/admin/views/${encodeURIComponent(e)}${n?`?${n}`:``}`}function SO(e,t,n){n?e.set(t,n):e.delete(t)}function CO(e){if(!e)return;let t=Number.parseInt(e,10);return Number.isFinite(t)&&t>0?t:void 0}function wO(e,t){if(e.list.columns.length>0)return[...e.list.columns];if(e.fields&&e.fields.length>0)return[...e.fields];let n=new Set;for(let e of t)for(let t of Object.keys(e))n.add(t);return[...n]}function TO({path:e}){let{language:t}=Iv();return(0,z.jsxs)(Iy,{className:`mx-auto max-w-md p-8 text-center`,children:[(0,z.jsx)(`h1`,{className:`mb-2 text-xl`,children:Q(t,`system.notFound.title`)}),(0,z.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[Q(t,`system.notFound.body`),` `,(0,z.jsx)(`code`,{className:`font-mono text-xs`,children:e}),`.`]}),(0,z.jsx)(`p`,{className:`mt-4 text-sm`,children:(0,z.jsx)(`a`,{href:`/admin`,className:`text-primary hover:underline`,children:Q(t,`system.notFound.back`)})})]})}function EO(){let{language:e,direction:t,theme:n,setLanguage:r,setTheme:i}=Iv();return(0,z.jsxs)(`div`,{className:`mx-auto max-w-4xl`,children:[(0,z.jsx)(Hy,{eyebrow:Q(e,`preferences.heading`),title:Q(e,`preferences.page.title`),description:Q(e,`preferences.page.body`)}),(0,z.jsxs)(`div`,{className:`grid gap-4`,children:[(0,z.jsxs)(Uy,{children:[(0,z.jsx)(OO,{icon:$t,title:Q(e,`preferences.language`),body:Q(e,`preferences.page.languageBody`)}),(0,z.jsx)(DO,{language:e,onChange:r})]}),(0,z.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:[(0,z.jsxs)(Uy,{children:[(0,z.jsx)(OO,{icon:un,title:Q(e,`preferences.appearance`),body:Q(e,`preferences.page.appearanceBody`)}),(0,z.jsx)(`div`,{className:`mt-4 grid gap-2`,children:AO(e).map(e=>(0,z.jsx)(kO,{selected:e.value===n,onClick:()=>i(e.value),icon:e.icon,children:e.label},e.value))})]}),(0,z.jsxs)(Uy,{children:[(0,z.jsx)(OO,{icon:gn,title:Q(e,`preferences.direction`),body:Q(e,`preferences.direction.auto`)}),(0,z.jsx)(`div`,{className:`mt-4 rounded-lg border border-border/70 bg-background/30 px-3 py-2 text-sm`,children:(0,z.jsx)(`span`,{className:`text-muted-foreground`,children:t===`rtl`?Q(e,`preferences.rtl`):Q(e,`preferences.ltr`)})})]})]})]})]})}function DO({language:e,onChange:t}){let[n,r]=R.useState(!1),[i,a]=R.useState(``),o=jv.find(t=>t.value===e)??jv[0],s=i.trim().toLowerCase(),c=s?jv.filter(e=>[e.nativeLabel,e.label,e.value,e.htmlLang,e.direction].join(` `).toLowerCase().includes(s)):jv;return(0,z.jsxs)(`div`,{className:`relative mt-4`,children:[(0,z.jsxs)(`button`,{type:`button`,onClick:()=>r(e=>!e),className:`flex w-full items-center justify-between gap-3 rounded-lg border border-border/70 bg-background/30 px-3 py-2 text-start text-sm transition-colors hover:bg-accent hover:text-accent-foreground`,"aria-expanded":n,children:[(0,z.jsxs)(`span`,{className:`min-w-0`,children:[(0,z.jsx)(`span`,{className:`block truncate font-medium text-foreground`,children:o.nativeLabel}),(0,z.jsxs)(`span`,{className:`block truncate text-xs text-muted-foreground`,children:[o.label,` · `,o.value,` · `,Uv(o.value).toUpperCase()]})]}),(0,z.jsx)(Mt,{className:`size-4 shrink-0 text-muted-foreground`,"aria-hidden":!0})]}),n?(0,z.jsxs)(`div`,{className:`absolute z-30 mt-2 w-full overflow-hidden rounded-lg border bg-popover text-popover-foreground shadow-md`,children:[(0,z.jsxs)(`div`,{className:`flex items-center gap-2 border-b px-3 py-2`,children:[(0,z.jsx)(xn,{className:`size-4 shrink-0 text-muted-foreground`,"aria-hidden":!0}),(0,z.jsx)(`input`,{autoFocus:!0,value:i,onChange:e=>a(e.target.value),onKeyDown:e=>{e.key===`Escape`&&r(!1)},placeholder:Q(e,`preferences.language.search`),className:`min-w-0 flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground/70`})]}),(0,z.jsx)(`div`,{className:`max-h-72 overflow-y-auto p-1`,children:c.length===0?(0,z.jsx)(`div`,{className:`px-3 py-6 text-center text-sm text-muted-foreground`,children:Q(e,`preferences.language.noResults`)}):c.map(n=>(0,z.jsxs)(`button`,{type:`button`,onClick:()=>{t(n.value),a(``),r(!1)},className:Y(`flex w-full items-center justify-between gap-3 rounded-lg px-3 py-2 text-start text-sm transition-colors`,n.value===e?`bg-primary/10 text-foreground`:`text-muted-foreground hover:bg-accent hover:text-accent-foreground`),children:[(0,z.jsxs)(`span`,{className:`min-w-0`,children:[(0,z.jsx)(`span`,{className:`block truncate font-medium`,children:n.nativeLabel}),(0,z.jsxs)(`span`,{className:`block truncate text-xs opacity-75`,children:[n.label,` · `,n.value,` · `,n.direction.toUpperCase()]})]}),(0,z.jsx)(Dt,{className:Y(`size-4 shrink-0 text-primary`,n.value===e?`opacity-100`:`opacity-0`),"aria-hidden":!0})]},n.value))})]}):null]})}function OO({icon:e,title:t,body:n}){return(0,z.jsxs)(`div`,{className:`flex items-start gap-3`,children:[(0,z.jsx)(`div`,{className:`rounded-xl bg-primary/15 p-2 text-primary`,children:(0,z.jsx)(e,{className:`size-5`,"aria-hidden":!0})}),(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h2`,{className:`text-lg`,children:t}),(0,z.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:n})]})]})}function kO({selected:e,onClick:t,icon:n,children:r}){return(0,z.jsxs)(`button`,{type:`button`,onClick:t,className:Y(`flex min-h-10 items-center justify-between gap-3 rounded-lg border px-3 py-2 text-start text-sm transition-colors`,e?`border-primary/50 bg-primary/10 text-foreground`:`border-border/70 bg-background/30 text-muted-foreground hover:bg-accent hover:text-accent-foreground`),children:[(0,z.jsxs)(`span`,{className:`flex min-w-0 items-center gap-2`,children:[n?(0,z.jsx)(n,{className:`size-4 shrink-0`,"aria-hidden":!0}):null,(0,z.jsx)(`span`,{className:`truncate`,children:r})]}),(0,z.jsx)(Dt,{className:Y(`size-4 shrink-0 text-primary`,e?`opacity-100`:`opacity-0`),"aria-hidden":!0})]})}function AO(e){return[{value:`light`,label:Q(e,`preferences.light`),icon:En},{value:`dark`,label:Q(e,`preferences.dark`),icon:dn},{value:`system`,label:Q(e,`preferences.system`),icon:un}]}function jO(){let{language:e}=Iv(),t=Ke(),n=st({queryKey:[`site-settings`],queryFn:()=>Z.get(`/site-settings`)}),[r,i]=R.useState(null),[a,o]=R.useState(`brand`);R.useEffect(()=>{n.data&&i(n.data)},[n.data]);let s=ct({mutationFn:e=>Z.patch(`/site-settings`,e),onSuccess:e=>{t.setQueryData([`site-settings`],e),i(e)}});if(n.isLoading||!r)return(0,z.jsx)(L_,{className:`h-64 w-full`});if(n.isError)return(0,z.jsx)(Ky,{error:n.error});let c=!FO(r,n.data),l=s.isSuccess&&!c;function u(e,t){s.reset(),i(n=>n&&{...n,[e]:t})}return(0,z.jsxs)(`div`,{className:`flex min-h-full flex-col gap-6`,children:[(0,z.jsx)(Hy,{title:Q(e,`settings.page.title`),description:Q(e,`settings.page.body`)}),s.isError?(0,z.jsx)(qy,{error:cx(s.error)}):null,(0,z.jsxs)(`div`,{role:`tablist`,"aria-label":Q(e,`settings.tabsLabel`),className:`inline-flex gap-1 rounded-lg border bg-muted/40 p-1`,children:[(0,z.jsx)(MO,{active:a===`brand`,icon:Cn,label:Q(e,`settings.tab.brand`),onClick:()=>o(`brand`)}),(0,z.jsx)(MO,{active:a===`tracking`,icon:Et,label:Q(e,`settings.tab.tracking`),onClick:()=>o(`tracking`)})]}),a===`brand`?(0,z.jsxs)(Uy,{className:`grid max-w-5xl gap-4`,children:[(0,z.jsx)(NO,{title:Q(e,`settings.brandSection`),body:Q(e,`settings.brandSectionBody`)}),(0,z.jsx)(PO,{label:Q(e,`settings.siteBrand`),description:Q(e,`settings.siteBrandHelp`),children:(0,z.jsx)(O_,{value:r.brand,onChange:e=>u(`brand`,e.target.value)})}),(0,z.jsx)(PO,{label:Q(e,`settings.siteTitle`),description:Q(e,`settings.siteTitleHelp`),children:(0,z.jsx)(O_,{value:r.title,onChange:e=>u(`title`,e.target.value)})}),(0,z.jsx)(PO,{label:Q(e,`settings.siteDescription`),description:Q(e,`settings.siteDescriptionHelp`),children:(0,z.jsx)(mE,{className:`min-h-24`,value:r.description,onChange:e=>u(`description`,e.target.value)})})]}):null,a===`tracking`?(0,z.jsxs)(Uy,{className:`grid max-w-5xl gap-4`,children:[(0,z.jsx)(NO,{title:Q(e,`settings.trackingSection`),body:Q(e,`settings.trackingSectionBody`)}),(0,z.jsxs)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:[(0,z.jsx)(PO,{label:Q(e,`settings.ga4MeasurementId`),description:Q(e,`settings.ga4MeasurementIdHelp`),children:(0,z.jsx)(O_,{value:r.ga4MeasurementId,placeholder:Q(e,`settings.notConfigured`),onChange:e=>u(`ga4MeasurementId`,e.target.value)})}),(0,z.jsx)(PO,{label:Q(e,`settings.facebookPixelId`),description:Q(e,`settings.facebookPixelIdHelp`),children:(0,z.jsx)(O_,{value:r.facebookPixelId,placeholder:Q(e,`settings.notConfigured`),onChange:e=>u(`facebookPixelId`,e.target.value)})})]})]}):null,(0,z.jsx)(Wy,{status:s.isPending?Q(e,`crud.saving`):c?Q(e,`common.unsavedChanges`):l?Q(e,`common.saved`):void 0,children:(0,z.jsxs)(X,{onClick:()=>s.mutate(r),disabled:!c||s.isPending,children:[(0,z.jsx)(bn,{className:`size-4`,"aria-hidden":!0}),s.isPending?Q(e,`crud.saving`):Q(e,`entryEdit.save`)]})})]})}function MO({active:e,icon:t,label:n,onClick:r}){return(0,z.jsxs)(`button`,{type:`button`,role:`tab`,"aria-selected":e,className:Y(`inline-flex h-9 items-center gap-2 rounded-md px-3 text-sm font-semibold transition`,e?`bg-primary text-primary-foreground shadow-sm`:`text-muted-foreground hover:bg-accent hover:text-accent-foreground`),onClick:r,children:[(0,z.jsx)(t,{className:`size-4`,"aria-hidden":!0}),n]})}function NO({title:e,body:t}){return(0,z.jsxs)(`div`,{children:[(0,z.jsx)(`h2`,{className:`text-lg font-semibold`,children:e}),(0,z.jsx)(`p`,{className:`mt-1 text-sm text-muted-foreground`,children:t})]})}function PO({label:e,description:t,children:n}){return(0,z.jsxs)(`label`,{className:`grid gap-1.5 text-sm font-medium`,children:[(0,z.jsx)(`span`,{children:e}),t?(0,z.jsx)(`span`,{className:`text-xs font-normal text-muted-foreground`,children:t}):null,n]})}function FO(e,t){return!!t&&Object.keys(e).every(n=>e[n]===t[n])}var IO=`https://developers.cloudflare.com/email-service/`,LO=`Enable email sign-in for this Mantle site. Implement the Mantle EmailSender port with a transactional email provider. For Cloudflare, prefer an Email Service binding. Register either { kind: "email-otp", sender } or { kind: "magic-link", sender } in createAuth(), keep credentials in Worker secrets, deploy, then verify that /api/auth/methods lists the method and a real email arrives.`,RO=[`owner`,`editor`,`contributor`,`none`],zO=[`owner`,`editor`,`contributor`];function BO(){let{language:e}=Iv(),t=Ke(),n=st({queryKey:[`me`],queryFn:()=>Z.get(`/me`),retry:!1}),r=st({queryKey:[`staff`],queryFn:()=>Z.get(`/staff`),retry:!1}),i=st(xv()),a=i.data?.some(({kind:e})=>e===`email-otp`||e===`magic-link`),o=()=>{t.invalidateQueries({queryKey:[`staff`]})},s=ct({mutationFn:e=>Z.patch(`/staff/${encodeURIComponent(e.userId)}/role`,{role:e.role}),onSettled:o}),c=ct({mutationFn:e=>Z.delete(`/staff/invitations/${encodeURIComponent(e)}`),onSettled:o});if(r.isError)return(0,z.jsx)(Ky,{error:r.error});if(r.isLoading||!r.data)return(0,z.jsx)(L_,{className:`h-64 w-full`});let l=t=>Q(e,`staff.role.${t}`);return(0,z.jsxs)(`div`,{className:`space-y-6`,children:[(0,z.jsx)(Hy,{title:Q(e,`staff.page.title`),description:Q(e,`staff.page.body`)}),s.isError?(0,z.jsx)(Ky,{error:cx(s.error)}):null,c.isError?(0,z.jsx)(Ky,{error:cx(c.error)}):null,i.data&&!a?(0,z.jsx)(HO,{}):null,(0,z.jsx)(VO,{onInvited:o}),(0,z.jsx)(Uy,{className:`overflow-x-auto p-0`,children:(0,z.jsxs)(Mb,{children:[(0,z.jsx)(Nb,{children:(0,z.jsxs)(Fb,{children:[(0,z.jsx)(Ib,{children:Q(e,`staff.table.name`)}),(0,z.jsx)(Ib,{children:Q(e,`staff.table.email`)}),(0,z.jsx)(Ib,{children:Q(e,`staff.table.status`)}),(0,z.jsx)(Ib,{children:Q(e,`staff.table.role`)})]})}),(0,z.jsx)(Pb,{children:r.data.users.map(t=>{let r=t.id===n.data?.userId,i=!t.emailVerified&&!t.githubLogin,a=UO(t.role)?t.role:`none`;return(0,z.jsxs)(Fb,{children:[(0,z.jsx)(Lb,{children:t.name}),(0,z.jsx)(Lb,{children:t.email}),(0,z.jsx)(Lb,{children:i?(0,z.jsxs)(`span`,{className:`inline-flex items-center gap-2`,children:[(0,z.jsx)(bb,{variant:`secondary`,children:Q(e,`staff.badge.invited`)}),(0,z.jsx)(X,{variant:`ghost`,size:`sm`,disabled:c.isPending,onClick:()=>c.mutate(t.id),children:Q(e,`staff.invite.revoke`)})]}):t.githubLogin?`GitHub: ${t.githubLogin}`:Q(e,`staff.status.emailSignIn`)}),(0,z.jsx)(Lb,{children:r?(0,z.jsxs)(`span`,{className:`text-muted-foreground`,children:[l(a),` · `,Q(e,`staff.self`)]}):(0,z.jsxs)(sE,{value:a,disabled:s.isPending,onValueChange:e=>{s.mutate({userId:t.id,role:UO(e)?e:null})},children:[(0,z.jsx)(lE,{className:`w-44`,children:(0,z.jsx)(cE,{})}),(0,z.jsx)(uE,{children:RO.map(e=>(0,z.jsx)(dE,{value:e,children:l(e)},e))})]})})]},t.id)})})]})})]})}function VO({onInvited:e}){let{language:t}=Iv(),[n,r]=R.useState(``),[i,a]=R.useState(`contributor`),o=ct({mutationFn:()=>Z.post(`/staff/invitations`,{email:n,role:i}),onSuccess:()=>{r(``),e()}});return(0,z.jsxs)(Uy,{className:`grid gap-4`,children:[(0,z.jsx)(`h2`,{className:`text-sm font-semibold`,children:Q(t,`staff.invite.title`)}),o.isError?(0,z.jsx)(Ky,{error:cx(o.error)}):null,(0,z.jsxs)(`form`,{className:`grid max-w-4xl gap-4 md:grid-cols-[minmax(0,1fr)_18rem]`,onSubmit:e=>{e.preventDefault(),o.mutate()},children:[(0,z.jsxs)(`label`,{className:`grid min-w-64 flex-1 gap-1.5 text-sm font-medium`,children:[(0,z.jsx)(`span`,{children:Q(t,`staff.invite.emailLabel`)}),(0,z.jsx)(O_,{type:`email`,value:n,placeholder:Q(t,`staff.invite.emailPlaceholder`),onChange:e=>r(e.target.value)}),(0,z.jsx)(`span`,{className:`text-xs font-normal leading-5 text-muted-foreground`,children:Q(t,`staff.invite.hint`)})]}),(0,z.jsxs)(`label`,{className:`grid gap-1.5 text-sm font-medium`,children:[(0,z.jsx)(`span`,{children:Q(t,`staff.invite.roleLabel`)}),(0,z.jsxs)(sE,{value:i,onValueChange:e=>{UO(e)&&a(e)},children:[(0,z.jsx)(lE,{className:`w-full`,children:(0,z.jsx)(cE,{children:Q(t,`staff.role.${i}`)})}),(0,z.jsx)(uE,{className:`min-w-72`,children:zO.map(e=>(0,z.jsx)(dE,{value:e,textValue:Q(t,`staff.role.${e}`),className:`items-start py-2`,children:(0,z.jsxs)(`span`,{className:`grid gap-0.5`,children:[(0,z.jsx)(`span`,{className:`font-medium`,children:Q(t,`staff.role.${e}`)}),(0,z.jsx)(`span`,{className:`text-xs font-normal text-muted-foreground`,children:Q(t,`staff.role.${e}.help`)})]})},e))})]}),(0,z.jsx)(`span`,{className:`max-w-56 text-xs font-normal leading-5 text-muted-foreground`,children:Q(t,`staff.role.${i}.help`)})]}),(0,z.jsx)(`div`,{className:`flex justify-end md:col-span-2`,children:(0,z.jsxs)(X,{type:`submit`,disabled:o.isPending||n.trim()===``,children:[(0,z.jsx)(Ln,{className:`size-4`,"aria-hidden":!0}),o.isPending?Q(t,`staff.invite.sending`):Q(t,`staff.invite.button`)]})})]})]})}function HO(){let{language:e}=Iv(),[t,n]=R.useState(!1);async function r(){try{await navigator.clipboard.writeText(LO),n(!0),window.setTimeout(()=>n(!1),1400)}catch{n(!1)}}return(0,z.jsxs)(Uy,{className:`flex-row flex-wrap items-center gap-4`,children:[(0,z.jsx)(`span`,{className:`flex size-10 shrink-0 items-center justify-center rounded-lg bg-muted`,children:(0,z.jsx)(ln,{className:`size-5`,"aria-hidden":!0})}),(0,z.jsxs)(`div`,{className:`min-w-64 flex-1`,children:[(0,z.jsx)(`h2`,{className:`font-semibold`,children:Q(e,`staff.emailSetup.title`)}),(0,z.jsx)(`p`,{className:`mt-1 text-sm leading-6 text-muted-foreground`,children:Q(e,`staff.emailSetup.body`)})]}),(0,z.jsxs)(`div`,{className:`flex flex-wrap gap-2`,children:[(0,z.jsxs)(X,{type:`button`,variant:`secondary`,onClick:()=>void r(),children:[t?(0,z.jsx)(Dt,{"aria-hidden":!0}):(0,z.jsx)(Lt,{"aria-hidden":!0}),Q(e,t?`staff.emailSetup.copied`:`staff.emailSetup.copy`)]}),(0,z.jsx)(X,{asChild:!0,variant:`outline`,children:(0,z.jsxs)(`a`,{href:IO,target:`_blank`,rel:`noreferrer`,children:[(0,z.jsx)(Vt,{"aria-hidden":!0}),Q(e,`staff.emailSetup.guide`)]})})]})]})}function UO(e){return e===`owner`||e===`editor`||e===`contributor`}var WO=50,GO=[`owner`,`editor`,`contributor`];function KO(){let{language:e}=Iv(),t=Ke(),{search:n}=Av(),r=new URLSearchParams(n),i=r.get(`search`)?.trim()??``,a=r.get(`cursor`)||void 0,o=r.get(`cursor_direction`)===`backward`?`backward`:`forward`,s=st({queryKey:[`members`,i,a??`first`,o],queryFn:()=>{let e=new URLSearchParams({limit:String(WO)});return i&&e.set(`search`,i),a&&e.set(`cursor`,a),o===`backward`&&e.set(`cursor_direction`,`backward`),Z.get(`/members?${e.toString()}`)}}),c=st({queryKey:[`me`],queryFn:()=>Z.get(`/me`),retry:!1}),l=ct({mutationFn:({userId:e,role:t})=>Z.patch(`/staff/${encodeURIComponent(e)}/role`,{role:t}),onSuccess:()=>{t.invalidateQueries({queryKey:[`members`]}),t.invalidateQueries({queryKey:[`staff`]})}}),u=c.data?.role===`owner`;return(0,z.jsxs)(`div`,{children:[(0,z.jsx)(Hy,{title:Q(e,`members.page.title`),description:Q(e,`members.page.body`)}),(0,z.jsx)(qO,{search:i}),l.isError?(0,z.jsx)(Ky,{error:l.error}):null,s.isLoading?(0,z.jsx)(L_,{className:`h-64 w-full`}):null,s.isError?(0,z.jsx)(Ky,{error:s.error}):null,s.data?.items.length===0?(0,z.jsx)(Gy,{icon:It,title:Q(e,i?`members.emptySearch.title`:`members.empty.title`),description:Q(e,i?`members.emptySearch.body`:`members.empty.body`)}):null,s.data&&s.data.items.length>0?(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)(Uy,{className:`overflow-x-auto p-0`,children:(0,z.jsxs)(Mb,{children:[(0,z.jsx)(Nb,{children:(0,z.jsxs)(Fb,{children:[(0,z.jsx)(Ib,{children:Q(e,`members.table.name`)}),(0,z.jsx)(Ib,{children:Q(e,`members.table.email`)}),(0,z.jsx)(Ib,{children:Q(e,`members.table.status`)}),(0,z.jsx)(Ib,{children:Q(e,`members.table.joined`)}),u?(0,z.jsx)(Ib,{children:Q(e,`members.table.teamAccess`)}):null]})}),(0,z.jsx)(Pb,{children:s.data.items.map(t=>(0,z.jsxs)(Fb,{children:[(0,z.jsx)(Lb,{className:`font-medium`,children:t.name}),(0,z.jsx)(Lb,{children:t.email}),(0,z.jsx)(Lb,{children:(0,z.jsx)(bb,{variant:t.emailVerified?`default`:`secondary`,children:Q(e,t.emailVerified?`members.verified`:`members.unverified`)})}),(0,z.jsx)(Lb,{className:`text-muted-foreground`,children:ax(Date.parse(t.createdAt))??`-`}),u?(0,z.jsx)(Lb,{children:(0,z.jsxs)(sE,{disabled:l.isPending,onValueChange:e=>{let n=GO.find(t=>t===e);n&&l.mutate({userId:t.id,role:n})},children:[(0,z.jsx)(lE,{className:`w-44`,"aria-label":`${Q(e,`members.promote`)}: ${t.name}`,children:(0,z.jsx)(cE,{placeholder:Q(e,`members.promote`)})}),(0,z.jsx)(uE,{children:GO.map(t=>(0,z.jsx)(dE,{value:t,children:Q(e,`staff.role.${t}`)},t))})]})}):null]},t.id))})]})}),(0,z.jsx)(JO,{search:i,previousCursor:s.data.previous_cursor,nextCursor:s.data.next_cursor})]}):null]})}function qO({search:e}){let{language:t}=Iv(),{navigate:n}=kv(),[r,i]=R.useState(e);return R.useEffect(()=>i(e),[e]),(0,z.jsxs)(`form`,{className:`mb-4 flex max-w-xl gap-2`,role:`search`,onSubmit:e=>{e.preventDefault(),n(YO(r.trim()))},children:[(0,z.jsxs)(`label`,{className:`relative block flex-1`,"aria-label":Q(t,`members.searchPlaceholder`),children:[(0,z.jsx)(xn,{className:`pointer-events-none absolute left-3 top-1/2 size-4 -translate-y-1/2 text-muted-foreground`,"aria-hidden":!0}),(0,z.jsx)(O_,{className:`h-9 ps-9`,value:r,onChange:e=>i(e.target.value),placeholder:Q(t,`members.searchPlaceholder`)})]}),(0,z.jsxs)(X,{type:`submit`,variant:`secondary`,size:`sm`,className:`h-9`,children:[(0,z.jsx)(xn,{"aria-hidden":!0}),Q(t,`members.search`)]})]})}function JO({search:e,previousCursor:t,nextCursor:n}){let{language:r}=Iv();return!t&&!n?null:(0,z.jsx)(Eb,{className:`mt-4 justify-end`,"aria-label":Q(r,`members.pagination`),children:(0,z.jsxs)(Db,{children:[(0,z.jsx)(Ob,{children:(0,z.jsx)(Ab,{href:t?YO(e,t,`backward`):void 0,text:Q(r,`members.previousPage`),"aria-label":Q(r,`members.previousPage`),"aria-disabled":!t||void 0,tabIndex:t?void 0:-1,className:Y(!t&&`pointer-events-none opacity-50`)})}),(0,z.jsx)(Ob,{children:(0,z.jsx)(jb,{href:n?YO(e,n,`forward`):void 0,text:Q(r,`members.nextPage`),"aria-label":Q(r,`members.nextPage`),"aria-disabled":!n||void 0,tabIndex:n?void 0:-1,className:Y(!n&&`pointer-events-none opacity-50`)})})]})})}function YO(e,t,n=`forward`){let r=new URLSearchParams;e&&r.set(`search`,e),t&&r.set(`cursor`,t),n===`backward`&&r.set(`cursor_direction`,`backward`);let i=r.toString();return`/admin/members${i?`?${i}`:``}`}function XO(){let e=Av();return e.pathname===`/admin/sign-in`?(0,z.jsx)(fb,{}):(0,z.jsx)(ZO,{path:e.pathname})}function ZO({path:e}){let t=st({queryKey:[`me`],queryFn:()=>Z.get(`/me`),retry:!1}),n=t.isError&&t.error instanceof mv&&t.error.status===401;if((0,R.useEffect)(()=>{if(!n||typeof window>`u`)return;let e=window.location.pathname+window.location.search;window.location.href=`/admin/sign-in?return=${encodeURIComponent(e)}`},[n]),n)return(0,z.jsx)(ib,{});if(t.isError&&t.error instanceof mv&&t.error.status===403){let e=t.error.body??{};return(0,z.jsx)(ob,{login:e.login??null})}if(t.isError)return(0,z.jsx)(ab,{error:t.error});if(t.isLoading)return(0,z.jsx)(ib,{});let r=e.match(/^\/admin\/c\/([^/]+)\/?$/);if(r)return(0,z.jsx)(Qy,{children:(0,z.jsx)(eO,{collectionName:decodeURIComponent(r[1])})});let i=e.match(/^\/admin\/c\/([^/]+)\/([^/]+)\/?$/);if(i){let e=decodeURIComponent(i[1]),t=decodeURIComponent(i[2]);return(0,z.jsx)(Qy,{children:(0,z.jsx)(sD,{collectionName:e,entryId:t})})}if(e===`/admin`||e===`/admin/`)return(0,z.jsx)(Qy,{children:(0,z.jsx)(Cb,{})});if(e===`/admin/media`)return(0,z.jsx)(Qy,{children:(0,z.jsx)(KE,{})});if(e===`/admin/preferences`)return(0,z.jsx)(Qy,{children:(0,z.jsx)(EO,{})});if(e===`/admin/settings`)return(0,z.jsx)(Qy,{children:(0,z.jsx)(jO,{})});if(e===`/admin/staff`)return(0,z.jsx)(Qy,{children:(0,z.jsx)(BO,{})});if(e===`/admin/members`)return(0,z.jsx)(Qy,{children:(0,z.jsx)(KO,{})});let a=e.match(/^\/admin\/views\/([^/]+)\/?$/);return a?(0,z.jsx)(Qy,{children:(0,z.jsx)(mO,{name:decodeURIComponent(a[1])})}):(0,z.jsx)(Qy,{children:(0,z.jsx)(TO,{path:e})})}var QO=new He({defaultOptions:{queries:{retry:(e,t)=>t instanceof mv&&[401,403,501].includes(t.status)?!1:e<2,refetchOnWindowFocus:!1,staleTime:1e4}}}),$O=({...e})=>(0,z.jsx)(Bx,{className:`toaster group`,icons:{success:(0,z.jsx)(Pt,{className:`size-4`}),info:(0,z.jsx)(Zt,{className:`size-4`}),warning:(0,z.jsx)(Mn,{className:`size-4`}),error:(0,z.jsx)(fn,{className:`size-4`}),loading:(0,z.jsx)(on,{className:`size-4 animate-spin`})},style:{"--normal-bg":`var(--popover)`,"--normal-text":`var(--popover-foreground)`,"--normal-border":`var(--border)`,"--border-radius":`var(--radius)`},toastOptions:{classNames:{toast:`cn-toast`}},...e}),ek=document.getElementById(`root`);if(!ek)throw Error(`Missing #root element.`);Hn.createRoot(ek).render((0,z.jsx)(R.StrictMode,{children:(0,z.jsx)(qe,{client:QO,children:(0,z.jsx)(Fv,{children:(0,z.jsx)(Ov,{children:(0,z.jsx)(R_,{children:(0,z.jsxs)(Yb,{children:[(0,z.jsx)(XO,{}),(0,z.jsx)(tk,{})]})})})})})}));function tk(){let{theme:e}=Iv();return(0,z.jsx)($O,{theme:e,position:`bottom-right`})}
|