pipe-kan 0.25.4 → 0.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -2
- package/dist/pipe-kan.js +615 -105
- package/dist/ui/assets/index-sJ2vPLG9.css +2 -0
- package/dist/ui/assets/index-xaefvhYI.js +56 -0
- package/dist/ui/index.html +2 -2
- package/fixtures/issues.json +16 -8
- package/package.json +4 -1
- package/dist/ui/assets/index-DE44F4tt.js +0 -56
- package/dist/ui/assets/index-DdZGfEDG.css +0 -2
|
@@ -0,0 +1,56 @@
|
|
|
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,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},c=(n,r,o)=>(o=n==null?{}:e(i(n)),s(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 l=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},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 D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ee(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?ee(``+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&&(O(o)&&(o=D(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 te(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 N(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:te,forEach:function(e,t,n){te(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return te(e,function(){t++}),t},toArray:function(e){return te(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=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=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:N}},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`})),u=o(((e,t)=>{t.exports=l()})),d=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,O());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 D(){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}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var ee=new MessageChannel,k=ee.port2;ee.port1.onmessage=D,O=function(){k.postMessage(null)}}else O=function(){_(D,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,O()))),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}}}})),f=o(((e,t)=>{t.exports=d()})),p=o((e=>{var t=u();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)}},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()},e.version=`19.2.8`})),m=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=p()})),h=o((e=>{var t=f(),n=u(),r=m();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 d(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 p(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=p(e),t!==null)return t;e=e.sibling}return null}var h=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`),D=Symbol.for(`react.memo`),O=Symbol.for(`react.lazy`),ee=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 te(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 ee: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 D:return t=e.displayName||null,t===null?te(e.type)||`Memo`:t;case O:t=e._payload,e=e._init;try{return te(e(t))}catch{}}return null}var N=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 I(e){return{current:e}}function L(e){0>ie||(e.current=re[ie],re[ie]=null,ie--)}function R(e,t){ie++,re[ie]=e.current,e.current=t}var ae=I(null),z=I(null),B=I(null),oe=I(null);function se(e,t){switch(R(B,t),R(z,e),R(ae,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Wd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Wd(t),e=Gd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}L(ae),R(ae,e)}function ce(){L(ae),L(z),L(B)}function le(e){e.memoizedState!==null&&R(oe,e);var t=ae.current,n=Gd(t,e.type);t!==n&&(R(z,e),R(ae,n))}function ue(e){z.current===e&&(L(ae),L(z)),oe.current===e&&(L(oe),tp._currentValue=ne)}var de,fe;function pe(e){if(de===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);de=t&&t[1]||``,fe=-1<e.stack.indexOf(`
|
|
2
|
+
at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
|
|
3
|
+
`+de+e+fe}var me=!1;function he(e,t){if(!e||me)return``;me=!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{me=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?pe(n):``}function ge(e,t){switch(e.tag){case 26:case 27:case 5:return pe(e.type);case 16:return pe(`Lazy`);case 13:return e.child!==t&&t!==null?pe(`Suspense Fallback`):pe(`Suspense`);case 19:return pe(`SuspenseList`);case 0:case 15:return he(e.type,!1);case 11:return he(e.type.render,!1);case 1:return he(e.type,!0);case 31:return pe(`Activity`);default:return``}}function _e(e){try{var t=``,n=null;do t+=ge(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
|
|
7
|
+
Error generating stack: `+e.message+`
|
|
8
|
+
`+e.stack}}var ve=Object.prototype.hasOwnProperty,ye=t.unstable_scheduleCallback,be=t.unstable_cancelCallback,xe=t.unstable_shouldYield,Se=t.unstable_requestPaint,Ce=t.unstable_now,we=t.unstable_getCurrentPriorityLevel,Te=t.unstable_ImmediatePriority,Ee=t.unstable_UserBlockingPriority,De=t.unstable_NormalPriority,Oe=t.unstable_LowPriority,ke=t.unstable_IdlePriority,Ae=t.log,je=t.unstable_setDisableYieldValue,Me=null,Ne=null;function Pe(e){if(typeof Ae==`function`&&je(e),Ne&&typeof Ne.setStrictMode==`function`)try{Ne.setStrictMode(Me,e)}catch{}}var Fe=Math.clz32?Math.clz32:Re,Ie=Math.log,Le=Math.LN2;function Re(e){return e>>>=0,e===0?32:31-(Ie(e)/Le|0)|0}var ze=256,Be=262144,Ve=4194304;function He(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 Ue(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=He(n))):i=He(o):i=He(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=He(n))):i=He(o)):i=He(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 We(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ge(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 Ke(){var e=Ve;return Ve<<=1,!(Ve&62914560)&&(Ve=4194304),e}function qe(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Je(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ye(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-Fe(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&&Xe(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function Xe(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Fe(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function Ze(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Fe(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function Qe(e,t){var n=t&-t;return n=n&42?1:$e(n),(n&(e.suspendedLanes|t))===0?n:0}function $e(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 et(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function tt(){var e=F.p;return e===0?(e=window.event,e===void 0?32:_p(e.type)):e}function nt(e,t){var n=F.p;try{return F.p=e,t()}finally{F.p=n}}var rt=Math.random().toString(36).slice(2),it=`__reactFiber$`+rt,at=`__reactProps$`+rt,ot=`__reactContainer$`+rt,st=`__reactEvents$`+rt,ct=`__reactListeners$`+rt,lt=`__reactHandles$`+rt,ut=`__reactResources$`+rt,dt=`__reactMarker$`+rt;function ft(e){delete e[it],delete e[at],delete e[st],delete e[ct],delete e[lt]}function pt(e){var t=e[it];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ot]||n[it]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=mf(e);e!==null;){if(n=e[it])return n;e=mf(e)}return t}e=n,n=e.parentNode}return null}function mt(e){if(e=e[it]||e[ot]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function ht(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function gt(e){var t=e[ut];return t||=e[ut]={hoistableStyles:new Map,hoistableScripts:new Map},t}function _t(e){e[dt]=!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 ve.call(wt,e)?!0:ve.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(N(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=mt(e);if(t&&(e=t.stateNode)){var n=e[at]||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[at]||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)&&(bu(),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[at]||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 h(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=h({},vn,{view:0,detail:0}),xn=_n(bn),Sn,Cn,wn,Tn=h({},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(h({},Tn,{dataTransfer:0})),On=_n(h({},bn,{relatedTarget:0})),kn=_n(h({},vn,{animationName:0,elapsedTime:0,pseudoElement:0})),An=_n(h({},vn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),jn=_n(h({},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(h({},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(h({},Tn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),zn=_n(h({},bn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:In})),Bn=_n(h({},vn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Vn=_n(h({},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(h({},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 Qn=!1;function $n(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 er(e,t){if(Qn)return e===`compositionend`||!Wn&&Xn(e,t)?(e=pn(),fn=dn=un=null,Qn=!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 tr={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 nr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!tr[e.type]:t===`textarea`}function rr(e,t,n,r){en?tn?tn.push(r):tn=[r]:en=r,t=Od(t,`onChange`),0<t.length&&(n=new yn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var ir=null,ar=null;function or(e){bd(e,0)}function sr(e){if(Nt(ht(e)))return e}function cr(e,t){if(e===`change`)return t}var lr=!1;if(sn){var ur;if(sn){var dr=`oninput`in document;if(!dr){var fr=document.createElement(`div`);fr.setAttribute(`oninput`,`return;`),dr=typeof fr.oninput==`function`}ur=dr}else ur=!1;lr=ur&&(!document.documentMode||9<document.documentMode)}function pr(){ir&&(ir.detachEvent(`onpropertychange`,mr),ar=ir=null)}function mr(e){if(e.propertyName===`value`&&sr(ar)){var t=[];rr(t,ar,e,$t(e)),an(or,t)}}function hr(e,t,n){e===`focusin`?(pr(),ir=t,ar=n,ir.attachEvent(`onpropertychange`,mr)):e===`focusout`&&pr()}function gr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return sr(ar)}function _r(e,t){if(e===`click`)return sr(t)}function vr(e,t){if(e===`input`||e===`change`)return sr(t)}function yr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var br=typeof Object.is==`function`?Object.is:yr;function xr(e,t){if(br(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(!ve.call(t,i)||!br(e[i],t[i]))return!1}return!0}function Sr(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Cr(e,t){var n=Sr(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=Sr(n)}}function wr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?wr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Tr(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 Er(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 V=sn&&`documentMode`in document&&11>=document.documentMode,Dr=null,Or=null,kr=null,Ar=!1;function jr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Ar||Dr==null||Dr!==Pt(r)||(r=Dr,`selectionStart`in r&&Er(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}),kr&&xr(kr,r)||(kr=r,r=Od(Or,`onSelect`),0<r.length&&(t=new yn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Dr)))}function Mr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Nr={animationend:Mr(`Animation`,`AnimationEnd`),animationiteration:Mr(`Animation`,`AnimationIteration`),animationstart:Mr(`Animation`,`AnimationStart`),transitionrun:Mr(`Transition`,`TransitionRun`),transitionstart:Mr(`Transition`,`TransitionStart`),transitioncancel:Mr(`Transition`,`TransitionCancel`),transitionend:Mr(`Transition`,`TransitionEnd`)},Pr={},Fr={};sn&&(Fr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Nr.animationend.animation,delete Nr.animationiteration.animation,delete Nr.animationstart.animation),`TransitionEvent`in window||delete Nr.transitionend.transition);function Ir(e){if(Pr[e])return Pr[e];if(!Nr[e])return e;var t=Nr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Fr)return Pr[e]=t[n];return e}var Lr=Ir(`animationend`),H=Ir(`animationiteration`),Rr=Ir(`animationstart`),zr=Ir(`transitionrun`),Br=Ir(`transitionstart`),Vr=Ir(`transitioncancel`),Hr=Ir(`transitionend`),Ur=new Map,Wr=`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(` `);Wr.push(`scrollEnd`);function U(e,t){Ur.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-Fe(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<du)throw du=0,fu=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=Kf(e,n,ae.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case ee:return e=ri(31,n,t,a),e.elementType=ee,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 D:s=14;break a;case O: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 W(e,t,n){return e=ri(6,e,null,t),e.lanes=n,e}function li(e){var t=ri(18,null,null,0);return t.stateNode=e,t}function G(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 ui=new WeakMap;function di(e,t){if(typeof e==`object`&&e){var n=ui.get(e);return n===void 0?(t={value:e,source:t,stack:_e(t)},ui.set(e,t),t):n}return{value:e,source:t,stack:_e(t)}}var fi=[],pi=0,mi=null,hi=0,gi=[],_i=0,vi=null,yi=1,bi=``;function xi(e,t){fi[pi++]=hi,fi[pi++]=mi,mi=e,hi=t}function Si(e,t,n){gi[_i++]=yi,gi[_i++]=bi,gi[_i++]=vi,vi=e;var r=yi;e=bi;var i=32-Fe(r)-1;r&=~(1<<i),n+=1;var a=32-Fe(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,yi=1<<32-Fe(t)+i|n<<i|r,bi=a+e}else yi=1<<a|n<<i|r,bi=e}function Ci(e){e.return!==null&&(xi(e,1),Si(e,1,0))}function wi(e){for(;e===mi;)mi=fi[--pi],fi[pi]=null,hi=fi[--pi],fi[pi]=null;for(;e===vi;)vi=gi[--_i],gi[_i]=null,bi=gi[--_i],gi[_i]=null,yi=gi[--_i],gi[_i]=null}function Ti(e,t){gi[_i++]=yi,gi[_i++]=bi,gi[_i++]=vi,yi=t.id,bi=t.overflow,vi=e}var Ei=null,Di=null,K=!1,Oi=null,ki=!1,Ai=Error(i(519));function ji(e){throw Li(di(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Ai}function Mi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[it]=e,t[at]=r,n){case`dialog`:xd(`cancel`,t),xd(`close`,t);break;case`iframe`:case`object`:case`embed`:xd(`load`,t);break;case`video`:case`audio`:for(n=0;n<vd.length;n++)xd(vd[n],t);break;case`source`:xd(`error`,t);break;case`img`:case`image`:case`link`:xd(`error`,t),xd(`load`,t);break;case`details`:xd(`toggle`,t);break;case`input`:xd(`invalid`,t),Rt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:xd(`invalid`,t);break;case`textarea`:xd(`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||Pd(t.textContent,n)?(r.popover!=null&&(xd(`beforetoggle`,t),xd(`toggle`,t)),r.onScroll!=null&&xd(`scroll`,t),r.onScrollEnd!=null&&xd(`scrollend`,t),r.onClick!=null&&(t.onclick=Zt),t=!0):t=!1,t||ji(e,!0)}function Ni(e){for(Ei=e.return;Ei;)switch(Ei.tag){case 5:case 31:case 13:ki=!1;return;case 27:case 3:ki=!0;return;default:Ei=Ei.return}}function Pi(e){if(e!==Ei)return!1;if(!K)return Ni(e),K=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=n===`form`||n===`button`||Kd(e.type,e.memoizedProps)),n=!n),n&&Di&&ji(e),Ni(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Di=pf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Di=pf(e)}else t===27?(t=Di,ef(e.type)?(e=ff,ff=null,Di=e):Di=t):Di=Ei?df(e.stateNode.nextSibling):null;return!0}function Fi(){Di=Ei=null,K=!1}function Ii(){var e=Oi;return e!==null&&(Zl===null?Zl=e:Zl.push.apply(Zl,e),Oi=null),e}function Li(e){Oi===null?Oi=[e]:Oi.push(e)}var Ri=I(null),zi=null,Bi=null;function q(e,t,n){R(Ri,t._currentValue),t._currentValue=n}function Vi(e){e._currentValue=Ri.current,L(Ri)}function Hi(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 Ui(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),Hi(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),Hi(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 J(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;br(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===oe.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[tp]:e.push(tp))}a=a.return}e!==null&&Ui(t,e,n,r),t.flags|=262144}function Wi(e){for(e=e.firstContext;e!==null;){if(!br(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Gi(e){zi=e,Bi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Ki(e){return Ji(zi,e)}function qi(e,t){return zi===null&&Gi(e),Ji(e,t)}function Ji(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Bi===null){if(e===null)throw Error(i(308));Bi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Bi=Bi.next=t;return n}var Yi=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()})}},Xi=t.unstable_scheduleCallback,Zi=t.unstable_NormalPriority,Qi={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function $i(){return{controller:new Yi,data:new Map,refCount:0}}function ea(e){e.refCount--,e.refCount===0&&Xi(Zi,function(){e.controller.abort()})}var ta=null,na=0,ra=0,ia=null;function aa(e,t){if(ta===null){var n=ta=[];na=0,ra=fd(),ia={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return na++,t.then(oa,oa),t}function oa(){if(--na===0&&ta!==null){ia!==null&&(ia.status=`fulfilled`);var e=ta;ta=null,ra=0,ia=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function sa(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 ca=P.S;P.S=function(e,t){eu=Ce(),typeof t==`object`&&t&&typeof t.then==`function`&&aa(e,t),ca!==null&&ca(e,t)};var la=I(null);function ua(){var e=la.current;return e===null?Fl.pooledCache:e}function da(e,t){t===null?R(la,la.current):R(la,t.pool)}function fa(){var e=ua();return e===null?null:{parent:Qi._currentValue,pool:e}}var pa=Error(i(460)),ma=Error(i(474)),ha=Error(i(542)),ga={then:function(){}};function _a(e){return e=e.status,e===`fulfilled`||e===`rejected`}function va(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,Sa(e),e;default:if(typeof t.status==`string`)t.then(Zt,Zt);else{if(e=Fl,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,Sa(e),e}throw ba=t,pa}}function ya(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(ba=e,pa):e}}var ba=null;function xa(){if(ba===null)throw Error(i(459));var e=ba;return ba=null,e}function Sa(e){if(e===pa||e===ha)throw Error(i(483))}var Ca=null,wa=0;function Ta(e){var t=wa;return wa+=1,Ca===null&&(Ca=[]),va(Ca,e,t)}function Ea(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Da(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 Oa(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=W(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===O&&ya(i)===t.type)?(t=a(t,n.props),Ea(t,n),t.return=e,t):(t=si(n.type,n.key,n.props,null,e.mode,r),Ea(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=G(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=W(``+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),Ea(n,t),n.return=e,n;case v:return t=G(t,e.mode,n),t.return=e,t;case O:return t=ya(t),f(e,t,n)}if(N(t)||j(t))return t=ci(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Ta(t),n);if(t.$$typeof===C)return f(e,qi(e,t),n);Da(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 O:return n=ya(n),p(e,t,n,r)}if(N(n)||j(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Ta(n),r);if(n.$$typeof===C)return p(e,t,qi(e,n),r);Da(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 O:return r=ya(r),m(e,t,n,r,i)}if(N(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,Ta(r),i);if(r.$$typeof===C)return m(e,t,n,qi(t,r),i);Da(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),K&&xi(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 K&&xi(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)}),K&&xi(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),K&&xi(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 K&&xi(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)}),K&&xi(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===O&&ya(l)===r.type){n(e,r.sibling),c=a(r,o.props),Ea(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),Ea(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=G(o,e.mode,c),c.return=e,e=c}return s(e);case O:return o=ya(o),b(e,r,o,c)}if(N(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,Ta(o),c);if(o.$$typeof===C)return b(e,r,qi(e,o),c);Da(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=W(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{wa=0;var i=b(e,t,n,r);return Ca=null,i}catch(t){if(t===pa||t===ha)throw t;var a=ri(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var ka=Oa(!0),Aa=Oa(!1),ja=!1;function Ma(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Na(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 Pa(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Fa(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Pl&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 Ia(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,Ze(e,n)}}function La(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 Ra=!1;function za(){if(Ra){var e=ia;if(e!==null)throw e}}function Ba(e,t,n,r){Ra=!1;var i=e.updateQueue;ja=!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?(Ll&f)===f:(r&f)===f){f!==0&&f===ra&&(Ra=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:ja=!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),Gl|=o,e.lanes=o,e.memoizedState=d}}function Va(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function Ha(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Va(n[e],t)}var Ua=I(null),Wa=I(0);function Ga(e,t){e=Ul,R(Wa,e),R(Ua,t),Ul=e|t.baseLanes}function Ka(){R(Wa,Ul),R(Ua,Ua.current)}function qa(){Ul=Wa.current,L(Ua),L(Wa)}var Ja=I(null),Ya=null;function Xa(e){var t=e.alternate;R(to,to.current&1),R(Ja,e),Ya===null&&(t===null||Ua.current!==null||t.memoizedState!==null)&&(Ya=e)}function Za(e){R(to,to.current),R(Ja,e),Ya===null&&(Ya=e)}function Qa(e){e.tag===22?(R(to,to.current),R(Ja,e),Ya===null&&(Ya=e)):$a(e)}function $a(){R(to,to.current),R(Ja,Ja.current)}function eo(e){L(Ja),Ya===e&&(Ya=null),L(to)}var to=I(0);function no(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||cf(n)||lf(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 ro=0,Y=null,X=null,io=null,ao=!1,oo=!1,so=!1,co=0,lo=0,uo=null,fo=0;function po(){throw Error(i(321))}function mo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!br(e[n],t[n]))return!1;return!0}function ho(e,t,n,r,i,a){return ro=a,Y=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,P.H=e===null||e.memoizedState===null?Ms:Ns,so=!1,a=n(r,i),so=!1,oo&&(a=_o(t,n,r,i)),go(e),a}function go(e){P.H=js;var t=X!==null&&X.next!==null;if(ro=0,io=X=Y=null,ao=!1,lo=0,uo=null,t)throw Error(i(300));e===null||Xs||(e=e.dependencies,e!==null&&Wi(e)&&(Xs=!0))}function _o(e,t,n,r){Y=e;var a=0;do{if(oo&&(uo=null),lo=0,oo=!1,25<=a)throw Error(i(301));if(a+=1,io=X=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=Ps,o=t(n,r)}while(oo);return o}function vo(){var e=P.H,t=e.useState()[0];return t=typeof t.then==`function`?To(t):t,e=e.useState()[0],(X===null?null:X.memoizedState)!==e&&(Y.flags|=1024),t}function yo(){var e=co!==0;return co=0,e}function bo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function xo(e){if(ao){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}ao=!1}ro=0,io=X=Y=null,oo=!1,lo=co=0,uo=null}function So(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return io===null?Y.memoizedState=io=e:io=io.next=e,io}function Co(){if(X===null){var e=Y.alternate;e=e===null?null:e.memoizedState}else e=X.next;var t=io===null?Y.memoizedState:io.next;if(t!==null)io=t,X=e;else{if(e===null)throw Y.alternate===null?Error(i(467)):Error(i(310));X=e,e={memoizedState:X.memoizedState,baseState:X.baseState,baseQueue:X.baseQueue,queue:X.queue,next:null},io===null?Y.memoizedState=io=e:io=io.next=e}return io}function wo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function To(e){var t=lo;return lo+=1,uo===null&&(uo=[]),e=va(uo,e,t),t=Y,(io===null?t.memoizedState:io.next)===null&&(t=t.alternate,P.H=t===null||t.memoizedState===null?Ms:Ns),e}function Eo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return To(e);if(e.$$typeof===C)return Ki(e)}throw Error(i(438,String(e)))}function Do(e){var t=null,n=Y.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=Y.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=wo(),Y.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 Oo(e,t){return typeof t==`function`?t(e):t}function ko(e){return Ao(Co(),X,e)}function Ao(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?(ro&f)===f:(Ll&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===ra&&(d=!0);else if((ro&p)===p){u=u.next,p===ra&&(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,Y.lanes|=p,Gl|=p;f=u.action,so&&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,Y.lanes|=f,Gl|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!br(o,e.memoizedState)&&(Xs=!0,d&&(n=ia,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 jo(e){var t=Co(),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);br(o,t.memoizedState)||(Xs=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Mo(e,t,n){var r=Y,a=Co(),o=K;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!br((X||a).memoizedState,n);if(s&&(a.memoizedState=n,Xs=!0),a=a.queue,rs(Fo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||io!==null&&io.memoizedState.tag&1){if(r.flags|=2048,Qo(9,{destroy:void 0},Po.bind(null,r,a,n,t),null),Fl===null)throw Error(i(349));o||ro&127||No(r,t,n)}return n}function No(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=Y.updateQueue,t===null?(t=wo(),Y.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Po(e,t,n,r){t.value=n,t.getSnapshot=r,Io(t)&&Lo(e)}function Fo(e,t,n){return n(function(){Io(t)&&Lo(e)})}function Io(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!br(e,n)}catch{return!0}}function Lo(e){var t=Qr(e,2);t!==null&&hu(t,e,2)}function Ro(e){var t=So();if(typeof e==`function`){var n=e;if(e=n(),so){Pe(!0);try{n()}finally{Pe(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Oo,lastRenderedState:e},t}function zo(e,t,n,r){return e.baseState=n,Ao(e,X,typeof r==`function`?r:Oo)}function Bo(e,t,n,r,a){if(Os(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,Vo(t,o)):(o.next=n.next,t.pending=n.next=o)}}function Vo(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),Ho(e,t,s)}catch(n){Wo(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),P.T=a}}else try{a=n(i,r),Ho(e,t,a)}catch(n){Wo(e,t,n)}}function Ho(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){Uo(e,t,n)},function(n){return Wo(e,t,n)}):Uo(e,t,n)}function Uo(e,t,n){t.status=`fulfilled`,t.value=n,Go(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Vo(e,n)))}function Wo(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,Go(t),t=t.next;while(t!==r)}e.action=null}function Go(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Ko(e,t){return t}function qo(e,t){if(K){var n=Fl.formState;if(n!==null){a:{var r=Y;if(K){if(Di){b:{for(var i=Di,a=ki;i.nodeType!==8;){if(!a){i=null;break b}if(i=df(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Di=df(i.nextSibling),r=i.data===`F!`;break a}}ji(r)}r=!1}r&&(t=n[0])}}return n=So(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ko,lastRenderedState:t},n.queue=r,n=Ts.bind(null,Y,r),r.dispatch=n,r=Ro(!1),a=Ds.bind(null,Y,!1,r.queue),r=So(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Bo.bind(null,Y,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function Jo(e){return Yo(Co(),X,e)}function Yo(e,t,n){if(t=Ao(e,t,Ko)[0],e=ko(Oo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=To(t)}catch(e){throw e===pa?ha:e}else r=t;t=Co();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(Y.flags|=2048,Qo(9,{destroy:void 0},Xo.bind(null,i,n),null)),[r,a,e]}function Xo(e,t){e.action=t}function Zo(e){var t=Co(),n=X;if(n!==null)return Yo(t,n,e);Co(),t=t.memoizedState,n=Co();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function Qo(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=Y.updateQueue,t===null&&(t=wo(),Y.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 $o(){return Co().memoizedState}function es(e,t,n,r){var i=So();Y.flags|=e,i.memoizedState=Qo(1|t,{destroy:void 0},n,r===void 0?null:r)}function ts(e,t,n,r){var i=Co();r=r===void 0?null:r;var a=i.memoizedState.inst;X!==null&&r!==null&&mo(r,X.memoizedState.deps)?i.memoizedState=Qo(t,a,n,r):(Y.flags|=e,i.memoizedState=Qo(1|t,a,n,r))}function ns(e,t){es(8390656,8,e,t)}function rs(e,t){ts(2048,8,e,t)}function is(e){Y.flags|=4;var t=Y.updateQueue;if(t===null)t=wo(),Y.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function as(e){var t=Co().memoizedState;return is({ref:t,nextImpl:e}),function(){if(Pl&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function os(e,t){return ts(4,2,e,t)}function ss(e,t){return ts(4,4,e,t)}function cs(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 ls(e,t,n){n=n==null?null:n.concat([e]),ts(4,4,cs.bind(null,t,e),n)}function us(){}function ds(e,t){var n=Co();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&mo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function fs(e,t){var n=Co();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&mo(t,r[1]))return r[0];if(r=e(),so){Pe(!0);try{e()}finally{Pe(!1)}}return n.memoizedState=[r,t],r}function ps(e,t,n){return n===void 0||ro&1073741824&&!(Ll&261930)?e.memoizedState=t:(e.memoizedState=n,e=mu(),Y.lanes|=e,Gl|=e,n)}function ms(e,t,n,r){return br(n,t)?n:Ua.current===null?!(ro&42)||ro&1073741824&&!(Ll&261930)?(Xs=!0,e.memoizedState=n):(e=mu(),Y.lanes|=e,Gl|=e,t):(e=ps(e,n,r),br(e,t)||(Xs=!0),e)}function hs(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,Ds(e,!1,t,n);try{var c=i(),l=P.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Es(e,t,sa(c,r),pu(e)):Es(e,t,r,pu(e))}catch(n){Es(e,t,{then:function(){},status:`rejected`,reason:n},pu())}finally{F.p=a,o!==null&&s.types!==null&&(o.types=s.types),P.T=o}}function gs(){}function _s(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=vs(e).queue;hs(e,a,t,ne,n===null?gs:function(){return ys(e),n(r)})}function vs(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:Oo,lastRenderedState:ne},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Oo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function ys(e){var t=vs(e);t.next===null&&(t=e.alternate.memoizedState),Es(e,t.next.queue,{},pu())}function bs(){return Ki(tp)}function xs(){return Co().memoizedState}function Ss(){return Co().memoizedState}function Cs(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=pu();e=Pa(n);var r=Fa(t,e,n);r!==null&&(hu(r,t,n),Ia(r,t,n)),t={cache:$i()},e.payload=t;return}t=t.return}}function ws(e,t,n){var r=pu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Os(e)?ks(t,n):(n=Zr(e,t,n,r),n!==null&&(hu(n,e,r),As(n,t,r)))}function Ts(e,t,n){Es(e,t,n,pu())}function Es(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Os(e))ks(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,br(s,o))return Xr(e,t,i,0),Fl===null&&Yr(),!1}catch{}if(n=Zr(e,t,i,r),n!==null)return hu(n,e,r),As(n,t,r),!0}return!1}function Ds(e,t,n,r){if(r={lane:2,revertLane:fd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Os(e)){if(t)throw Error(i(479))}else t=Zr(e,n,r,2),t!==null&&hu(t,e,2)}function Os(e){var t=e.alternate;return e===Y||t!==null&&t===Y}function ks(e,t){oo=ao=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function As(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}var js={readContext:Ki,use:Eo,useCallback:po,useContext:po,useEffect:po,useImperativeHandle:po,useLayoutEffect:po,useInsertionEffect:po,useMemo:po,useReducer:po,useRef:po,useState:po,useDebugValue:po,useDeferredValue:po,useTransition:po,useSyncExternalStore:po,useId:po,useHostTransitionStatus:po,useFormState:po,useActionState:po,useOptimistic:po,useMemoCache:po,useCacheRefresh:po};js.useEffectEvent=po;var Ms={readContext:Ki,use:Eo,useCallback:function(e,t){return So().memoizedState=[e,t===void 0?null:t],e},useContext:Ki,useEffect:ns,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),es(4194308,4,cs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return es(4194308,4,e,t)},useInsertionEffect:function(e,t){es(4,2,e,t)},useMemo:function(e,t){var n=So();t=t===void 0?null:t;var r=e();if(so){Pe(!0);try{e()}finally{Pe(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=So();if(n!==void 0){var i=n(t);if(so){Pe(!0);try{n(t)}finally{Pe(!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=ws.bind(null,Y,e),[r.memoizedState,e]},useRef:function(e){var t=So();return e={current:e},t.memoizedState=e},useState:function(e){e=Ro(e);var t=e.queue,n=Ts.bind(null,Y,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:us,useDeferredValue:function(e,t){return ps(So(),e,t)},useTransition:function(){var e=Ro(!1);return e=hs.bind(null,Y,e.queue,!0,!1),So().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=Y,a=So();if(K){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Fl===null)throw Error(i(349));Ll&127||No(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,ns(Fo.bind(null,r,o,e),[e]),r.flags|=2048,Qo(9,{destroy:void 0},Po.bind(null,r,o,n,t),null),n},useId:function(){var e=So(),t=Fl.identifierPrefix;if(K){var n=bi,r=yi;n=(r&~(1<<32-Fe(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=co++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=fo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:bs,useFormState:qo,useActionState:qo,useOptimistic:function(e){var t=So();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Ds.bind(null,Y,!0,n),n.dispatch=t,[e,t]},useMemoCache:Do,useCacheRefresh:function(){return So().memoizedState=Cs.bind(null,Y)},useEffectEvent:function(e){var t=So(),n={impl:e};return t.memoizedState=n,function(){if(Pl&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},Ns={readContext:Ki,use:Eo,useCallback:ds,useContext:Ki,useEffect:rs,useImperativeHandle:ls,useInsertionEffect:os,useLayoutEffect:ss,useMemo:fs,useReducer:ko,useRef:$o,useState:function(){return ko(Oo)},useDebugValue:us,useDeferredValue:function(e,t){return ms(Co(),X.memoizedState,e,t)},useTransition:function(){var e=ko(Oo)[0],t=Co().memoizedState;return[typeof e==`boolean`?e:To(e),t]},useSyncExternalStore:Mo,useId:xs,useHostTransitionStatus:bs,useFormState:Jo,useActionState:Jo,useOptimistic:function(e,t){return zo(Co(),X,e,t)},useMemoCache:Do,useCacheRefresh:Ss};Ns.useEffectEvent=as;var Ps={readContext:Ki,use:Eo,useCallback:ds,useContext:Ki,useEffect:rs,useImperativeHandle:ls,useInsertionEffect:os,useLayoutEffect:ss,useMemo:fs,useReducer:jo,useRef:$o,useState:function(){return jo(Oo)},useDebugValue:us,useDeferredValue:function(e,t){var n=Co();return X===null?ps(n,e,t):ms(n,X.memoizedState,e,t)},useTransition:function(){var e=jo(Oo)[0],t=Co().memoizedState;return[typeof e==`boolean`?e:To(e),t]},useSyncExternalStore:Mo,useId:xs,useHostTransitionStatus:bs,useFormState:Zo,useActionState:Zo,useOptimistic:function(e,t){var n=Co();return X===null?(n.baseState=e,[e,n.queue.dispatch]):zo(n,X,e,t)},useMemoCache:Do,useCacheRefresh:Ss};Ps.useEffectEvent=as;function Fs(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:h({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Is={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=pu(),i=Pa(r);i.payload=t,n!=null&&(i.callback=n),t=Fa(e,i,r),t!==null&&(hu(t,e,r),Ia(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=pu(),i=Pa(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Fa(e,i,r),t!==null&&(hu(t,e,r),Ia(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=pu(),r=Pa(n);r.tag=2,t!=null&&(r.callback=t),t=Fa(e,r,n),t!==null&&(hu(t,e,n),Ia(t,e,n))}};function Ls(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?!xr(n,r)||!xr(i,a):!0}function Rs(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&&Is.enqueueReplaceState(t,t.state,null)}function zs(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=h({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function Bs(e){Gr(e)}function Vs(e){console.error(e)}function Hs(e){Gr(e)}function Us(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Ws(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 Gs(e,t,n){return n=Pa(n),n.tag=3,n.payload={element:null},n.callback=function(){Us(e,t)},n}function Ks(e){return e=Pa(e),e.tag=3,e}function qs(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(){Ws(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){Ws(t,n,r),typeof i!=`function`&&(ru===null?ru=new Set([this]):ru.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function Js(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&J(t,n,a,!0),n=Ja.current,n!==null){switch(n.tag){case 31:case 13:return Ya===null?Du():n.alternate===null&&Wl===0&&(Wl=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===ga?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),Ku(e,r,a)),!1;case 22:return n.flags|=65536,r===ga?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)),Ku(e,r,a)),!1}throw Error(i(435,n.tag))}return Ku(e,r,a),Du(),!1}if(K)return t=Ja.current,t===null?(r!==Ai&&(t=Error(i(423),{cause:r}),Li(di(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=di(r,n),a=Gs(e.stateNode,r,a),La(e,a),Wl!==4&&(Wl=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==Ai&&(e=Error(i(422),{cause:r}),Li(di(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=di(o,n),Xl===null?Xl=[o]:Xl.push(o),Wl!==4&&(Wl=2),t===null)return!0;r=di(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=Gs(n.stateNode,r,e),La(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`&&(ru===null||!ru.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=Ks(a),qs(a,e,n,r),La(n,a),!1}n=n.return}while(n!==null);return!1}var Ys=Error(i(461)),Xs=!1;function Zs(e,t,n,r){t.child=e===null?Aa(t,null,n,r):ka(t,e.child,n,r)}function Qs(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 Gi(t),r=ho(e,t,n,o,a,i),s=yo(),e!==null&&!Xs?(bo(e,t,i),Sc(e,t,i)):(K&&s&&Ci(t),t.flags|=1,Zs(e,t,r,i),t.child)}function $s(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,ec(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,!Cc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?xr:n,n(o,r)&&e.ref===t.ref)return Sc(e,t,i)}return t.flags|=1,e=ai(a,r),e.ref=t.ref,e.return=t,t.child=e}function ec(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(xr(a,r)&&e.ref===t.ref){if(Xs=!1,t.pendingProps=r=a,Cc(e,i))e.flags&131072&&(Xs=!0);else return t.lanes=e.lanes,Sc(e,t,i)}}return cc(e,t,n,r,i)}function tc(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 rc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&da(t,a===null?null:a.cachePool),a===null?Ka():Ga(t,a),Qa(t);else return r=t.lanes=536870912,rc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&da(t,null),Ka(),$a(t)):(da(t,a.cachePool),Ga(t,a),$a(t),t.memoizedState=null);return Zs(e,t,i,n),t.child}function nc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function rc(e,t,n,r,i){var a=ua();return a=a===null?null:{parent:Qi._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&da(t,null),Ka(),Qa(t),e!==null&&J(e,t,r,!0),t.childLanes=i,null}function ic(e,t){return t=_c({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function ac(e,t,n){return ka(t,e.child,null,n),e=ic(t,t.pendingProps),e.flags|=2,eo(t),t.memoizedState=null,e}function oc(e,t,n){var r=t.pendingProps,a=!!(t.flags&128);if(t.flags&=-129,e===null){if(K){if(r.mode===`hidden`)return e=ic(t,r),t.lanes=536870912,nc(null,e);if(Za(t),(e=Di)?(e=sf(e,ki),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:vi===null?null:{id:yi,overflow:bi},retryLane:536870912,hydrationErrors:null},n=li(e),n.return=t,t.child=n,Ei=t,Di=null)):e=null,e===null)throw ji(t);return t.lanes=536870912,null}return ic(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(Za(t),a){if(t.flags&256)t.flags&=-257,t=ac(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558))}else if(Xs||J(e,t,n,!1),a=(n&e.childLanes)!==0,Xs||a){if(r=Fl,r!==null&&(s=Qe(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,Qr(e,s),hu(r,e,s),Ys;Du(),t=ac(e,t,n)}else e=o.treeContext,Di=df(s.nextSibling),Ei=t,K=!0,Oi=null,ki=!1,e!==null&&Ti(t,e),t=ic(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 sc(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 cc(e,t,n,r,i){return Gi(t),n=ho(e,t,n,r,void 0,i),r=yo(),e!==null&&!Xs?(bo(e,t,i),Sc(e,t,i)):(K&&r&&Ci(t),t.flags|=1,Zs(e,t,n,i),t.child)}function lc(e,t,n,r,i,a){return Gi(t),t.updateQueue=null,n=_o(t,r,n,i),go(e),r=yo(),e!==null&&!Xs?(bo(e,t,a),Sc(e,t,a)):(K&&r&&Ci(t),t.flags|=1,Zs(e,t,n,a),t.child)}function uc(e,t,n,r,i){if(Gi(t),t.stateNode===null){var a=ti,o=n.contextType;typeof o==`object`&&o&&(a=Ki(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Is,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Ma(t),o=n.contextType,a.context=typeof o==`object`&&o?Ki(o):ti,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Fs(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&&Is.enqueueReplaceState(a,a.state,null),Ba(t,r,a,i),za(),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=zs(n,s);a.props=c;var l=a.context,u=n.contextType;o=ti,typeof u==`object`&&u&&(o=Ki(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)&&Rs(t,a,r,o),ja=!1;var f=t.memoizedState;a.state=f,Ba(t,r,a,i),za(),l=t.memoizedState,s||f!==l||ja?(typeof d==`function`&&(Fs(t,n,d,r),l=t.memoizedState),(c=ja||Ls(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,Na(e,t),o=t.memoizedProps,u=zs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ti,typeof l==`object`&&l&&(c=Ki(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)&&Rs(t,a,r,c),ja=!1,f=t.memoizedState,a.state=f,Ba(t,r,a,i),za();var p=t.memoizedState;o!==d||f!==p||ja||e!==null&&e.dependencies!==null&&Wi(e.dependencies)?(typeof s==`function`&&(Fs(t,n,s,r),p=t.memoizedState),(u=ja||Ls(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&Wi(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,sc(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=ka(t,e.child,null,i),t.child=ka(t,null,n,i)):Zs(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Sc(e,t,i),e}function dc(e,t,n,r){return Fi(),t.flags|=256,Zs(e,t,n,r),t.child}var fc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function pc(e){return{baseLanes:e,cachePool:fa()}}function mc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=Jl),e}function hc(e,t,n){var r=t.pendingProps,a=!1,o=!!(t.flags&128),s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:!!(to.current&2)),s&&(a=!0,t.flags&=-129),s=!!(t.flags&32),t.flags&=-33,e===null){if(K){if(a?Xa(t):$a(t),(e=Di)?(e=sf(e,ki),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:vi===null?null:{id:yi,overflow:bi},retryLane:536870912,hydrationErrors:null},n=li(e),n.return=t,t.child=n,Ei=t,Di=null)):e=null,e===null)throw ji(t);return lf(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?($a(t),a=t.mode,c=_c({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=pc(n),r.childLanes=mc(e,s,n),t.memoizedState=fc,nc(null,r)):(Xa(t),gc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(Xa(t),t.flags&=-257,t=vc(e,t,n)):t.memoizedState===null?($a(t),c=r.fallback,a=t.mode,r=_c({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,ka(t,e.child,null,n),r=t.child,r.memoizedState=pc(n),r.childLanes=mc(e,s,n),t.memoizedState=fc,t=nc(null,r)):($a(t),t.child=e.child,t.flags|=128,t=null);else if(Xa(t),lf(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Li({value:r,source:null,stack:null}),t=vc(e,t,n)}else if(Xs||J(e,t,n,!1),s=(n&e.childLanes)!==0,Xs||s){if(s=Fl,s!==null&&(r=Qe(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,Qr(e,r),hu(s,e,r),Ys;cf(c)||Du(),t=vc(e,t,n)}else cf(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Di=df(c.nextSibling),Ei=t,K=!0,Oi=null,ki=!1,e!==null&&Ti(t,e),t=gc(t,r.children),t.flags|=4096);return t}return a?($a(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,nc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=pc(n):(a=c.cachePool,a===null?a=fa():(l=Qi._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=mc(e,s,n),t.memoizedState=fc,nc(e.child,r)):(Xa(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 gc(e,t){return t=_c({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function _c(e,t){return e=ri(22,e,null,t),e.lanes=0,e}function vc(e,t,n){return ka(t,e.child,null,n),e=gc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function yc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Hi(e.return,t,n)}function bc(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 xc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=to.current,s=!!(o&2);if(s?(o=o&1|2,t.flags|=128):o&=1,R(to,o),Zs(e,t,r,n),r=K?hi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&yc(e,n,t);else if(e.tag===19)yc(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&&no(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),bc(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&&no(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}bc(t,!0,n,null,a,r);break;case`together`:bc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Sc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Gl|=t.lanes,(n&t.childLanes)===0){if(e!==null){if(J(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 Cc(e,t){return(e.lanes&t)!==0||(e=e.dependencies,!!(e!==null&&Wi(e)))}function wc(e,t,n){switch(t.tag){case 3:se(t,t.stateNode.containerInfo),q(t,Qi,e.memoizedState.cache),Fi();break;case 27:case 5:le(t);break;case 4:se(t,t.stateNode.containerInfo);break;case 10:q(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,Za(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(Xa(t),e=Sc(e,t,n),e===null?null:e.sibling):hc(e,t,n):(Xa(t),t.flags|=128,null);Xa(t);break;case 19:var i=!!(e.flags&128);if(r=(n&t.childLanes)!==0,r||=(J(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return xc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),R(to,to.current),r)break;return null;case 22:return t.lanes=0,tc(e,t,n,t.pendingProps);case 24:q(t,Qi,e.memoizedState.cache)}return Sc(e,t,n)}function Tc(e,t,n){if(e!==null){if(e.memoizedProps!==t.pendingProps)Xs=!0;else{if(!Cc(e,n)&&!(t.flags&128))return Xs=!1,wc(e,t,n);Xs=!!(e.flags&131072)}}else Xs=!1,K&&t.flags&1048576&&Si(t,hi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=ya(t.elementType),t.type=e,typeof e==`function`)ii(e)?(r=zs(e,r),t.tag=1,t=uc(null,t,e,r,n)):(t.tag=0,t=cc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===w){t.tag=11,t=Qs(null,t,e,r,n);break a}if(a===D){t.tag=14,t=$s(null,t,e,r,n);break a}}throw t=te(e)||e,Error(i(306,t,``))}}return t;case 0:return cc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=zs(r,t.pendingProps),uc(e,t,r,a,n);case 3:a:{if(se(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,Na(e,t),Ba(t,r,null,n);var s=t.memoizedState;if(r=s.cache,q(t,Qi,r),r!==o.cache&&Ui(t,[Qi],n,!0),za(),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=dc(e,t,r,n);break a}if(r!==a){a=di(Error(i(424)),t),Li(a),t=dc(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(Di=df(e.firstChild),Ei=t,K=!0,Oi=null,ki=!0,n=Aa(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Fi(),r===a){t=Sc(e,t,n);break a}Zs(e,t,r,n)}t=t.child}return t;case 26:return sc(e,t),e===null?(n=Mf(t.type,null,t.pendingProps,null))?t.memoizedState=n:K||(n=t.type,e=t.pendingProps,r=Ud(B.current).createElement(n),r[it]=t,r[at]=e,Ld(r,n,e),_t(r),t.stateNode=r):t.memoizedState=Mf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return le(t),e===null&&K&&(r=t.stateNode=hf(t.type,t.pendingProps,B.current),Ei=t,ki=!0,a=Di,ef(t.type)?(ff=a,Di=df(r.firstChild)):Di=a),Zs(e,t,t.pendingProps.children,n),sc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&K&&((a=r=Di)&&(r=af(r,t.type,t.pendingProps,ki),r===null?a=!1:(t.stateNode=r,Ei=t,Di=df(r.firstChild),ki=!1,a=!0)),a||ji(t)),le(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,Kd(a,o)?r=null:s!==null&&Kd(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=ho(e,t,vo,null,null,n),tp._currentValue=a),sc(e,t),Zs(e,t,r,n),t.child;case 6:return e===null&&K&&((e=n=Di)&&(n=of(n,t.pendingProps,ki),n===null?e=!1:(t.stateNode=n,Ei=t,Di=null,e=!0)),e||ji(t)),null;case 13:return hc(e,t,n);case 4:return se(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=ka(t,null,r,n):Zs(e,t,r,n),t.child;case 11:return Qs(e,t,t.type,t.pendingProps,n);case 7:return Zs(e,t,t.pendingProps,n),t.child;case 8:return Zs(e,t,t.pendingProps.children,n),t.child;case 12:return Zs(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,q(t,t.type,r.value),Zs(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,Gi(t),a=Ki(a),r=r(a),t.flags|=1,Zs(e,t,r,n),t.child;case 14:return $s(e,t,t.type,t.pendingProps,n);case 15:return ec(e,t,t.type,t.pendingProps,n);case 19:return xc(e,t,n);case 31:return oc(e,t,n);case 22:return tc(e,t,n,t.pendingProps);case 24:return Gi(t),r=Ki(Qi),e===null?(a=ua(),a===null&&(a=Fl,o=$i(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},Ma(t),q(t,Qi,a)):((e.lanes&n)!==0&&(Na(e,t),Ba(t,null,null,n),za()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,q(t,Qi,r),r!==a.cache&&Ui(t,[Qi],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),q(t,Qi,r))),Zs(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function Ec(e){e.flags|=4}function Dc(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(wu())e.flags|=8192;else throw ba=ga,ma}}else e.flags&=-16777217}function Oc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!qf(t)){if(wu())e.flags|=8192;else throw ba=ga,ma}}function kc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Ke(),e.lanes|=t,Yl|=t)}function Ac(e,t){if(!K)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 jc(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 Mc(e,t,n){var r=t.pendingProps;switch(wi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return jc(t),null;case 1:return jc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Vi(Qi),ce(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Pi(t)?Ec(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ii())),jc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(Ec(t),o===null?(jc(t),Dc(t,a,null,r,n)):(jc(t),Oc(t,o))):o?o===e.memoizedState?(jc(t),t.flags&=-16777217):(Ec(t),jc(t),Oc(t,o)):(e=e.memoizedProps,e!==r&&Ec(t),jc(t),Dc(t,a,e,r,n)),null;case 27:if(ue(t),n=B.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Ec(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return jc(t),null}e=ae.current,Pi(t)?Mi(t,e):(e=hf(a,r,n),t.stateNode=e,Ec(t))}return jc(t),null;case 5:if(ue(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Ec(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return jc(t),null}if(o=ae.current,Pi(t))Mi(t,o);else{var s=Ud(B.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[it]=t,o[at]=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(Ld(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&&Ec(t)}}return jc(t),Dc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Ec(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=B.current,Pi(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Ei,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[it]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Pd(e.nodeValue,n)),e||ji(t,!0)}else e=Ud(e).createTextNode(r),e[it]=t,t.stateNode=e}return jc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Pi(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[it]=t}else Fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;jc(t),e=!1}else n=Ii(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(eo(t),t):(eo(t),null);if(t.flags&128)throw Error(i(558))}return jc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Pi(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[it]=t}else Fi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;jc(t),a=!1}else a=Ii(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(eo(t),t):(eo(t),null)}return eo(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),kc(t,t.updateQueue),jc(t),null);case 4:return ce(),e===null&&wd(t.stateNode.containerInfo),jc(t),null;case 10:return Vi(t.type),jc(t),null;case 19:if(L(to),r=t.memoizedState,r===null)return jc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Ac(r,!1);else{if(Wl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=no(e),o!==null){for(t.flags|=128,Ac(r,!1),e=o.updateQueue,t.updateQueue=e,kc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)oi(n,e),n=n.sibling;return R(to,to.current&1|2),K&&xi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ce()>tu&&(t.flags|=128,a=!0,Ac(r,!1),t.lanes=4194304)}}else{if(!a){if(e=no(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,kc(t,e),Ac(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!K)return jc(t),null}else 2*Ce()-r.renderingStartTime>tu&&n!==536870912&&(t.flags|=128,a=!0,Ac(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?(jc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ce(),e.sibling=null,n=to.current,R(to,a?n&1|2:n&1),K&&xi(t,r.treeForkCount),e);case 22:case 23:return eo(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)&&(jc(t),t.subtreeFlags&6&&(t.flags|=8192)):jc(t),n=t.updateQueue,n!==null&&kc(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&&L(la),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Vi(Qi),jc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Nc(e,t){switch(wi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Vi(Qi),ce(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ue(t),null;case 31:if(t.memoizedState!==null){if(eo(t),t.alternate===null)throw Error(i(340));Fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(eo(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Fi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return L(to),null;case 4:return ce(),null;case 10:return Vi(t.type),null;case 22:case 23:return eo(t),qa(),e!==null&&L(la),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Vi(Qi),null;case 25:return null;default:return null}}function Pc(e,t){switch(wi(t),t.tag){case 3:Vi(Qi),ce();break;case 26:case 27:case 5:ue(t);break;case 4:ce();break;case 31:t.memoizedState!==null&&eo(t);break;case 13:eo(t);break;case 19:L(to);break;case 10:Vi(t.type);break;case 22:case 23:eo(t),qa(),e!==null&&L(la);break;case 24:Vi(Qi)}}function Fc(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){Gu(t,t.return,e)}}function Ic(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){Gu(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Gu(t,t.return,e)}}function Lc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ha(t,n)}catch(t){Gu(e,e.return,t)}}}function Rc(e,t,n){n.props=zs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Gu(e,t,n)}}function zc(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){Gu(e,t,n)}}function Bc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){Gu(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){Gu(e,t,n)}else n.current=null}}function Vc(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){Gu(e,e.return,t)}}function Hc(e,t,n){try{var r=e.stateNode;Rd(r,e.type,n,t),r[at]=t}catch(t){Gu(e,e.return,t)}}function Uc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&ef(e.type)||e.tag===4}function Wc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||Uc(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&&ef(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 Gc(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&&ef(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Gc(e,t,n),e=e.sibling;e!==null;)Gc(e,t,n),e=e.sibling}function Kc(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&&ef(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Kc(e,t,n),e=e.sibling;e!==null;)Kc(e,t,n),e=e.sibling}function qc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Ld(t,r,n),t[it]=e,t[at]=n}catch(t){Gu(e,e.return,t)}}var Jc=!1,Yc=!1,Xc=!1,Zc=typeof WeakSet==`function`?WeakSet:Set,Qc=null;function $c(e,t){if(e=e.containerInfo,Vd=up,e=Tr(e),Er(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(Hd={focusedElem:e,selectionRange:n},up=!1,Qc=t;Qc!==null;)if(t=Qc,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,Qc=e;else for(;Qc!==null;){switch(t=Qc,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=zs(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Gu(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)rf(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:rf(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,Qc=e;break}Qc=t.return}}function el(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:hl(e,n),r&4&&Fc(5,n);break;case 1:if(hl(e,n),r&4){if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){Gu(n,n.return,e)}else{var i=zs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Gu(n,n.return,e)}}}r&64&&Lc(n),r&512&&zc(n,n.return);break;case 3:if(hl(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{Ha(e,t)}catch(e){Gu(n,n.return,e)}}break;case 27:t===null&&r&4&&qc(n);case 26:case 5:hl(e,n),t===null&&r&4&&Vc(n),r&512&&zc(n,n.return);break;case 12:hl(e,n);break;case 31:hl(e,n),r&4&&ol(e,n);break;case 13:hl(e,n),r&4&&sl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=Yu.bind(null,n),uf(e,n))));break;case 22:if(r=n.memoizedState!==null||Jc,!r){t=t!==null&&t.memoizedState!==null||Yc,i=Jc;var a=Yc;Jc=r,(Yc=t)&&!a?_l(e,n,!!(n.subtreeFlags&8772)):hl(e,n),Jc=i,Yc=a}break;case 30:break;default:hl(e,n)}}function tl(e){var t=e.alternate;t!==null&&(e.alternate=null,tl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&ft(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 nl=null,rl=!1;function il(e,t,n){for(n=n.child;n!==null;)al(e,t,n),n=n.sibling}function al(e,t,n){if(Ne&&typeof Ne.onCommitFiberUnmount==`function`)try{Ne.onCommitFiberUnmount(Me,n)}catch{}switch(n.tag){case 26:Yc||Bc(n,t),il(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:Yc||Bc(n,t);var r=nl,i=rl;ef(n.type)&&(nl=n.stateNode,rl=!1),il(e,t,n),gf(n.stateNode),nl=r,rl=i;break;case 5:Yc||Bc(n,t);case 6:if(r=nl,i=rl,nl=null,il(e,t,n),nl=r,rl=i,nl!==null){if(rl)try{(nl.nodeType===9?nl.body:nl.nodeName===`HTML`?nl.ownerDocument.body:nl).removeChild(n.stateNode)}catch(e){Gu(n,t,e)}else try{nl.removeChild(n.stateNode)}catch(e){Gu(n,t,e)}}break;case 18:nl!==null&&(rl?(e=nl,tf(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Ip(e)):tf(nl,n.stateNode));break;case 4:r=nl,i=rl,nl=n.stateNode.containerInfo,rl=!0,il(e,t,n),nl=r,rl=i;break;case 0:case 11:case 14:case 15:Ic(2,n,t),Yc||Ic(4,n,t),il(e,t,n);break;case 1:Yc||(Bc(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Rc(n,t,r)),il(e,t,n);break;case 21:il(e,t,n);break;case 22:Yc=(r=Yc)||n.memoizedState!==null,il(e,t,n),Yc=r;break;default:il(e,t,n)}}function ol(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Ip(e)}catch(e){Gu(t,t.return,e)}}}function sl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Ip(e)}catch(e){Gu(t,t.return,e)}}function cl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Zc),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Zc),t;default:throw Error(i(435,e.tag))}}function ll(e,t){var n=cl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Xu.bind(null,e,t);t.then(r,r)}})}function ul(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(ef(c.type)){nl=c.stateNode,rl=!1;break a}break;case 5:nl=c.stateNode,rl=!1;break a;case 3:case 4:nl=c.stateNode.containerInfo,rl=!0;break a}c=c.return}if(nl===null)throw Error(i(160));al(o,s,a),nl=null,rl=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)fl(t,e),t=t.sibling}var dl=null;function fl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:ul(t,e),pl(e),r&4&&(Ic(3,e,e.return),Fc(3,e),Ic(5,e,e.return));break;case 1:ul(t,e),pl(e),r&512&&(Yc||n===null||Bc(n,n.return)),r&64&&Jc&&(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=dl;if(ul(t,e),pl(e),r&512&&(Yc||n===null||Bc(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[dt]||o[it]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Ld(o,r,n),o[it]=e,_t(o),r=o;break a;case`link`:var s=Wf(`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),Ld(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Wf(`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),Ld(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[it]=e,_t(o),r=o}e.stateNode=r}else Gf(a,e.type,e.stateNode)}else e.stateNode=zf(a,r,e.memoizedProps)}else o===r?r===null&&e.stateNode!==null&&Hc(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?Gf(a,e.type,e.stateNode):zf(a,r,e.memoizedProps))}break;case 27:ul(t,e),pl(e),r&512&&(Yc||n===null||Bc(n,n.return)),n!==null&&r&4&&Hc(e,e.memoizedProps,n.memoizedProps);break;case 5:if(ul(t,e),pl(e),r&512&&(Yc||n===null||Bc(n,n.return)),e.flags&32){a=e.stateNode;try{Ut(a,``)}catch(t){Gu(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,Hc(e,a,n===null?a:n.memoizedProps)),r&1024&&(Xc=!0);break;case 6:if(ul(t,e),pl(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Gu(e,e.return,t)}}break;case 3:if(Uf=null,a=dl,dl=yf(t.containerInfo),ul(t,e),dl=a,pl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Ip(t.containerInfo)}catch(t){Gu(e,e.return,t)}Xc&&(Xc=!1,ml(e));break;case 4:r=dl,dl=yf(e.stateNode.containerInfo),ul(t,e),pl(e),dl=r;break;case 12:ul(t,e),pl(e);break;case 31:ul(t,e),pl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ll(e,r)));break;case 13:ul(t,e),pl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&($l=Ce()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ll(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=Jc,d=Yc;if(Jc=u||a,Yc=d||l,ul(t,e),Yc=d,Jc=u,pl(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||Jc||Yc||gl(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){Gu(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){Gu(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?nf(m,!0):nf(l.stateNode,!1)}catch(e){Gu(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,ll(e,n))));break;case 19:ul(t,e),pl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,ll(e,r)));break;case 30:break;case 21:break;default:ul(t,e),pl(e)}}function pl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(Uc(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;Kc(e,Wc(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Ut(o,``),n.flags&=-33),Kc(e,Wc(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;Gc(e,Wc(e),s);break;default:throw Error(i(161))}}catch(t){Gu(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function ml(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;ml(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function hl(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)el(e,t.alternate,t),t=t.sibling}function gl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Ic(4,t,t.return),gl(t);break;case 1:Bc(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Rc(t,t.return,n),gl(t);break;case 27:gf(t.stateNode);case 26:case 5:Bc(t,t.return),gl(t);break;case 22:t.memoizedState===null&&gl(t);break;case 30:gl(t);break;default:gl(t)}e=e.sibling}}function _l(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:_l(i,a,n),Fc(4,a);break;case 1:if(_l(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){Gu(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++)Va(c[i],s)}catch(e){Gu(r,r.return,e)}}n&&o&64&&Lc(a),zc(a,a.return);break;case 27:qc(a);case 26:case 5:_l(i,a,n),n&&r===null&&o&4&&Vc(a),zc(a,a.return);break;case 12:_l(i,a,n);break;case 31:_l(i,a,n),n&&o&4&&ol(i,a);break;case 13:_l(i,a,n),n&&o&4&&sl(i,a);break;case 22:a.memoizedState===null&&_l(i,a,n),zc(a,a.return);break;case 30:break;default:_l(i,a,n)}t=t.sibling}}function vl(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&&ea(n))}function yl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ea(e))}function bl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)xl(e,t,n,r),t=t.sibling}function xl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:bl(e,t,n,r),i&2048&&Fc(9,t);break;case 1:bl(e,t,n,r);break;case 3:bl(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&&ea(e)));break;case 12:if(i&2048){bl(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){Gu(t,t.return,e)}}else bl(e,t,n,r);break;case 31:bl(e,t,n,r);break;case 13:bl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?bl(e,t,n,r):(a._visibility|=2,Sl(e,t,n,r,!!(t.subtreeFlags&10256)||!1)):a._visibility&2?bl(e,t,n,r):Cl(e,t),i&2048&&vl(o,t);break;case 24:bl(e,t,n,r),i&2048&&yl(t.alternate,t);break;default:bl(e,t,n,r)}}function Sl(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:Sl(a,o,s,c,i),Fc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Sl(a,o,s,c,i)):u._visibility&2?Sl(a,o,s,c,i):Cl(a,o),i&&l&2048&&vl(o.alternate,o);break;case 24:Sl(a,o,s,c,i),i&&l&2048&&yl(o.alternate,o);break;default:Sl(a,o,s,c,i)}t=t.sibling}}function Cl(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:Cl(n,r),i&2048&&vl(r.alternate,r);break;case 24:Cl(n,r),i&2048&&yl(r.alternate,r);break;default:Cl(n,r)}t=t.sibling}}var wl=8192;function Tl(e,t,n){if(e.subtreeFlags&wl)for(e=e.child;e!==null;)El(e,t,n),e=e.sibling}function El(e,t,n){switch(e.tag){case 26:Tl(e,t,n),e.flags&wl&&e.memoizedState!==null&&Jf(n,dl,e.memoizedState,e.memoizedProps);break;case 5:Tl(e,t,n);break;case 3:case 4:var r=dl;dl=yf(e.stateNode.containerInfo),Tl(e,t,n),dl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=wl,wl=16777216,Tl(e,t,n),wl=r):Tl(e,t,n));break;default:Tl(e,t,n)}}function Dl(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 Ol(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Qc=r,jl(r,e)}Dl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)kl(e),e=e.sibling}function kl(e){switch(e.tag){case 0:case 11:case 15:Ol(e),e.flags&2048&&Ic(9,e,e.return);break;case 3:Ol(e);break;case 12:Ol(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Al(e)):Ol(e);break;default:Ol(e)}}function Al(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];Qc=r,jl(r,e)}Dl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Ic(8,t,t.return),Al(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Al(t));break;default:Al(t)}e=e.sibling}}function jl(e,t){for(;Qc!==null;){var n=Qc;switch(n.tag){case 0:case 11:case 15:Ic(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:ea(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,Qc=r;else a:for(n=e;Qc!==null;){r=Qc;var i=r.sibling,a=r.return;if(tl(r),r===n){Qc=null;break a}if(i!==null){i.return=a,Qc=i;break a}Qc=a}}}var Ml={getCacheForType:function(e){var t=Ki(Qi),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return Ki(Qi).controller.signal}},Nl=typeof WeakMap==`function`?WeakMap:Map,Pl=0,Fl=null,Il=null,Ll=0,Rl=0,zl=null,Bl=!1,Vl=!1,Hl=!1,Ul=0,Wl=0,Gl=0,Kl=0,ql=0,Jl=0,Yl=0,Xl=null,Zl=null,Ql=!1,$l=0,eu=0,tu=1/0,nu=null,ru=null,iu=0,au=null,ou=null,su=0,cu=0,lu=null,uu=null,du=0,fu=null;function pu(){return Pl&2&&Ll!==0?Ll&-Ll:P.T===null?tt():fd()}function mu(){if(Jl===0){if(!(Ll&536870912)||K){var e=Be;Be<<=1,!(Be&3932160)&&(Be=262144),Jl=e}else Jl=536870912}return e=Ja.current,e!==null&&(e.flags|=32),Jl}function hu(e,t,n){(e===Fl&&(Rl===2||Rl===9)||e.cancelPendingCommit!==null)&&(Su(e,0),yu(e,Ll,Jl,!1)),Je(e,n),(!(Pl&2)||e!==Fl)&&(e===Fl&&(!(Pl&2)&&(Kl|=n),Wl===4&&yu(e,Ll,Jl,!1)),id(e))}function gu(e,t,n){if(Pl&6)throw Error(i(327));var r=!n&&!(t&127)&&(t&e.expiredLanes)===0||We(e,t),a=r?Au(e,t):Ou(e,t,!0),o=r;do{if(a===0){Vl&&!r&&yu(e,t,0,!1);break}if(n=e.current.alternate,o&&!vu(n)){a=Ou(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=Xl;var l=c.current.memoizedState.isDehydrated;if(l&&(Su(c,s).flags|=256),s=Ou(c,s,!1),s!==2){if(Hl&&!l){c.errorRecoveryDisabledLanes|=o,Kl|=o,a=4;break a}o=Zl,Zl=a,o!==null&&(Zl===null?Zl=o:Zl.push.apply(Zl,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Su(e,0),yu(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:yu(r,t,Jl,!Bl);break a;case 2:Zl=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=$l+300-Ce(),10<a)){if(yu(r,t,Jl,!Bl),Ue(r,0,!0)!==0)break a;su=t,r.timeoutHandle=Yd(_u.bind(null,r,n,Zl,nu,Ql,t,Jl,Kl,Yl,Bl,o,`Throttled`,-0,0),a);break a}_u(r,n,Zl,nu,Ql,t,Jl,Kl,Yl,Bl,o,null,-0,0)}break}while(1);id(e)}function _u(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},El(t,a,d);var m=(a&62914560)===a?$l-Ce():(a&4194048)===a?eu-Ce():0;if(m=Xf(d,m),m!==null){su=a,e.cancelPendingCommit=m(Lu.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),yu(e,a,o,!l);return}}Lu(e,t,a,n,r,i,o,s,c)}function vu(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(!br(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 yu(e,t,n,r){t&=~ql,t&=~Kl,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Fe(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&Xe(e,n,t)}function bu(){return Pl&6?!0:(ad(0,!1),!1)}function xu(){if(Il!==null){if(Rl===0)var e=Il.return;else e=Il,Bi=zi=null,xo(e),Ca=null,wa=0,e=Il;for(;e!==null;)Pc(e.alternate,e),e=e.return;Il=null}}function Su(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,Xd(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),su=0,xu(),Fl=e,Il=n=ai(e.current,null),Ll=t,Rl=0,zl=null,Bl=!1,Vl=We(e,t),Hl=!1,Yl=Jl=ql=Kl=Gl=Wl=0,Zl=Xl=null,Ql=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Fe(r),a=1<<i;t|=e[i],r&=~a}return Ul=t,Yr(),n}function Cu(e,t){Y=null,P.H=js,t===pa||t===ha?(t=xa(),Rl=3):t===ma?(t=xa(),Rl=4):Rl=t===Ys?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,zl=t,Il===null&&(Wl=1,Us(e,di(t,e.current)))}function wu(){var e=Ja.current;return e===null?!0:(Ll&4194048)===Ll?Ya===null:(Ll&62914560)===Ll||Ll&536870912?e===Ya:!1}function Tu(){var e=P.H;return P.H=js,e===null?js:e}function Eu(){var e=P.A;return P.A=Ml,e}function Du(){Wl=4,Bl||(Ll&4194048)!==Ll&&Ja.current!==null||(Vl=!0),!(Gl&134217727)&&!(Kl&134217727)||Fl===null||yu(Fl,Ll,Jl,!1)}function Ou(e,t,n){var r=Pl;Pl|=2;var i=Tu(),a=Eu();(Fl!==e||Ll!==t)&&(nu=null,Su(e,t)),t=!1;var o=Wl;a:do try{if(Rl!==0&&Il!==null){var s=Il,c=zl;switch(Rl){case 8:xu(),o=6;break a;case 3:case 2:case 9:case 6:Ja.current===null&&(t=!0);var l=Rl;if(Rl=0,zl=null,Pu(e,s,c,l),n&&Vl){o=0;break a}break;default:l=Rl,Rl=0,zl=null,Pu(e,s,c,l)}}ku(),o=Wl;break}catch(t){Cu(e,t)}while(1);return t&&e.shellSuspendCounter++,Bi=zi=null,Pl=r,P.H=i,P.A=a,Il===null&&(Fl=null,Ll=0,Yr()),o}function ku(){for(;Il!==null;)Mu(Il)}function Au(e,t){var n=Pl;Pl|=2;var r=Tu(),a=Eu();Fl!==e||Ll!==t?(nu=null,tu=Ce()+500,Su(e,t)):Vl=We(e,t);a:do try{if(Rl!==0&&Il!==null){t=Il;var o=zl;b:switch(Rl){case 1:Rl=0,zl=null,Pu(e,t,o,1);break;case 2:case 9:if(_a(o)){Rl=0,zl=null,Nu(t);break}t=function(){Rl!==2&&Rl!==9||Fl!==e||(Rl=7),id(e)},o.then(t,t);break a;case 3:Rl=7;break a;case 4:Rl=5;break a;case 7:_a(o)?(Rl=0,zl=null,Nu(t)):(Rl=0,zl=null,Pu(e,t,o,7));break;case 5:var s=null;switch(Il.tag){case 26:s=Il.memoizedState;case 5:case 27:var c=Il;if(s?qf(s):c.stateNode.complete){Rl=0,zl=null;var l=c.sibling;if(l!==null)Il=l;else{var u=c.return;u===null?Il=null:(Il=u,Fu(u))}break b}}Rl=0,zl=null,Pu(e,t,o,5);break;case 6:Rl=0,zl=null,Pu(e,t,o,6);break;case 8:xu(),Wl=6;break a;default:throw Error(i(462))}}ju();break}catch(t){Cu(e,t)}while(1);return Bi=zi=null,P.H=r,P.A=a,Pl=n,Il===null?(Fl=null,Ll=0,Yr(),Wl):0}function ju(){for(;Il!==null&&!xe();)Mu(Il)}function Mu(e){var t=Tc(e.alternate,e,Ul);e.memoizedProps=e.pendingProps,t===null?Fu(e):Il=t}function Nu(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=lc(n,t,t.pendingProps,t.type,void 0,Ll);break;case 11:t=lc(n,t,t.pendingProps,t.type.render,t.ref,Ll);break;case 5:xo(t);default:Pc(n,t),t=Il=oi(t,Ul),t=Tc(n,t,Ul)}e.memoizedProps=e.pendingProps,t===null?Fu(e):Il=t}function Pu(e,t,n,r){Bi=zi=null,xo(t),Ca=null,wa=0;var i=t.return;try{if(Js(e,i,t,n,Ll)){Wl=1,Us(e,di(n,e.current)),Il=null;return}}catch(t){if(i!==null)throw Il=i,t;Wl=1,Us(e,di(n,e.current)),Il=null;return}t.flags&32768?(K||r===1?e=!0:Vl||Ll&536870912?e=!1:(Bl=e=!0,(r===2||r===9||r===3||r===6)&&(r=Ja.current,r!==null&&r.tag===13&&(r.flags|=16384))),Iu(t,e)):Fu(t)}function Fu(e){var t=e;do{if(t.flags&32768){Iu(t,Bl);return}e=t.return;var n=Mc(t.alternate,t,Ul);if(n!==null){Il=n;return}if(t=t.sibling,t!==null){Il=t;return}Il=t=e}while(t!==null);Wl===0&&(Wl=5)}function Iu(e,t){do{var n=Nc(e.alternate,e);if(n!==null){n.flags&=32767,Il=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Il=e;return}Il=e=n}while(e!==null);Wl=6,Il=null}function Lu(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do Hu();while(iu!==0);if(Pl&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=Jr,Ye(e,n,o,s,c,l),e===Fl&&(Il=Fl=null,Ll=0),ou=t,au=e,su=n,cu=o,lu=a,uu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,Zu(De,function(){return Uu(),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=Pl,Pl|=4;try{$c(e,t,n)}finally{Pl=s,F.p=a,P.T=r}}iu=1,Ru(),zu(),Bu()}}function Ru(){if(iu===1){iu=0;var e=au,t=ou,n=!!(t.flags&13878);if(t.subtreeFlags&13878||n){n=P.T,P.T=null;var r=F.p;F.p=2;var i=Pl;Pl|=4;try{fl(t,e);var a=Hd,o=Tr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&wr(s.ownerDocument.documentElement,s)){if(c!==null&&Er(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 _=Cr(s,h),v=Cr(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}}up=!!Vd,Hd=Vd=null}finally{Pl=i,F.p=r,P.T=n}}e.current=t,iu=2}}function zu(){if(iu===2){iu=0;var e=au,t=ou,n=!!(t.flags&8772);if(t.subtreeFlags&8772||n){n=P.T,P.T=null;var r=F.p;F.p=2;var i=Pl;Pl|=4;try{el(e,t.alternate,t)}finally{Pl=i,F.p=r,P.T=n}}iu=3}}function Bu(){if(iu===4||iu===3){iu=0,Se();var e=au,t=ou,n=su,r=uu;t.subtreeFlags&10256||t.flags&10256?iu=5:(iu=0,ou=au=null,Vu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(ru=null),et(n),t=t.stateNode,Ne&&typeof Ne.onCommitFiberRoot==`function`)try{Ne.onCommitFiberRoot(Me,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}}su&3&&Hu(),id(e),i=e.pendingLanes,n&261930&&i&42?e===fu?du++:(du=0,fu=e):du=0,ad(0,!1)}}function Vu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ea(t)))}function Hu(){return Ru(),zu(),Bu(),Uu()}function Uu(){if(iu!==5)return!1;var e=au,t=cu;cu=0;var n=et(su),r=P.T,a=F.p;try{F.p=32>n?32:n,P.T=null,n=lu,lu=null;var o=au,s=su;if(iu=0,ou=au=null,su=0,Pl&6)throw Error(i(331));var c=Pl;if(Pl|=4,kl(o.current),xl(o,o.current,s,n),Pl=c,ad(0,!1),Ne&&typeof Ne.onPostCommitFiberRoot==`function`)try{Ne.onPostCommitFiberRoot(Me,o)}catch{}return!0}finally{F.p=a,P.T=r,Vu(e,t)}}function Wu(e,t,n){t=di(n,t),t=Gs(e.stateNode,t,2),e=Fa(e,t,2),e!==null&&(Je(e,2),id(e))}function Gu(e,t,n){if(e.tag===3)Wu(e,e,n);else for(;t!==null;){if(t.tag===3){Wu(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(ru===null||!ru.has(r))){e=di(n,e),n=Ks(2),r=Fa(t,n,2),r!==null&&(qs(n,r,t,e),Je(r,2),id(r));break}}t=t.return}}function Ku(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Nl;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)||(Hl=!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,Fl===e&&(Ll&n)===n&&(Wl===4||Wl===3&&(Ll&62914560)===Ll&&300>Ce()-$l?!(Pl&2)&&Su(e,0):ql|=n,Yl===Ll&&(Yl=0)),id(e)}function Ju(e,t){t===0&&(t=Ke()),e=Qr(e,t),e!==null&&(Je(e,t),id(e))}function Yu(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ju(e,n)}function Xu(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),Ju(e,n)}function Zu(e,t){return ye(e,t)}var Qu=null,$u=null,ed=!1,td=!1,nd=!1,rd=0;function id(e){e!==$u&&e.next===null&&($u===null?Qu=$u=e:$u=$u.next=e),td=!0,ed||(ed=!0,dd())}function ad(e,t){if(!nd&&td){nd=!0;do for(var n=!1,r=Qu;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-Fe(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,ud(r,a))}else a=Ll,a=Ue(r,r===Fl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||We(r,a)||(n=!0,ud(r,a))}r=r.next}while(n);nd=!1}}function od(){sd()}function sd(){td=ed=!1;var e=0;rd!==0&&Jd()&&(e=rd);for(var t=Ce(),n=null,r=Qu;r!==null;){var i=r.next,a=cd(r,t);a===0?(r.next=null,n===null?Qu=i:n.next=i,i===null&&($u=n)):(n=r,(e!==0||a&3)&&(td=!0)),r=i}iu!==0&&iu!==5||ad(e,!1),rd!==0&&(rd=0)}function cd(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Fe(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Ge(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Fl,n=Ll,n=Ue(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Rl===2||Rl===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&be(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||We(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&be(r),et(n)){case 2:case 8:n=Ee;break;case 32:n=De;break;case 268435456:n=ke;break;default:n=De}return r=ld.bind(null,e),n=ye(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&be(r),e.callbackPriority=2,e.callbackNode=null,2}function ld(e,t){if(iu!==0&&iu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Hu()&&e.callbackNode!==n)return null;var r=Ll;return r=Ue(e,e===Fl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(gu(e,r,t),cd(e,Ce()),e.callbackNode!=null&&e.callbackNode===n?ld.bind(null,e):null)}function ud(e,t){if(Hu())return null;gu(e,t,!0)}function dd(){Qd(function(){Pl&6?ye(Te,od):sd()})}function fd(){if(rd===0){var e=ra;e===0&&(e=ze,ze<<=1,!(ze&261888)&&(ze=256)),rd=e}return rd}function pd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:Xt(``+e)}function md(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 hd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=pd((i[at]||null).action),o=r.submitter;o&&(t=(t=o[at]||null)?pd(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(rd!==0){var e=o?md(i,o):new FormData(i);_s(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?md(i,o):new FormData(i),_s(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var gd=0;gd<Wr.length;gd++){var _d=Wr[gd];U(_d.toLowerCase(),`on`+(_d[0].toUpperCase()+_d.slice(1)))}U(Lr,`onAnimationEnd`),U(H,`onAnimationIteration`),U(Rr,`onAnimationStart`),U(`dblclick`,`onDoubleClick`),U(`focusin`,`onFocus`),U(`focusout`,`onBlur`),U(zr,`onTransitionRun`),U(Br,`onTransitionStart`),U(Vr,`onTransitionCancel`),U(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 vd=`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(` `),yd=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(vd));function bd(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 xd(e,t){var n=t[st];n===void 0&&(n=t[st]=new Set);var r=e+`__bubble`;n.has(r)||(Td(t,e,2,!1),n.add(r))}function Sd(e,t,n){var r=0;t&&(r|=4),Td(n,e,r,t)}var Cd=`_reactListening`+Math.random().toString(36).slice(2);function wd(e){if(!e[Cd]){e[Cd]=!0,vt.forEach(function(t){t!==`selectionchange`&&(yd.has(t)||Sd(t,!1,e),Sd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Cd]||(t[Cd]=!0,Sd(`selectionchange`,!1,t))}}function Td(e,t,n,r){switch(_p(t)){case 2:var i=dp;break;case 8:i=fp;break;default:i=pp}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 Ed(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=pt(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=Ur.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 Lr:case H: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(Dd(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)&&(pt(u)||u[ot]))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?pt(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:ht(l),h=u==null?c:ht(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,pt(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=kd,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&&Ad(s,c,l,d,!1),u!==null&&f!==null&&Ad(s,f,u,d,!0)}}a:{if(c=r?ht(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=cr;else if(nr(c)){if(lr)v=vr;else{v=gr;var y=hr}}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&qt(r.elementType)&&(v=cr):v=_r;if(v&&=v(e,r)){rr(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?ht(r):window,e){case`focusin`:(nr(y)||y.contentEditable===`true`)&&(Dr=y,Or=r,kr=null);break;case`focusout`:kr=Or=Dr=null;break;case`mousedown`:Ar=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Ar=!1,jr(s,n,i);break;case`selectionchange`:if(V)break;case`keydown`:case`keyup`:jr(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 Qn?Xn(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(qn&&n.locale!==`ko`&&(Qn||x!==`onCompositionStart`?x===`onCompositionEnd`&&Qn&&(b=pn()):(un=i,dn=`value`in un?un.value:un.textContent,Qn=!0)),y=Od(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?$n(e,n):er(e,n))&&(x=Od(r,`onBeforeInput`),0<x.length&&(y=new jn(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:y,listeners:x}),y.data=b)),hd(s,e,r,n,i)}bd(s,t)})}function Dd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Od(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(Dd(e,i,a)),i=on(e,t),i!=null&&r.push(Dd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function kd(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Ad(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(Dd(n,l,c))):i||(l=on(n,a),l!=null&&o.push(Dd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var jd=/\r\n?/g,Md=/\u0000|\uFFFD/g;function Nd(e){return(typeof e==`string`?e:``+e).replace(jd,`
|
|
9
|
+
`).replace(Md,``)}function Pd(e,t){return t=Nd(t),Nd(e)===t}function Fd(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`&&Fd(e,t,`name`,a.name,a,null),Fd(e,t,`formEncType`,a.formEncType,a,null),Fd(e,t,`formMethod`,a.formMethod,a,null),Fd(e,t,`formTarget`,a.formTarget,a,null)):(Fd(e,t,`encType`,a.encType,a,null),Fd(e,t,`method`,a.method,a,null),Fd(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&&xd(`scroll`,e);break;case`onScrollEnd`:r!=null&&xd(`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`:xd(`beforetoggle`,e),xd(`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 Id(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&&xd(`scroll`,e);break;case`onScrollEnd`:r!=null&&xd(`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[at]||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 Ld(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:xd(`error`,e),xd(`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:Fd(e,t,o,s,n,null)}}a&&Fd(e,t,`srcSet`,n.srcSet,n,null),r&&Fd(e,t,`src`,n.src,n,null);return;case`input`:xd(`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:Fd(e,t,r,d,n,null)}}Rt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in xd(`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:Fd(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 xd(`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:Fd(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:Fd(e,t,l,r,n,null)}return;case`dialog`:xd(`beforetoggle`,e),xd(`toggle`,e),xd(`cancel`,e),xd(`close`,e);break;case`iframe`:case`object`:xd(`load`,e);break;case`video`:case`audio`:for(r=0;r<vd.length;r++)xd(vd[r],e);break;case`image`:xd(`error`,e),xd(`load`,e);break;case`details`:xd(`toggle`,e);break;case`embed`:case`source`:case`link`:xd(`error`,e),xd(`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:Fd(e,t,u,r,n,null)}return;default:if(qt(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Id(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Fd(e,t,c,r,n,null))}function Rd(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)||Fd(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&&Fd(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)||Fd(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&&Fd(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:Fd(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&&Fd(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:Fd(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:Fd(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)&&Fd(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:Fd(e,t,u,p,r,m)}return;default:if(qt(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Id(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||Id(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Fd(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||Fd(e,t,f,p,r,m)}function zd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Bd(){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&&zd(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&&zd(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 Vd=null,Hd=null;function Ud(e){return e.nodeType===9?e:e.ownerDocument}function Wd(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 Gd(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 Kd(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 qd=null;function Jd(){var e=window.event;return e&&e.type===`popstate`?e!==qd&&(qd=e,!0):(qd=null,!1)}var Yd=typeof setTimeout==`function`?setTimeout:void 0,Xd=typeof clearTimeout==`function`?clearTimeout:void 0,Zd=typeof Promise==`function`?Promise:void 0,Qd=typeof queueMicrotask==`function`?queueMicrotask:Zd===void 0?Yd:function(e){return Zd.resolve(null).then(e).catch($d)};function $d(e){setTimeout(function(){throw e})}function ef(e){return e===`head`}function tf(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),Ip(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)gf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,gf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[dt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&gf(e.ownerDocument.body)}n=i}while(n);Ip(t)}function nf(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 rf(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`:rf(n),ft(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function af(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[dt])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=df(e.nextSibling),e===null)break}return null}function of(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=df(e.nextSibling),e===null))return null;return e}function sf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=df(e.nextSibling),e===null))return null;return e}function cf(e){return e.data===`$?`||e.data===`$~`}function lf(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function uf(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 df(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 ff=null;function pf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return df(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function mf(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 hf(e,t,n){switch(t=Ud(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 gf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);ft(e)}var _f=new Map,vf=new Set;function yf(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var bf=F.d;F.d={f:xf,r:Sf,D:Tf,C:Ef,L:Df,m:Of,X:Af,S:kf,M:jf};function xf(){var e=bf.f(),t=bu();return e||t}function Sf(e){var t=mt(e);t!==null&&t.tag===5&&t.type===`form`?ys(t):bf.r(e)}var Cf=typeof document>`u`?null:document;function wf(e,t,n){var r=Cf;if(r&&typeof t==`string`&&t){var i=It(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),vf.has(i)||(vf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Ld(t,`link`,e),_t(t),r.head.appendChild(t)))}}function Tf(e){bf.D(e),wf(`dns-prefetch`,e,null)}function Ef(e,t){bf.C(e,t),wf(`preconnect`,e,t)}function Df(e,t,n){bf.L(e,t,n);var r=Cf;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=Nf(e);break;case`script`:a=Lf(e)}_f.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),_f.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Pf(a))||t===`script`&&r.querySelector(Rf(a))||(t=r.createElement(`link`),Ld(t,`link`,e),_t(t),r.head.appendChild(t)))}}function Of(e,t){bf.m(e,t);var n=Cf;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=Lf(e)}if(!_f.has(a)&&(e=h({rel:`modulepreload`,href:e},t),_f.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Rf(a)))return}r=n.createElement(`link`),Ld(r,`link`,e),_t(r),n.head.appendChild(r)}}}function kf(e,t,n){bf.S(e,t,n);var r=Cf;if(r&&e){var i=gt(r).hoistableStyles,a=Nf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Pf(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=_f.get(a))&&Vf(e,n);var c=o=r.createElement(`link`);_t(c),Ld(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,Bf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Af(e,t){bf.X(e,t);var n=Cf;if(n&&e){var r=gt(n).hoistableScripts,i=Lf(e),a=r.get(i);a||(a=n.querySelector(Rf(i)),a||(e=h({src:e,async:!0},t),(t=_f.get(i))&&Hf(e,t),a=n.createElement(`script`),_t(a),Ld(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function jf(e,t){bf.M(e,t);var n=Cf;if(n&&e){var r=gt(n).hoistableScripts,i=Lf(e),a=r.get(i);a||(a=n.querySelector(Rf(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=_f.get(i))&&Hf(e,t),a=n.createElement(`script`),_t(a),Ld(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Mf(e,t,n,r){var a=(a=B.current)?yf(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=Nf(n.href),n=gt(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=Nf(n.href);var o=gt(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(Pf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),_f.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},_f.set(e,n),o||If(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=Lf(n),n=gt(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 Nf(e){return`href="`+It(e)+`"`}function Pf(e){return`link[rel="stylesheet"][`+e+`]`}function Ff(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function If(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}),Ld(t,`link`,n),_t(t),e.head.appendChild(t))}function Lf(e){return`[src="`+It(e)+`"]`}function Rf(e){return`script[async]`+e}function zf(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,_t(r),r;var a=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),_t(r),Ld(r,`style`,a),Bf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Nf(n.href);var o=e.querySelector(Pf(a));if(o)return t.state.loading|=4,t.instance=o,_t(o),o;r=Ff(n),(a=_f.get(a))&&Vf(r,a),o=(e.ownerDocument||e).createElement(`link`),_t(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Ld(o,`link`,r),t.state.loading|=4,Bf(o,n.precedence,e),t.instance=o;case`script`:return o=Lf(n.src),(a=e.querySelector(Rf(o)))?(t.instance=a,_t(a),a):(r=n,(a=_f.get(o))&&(r=h({},n),Hf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),_t(a),Ld(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,Bf(r,n.precedence,e));return t.instance}function Bf(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 Vf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Hf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Uf=null;function Wf(e,t,n){if(Uf===null){var r=new Map,i=Uf=new Map;i.set(n,r)}else i=Uf,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[dt]||a[it]||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 Gf(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function Kf(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 qf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Jf(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=Nf(r.href),a=t.querySelector(Pf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Zf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,_t(a);return}a=t.ownerDocument||t,r=Ff(r),(i=_f.get(i))&&Vf(r,i),a=a.createElement(`link`),_t(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Ld(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=Zf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Yf=0;function Xf(e,t){return e.stylesheets&&e.count===0&&$f(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&$f(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&Yf===0&&(Yf=62500*Bd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&$f(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>Yf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Zf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)$f(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Qf=null;function $f(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Qf=new Map,t.forEach(ep,e),Qf=null,Zf.call(e))}function ep(e,t){if(!(t.state.loading&4)){var n=Qf.get(e);if(n)var r=n.get(null);else{n=new Map,Qf.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=Zf.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 tp={$$typeof:C,Provider:null,Consumer:null,_currentValue:ne,_currentValue2:ne,_threadCount:0};function np(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=qe(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=qe(0),this.hiddenUpdates=qe(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 rp(e,t,n,r,i,a,o,s,c,l,u,d){return e=new np(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=$i(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ma(a),e}function ip(e){return e?(e=ti,e):ti}function ap(e,t,n,r,i,a){i=ip(i),r.context===null?r.context=i:r.pendingContext=i,r=Pa(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Fa(e,r,t),n!==null&&(hu(n,e,t),Ia(n,e,t))}function op(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function sp(e,t){op(e,t),(e=e.alternate)&&op(e,t)}function cp(e){if(e.tag===13||e.tag===31){var t=Qr(e,67108864);t!==null&&hu(t,e,67108864),sp(e,67108864)}}function lp(e){if(e.tag===13||e.tag===31){var t=pu();t=$e(t);var n=Qr(e,t);n!==null&&hu(n,e,t),sp(e,t)}}var up=!0;function dp(e,t,n,r){var i=P.T;P.T=null;var a=F.p;try{F.p=2,pp(e,t,n,r)}finally{F.p=a,P.T=i}}function fp(e,t,n,r){var i=P.T;P.T=null;var a=F.p;try{F.p=8,pp(e,t,n,r)}finally{F.p=a,P.T=i}}function pp(e,t,n,r){if(up){var i=mp(r);if(i===null)Ed(e,t,r,hp,n),Ep(e,r);else if(Op(i,e,t,n,r))r.stopPropagation();else if(Ep(e,r),t&4&&-1<Tp.indexOf(e)){for(;i!==null;){var a=mt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=He(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Fe(o);s.entanglements[1]|=c,o&=~c}id(a),!(Pl&6)&&(tu=Ce()+500,ad(0,!1))}}break;case 31:case 13:s=Qr(a,2),s!==null&&hu(s,a,2),bu(),sp(a,2)}if(a=mp(r),a===null&&Ed(e,t,r,hp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Ed(e,t,r,null,n)}}function mp(e){return e=$t(e),gp(e)}var hp=null;function gp(e){if(hp=null,e=pt(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 hp=e,null}function _p(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(we()){case Te:return 2;case Ee:return 8;case De:case Oe:return 32;case ke:return 268435456;default:return 32}default:return 32}}var vp=!1,yp=null,bp=null,xp=null,Sp=new Map,Cp=new Map,wp=[],Tp=`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 Ep(e,t){switch(e){case`focusin`:case`focusout`:yp=null;break;case`dragenter`:case`dragleave`:bp=null;break;case`mouseover`:case`mouseout`:xp=null;break;case`pointerover`:case`pointerout`:Sp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:Cp.delete(t.pointerId)}}function Dp(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=mt(t),t!==null&&cp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Op(e,t,n,r,i){switch(t){case`focusin`:return yp=Dp(yp,e,t,n,r,i),!0;case`dragenter`:return bp=Dp(bp,e,t,n,r,i),!0;case`mouseover`:return xp=Dp(xp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Sp.set(a,Dp(Sp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,Cp.set(a,Dp(Cp.get(a)||null,e,t,n,r,i)),!0}return!1}function kp(e){var t=pt(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,nt(e.priority,function(){lp(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,nt(e.priority,function(){lp(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 Ap(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=mp(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=mt(n),t!==null&&cp(t),e.blockedOn=n,!1;t.shift()}return!0}function jp(e,t,n){Ap(e)&&n.delete(t)}function Mp(){vp=!1,yp!==null&&Ap(yp)&&(yp=null),bp!==null&&Ap(bp)&&(bp=null),xp!==null&&Ap(xp)&&(xp=null),Sp.forEach(jp),Cp.forEach(jp)}function Np(e,n){e.blockedOn===n&&(e.blockedOn=null,vp||(vp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Mp)))}var Pp=null;function Fp(e){Pp!==e&&(Pp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Pp===e&&(Pp=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(gp(r||n)===null)continue;break}var a=mt(n);a!==null&&(e.splice(t,3),t-=3,_s(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Ip(e){function t(t){return Np(t,e)}yp!==null&&Np(yp,e),bp!==null&&Np(bp,e),xp!==null&&Np(xp,e),Sp.forEach(t),Cp.forEach(t);for(var n=0;n<wp.length;n++){var r=wp[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<wp.length&&(n=wp[0],n.blockedOn===null);)kp(n),n.blockedOn===null&&wp.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[at]||null;if(typeof a==`function`)o||Fp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[at]||null)s=o.formAction;else if(gp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Fp(n)}}}function Lp(){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 Rp(e){this._internalRoot=e}zp.prototype.render=Rp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;ap(n,pu(),e,t,null,null)},zp.prototype.unmount=Rp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;ap(e.current,2,null,e,null,null),bu(),t[ot]=null}};function zp(e){this._internalRoot=e}zp.prototype.unstable_scheduleHydration=function(e){if(e){var t=tt();e={blockedOn:null,target:e,priority:t};for(var n=0;n<wp.length&&t!==0&&t<wp[n].priority;n++);wp.splice(n,0,e),n===0&&kp(e)}};var Bp=n.version;if(Bp!==`19.2.8`)throw Error(i(527,Bp,`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=d(t),e=e===null?null:p(e),e=e===null?null:e.stateNode,e};var Vp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:P,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Hp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Hp.isDisabled&&Hp.supportsFiber)try{Me=Hp.inject(Vp),Ne=Hp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=Bs,s=Vs,c=Hs;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=rp(e,1,!1,null,null,n,r,null,o,s,c,Lp),e[ot]=t.current,wd(e),new Rp(t)}})),g=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=h()})),_=(...e)=>e.filter((e,t,n)=>!!e&&e.trim()!==``&&n.indexOf(e)===t).join(` `).trim(),v=e=>e.replace(/([a-z0-9])([A-Z])/g,`$1-$2`).toLowerCase(),y=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,n)=>n?n.toUpperCase():t.toLowerCase()),b=e=>{let t=y(e);return t.charAt(0).toUpperCase()+t.slice(1)},x={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`},S=e=>{for(let t in e)if(t.startsWith(`aria-`)||t===`role`||t===`title`)return!0;return!1},C=c(u(),1),w=(0,C.createContext)({}),T=()=>(0,C.useContext)(w),E=(0,C.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=``}=T()??{},m=r??d?Number(n??u)*24/Number(t??l):n??u;return(0,C.createElement)(`svg`,{ref:c,...x,width:t??l??x.width,height:t??l??x.height,stroke:e??f,strokeWidth:m,className:_(`lucide`,p,i),...!a&&!S(s)&&{"aria-hidden":`true`},...s},[...o.map(([e,t])=>(0,C.createElement)(e,t)),...Array.isArray(a)?a:[a]])}),D=(e,t)=>{let n=(0,C.forwardRef)(({className:n,...r},i)=>(0,C.createElement)(E,{ref:i,iconNode:t,className:_(`lucide-${v(b(e))}`,`lucide-${e}`,n),...r}));return n.displayName=b(e),n},O=D(`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`}]]),ee=D(`arrow-up`,[[`path`,{d:`m5 12 7-7 7 7`,key:`hav0vg`}],[`path`,{d:`M12 19V5`,key:`x0mq9r`}]]),k=D(`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`}]]),A=D(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),j=D(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),M=D(`chevron-left`,[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]),te=D(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),N=D(`columns-3`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}],[`path`,{d:`M15 3v18`,key:`14nvp0`}]]),P=D(`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`}]]),F=D(`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`}]]),ne=D(`eye-off`,[[`path`,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,key:`ct8e1f`}],[`path`,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,key:`151rxh`}],[`path`,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,key:`13bj9a`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),re=D(`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`}]]),ie=D(`grip-vertical`,[[`circle`,{cx:`9`,cy:`12`,r:`1`,key:`1vctgf`}],[`circle`,{cx:`9`,cy:`5`,r:`1`,key:`hp0tcf`}],[`circle`,{cx:`9`,cy:`19`,r:`1`,key:`fkjjf6`}],[`circle`,{cx:`15`,cy:`12`,r:`1`,key:`1tmaij`}],[`circle`,{cx:`15`,cy:`5`,r:`1`,key:`19l28e`}],[`circle`,{cx:`15`,cy:`19`,r:`1`,key:`f4zoj3`}]]),I=D(`list-filter`,[[`path`,{d:`M2 5h20`,key:`1fs1ex`}],[`path`,{d:`M6 12h12`,key:`8npq4p`}],[`path`,{d:`M9 19h6`,key:`456am0`}]]),L=D(`loader-circle`,[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]]),R=D(`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`}]]),ae=D(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),z=D(`search`,[[`path`,{d:`m21 21-4.34-4.34`,key:`14j7rj`}],[`circle`,{cx:`11`,cy:`11`,r:`8`,key:`4ej97u`}]]),B=D(`shield-alert`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}],[`path`,{d:`M12 8v4`,key:`1got3b`}],[`path`,{d:`M12 16h.01`,key:`1drbdi`}]]),oe=D(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),se=D(`square`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}]]),ce=D(`star`,[[`path`,{d:`M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z`,key:`r04s7s`}]]),le=D(`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`}]]),ue=D(`wrench`,[[`path`,{d:`M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z`,key:`1ngwbx`}]]),de=D(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),fe=g(),pe=c(m(),1);function me(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 he=e=>{switch(e){case`success`:return ve;case`info`:return be;case`warning`:return ye;case`error`:return xe;default:return null}},ge=Array(12).fill(0),_e=({visible:e,className:t})=>C.createElement(`div`,{className:[`sonner-loading-wrapper`,t].filter(Boolean).join(` `),"data-visible":e},C.createElement(`div`,{className:`sonner-spinner`},ge.map((e,t)=>C.createElement(`div`,{className:`sonner-loading-bar`,key:`spinner-bar-${t}`})))),ve=C.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},C.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`})),ye=C.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 24 24`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},C.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`})),be=C.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},C.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`})),xe=C.createElement(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 20 20`,fill:`currentColor`,height:`20`,width:`20`,"aria-hidden":`true`},C.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`})),Se=C.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`},C.createElement(`line`,{x1:`18`,y1:`6`,x2:`6`,y2:`18`}),C.createElement(`line`,{x1:`6`,y1:`6`,x2:`18`,y2:`18`})),Ce=()=>{let[e,t]=C.useState(document.hidden);return C.useEffect(()=>{let e=()=>{t(document.hidden)};return document.addEventListener(`visibilitychange`,e),()=>document.removeEventListener(`visibilitychange`,e)},[]),e},we=1,Te=100,Ee=e=>typeof e?.id==`number`||e?.id?.length>0?e.id:we++,De=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-Te;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=Ee(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],C.isValidElement(e))i=!1,this.create({id:n,type:`default`,message:e});else if(ke(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`&&!C.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`&&!C.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`&&!C.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`&&!C.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=Ee(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}},Oe=(e,t)=>De.message(e,t),ke=e=>e&&typeof e==`object`&&`ok`in e&&typeof e.ok==`boolean`&&`status`in e&&typeof e.status==`number`,Ae=Object.assign(Oe,{success:De.success,info:De.info,warning:De.warning,error:De.error,custom:De.custom,message:De.message,promise:De.promise,dismiss:De.dismiss,loading:De.loading},{getHistory:()=>De.toasts,getToasts:()=>De.getActiveToasts()});me(`[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 je(e){return e.label!==void 0}var Me=3,Ne=`24px`,Pe=`16px`,Fe=4e3,Ie=356,Le=14,Re=45,ze=200;function Be(...e){return e.filter(Boolean).join(` `)}function Ve(e){let[t,n]=e.split(`-`),r=[];return t&&r.push(t),n&&r.push(n),r}var He=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:w,icons:T,closeButtonAriaLabel:E=`Close toast`}=e,[D,O]=C.useState(null),[ee,k]=C.useState(null),[A,j]=C.useState(!1),[M,te]=C.useState(!1),[N,P]=C.useState(!1),[F,ne]=C.useState(!1),[re,ie]=C.useState(!1),[I,L]=C.useState(0),[R,ae]=C.useState(0),z=C.useRef(n.duration||y||Fe),B=C.useRef(null),oe=C.useRef(null),se=c===0,ce=c+1<=o,le=n.type,ue=le??`default`,de=n.dismissible!==!1,fe=n.className||``,pe=n.descriptionClassName||``,me=C.useMemo(()=>s.findIndex(e=>e.toastId===n.id)||0,[s,n.id]),ge=C.useMemo(()=>n.closeButton??p,[n.closeButton,p]),ve=C.useMemo(()=>n.duration||y||Fe,[n.duration,y]),ye=C.useRef(0),be=C.useRef(0),xe=C.useRef(0),we=C.useRef(null),[Te,Ee]=b.split(`-`),De=C.useMemo(()=>s.reduce((e,t,n)=>n>=me?e:e+t.height,0),[s,me]),Oe=Ce(),ke=C.useMemo(()=>e.swipeDirections??Ve(b),[e.swipeDirections,b]),Ae=n.invert||t,Me=le===`loading`;be.current=C.useMemo(()=>me*x+De,[me,De]),C.useEffect(()=>{z.current=ve},[ve]),C.useEffect(()=>{j(!0)},[]),C.useEffect(()=>{let e=oe.current;if(e){let t=e.getBoundingClientRect().height;return ae(t),a(e=>[{toastId:n.id,height:t,position:n.position},...e]),()=>a(e=>e.filter(e=>e.toastId!==n.id))}},[a,n.id]),C.useLayoutEffect(()=>{if(!A)return;let e=oe.current,t=e.style.height;e.style.height=`auto`;let r=e.getBoundingClientRect().height;e.style.height=t,ae(r),a(e=>e.find(e=>e.toastId===n.id)?e.map(e=>e.toastId===n.id?{...e,height:r}:e):[{toastId:n.id,height:r,position:n.position},...e])},[A,n.title,n.description,a,n.id,n.jsx,n.action,n.cancel]);let Ne=C.useCallback(()=>{te(!0),L(be.current),a(e=>e.filter(e=>e.toastId!==n.id)),setTimeout(()=>{d(n)},ze)},[n,d,a,be]);C.useEffect(()=>{if(n.promise&&le===`loading`||n.duration===1/0||n.type===`loading`)return;let e;return u||i||Oe?(()=>{if(xe.current<ye.current){let e=new Date().getTime()-ye.current;z.current-=e}xe.current=new Date().getTime()})():z.current!==1/0&&(ye.current=new Date().getTime(),e=setTimeout(()=>{n.onAutoClose==null||n.onAutoClose.call(n,n),Ne()},z.current)),()=>clearTimeout(e)},[u,i,n,le,Oe,Ne]),C.useEffect(()=>{n.delete&&(Ne(),n.onDismiss==null||n.onDismiss.call(n,n))},[Ne,n.delete]);function Pe(){return T?.loading?C.createElement(`div`,{className:Be(w?.loader,n?.classNames?.loader,`sonner-loader`),"data-visible":le===`loading`},T.loading):C.createElement(_e,{className:Be(w?.loader,n?.classNames?.loader),visible:le===`loading`})}let Ie=n.icon||T?.[le]||he(le);return C.createElement(`li`,{tabIndex:0,ref:oe,className:Be(_,fe,w?.toast,n?.classNames?.toast,w?.[ue],n?.classNames?.[ue]),"data-sonner-toast":``,"data-rich-colors":n.richColors??f,"data-styled":!(n.jsx||n.unstyled||r),"data-mounted":A,"data-promise":!!n.promise,"data-swiped":re,"data-removed":M,"data-visible":ce,"data-y-position":Te,"data-x-position":Ee,"data-index":c,"data-front":se,"data-swiping":N,"data-dismissible":de,"data-type":le,"data-invert":Ae,"data-swipe-out":F,"data-swipe-direction":ee,"data-expanded":!!(u||S&&A),"data-testid":n.testId,style:{"--index":c,"--toasts-before":c,"--z-index":l.length-c,"--offset":`${M?I:be.current}px`,"--initial-height":S?`auto`:`${R}px`,...m,...n.style},onDragEnd:()=>{P(!1),O(null),we.current=null},onPointerDown:e=>{e.button!==2&&!Me&&de&&(B.current=new Date,L(be.current),e.target.setPointerCapture(e.pointerId),e.target.tagName!==`BUTTON`&&(P(!0),we.current={x:e.clientX,y:e.clientY}))},onPointerUp:()=>{if(F||!de)return;we.current=null;let e=Number(oe.current?.style.getPropertyValue(`--swipe-amount-x`).replace(`px`,``)||0),t=Number(oe.current?.style.getPropertyValue(`--swipe-amount-y`).replace(`px`,``)||0),r=new Date().getTime()-B.current?.getTime(),i=D===`x`?e:t,a=Math.abs(i)/r;if((D===`x`?ke.includes(e>0?`right`:`left`):ke.includes(t>0?`bottom`:`top`))&&(Math.abs(i)>=Re||a>.11)){L(be.current),n.onDismiss==null||n.onDismiss.call(n,n),k(D===`x`?e>0?`right`:`left`:t>0?`down`:`up`),Ne(),ne(!0);return}var o,s;(o=oe.current)==null||o.style.setProperty(`--swipe-amount-x`,`0px`),(s=oe.current)==null||s.style.setProperty(`--swipe-amount-y`,`0px`),ie(!1),P(!1),O(null)},onPointerMove:e=>{var t,n;if(!we.current||!de||window.getSelection()?.toString().length>0)return;let r=e.clientY-we.current.y,i=e.clientX-we.current.x;!D&&(Math.abs(i)>1||Math.abs(r)>1)&&O(Math.abs(i)>Math.abs(r)?`x`:`y`);let a={x:0,y:0},o=e=>1/(1.5+Math.abs(e)/20);if(D===`y`){if(ke.includes(`top`)||ke.includes(`bottom`)){if(ke.includes(`top`)&&r<0||ke.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(D===`x`&&(ke.includes(`left`)||ke.includes(`right`))){if(ke.includes(`left`)&&i<0||ke.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)&&ie(!0),(t=oe.current)==null||t.style.setProperty(`--swipe-amount-x`,`${a.x}px`),(n=oe.current)==null||n.style.setProperty(`--swipe-amount-y`,`${a.y}px`)}},ge&&!n.jsx&&le!==`loading`?C.createElement(`button`,{"aria-label":E,"data-disabled":Me,"data-close-button":!0,onClick:Me||!de?()=>{}:()=>{Ne(),n.onDismiss==null||n.onDismiss.call(n,n)},className:Be(w?.closeButton,n?.classNames?.closeButton)},T?.close??Se):null,(le||n.icon||n.promise)&&n.icon!==null&&(T?.[le]!==null||n.icon)?C.createElement(`div`,{"data-icon":``,className:Be(w?.icon,n?.classNames?.icon)},le===`loading`?n.icon||Pe():n.promise?Pe():null,le===`loading`?null:Ie):null,C.createElement(`div`,{"data-content":``,className:Be(w?.content,n?.classNames?.content)},C.createElement(`div`,{"data-title":``,className:Be(w?.title,n?.classNames?.title)},n.jsx?n.jsx:typeof n.title==`function`?n.title():n.title),n.description?C.createElement(`div`,{"data-description":``,className:Be(v,pe,w?.description,n?.classNames?.description)},typeof n.description==`function`?n.description():n.description):null),C.isValidElement(n.cancel)?n.cancel:n.cancel&&je(n.cancel)?C.createElement(`button`,{"data-button":!0,"data-cancel":!0,style:n.cancelButtonStyle||h,onClick:e=>{je(n.cancel)&&de&&(n.cancel.onClick==null||n.cancel.onClick.call(n.cancel,e),Ne())},className:Be(w?.cancelButton,n?.classNames?.cancelButton)},n.cancel.label):null,C.isValidElement(n.action)?n.action:n.action&&je(n.action)?C.createElement(`button`,{"data-button":!0,"data-action":!0,style:n.actionButtonStyle||g,onClick:e=>{je(n.action)&&(n.action.onClick==null||n.action.onClick.call(n.action,e),!e.defaultPrevented&&Ne())},className:Be(w?.actionButton,n?.classNames?.actionButton)},n.action.label):null)};function Ue(){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 We(e,t){let n={};return[e,t].forEach((e,t)=>{let r=t===1,i=r?`--mobile-offset`:`--offset`,a=r?Pe:Ne;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 Ge=C.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=Me,toastOptions:g,dir:_=Ue(),gap:v=Le,icons:y,customAriaLabel:b,containerAriaLabel:x=`Notifications`}=e,[S,w]=C.useState([]),T=C.useMemo(()=>n?S.filter(e=>e.toasterId===n):S.filter(e=>!e.toasterId),[S,n]),E=C.useMemo(()=>Array.from(new Set([i].concat(T.filter(e=>e.position).map(e=>e.position)))),[T,i]),[D,O]=C.useState([]),[ee,k]=C.useState(!1),[A,j]=C.useState(!1),[M,te]=C.useState(d===`system`?typeof window<`u`&&window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`:d),N=C.useRef(null),P=a.join(`+`).replace(/Key/g,``).replace(/Digit/g,``),F=C.useRef(null),ne=C.useRef(!1),re=C.useCallback(e=>{w(t=>(t.find(t=>t.id===e.id)?.delete||De.dismiss(e.id),t.filter(({id:t})=>t!==e.id)))},[]);return C.useEffect(()=>De.subscribe(e=>{if(e.dismiss){requestAnimationFrame(()=>{w(t=>t.map(t=>t.id===e.id?{...t,delete:!0}:t))});return}setTimeout(()=>{pe.flushSync(()=>{w(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)]})})})}),[]),C.useEffect(()=>{if(d!==`system`){te(d);return}if(d===`system`&&(window.matchMedia&&window.matchMedia(`(prefers-color-scheme: dark)`).matches?te(`dark`):te(`light`)),typeof window>`u`)return;let e=window.matchMedia(`(prefers-color-scheme: dark)`);try{e.addEventListener(`change`,({matches:e})=>{te(e?`dark`:`light`)})}catch{e.addListener(({matches:e})=>{try{te(e?`dark`:`light`)}catch(e){console.error(e)}})}},[d]),C.useEffect(()=>{S.length<=1&&k(!1)},[S]),C.useEffect(()=>{let e=e=>{if(a.length>0&&a.every(t=>e[t]||e.code===t)){var t;k(!0),(t=N.current)==null||t.focus()}e.code===`Escape`&&(document.activeElement===N.current||N.current?.contains(document.activeElement))&&k(!1)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[a]),C.useEffect(()=>{if(N.current)return()=>{F.current&&(F.current.focus({preventScroll:!0}),F.current=null,ne.current=!1)}},[N.current]),C.createElement(`section`,{ref:t,"aria-label":b??`${x} ${P}`,tabIndex:-1,"aria-live":`polite`,"aria-relevant":`additions text`,"aria-atomic":`false`,suppressHydrationWarning:!0,"data-react-aria-top-layer":!0},E.map((t,n)=>{let[i,a]=t.split(`-`);return T.length?C.createElement(`ol`,{key:t,dir:_===`auto`?Ue():_,tabIndex:-1,ref:N,className:c,"data-sonner-toaster":!0,"data-sonner-theme":M,"data-y-position":i,"data-x-position":a,style:{"--front-toast-height":`${D[0]?.height||0}px`,"--width":`${Ie}px`,"--gap":`${v}px`,...m,...We(l,u)},onBlur:e=>{ne.current&&!e.currentTarget.contains(e.relatedTarget)&&(ne.current=!1,F.current&&=(F.current.focus({preventScroll:!0}),null))},onFocus:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||ne.current||(ne.current=!0,F.current=e.relatedTarget)},onMouseEnter:()=>k(!0),onMouseMove:()=>k(!0),onMouseLeave:()=>{A||k(!1)},onDragEnd:()=>k(!1),onPointerDown:e=>{e.target instanceof HTMLElement&&e.target.dataset.dismissible===`false`||j(!0)},onPointerUp:()=>j(!1)},T.filter(e=>!e.position&&n===0||e.position===t).map((n,i)=>C.createElement(He,{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:A,position:t,style:g?.style,unstyled:g?.unstyled,classNames:g?.classNames,cancelButtonStyle:g?.cancelButtonStyle,actionButtonStyle:g?.actionButtonStyle,closeButtonAriaLabel:g?.closeButtonAriaLabel,removeToast:re,toasts:T.filter(e=>e.position==n.position),heights:D.filter(e=>e.position==n.position),setHeights:O,expandByDefault:o,gap:v,expanded:ee,swipeDirections:e.swipeDirections}))):null}))});function Ke(e){if(typeof e==`string`&&e.trim()){let t=e.trim(),n=/^(\d{4})-(\d{2})-(\d{2})/.exec(t);if(n)return`${n[1]}-${n[2]}-${n[3]}`;let r=Date.parse(t);if(Number.isNaN(r))return;let i=new Date(r);return`${i.getFullYear()}-${String(i.getMonth()+1).padStart(2,`0`)}-${String(i.getDate()).padStart(2,`0`)}`}if(e&&typeof e==`object`){let t=e;return Ke(t.value)??Ke(t.date)}}function qe(e,t=Date.now()){if(typeof e!=`string`||!e)return;let n=/^(\d{4})-(\d{2})-(\d{2})/.exec(e),r=n?Date.UTC(Number(n[1]),Number(n[2])-1,Number(n[3])):Date.parse(e);if(Number.isNaN(r))return;let i=new Date(t),a=Date.UTC(i.getUTCFullYear(),i.getUTCMonth(),i.getUTCDate()),o=n?r:Date.UTC(new Date(r).getUTCFullYear(),new Date(r).getUTCMonth(),new Date(r).getUTCDate());return`${Math.max(0,Math.round((a-o)/864e5))}d`}function Je(e,t=Date.now()){let n=Ke(e);if(!n)return;let r=/^(\d{4})-(\d{2})-(\d{2})$/.exec(n);if(!r)return;let i=Date.UTC(Number(r[1]),Number(r[2])-1,Number(r[3])),a=new Date(t),o=Date.UTC(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate()),s=Math.round((i-o)/864e5),c=Math.abs(s);return c<7?`${c}d`:c<60?`${Math.max(1,Math.floor(c/7))}w`:`${Math.max(1,Math.round(c/30))}m`}function Ye(e){let t=[],n=new Map;for(let r of e){let e=r.status??`To Do`,i=n.get(e);i||(i={id:e,title:e,cards:[]},n.set(e,i),t.push(i)),i.cards.push({key:r.key,summary:r.summary,type:`Epic`,...r.priority?{priority:r.priority}:{},...r.assignee?{assignee:r.assignee}:{},...r.dueDate?{dueDate:r.dueDate}:{},...r.targetEnd?{targetEnd:r.targetEnd}:{},...r.labels?{labels:r.labels}:{},...r.created?{created:r.created}:{}})}return t}function Xe(e){let t=[],n=/"([^"]*)"|'([^']*)'|(\S+)/g,r;for(;r=n.exec(e);)t.push(r[1]??r[2]??r[3]);return t}function Ze(e,t,n){let r=e[t].slice(n.length);return r?[r,t]:[e[t+1]??``,t+1]}function Qe(e){let t=Xe(e.trim()||``),n=``,r=``,i=``,a=``,o=``,s=[],c=[];for(let e=0;e<t.length;e++){let l=t[e];if(l!==`--raw`){if(l.startsWith(`-a`)){[n,e]=Ze(t,e,`-a`);continue}if(l.startsWith(`-P`)){[r,e]=Ze(t,e,`-P`);continue}if(l.startsWith(`-t`)){[i,e]=Ze(t,e,`-t`);continue}if(l.startsWith(`-s`)){let[n,r]=Ze(t,e,`-s`);e=r,n.startsWith(`~`)?c.push(n.slice(1)):s.push(n);continue}if(l===`--projects`){[o,e]=Ze(t,e,`--projects`);continue}if(l===`-q`||l===`--jql`){a=t[++e]??``;continue}l.startsWith(`-q`)&&(a=l.slice(2))}}let l=o.split(`,`).map(e=>e.trim().toUpperCase()).filter(Boolean);if(a)return{jql:a,projects:l};let u=l.length?`project in (${l.map(e=>`"${e}"`).join(`, `)})`:``,d=[];u&&d.push(u),n&&d.push(`assignee="${n}"`),i&&d.push(`type="${i}"`),r&&d.push(`parent="${r}"`);for(let e of s)d.push(`status="${e}"`);for(let e of c)d.push(`status!="${e}"`);return{jql:d.join(` AND `),projects:l}}function $e(e,t){return e.epic===t}function et(e){return e.trim().toLowerCase()}function tt(e){return[e.key,e.summary,e.assignee,e.priority,e.epic,...e.labels??[]].filter(e=>!!e).join(`
|
|
10
|
+
`).toLowerCase()}function nt(e,t){let n=et(t);return!n||tt(e).includes(n)}function rt(e,t){let n=et(t);return!n||`${e.key}\n${e.summary}\n${(e.labels??[]).join(`
|
|
11
|
+
`)}`.toLowerCase().includes(n)}function it(e){let t=(e??``).trim().toLowerCase();if(!t)return 1e3;let n=/^p(\d+)$/.exec(t);return n?Number(n[1]):{highest:1,critical:1,blocker:1,high:2,h:2,medium:3,med:3,m:3,normal:3,low:4,l:4,lowest:5,trivial:5}[t]??100}function at(e=[]){return new Map(e.map(e=>[e.key,e]))}function ot(e,t){return(e.epic?t.get(e.epic)?.assignee:void 0)??`Unassigned`}function st(e,t,n){return t===`assignee`?[e.assignee??`Unassigned`]:t===`epicAssignee`?[ot(e,n)]:t===`priority`?e.priority?[e.priority]:[]:t===`labels`?e.labels??[]:[]}function ct(e){return!!(e&&Object.values(e).some(e=>e.length>0))}function lt(e,t,n){if(!ct(t))return!0;let r=at(n);return Object.entries(t).every(([t,n])=>!n.length||st(e,t,r).some(e=>n.includes(e)))}function ut(e,t){return[...new Set(e)].sort(t)}function dt(e,t,n,r){if(n.length)return{key:e,label:t,group:`Assignee`,values:[...ut(n,(e,t)=>e.localeCompare(t)),...r?[`Unassigned`]:[]]}}function ft(e,t=[]){let n=[],r=[...e.map(e=>e.priority),...t.map(e=>e.priority)].filter(e=>!!e);r.length&&n.push({key:`priority`,label:`Priority`,group:`Priority`,values:ut(r,(e,t)=>it(e)-it(t)||e.localeCompare(t))});let i=at(t),a=dt(`epicAssignee`,`Epic`,e.map(e=>e.epic?i.get(e.epic)?.assignee:void 0).filter(e=>!!e),e.some(e=>!i.get(e.epic??``)?.assignee));a&&n.push(a);let o=dt(`assignee`,`Stories`,[...e.map(e=>e.assignee),...t.map(e=>e.assignee)].filter(e=>!!e),e.some(e=>!e.assignee)||t.some(e=>!e.assignee));o&&n.push(o);let s=[...e.flatMap(e=>e.labels??[]),...t.flatMap(e=>e.labels??[])];return s.length&&n.push({key:`labels`,label:`Labels`,group:`Labels`,values:ut(s,(e,t)=>e.localeCompare(t))}),n}function pt(e,t,n,r,i){return t&&!$e(e,t)?!0:!nt(e,n)||!lt(e,r,i)}function mt(e){return e?Date.parse(e):NaN}function ht(e,t){let n=Number.isNaN(e),r=Number.isNaN(t);return n&&r?0:n?1:r?-1:e-t}function gt(e,t){let n=it(e.priority)-it(t.priority);return n===0?e.key.localeCompare(t.key):n}function _t(e,t){return Array.isArray(e)&&e.length>0&&!(typeof e[0]==`object`&&`title`in e[0])?vt(e,t):e.map(({title:e,cards:n})=>({title:e,cards:vt(n,t)}))}function vt(e,t){return!t||t===`payload`?e:[...e].sort((e,n)=>{let r=0;return t===`priority`?r=gt(e,n):t===`age`?r=ht(mt(e.created),mt(n.created)):t===`due`?r=ht(mt(e.dueDate),mt(n.dueDate)):t===`key`&&(r=e.key.localeCompare(n.key)),r===0?e.key.localeCompare(n.key):r})}function yt(e,t,n){if(!et(n)||!t)return e;let r=new Set(Object.values(e).flatMap(e=>e.map(e=>e.key))),i=Object.fromEntries(Object.entries(e).map(([e,t])=>[e,[...t]]));for(let[e,a]of Object.entries(t))for(let t of a){if(r.has(t.key)||!nt(t,n))continue;r.add(t.key);let a=i[e]??[];a.push(t),i[e]=a}return i}function bt(e,t,n=``,r){let i=new Set(r?.hide??[]),a=r?.filter,o=t.filter(e=>nt(e,n)&&Ct(e,a)),s=o.map(e=>({key:e.key,summary:e.summary,priority:e.priority,assignee:e.assignee,dueDate:e.dueDate,targetEnd:e.targetEnd,labels:e.labels,type:`Epic`,created:e.created})),c=Object.values(e).flat().filter(e=>!o.some(t=>t.key===e.key)&&nt(e,n)&<(e,a,t)),l=[...s,...c],u=new Map;for(let t of Object.keys(e))u.set(t,[]);for(let n of l){let r=n.type===`Epic`?t.find(e=>e.key===n.key)?.status??`To Do`:Object.entries(e).find(([,e])=>e.some(e=>e.key===n.key))?.[0]??`To Do`,i=u.get(r)??[];i.push(n),u.set(r,i)}let d=_t([...u.entries()].filter(([,e])=>e.length>0).map(([e,t])=>({title:e,cards:t})),r?.sort);return Object.fromEntries(d.filter(({title:e})=>!i.has(e)).map(({title:e,cards:t})=>[e,t]))}function xt(e,t,n=``,r){let i=new Set(r?.hide??[]),a=Object.fromEntries(Object.entries(e).filter(([e])=>!i.has(e)).map(([e,i])=>[e,_t(i.filter(e=>!pt(e,t,n,r?.filter,r?.epics)),r?.sort)]));return!et(n)&&!ct(r?.filter)?a:Object.fromEntries(Object.entries(a).filter(([,e])=>e.length>0))}function St(e,t){return t===`assignee`||t===`epicAssignee`?[e.assignee??`Unassigned`]:t===`priority`?e.priority?[e.priority]:[]:t===`labels`?e.labels??[]:[]}function Ct(e,t){return!ct(t)||Object.entries(t).every(([t,n])=>!n.length||St(e,t).some(e=>n.includes(e)))}function wt(e,t,n,r,i){return t.filter(t=>t.epic===e.key&&nt(t,n)&<(t,r,i))}function Tt(e,t,n,r,i){let a=t.filter(t=>t.epic===e.key);return!et(n)||rt(e,n)||a.some(e=>nt(e,n))?!ct(r)||a.length===0||Ct(e,r)||wt(e,t,n,r,i).length>0:!1}function Et(e,t,n=``,r,i){return wt({key:t,summary:``},e,n,r,i).length}function Dt(e,t,n,r){return!et(n)&&!ct(r)?e:e.filter(i=>Tt(i,t,n,r,e))}function Ot(e){let t=new Map,n=[],r=[];for(let i of e){let e=i.status?.trim()??``;if(!e){r.push(i);continue}let a=t.get(e);if(!a){t.set(e,[i]),n.push(e);continue}a.push(i)}return[...n.map(e=>({status:e,epics:t.get(e)??[]})),...r.length?[{status:``,epics:r}]:[]]}function kt(e){let t=new Map;for(let[n,r]of Object.entries(e))for(let e of r)t.set(e.key,n);return Object.fromEntries(Object.entries(e).map(([e,n])=>{let r=new Set;return[e,n.filter(n=>t.get(n.key)!==e||r.has(n.key)?!1:(r.add(n.key),!0))]}))}function At(e,t){if(!t||t.length===0)return e;let n=new Set(Object.keys(e)),r=[...t.filter(e=>n.has(e)),...Object.keys(e).filter(e=>!t.includes(e))];return Object.fromEntries(r.map(t=>[t,e[t]??[]]))}function jt(e,t,n,r=``,i){let a=i?.hide??[],o=kt(e);if(!n&&!et(r)&&!ct(i?.filter)&&a.length===0)return o;let s=new Set(Object.values(o).flatMap(e=>e.map(e=>e.key))),c=Object.fromEntries(Object.entries(t).map(([e,t])=>[e,(a.includes(e)?t:t.filter(e=>pt(e,n,r,i?.filter,i?.epics))).filter(e=>!s.has(e.key))])),l=[...Object.keys(o),...Object.keys(c).filter(e=>!(e in o))];return Object.fromEntries(l.map(e=>[e,[...c[e]??[],...o[e]??[]]]))}function Mt(e,t,n,r=``,i){return jt(e,t,n,r,i)}function Nt(e,t,n){let r=new Set(Object.values(t).flat().map(e=>e.key)),i=new Set([...Object.keys(e),...Object.keys(t)]);return Object.fromEntries([...i].map(i=>{let a=e[i]??[],o=t[i]??[],s=new Set(a.map(e=>e.key)),c=a.map(e=>r.has(e.key)?{...e,epic:e.epic??n}:e),l=o.filter(e=>!s.has(e.key)).map(e=>({...e,epic:e.epic??n}));return[i,[...c,...l]]}))}function Pt(e,t){return t.find(t=>t.name.toLowerCase()===e.trim().toLowerCase())}function Ft(e,t,n=``,r=[],i){let a=new Set(t.folders.flatMap(e=>e.keys)),o=new Map(e.map(e=>[e.key,e]));return{unfiled:t.keys.map(e=>o.get(e)).filter(t=>!!t&&!a.has(t.key)&&Tt(t,r,n,i,e)).sort(gt),folders:[...t.folders].sort((e,t)=>e.name.localeCompare(t.name)).map(t=>({name:t.name,epics:t.keys.map(e=>o.get(e)).filter(t=>!!t&&Tt(t,r,n,i,e)).sort(gt)})).filter(e=>!et(n)||rt({key:``,summary:e.name},n)||e.epics.length>0)}}function It(e,t){return e.keys.includes(t)?{keys:e.keys.filter(e=>e!==t),folders:e.folders.map(e=>({...e,keys:e.keys.filter(e=>e!==t)}))}:{...e,keys:[...e.keys,t]}}function Lt(e,t){let n=t.trim();return!n||Pt(n,e.folders)?{ok:!1}:{ok:!0,state:{...e,folders:[...e.folders,{name:n,keys:[]}]}}}function Rt(e,t,n){let r=n.trim(),i=Pt(t,e.folders);if(!r||!i)return{ok:!1};let a=Pt(r,e.folders);return a&&a!==i||a===i?{ok:!1}:{ok:!0,state:{...e,folders:e.folders.map(e=>e===i?{...e,name:r}:e)}}}function zt(e,t){return{...e,folders:e.folders.filter(e=>e.name.toLowerCase()!==t.trim().toLowerCase())}}function Bt(e,t,n){let r=e.keys.includes(t)?e.keys:[...e.keys,t],i=e.folders.map(e=>({...e,keys:e.keys.filter(e=>e!==t)}));if(n){let e=Pt(n,i);e&&e.keys.push(t)}return{keys:r,folders:i}}function Vt(e,t){return t.find(t=>t.name.toLowerCase()===e.trim().toLowerCase())}function Ht(e){return{filter:{...e.filter},sort:e.sort,hide:[...e.hide],boardKind:e.boardKind,projects:e.projects?[...e.projects]:void 0}}function Ut(e,t,n){let r=t.trim();return!r||Vt(r,e)?{ok:!1}:{ok:!0,presets:[...e,{name:r,...Ht(n)}]}}function Wt(e,t){let n=Vt(t,e);return n?{ok:!0,chrome:Ht(n)}:{ok:!1}}function Gt(e,t,n){let r=Vt(t,e);return r?{ok:!0,presets:e.map(e=>e===r?{name:r.name,...Ht(n)}:e)}:{ok:!1}}function Kt(e,t,n){let r=n.trim(),i=Vt(t,e);return!r||!i||Vt(r,e)?{ok:!1}:{ok:!0,presets:e.map(e=>e===i?{...e,name:r}:e)}}function qt(e,t){return e.filter(e=>e.name.toLowerCase()!==t.trim().toLowerCase())}function Jt(e){let t=e.query.trim().toLowerCase(),n=[{label:`All stories`,jump:{kind:`all-stories`}},{label:`All epics`,jump:{kind:`all-epics`}},{label:`All combined`,jump:{kind:`all-combined`}},{label:`Refresh`,jump:{kind:`refresh`}},{label:`Agent`,jump:{kind:`agent`}},{label:`Create issue`,jump:{kind:`create`}},{label:`Create with AI`,jump:{kind:`create-ai`}},...e.presets.map(e=>({label:`Apply ${e}`,jump:{kind:`preset`,name:e}}))].filter(e=>!t||e.label.toLowerCase().includes(t)),r=[];if(n.length&&r.push({id:`actions`,title:`Actions`,rows:n}),!t)return r;let i=new Set(e.favouriteKeys??[]),a=(e.epics??[]).filter(t=>rt(t,e.query)).map(e=>({label:e.summary,key:e.key,...i.has(e.key)?{starred:!0}:{},jump:{kind:`epic`,key:e.key}}));a.length&&r.push({id:`epics`,title:`Epics`,rows:a});let o=(e.cards??[]).filter(t=>nt(t,e.query)).map(e=>({label:e.summary,key:e.key,jump:{kind:`card`,key:e.key,...e.epic?{epic:e.epic}:{}}}));return o.length&&r.push({id:`cards`,title:`Cards`,rows:o}),r}function Yt(e){return e.jump}var Xt=/[a-z0-9]{2,}/g;function Zt(e){return e.toLowerCase().match(Xt)??[]}function Qt(e){let t=new Set,n=[];for(let r of e)for(let e of r?.labels??[]){let r=e.toLowerCase();e&&!t.has(r)&&(t.add(r),n.push(e))}return n}function $t(e){let t=e.text.toLowerCase();if(!e.text.trim())return[];let n=new Set((e.selected??[]).map(e=>e.toLowerCase())),r=Zt(e.text),i=new Set,a=[];for(let o of e.labels){let e=o.toLowerCase();if(!e||n.has(e)||i.has(e))continue;let s=Zt(o);if((t.includes(e)||s.some(e=>r.includes(e)||t.includes(e))||r.some(t=>e.includes(t)))&&(i.add(e),a.push(o),a.length>=5))break}return a}function en(e,t){let n=$t({text:`${e.title}\n${e.description}`,labels:t,selected:e.labels}),r=new Set(e.dismissed.map(e=>e.toLowerCase()));return n.filter(e=>!r.has(e.toLowerCase()))}function tn(e,t){return e.labels.some(e=>e.toLowerCase()===t.toLowerCase())?e:{...e,labels:[...e.labels,t]}}function nn(e,t){return e.dismissed.some(e=>e.toLowerCase()===t.toLowerCase())?e:{...e,dismissed:[...e.dismissed,t]}}function rn(e,t){return{...e,labels:e.labels.filter(e=>e.toLowerCase()!==t.toLowerCase())}}function an(e){return{...e.status?{status:e.status}:{},...e.selectedEpic&&e.boardKind!==`epics`?{epic:e.selectedEpic}:{},...e.boardKind===`epics`?{type:`Epic`}:{}}}function on(e={}){return{mode:`create`,title:``,description:``,labels:[],dismissed:[],...e}}function sn(e={}){return on(an(e))}function cn(e={}){let t=sn(e);return{draft:t,seed:vn(t)}}function ln(e){let t={...e.status?{status:e.status}:{},...e.epic?{epic:e.epic}:{},...e.type?{type:e.type}:{}};return e.fields?.length?gn(e.key,e.fields,t):{mode:`edit`,key:e.key,title:e.summary??``,description:e.description??``,labels:e.labels??[],dismissed:[],...t}}function un(e,t=!1){return!!e?.title.trim()&&!t}function dn(e){return!e||e.mode!==`create`||!un(e)?null:{summary:e.title.trim(),description:e.description,labels:e.labels,...e.status?{status:e.status}:{},...e.epic?{parent:e.epic}:{},...e.type?{type:e.type}:{}}}function fn(e){return!e||e.mode!==`edit`||!e.key||!un(e)?null:{key:e.key,summary:e.title.trim(),description:e.description,labels:e.labels}}function pn(e,t,n=!1){return e.key===`Escape`?`close`:e.key===`Enter`&&(e.metaKey||e.ctrlKey)&&un(t,n)?`submit`:null}function mn(e,t){let n=t.toLowerCase();return e?.find(e=>e.label.toLowerCase()===n)}function hn(e){return e?.pills?.length?e.pills:e?.value.trim()?e.value.split(/,\s*/).filter(Boolean):[]}function gn(e,t,n={}){return{mode:`edit`,key:e,title:mn(t,`Summary`)?.value??``,description:mn(t,`Description`)?.value??``,labels:hn(mn(t,`Labels`)),dismissed:[],...n}}function _n(e,t){if(e.mode!==`edit`||!e.key)return e;let n=gn(e.key,t,{status:e.status,epic:e.epic,type:e.type});return{...n,title:e.title.trim()?e.title:n.title,description:e.description.trim()?e.description:n.description,labels:e.labels.length?e.labels:n.labels,dismissed:e.dismissed}}function vn(e){let t=[`Draft a new Jira issue for this board.`,`Propose a concise summary, a short description, and labels from labels already on the board.`,`Then call the create_issue tool with those fields so the issue is created after I approve.`];return e?.title.trim()&&t.push(`Working title: ${e.title.trim()}`),e?.description.trim()&&t.push(`Working description: ${e.description.trim()}`),e?.status&&t.push(`Create it in status ${e.status}.`),e?.epic&&t.push(`Parent Epic: ${e.epic}.`),e?.labels.length&&t.push(`Preferred labels: ${e.labels.join(`, `)}.`),t.join(` `)}function yn(e){let t=[],n=!1,r=e.toast??Ae;function i(e){let r=Array.isArray(e)?e:[e];for(let e of r)t.push(e);n||a()}async function a(){n=!0;try{for(;t.length>0;){let n=t.shift(),i=r.loading(`Moving ${n.key} → ${n.target}…`);try{let t=await e.run(n);if(t.ok)r.success(`Moved ${n.key} to ${n.target}`,{id:i});else{let a=t.error??`Move failed`;r.error(`Move ${n.key} failed`,{id:i,description:a}),e.onRollback(n)}}catch(t){let a=t instanceof Error?t.message:`Move failed`;r.error(`Move ${n.key} failed`,{id:i,description:a}),e.onRollback(n)}}}finally{n=!1}}return{move:i}}function bn(e,t){let n=(0,C.useRef)(null);return n.current||=yn({run:async e=>await(await fetch(`/api/move`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({key:e.key,status:e.target,raw:!0})})).json(),onRollback:n=>{if(n.kind===`card`){e(e=>{let t=e[n.target]??[],r=t.findIndex(e=>e.key===n.key);if(r===-1)return e;let i=t[r],a={...e};return a[n.target]=t.filter(e=>e.key!==n.key),a[n.source]=[...e[n.source]??[],i],a});return}t(e=>{let t=e.findIndex(e=>e.key===n.key);if(t===-1)return e;let r=[...e];return r[t]={...r[t],status:n.source},r})}}),n.current}function xn(e,t){if(e.startsWith(`/`))return e;try{let n=new URL(e,t);return n.origin===new URL(t).origin?n.toString():null}catch{return null}}var Sn=`board-canvas-tab`;function Cn(){try{return localStorage.getItem(`board-canvas-tab`)===`calendar`?`calendar`:`board`}catch{return`board`}}function wn(e){localStorage.setItem(Sn,e)}function Tn(){wn(`calendar`)}function En(e){return typeof e?.key==`string`&&e.key?e.key:void 0}function Dn(e){if(!e)return;let t=/^(\d{4})-(\d{2})-(\d{2})/.exec(e);return t?`${t[1]}-${t[2]}-${t[3]}`:void 0}function On(e){let t=[];for(let n of e){let e=Dn(n.created);e&&t.push({id:`${n.key}:created`,title:`${n.key} created`,start:e,allDay:!0,classNames:[`fc-event-created`],extendedProps:{key:n.key,kind:`created`}});let r=Dn(n.targetEnd);r&&t.push({id:`${n.key}:targetEnd`,title:`${n.key} target end`,start:r,allDay:!0,classNames:[`fc-event-target-end`],extendedProps:{key:n.key,kind:`targetEnd`}})}return t}function kn(e){return[{type:`text`,text:jn({...e,scope:e.scope??`view`})},{type:`resource`,resource:{uri:`pipe-kan://board`,mimeType:`application/json`,text:JSON.stringify(e)}}]}function An(e){return kn({scope:`pipe`,kind:`stories`,selectedEpic:null,search:``,filter:{},sort:`payload`,hide:[],columns:e.columns,epics:e.epics})}function jn(e){let t=e.kind===`epics`?`All epics`:e.kind===`combined`?`All combined`:`All stories`,n=e.selectedEpic?`${t}, children of ${e.selectedEpic}`:t,r=[e.scope===`pipe`?`The user is working with piped Jira issues (the full payload). Answer from these Jira issues. This is not GitHub and not the local source repo.`:`The user attached the current Jira Kanban board (visible cards only). Answer from these Jira issues. This is not GitHub and not the local source repo.`,`Board: ${n}`];if(e.search.trim()&&r.push(`Search: ${e.search.trim()}`),Object.values(e.filter).some(e=>e.length)&&r.push(`Filter: ${JSON.stringify(e.filter)}`),r.push(`Sort: ${e.sort}`),e.hide.length&&r.push(`Hidden columns: ${e.hide.join(`, `)}`),r.push(``,`Columns:`),!e.columns.length)r.push(`(empty)`);else for(let t of e.columns){if(r.push(`## ${t.title}`),!t.cards.length){r.push(`(no cards)`);continue}for(let e of t.cards)r.push(`- ${Mn(e)}`)}if(e.epics.length){r.push(``,`Epics:`);for(let t of e.epics){let e=t.status?` (${t.status})`:``;r.push(`- ${t.key} ${t.summary}${e}`)}}return r.join(`
|
|
12
|
+
`)}function Mn(e){let t=[e.key,e.summary];e.epic&&t.push(`[epic ${e.epic}]`);let n=[e.priority,e.assignee,e.dueDate,e.targetEnd,e.labels?.join(`, `)].filter(e=>!!e);return n.length&&t.push(`(${n.join(`, `)})`),t.join(` `)}async function Nn(e,t=Pn(),n=Fn){if(t)try{await t.writeText(e);return}catch{n(e);return}n(e)}function Pn(){return typeof navigator>`u`||!navigator.clipboard?.writeText?null:navigator.clipboard}function Fn(e,t=document){let n=t.createElement(`textarea`);n.value=e,n.setAttribute(`readonly`,``),n.style.position=`fixed`,n.style.top=`0`,n.style.left=`0`,n.style.width=`1px`,n.style.height=`1px`,n.style.opacity=`0`,t.body.appendChild(n),n.focus(),n.select(),n.setSelectionRange(0,e.length);let r=t.execCommand(`copy`);if(t.body.removeChild(n),!r)throw Error(`Copy failed`)}function In(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=In(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n)}return r}function Ln(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=In(e))&&(r&&(r+=` `),r+=t);return r}var Rn=(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},zn=(e,t)=>({classGroupId:e,validator:t}),Bn=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),Vn=`-`,Hn=[],Un=`arbitrary..`,Wn=e=>{let t=qn(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return Kn(e);let n=e.split(Vn);return Gn(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?Rn(i,t):t:i||Hn}return n[e]||Hn}}},Gn=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=Gn(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(Vn):e.slice(t).join(Vn),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},Kn=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?Un+r:void 0})(),qn=e=>{let{theme:t,classGroups:n}=e;return Jn(n,t)},Jn=(e,t)=>{let n=Bn();for(let r in e){let i=e[r];Yn(i,n,r,t)}return n},Yn=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];Xn(i,t,n,r)}},Xn=(e,t,n,r)=>{if(typeof e==`string`){Zn(e,t,n);return}if(typeof e==`function`){Qn(e,t,n,r);return}$n(e,t,n,r)},Zn=(e,t,n)=>{let r=e===``?t:er(t,e);r.classGroupId=n},Qn=(e,t,n,r)=>{if(tr(e)){Yn(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(zn(n,e))},$n=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];Yn(o,er(t,a),n,r)}},er=(e,t)=>{let n=e,r=t.split(Vn),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=Bn(),n.nextPart.set(t,i)),n=i}return n},tr=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,nr=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)}}},rr=`!`,ir=`:`,ar=[],or=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),sr=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===ir){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(rr)?(c=s.slice(0,-1),l=!0):s.startsWith(rr)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return or(t,l,c,u)};if(t){let e=t+ir,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):or(ar,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},cr=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}},lr=e=>({cache:nr(e.cacheSize),parseClassName:sr(e),sortModifiers:cr(e),postfixLookupClassGroupIds:ur(e),...Wn(e)}),ur=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},dr=/\s+/,fr=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a,postfixLookupClassGroupIds:o}=t,s=[],c=e.trim().split(dr),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?_+rr:_,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},pr=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=mr(n))&&(i&&(i+=` `),i+=r);return i},mr=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=mr(e[r]))&&(n&&(n+=` `),n+=t);return n},hr=(e,...t)=>{let n,r,i,a,o=o=>(n=lr(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=fr(e,n);return i(e,a),a};return a=o,(...e)=>a(pr(...e))},gr=[],_r=e=>{let t=t=>t[e]||gr;return t.isThemeGetter=!0,t},vr=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,yr=/^\((?:(\w[\w-]*):)?(.+)\)$/i,br=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,xr=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Sr=/\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$/,Cr=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,wr=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Tr=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Er=e=>br.test(e),V=e=>!!e&&!Number.isNaN(Number(e)),Dr=e=>!!e&&Number.isInteger(Number(e)),Or=e=>e.endsWith(`%`)&&V(e.slice(0,-1)),kr=e=>xr.test(e),Ar=()=>!0,jr=e=>Sr.test(e)&&!Cr.test(e),Mr=()=>!1,Nr=e=>wr.test(e),Pr=e=>Tr.test(e),Fr=e=>!H(e)&&!U(e),Ir=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)),Lr=e=>Qr(e,ni,Mr),H=e=>vr.test(e),Rr=e=>Qr(e,ri,jr),zr=e=>Qr(e,ii,V),Br=e=>Qr(e,oi,Ar),Vr=e=>Qr(e,ai,Mr),Hr=e=>Qr(e,ei,Mr),Ur=e=>Qr(e,ti,Pr),Wr=e=>Qr(e,si,Nr),U=e=>yr.test(e),Gr=e=>$r(e,ri),Kr=e=>$r(e,ai),qr=e=>$r(e,ei),Jr=e=>$r(e,ni),Yr=e=>$r(e,ti),Xr=e=>$r(e,si,!0),Zr=e=>$r(e,oi,!0),Qr=(e,t,n)=>{let r=vr.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},$r=(e,t,n=!1)=>{let r=yr.exec(e);return r?r[1]?t(r[1]):n:!1},ei=e=>e===`position`||e===`percentage`,ti=e=>e===`image`||e===`url`,ni=e=>e===`length`||e===`size`||e===`bg-size`,ri=e=>e===`length`,ii=e=>e===`number`,ai=e=>e===`family-name`,oi=e=>e===`number`||e===`weight`,si=e=>e===`shadow`,ci=hr(()=>{let e=_r(`color`),t=_r(`font`),n=_r(`text`),r=_r(`font-weight`),i=_r(`tracking`),a=_r(`leading`),o=_r(`breakpoint`),s=_r(`container`),c=_r(`spacing`),l=_r(`radius`),u=_r(`shadow`),d=_r(`inset-shadow`),f=_r(`text-shadow`),p=_r(`drop-shadow`),m=_r(`blur`),h=_r(`perspective`),g=_r(`aspect`),_=_r(`ease`),v=_r(`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(),U,H],S=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],C=()=>[`auto`,`contain`,`none`],w=()=>[U,H,c],T=()=>[Er,`full`,`auto`,...w()],E=()=>[Dr,`none`,`subgrid`,U,H],D=()=>[`auto`,{span:[`full`,Dr,U,H]},Dr,U,H],O=()=>[Dr,`auto`,U,H],ee=()=>[`auto`,`min`,`max`,`fr`,U,H],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=()=>[Er,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],te=()=>[Er,`screen`,`full`,`dvw`,`lvw`,`svw`,`min`,`max`,`fit`,...w()],N=()=>[Er,`screen`,`full`,`lh`,`dvh`,`lvh`,`svh`,`min`,`max`,`fit`,...w()],P=()=>[e,U,H],F=()=>[...b(),qr,Hr,{position:[U,H]}],ne=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],re=()=>[`auto`,`cover`,`contain`,Jr,Lr,{size:[U,H]}],ie=()=>[Or,Gr,Rr],I=()=>[``,`none`,`full`,l,U,H],L=()=>[``,V,Gr,Rr],R=()=>[`solid`,`dashed`,`dotted`,`double`],ae=()=>[`normal`,`multiply`,`screen`,`overlay`,`darken`,`lighten`,`color-dodge`,`color-burn`,`hard-light`,`soft-light`,`difference`,`exclusion`,`hue`,`saturation`,`color`,`luminosity`],z=()=>[V,Or,qr,Hr],B=()=>[``,`none`,m,U,H],oe=()=>[`none`,V,U,H],se=()=>[`none`,V,U,H],ce=()=>[V,U,H],le=()=>[Er,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[kr],breakpoint:[kr],color:[Ar],container:[kr],"drop-shadow":[kr],ease:[`in`,`out`,`in-out`],font:[Fr],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[kr],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[kr],shadow:[kr],spacing:[`px`,V],text:[kr],"text-shadow":[kr],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,Er,H,U,g]}],container:[`container`],"container-type":[{"@container":[``,`normal`,`size`,U,H]}],"container-named":[Ir],columns:[{columns:[V,H,U,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:[Dr,`auto`,U,H]}],basis:[{basis:[Er,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[V,Er,`auto`,`initial`,`none`,H]}],grow:[{grow:[``,V,U,H]}],shrink:[{shrink:[``,V,U,H]}],order:[{order:[Dr,`first`,`last`,`none`,U,H]}],"grid-cols":[{"grid-cols":E()}],"col-start-end":[{col:D()}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":E()}],"row-start-end":[{row:D()}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":ee()}],"auto-rows":[{"auto-rows":ee()}],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`,...te()]}],"min-inline-size":[{"min-inline":[`auto`,...te()]}],"max-inline-size":[{"max-inline":[`none`,...te()]}],"block-size":[{block:[`auto`,...N()]}],"min-block-size":[{"min-block":[`auto`,...N()]}],"max-block-size":[{"max-block":[`none`,...N()]}],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,Gr,Rr]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,Zr,Br]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,Or,H]}],"font-family":[{font:[Kr,Vr,t]}],"font-features":[{"font-features":[H]}],"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,U,H]}],"line-clamp":[{"line-clamp":[V,`none`,U,zr]}],leading:[{leading:[a,...w()]}],"list-image":[{"list-image":[`none`,U,H]}],"list-style-position":[{list:[`inside`,`outside`]}],"list-style-type":[{list:[`disc`,`decimal`,`none`,U,H]}],"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:[...R(),`wavy`]}],"text-decoration-thickness":[{decoration:[V,`from-font`,`auto`,U,Rr]}],"text-decoration-color":[{decoration:P()}],"underline-offset":[{"underline-offset":[V,`auto`,U,H]}],"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:[Dr,U,H]}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,U,H]}],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`,U,H]}],"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`]},Dr,U,H],radial:[``,U,H],conic:[Dr,U,H]},Yr,Ur]}],"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:I()}],"rounded-s":[{"rounded-s":I()}],"rounded-e":[{"rounded-e":I()}],"rounded-t":[{"rounded-t":I()}],"rounded-r":[{"rounded-r":I()}],"rounded-b":[{"rounded-b":I()}],"rounded-l":[{"rounded-l":I()}],"rounded-ss":[{"rounded-ss":I()}],"rounded-se":[{"rounded-se":I()}],"rounded-ee":[{"rounded-ee":I()}],"rounded-es":[{"rounded-es":I()}],"rounded-tl":[{"rounded-tl":I()}],"rounded-tr":[{"rounded-tr":I()}],"rounded-br":[{"rounded-br":I()}],"rounded-bl":[{"rounded-bl":I()}],"border-w":[{border:L()}],"border-w-x":[{"border-x":L()}],"border-w-y":[{"border-y":L()}],"border-w-s":[{"border-s":L()}],"border-w-e":[{"border-e":L()}],"border-w-bs":[{"border-bs":L()}],"border-w-be":[{"border-be":L()}],"border-w-t":[{"border-t":L()}],"border-w-r":[{"border-r":L()}],"border-w-b":[{"border-b":L()}],"border-w-l":[{"border-l":L()}],"divide-x":[{"divide-x":L()}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":L()}],"divide-y-reverse":[`divide-y-reverse`],"border-style":[{border:[...R(),`hidden`,`none`]}],"divide-style":[{divide:[...R(),`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:[...R(),`none`,`hidden`]}],"outline-offset":[{"outline-offset":[V,U,H]}],"outline-w":[{outline:[``,V,Gr,Rr]}],"outline-color":[{outline:P()}],shadow:[{shadow:[``,`none`,u,Xr,Wr]}],"shadow-color":[{shadow:P()}],"inset-shadow":[{"inset-shadow":[`none`,d,Xr,Wr]}],"inset-shadow-color":[{"inset-shadow":P()}],"ring-w":[{ring:L()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:P()}],"ring-offset-w":[{"ring-offset":[V,Rr]}],"ring-offset-color":[{"ring-offset":P()}],"inset-ring-w":[{"inset-ring":L()}],"inset-ring-color":[{"inset-ring":P()}],"text-shadow":[{"text-shadow":[`none`,f,Xr,Wr]}],"text-shadow-color":[{"text-shadow":P()}],opacity:[{opacity:[V,U,H]}],"mix-blend":[{"mix-blend":[...ae(),`plus-darker`,`plus-lighter`]}],"bg-blend":[{"bg-blend":ae()}],"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":[V]}],"mask-image-linear-from-pos":[{"mask-linear-from":z()}],"mask-image-linear-to-pos":[{"mask-linear-to":z()}],"mask-image-linear-from-color":[{"mask-linear-from":P()}],"mask-image-linear-to-color":[{"mask-linear-to":P()}],"mask-image-t-from-pos":[{"mask-t-from":z()}],"mask-image-t-to-pos":[{"mask-t-to":z()}],"mask-image-t-from-color":[{"mask-t-from":P()}],"mask-image-t-to-color":[{"mask-t-to":P()}],"mask-image-r-from-pos":[{"mask-r-from":z()}],"mask-image-r-to-pos":[{"mask-r-to":z()}],"mask-image-r-from-color":[{"mask-r-from":P()}],"mask-image-r-to-color":[{"mask-r-to":P()}],"mask-image-b-from-pos":[{"mask-b-from":z()}],"mask-image-b-to-pos":[{"mask-b-to":z()}],"mask-image-b-from-color":[{"mask-b-from":P()}],"mask-image-b-to-color":[{"mask-b-to":P()}],"mask-image-l-from-pos":[{"mask-l-from":z()}],"mask-image-l-to-pos":[{"mask-l-to":z()}],"mask-image-l-from-color":[{"mask-l-from":P()}],"mask-image-l-to-color":[{"mask-l-to":P()}],"mask-image-x-from-pos":[{"mask-x-from":z()}],"mask-image-x-to-pos":[{"mask-x-to":z()}],"mask-image-x-from-color":[{"mask-x-from":P()}],"mask-image-x-to-color":[{"mask-x-to":P()}],"mask-image-y-from-pos":[{"mask-y-from":z()}],"mask-image-y-to-pos":[{"mask-y-to":z()}],"mask-image-y-from-color":[{"mask-y-from":P()}],"mask-image-y-to-color":[{"mask-y-to":P()}],"mask-image-radial":[{"mask-radial":[U,H]}],"mask-image-radial-from-pos":[{"mask-radial-from":z()}],"mask-image-radial-to-pos":[{"mask-radial-to":z()}],"mask-image-radial-from-color":[{"mask-radial-from":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":[V]}],"mask-image-conic-from-pos":[{"mask-conic-from":z()}],"mask-image-conic-to-pos":[{"mask-conic-to":z()}],"mask-image-conic-from-color":[{"mask-conic-from":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`,U,H]}],filter:[{filter:[``,`none`,U,H]}],blur:[{blur:B()}],brightness:[{brightness:[V,U,H]}],contrast:[{contrast:[V,U,H]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,Xr,Wr]}],"drop-shadow-color":[{"drop-shadow":P()}],grayscale:[{grayscale:[``,V,U,H]}],"hue-rotate":[{"hue-rotate":[V,U,H]}],invert:[{invert:[``,V,U,H]}],saturate:[{saturate:[V,U,H]}],sepia:[{sepia:[``,V,U,H]}],"backdrop-filter":[{"backdrop-filter":[``,`none`,U,H]}],"backdrop-blur":[{"backdrop-blur":B()}],"backdrop-brightness":[{"backdrop-brightness":[V,U,H]}],"backdrop-contrast":[{"backdrop-contrast":[V,U,H]}],"backdrop-grayscale":[{"backdrop-grayscale":[``,V,U,H]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[V,U,H]}],"backdrop-invert":[{"backdrop-invert":[``,V,U,H]}],"backdrop-opacity":[{"backdrop-opacity":[V,U,H]}],"backdrop-saturate":[{"backdrop-saturate":[V,U,H]}],"backdrop-sepia":[{"backdrop-sepia":[``,V,U,H]}],"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`,U,H]}],"transition-behavior":[{transition:[`normal`,`discrete`]}],duration:[{duration:[V,`initial`,U,H]}],ease:[{ease:[`linear`,`initial`,_,U,H]}],delay:[{delay:[V,U,H]}],animate:[{animate:[`none`,v,U,H]}],backface:[{backface:[`hidden`,`visible`]}],perspective:[{perspective:[h,U,H]}],"perspective-origin":[{"perspective-origin":x()}],rotate:[{rotate:oe()}],"rotate-x":[{"rotate-x":oe()}],"rotate-y":[{"rotate-y":oe()}],"rotate-z":[{"rotate-z":oe()}],scale:[{scale:se()}],"scale-x":[{"scale-x":se()}],"scale-y":[{"scale-y":se()}],"scale-z":[{"scale-z":se()}],"scale-3d":[`scale-3d`],skew:[{skew:ce()}],"skew-x":[{"skew-x":ce()}],"skew-y":[{"skew-y":ce()}],transform:[{transform:[U,H,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:le()}],"translate-x":[{"translate-x":le()}],"translate-y":[{"translate-y":le()}],"translate-z":[{"translate-z":le()}],"translate-none":[`translate-none`],zoom:[{zoom:[Dr,U,H]}],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`,U,H]}],"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`,U,H]}],fill:[{fill:[`none`,...P()]}],"stroke-w":[{stroke:[V,Gr,Rr,zr]}],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 W(...e){return ci(Ln(e))}var li=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})),G=o(((e,t)=>{t.exports=li()}))();function ui({className:e,...t}){return(0,G.jsx)(`span`,{"data-slot":`avatar`,className:W(`bg-muted text-muted-foreground relative flex size-4 shrink-0 items-center justify-center overflow-hidden rounded-full text-[9px] font-medium`,e),...t})}function di({className:e,...t}){return(0,G.jsx)(`span`,{"data-slot":`avatar-fallback`,className:W(`flex size-full items-center justify-center`,e),...t})}var fi=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,pi=Ln,mi=(e,t)=>n=>{if(t?.variants==null)return pi(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=fi(t)||fi(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 pi(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)},hi=mi(`relative inline-flex h-5 min-w-5 w-fit shrink-0 items-center justify-center border px-1.5 text-xs font-medium whitespace-nowrap`,{variants:{variant:{outline:`border-border bg-transparent text-muted-foreground dark:bg-input/32`,"primary-light":`border-primary/10 bg-primary/10 text-primary dark:border-primary/25 dark:bg-primary/15 dark:text-primary`,"warning-light":`border-warning/15 bg-warning/10 text-warning-foreground dark:border-warning/25 dark:bg-warning/15 dark:text-warning`,"destructive-light":`border-destructive/15 bg-destructive/10 text-destructive-foreground dark:border-destructive/25 dark:bg-destructive/15 dark:text-destructive`}},defaultVariants:{variant:`outline`}});function gi({className:e,variant:t,...n}){return(0,G.jsx)(`span`,{"data-slot":`badge`,className:W(hi({variant:t}),`rounded-sm`,e),...n})}var _i=mi(`group/bubble relative flex w-fit max-w-full min-w-0 flex-col gap-1 group-data-[align=end]/message:self-end`,{variants:{variant:{default:`*:data-[slot=bubble-content]:bg-primary *:data-[slot=bubble-content]:text-primary-foreground`,muted:`*:data-[slot=bubble-content]:bg-muted`}},defaultVariants:{variant:`muted`}});function vi({variant:e=`muted`,className:t,...n}){return(0,G.jsx)(`div`,{"data-slot":`bubble`,"data-variant":e,className:W(_i({variant:e}),t),...n})}function yi({className:e,...t}){return(0,G.jsx)(`div`,{"data-slot":`bubble-content`,className:W(`w-fit max-w-full min-w-0 overflow-hidden rounded-xl px-3 py-2 text-sm leading-relaxed whitespace-pre-wrap wrap-break-word`,e),...t})}var bi=Object.defineProperty,xi=(e,t)=>bi(e,`name`,{value:t,configurable:!0});function Si(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}xi(Si,`setRef`);function Ci(...e){return t=>{let n=!1,r=e.map(e=>{let r=Si(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():Si(e[t],null)}}}}xi(Ci,`composeRefs`);function wi(...e){return C.useCallback(Ci(...e),e)}xi(wi,`useComposedRefs`);var Ti=Object.defineProperty,Ei=(e,t)=>Ti(e,`name`,{value:t,configurable:!0});function Di(e){let t=C.forwardRef((t,n)=>{let{children:r,...i}=t,a=null,o=!1,s=[];Fi(r)&&typeof zi==`function`&&(r=zi(r._payload)),C.Children.forEach(r,e=>{if(Ni(e)){o=!0;let t=e,n=`child`in t.props?t.props.child:t.props.children;Fi(n)&&typeof zi==`function`&&(n=zi(n._payload)),a=Ai(t,n),s.push(a?.props?.children)}else s.push(e)}),a?a=C.cloneElement(a,void 0,s):!o&&C.Children.count(r)===1&&C.isValidElement(r)&&(a=r);let c=a?Mi(a):void 0,l=wi(n,c);if(!a){if(r||r===0)throw Error(o?Ri(e):Li(e));return r}let u=ji(i,a.props??{});return a.type!==C.Fragment&&(u.ref=n?l:c),C.cloneElement(a,u)});return t.displayName=`${e}.Slot`,t}Ei(Di,`createSlot`);var K=Di(`Slot`),Oi=Symbol.for(`radix.slottable`);function ki(e){let t=Ei(e=>`child`in e?e.children(e.child):e.children,`Slottable`);return t.displayName=`${e}.Slottable`,t.__radixId=Oi,t}Ei(ki,`createSlottable`);var Ai=Ei((e,t)=>{if(`child`in e.props){let t=e.props.child;return C.isValidElement(t)?C.cloneElement(t,void 0,e.props.children(t.props.children)):null}return C.isValidElement(t)?t:null},`getSlottableElementFromSlottable`);function ji(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}}Ei(ji,`mergeProps`);function Mi(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)}Ei(Mi,`getElementRef`);function Ni(e){return C.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===Oi}Ei(Ni,`isSlottable`);var Pi=Symbol.for(`react.lazy`);function Fi(e){return typeof e==`object`&&!!e&&`$$typeof`in e&&e.$$typeof===Pi&&`_payload`in e&&Ii(e._payload)}Ei(Fi,`isLazyComponent`);function Ii(e){return typeof e==`object`&&!!e&&`then`in e}Ei(Ii,`isPromiseLike`);var Li=Ei(e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,`createSlotError`),Ri=Ei(e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,`createSlottableError`),zi=C.use,Bi=mi(`inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive`,{variants:{variant:{default:`bg-primary text-primary-foreground shadow-xs hover:bg-primary/90`,destructive:`text-destructive hover-text-foreground bg-secondary border border-border hover:text-white shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:hover:bg-destructive/60`,outline:`border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50`,secondary:`bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80`,ghost:`hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-9 px-4 py-2 has-[>svg]:px-3`,sm:`h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5`,lg:`h-10 rounded-md px-6 has-[>svg]:px-4`,icon:`size-9`,"icon-xs":`size-6 rounded-md [&_svg:not([class*=size-])]:size-3.5`}},defaultVariants:{variant:`default`,size:`default`}});function q({className:e,variant:t,size:n,asChild:r=!1,...i}){return(0,G.jsx)(r?K:`button`,{"data-slot":`button`,className:W(Bi({variant:t,size:n,className:e})),...i})}var Vi=Object.defineProperty,Hi=(e,t)=>Vi(e,`name`,{value:t,configurable:!0}),Ui=!!(typeof window<`u`&&window.document&&window.document.createElement);function J(e,t,{checkForDefaultPrevented:n=!0}={}){return Hi(function(r){if(e?.(r),n===!1||!r||!r.defaultPrevented)return t?.(r)},`handleEvent`)}Hi(J,`composeEventHandlers`);function Wi(e){if(!Ui)throw Error(`Cannot access window outside of the DOM`);return e?.ownerDocument?.defaultView??window}Hi(Wi,`getOwnerWindow`);function Gi(e){if(!Ui)throw Error(`Cannot access document outside of the DOM`);return e?.ownerDocument??document}Hi(Gi,`getOwnerDocument`);function Ki(e,t=!1){let{activeElement:n}=Gi(e);if(!n?.nodeName)return null;if(qi(n)&&n.contentDocument)return Ki(n.contentDocument.body,t);if(t){let e=n.getAttribute(`aria-activedescendant`);if(e){let t=Gi(n).getElementById(e);if(t)return t}}return n}Hi(Ki,`getActiveElement`);function qi(e){return e.tagName===`IFRAME`}Hi(qi,`isFrame`);var Ji=Object.defineProperty,Yi=(e,t)=>Ji(e,`name`,{value:t,configurable:!0});function Xi(e,t){let n=C.createContext(t);n.displayName=e+`Context`;let r=Yi(e=>{let{children:t,...r}=e,i=C.useMemo(()=>r,Object.values(r));return(0,G.jsx)(n.Provider,{value:i,children:t})},`Provider`);r.displayName=e+`Provider`;function i(r,i={}){let{optional:a=!1}=i,o=C.useContext(n);if(o)return o;if(t!==void 0)return t;if(!a)throw Error(`\`${r}\` must be used within \`${e}\``)}return Yi(i,`useContext`),[r,i]}Yi(Xi,`createContext`);function Zi(e,t=[]){let n=[];function r(t,r){let i=C.createContext(r);i.displayName=t+`Context`;let a=n.length;n=[...n,r];let o=Yi(t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=C.useMemo(()=>o,Object.values(o));return(0,G.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=C.useContext(l);if(u)return u;if(r!==void 0)return r;if(!c)throw Error(`\`${n}\` must be used within \`${t}\``)}return Yi(s,`useContext`),[o,s]}Yi(r,`createContext`);let i=Yi(()=>{let t=n.map(e=>C.createContext(e));return Yi(function(n){let r=n?.[e]||t;return C.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])},`useScope`)},`createScope`);return i.scopeName=e,[r,Qi(i,...t)]}Yi(Zi,`createContextScope`);function Qi(...e){let t=e[0];if(e.length===1)return t;let n=Yi(()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return Yi(function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return C.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])},`useComposedScopes`)},`createScope`);return n.scopeName=t.scopeName,n}Yi(Qi,`composeContextScopes`);var $i=globalThis?.document?C.useLayoutEffect:()=>{},ea=Object.defineProperty,ta=(e,t)=>ea(e,`name`,{value:t,configurable:!0}),na=C.useEffectEvent,ra=C.useInsertionEffect;function ia(e){if(typeof na==`function`)return na(e);let t=C.useRef(()=>{throw Error(`Cannot call an event handler while rendering.`)});return typeof ra==`function`?ra(()=>{t.current=e}):$i(()=>{t.current=e}),C.useMemo(()=>((...e)=>t.current?.(...e)),[])}ta(ia,`useEffectEvent`);var aa=Object.defineProperty,oa=(e,t)=>aa(e,`name`,{value:t,configurable:!0}),sa=C.useInsertionEffect||$i;function ca({prop:e,defaultProp:t,onChange:n=oa(()=>{},`onChange`),caller:r}){let[i,a,o]=la({defaultProp:t,onChange:n}),s=e!==void 0;return[s?e:i,C.useCallback(t=>{if(s){let n=ua(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}oa(ca,`useControllableState`);function la({defaultProp:e,onChange:t}){let[n,r]=C.useState(e),i=C.useRef(n),a=C.useRef(t);return sa(()=>{a.current=t},[t]),C.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}oa(la,`useUncontrolledState`);function ua(e){return typeof e==`function`}oa(ua,`isFunction`);var da=Symbol(`RADIX:SYNC_STATE`);function fa(e,t,n,r){let{prop:i,defaultProp:a,onChange:o,caller:s}=t,c=i!==void 0,l=ia(o),u=[{...n,state:a}];r&&u.push(r);let[d,f]=C.useReducer((t,n)=>{if(n.type===da)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=C.useRef(p);C.useEffect(()=>{m.current!==p&&(m.current=p,c||l(p))},[p,m,c]);let h=C.useMemo(()=>i===void 0?d:{...d,state:i},[d,i]);return C.useEffect(()=>{c&&!Object.is(i,d.state)&&f({type:da,state:i})},[i,d.state,c]),[h,f]}oa(fa,`useControllableStateReducer`);var pa=Object.defineProperty,ma=(e,t)=>pa(e,`name`,{value:t,configurable:!0}),ha=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=Di(`Primitive.${t}`),r=C.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,G.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function ga(e,t){e&&pe.flushSync(()=>e.dispatchEvent(t))}ma(ga,`dispatchDiscreteCustomEvent`);var _a=Object.defineProperty,va=(e,t)=>_a(e,`name`,{value:t,configurable:!0});function ya(e){let t=e+`CollectionProvider`,[n,r]=Zi(t),[i,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=va(e=>{let{scope:t,children:n}=e,r=C.useRef(null),a=C.useRef(new Map).current;return(0,G.jsx)(i,{scope:t,itemMap:a,collectionRef:r,children:n})},`CollectionProvider`);o.displayName=t;let s=e+`CollectionSlot`,c=Di(s),l=C.forwardRef((e,t)=>{let{scope:n,children:r}=e,i=wi(t,a(s,n).collectionRef);return(0,G.jsx)(c,{ref:i,children:r})});l.displayName=s;let u=e+`CollectionItemSlot`,d=`data-radix-collection-item`,f=Di(u),p=C.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=C.useRef(null),s=wi(t,o),c=a(u,n);return C.useEffect(()=>(c.itemMap.set(o,{ref:o,...i}),()=>void c.itemMap.delete(o))),(0,G.jsx)(f,{[d]:``,ref:s,children:r})});p.displayName=u;function m(t){let n=a(e+`CollectionConsumer`,t);return C.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 va(m,`useCollection`),[{Provider:o,Slot:l,ItemSlot:p},m,r]}va(ya,`createCollection`);var ba=new WeakMap,xa=class e extends Map{static{va(this,`OrderedDict`)}#e;constructor(e){super(e),this.#e=[...super.keys()],ba.set(this,!0)}set(e,t){return ba.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=wa(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=Sa(this.#e,e);if(t!==void 0)return this.get(t)}entryAt(e){let t=Sa(this.#e,e);if(t!==void 0)return[t,this.get(t)]}indexOf(e){return this.#e.indexOf(e)}keyAt(e){return Sa(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 Sa(e,t){if(`at`in Array.prototype)return Array.prototype.at.call(e,t);let n=Ca(e,t);return n===-1?void 0:e[n]}va(Sa,`at`);function Ca(e,t){let n=e.length,r=wa(t),i=r>=0?r:n+r;return i<0||i>=n?-1:i}va(Ca,`toSafeIndex`);function wa(e){return e!==e||e===0?0:Math.trunc(e)}va(wa,`toSafeInteger`);function Ta(e){let t=e+`CollectionProvider`,[n,r]=Zi(t),[i,a]=n(t,{collectionElement:null,collectionRef:{current:null},collectionRefObject:{current:null},itemMap:new xa,setItemMap:va(()=>void 0,`setItemMap`)}),o=va(({state:e,...t})=>e?(0,G.jsx)(c,{...t,state:e}):(0,G.jsx)(s,{...t}),`CollectionProvider`);o.displayName=t;let s=va(e=>{let t=h();return(0,G.jsx)(c,{...e,state:t})},`CollectionInit`);s.displayName=t+`Init`;let c=va(e=>{let{scope:t,children:n,state:r}=e,a=C.useRef(null),[o,s]=C.useState(null),c=wi(a,s),[l,u]=r;return C.useEffect(()=>{if(!o)return;let e=ka(()=>{});return e.observe(o,{childList:!0,subtree:!0}),()=>{e.disconnect()}},[o]),(0,G.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=Di(l),d=C.forwardRef((e,t)=>{let{scope:n,children:r}=e,i=wi(t,a(l,n).collectionRef);return(0,G.jsx)(u,{ref:i,children:r})});d.displayName=l;let f=e+`CollectionItemSlot`,p=Di(f),m=C.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=C.useRef(null),[s,c]=C.useState(null),l=wi(t,o,c),{setItemMap:u}=a(f,n),d=C.useRef(i);Ea(d.current,i)||(d.current=i);let m=d.current;return C.useEffect(()=>{let e=m;return u(t=>s?t.has(s)?t.set(s,{...e,element:s}).toSorted(Oa):(t.set(s,{...e,element:s}),t.toSorted(Oa)):t),()=>{u(e=>!s||!e.has(s)?e:(e.delete(s),new xa(e)))}},[s,m,u]),(0,G.jsx)(p,{"data-radix-collection-item":``,ref:l,children:r})});m.displayName=f;function h(){return C.useState(new xa)}va(h,`useInitCollection`);function g(t){let{itemMap:n}=a(e+`CollectionConsumer`,t);return n}return va(g,`useCollection`),[{Provider:o,Slot:d,ItemSlot:m},{createCollectionScope:r,useCollection:g,useInitCollection:h}]}va(Ta,`createCollection`);function Ea(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}va(Ea,`shallowEqual`);function Da(e,t){return!!(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_PRECEDING)}va(Da,`isElementPreceding`);function Oa(e,t){return!e[1].element||!t[1].element?0:Da(e[1].element,t[1].element)?-1:1}va(Oa,`sortByDocumentPosition`);function ka(e){return new MutationObserver(t=>{for(let n of t)if(n.type===`childList`){e();return}})}va(ka,`getChildListObserver`);var Aa=Object.defineProperty,ja=(e,t)=>Aa(e,`name`,{value:t,configurable:!0}),Ma=C.createContext(void 0);function Na(e){let t=C.useContext(Ma);return e||t||`ltr`}ja(Na,`useDirection`);var Pa=Object.defineProperty,Fa=(e,t)=>Pa(e,`name`,{value:t,configurable:!0});function Ia(e){let t=C.useRef(e);return C.useEffect(()=>{t.current=e}),C.useMemo(()=>((...e)=>t.current?.(...e)),[])}Fa(Ia,`useCallbackRef`);var La=Object.defineProperty,Ra=(e,t)=>La(e,`name`,{value:t,configurable:!0}),za=`dismissableLayer.update`,Ba=`dismissableLayer.pointerDownOutside`,Va=`dismissableLayer.focusOutside`,Ha,Ua=C.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),Wa=C.forwardRef(Ra(function(e,t){let{disableOutsidePointerEvents:n=!1,deferPointerDownOutside:r=!1,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:o,onInteractOutside:s,onDismiss:c,...l}=e,u=C.useContext(Ua),[d,f]=C.useState(null),p=d?.ownerDocument??globalThis?.document,[,m]=C.useState({}),h=wi(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=C.useRef(!1),w=qa(e=>{a?.(e),s?.(e),e.defaultPrevented||c?.()},{ownerDocument:p,deferPointerDownOutside:r,isDeferredPointerDownOutsideRef:S,dismissableSurfaces:u.dismissableSurfaces,shouldHandlePointerDownOutside:C.useCallback(e=>{if(!(e instanceof Node))return!1;let t=[...u.branches].some(t=>t.contains(e));return x&&!t},[u.branches,x])}),T=Ja(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),E=d?y===g.length-1:!1,D=Ia(e=>{e.key===`Escape`&&(i?.(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))});return C.useEffect(()=>{if(E)return p.addEventListener(`keydown`,D,{capture:!0}),()=>p.removeEventListener(`keydown`,D,{capture:!0})},[p,E,D]),C.useEffect(()=>{if(d)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Ha=p.body.style.pointerEvents,p.body.style.pointerEvents=`none`),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),Ya(),()=>{n&&(u.layersWithOutsidePointerEventsDisabled.delete(d),u.layersWithOutsidePointerEventsDisabled.size===0&&(p.body.style.pointerEvents=Ha))}},[d,p,n,u]),C.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),Ya())},[d,u]),C.useEffect(()=>{let e=Ra(()=>m({}),`handleUpdate`);return document.addEventListener(za,e),()=>document.removeEventListener(za,e)},[]),(0,G.jsx)(ha.div,{...l,ref:h,style:{pointerEvents:b?x?`auto`:`none`:void 0,...e.style},onFocusCapture:J(e.onFocusCapture,T.onFocusCapture),onBlurCapture:J(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:J(e.onPointerDownCapture,w.onPointerDownCapture)})},`DismissableLayer`));function Ga(){let e=C.useContext(Ua),[t,n]=C.useState(null);return C.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),n}Ra(Ga,`useDismissableLayerSurface`);var Ka=Ra(()=>!0,`IS_TRUE`);function qa(e,t){let{ownerDocument:n=globalThis?.document,deferPointerDownOutside:r=!1,isDeferredPointerDownOutsideRef:i,dismissableSurfaces:a,shouldHandlePointerDownOutside:o=Ka}=t,s=Ia(e),c=C.useRef(!1),l=C.useRef(!1),u=C.useRef(new Map),d=C.useRef(()=>{});return C.useEffect(()=>{function e(){l.current=!1,i.current=!1,u.current.clear()}Ra(e,`resetOutsideInteraction`);function t(){return Array.from(u.current.values()).some(Boolean)}Ra(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)}Ra(f,`handleInteractionCapture`);function p(e){l.current&&u.current.set(e.type,!1)}Ra(p,`handleInteractionBubble`);let m=Ra(a=>{if(a.target&&!c.current){let f=function(){n.removeEventListener(`click`,d.current);let r=t();e(),r||Xa(Ba,s,p,{discrete:!0})};if(Ra(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:Ra(()=>c.current=!0,`onPointerDownCapture`)}}Ra(qa,`usePointerDownOutside`);function Ja(e,t=globalThis?.document){let n=Ia(e),r=C.useRef(!1);return C.useEffect(()=>{let e=Ra(e=>{e.target&&!r.current&&Xa(Va,n,{originalEvent:e},{discrete:!1})},`handleFocus`);return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:Ra(()=>r.current=!0,`onFocusCapture`),onBlurCapture:Ra(()=>r.current=!1,`onBlurCapture`)}}Ra(Ja,`useFocusOutside`);function Ya(){let e=new CustomEvent(za);document.dispatchEvent(e)}Ra(Ya,`dispatchUpdate`);function Xa(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?ga(i,a):i.dispatchEvent(a)}Ra(Xa,`handleAndDispatchCustomEvent`);var Za=Object.defineProperty,Qa=(e,t)=>Za(e,`name`,{value:t,configurable:!0}),$a=0,eo=null;function to(e){return no(),e.children}Qa(to,`FocusGuards`);function no(){C.useEffect(()=>{eo||={start:ro(),end:ro()};let{start:e,end:t}=eo;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement(`afterbegin`,e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement(`beforeend`,t),$a++,()=>{$a===1&&(eo?.start.remove(),eo?.end.remove(),eo=null),$a=Math.max(0,$a-1)}},[])}Qa(no,`useFocusGuards`);function ro(){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}Qa(ro,`createFocusGuard`);var Y=Object.defineProperty,X=(e,t)=>Y(e,`name`,{value:t,configurable:!0}),io=`focusScope.autoFocusOnMount`,ao=`focusScope.autoFocusOnUnmount`,oo={bubbles:!1,cancelable:!0},so=C.forwardRef(X(function(e,t){let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=C.useState(null),l=Ia(i),u=Ia(a),d=C.useRef(null),f=wi(t,c),p=C.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;C.useEffect(()=>{if(r){let e=function(e){if(p.paused||!s)return;let t=e.target;s.contains(t)?d.current=t:ho(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||ho(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&ho(s)};X(e,`handleFocusIn`),X(t,`handleFocusOut`),X(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]),C.useEffect(()=>{if(s){go.add(p);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(io,oo);s.addEventListener(io,l),s.dispatchEvent(t),t.defaultPrevented||(co(yo(uo(s)),{select:!0}),document.activeElement===e&&ho(s))}return()=>{s.removeEventListener(io,l),setTimeout(()=>{let t=new CustomEvent(ao,oo);s.addEventListener(ao,u),s.dispatchEvent(t),t.defaultPrevented||ho(e??document.body,{select:!0}),s.removeEventListener(ao,u),go.remove(p)},0)}}},[s,l,u,p]);let m=C.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]=lo(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&ho(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&ho(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,p.paused]);return(0,G.jsx)(ha.div,{tabIndex:-1,...o,ref:f,onKeyDown:m})},`FocusScope`));function co(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(ho(r,{select:t}),document.activeElement!==n)return}X(co,`focusFirst`);function lo(e){let t=uo(e);return[fo(t,e),fo(t.reverse(),e)]}X(lo,`getTabbableEdges`);function uo(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:X(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}X(uo,`getTabbableCandidates`);function fo(e,t){let n=typeof t.checkVisibility==`function`&&t.checkVisibility({checkVisibilityCSS:!0});for(let r of e)if(!(n?!r.checkVisibility({checkVisibilityCSS:!0}):po(r,{upTo:t})))return r}X(fo,`findVisible`);function po(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}X(po,`isHidden`);function mo(e){return e instanceof HTMLInputElement&&`select`in e}X(mo,`isSelectableInput`);function ho(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&mo(e)&&t&&e.select()}}X(ho,`focus`);var go=_o();function _o(){let e=[];return{add(t){let n=e[0];t!==n&&n?.pause(),e=vo(e,t),e.unshift(t)},remove(t){e=vo(e,t),e[0]?.resume()}}}X(_o,`createFocusScopesStack`);function vo(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}X(vo,`arrayRemove`);function yo(e){return e.filter(e=>e.tagName!==`A`)}X(yo,`removeLinks`);var bo=Object.defineProperty,xo=(e,t)=>bo(e,`name`,{value:t,configurable:!0}),So=C.useId||(()=>void 0),Co=0;function wo(e){let[t,n]=C.useState(So());return $i(()=>{e||n(e=>e??String(Co++))},[e]),e||(t?`radix-${t}`:``)}xo(wo,`useId`);var To=[`top`,`right`,`bottom`,`left`],Eo=Math.min,Do=Math.max,Oo=Math.round,ko=Math.floor,Ao=e=>({x:e,y:e}),jo={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function Mo(e,t,n){return Do(e,Eo(t,n))}function No(e,t){return typeof e==`function`?e(t):e}function Po(e){return e.split(`-`)[0]}function Fo(e){return e.split(`-`)[1]}function Io(e){return e===`x`?`y`:`x`}function Lo(e){return e===`y`?`height`:`width`}function Ro(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function zo(e){return Io(Ro(e))}function Bo(e,t,n){n===void 0&&(n=!1);let r=Fo(e),i=zo(e),a=Lo(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=Yo(o)),[o,Yo(o)]}function Vo(e){let t=Yo(e);return[Ho(e),t,Ho(t)]}function Ho(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var Uo=[`left`,`right`],Wo=[`right`,`left`],Go=[`top`,`bottom`],Ko=[`bottom`,`top`];function qo(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Wo:Uo:t?Uo:Wo;case`left`:case`right`:return t?Go:Ko;default:return[]}}function Jo(e,t,n,r){let i=Fo(e),a=qo(Po(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(Ho)))),a}function Yo(e){let t=Po(e);return jo[t]+e.slice(t.length)}function Xo(e){return{top:e.top??0,right:e.right??0,bottom:e.bottom??0,left:e.left??0}}function Zo(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:Xo(e)}function Qo(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 $o(e,t,n){let{reference:r,floating:i}=e,a=Ro(t),o=zo(t),s=Lo(o),c=Po(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=Fo(t);return m&&(p[o]+=f*(m===`end`?1:-1)*(n&&l?-1:1)),p}async function es(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}=No(t,e),p=Zo(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=Qo(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=Qo(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 ts=50,ns=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:es},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=$o(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<ts&&(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}=$o(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},rs=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}=No(e,t)||{};if(l==null)return{};let d=Zo(u),f={x:n,y:r},p=zo(i),m=Lo(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=Eo(d[_],T),D=Eo(d[v],T),O=C-h[m]-D,ee=C/2-h[m]/2+w,k=Mo(E,ee,O),A=!c.arrow&&Fo(i)!=null&&ee!==k&&a.reference[m]/2-(ee<E?E:D)-h[m]/2<0,j=A?ee<E?ee-E:ee-O:0;return{[p]:f[p]+j,data:{[p]:k,centerOffset:ee-k-j,...A&&{alignmentOffset:j}},reset:A}}}),is=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}=No(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=Po(r),_=Ro(o),v=Po(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[Yo(o)]:Vo(o)),x=p!==`none`;!d&&x&&b.push(...Jo(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=Bo(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`||_===Ro(t)||T.every(e=>Ro(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=Ro(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 as(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function os(e){return To.some(t=>e[t]>=0)}var ss=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=No(e,t);switch(i){case`referenceHidden`:{let e=as(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:os(e)}}}case`escaped`:{let e=as(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:os(e)}}}default:return{}}}}},cs=new Set([`left`,`top`]);async function ls(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Po(n),s=Fo(n),c=Ro(n)===`y`,l=cs.has(o)?-1:1,u=a&&c?-1:1,d=No(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 us=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 ls(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}}}}},ds=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}=No(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=Ro(i),p=Io(f),m=u[p],h=u[f],g=(e,t)=>Mo(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}}}}}},fs=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}=No(e,t),u={x:n,y:r},d=Ro(i),f=Io(d),p=u[f],m=u[d],h=No(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=cs.has(Po(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}}}},ps=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}=No(e,t),c=await i.detectOverflow(t,s),l=Po(n),u=Fo(n),d=Ro(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=Eo(p-c[m],g),y=Eo(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*Do(c.left,c.right):S=p-2*Do(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 ms(){return typeof window<`u`}function hs(e){return vs(e)?(e.nodeName||``).toLowerCase():`#document`}function gs(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function _s(e){return((vs(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function vs(e){return ms()?e instanceof Node||e instanceof gs(e).Node:!1}function ys(e){return ms()?e instanceof Element||e instanceof gs(e).Element:!1}function bs(e){return ms()?e instanceof HTMLElement||e instanceof gs(e).HTMLElement:!1}function xs(e){return!ms()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof gs(e).ShadowRoot}function Ss(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=Ns(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function Cs(e){return/^(table|td|th)$/.test(hs(e))}function ws(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var Ts=/transform|translate|scale|rotate|perspective|filter/,Es=/paint|layout|strict|content/,Ds=e=>!!e&&e!==`none`,Os;function ks(e){let t=ys(e)?Ns(e):e;return Ds(t.transform)||Ds(t.translate)||Ds(t.scale)||Ds(t.rotate)||Ds(t.perspective)||!js()&&(Ds(t.backdropFilter)||Ds(t.filter))||Ts.test(t.willChange||``)||Es.test(t.contain||``)}function As(e){let t=Fs(e);for(;bs(t)&&!Ms(t);){if(ks(t))return t;if(ws(t))return null;t=Fs(t)}return null}function js(){return Os??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),Os}function Ms(e){return/^(html|body|#document)$/.test(hs(e))}function Ns(e){return gs(e).getComputedStyle(e)}function Ps(e){return ys(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Fs(e){if(hs(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||xs(e)&&e.host||_s(e);return xs(t)?t.host:t}function Is(e){let t=Fs(e);return Ms(t)?(e.ownerDocument||e).body:bs(t)&&Ss(t)?t:Is(t)}function Ls(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=Is(e),i=r===e.ownerDocument?.body,a=gs(r);if(i){let e=Rs(a);return t.concat(a,a.visualViewport||[],Ss(r)?r:[],e&&n?Ls(e):[])}return t.concat(r,Ls(r,[],n))}function Rs(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function zs(e){let t=Ns(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=bs(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Oo(n)!==a||Oo(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function Bs(e){return ys(e)?e:e.contextElement}function Vs(e){let t=Bs(e);if(!bs(t))return Ao(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=zs(t),o=(a?Oo(n.width):n.width)/r,s=(a?Oo(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var Hs=Ao(0);function Us(e){let t=gs(e);return!js()||!t.visualViewport?Hs:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Ws(e,t,n){return t===void 0&&(t=!1),!!n&&t&&n===gs(e)}function Gs(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=Bs(e),o=Ao(1);t&&(r?ys(r)&&(o=Vs(r)):o=Vs(e));let s=Ws(a,n,r)?Us(a):Ao(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=gs(a),t=ys(r)?gs(r):r,n=e,i=Rs(n);for(;i&&t!==n;){let e=Vs(i),t=i.getBoundingClientRect(),r=Ns(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=gs(i),i=Rs(n)}}return Qo({width:u,height:d,x:c,y:l})}function Ks(e,t){let n=Ps(e).scrollLeft;return t?t.left+n:Gs(_s(e)).left+n}function qs(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Ks(e,n),y:n.top+t.scrollTop}}function Js(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=_s(r),s=t?ws(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=Ao(1),u=Ao(0),d=bs(r);if((d||!a)&&((hs(r)!==`body`||Ss(o))&&(c=Ps(r)),d)){let e=Gs(r);l=Vs(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?qs(o,c):Ao(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 Ys(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function Xs(e){let t=Ps(e),n=e.ownerDocument.body,r=Do(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=Do(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),a=-t.scrollLeft+Ks(e),o=-t.scrollTop;return Ns(n).direction===`rtl`&&(a+=Do(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:a,y:o}}var Zs=25;function Qs(e,t,n){n===void 0&&(n=`viewport`);let r=n===`layoutViewport`,i=gs(e),a=_s(e),o=i.visualViewport,s=a.clientWidth,c=a.clientHeight,l=0,u=0;if(o){let e=!js()||t===`fixed`;r?e||(l=-o.offsetLeft,u=-o.offsetTop):(s=o.width,c=o.height,e&&(l=o.offsetLeft,u=o.offsetTop))}if(Ks(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<=Zs&&(s-=o)}return{width:s,height:c,x:l,y:u}}function $s(e,t){let n=Gs(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Vs(e);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function ec(e,t,n){let r;if(t===`viewport`||t===`layoutViewport`)r=Qs(e,n,t);else if(t===`document`)r=Xs(_s(e));else if(ys(t))r=$s(t,n);else{let n=Us(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Qo(r)}function tc(e,t){let n=t.get(e);if(n)return n;let r=Ls(e,[],!1).filter(e=>ys(e)&&hs(e)!==`body`),i=null,a=Ns(e).position===`fixed`,o=a?Fs(e):e;for(;ys(o)&&!Ms(o);){let e=Ns(o),t=ks(o),n=i?i.position:a?`fixed`:``;!t&&(n===`fixed`||n===`absolute`&&e.position===`static`)?r=r.filter(e=>e!==o):i=e,o=Fs(o)}return t.set(e,r),r}function nc(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?ws(t)?[]:tc(t,this._c):[].concat(n),r],o=ec(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=ec(t,a[e],i);s=Do(n.top,s),c=Eo(n.right,c),l=Eo(n.bottom,l),u=Do(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function rc(e){let{width:t,height:n}=zs(e);return{width:t,height:n}}function ic(e,t,n){let r=bs(t),i=_s(t),a=n===`fixed`,o=Gs(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=Ao(0);if((r||!a)&&((hs(t)!==`body`||Ss(i))&&(s=Ps(t)),r)){let e=Gs(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}!r&&i&&(c.x=Ks(i));let l=i&&!r&&!a?qs(i,s):Ao(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 ac(e){return Ns(e).position===`static`}function oc(e,t){if(!bs(e)||Ns(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return _s(e)===n&&(n=n.ownerDocument.body),n}function sc(e,t){let n=gs(e);if(ws(e))return n;if(!bs(e)){let t=Fs(e);for(;t&&!Ms(t);){if(ys(t)&&!ac(t))return t;t=Fs(t)}return n}let r=oc(e,t);for(;r&&Cs(r)&&ac(r);)r=oc(r,t);return r&&Ms(r)&&ac(r)&&!ks(r)?n:r||As(e)||n}var cc=async function(e){let t=this.getOffsetParent||sc,n=this.getDimensions,r=await n(e.floating);return{reference:ic(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function lc(e){return Ns(e).direction===`rtl`}var uc={convertOffsetParentRelativeRectToViewportRelativeRect:Js,getDocumentElement:_s,getClippingRect:nc,getOffsetParent:sc,getElementRects:cc,getClientRects:Ys,getDimensions:rc,getScale:Vs,isElement:ys,isRTL:lc};function dc(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function fc(e,t,n){let r=null,i,a=_s(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=ko(d),h=ko(a.clientWidth-(u+f)),g=ko(a.clientHeight-(d+p)),_=ko(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:Do(0,Eo(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(!dc(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=gs(e),l=()=>s(n);return c.addEventListener(`resize`,l),s(!0),()=>{c.removeEventListener(`resize`,l),o()}}function pc(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=Bs(e),u=i||a?[...l?Ls(l):[],...t?Ls(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n),a&&e.addEventListener(`resize`,n)});let d=l&&s?fc(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?Gs(e):null;c&&g();function g(){let t=Gs(e);h&&!dc(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 mc=us,hc=ds,gc=is,_c=ps,vc=ss,yc=rs,bc=fs,xc=(e,t,n)=>{let r=new Map,i=n??{},a={...uc,...i.platform,_c:r};return ns(e,t,{...i,platform:a})},Sc=typeof document<`u`?C.useLayoutEffect:function(){};function Cc(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(!Cc(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)&&!Cc(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function wc(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Tc(e,t){let n=wc(e);return Math.round(t*n)/n}function Ec(e){let t=C.useRef(e);return Sc(()=>{t.current=e}),t}function Dc(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]=C.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=C.useState(r);Cc(f,r)||p(r);let[m,h]=C.useState(null),[g,_]=C.useState(null),v=C.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=C.useCallback(e=>{e!==w.current&&(w.current=e,_(e))},[]),b=a||m,x=o||g,S=C.useRef(null),w=C.useRef(null),T=C.useRef(u),E=c!=null,D=Ec(c),O=Ec(i),ee=Ec(l),k=C.useCallback(()=>{if(!S.current||!w.current)return;let e={placement:t,strategy:n,middleware:f};O.current&&(e.platform=O.current),xc(S.current,w.current,e).then(e=>{let t={...e,isPositioned:ee.current!==!1};A.current&&!Cc(T.current,t)&&(T.current=t,pe.flushSync(()=>{d(t)}))})},[f,t,n,O,ee]);Sc(()=>{l===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let A=C.useRef(!1);Sc(()=>(A.current=!0,()=>{A.current=!1}),[]),Sc(()=>{if(b&&(S.current=b),x&&(w.current=x),b&&x){if(D.current)return D.current(b,x,k);k()}},[b,x,k,D,E]);let j=C.useMemo(()=>({reference:S,floating:w,setReference:v,setFloating:y}),[v,y]),M=C.useMemo(()=>({reference:b,floating:x}),[b,x]),te=C.useMemo(()=>{let e={position:n,left:0,top:0};if(!M.floating)return e;let t=Tc(M.floating,u.x),r=Tc(M.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...wc(M.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,M.floating,u.x,u.y]);return C.useMemo(()=>({...u,update:k,refs:j,elements:M,floatingStyles:te}),[u,k,j,M,te])}var Oc=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?{}:yc({element:r.current,padding:i}).fn(n):r?yc({element:r,padding:i}).fn(n):{}}}},kc=(e,t)=>{let n=mc(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ac=(e,t)=>{let n=hc(e);return{name:n.name,fn:n.fn,options:[e,t]}},jc=(e,t)=>({fn:bc(e).fn,options:[e,t]}),Mc=(e,t)=>{let n=gc(e);return{name:n.name,fn:n.fn,options:[e,t]}},Nc=(e,t)=>{let n=_c(e);return{name:n.name,fn:n.fn,options:[e,t]}},Pc=(e,t)=>{let n=vc(e);return{name:n.name,fn:n.fn,options:[e,t]}},Fc=(e,t)=>{let n=Oc(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ic=Object.defineProperty,Lc=(e,t)=>Ic(e,`name`,{value:t,configurable:!0});function Rc(e){let[t,n]=C.useState(void 0);return $i(()=>{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}Lc(Rc,`useSize`);var zc=Object.defineProperty,Bc=(e,t)=>zc(e,`name`,{value:t,configurable:!0}),Vc=`Popper`,[Hc,Uc]=Zi(Vc),[Wc,Gc]=Hc(Vc),Kc=Bc(e=>{let{__scopePopper:t,children:n}=e,[r,i]=C.useState(null),[a,o]=C.useState(void 0);return(0,G.jsx)(Wc,{scope:t,anchor:r,onAnchorChange:i,placementState:a,setPlacementState:o,children:n})},`Popper`),qc=`PopperAnchor`,Jc=C.forwardRef(Bc(function(e,t){let{__scopePopper:n,virtualRef:r,...i}=e,a=Gc(qc,n),o=C.useRef(null),s=a.onAnchorChange,c=wi(t,C.useCallback(e=>{o.current=e,e&&s(e)},[s])),l=C.useRef(null);C.useEffect(()=>{if(!r)return;let e=l.current;l.current=r.current,e!==l.current&&s(l.current)});let u=a.placementState&&tl(a.placementState),d=u?.[0],f=u?.[1];return r?null:(0,G.jsx)(ha.div,{"data-radix-popper-side":d,"data-radix-popper-align":f,...i,ref:c})},`PopperAnchor`)),Yc=`PopperContent`,[Xc,Zc]=Hc(Yc),Qc=C.forwardRef(Bc(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=Gc(Yc,n),[_,v]=C.useState(null),y=wi(t,v),[b,x]=C.useState(null),S=Rc(b),w=S?.width??0,T=S?.height??0,E=r+(a===`center`?``:`-`+a),D=typeof u==`number`?u:{top:0,right:0,bottom:0,left:0,...u},O=Array.isArray(l)?l:[l],ee=O.length>0,k={padding:D,boundary:O.filter($c),altBoundary:ee},{refs:A,floatingStyles:j,placement:M,isPositioned:te,middlewareData:N}=Dc({strategy:`fixed`,placement:E,whileElementsMounted:Bc((...e)=>pc(...e,{animationFrame:p===`always`}),`whileElementsMounted`),elements:{reference:g.anchor},middleware:[kc({mainAxis:i+T,alignmentAxis:o}),c&&Ac({mainAxis:!0,crossAxis:!1,limiter:d===`partial`?jc():void 0,...k}),c&&Mc({...k}),Nc({...k,apply:Bc(({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&&Fc({element:b,padding:s}),el({arrowWidth:w,arrowHeight:T}),f&&Pc({strategy:`referenceHidden`,...k,boundary:ee?k.boundary:void 0})]}),P=g.setPlacementState;$i(()=>(P(M),()=>{P(void 0)}),[M,P]);let[F,ne]=tl(M),re=Ia(m);$i(()=>{te&&re?.()},[te,re]);let ie=N.arrow?.x,I=N.arrow?.y,L=N.arrow?.centerOffset!==0,[R,ae]=C.useState();return $i(()=>{_&&ae(window.getComputedStyle(_).zIndex)},[_]),(0,G.jsx)(`div`,{ref:A.setFloating,"data-radix-popper-content-wrapper":``,style:{...j,transform:te?j.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:R,"--radix-popper-transform-origin":[N.transformOrigin?.x,N.transformOrigin?.y].join(` `),...N.hide?.referenceHidden&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,G.jsx)(Xc,{scope:n,placedSide:F,placedAlign:ne,onArrowChange:x,arrowX:ie,arrowY:I,shouldHideArrow:L,children:(0,G.jsx)(ha.div,{"data-side":F,"data-align":ne,...h,ref:y,style:{...h.style,animation:te?h.style?.animation:`none`}})})})},`PopperContent`));function $c(e){return e!==null}Bc($c,`isNotNull`);var el=Bc(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]=tl(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 tl(e){let[t,n=`center`]=e.split(`-`);return[t,n]}Bc(tl,`getSideAndAlignFromPlacement`);var nl=Kc,rl=Jc,il=Qc,al=Object.defineProperty,ol=C.forwardRef(((e,t)=>al(e,`name`,{value:t,configurable:!0}))(function(e,t){let{container:n,...r}=e,[i,a]=C.useState(!1);$i(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?pe.createPortal((0,G.jsx)(ha.div,{...r,ref:t}),o):null},`Portal`)),sl=Object.defineProperty,cl=(e,t)=>sl(e,`name`,{value:t,configurable:!0});function ll(e,t){return C.useReducer((e,n)=>t[e][n]??e,e)}cl(ll,`useStateMachine`);var ul=cl(e=>{let{present:t,children:n}=e,r=dl(t),i=typeof n==`function`?n({present:r.isPresent}):C.Children.only(n),a=pl(r.ref,hl(i));return typeof n==`function`||r.isPresent?C.cloneElement(i,{ref:a}):null},`Presence`);function dl(e){let[t,n]=C.useState(),r=C.useRef(null),i=C.useRef(e),a=C.useRef(`none`),o=C.useRef(void 0),[s,c]=ll(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return C.useEffect(()=>{s===`mounted`?(a.current=o.current??ml(r.current),o.current=void 0):a.current=`none`},[s]),$i(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,s=ml(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]),$i(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=cl(a=>{let o=ml(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=cl(e=>{e.target===t&&(a.current=ml(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:C.useCallback(e=>{if(e){let t=getComputedStyle(e);r.current=t,o.current=ml(t)}else r.current=null;n(e)},[])}}cl(dl,`usePresence`);function fl(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}cl(fl,`setRef`);function pl(...e){let t=C.useRef(e);return t.current=e,C.useCallback(e=>{let n=t.current,r=!1,i=n.map(t=>{let n=fl(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():fl(n[e],null)}}},[])}cl(pl,`useStableComposedRefs`);function ml(e){return e?.animationName||`none`}cl(ml,`getAnimationName`);function hl(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)}cl(hl,`getElementRef`);var gl=Object.defineProperty,_l=(e,t)=>gl(e,`name`,{value:t,configurable:!0}),vl=!1;function yl(){let[e,t]=C.useState(vl);return C.useEffect(()=>{vl||(vl=!0,t(!0))},[]),e}_l(yl,`useIsHydrated`);var bl=C.useSyncExternalStore;function xl(){return()=>{}}_l(xl,`subscribe`);function Sl(){return bl(xl,()=>!0,()=>!1)}_l(Sl,`useIsHydratedModern`);var Cl=typeof bl==`function`?Sl:yl,wl=Object.defineProperty,Tl=(e,t)=>wl(e,`name`,{value:t,configurable:!0}),El=`rovingFocusGroup.onEntryFocus`,Dl={bubbles:!1,cancelable:!0},Ol=`RovingFocusGroup`,[kl,Al,jl]=ya(Ol),[Ml,Nl]=Zi(Ol,[jl]),[Pl,Fl]=Ml(Ol),Il=C.forwardRef(Tl(function(e,t){return(0,G.jsx)(kl.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,G.jsx)(kl.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,G.jsx)(Ll,{...e,ref:t})})})},`RovingFocusGroup`)),Ll=C.forwardRef(Tl(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=C.useRef(null),p=wi(t,f),m=Na(a),[h,g]=ca({prop:o,defaultProp:s??null,onChange:c,caller:Ol}),[_,v]=C.useState(!1),y=Ia(l),b=Al(n),x=C.useRef(!1),[S,w]=C.useState(0);return C.useEffect(()=>{let e=f.current;if(e)return e.addEventListener(El,y),()=>e.removeEventListener(El,y)},[y]),(0,G.jsx)(Pl,{scope:n,orientation:r,dir:m,loop:i,currentTabStopId:h,onItemFocus:C.useCallback(e=>g(e),[g]),onItemShiftTab:C.useCallback(()=>v(!0),[]),onFocusableItemAdd:C.useCallback(()=>w(e=>e+1),[]),onFocusableItemRemove:C.useCallback(()=>w(e=>e-1),[]),children:(0,G.jsx)(ha.div,{tabIndex:_||S===0?-1:0,"data-orientation":r,...d,ref:p,style:{outline:`none`,...e.style},onMouseDown:J(e.onMouseDown,()=>{x.current=!0}),onFocus:J(e.onFocus,e=>{let t=!x.current;if(e.target===e.currentTarget&&t&&!_){let t=new CustomEvent(El,Dl);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=b().filter(e=>e.focusable);Ul([e.find(e=>e.active),e.find(e=>e.id===h),...e].filter(Boolean).map(e=>e.ref.current),u)}}x.current=!1}),onBlur:J(e.onBlur,()=>v(!1))})})},`RovingFocusGroupImpl`)),Rl=`RovingFocusGroupItem`,zl=C.forwardRef(Tl(function(e,t){let{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,children:o,...s}=e,c=wo(),l=a||c,u=Fl(Rl,n),d=u.currentTabStopId===l,f=Al(n),{onFocusableItemAdd:p,onFocusableItemRemove:m,currentTabStopId:h}=u,g=Cl();return $i(()=>{if(g&&r)return p(),()=>m()},[g,r,p,m]),C.useEffect(()=>{if(!g&&r)return p(),()=>m()},[g,r,p,m]),(0,G.jsx)(kl.ItemSlot,{scope:n,id:l,focusable:r,active:i,children:(0,G.jsx)(ha.span,{tabIndex:d?0:-1,"data-orientation":u.orientation,...s,ref:t,onMouseDown:J(e.onMouseDown,e=>{r?u.onItemFocus(l):e.preventDefault()}),onFocus:J(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:J(e.onKeyDown,e=>{if(e.key===`Tab`&&e.shiftKey){u.onItemShiftTab();return}if(e.target!==e.currentTarget)return;let t=Hl(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?Wl(n,r+1):n.slice(r+1)}setTimeout(()=>Ul(n))}}),children:typeof o==`function`?o({isCurrentTabStop:d,hasTabStop:h!=null}):o})})},`RovingFocusGroupItem`)),Bl={ArrowLeft:`prev`,ArrowUp:`prev`,ArrowRight:`next`,ArrowDown:`next`,PageUp:`first`,Home:`first`,PageDown:`last`,End:`last`};function Vl(e,t){return t===`rtl`?e===`ArrowLeft`?`ArrowRight`:e===`ArrowRight`?`ArrowLeft`:e:e}Tl(Vl,`getDirectionAwareKey`);function Hl(e,t,n){let r=Vl(e.key,n);if(!(t===`vertical`&&[`ArrowLeft`,`ArrowRight`].includes(r))&&!(t===`horizontal`&&[`ArrowUp`,`ArrowDown`].includes(r)))return Bl[r]}Tl(Hl,`getFocusIntent`);function Ul(e,t=!1){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}Tl(Ul,`focusFirst`);function Wl(e,t){return e.map((n,r)=>e[(t+r)%e.length])}Tl(Wl,`wrapArray`);var Gl=Il,Kl=zl,ql=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},Jl=new WeakMap,Yl=new WeakMap,Xl={},Zl=0,Ql=function(e){return e&&(e.host||Ql(e.parentNode))},$l=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=Ql(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})},eu=function(e,t,n,r){var i=$l(t,Array.isArray(e)?e:[e]);Xl[n]||(Xl[n]=new WeakMap);var a=Xl[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=(Jl.get(e)||0)+1,l=(a.get(e)||0)+1;Jl.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Yl.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(),Zl++,function(){o.forEach(function(e){var t=Jl.get(e)-1,i=a.get(e)-1;Jl.set(e,t),a.set(e,i),t||(Yl.has(e)||e.removeAttribute(r),Yl.delete(e)),i||e.removeAttribute(n)}),Zl--,Zl||(Jl=new WeakMap,Jl=new WeakMap,Yl=new WeakMap,Xl={})}},tu=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||ql(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),eu(r,i,n,`aria-hidden`)):function(){return null}},nu=function(){return nu=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},nu.apply(this,arguments)};function ru(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 iu(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 au=`right-scroll-bar-position`,ou=`width-before-scroll-bar`,su=`with-scroll-bars-hidden`,cu=`--removed-body-scroll-bar-size`;function lu(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function uu(e,t){var n=(0,C.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 du=typeof window<`u`?C.useLayoutEffect:C.useEffect,fu=new WeakMap;function pu(e,t){var n=uu(t||null,function(t){return e.forEach(function(e){return lu(e,t)})});return du(function(){var t=fu.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||lu(e,null)}),i.forEach(function(e){r.has(e)||lu(e,a)})}fu.set(n,e)},[e]),n}function mu(e){return e}function hu(e,t){t===void 0&&(t=mu);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 gu(e){e===void 0&&(e={});var t=hu(null);return t.options=nu({async:!0,ssr:!1},e),t}var _u=function(e){var t=e.sideCar,n=ru(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 C.createElement(r,nu({},n))};_u.isSideCarExport=!0;function vu(e,t){return e.useMedium(t),_u}var yu=gu(),bu=function(){},xu=C.forwardRef(function(e,t){var n=C.useRef(null),r=C.useState({onScrollCapture:bu,onWheelCapture:bu,onTouchMoveCapture:bu}),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=ru(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),x=f,S=pu([n,t]),w=nu(nu({},b),i);return C.createElement(C.Fragment,null,u&&C.createElement(x,{sideCar:yu,removeScrollBar:l,shards:d,noRelative:p,noIsolation:m,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:y}),o?C.cloneElement(C.Children.only(s),nu(nu({},w),{ref:S})):C.createElement(v,nu({},w,{className:c,ref:S}),s))});xu.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},xu.classNames={fullWidth:ou,zeroRight:au};var Su=function(){if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function Cu(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=Su();return t&&e.setAttribute(`nonce`,t),e}function wu(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Tu(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var Eu=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Cu())&&(wu(t,n),Tu(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Du=function(){var e=Eu();return function(t,n){C.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Ou=function(){var e=Du();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},ku={left:0,top:0,right:0,gap:0},Au=function(e){return parseInt(e||``,10)||0},ju=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[Au(n),Au(r),Au(i)]},Mu=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return ku;var t=ju(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])}},Nu=Ou(),Pu=`data-scroll-locked`,Fu=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n=`margin`),`
|
|
13
|
+
.${su} {
|
|
14
|
+
overflow: hidden ${r};
|
|
15
|
+
padding-right: ${s}px ${r};
|
|
16
|
+
}
|
|
17
|
+
body[${Pu}] {
|
|
18
|
+
overflow: hidden ${r};
|
|
19
|
+
overscroll-behavior: contain;
|
|
20
|
+
${[t&&`position: relative ${r};`,n===`margin`&&`
|
|
21
|
+
padding-left: ${i}px;
|
|
22
|
+
padding-top: ${a}px;
|
|
23
|
+
padding-right: ${o}px;
|
|
24
|
+
margin-left:0;
|
|
25
|
+
margin-top:0;
|
|
26
|
+
margin-right: ${s}px ${r};
|
|
27
|
+
`,n===`padding`&&`padding-right: ${s}px ${r};`].filter(Boolean).join(``)}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.${au} {
|
|
31
|
+
right: ${s}px ${r};
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.${ou} {
|
|
35
|
+
margin-right: ${s}px ${r};
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.${au} .${au} {
|
|
39
|
+
right: 0 ${r};
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.${ou} .${ou} {
|
|
43
|
+
margin-right: 0 ${r};
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
body[${Pu}] {
|
|
47
|
+
${cu}: ${s}px;
|
|
48
|
+
}
|
|
49
|
+
`},Iu=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},Lu=function(){C.useEffect(function(){return document.body.setAttribute(Pu,(Iu()+1).toString()),function(){var e=Iu()-1;e<=0?document.body.removeAttribute(Pu):document.body.setAttribute(Pu,e.toString())}},[])},Ru=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;Lu();var a=C.useMemo(function(){return Mu(i)},[i]);return C.createElement(Nu,{styles:Fu(a,!t,i,n?``:`!important`)})},zu=!1;if(typeof window<`u`)try{var Bu=Object.defineProperty({},"passive",{get:function(){return zu=!0,!0}});window.addEventListener(`test`,Bu,Bu),window.removeEventListener(`test`,Bu,Bu)}catch{zu=!1}var Vu=zu?{passive:!1}:!1,Hu=function(e){return e.tagName===`TEXTAREA`},Uu=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!Hu(e)&&n[t]===`visible`)},Wu=function(e){return Uu(e,`overflowY`)},Gu=function(e){return Uu(e,`overflowX`)},Ku=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),Yu(e,r)){var i=Xu(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},qu=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},Ju=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},Yu=function(e,t){return e===`v`?Wu(t):Gu(t)},Xu=function(e,t){return e===`v`?qu(t):Ju(t)},Zu=function(e,t){return e===`h`&&t===`rtl`?-1:1},Qu=function(e,t,n,r,i){var a=Zu(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=Xu(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&Yu(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},$u=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ed=function(e){return[e.deltaX,e.deltaY]},td=function(e){return e&&`current`in e?e.current:e},nd=function(e,t){return e[0]===t[0]&&e[1]===t[1]},rd=function(e){return`
|
|
50
|
+
.block-interactivity-${e} {pointer-events: none;}
|
|
51
|
+
.allow-interactivity-${e} {pointer-events: all;}
|
|
52
|
+
`},id=0,ad=[];function od(e){var t=C.useRef([]),n=C.useRef([0,0]),r=C.useRef(),i=C.useState(id++)[0],a=C.useState(Ou)[0],o=C.useRef(e);C.useEffect(function(){o.current=e},[e]),C.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=iu([e.lockRef.current],(e.shards||[]).map(td),!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=C.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=$u(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=Ku(d,u);if(!m)return!0;if(m?l=d:(l=d===`v`?`h`:`v`,m=Ku(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 Qu(h,t,e,h===`h`?s:c,!0)},[]),c=C.useCallback(function(e){var n=e;if(ad.length&&ad[ad.length-1]===a){var r=`deltaY`in n?ed(n):$u(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&nd(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var c=(o.current.shards||[]).map(td).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=C.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:sd(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),u=C.useCallback(function(e){n.current=$u(e),r.current=void 0},[]),d=C.useCallback(function(t){l(t.type,ed(t),t.target,s(t,e.lockRef.current))},[]),f=C.useCallback(function(t){l(t.type,$u(t),t.target,s(t,e.lockRef.current))},[]);C.useEffect(function(){return ad.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener(`wheel`,c,Vu),document.addEventListener(`touchmove`,c,Vu),document.addEventListener(`touchstart`,u,Vu),function(){ad=ad.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,c,Vu),document.removeEventListener(`touchmove`,c,Vu),document.removeEventListener(`touchstart`,u,Vu)}},[]);var p=e.removeScrollBar,m=e.inert;return C.createElement(C.Fragment,null,m?C.createElement(a,{styles:rd(i)}):null,p?C.createElement(Ru,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function sd(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var cd=vu(yu,od),ld=C.forwardRef(function(e,t){return C.createElement(xu,nu({},e,{ref:t,sideCar:cd}))});ld.classNames=xu.classNames;var ud=Object.defineProperty,dd=(e,t)=>ud(e,`name`,{value:t,configurable:!0}),fd=[`Enter`,` `],pd=[`ArrowDown`,`PageUp`,`Home`],md=[`ArrowUp`,`PageDown`,`End`],hd=[...pd,...md],gd={ltr:[...fd,`ArrowRight`],rtl:[...fd,`ArrowLeft`]},_d={ltr:[`ArrowLeft`],rtl:[`ArrowRight`]},vd=`Menu`,[yd,bd,xd]=ya(vd),[Sd,Cd]=Zi(vd,[xd,Uc,Nl]),wd=Uc(),Td=Nl(),[Ed,Dd]=Sd(vd),[Od,kd]=Sd(vd),Ad=dd(e=>{let{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:a,modal:o=!0}=e,s=wd(t),[c,l]=C.useState(null),u=C.useRef(!1),d=Ia(a),f=Na(i);return C.useEffect(()=>{let e=dd(()=>{u.current=!0,document.addEventListener(`pointerdown`,t,{capture:!0,once:!0}),document.addEventListener(`pointermove`,t,{capture:!0,once:!0})},`handleKeyDown`),t=dd(()=>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})}},[]),C.useEffect(()=>{if(!n)return;let e=dd(()=>d(!1),`handleBlur`);return window.addEventListener(`blur`,e),()=>window.removeEventListener(`blur`,e)},[n,d]),(0,G.jsx)(nl,{...s,children:(0,G.jsx)(Ed,{scope:t,open:n,onOpenChange:d,content:c,onContentChange:l,children:(0,G.jsx)(Od,{scope:t,onClose:C.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:u,dir:f,modal:o,children:r})})})},`Menu`),jd=C.forwardRef(dd(function(e,t){let{__scopeMenu:n,...r}=e,i=wd(n);return(0,G.jsx)(rl,{...i,...r,ref:t})},`MenuAnchor`)),Md=`MenuPortal`,[Nd,Pd]=Sd(Md,{forceMount:void 0}),Fd=dd(e=>{let{__scopeMenu:t,forceMount:n,children:r,container:i}=e,a=Dd(Md,t);return(0,G.jsx)(Nd,{scope:t,forceMount:n,children:(0,G.jsx)(ul,{present:n||a.open,children:(0,G.jsx)(ol,{asChild:!0,container:i,children:r})})})},`MenuPortal`),Id=`MenuContent`,[Ld,Rd]=Sd(Id),zd=C.forwardRef(dd(function(e,t){let n=Pd(Id,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=Dd(Id,e.__scopeMenu),o=kd(Id,e.__scopeMenu);return(0,G.jsx)(yd.Provider,{scope:e.__scopeMenu,children:(0,G.jsx)(ul,{present:r||a.open,children:(0,G.jsx)(yd.Slot,{scope:e.__scopeMenu,children:o.modal?(0,G.jsx)(Bd,{...i,ref:t}):(0,G.jsx)(Vd,{...i,ref:t})})})})},`MenuContent`)),Bd=C.forwardRef(dd(function(e,t){let n=Dd(Id,e.__scopeMenu),r=C.useRef(null),i=wi(t,r);return C.useEffect(()=>{let e=r.current;if(e)return tu(e)},[]),(0,G.jsx)(Ud,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:J(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})},`MenuRootContentModal`)),Vd=C.forwardRef(dd(function(e,t){let n=Dd(Id,e.__scopeMenu);return(0,G.jsx)(Ud,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})},`MenuRootContentNonModal`)),Hd=Di(`MenuContent.ScrollLock`),Ud=C.forwardRef(dd(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=Dd(Id,n),_=kd(Id,n),v=wd(n),y=Td(n),b=bd(n),[x,S]=C.useState(null),w=C.useRef(null),T=wi(t,w,g.onContentChange),E=C.useRef(0),D=C.useRef(``),O=C.useRef(0),ee=C.useRef(null),k=C.useRef(`right`),A=C.useRef(0),j=m?ld:C.Fragment,M=m?{as:Hd,allowPinchZoom:!0}:void 0,te=dd(e=>{let t=D.current+e,n=b().filter(e=>!e.disabled),r=document.activeElement,i=n.find(e=>e.ref.current===r)?.textValue,a=xf(n.map(e=>e.textValue),t,i),o=n.find(e=>e.textValue===a)?.ref.current;dd((function e(t){D.current=t,window.clearTimeout(E.current),t!==``&&(E.current=window.setTimeout(()=>e(``),1e3))}),`updateSearch`)(t),o&&setTimeout(()=>o.focus())},`handleTypeaheadSearch`);C.useEffect(()=>()=>window.clearTimeout(E.current),[]),no();let N=C.useCallback(e=>k.current===ee.current?.side&&Cf(e,ee.current?.area),[]);return(0,G.jsx)(Ld,{scope:n,searchRef:D,onItemEnter:C.useCallback(e=>{N(e)&&e.preventDefault()},[N]),onItemLeave:C.useCallback(e=>{N(e)||(w.current?.focus(),S(null))},[N]),onTriggerLeave:C.useCallback(e=>{N(e)&&e.preventDefault()},[N]),pointerGraceTimerRef:O,onPointerGraceIntentChange:C.useCallback(e=>{ee.current=e},[]),children:(0,G.jsx)(j,{...M,children:(0,G.jsx)(so,{asChild:!0,trapped:i,onMountAutoFocus:J(a,e=>{e.preventDefault(),w.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:(0,G.jsx)(Wa,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,children:(0,G.jsx)(Gl,{asChild:!0,...y,dir:_.dir,orientation:`vertical`,loop:r,currentTabStopId:x,onCurrentTabStopIdChange:S,onEntryFocus:J(c,e=>{_.isUsingKeyboardRef.current||e.preventDefault()}),preventScrollOnEntryFocus:!0,children:(0,G.jsx)(il,{role:`menu`,"aria-orientation":`vertical`,"data-state":gf(g.open),"data-radix-menu-content":``,dir:_.dir,...v,...h,ref:T,style:{outline:`none`,...h.style},onKeyDown:J(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&&te(e.key));let i=w.current;if(e.target!==i||!hd.includes(e.key))return;e.preventDefault();let a=b().filter(e=>!e.disabled).map(e=>e.ref.current);md.includes(e.key)&&a.reverse(),yf(a)}),onBlur:J(e.onBlur,e=>{e.currentTarget.contains(e.target)||(window.clearTimeout(E.current),D.current=``)}),onPointerMove:J(e.onPointerMove,wf(e=>{let t=e.target,n=A.current!==e.clientX;if(e.currentTarget.contains(t)&&n){let t=e.clientX>A.current?`right`:`left`;k.current=t,A.current=e.clientX}}))})})})})})})},`MenuContentImpl`)),Wd=C.forwardRef(dd(function(e,t){let{__scopeMenu:n,...r}=e;return(0,G.jsx)(ha.div,{role:`group`,...r,ref:t})},`MenuGroup`)),Gd=C.forwardRef(dd(function(e,t){let{__scopeMenu:n,...r}=e;return(0,G.jsx)(ha.div,{...r,ref:t})},`MenuLabel`)),Kd=`MenuItem`,qd=`menu.itemSelect`,Jd=C.forwardRef(dd(function(e,t){let{disabled:n=!1,onSelect:r,...i}=e,a=C.useRef(null),o=kd(Kd,e.__scopeMenu),s=Rd(Kd,e.__scopeMenu),c=wi(t,a),l=C.useRef(!1),u=dd(()=>{let e=a.current;if(!n&&e){let t=new CustomEvent(qd,{bubbles:!0,cancelable:!0});e.addEventListener(qd,e=>r?.(e),{once:!0}),ga(e,t),t.defaultPrevented?l.current=!1:o.onClose()}},`handleSelect`);return(0,G.jsx)(Yd,{...i,ref:c,disabled:n,onClick:J(e.onClick,u),onPointerDown:t=>{e.onPointerDown?.(t),l.current=!0},onPointerUp:J(e.onPointerUp,e=>{l.current||e.currentTarget?.click()}),onKeyDown:J(e.onKeyDown,e=>{n||e.target!==e.currentTarget||(s.searchRef.current===``||e.key!==` `)&&fd.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())})})},`MenuItem`)),Yd=C.forwardRef(dd(function(e,t){let{__scopeMenu:n,disabled:r=!1,textValue:i,...a}=e,o=Rd(Kd,n),s=Td(n),c=C.useRef(null),l=wi(t,c),[u,d]=C.useState(!1),[f,p]=C.useState(``);return C.useEffect(()=>{let e=c.current;e&&p((e.textContent??``).trim())},[a.children]),(0,G.jsx)(yd.ItemSlot,{scope:n,disabled:r,textValue:i??f,children:(0,G.jsx)(Kl,{asChild:!0,...s,focusable:!r,children:(0,G.jsx)(ha.div,{role:`menuitem`,"data-highlighted":u?``:void 0,"aria-disabled":r||void 0,"data-disabled":r?``:void 0,...a,ref:l,onPointerMove:J(e.onPointerMove,wf(e=>{r?o.onItemLeave(e):(o.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:J(e.onPointerLeave,wf(e=>o.onItemLeave(e))),onFocus:J(e.onFocus,()=>d(!0)),onBlur:J(e.onBlur,()=>d(!1))})})})},`MenuItemImpl`)),Xd=C.forwardRef(dd(function(e,t){let{checked:n=!1,onCheckedChange:r,...i}=e;return(0,G.jsx)(rf,{scope:e.__scopeMenu,checked:n,children:(0,G.jsx)(Jd,{role:`menuitemcheckbox`,"aria-checked":_f(n)?`mixed`:n,...i,ref:t,"data-state":vf(n),onSelect:J(i.onSelect,()=>r?.(_f(n)?!0:!n),{checkForDefaultPrevented:!1})})})},`MenuCheckboxItem`)),[Zd,Qd]=Sd(`MenuRadioGroup`,{value:void 0,onValueChange:dd(()=>{},`onValueChange`)}),$d=C.forwardRef(dd(function(e,t){let{value:n,onValueChange:r,...i}=e,a=Ia(r);return(0,G.jsx)(Zd,{scope:e.__scopeMenu,value:n,onValueChange:a,children:(0,G.jsx)(Wd,{...i,ref:t})})},`MenuRadioGroup`)),ef=`MenuRadioItem`,tf=C.forwardRef(dd(function(e,t){let{value:n,...r}=e,i=Qd(ef,e.__scopeMenu),a=n===i.value;return(0,G.jsx)(rf,{scope:e.__scopeMenu,checked:a,children:(0,G.jsx)(Jd,{role:`menuitemradio`,"aria-checked":a,...r,ref:t,"data-state":vf(a),onSelect:J(r.onSelect,()=>i.onValueChange?.(n),{checkForDefaultPrevented:!1})})})},`MenuRadioItem`)),nf=`MenuItemIndicator`,[rf,af]=Sd(nf,{checked:!1}),of=C.forwardRef(dd(function(e,t){let{__scopeMenu:n,forceMount:r,...i}=e,a=af(nf,n);return(0,G.jsx)(ul,{present:r||_f(a.checked)||a.checked===!0,children:(0,G.jsx)(ha.span,{...i,ref:t,"data-state":vf(a.checked)})})},`MenuItemIndicator`)),sf=C.forwardRef(dd(function(e,t){let{__scopeMenu:n,...r}=e;return(0,G.jsx)(ha.div,{role:`separator`,"aria-orientation":`horizontal`,...r,ref:t})},`MenuSeparator`)),cf=`MenuSub`,[lf,uf]=Sd(cf),df=dd(e=>{let{__scopeMenu:t,children:n,open:r=!1,onOpenChange:i}=e,a=Dd(cf,t),o=wd(t),[s,c]=C.useState(null),[l,u]=C.useState(null),d=Ia(i);return C.useEffect(()=>(a.open===!1&&d(!1),()=>d(!1)),[a.open,d]),(0,G.jsx)(nl,{...o,children:(0,G.jsx)(Ed,{scope:t,open:r,onOpenChange:d,content:l,onContentChange:u,children:(0,G.jsx)(lf,{scope:t,contentId:wo(),triggerId:wo(),trigger:s,onTriggerChange:c,children:n})})})},`MenuSub`),ff=`MenuSubTrigger`,pf=C.forwardRef(dd(function(e,t){let n=Dd(ff,e.__scopeMenu),r=kd(ff,e.__scopeMenu),i=uf(ff,e.__scopeMenu),a=Rd(ff,e.__scopeMenu),o=C.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:c}=a,l={__scopeMenu:e.__scopeMenu},u=C.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);C.useEffect(()=>u,[u]),C.useEffect(()=>{let e=s.current;return()=>{window.clearTimeout(e),c(null)}},[s,c]);let d=wi(t,i.onTriggerChange);return(0,G.jsx)(jd,{asChild:!0,...l,children:(0,G.jsx)(Yd,{id:i.triggerId,"aria-haspopup":`menu`,"aria-expanded":n.open,"aria-controls":n.open?i.contentId:void 0,"data-state":gf(n.open),...e,ref:d,onClick:t=>{e.onClick?.(t),!(e.disabled||t.defaultPrevented)&&(t.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:J(e.onPointerMove,wf(t=>{a.onItemEnter(t),!t.defaultPrevented&&!e.disabled&&!n.open&&!o.current&&(a.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{n.onOpenChange(!0),u()},100))})),onPointerLeave:J(e.onPointerLeave,wf(e=>{u();let t=n.content?.getBoundingClientRect();if(t){let r=n.content?.dataset.side,i=r===`right`,o=i?-5:5,c=t[i?`left`:`right`],l=t[i?`right`:`left`];a.onPointerGraceIntentChange({area:[{x:e.clientX+o,y:e.clientY},{x:c,y:t.top},{x:l,y:t.top},{x:l,y:t.bottom},{x:c,y:t.bottom}],side:r}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(e),e.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:J(e.onKeyDown,t=>{e.disabled||t.target!==t.currentTarget||(a.searchRef.current===``||t.key!==` `)&&gd[r.dir].includes(t.key)&&(n.onOpenChange(!0),n.content?.focus(),t.preventDefault())})})})},`MenuSubTrigger`)),mf=`MenuSubContent`,hf=C.forwardRef(dd(function(e,t){let n=Pd(Id,e.__scopeMenu),{forceMount:r=n.forceMount,align:i=`start`,...a}=e,o=Dd(Id,e.__scopeMenu),s=kd(Id,e.__scopeMenu),c=uf(mf,e.__scopeMenu),l=C.useRef(null),u=wi(t,l);return(0,G.jsx)(yd.Provider,{scope:e.__scopeMenu,children:(0,G.jsx)(ul,{present:r||o.open,children:(0,G.jsx)(yd.Slot,{scope:e.__scopeMenu,children:(0,G.jsx)(Ud,{id:c.contentId,"aria-labelledby":c.triggerId,...a,ref:u,align:i,side:s.dir===`rtl`?`left`:`right`,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:e=>{s.isUsingKeyboardRef.current&&l.current?.focus(),e.preventDefault()},onCloseAutoFocus:e=>e.preventDefault(),onFocusOutside:J(e.onFocusOutside,e=>{e.target!==c.trigger&&o.onOpenChange(!1)}),onEscapeKeyDown:J(e.onEscapeKeyDown,e=>{s.onClose(),e.preventDefault()}),onKeyDown:J(e.onKeyDown,e=>{let t=e.currentTarget.contains(e.target),n=_d[s.dir].includes(e.key);t&&n&&(o.onOpenChange(!1),c.trigger?.focus(),e.preventDefault())})})})})})},`MenuSubContent`));function gf(e){return e?`open`:`closed`}dd(gf,`getOpenState`);function _f(e){return e===`indeterminate`}dd(_f,`isIndeterminate`);function vf(e){return _f(e)?`indeterminate`:e?`checked`:`unchecked`}dd(vf,`getCheckedState`);function yf(e){let t=document.activeElement;for(let n of e)if(n===t||(n.focus(),document.activeElement!==t))return}dd(yf,`focusFirst`);function bf(e,t){return e.map((n,r)=>e[(t+r)%e.length])}dd(bf,`wrapArray`);function xf(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=bf(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}dd(xf,`getNextMatch`);function Sf(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}dd(Sf,`isPointInPolygon`);function Cf(e,t){return t?Sf({x:e.clientX,y:e.clientY},t):!1}dd(Cf,`isPointerInGraceArea`);function wf(e){return t=>t.pointerType===`mouse`?e(t):void 0}dd(wf,`whenMouse`);var Tf=Ad,Ef=jd,Df=Fd,Of=zd,kf=Gd,Af=Jd,jf=Xd,Mf=$d,Nf=tf,Pf=of,Ff=sf,If=df,Lf=pf,Rf=hf,zf=Object.defineProperty,Bf=(e,t)=>zf(e,`name`,{value:t,configurable:!0}),Vf=`DropdownMenu`,[Hf,Uf]=Zi(Vf,[Cd]),Wf=Cd(),[Gf,Kf]=Hf(Vf),qf=Bf(e=>{let{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=e,c=Wf(t),l=C.useRef(null),[u,d]=ca({prop:i,defaultProp:a??!1,onChange:o,caller:Vf});return(0,G.jsx)(Gf,{scope:t,triggerId:wo(),triggerRef:l,contentId:wo(),open:u,onOpenChange:d,onOpenToggle:C.useCallback(()=>d(e=>!e),[d]),modal:s,children:(0,G.jsx)(Tf,{...c,open:u,onOpenChange:d,dir:r,modal:s,children:n})})},`DropdownMenu`),Jf=`DropdownMenuTrigger`,Yf=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,a=Kf(Jf,n),o=Wf(n),s=wi(t,a.triggerRef);return(0,G.jsx)(Ef,{asChild:!0,...o,children:(0,G.jsx)(ha.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:J(e.onPointerDown,e=>{!r&&e.button===0&&e.ctrlKey===!1&&(a.onOpenToggle(),a.open||e.preventDefault())}),onKeyDown:J(e.onKeyDown,e=>{r||([`Enter`,` `].includes(e.key)&&a.onOpenToggle(),e.key===`ArrowDown`&&a.onOpenChange(!0),[`Enter`,` `,`ArrowDown`].includes(e.key)&&e.preventDefault())})})})},`DropdownMenuTrigger`)),Xf=Bf(e=>{let{__scopeDropdownMenu:t,...n}=e,r=Wf(t);return(0,G.jsx)(Df,{...r,...n})},`DropdownMenuPortal`),Zf=`DropdownMenuContent`,Qf=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Kf(Zf,n),a=Wf(n),o=C.useRef(!1);return(0,G.jsx)(Of,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...r,ref:t,onCloseAutoFocus:J(e.onCloseAutoFocus,e=>{o.current||i.triggerRef.current?.focus(),o.current=!1,e.preventDefault()}),onInteractOutside:J(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`)),$f=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(kf,{...i,...r,ref:t})},`DropdownMenuLabel`)),ep=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Af,{...i,...r,ref:t})},`DropdownMenuItem`)),tp=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(jf,{...i,...r,ref:t})},`DropdownMenuCheckboxItem`)),np=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Mf,{...i,...r,ref:t})},`DropdownMenuRadioGroup`)),rp=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Nf,{...i,...r,ref:t})},`DropdownMenuRadioItem`)),ip=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Pf,{...i,...r,ref:t})},`DropdownMenuItemIndicator`)),ap=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Ff,{...i,...r,ref:t})},`DropdownMenuSeparator`)),op=Bf(e=>{let{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:i,defaultOpen:a}=e,o=Wf(t),[s,c]=ca({prop:r,defaultProp:a??!1,onChange:i,caller:`DropdownMenuSub`});return(0,G.jsx)(If,{...o,open:s,onOpenChange:c,children:n})},`DropdownMenuSub`),sp=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Lf,{...i,...r,ref:t})},`DropdownMenuSubTrigger`)),cp=C.forwardRef(Bf(function(e,t){let{__scopeDropdownMenu:n,...r}=e,i=Wf(n);return(0,G.jsx)(Rf,{...i,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":`var(--radix-popper-transform-origin)`,"--radix-dropdown-menu-content-available-width":`var(--radix-popper-available-width)`,"--radix-dropdown-menu-content-available-height":`var(--radix-popper-available-height)`,"--radix-dropdown-menu-trigger-width":`var(--radix-popper-anchor-width)`,"--radix-dropdown-menu-trigger-height":`var(--radix-popper-anchor-height)`}})},`DropdownMenuSubContent`)),lp=qf,up=Yf,dp=Xf,fp=Qf,pp=$f,mp=ep,hp=tp,gp=np,_p=rp,vp=ip,yp=ap,bp=op,xp=sp,Sp=cp;function Cp(e){return(0,G.jsx)(lp,{"data-slot":`dropdown-menu`,...e})}function wp(e){return(0,G.jsx)(up,{"data-slot":`dropdown-menu-trigger`,...e})}function Tp({className:e,sideOffset:t=4,...n}){return(0,G.jsx)(dp,{children:(0,G.jsx)(fp,{"data-slot":`dropdown-menu-content`,sideOffset:t,className:W(`bg-popover text-popover-foreground z-50 max-h-[var(--radix-dropdown-menu-content-available-height,70vh)] min-w-40 overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md`,e),...n})})}function Ep({className:e,...t}){return(0,G.jsx)(pp,{"data-slot":`dropdown-menu-label`,className:W(`text-muted-foreground px-2 py-1.5 text-[11px] font-medium`,e),...t})}function Dp({className:e,...t}){return(0,G.jsx)(mp,{"data-slot":`dropdown-menu-item`,className:W(`focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-[13px] outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-50`,e),...t})}function Op({className:e,children:t,...n}){return(0,G.jsxs)(hp,{"data-slot":`dropdown-menu-checkbox-item`,className:W(`focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-[13px] outline-none select-none`,e),...n,children:[(0,G.jsx)(`span`,{className:`absolute left-2 flex size-3.5 items-center justify-center`,children:(0,G.jsx)(vp,{children:(0,G.jsx)(A,{className:`size-3.5`})})}),t]})}function kp(e){return(0,G.jsx)(gp,{"data-slot":`dropdown-menu-radio-group`,...e})}function Ap({className:e,children:t,...n}){return(0,G.jsxs)(_p,{"data-slot":`dropdown-menu-radio-item`,className:W(`focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-[13px] outline-none select-none`,e),...n,children:[(0,G.jsx)(`span`,{className:`absolute left-2 flex size-3.5 items-center justify-center`,children:(0,G.jsx)(vp,{children:(0,G.jsx)(A,{className:`size-3.5`})})}),t]})}function jp({className:e,...t}){return(0,G.jsx)(yp,{"data-slot":`dropdown-menu-separator`,className:W(`bg-border -mx-1 my-1 h-px`,e),...t})}function Mp(e){return(0,G.jsx)(bp,{"data-slot":`dropdown-menu-sub`,...e})}function Np({className:e,children:t,...n}){return(0,G.jsxs)(xp,{"data-slot":`dropdown-menu-sub-trigger`,className:W(`focus:bg-accent focus:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-[13px] outline-none select-none`,e),...n,children:[t,(0,G.jsx)(te,{className:`ml-auto size-3.5`})]})}function Pp({className:e,...t}){return(0,G.jsx)(Sp,{"data-slot":`dropdown-menu-sub-content`,className:W(`bg-popover text-popover-foreground z-50 min-w-32 overflow-hidden rounded-md border p-1 shadow-md`,e),...t})}var Fp=mi(`group/marker relative flex min-h-4 w-full items-center gap-2 text-left text-sm text-muted-foreground [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:``,separator:`before:mr-1 before:h-px before:min-w-0 before:flex-1 before:bg-border after:ml-1 after:h-px after:min-w-0 after:flex-1 after:bg-border`,border:`border-b border-border pb-2`}},defaultVariants:{variant:`default`}});function Ip({className:e,variant:t=`default`,...n}){return(0,G.jsx)(`div`,{"data-slot":`marker`,"data-variant":t,className:W(Fp({variant:t}),e),...n})}function Lp({className:e,...t}){return(0,G.jsx)(`span`,{"data-slot":`marker-icon`,"aria-hidden":`true`,className:W(`size-4 shrink-0 [&_svg:not([class*='size-'])]:size-4`,e),...t})}function Rp({className:e,...t}){return(0,G.jsx)(`span`,{"data-slot":`marker-content`,className:W(`min-w-0 wrap-break-word group-data-[variant=separator]/marker:flex-none`,e),...t})}function zp({className:e,align:t=`start`,...n}){return(0,G.jsx)(`div`,{"data-slot":`message`,"data-align":t,className:W(`group/message relative flex w-full min-w-0 gap-2 text-sm data-[align=end]:flex-row-reverse`,e),...n})}function Bp({className:e,...t}){return(0,G.jsx)(`div`,{"data-slot":`message-content`,className:W(`flex min-w-0 max-w-[85%] flex-col gap-1 wrap-break-word group-data-[align=end]/message:items-end`,e),...t})}function Vp({className:e,...t}){return(0,G.jsx)(`div`,{"data-slot":`message-footer`,className:W(`text-muted-foreground flex max-w-full min-w-0 items-center text-xs font-medium group-data-[align=end]/message:justify-end`,e),...t})}function Hp(e,t){let n=getComputedStyle(e);return t*parseFloat(n.fontSize)}function Up(e,t){let n=getComputedStyle(e.ownerDocument.documentElement);return t*parseFloat(n.fontSize)}function Wp(e){return e/100*window.innerHeight}function Gp(e){return e/100*window.innerWidth}function Kp(e){switch(typeof e){case`number`:return[e,`px`];case`string`:{let t=parseFloat(e);return e.endsWith(`%`)?[t,`%`]:e.endsWith(`px`)?[t,`px`]:e.endsWith(`rem`)?[t,`rem`]:e.endsWith(`em`)?[t,`em`]:e.endsWith(`vh`)?[t,`vh`]:e.endsWith(`vw`)?[t,`vw`]:[t,`%`]}}}function qp({groupSize:e,panelElement:t,styleProp:n}){let r,[i,a]=Kp(n);switch(a){case`%`:r=i/100*e;break;case`px`:r=i;break;case`rem`:r=Up(t,i);break;case`em`:r=Hp(t,i);break;case`vh`:r=Wp(i);break;case`vw`:r=Gp(i)}return r}function Jp(e){return parseFloat(e.toFixed(3))}function Yp({group:e}){let{orientation:t,panels:n}=e;return n.reduce((e,n)=>(e+=t===`horizontal`?n.element.offsetWidth:n.element.offsetHeight,e),0)}function Xp(e){let{panels:t}=e,n=Yp({group:e});return n===0?t.map(e=>({groupResizeBehavior:e.panelConstraints.groupResizeBehavior,collapsedSize:0,collapsible:e.panelConstraints.collapsible===!0,defaultSize:void 0,disabled:e.panelConstraints.disabled,minSize:0,maxSize:100,panelId:e.id})):t.map(e=>{let{element:t,panelConstraints:r}=e,i=0;r.collapsedSize!==void 0&&(i=Jp(qp({groupSize:n,panelElement:t,styleProp:r.collapsedSize})/n*100));let a;r.defaultSize!==void 0&&(a=Jp(qp({groupSize:n,panelElement:t,styleProp:r.defaultSize})/n*100));let o=0;r.minSize!==void 0&&(o=Jp(qp({groupSize:n,panelElement:t,styleProp:r.minSize})/n*100));let s=100;return r.maxSize!==void 0&&(s=Jp(qp({groupSize:n,panelElement:t,styleProp:r.maxSize})/n*100)),{groupResizeBehavior:r.groupResizeBehavior,collapsedSize:i,collapsible:r.collapsible===!0,defaultSize:a,disabled:r.disabled,minSize:o,maxSize:s,panelId:e.id}})}function Zp(e,t=`Assertion error`){if(!e)throw Error(t)}function Qp(e,t){return Array.from(t).sort(e===`horizontal`?$p:em)}function $p(e,t){let n=e.element.offsetLeft-t.element.offsetLeft;return n===0?e.element.offsetWidth-t.element.offsetWidth:n}function em(e,t){let n=e.element.offsetTop-t.element.offsetTop;return n===0?e.element.offsetHeight-t.element.offsetHeight:n}function tm(e){return typeof e==`object`&&!!e&&`nodeType`in e&&e.nodeType===Node.ELEMENT_NODE}function nm(e,t){return{x:e.x>=t.left&&e.x<=t.right?0:Math.min(Math.abs(e.x-t.left),Math.abs(e.x-t.right)),y:e.y>=t.top&&e.y<=t.bottom?0:Math.min(Math.abs(e.y-t.top),Math.abs(e.y-t.bottom))}}function rm({orientation:e,rects:t,targetRect:n}){let r={x:n.x+n.width/2,y:n.y+n.height/2},i,a=Number.MAX_VALUE;for(let n of t){let{x:t,y:o}=nm(r,n),s=e===`horizontal`?t:o;s<a&&(a=s,i=n)}return Zp(i,`No rect found`),i}var im;function am(){return im===void 0&&(im=typeof matchMedia==`function`&&!!matchMedia(`(pointer:coarse)`).matches),im}function om(e){let{element:t,orientation:n,panels:r,separators:i}=e,a=Qp(n,Array.from(t.children).filter(tm).map(e=>({element:e}))).map(({element:e})=>e),o=[],s=!1,c=!1,l=-1,u=-1,d=0,f,p=[];{let e=-1;for(let t of a)t.hasAttribute(`data-panel`)&&(e++,t.hasAttribute(`data-disabled`)||(d++,l===-1&&(l=e),u=e))}if(d>1){let t=-1;for(let d of a)if(d.hasAttribute(`data-panel`)){t++;let i=r.find(e=>e.element===d);if(i){if(f){let r=f.element.getBoundingClientRect(),a=d.getBoundingClientRect(),m;if(c){let e=n===`horizontal`?new DOMRect(r.right,r.top,0,r.height):new DOMRect(r.left,r.bottom,r.width,0),t=n===`horizontal`?new DOMRect(a.left,a.top,0,a.height):new DOMRect(a.left,a.top,a.width,0);switch(p.length){case 0:m=[e,t];break;case 1:{let i=p[0];m=[i,rm({orientation:n,rects:[r,a],targetRect:i.element.getBoundingClientRect()})===r?t:e];break}default:m=p}}else m=p.length?p:[n===`horizontal`?new DOMRect(r.right,a.top,a.left-r.right,a.height):new DOMRect(a.left,r.bottom,a.width,a.top-r.bottom)];for(let n of m){let r=`width`in n?n:n.element.getBoundingClientRect(),a=am()?e.resizeTargetMinimumSize.coarse:e.resizeTargetMinimumSize.fine;if(r.width<a){let e=a-r.width;r=new DOMRect(r.x-e/2,r.y,r.width+e,r.height)}if(r.height<a){let e=a-r.height;r=new DOMRect(r.x,r.y-e/2,r.width,r.height+e)}!s&&!(t<=l||t>u)&&o.push({group:e,groupSize:Yp({group:e}),panels:[f,i],separator:`width`in n?void 0:n,rect:r}),s=!1}}c=!1,f=i,p=[]}}else if(d.hasAttribute(`data-separator`)){d.ariaDisabled!==null&&(s=!0);let e=i.find(e=>e.element===d);e?p.push(e):(f=void 0,p=[])}else c=!0}return o}var sm=class{#e={};addListener(e,t){let n=this.#e[e];return n===void 0?this.#e[e]=[t]:n.includes(t)||n.push(t),()=>{this.removeListener(e,t)}}emit(e,t){let n=this.#e[e];if(n!==void 0){if(n.length===1)n[0].call(null,t);else{let e=!1,r=null,i=Array.from(n);for(let n=0;n<i.length;n++){let a=i[n];try{a.call(null,t)}catch(t){r===null&&(e=!0,r=t)}}if(e)throw r}}}removeAllListeners(){this.#e={}}removeListener(e,t){let n=this.#e[e];if(n!==void 0){let e=n.indexOf(t);e>=0&&n.splice(e,1)}}},cm={cursorFlags:0,state:`inactive`},lm=new sm;function um(){return cm}function dm(e){return lm.addListener(`change`,e)}function fm(e){let t=cm,n={...cm};n.cursorFlags=e,cm=n,lm.emit(`change`,{prev:t,next:n})}function pm(e){let t=cm;cm=e,lm.emit(`change`,{prev:t,next:e})}var mm=e=>e,hm=()=>{},gm=1,_m=2,vm=4,ym=8,bm=3,xm=12,Sm;function Cm(){return Sm===void 0&&(Sm=!1,typeof window<`u`&&(window.navigator.userAgent.includes(`Chrome`)||window.navigator.userAgent.includes(`Firefox`))&&(Sm=!0)),Sm}function wm({cursorFlags:e,groups:t,state:n}){let r=0,i=0;switch(n){case`active`:case`hover`:t.forEach(e=>{if(!e.mutableState.disableCursor)switch(e.orientation){case`horizontal`:r++;break;case`vertical`:i++}})}if(r!==0||i!==0){if(n===`active`&&e&&Cm()){let t=(e&gm)!==0,n=(e&_m)!==0,r=(e&vm)!==0,i=(e&ym)!==0;if(t)return r?`se-resize`:i?`ne-resize`:`e-resize`;if(n)return r?`sw-resize`:i?`nw-resize`:`w-resize`;if(r)return`s-resize`;if(i)return`n-resize`}return Cm()?r>0&&i>0?`move`:r>0?`ew-resize`:`ns-resize`:r>0&&i>0?`grab`:r>0?`col-resize`:`row-resize`}}var Tm=new WeakMap;function Em(e){if(!e.defaultView||!e.adoptedStyleSheets)return;let{prevStyle:t,styleSheet:n}=Tm.get(e)??{};n===void 0&&(n=new e.defaultView.CSSStyleSheet,e.adoptedStyleSheets&&(Object.isExtensible(e.adoptedStyleSheets)?e.adoptedStyleSheets.push(n):e.adoptedStyleSheets=[...e.adoptedStyleSheets,n]));let r=um();switch(r.state){case`active`:case`hover`:{let e=wm({cursorFlags:r.cursorFlags,groups:r.hitRegions.map(e=>e.group),state:r.state}),i=`*, *:hover {cursor: ${e} !important; }`;if(t===i)return;t=i,e?n.cssRules.length===0?n.insertRule(i):n.replaceSync(i):n.cssRules.length===1&&n.deleteRule(0);break}case`inactive`:t=void 0,n.cssRules.length===1&&n.deleteRule(0)}Tm.set(e,{prevStyle:t,styleSheet:n})}var Dm=new Map,Om=new sm;function km(e){Dm=new Map(Dm),Dm.delete(e)}function Am(e,t){for(let[t]of Dm)if(t.id===e)return t}function jm(e,t){for(let[t,n]of Dm)if(t.id===e)return n;if(t)throw Error(`Could not find data for Group with id ${e}`)}function Mm(){return Dm}function Nm(e,t){return Om.addListener(`groupChange`,n=>{n.group.id===e&&t(n)})}function Pm(e,t,n){let r=Dm.get(e);Dm=new Map(Dm),Dm.set(e,t),Om.emit(`groupChange`,{group:e,isUserInteraction:n?.isUserInteraction===!0,prev:r,next:t})}function Fm(e){let t=um(),n=Mm(),r=!1;return t.state===`active`&&(pm({cursorFlags:0,state:`inactive`}),t.hitRegions.length>0&&(Em(e),r=!0,t.hitRegions.forEach(e=>{if(!n.has(e.group))return;let t=jm(e.group.id,!0);Pm(e.group,t,{isUserInteraction:!0})}))),r}function Im(e){e.defaultPrevented||Fm(e.currentTarget)}function Lm(e,t,n){let r,i={x:1/0,y:1/0};for(let a of t){let t=nm(n,a.rect);switch(e){case`horizontal`:t.x<=i.x&&(r=a,i=t);break;case`vertical`:t.y<=i.y&&(r=a,i=t)}}return r?{distance:i,hitRegion:r}:void 0}function Rm(e){return typeof e==`object`&&!!e&&`nodeType`in e&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE}function zm(e,t){if(e===t)throw Error(`Cannot compare node with itself`);let n={a:Gm(e),b:Gm(t)},r;for(;n.a.at(-1)===n.b.at(-1);)r=n.a.pop(),n.b.pop();Zp(r,`Stacking order can only be calculated for elements with a common ancestor`);let i={a:Wm(Um(n.a)),b:Wm(Um(n.b))};if(i.a===i.b){let e=r.childNodes,t={a:n.a.at(-1),b:n.b.at(-1)},i=e.length;for(;i--;){let n=e[i];if(n===t.a)return 1;if(n===t.b)return-1}}return Math.sign(i.a-i.b)}var Bm=/\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\b/;function Vm(e){let t=getComputedStyle(Km(e)??e).display;return t===`flex`||t===`inline-flex`}function Hm(e){let t=getComputedStyle(e);return!!(t.position===`fixed`||t.zIndex!==`auto`&&(t.position!==`static`||Vm(e))||+t.opacity<1||`transform`in t&&t.transform!==`none`||`webkitTransform`in t&&t.webkitTransform!==`none`||`mixBlendMode`in t&&t.mixBlendMode!==`normal`||`filter`in t&&t.filter!==`none`||`webkitFilter`in t&&t.webkitFilter!==`none`||`isolation`in t&&t.isolation===`isolate`||Bm.test(t.willChange)||t.webkitOverflowScrolling===`touch`)}function Um(e){let t=e.length;for(;t--;){let n=e[t];if(Zp(n,`Missing node`),Hm(n))return n}return null}function Wm(e){return e&&Number(getComputedStyle(e).zIndex)||0}function Gm(e){let t=[];for(;e;)t.push(e),e=Km(e);return t}function Km(e){let{parentNode:t}=e;return Rm(t)?t.host:t}function qm(e,t){return e.x<t.x+t.width&&e.x+e.width>t.x&&e.y<t.y+t.height&&e.y+e.height>t.y}function Jm({groupElement:e,hitRegion:t,pointerEventTarget:n}){if(!tm(n)||n.contains(e)||e.contains(n))return!0;if(zm(n,e)>0){let r=n;for(;r;){if(r.contains(e))return!0;if(qm(r.getBoundingClientRect(),t))return!1;r=r.parentElement}}return!0}function Ym(e,t){let n=[];return t.forEach((t,r)=>{if(r.disabled)return;let i=om(r),a=Lm(r.orientation,i,{x:e.clientX,y:e.clientY});a&&a.distance.x<=0&&a.distance.y<=0&&Jm({groupElement:r.element,hitRegion:a.hitRegion.rect,pointerEventTarget:e.target})&&n.push(a.hitRegion)}),n}function Xm(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!=t[n])return!1;return!0}function Zm(e,t,n=0){return Math.abs(Jp(e)-Jp(t))<=n}function Qm(e,t){return Zm(e,t)?0:e>t?1:-1}function $m({overrideDisabledPanels:e,panelConstraints:t,prevSize:n,size:r}){let{collapsedSize:i=0,collapsible:a,disabled:o,maxSize:s=100,minSize:c=0}=t;if(o&&!e)return n;if(Qm(r,c)<0){if(a){let e=(i+c)/2;r=Qm(r,e)<0?i:c}else r=c}return r=Math.min(s,r),r=Jp(r),r}function eh({delta:e,initialLayout:t,panelConstraints:n,pivotIndices:r,prevLayout:i,trigger:a}){if(Zm(e,0))return t;let o=a===`imperative-api`,s=Object.values(t),c=Object.values(i),l=[...s],[u,d]=r;Zp(u!=null,`Invalid first pivot index`),Zp(d!=null,`Invalid second pivot index`);let f=0;switch(a){case`keyboard`:{let t=e<0?d:u,r=n[t];Zp(r,`Panel constraints not found for index ${t}`);let{collapsedSize:i=0,collapsible:a,minSize:o=0}=r;if(a){let n=s[t];if(Zp(n!=null,`Previous layout not found for panel index ${t}`),Zm(n,i)){let t=o-n;Qm(t,Math.abs(e))>0&&(e=e<0?0-t:t)}}}{let t=e<0?u:d,r=n[t];Zp(r,`No panel constraints found for index ${t}`);let{collapsedSize:i=0,collapsible:a,minSize:o=0}=r;if(a){let n=s[t];if(Zp(n!=null,`Previous layout not found for panel index ${t}`),Zm(n,o)){let t=n-i;Qm(t,Math.abs(e))>0&&(e=e<0?0-t:t)}}}break;default:{let t=e<0?d:u,r=n[t];Zp(r,`Panel constraints not found for index ${t}`);let i=s[t],{collapsible:a,collapsedSize:o,minSize:c}=r;if(a&&Qm(i,c)<0){if(e>0){let t=c-o,n=t/2;Qm(i+e,c)<0&&(e=Qm(e,n)<=0?0:t)}else{let t=c-o,n=100-t/2;Qm(i-e,c)<0&&(e=Qm(100+e,n)>0?0:-t)}}break}}{let t=e<0?1:-1,r=e<0?d:u,i=0;for(;;){let e=s[r];Zp(e!=null,`Previous layout not found for panel index ${r}`);let a=$m({overrideDisabledPanels:o,panelConstraints:n[r],prevSize:e,size:100})-e;if(i+=a,r+=t,r<0||r>=n.length)break}let a=Math.min(Math.abs(e),Math.abs(i));e=e<0?0-a:a}{let t=e<0?u:d;for(;t>=0&&t<n.length;){let r=Math.abs(e)-Math.abs(f),i=s[t];Zp(i!=null,`Previous layout not found for panel index ${t}`);let a=i-r,c=$m({overrideDisabledPanels:o,panelConstraints:n[t],prevSize:i,size:a});if(!Zm(i,c)&&(f+=i-c,l[t]=c,f.toFixed(3).localeCompare(Math.abs(e).toFixed(3),void 0,{numeric:!0})>=0))break;e<0?t--:t++}}if(Xm(c,l))return i;{let t=e<0?d:u,r=s[t];Zp(r!=null,`Previous layout not found for panel index ${t}`);let i=r+f,a=$m({overrideDisabledPanels:o,panelConstraints:n[t],prevSize:r,size:i});if(l[t]=a,!Zm(a,i)){let t=i-a,r=e<0?d:u;for(;r>=0&&r<n.length;){let i=l[r];Zp(i!=null,`Previous layout not found for panel index ${r}`);let a=i+t,s=$m({overrideDisabledPanels:o,panelConstraints:n[r],prevSize:i,size:a});if(Zm(i,s)||(t-=s-i,l[r]=s),Zm(t,0))break;e>0?r--:r++}}}if(!Zm(Object.values(l).reduce((e,t)=>t+e,0),100,.1))return i;let p=Object.keys(i);return l.reduce((e,t,n)=>(e[p[n]]=t,e),{})}function th(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let n in e)if(t[n]===void 0||Qm(e[n],t[n])!==0)return!1;return!0}function nh({layout:e,panelConstraints:t}){let n=Object.values(e),r=[...n],i=r.reduce((e,t)=>e+t,0);if(r.length!==t.length)throw Error(`Invalid ${t.length} panel layout: ${r.map(e=>`${e}%`).join(`, `)}`);if(!Zm(i,100)&&r.length>0)for(let e=0;e<t.length;e++){let t=r[e];Zp(t!=null,`No layout data found for index ${e}`);let n=100/i*t;r[e]=n}let a=0;for(let e=0;e<t.length;e++){let i=n[e];Zp(i!=null,`No layout data found for index ${e}`);let o=r[e];Zp(o!=null,`No layout data found for index ${e}`);let s=$m({overrideDisabledPanels:!0,panelConstraints:t[e],prevSize:i,size:o});o!=s&&(a+=o-s,r[e]=s)}if(!Zm(a,0))for(let e=0;e<t.length;e++){let n=r[e];Zp(n!=null,`No layout data found for index ${e}`);let i=n+a,o=$m({overrideDisabledPanels:!0,panelConstraints:t[e],prevSize:n,size:i});if(n!==o&&(a-=o-n,r[e]=o,Zm(a,0)))break}let o=Object.keys(e);return r.reduce((e,t,n)=>(e[o[n]]=t,e),{})}function rh({groupId:e,panelId:t}){let n=()=>{let t=Mm();for(let[n,{defaultLayoutDeferred:r,derivedPanelConstraints:i,layout:a,groupSize:o,separatorToPanels:s}]of t)if(n.id===e)return{defaultLayoutDeferred:r,derivedPanelConstraints:i,group:n,groupSize:o,layout:a,separatorToPanels:s};throw Error(`Group ${e} not found`)},r=()=>{let e=n().derivedPanelConstraints.find(e=>e.panelId===t);if(e!==void 0)return e;throw Error(`Panel constraints not found for Panel ${t}`)},i=()=>{let e=n().group.panels.find(e=>e.id===t);if(e!==void 0)return e;throw Error(`Layout not found for Panel ${t}`)},a=()=>{let e=n().layout[t];if(e!==void 0)return e;throw Error(`Layout not found for Panel ${t}`)},o=({nextSize:e,panels:n,prevLayout:r,derivedPanelConstraints:i})=>{let o=a(),s=n.findIndex(e=>e.id===t),c=s===0,l=s===n.length-1;if(l&&e<o&&(c||n.slice(0,s).every((e,t)=>{let n=i[t];return n?.collapsible&&Zm(n.collapsedSize,r[n.panelId])}))){let e=n.slice(0,s).reduce((e,t)=>e+r[t.id],0);return{...r,[t]:Jp(100-e)}}return eh({delta:l?o-e:e-o,initialLayout:r,panelConstraints:i,pivotIndices:l?[s-1,s]:[s,s+1],prevLayout:r,trigger:`imperative-api`})},s=e=>{if(e===a())return;let{defaultLayoutDeferred:t,derivedPanelConstraints:r,group:i,groupSize:s,layout:c,separatorToPanels:l}=n(),u=nh({layout:o({nextSize:e,panels:i.panels,prevLayout:c,derivedPanelConstraints:r}),panelConstraints:r});th(c,u)||Pm(i,{defaultLayoutDeferred:t,derivedPanelConstraints:r,groupSize:s,layout:u,separatorToPanels:l})};return{collapse:()=>{let{collapsible:e,collapsedSize:t}=r(),{mutableValues:n}=i(),o=a();e&&o!==t&&(n.expandToSize=o,s(t))},expand:()=>{let{collapsible:e,collapsedSize:t,minSize:n}=r(),{mutableValues:o}=i(),c=a();if(e&&c===t){let e=o.expandToSize??n;e===0&&(e=1),s(e)}},getSize:()=>{let{group:e}=n(),t=a(),{element:r}=i();return{asPercentage:t,inPixels:e.orientation===`horizontal`?r.offsetWidth:r.offsetHeight}},isCollapsed:()=>{let{collapsible:e,collapsedSize:t}=r(),n=a();return e&&Zm(t,n)},resize:e=>{let{group:t}=n(),{element:r}=i(),a=Yp({group:t}),o=Jp(qp({groupSize:a,panelElement:r,styleProp:e})/a*100);s(o)}}}function ih(e){e.defaultPrevented||Ym(e,Mm()).forEach(t=>{if(t.separator&&!t.separator.disableDoubleClick){let n=t.panels.find(e=>e.panelConstraints.defaultSize!==void 0);if(n){let r=n.panelConstraints.defaultSize,i=rh({groupId:t.group.id,panelId:n.id});i&&r!==void 0&&(i.resize(r),e.preventDefault())}}})}function ah(e){let t=Mm();for(let[n]of t)if(n.separators.some(t=>t.element===e))return n;throw Error(`Could not find parent Group for separator element`)}function oh({groupId:e}){let t=()=>{let t=Mm();for(let[n,r]of t)if(n.id===e)return{group:n,...r};throw Error(`Could not find Group with id "${e}"`)};return{getLayout(){let{defaultLayoutDeferred:e,layout:n}=t();return e?{}:n},setLayout(e){let{defaultLayoutDeferred:n,derivedPanelConstraints:r,group:i,groupSize:a,layout:o,separatorToPanels:s}=t(),c=nh({layout:e,panelConstraints:r});return n?o:(th(o,c)||Pm(i,{defaultLayoutDeferred:n,derivedPanelConstraints:r,groupSize:a,layout:c,separatorToPanels:s}),c)}}}function sh(e,t){let n=ah(e),r=jm(n.id,!0),i=n.separators.find(t=>t.element===e);Zp(i,`Matching separator not found`);let a=r.separatorToPanels.get(i);Zp(a,`Matching panels not found`);let o=a.map(e=>n.panels.indexOf(e)),s=oh({groupId:n.id}).getLayout(),c=nh({layout:eh({delta:t,initialLayout:s,panelConstraints:r.derivedPanelConstraints,pivotIndices:o,prevLayout:s,trigger:`keyboard`}),panelConstraints:r.derivedPanelConstraints});th(s,c)||Pm(n,{defaultLayoutDeferred:r.defaultLayoutDeferred,derivedPanelConstraints:r.derivedPanelConstraints,groupSize:r.groupSize,layout:c,separatorToPanels:r.separatorToPanels},{isUserInteraction:!0})}function ch(e){if(e.defaultPrevented)return;let t=e.currentTarget,n=ah(t);if(!n.disabled)switch(e.key){case`ArrowDown`:e.preventDefault(),n.orientation===`vertical`&&sh(t,5);break;case`ArrowLeft`:e.preventDefault(),n.orientation===`horizontal`&&sh(t,-5);break;case`ArrowRight`:e.preventDefault(),n.orientation===`horizontal`&&sh(t,5);break;case`ArrowUp`:e.preventDefault(),n.orientation===`vertical`&&sh(t,-5);break;case`End`:e.preventDefault(),sh(t,100);break;case`Enter`:{e.preventDefault();let n=ah(t),{derivedPanelConstraints:r,layout:i,separatorToPanels:a}=jm(n.id,!0),o=n.separators.find(e=>e.element===t);Zp(o,`Matching separator not found`);let s=a.get(o);Zp(s,`Matching panels not found`);let c=s[0],l=r.find(e=>e.panelId===c.id);if(Zp(l,`Panel metadata not found`),l.collapsible){let e=i[c.id];sh(t,(l.collapsedSize===e?n.mutableState.expandedPanelSizes[c.id]??l.minSize:l.collapsedSize)-e)}break}case`F6`:{e.preventDefault();let n=ah(t).separators.map(e=>e.element),r=Array.from(n).findIndex(t=>t===e.currentTarget);Zp(r!==null,`Index not found`),n[e.shiftKey?r>0?r-1:n.length-1:r+1<n.length?r+1:0].focus({preventScroll:!0});break}case`Home`:e.preventDefault(),sh(t,-100)}}function lh(e){if(e.defaultPrevented||e.pointerType===`mouse`&&e.button>0)return;let t=Mm(),n=Ym(e,t),r=new Map,i=!1;n.forEach(e=>{e.separator&&(i||(i=!0,e.separator.element.focus({focusVisible:!1,preventScroll:!0})));let n=t.get(e.group);n&&r.set(e.group,n.layout)}),pm({cursorFlags:0,hitRegions:n,initialLayoutMap:r,pointerDownAtPoint:{x:e.clientX,y:e.clientY},state:`active`}),n.length&&e.preventDefault()}function uh({document:e,event:t,hitRegions:n,initialLayoutMap:r,mountedGroups:i,pointerDownAtPoint:a,prevCursorFlags:o}){let s=0;n.forEach(e=>{let{group:n,groupSize:o}=e,{orientation:c,panels:l}=n,{disableCursor:u}=n.mutableState,d=0;d=a?c===`horizontal`?(t.clientX-a.x)/o*100:(t.clientY-a.y)/o*100:c===`horizontal`?t.clientX<0?-100:100:t.clientY<0?-100:100;let f=r.get(n),p=i.get(n);if(!f||!p)return;let{defaultLayoutDeferred:m,derivedPanelConstraints:h,groupSize:g,layout:_,separatorToPanels:v}=p;if(h&&_&&v){let t=eh({delta:d,initialLayout:f,panelConstraints:h,pivotIndices:e.panels.map(e=>l.indexOf(e)),prevLayout:_,trigger:`mouse-or-touch`});if(th(t,_)){if(d!==0&&!u)switch(c){case`horizontal`:s|=d<0?gm:_m;break;case`vertical`:s|=d<0?vm:ym}}else Pm(e.group,{defaultLayoutDeferred:m,derivedPanelConstraints:h,groupSize:g,layout:t,separatorToPanels:v})}});let c=0;t.movementX===0?c|=o&bm:c|=s&bm,t.movementY===0?c|=o&xm:c|=s&xm,fm(c),Em(e)}function dh(e){let t=Mm(),n=um();n.state===`active`&&uh({document:e.currentTarget,event:e,hitRegions:n.hitRegions,initialLayoutMap:n.initialLayoutMap,mountedGroups:t,prevCursorFlags:n.cursorFlags})}function fh(e){if(e.defaultPrevented)return;let t=um(),n=Mm();switch(t.state){case`active`:if(e.buttons===0){pm({cursorFlags:0,state:`inactive`}),t.hitRegions.forEach(e=>{if(!n.has(e.group))return;let t=jm(e.group.id,!0);Pm(e.group,t,{isUserInteraction:!0})});return}for(let n of t.hitRegions)if(n.separator){let{element:t}=n.separator;t.hasPointerCapture?.(e.pointerId)||t.setPointerCapture?.(e.pointerId)}uh({document:e.currentTarget,event:e,hitRegions:t.hitRegions,initialLayoutMap:t.initialLayoutMap,mountedGroups:n,pointerDownAtPoint:t.pointerDownAtPoint,prevCursorFlags:t.cursorFlags});break;default:{let r=Ym(e,n);r.length===0?t.state!==`inactive`&&pm({cursorFlags:0,state:`inactive`}):pm({cursorFlags:0,hitRegions:r,state:`hover`}),Em(e.currentTarget);break}}}function ph(e){if(e.relatedTarget instanceof HTMLIFrameElement)switch(um().state){case`hover`:pm({cursorFlags:0,state:`inactive`})}}function mh(e){e.defaultPrevented||e.pointerType===`mouse`&&e.button>0||Fm(e.currentTarget)&&e.preventDefault()}function hh(e){let t=0,n=0,r={};for(let i of e)if(i.defaultSize!==void 0){t++;let e=Jp(i.defaultSize);n+=e,r[i.panelId]=e}else r[i.panelId]=void 0;let i=e.length-t;if(i!==0){let t=Jp((100-n)/i);for(let n of e)n.defaultSize===void 0&&(r[n.panelId]=t)}return r}function gh(e,t,n){if(!n[0])return;let r=e.panels.find(e=>e.element===t);if(!r||!r.onResize)return;let i=Yp({group:e}),a=e.orientation===`horizontal`?r.element.offsetWidth:r.element.offsetHeight,o=r.mutableValues.prevSize,s={asPercentage:Jp(a/i*100),inPixels:a};r.mutableValues.prevSize=s,r.onResize(s,r.id,o)}function _h(e,t){if(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 vh(e,t){return e.length===t.length&&e.every((e,n)=>_h(e,t[n]))}function yh({group:e,nextGroupSize:t,prevGroupSize:n,prevLayout:r}){if(n<=0||t<=0||n===t)return r;let i=0,a=0,o=!1,s=new Map,c=[];for(let l of e.panels){let e=r[l.id]??0;switch(l.panelConstraints.groupResizeBehavior){case`preserve-pixel-size`:{o=!0;let r=Jp(e/100*n/t*100);s.set(l.id,r),i+=r;break}default:c.push(l.id),a+=e}}if(!o||c.length===0)return r;let l=100-i,u={...r};if(s.forEach((e,t)=>{u[t]=e}),a>0)for(let e of c)u[e]=Jp((r[e]??0)/a*l);else{let e=Jp(l/c.length);for(let t of c)u[t]=e}return u}function bh(e,t){let n=e.map(e=>e.id),r=Object.keys(t);if(n.length!==r.length)return!1;for(let e of n)if(!r.includes(e))return!1;return!0}var xh=new Map;function Sh(e){let t=!0;Zp(e.element.ownerDocument.defaultView,`Cannot register an unmounted Group`);let n=e.element.ownerDocument.defaultView.ResizeObserver,r=new Set,i=new Set,a=new n(n=>{for(let r of n){let{borderBoxSize:n,target:i}=r;if(i===e.element){if(t){let t=Yp({group:e});if(t===0)return;let n=jm(e.id);if(!n)return;let r=Xp(e),i=n.defaultLayoutDeferred?hh(r):n.layout,a=nh({layout:yh({group:e,nextGroupSize:t,prevGroupSize:n.groupSize,prevLayout:i}),panelConstraints:r});if(!n.defaultLayoutDeferred&&th(n.layout,a)&&vh(n.derivedPanelConstraints,r)&&n.groupSize===t)continue;Pm(e,{defaultLayoutDeferred:!1,derivedPanelConstraints:r,groupSize:t,layout:a,separatorToPanels:n.separatorToPanels})}}else gh(e,i,n)}});a.observe(e.element),e.panels.forEach(e=>{Zp(!r.has(e.id),`Panel ids must be unique; id "${e.id}" was used more than once`),r.add(e.id),e.onResize&&a.observe(e.element)});let o=Yp({group:e}),s=Xp(e),c=e.panels.map(({id:e})=>e).join(`,`),l=e.mutableState.defaultLayout;l&&(bh(e.panels,l)||(l=void 0));let u=nh({layout:e.mutableState.layouts[c]??l??hh(s),panelConstraints:s}),d=e.element.ownerDocument;xh.set(d,(xh.get(d)??0)+1);let f=new Map;return om(e).forEach(e=>{e.separator&&f.set(e.separator,e.panels)}),Pm(e,{defaultLayoutDeferred:o===0,derivedPanelConstraints:s,groupSize:o,layout:u,separatorToPanels:f}),e.separators.forEach(e=>{Zp(!i.has(e.id),`Separator ids must be unique; id "${e.id}" was used more than once`),i.add(e.id),e.element.addEventListener(`keydown`,ch)}),xh.get(d)===1&&(d.addEventListener(`contextmenu`,Im,!0),d.addEventListener(`dblclick`,ih,!0),d.addEventListener(`pointerdown`,lh,!0),d.addEventListener(`pointerleave`,dh),d.addEventListener(`pointermove`,fh),d.addEventListener(`pointerout`,ph),d.addEventListener(`pointerup`,mh,!0)),function(){t=!1,xh.set(d,Math.max(0,(xh.get(d)??0)-1)),km(e),e.separators.forEach(e=>{e.element.removeEventListener(`keydown`,ch)}),xh.get(d)||(d.removeEventListener(`contextmenu`,Im,!0),d.removeEventListener(`dblclick`,ih,!0),d.removeEventListener(`pointerdown`,lh,!0),d.removeEventListener(`pointerleave`,dh),d.removeEventListener(`pointermove`,fh),d.removeEventListener(`pointerout`,ph),d.removeEventListener(`pointerup`,mh,!0)),a.disconnect()}}function Ch(){let[e,t]=(0,C.useState)({});return[e,(0,C.useCallback)(()=>t({}),[])]}function wh(e){let t=(0,C.useId)();return`${e??t}`}var Th=typeof window<`u`?C.useLayoutEffect:C.useEffect;function Eh(e){let t=(0,C.useRef)(e);return Th(()=>{t.current=e},[e]),(0,C.useCallback)((...e)=>t.current?.(...e),[t])}function Dh(...e){return Eh(t=>{e.forEach(e=>{if(e)switch(typeof e){case`function`:e(t);break;case`object`:e.current=t}})})}function Oh(e){let t=(0,C.useRef)({...e});return Th(()=>{for(let n in e)t.current[n]=e[n]},[e]),t.current}var kh=(0,C.createContext)(null);function Ah(e,t){let n=(0,C.useRef)({getLayout:()=>({}),setLayout:mm});(0,C.useImperativeHandle)(t,()=>n.current,[]),Th(()=>{Object.assign(n.current,oh({groupId:e}))})}function jh({children:e,className:t,defaultLayout:n,disableCursor:r,disabled:i,elementRef:a,groupRef:o,id:s,onLayoutChange:c,onLayoutChanged:l,orientation:u=`horizontal`,resizeTargetMinimumSize:d={coarse:20,fine:10},style:f,...p}){let m=(0,C.useRef)({onLayoutChange:{},onLayoutChanged:{}}),h=Eh(e=>{th(m.current.onLayoutChange,e)||(m.current.onLayoutChange=e,c?.(e))}),g=Eh((e,t)=>{th(m.current.onLayoutChanged,e)||(m.current.onLayoutChanged=e,l?.(e,{isUserInteraction:t}))}),_=wh(s),v=(0,C.useRef)(null),[y,b]=Ch(),x=(0,C.useRef)({lastExpandedPanelSizes:{},layouts:{},panels:[],resizeTargetMinimumSize:d,separators:[]}),S=Dh(v,a);Ah(_,o);let w=Eh((e,t)=>{let r=um(),i=Am(e),a=jm(e);if(a){let e=!1;return r.state===`active`&&(e=r.hitRegions.some(e=>e.group===i)),{flexGrow:a.layout[t]??1,pointerEvents:e?`none`:void 0}}if(n?.[t])return{flexGrow:n?.[t]}}),T=Oh({defaultLayout:n,disableCursor:r}),E=(0,C.useMemo)(()=>({get disableCursor(){return!!T.disableCursor},getPanelStyles:w,id:_,orientation:u,registerPanel:e=>{let t=x.current;return t.panels=Qp(u,[...t.panels,e]),b(),()=>{t.panels=t.panels.filter(t=>t!==e),b()}},registerSeparator:e=>{let t=x.current;return t.separators=Qp(u,[...t.separators,e]),b(),()=>{t.separators=t.separators.filter(t=>t!==e),b()}},updatePanelProps:(e,{disabled:t})=>{let n=x.current.panels.find(t=>t.id===e);n&&(n.panelConstraints.disabled=t);let r=Am(_),i=jm(_);r&&i&&Pm(r,{...i,derivedPanelConstraints:Xp(r)})},updateSeparatorProps:(e,{disabled:t,disableDoubleClick:n})=>{let r=x.current.separators.find(t=>t.id===e);r&&(r.disabled=t,r.disableDoubleClick=n)}}),[w,_,b,u,T]),D=(0,C.useRef)(null);return Th(()=>{let e=v.current;if(e===null)return;let t=x.current,n;if(T.defaultLayout!==void 0&&Object.keys(T.defaultLayout).length===t.panels.length){n={};for(let e of t.panels){let t=T.defaultLayout[e.id];t!==void 0&&(n[e.id]=t)}}let r={disabled:!!i,element:e,id:_,mutableState:{defaultLayout:n,disableCursor:!!T.disableCursor,expandedPanelSizes:x.current.lastExpandedPanelSizes,layouts:x.current.layouts},orientation:u,panels:t.panels,resizeTargetMinimumSize:t.resizeTargetMinimumSize,separators:t.separators};D.current=r;let a=Sh(r),{defaultLayoutDeferred:o,derivedPanelConstraints:s,layout:c}=jm(r.id,!0);!o&&s.length>0&&(h(c),g(c,!1));let l=Nm(_,e=>{let{defaultLayoutDeferred:t,derivedPanelConstraints:n,layout:i}=e.next;if(t||n.length===0)return;let a=r.panels.map(({id:e})=>e).join(`,`);r.mutableState.layouts[a]=i,n.forEach(t=>{if(t.collapsible){let{layout:n}=e.prev??{};if(n){let e=Zm(t.collapsedSize,i[t.panelId]),a=Zm(t.collapsedSize,n[t.panelId]);e&&!a&&(r.mutableState.expandedPanelSizes[t.panelId]=n[t.panelId])}}});let o=um().state!==`active`;h(i),o&&g(i,e.isUserInteraction)});return()=>{D.current=null,a(),l()}},[i,_,g,h,u,y,T]),(0,C.useEffect)(()=>{let e=D.current;e&&(e.mutableState.defaultLayout=n,e.mutableState.disableCursor=!!r)}),(0,G.jsx)(kh.Provider,{value:E,children:(0,G.jsx)(`div`,{...p,className:t,"data-group":!0,"data-testid":_,id:_,ref:S,style:{height:`100%`,width:`100%`,overflow:`hidden`,...f,display:`flex`,flexDirection:u===`horizontal`?`row`:`column`,flexWrap:`nowrap`,touchAction:u===`horizontal`?`pan-y`:`pan-x`},children:e})})}jh.displayName=`Group`;function Mh(e,t){return`react-resizable-panels:${[e,...t].join(`:`)}`}function Nh({id:e,panelIds:t,storage:n}){let r=Mh(e,[]),i=n.getItem(r);if(i)try{let e=JSON.parse(i);if(t){let n=e[t.join(`,`)];if(n&&Array.isArray(n.layout)&&t.length===n.layout.length){let e={};for(let r=0;r<t.length;r++)e[t[r]]=n.layout[r];return e}}else{let t=Object.keys(e);if(t.length===1){let n=e[t[0]];if(n&&Array.isArray(n.layout)){let e=t[0].split(`,`);if(e.length===n.layout.length){let t={};for(let r=0;r<e.length;r++)t[e[r]]=n.layout[r];return t}}}}}catch{}}function Ph({debounceSaveMs:e=100,onlySaveAfterUserInteractions:t,panelIds:n,storage:r=localStorage,...i}){let a=n!==void 0,o=`id`in i?i.id:i.groupId,s=Mh(o,n??[]),c=(0,C.useSyncExternalStore)(Fh,()=>r.getItem(s),()=>r.getItem(s)),l=(0,C.useMemo)(()=>{if(c){let e=JSON.parse(c),t=Object.values(e);if(Array.from(t).every(e=>typeof e==`number`))return e}},[c]),u=(0,C.useMemo)(()=>{if(!l)return Nh({id:o,panelIds:n,storage:r})},[l,o,n,r]),d=l??u,f=(0,C.useRef)(null),p=(0,C.useCallback)(()=>{let e=f.current;e&&(f.current=null,clearTimeout(e))},[]);(0,C.useLayoutEffect)(()=>()=>{p()},[p]);let m=(0,C.useCallback)((e,n)=>{if(t&&!n.isUserInteraction)return;p();let i;i=a?Mh(o,Object.keys(e)):Mh(o,[]);try{r.setItem(i,JSON.stringify(e))}catch(e){console.error(e)}},[p,a,o,t,r]);return{defaultLayout:d,onLayoutChange:(0,C.useCallback)(t=>{p(),e===0?m(t,{isUserInteraction:!1}):f.current=setTimeout(()=>{m(t,{isUserInteraction:!1})},e)},[p,e,m]),onLayoutChanged:m}}function Fh(){return function(){}}function Ih(){let e=(0,C.useContext)(kh);return Zp(e,`Group Context not found; did you render a Panel or Separator outside of a Group?`),e}function Lh(e,t){let{id:n}=Ih(),r=(0,C.useRef)({collapse:hm,expand:hm,getSize:()=>({asPercentage:0,inPixels:0}),isCollapsed:()=>!1,resize:hm});(0,C.useImperativeHandle)(t,()=>r.current,[]),Th(()=>{Object.assign(r.current,rh({groupId:n,panelId:e}))})}function Rh({children:e,className:t,collapsedSize:n=`0%`,collapsible:r=!1,defaultSize:i,disabled:a,elementRef:o,groupResizeBehavior:s=`preserve-relative-size`,id:c,maxSize:l=`100%`,minSize:u=`0%`,onResize:d,panelRef:f,style:p,...m}){let h=!!c,g=wh(c),_=Oh({disabled:a}),v=(0,C.useRef)(null),y=Dh(v,o),{getPanelStyles:b,id:x,orientation:S,registerPanel:w,updatePanelProps:T}=Ih(),E=d!==null,D=Eh((e,t,n)=>{d?.(e,c,n)});Th(()=>{let e=v.current;if(e!==null){let t={element:e,id:g,idIsStable:h,mutableValues:{expandToSize:void 0,prevSize:void 0},onResize:E?D:void 0,panelConstraints:{groupResizeBehavior:s,collapsedSize:n,collapsible:r,defaultSize:i,disabled:_.disabled,maxSize:l,minSize:u}};return w(t)}},[s,n,r,i,E,g,h,l,u,D,w,_]),(0,C.useEffect)(()=>{T(g,{disabled:a})},[a,g,T]),Lh(g,f);let O=()=>{let e=b(x,g);if(e)return JSON.stringify(e)},ee=(0,C.useSyncExternalStore)(e=>Nm(x,e),O,O),k;return k=ee?JSON.parse(ee):i===void 0?{flexGrow:1}:{flexGrow:void 0,flexShrink:void 0,flexBasis:i},(0,G.jsx)(`div`,{...m,"data-disabled":a||void 0,"data-panel":!0,"data-testid":g,id:g,ref:y,style:{...zh,display:`flex`,flexBasis:0,flexShrink:1,overflow:`visible`,...k},children:(0,G.jsx)(`div`,{className:t,style:{maxHeight:`100%`,maxWidth:`100%`,flexGrow:1,overflow:`auto`,...p,touchAction:S===`horizontal`?`pan-y`:`pan-x`},children:e})})}Rh.displayName=`Panel`;var zh={minHeight:0,maxHeight:`100%`,height:`auto`,minWidth:0,maxWidth:`100%`,width:`auto`,border:`none`,borderWidth:0,padding:0,margin:0};function Bh(){return(0,C.useRef)(null)}function Vh({layout:e,panelConstraints:t,panelId:n,panelIndex:r}){let i,a,o=e[n],s=t.find(e=>e.panelId===n);if(s){let c=s.maxSize,l=s.collapsible?s.collapsedSize:s.minSize,u=[r,r+1];a=nh({layout:eh({delta:l-o,initialLayout:e,panelConstraints:t,pivotIndices:u,prevLayout:e}),panelConstraints:t})[n],i=nh({layout:eh({delta:c-o,initialLayout:e,panelConstraints:t,pivotIndices:u,prevLayout:e}),panelConstraints:t})[n]}return{valueControls:n,valueMax:i,valueMin:a,valueNow:o}}function Hh({children:e,className:t,disabled:n,disableDoubleClick:r,elementRef:i,id:a,style:o,...s}){let c=wh(a),l=Oh({disabled:n,disableDoubleClick:r}),[u,d]=(0,C.useState)({}),[f,p]=(0,C.useState)(`inactive`),[m,h]=(0,C.useState)(!1),g=(0,C.useRef)(null),_=Dh(g,i),{disableCursor:v,id:y,orientation:b,registerSeparator:x,updateSeparatorProps:S}=Ih(),w=b===`horizontal`?`vertical`:`horizontal`;Th(()=>{let e=g.current;if(e!==null){let t={disabled:l.disabled,disableDoubleClick:l.disableDoubleClick,element:e,id:c},n=x(t),r=dm(e=>{p(e.next.state!==`inactive`&&e.next.hitRegions.some(e=>e.separator===t)?e.next.state:`inactive`)}),i=Nm(y,e=>{let{derivedPanelConstraints:n,layout:r,separatorToPanels:i}=e.next,a=i.get(t);if(a){let e=a[0],t=a.indexOf(e);d(Vh({layout:r,panelConstraints:n,panelId:e.id,panelIndex:t}))}});return()=>{r(),i(),n()}}},[y,c,x,l]),(0,C.useEffect)(()=>{S(c,{disabled:n,disableDoubleClick:r})},[n,r,c,S]);let T;n&&!v&&(T=`not-allowed`);let E;if(n)E=`disabled`;else switch(f){case`active`:E=`active`;break;default:E=m?`focus`:f}return(0,G.jsx)(`div`,{...s,"aria-controls":u.valueControls,"aria-disabled":n||void 0,"aria-orientation":w,"aria-valuemax":u.valueMax,"aria-valuemin":u.valueMin,"aria-valuenow":u.valueNow,children:e,className:t,"data-separator":E,"data-testid":c,id:c,onBlur:()=>h(!1),onFocus:()=>h(!0),ref:_,role:`separator`,style:{flexBasis:`auto`,cursor:T,...o,flexGrow:0,flexShrink:0,touchAction:`none`},tabIndex:n?void 0:0})}Hh.displayName=`Separator`;function Uh({className:e,...t}){return(0,G.jsx)(jh,{"data-slot":`resizable-panel-group`,className:W(`flex h-full w-full aria-[orientation=vertical]:flex-col`,e),...t})}function Wh({...e}){return(0,G.jsx)(Rh,{"data-slot":`resizable-panel`,...e})}function Gh({withHandle:e,className:t,...n}){return(0,G.jsx)(Hh,{"data-slot":`resizable-handle`,className:W(`bg-border focus-visible:ring-ring relative flex w-px items-center justify-center after:absolute after:inset-y-0 after:left-1/2 after:w-1 after:-translate-x-1/2 focus-visible:ring-1 focus-visible:ring-offset-1 focus-visible:outline-hidden aria-[orientation=horizontal]:h-px aria-[orientation=horizontal]:w-full aria-[orientation=horizontal]:after:left-0 aria-[orientation=horizontal]:after:h-1 aria-[orientation=horizontal]:after:w-full aria-[orientation=horizontal]:after:translate-x-0 aria-[orientation=horizontal]:after:-translate-y-1/2 [&[aria-orientation=horizontal]>div]:rotate-90`,t),...n,children:e?(0,G.jsx)(`div`,{className:`bg-border z-10 flex h-4 w-3 items-center justify-center rounded-xs border`,children:(0,G.jsx)(ie,{className:`size-2.5`})}):null})}function Kh({kind:e,description:t,onAllowOnce:n,onAllowAlways:r,onReject:i}){return(0,G.jsxs)(`div`,{className:`border-warning/50 w-full rounded-lg border px-2 py-2`,children:[(0,G.jsxs)(Ip,{className:`min-h-0 items-start py-0`,children:[(0,G.jsx)(Lp,{className:`text-warning-foreground mt-0.5`,children:(0,G.jsx)(B,{})}),(0,G.jsxs)(Rp,{className:`text-foreground font-medium`,children:[`Permission: `,e]})]}),t?(0,G.jsx)(`p`,{className:`text-muted-foreground mt-1 pl-6 text-xs`,children:t}):null,(0,G.jsxs)(`div`,{className:`mt-2 flex flex-wrap gap-1.5 pl-6`,children:[(0,G.jsx)(q,{size:`sm`,variant:`default`,onClick:n,children:`Allow once`}),(0,G.jsx)(q,{size:`sm`,variant:`secondary`,onClick:r,children:`Always allow`}),(0,G.jsx)(q,{size:`sm`,variant:`outline`,onClick:i,children:`Reject`})]})]})}var qh=Object.defineProperty,Jh=(e,t)=>qh(e,`name`,{value:t,configurable:!0}),Yh=`Collapsible`,[Xh,Zh]=Zi(Yh),[Qh,$h]=Xh(Yh),eg=C.forwardRef(Jh(function(e,t){let{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:a,onOpenChange:o,...s}=e,[c,l]=ca({prop:r,defaultProp:i??!1,onChange:o,caller:Yh});return(0,G.jsx)(Qh,{scope:n,disabled:a,contentId:wo(),open:c,onOpenToggle:C.useCallback(()=>l(e=>!e),[l]),children:(0,G.jsx)(ha.div,{"data-state":og(c),"data-disabled":a?``:void 0,...s,ref:t})})},`Collapsible`)),tg=`CollapsibleTrigger`,ng=C.forwardRef(Jh(function(e,t){let{__scopeCollapsible:n,...r}=e,i=$h(tg,n);return(0,G.jsx)(ha.button,{type:`button`,"aria-controls":i.open?i.contentId:void 0,"aria-expanded":i.open||!1,"data-state":og(i.open),"data-disabled":i.disabled?``:void 0,disabled:i.disabled,...r,ref:t,onClick:J(e.onClick,i.onOpenToggle)})},`CollapsibleTrigger`)),rg=`CollapsibleContent`,ig=C.forwardRef(Jh(function(e,t){let{forceMount:n,...r}=e,i=$h(rg,e.__scopeCollapsible);return(0,G.jsx)(ul,{present:n||i.open,children:({present:e})=>(0,G.jsx)(ag,{...r,ref:t,present:e})})},`CollapsibleContent`)),ag=C.forwardRef(Jh(function(e,t){let{__scopeCollapsible:n,present:r,children:i,...a}=e,o=$h(rg,n),[s,c]=C.useState(r),l=C.useRef(null),u=wi(t,l),d=C.useRef(0),f=d.current,p=C.useRef(0),m=p.current,h=o.open||s,g=C.useRef(h),_=C.useRef(void 0);return C.useEffect(()=>{let e=requestAnimationFrame(()=>g.current=!1);return()=>cancelAnimationFrame(e)},[]),$i(()=>{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,G.jsx)(ha.div,{"data-state":og(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 og(e){return e?`open`:`closed`}Jh(og,`getState`);var sg=eg;function cg({...e}){return(0,G.jsx)(sg,{"data-slot":`collapsible`,...e})}function lg({...e}){return(0,G.jsx)(ng,{"data-slot":`collapsible-trigger`,...e})}function ug({...e}){return(0,G.jsx)(ig,{"data-slot":`collapsible-content`,...e})}function dg({name:e,args:t,status:n=`pending`,onApprove:r,onAllowAlways:i,onReject:a}){let o=Object.keys(t),s=n===`pending`&&(r||i||a);return(0,G.jsx)(cg,{defaultOpen:n===`pending`,className:`w-full`,children:(0,G.jsxs)(`div`,{className:W(`rounded-lg border px-2 py-1.5`,n===`pending`&&`border-warning/50`,n===`failed`&&`border-destructive/40`),children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsx)(`button`,{type:`button`,className:`hover:bg-muted/50 flex w-full items-center gap-2 rounded-md text-left`,children:(0,G.jsxs)(Ip,{className:`min-h-0 py-0.5`,children:[(0,G.jsx)(Lp,{children:(0,G.jsx)(ue,{})}),(0,G.jsxs)(Rp,{className:`flex min-w-0 flex-1 items-center gap-2 text-foreground`,children:[(0,G.jsx)(`span`,{className:`truncate font-medium`,children:e}),(0,G.jsx)(`span`,{className:`text-muted-foreground ml-auto shrink-0 text-[11px] uppercase`,children:n.replace(`_`,` `)}),(0,G.jsx)(j,{className:`text-muted-foreground size-3.5 shrink-0`})]})]})})}),(0,G.jsxs)(ug,{children:[o.length>0?(0,G.jsx)(`pre`,{className:`text-muted-foreground mt-1 max-h-24 overflow-auto px-1 text-[11px] leading-snug`,children:JSON.stringify(t,null,2)}):null,s?(0,G.jsxs)(`div`,{className:`mt-2 flex flex-wrap gap-1.5`,children:[r&&(0,G.jsx)(q,{size:`sm`,variant:`default`,onClick:r,children:`Allow once`}),i&&(0,G.jsx)(q,{size:`sm`,variant:`secondary`,onClick:i,children:`Allow always`}),a&&(0,G.jsx)(q,{size:`sm`,variant:`outline`,onClick:a,children:`Reject`})]}):null]})]})})}async function fg(e){let t=await e.text(),n={};if(t)try{n=JSON.parse(t)}catch{throw Error(t.slice(0,180)||`HTTP ${e.status}`)}if(!e.ok)throw Error(n.error||`HTTP ${e.status}`);return n}function pg(e){return e.status??(e.approved===!0?`in_progress`:e.approved===!1?`failed`:`pending`)}function mg({open:e,onClose:t,selectedIssueKey:n,boardView:r,pipeView:i,onApplyPreset:a,onSetFilter:o,onBoardMutated:s,seedPrompt:c,onSeedConsumed:l}){let[u,d]=(0,C.useState)(null),[f,p]=(0,C.useState)([]),[m,h]=(0,C.useState)(null),[g,_]=(0,C.useState)([]),[v,y]=(0,C.useState)(``),[b,x]=(0,C.useState)(!1),[S,w]=(0,C.useState)(!1),[T,E]=(0,C.useState)(null),[D,O]=(0,C.useState)(null),[M,te]=(0,C.useState)([]),[N,F]=(0,C.useState)(null),[ne,re]=(0,C.useState)([]),[ie,I]=(0,C.useState)(null),R=(0,C.useRef)(null),ae=(0,C.useRef)(null),z=(0,C.useRef)(0),B=(0,C.useRef)(null),ce=(0,C.useRef)(null);ce.current=m;let le=(0,C.useRef)(null),ue=(0,C.useCallback)(async(e,t)=>{B.current?.abort();let n=new AbortController;B.current=n;let r=++z.current;w(!0);try{let i=await fg(await fetch(`/api/agent/session`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({agentId:e,model:t}),signal:n.signal}));return r===z.current?(h(i.sessionId),i.models?.length&&te(i.models),i.selectedModel&&O(i.selectedModel),i.sessionId):null}catch(e){return r!==z.current||n.signal.aborted?null:(h(null),_(t=>[...t,{role:`agent`,text:`Failed to start session: ${String(e)}`}]),null)}finally{r===z.current&&w(!1)}},[]);(0,C.useEffect)(()=>{fetch(`/api/agent/config`).then(e=>fg(e)).then(e=>{d(e);let t=e.agents.filter(e=>e.available!==!1),n=t.find(t=>t.id===e.defaultAgent)??t[0]??e.agents[0];E(n?.id??e.defaultAgent),O(n?.model??null),te(n?.models??[]),e.defaultSkill&&F(e.defaultSkill)}).catch(()=>d({defaultAgent:`devin`,agents:[]})),fetch(`/api/agent/skills`).then(e=>fg(e)).then(p).catch(()=>p([]))},[]);let fe=(0,C.useRef)(u);fe.current=u;let pe=(0,C.useRef)(D);pe.current=D,(0,C.useEffect)(()=>{if(!e||!T)return;h(null);let t=fe.current?.agents.find(e=>e.id===T)?.model??null;return ue(T,pe.current??t),()=>{z.current+=1,B.current?.abort(),w(!1)}},[e,T,ue]),(0,C.useEffect)(()=>{if(!m)return;let e=new EventSource(`/api/agent/events?sessionId=${encodeURIComponent(m)}`),t={agent_message_chunk:e=>{let t=e.text??``;_(e=>{let n=e[e.length-1];return n?.role===`agent`?[...e.slice(0,-1),{...n,text:n.text+t}]:[...e,{role:`agent`,text:t}]})},tool_call:e=>{let t=e.name??`unknown`;_(n=>[...n,{role:`tool`,requestId:e.requestId??``,name:t,args:e.args??{},status:`pending`}])},tool_result:e=>{_(t=>t.map(t=>t.role===`tool`&&t.requestId===(e.requestId??``)?{...t,status:`completed`}:t));let t=e.result;t?.__ui_action===`apply_preset`&&t.preset?a?.(t.preset):t?.__ui_action===`set_filter`&&t.filter?o?.(t.filter):t?.__ui_action===`refresh_board`&&s?.()},request_permission:e=>{let t=e.kind??`unknown`;_(n=>[...n,{role:`permission`,requestId:e.requestId??``,kind:t,description:e.description??``}])},config:e=>{e.models?.length&&te(e.models),e.selectedModel&&O(e.selectedModel)},stop_reason:()=>x(!1),error:e=>{x(!1),_(t=>[...t,{role:`agent`,text:`Error: ${e.message??`unknown`}`}])},disconnected:()=>{x(!1),e.close()}};return e.addEventListener(`message`,e=>{let n=JSON.parse(e.data);t[n.type]?.(n)}),()=>e.close()},[m,a,o,s]);let me=(e,t)=>{m&&fetch(`/api/agent/approve`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({sessionId:m,requestId:e,decision:t})}).catch(()=>void 0)},he=async e=>{let t=(e??v).trim();if(!t||b||S)return;e===void 0&&y(``),_(e=>[...e,{role:`user`,text:t}]),x(!0);let n=ne.find(e=>e.kind===`board`),r=[...ne.flatMap(e=>e.kind===`issue`?[{type:`text`,text:`Selected issue: ${e.key}`}]:[]),...n?kn(n.view):i?An({columns:i.columns,epics:i.epics}):[]];try{let e=ce.current;if(!e){if(!T)throw Error(`No agent selected`);if(e=await ue(T,D),!e){x(!1);return}}await fg(await fetch(`/api/agent/prompt`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({sessionId:e,prompt:t,skillId:N,context:r.length?r:void 0})}))}catch(e){x(!1),_(t=>[...t,{role:`agent`,text:`Failed to send: ${String(e)}`}])}};(0,C.useEffect)(()=>{if(!e){le.current=null;return}if(!c){le.current=null;return}if(!m||S||b||le.current===c)return;le.current=c;let t=c;l?.(),he(t)},[e,c,m,S,b,l]);let ge=()=>{m&&(fetch(`/api/agent/cancel`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({sessionId:m})}).catch(()=>void 0),x(!1))},_e=async e=>{if(O(e),m)try{let t=await fg(await fetch(`/api/agent/model`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({sessionId:m,model:e})}));t.models?.length&&te(t.models),t.selectedModel&&O(t.selectedModel)}catch(e){_(t=>[...t,{role:`agent`,text:`Failed to set model: ${String(e)}`}])}},ve=async()=>{if(T)try{let e=await fg(await fetch(`/api/agent/config`,{method:`POST`,headers:{"content-type":`application/json`},body:JSON.stringify({defaultAgent:T,agents:{[T]:{model:D}}})}));d(e)}catch(e){_(t=>[...t,{role:`agent`,text:`Failed to save default: ${String(e)}`}])}},ye=(e,t)=>{me(e,t),_(n=>n.map(n=>n.role===`tool`&&n.requestId===e?{...n,approved:t!==`reject`,status:t===`reject`?`failed`:`in_progress`}:n))},be=(e,t)=>{me(e,t)},xe=()=>{n&&re(e=>[...e.filter(e=>e.kind!==`issue`),{kind:`issue`,key:n}])},Se=()=>{r&&re(e=>[...e.filter(e=>e.kind!==`board`),{kind:`board`,view:r}])},Ce=e=>{re(t=>t.filter(t=>t.kind!==e))};(0,C.useEffect)(()=>{R.current?.scrollIntoView({behavior:`smooth`})},[g]),(0,C.useEffect)(()=>{let e=ae.current;e&&(e.style.height=`auto`,e.style.height=`${Math.min(e.scrollHeight,128)}px`)},[v]);let we=(0,C.useMemo)(()=>u?.agents.find(e=>e.id===T),[u,T]),Te=M.length?M:we?.models??[],Ee=(0,C.useMemo)(()=>Te.find(e=>e.id===D)?.name??D??`Model`,[Te,D]),De=(0,C.useMemo)(()=>f.find(e=>e.id===N)?.name??N,[f,N]),Oe=u?.defaultAgent===T&&(we?.model??null)===D,ke=(0,C.useMemo)(()=>n?[`Tell me about ${n}`,`What's blocked?`,`What should I work on next?`]:[`Summarize this board`,`What's blocked?`,`What should I work on next?`],[n]),Ae=g[g.length-1],je=Ae?.role===`permission`||Ae?.role===`tool`&&pg(Ae)===`pending`,Me=Ae?.role===`agent`&&Ae.text.length>0,Ne=S||b&&!je&&!Me;return e?(0,G.jsx)(Wh,{id:`agent`,defaultSize:`320px`,minSize:`16rem`,maxSize:`50%`,className:`min-h-0`,children:(0,G.jsxs)(`div`,{className:`bg-background flex h-full min-h-0 flex-col`,children:[(0,G.jsxs)(`header`,{className:`shrink-0 border-b px-3 py-2`,children:[(0,G.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,G.jsx)(ui,{className:`bg-primary/10 text-primary size-6`,children:(0,G.jsx)(di,{children:(0,G.jsx)(k,{className:`size-3.5`})})}),(0,G.jsx)(`div`,{className:`min-w-0 flex-1`,children:(0,G.jsx)(`p`,{className:`text-sm font-medium leading-none`,children:`Agent`})}),S?(0,G.jsx)(gi,{variant:`outline`,children:`Starting`}):b?(0,G.jsx)(gi,{variant:`primary-light`,children:`Live`}):m?(0,G.jsx)(gi,{variant:`outline`,children:`Ready`}):null,(0,G.jsx)(q,{type:`button`,variant:`ghost`,size:`icon-xs`,"aria-label":`Close`,title:`Close`,onClick:t,children:(0,G.jsx)(de,{})})]}),(0,G.jsxs)(`div`,{className:`mt-2 flex flex-wrap items-center gap-1`,children:[(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`outline`,size:`sm`,className:`h-6 rounded-full px-2 text-xs capitalize`,children:[T??`Agent`,(0,G.jsx)(j,{className:`size-3`})]})}),(0,G.jsxs)(Tp,{align:`start`,children:[u?.agents.map(e=>(0,G.jsxs)(Dp,{disabled:e.available===!1,onClick:()=>{E(e.id),O(e.model??null),te(e.models??[])},children:[(0,G.jsx)(`span`,{className:`capitalize`,children:e.id}),e.available===!1?` (not found)`:``]},e.id)),(0,G.jsx)(jp,{}),(0,G.jsx)(Dp,{disabled:!T||Oe,onClick:()=>void ve(),children:Oe?`Default`:`Set as default`})]})]}),T&&(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`outline`,size:`sm`,className:`text-muted-foreground h-6 rounded-full px-2 text-xs`,children:[Ee,(0,G.jsx)(j,{className:`size-3`})]})}),(0,G.jsx)(Tp,{align:`start`,children:Te.map(e=>(0,G.jsxs)(Dp,{onClick:()=>void _e(e.id),children:[e.name,e.description?` — ${e.description}`:``]},e.id))})]}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`outline`,size:`sm`,className:`h-6 rounded-full px-2 text-xs`,children:[De??`Skill`,(0,G.jsx)(j,{className:`size-3`})]})}),(0,G.jsxs)(Tp,{align:`end`,children:[(0,G.jsx)(Dp,{onClick:()=>F(null),children:`None`}),f.map(e=>(0,G.jsx)(Dp,{onClick:()=>F(e.id),children:e.name},e.id))]})]})]})]}),(0,G.jsxs)(`div`,{className:W(`min-h-0 flex-1 overflow-y-auto px-3 py-3`,g.length>0&&`scroll-fade`),children:[g.length===0?(0,G.jsxs)(`div`,{className:`flex h-full flex-col items-center justify-center gap-3 px-2 text-center`,children:[(0,G.jsx)(`span`,{className:`bg-muted flex size-10 items-center justify-center rounded-full`,children:(0,G.jsx)(oe,{className:`size-5`})}),(0,G.jsxs)(`div`,{className:`space-y-1`,children:[(0,G.jsx)(`p`,{className:`text-sm font-medium`,children:`Ask the agent`}),S?(0,G.jsx)(`p`,{className:`shimmer text-muted-foreground text-xs`,children:`Starting session…`}):(0,G.jsx)(`p`,{className:`text-muted-foreground text-xs`,children:`About this board, or attach a skill or issue.`})]}),(0,G.jsx)(`div`,{className:`flex flex-wrap justify-center gap-1.5`,children:ke.map(e=>(0,G.jsx)(q,{type:`button`,variant:`outline`,size:`sm`,className:`h-7 rounded-full text-xs`,disabled:b||S,onClick:()=>void he(e),children:e},e))})]}):(0,G.jsx)(`div`,{className:`flex flex-col gap-3`,children:g.map((e,t)=>(0,G.jsx)(C.Fragment,{children:{user:e=>e.role===`user`?(0,G.jsx)(zp,{align:`end`,children:(0,G.jsx)(Bp,{children:(0,G.jsx)(vi,{variant:`default`,children:(0,G.jsx)(yi,{children:e.text})})})}):null,agent:(e,t)=>e.role===`agent`?(0,G.jsx)(zp,{align:`start`,children:(0,G.jsxs)(Bp,{children:[(0,G.jsx)(vi,{variant:`muted`,children:(0,G.jsx)(yi,{children:e.text})}),(0,G.jsx)(Vp,{children:(0,G.jsx)(q,{type:`button`,variant:`ghost`,size:`icon-xs`,className:`text-muted-foreground`,"aria-label":`Copy`,title:`Copy`,onClick:n=>{n.preventDefault(),n.stopPropagation();let r=()=>{I(t),window.setTimeout(()=>{I(e=>e===t?null:e)},1500)};try{Fn(e.text),r()}catch{Nn(e.text).then(r).catch(()=>void 0)}},children:ie===t?(0,G.jsx)(A,{}):(0,G.jsx)(P,{})})})]})}):null,tool:e=>{if(e.role!==`tool`)return null;let t=pg(e);return(0,G.jsx)(dg,{name:e.name,args:e.args,status:t,onApprove:t===`pending`?()=>ye(e.requestId,`once`):void 0,onAllowAlways:t===`pending`?()=>ye(e.requestId,`always`):void 0,onReject:t===`pending`?()=>ye(e.requestId,`reject`):void 0})},permission:e=>e.role===`permission`?(0,G.jsx)(Kh,{kind:e.kind,description:e.description,onAllowOnce:()=>be(e.requestId,`once`),onAllowAlways:()=>be(e.requestId,`always`),onReject:()=>be(e.requestId,`reject`)}):null}[e.role](e,t)},t))}),g.length>0&&Ne?(0,G.jsxs)(Ip,{role:`status`,className:`mt-2`,children:[(0,G.jsx)(Lp,{children:(0,G.jsx)(L,{className:`animate-spin`})}),(0,G.jsx)(Rp,{className:`shimmer`,children:S?`Starting session…`:`Thinking…`})]}):null,(0,G.jsx)(`div`,{ref:R})]}),(0,G.jsx)(`div`,{className:`shrink-0 p-2`,children:(0,G.jsxs)(`form`,{className:`bg-background rounded-2xl border p-2 shadow-xs`,onSubmit:e=>{e.preventDefault(),he()},children:[(N||ne.length>0)&&(0,G.jsxs)(`div`,{className:`mb-1.5 flex flex-wrap gap-1`,children:[N&&(0,G.jsxs)(`span`,{className:`bg-muted inline-flex items-center gap-1 rounded-full px-2 py-0.5 text-xs`,children:[De,(0,G.jsx)(`button`,{type:`button`,className:`text-muted-foreground`,onClick:()=>F(null),children:`×`})]}),ne.map((e,t)=>(0,G.jsxs)(`span`,{className:`bg-muted inline-flex items-center gap-1 rounded-full px-2 py-0.5 text-xs`,children:[e.kind===`issue`?`Issue ${e.key}`:e.kind===`board`?`Board view`:e.label,(0,G.jsx)(`button`,{type:`button`,className:`text-muted-foreground`,onClick:()=>Ce(e.kind),children:`×`})]},`${e.kind}-${t}`))]}),(0,G.jsx)(`textarea`,{ref:ae,rows:1,value:v,onChange:e=>y(e.target.value),onKeyDown:e=>{e.key===`Enter`&&!e.shiftKey&&(e.preventDefault(),he())},placeholder:`Ask the agent…`,disabled:b||S,className:`placeholder:text-muted-foreground max-h-32 min-h-8 w-full resize-none bg-transparent px-1 py-1 text-sm outline-none disabled:cursor-not-allowed disabled:opacity-50`}),(0,G.jsxs)(`div`,{className:`mt-1 flex items-end justify-between gap-1`,children:[(0,G.jsxs)(`div`,{className:`flex min-w-0 flex-wrap gap-1`,children:[n&&!ne.some(e=>e.kind===`issue`)&&(0,G.jsx)(q,{type:`button`,variant:`ghost`,size:`sm`,className:`h-7 text-xs`,onClick:xe,children:`Attach issue`}),r&&!ne.some(e=>e.kind===`board`)&&(0,G.jsx)(q,{type:`button`,variant:`ghost`,size:`sm`,className:`h-7 text-xs`,onClick:Se,children:`Attach board view`})]}),b?(0,G.jsx)(q,{type:`button`,variant:`secondary`,size:`icon`,className:`size-8 shrink-0 rounded-full`,"aria-label":`Stop`,title:`Stop`,onClick:ge,children:(0,G.jsx)(se,{})}):(0,G.jsx)(q,{type:`submit`,size:`icon`,className:`size-8 shrink-0 rounded-full`,"aria-label":`Send`,title:`Send`,disabled:b||S||!v.trim(),children:(0,G.jsx)(ee,{})})]})]})})]})}):null}var hg,Z,gg,_g,vg,yg,bg,xg,Sg,Cg={},wg=[],Tg=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function Eg(e,t){for(var n in t)e[n]=t[n];return e}function Dg(e){var t=e.parentNode;t&&t.removeChild(e)}function Q(e,t,n){var r,i,a,o={};for(a in t)a==`key`?r=t[a]:a==`ref`?i=t[a]:o[a]=t[a];if(arguments.length>2&&(o.children=arguments.length>3?hg.call(arguments,2):n),typeof e==`function`&&e.defaultProps!=null)for(a in e.defaultProps)o[a]===void 0&&(o[a]=e.defaultProps[a]);return Og(e,o,r,i,null)}function Og(e,t,n,r,i){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:i??++gg};return i==null&&Z.vnode!=null&&Z.vnode(a),a}function kg(){return{current:null}}function Ag(e){return e.children}function jg(e,t,n,r,i){for(var a in n)a===`children`||a===`key`||a in t||Ng(e,a,null,n[a],r);for(a in t)i&&typeof t[a]!=`function`||a===`children`||a===`key`||a===`value`||a===`checked`||n[a]===t[a]||Ng(e,a,t[a],n[a],r)}function Mg(e,t,n){t[0]===`-`?e.setProperty(t,n??``):e[t]=n==null?``:typeof n!=`number`||Tg.test(t)?n:n+`px`}function Ng(e,t,n,r,i){var a;n:if(t===`style`){if(typeof n==`string`)e.style.cssText=n;else{if(typeof r==`string`&&(e.style.cssText=r=``),r)for(t in r)n&&t in n||Mg(e.style,t,``);if(n)for(t in n)r&&n[t]===r[t]||Mg(e.style,t,n[t])}}else if(t[0]===`o`&&t[1]===`n`)a=t!==(t=t.replace(/Capture$/,``)),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||={},e.l[t+a]=n,n?r||e.addEventListener(t,a?Fg:Pg,a):e.removeEventListener(t,a?Fg:Pg,a);else if(t!==`dangerouslySetInnerHTML`){if(i)t=t.replace(/xlink(H|:h)/,`h`).replace(/sName$/,`s`);else if(t!==`width`&&t!==`height`&&t!==`href`&&t!==`list`&&t!==`form`&&t!==`tabIndex`&&t!==`download`&&t in e)try{e[t]=n??``;break n}catch{}typeof n==`function`||(n==null||!1===n&&t.indexOf(`-`)==-1?e.removeAttribute(t):e.setAttribute(t,n))}}function Pg(e){vg=!0;try{return this.l[e.type+!1](Z.event?Z.event(e):e)}finally{vg=!1}}function Fg(e){vg=!0;try{return this.l[e.type+!0](Z.event?Z.event(e):e)}finally{vg=!1}}function Ig(e,t){this.props=e,this.context=t}function Lg(e,t){if(t==null)return e.__?Lg(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type==`function`?Lg(e):null}function Rg(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Rg(e)}}function zg(e){vg?setTimeout(e):xg(e)}function Bg(e){(!e.__d&&(e.__d=!0)&&yg.push(e)&&!Vg.__r++||bg!==Z.debounceRendering)&&((bg=Z.debounceRendering)||zg)(Vg)}function Vg(){var e,t,n,r,i,a,o,s;for(yg.sort(function(e,t){return e.__v.__b-t.__v.__b});e=yg.shift();)e.__d&&(t=yg.length,r=void 0,i=void 0,o=(a=(n=e).__v).__e,(s=n.__P)&&(r=[],(i=Eg({},a)).__v=a.__v+1,qg(s,a,i,n.__n,s.ownerSVGElement!==void 0,a.__h==null?null:[o],r,o??Lg(a),a.__h),Jg(r,a),a.__e!=o&&Rg(a)),yg.length>t&&yg.sort(function(e,t){return e.__v.__b-t.__v.__b}));Vg.__r=0}function Hg(e,t,n,r,i,a,o,s,c,l){var u,d,f,p,m,h,g,_=r&&r.__k||wg,v=_.length;for(n.__k=[],u=0;u<t.length;u++)if((p=n.__k[u]=(p=t[u])==null||typeof p==`boolean`?null:typeof p==`string`||typeof p==`number`||typeof p==`bigint`?Og(null,p,null,null,p):Array.isArray(p)?Og(Ag,{children:p},null,null,null):p.__b>0?Og(p.type,p.props,p.key,p.ref?p.ref:null,p.__v):p)!=null){if(p.__=n,p.__b=n.__b+1,(f=_[u])===null||f&&p.key==f.key&&p.type===f.type)_[u]=void 0;else for(d=0;d<v;d++){if((f=_[d])&&p.key==f.key&&p.type===f.type){_[d]=void 0;break}f=null}qg(e,p,f||=Cg,i,a,o,s,c,l),m=p.__e,(d=p.ref)&&f.ref!=d&&(g||=[],f.ref&&g.push(f.ref,null,p),g.push(d,p.__c||m,p)),m==null?c&&f.__e==c&&c.parentNode!=e&&(c=Lg(f)):(h??=m,typeof p.type==`function`&&p.__k===f.__k?p.__d=c=Ug(p,c,e):c=Gg(e,p,f,_,m,c),typeof n.type==`function`&&(n.__d=c))}for(n.__e=h,u=v;u--;)_[u]!=null&&(typeof n.type==`function`&&_[u].__e!=null&&_[u].__e==n.__d&&(n.__d=Kg(r).nextSibling),Zg(_[u],_[u]));if(g)for(u=0;u<g.length;u++)Xg(g[u],g[++u],g[++u])}function Ug(e,t,n){for(var r,i=e.__k,a=0;i&&a<i.length;a++)(r=i[a])&&(r.__=e,t=typeof r.type==`function`?Ug(r,t,n):Gg(n,r,r,i,r.__e,t));return t}function Wg(e,t){return t||=[],e==null||typeof e==`boolean`||(Array.isArray(e)?e.some(function(e){Wg(e,t)}):t.push(e)),t}function Gg(e,t,n,r,i,a){var o,s,c;if(t.__d!==void 0)o=t.__d,t.__d=void 0;else if(n==null||i!=a||i.parentNode==null)n:if(a==null||a.parentNode!==e)e.appendChild(i),o=null;else{for(s=a,c=0;(s=s.nextSibling)&&c<r.length;c+=1)if(s==i)break n;e.insertBefore(i,a),o=a}return o===void 0?i.nextSibling:o}function Kg(e){var t,n,r;if(e.type==null||typeof e.type==`string`)return e.__e;if(e.__k){for(t=e.__k.length-1;t>=0;t--)if((n=e.__k[t])&&(r=Kg(n)))return r}return null}function qg(e,t,n,r,i,a,o,s,c){var l,u,d,f,p,m,h,g,_,v,y,b,x,S,C,w=t.type;if(t.constructor!==void 0)return null;n.__h!=null&&(c=n.__h,s=t.__e=n.__e,t.__h=null,a=[s]),(l=Z.__b)&&l(t);try{n:if(typeof w==`function`){if(g=t.props,_=(l=w.contextType)&&r[l.__c],v=l?_?_.props.value:l.__:r,n.__c?h=(u=t.__c=n.__c).__=u.__E:(`prototype`in w&&w.prototype.render?t.__c=u=new w(g,v):(t.__c=u=new Ig(g,v),u.constructor=w,u.render=Qg),_&&_.sub(u),u.props=g,u.state||(u.state={}),u.context=v,u.__n=r,d=u.__d=!0,u.__h=[],u._sb=[]),u.__s??(u.__s=u.state),w.getDerivedStateFromProps!=null&&(u.__s==u.state&&(u.__s=Eg({},u.__s)),Eg(u.__s,w.getDerivedStateFromProps(g,u.__s))),f=u.props,p=u.state,u.__v=t,d)w.getDerivedStateFromProps==null&&u.componentWillMount!=null&&u.componentWillMount(),u.componentDidMount!=null&&u.__h.push(u.componentDidMount);else{if(w.getDerivedStateFromProps==null&&g!==f&&u.componentWillReceiveProps!=null&&u.componentWillReceiveProps(g,v),!u.__e&&u.shouldComponentUpdate!=null&&!1===u.shouldComponentUpdate(g,u.__s,v)||t.__v===n.__v){for(t.__v!==n.__v&&(u.props=g,u.state=u.__s,u.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.forEach(function(e){e&&(e.__=t)}),y=0;y<u._sb.length;y++)u.__h.push(u._sb[y]);u._sb=[],u.__h.length&&o.push(u);break n}u.componentWillUpdate!=null&&u.componentWillUpdate(g,u.__s,v),u.componentDidUpdate!=null&&u.__h.push(function(){u.componentDidUpdate(f,p,m)})}if(u.context=v,u.props=g,u.__P=e,b=Z.__r,x=0,`prototype`in w&&w.prototype.render){for(u.state=u.__s,u.__d=!1,b&&b(t),l=u.render(u.props,u.state,u.context),S=0;S<u._sb.length;S++)u.__h.push(u._sb[S]);u._sb=[]}else do u.__d=!1,b&&b(t),l=u.render(u.props,u.state,u.context),u.state=u.__s;while(u.__d&&++x<25);u.state=u.__s,u.getChildContext!=null&&(r=Eg(Eg({},r),u.getChildContext())),d||u.getSnapshotBeforeUpdate==null||(m=u.getSnapshotBeforeUpdate(f,p)),C=l!=null&&l.type===Ag&&l.key==null?l.props.children:l,Hg(e,Array.isArray(C)?C:[C],t,n,r,i,a,o,s,c),u.base=t.__e,t.__h=null,u.__h.length&&o.push(u),h&&(u.__E=u.__=null),u.__e=!1}else a==null&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=Yg(n.__e,t,n,r,i,a,o,c);(l=Z.diffed)&&l(t)}catch(e){t.__v=null,(c||a!=null)&&(t.__e=s,t.__h=!!c,a[a.indexOf(s)]=null),Z.__e(e,t,n)}}function Jg(e,t){Z.__c&&Z.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){Z.__e(e,t.__v)}})}function Yg(e,t,n,r,i,a,o,s){var c,l,u,d=n.props,f=t.props,p=t.type,m=0;if(p===`svg`&&(i=!0),a!=null){for(;m<a.length;m++)if((c=a[m])&&`setAttribute`in c==!!p&&(p?c.localName===p:c.nodeType===3)){e=c,a[m]=null;break}}if(e==null){if(p===null)return document.createTextNode(f);e=i?document.createElementNS(`http://www.w3.org/2000/svg`,p):document.createElement(p,f.is&&f),a=null,s=!1}if(p===null)d===f||s&&e.data===f||(e.data=f);else{if(a&&=hg.call(e.childNodes),l=(d=n.props||Cg).dangerouslySetInnerHTML,u=f.dangerouslySetInnerHTML,!s){if(a!=null)for(d={},m=0;m<e.attributes.length;m++)d[e.attributes[m].name]=e.attributes[m].value;(u||l)&&(u&&(l&&u.__html==l.__html||u.__html===e.innerHTML)||(e.innerHTML=u&&u.__html||``))}if(jg(e,f,d,i,s),u)t.__k=[];else if(m=t.props.children,Hg(e,Array.isArray(m)?m:[m],t,n,r,i&&p!==`foreignObject`,a,o,a?a[0]:n.__k&&Lg(n,0),s),a!=null)for(m=a.length;m--;)a[m]!=null&&Dg(a[m]);s||(`value`in f&&(m=f.value)!==void 0&&(m!==e.value||p===`progress`&&!m||p===`option`&&m!==d.value)&&Ng(e,`value`,m,d.value,!1),`checked`in f&&(m=f.checked)!==void 0&&m!==e.checked&&Ng(e,`checked`,m,d.checked,!1))}return e}function Xg(e,t,n){try{typeof e==`function`?e(t):e.current=t}catch(e){Z.__e(e,n)}}function Zg(e,t,n){var r,i;if(Z.unmount&&Z.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Xg(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){Z.__e(e,t)}r.base=r.__P=null,e.__c=void 0}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&Zg(r[i],t,n||typeof e.type!=`function`);n||e.__e==null||Dg(e.__e),e.__=e.__e=e.__d=void 0}function Qg(e,t,n){return this.constructor(e,n)}function $g(e,t,n){var r,i,a;Z.__&&Z.__(e,t),i=(r=typeof n==`function`)?null:n&&n.__k||t.__k,a=[],qg(t,e=(!r&&n||t).__k=Q(Ag,null,[e]),i||Cg,Cg,t.ownerSVGElement!==void 0,!r&&n?[n]:i?null:t.firstChild?hg.call(t.childNodes):null,a,!r&&n?n:i?i.__e:t.firstChild,r),Jg(a,e)}function e_(e,t){var n={__c:t=`__cC`+Sg++,__:e,Consumer:function(e,t){return e.children(t)},Provider:function(e){var n,r;return this.getChildContext||(n=[],(r={})[t]=this,this.getChildContext=function(){return r},this.shouldComponentUpdate=function(e){this.props.value!==e.value&&n.some(function(e){e.__e=!0,Bg(e)})},this.sub=function(e){n.push(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n.splice(n.indexOf(e),1),t&&t.call(e)}}),e.children}};return n.Provider.__=n.Consumer.contextType=n}hg=wg.slice,Z={__e:function(e,t,n,r){for(var i,a,o;t=t.__;)if((i=t.__c)&&!i.__)try{if((a=i.constructor)&&a.getDerivedStateFromError!=null&&(i.setState(a.getDerivedStateFromError(e)),o=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),o=i.__d),o)return i.__E=i}catch(t){e=t}throw e}},gg=0,_g=function(e){return e!=null&&e.constructor===void 0},vg=!1,Ig.prototype.setState=function(e,t){var n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=Eg({},this.state);typeof e==`function`&&(e=e(Eg({},n),this.props)),e&&Eg(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),Bg(this))},Ig.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),Bg(this))},Ig.prototype.render=Ag,yg=[],xg=typeof Promise==`function`?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Vg.__r=0,Sg=0;var t_,n_,r_,i_=[],a_=[],o_=Z.__b,s_=Z.__r,c_=Z.diffed,l_=Z.__c,u_=Z.unmount;function d_(){for(var e;e=i_.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(m_),e.__H.__h.forEach(h_),e.__H.__h=[]}catch(t){e.__H.__h=[],Z.__e(t,e.__v)}}Z.__b=function(e){t_=null,o_&&o_(e)},Z.__r=function(e){s_&&s_(e);var t=(t_=e.__c).__H;t&&(n_===t_?(t.__h=[],t_.__h=[],t.__.forEach(function(e){e.__N&&(e.__=e.__N),e.__V=a_,e.__N=e.i=void 0})):(t.__h.forEach(m_),t.__h.forEach(h_),t.__h=[])),n_=t_},Z.diffed=function(e){c_&&c_(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(i_.push(t)!==1&&r_===Z.requestAnimationFrame||((r_=Z.requestAnimationFrame)||p_)(d_)),t.__H.__.forEach(function(e){e.i&&(e.__H=e.i),e.__V!==a_&&(e.__=e.__V),e.i=void 0,e.__V=a_})),n_=t_=null},Z.__c=function(e,t){t.some(function(e){try{e.__h.forEach(m_),e.__h=e.__h.filter(function(e){return!e.__||h_(e)})}catch(n){t.some(function(e){e.__h&&=[]}),t=[],Z.__e(n,e.__v)}}),l_&&l_(e,t)},Z.unmount=function(e){u_&&u_(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(e){try{m_(e)}catch(e){t=e}}),n.__H=void 0,t&&Z.__e(t,n.__v))};var f_=typeof requestAnimationFrame==`function`;function p_(e){var t,n=function(){clearTimeout(r),f_&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);f_&&(t=requestAnimationFrame(n))}function m_(e){var t=t_,n=e.__c;typeof n==`function`&&(e.__c=void 0,n()),t_=t}function h_(e){var t=t_;e.__c=e.__(),t_=t}function g_(e,t){for(var n in t)e[n]=t[n];return e}function __(e,t){for(var n in e)if(n!==`__source`&&!(n in t))return!0;for(var r in t)if(r!==`__source`&&e[r]!==t[r])return!0;return!1}function v_(e){this.props=e}(v_.prototype=new Ig).isPureReactComponent=!0,v_.prototype.shouldComponentUpdate=function(e,t){return __(this.props,e)||__(this.state,t)};var y_=Z.__b;Z.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),y_&&y_(e)},typeof Symbol<`u`&&Symbol.for;var b_=Z.__e;Z.__e=function(e,t,n,r){if(e.then){for(var i,a=t;a=a.__;)if((i=a.__c)&&i.__c)return t.__e??(t.__e=n.__e,t.__k=n.__k),i.__c(e,t)}b_(e,t,n,r)};var x_=Z.unmount;function S_(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(e){typeof e.__c==`function`&&e.__c()}),e.__c.__H=null),(e=g_({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(e){return S_(e,t,n)})),e}function C_(e,t,n){return e&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(e){return C_(e,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.insertBefore(e.__e,e.__d),e.__c.__e=!0,e.__c.__P=n)),e}function w_(){this.__u=0,this.t=null,this.__b=null}function T_(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function E_(){this.u=null,this.o=null}Z.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&!0===e.__h&&(e.type=null),x_&&x_(e)},(w_.prototype=new Ig).__c=function(e,t){var n=t.__c,r=this;r.t??=[],r.t.push(n);var i=T_(r.__v),a=!1,o=function(){a||(a=!0,n.__R=null,i?i(s):s())};n.__R=o;var s=function(){if(!--r.__u){if(r.state.__a){var e=r.state.__a;r.__v.__k[0]=C_(e,e.__c.__P,e.__c.__O)}var t;for(r.setState({__a:r.__b=null});t=r.t.pop();)t.forceUpdate()}},c=!0===t.__h;r.__u++||c||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(o,o)},w_.prototype.componentWillUnmount=function(){this.t=[]},w_.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement(`div`),r=this.__v.__k[0].__c;this.__v.__k[0]=S_(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&Q(Ag,null,e.fallback);return i&&(i.__h=null),[Q(Ag,null,t.__a?null:e.children),i]};var D_=function(e,t,n){if(++n[1]===n[0]&&e.o.delete(t),e.props.revealOrder&&(e.props.revealOrder[0]!==`t`||!e.o.size))for(n=e.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.u=n=n[2]}};function O_(e){return this.getChildContext=function(){return e.context},e.children}function k_(e){var t=this,n=e.i;t.componentWillUnmount=function(){$g(null,t.l),t.l=null,t.i=null},t.i&&t.i!==n&&t.componentWillUnmount(),e.__v?(t.l||=(t.i=n,{nodeType:1,parentNode:n,childNodes:[],appendChild:function(e){this.childNodes.push(e),t.i.appendChild(e)},insertBefore:function(e,n){this.childNodes.push(e),t.i.appendChild(e)},removeChild:function(e){this.childNodes.splice(this.childNodes.indexOf(e)>>>1,1),t.i.removeChild(e)}}),$g(Q(O_,{context:t.context},e.__v),t.l)):t.l&&t.componentWillUnmount()}function A_(e,t){var n=Q(k_,{__v:e,i:t});return n.containerInfo=t,n}(E_.prototype=new Ig).__a=function(e){var t=this,n=T_(t.__v),r=t.o.get(e);return r[0]++,function(i){var a=function(){t.props.revealOrder?(r.push(i),D_(t,e,r)):i()};n?n(a):a()}},E_.prototype.render=function(e){this.u=null,this.o=new Map;var t=Wg(e.children);e.revealOrder&&e.revealOrder[0]===`b`&&t.reverse();for(var n=t.length;n--;)this.o.set(t[n],this.u=[1,0,this.u]);return e.children},E_.prototype.componentDidUpdate=E_.prototype.componentDidMount=function(){var e=this;this.o.forEach(function(t,n){D_(e,n,t)})};var j_=typeof Symbol<`u`&&Symbol.for&&Symbol.for(`react.element`)||60103,M_=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,N_=typeof document<`u`,P_=function(e){return(typeof Symbol<`u`&&typeof Symbol()==`symbol`?/fil|che|rad/i:/fil|che|ra/i).test(e)};Ig.prototype.isReactComponent={},[`componentWillMount`,`componentWillReceiveProps`,`componentWillUpdate`].forEach(function(e){Object.defineProperty(Ig.prototype,e,{configurable:!0,get:function(){return this[`UNSAFE_`+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var F_=Z.event;function I_(){}function L_(){return this.cancelBubble}function R_(){return this.defaultPrevented}Z.event=function(e){return F_&&(e=F_(e)),e.persist=I_,e.isPropagationStopped=L_,e.isDefaultPrevented=R_,e.nativeEvent=e};var z_={configurable:!0,get:function(){return this.class}},B_=Z.vnode;Z.vnode=function(e){var t=e.type,n=e.props,r=n;if(typeof t==`string`){var i=t.indexOf(`-`)===-1;for(var a in r={},n){var o=n[a];N_&&a===`children`&&t===`noscript`||a===`value`&&`defaultValue`in n&&o==null||(a===`defaultValue`&&`value`in n&&n.value==null?a=`value`:a===`download`&&!0===o?o=``:/ondoubleclick/i.test(a)?a=`ondblclick`:/^onchange(textarea|input)/i.test(a+t)&&!P_(n.type)?a=`oninput`:/^onfocus$/i.test(a)?a=`onfocusin`:/^onblur$/i.test(a)?a=`onfocusout`:/^on(Ani|Tra|Tou|BeforeInp|Compo)/.test(a)?a=a.toLowerCase():i&&M_.test(a)?a=a.replace(/[A-Z0-9]/g,`-$&`).toLowerCase():o===null&&(o=void 0),/^oninput$/i.test(a)&&(a=a.toLowerCase(),r[a]&&(a=`oninputCapture`)),r[a]=o)}t==`select`&&r.multiple&&Array.isArray(r.value)&&(r.value=Wg(n.children).forEach(function(e){e.props.selected=r.value.indexOf(e.props.value)!=-1})),t==`select`&&r.defaultValue!=null&&(r.value=Wg(n.children).forEach(function(e){e.props.selected=r.multiple?r.defaultValue.indexOf(e.props.value)!=-1:r.defaultValue==e.props.value})),e.props=r,n.class!=n.className&&(z_.enumerable=`className`in n,n.className!=null&&(r.class=n.className),Object.defineProperty(r,"className",z_))}e.$$typeof=j_,B_&&B_(e)};var V_=Z.__r;Z.__r=function(e){V_&&V_(e),e.__c};var H_=[],U_=new Map;function W_(e){H_.push(e),U_.forEach(t=>{J_(t,e)})}function G_(e){e.isConnected&&e.getRootNode&&K_(e.getRootNode())}function K_(e){let t=U_.get(e);if(!t||!t.isConnected){if(t=e.querySelector(`style[data-fullcalendar]`),!t){t=document.createElement(`style`),t.setAttribute(`data-fullcalendar`,``);let n=X_();n&&(t.nonce=n);let r=e===document?document.head:e,i=e===document?r.querySelector(`script,link[rel=stylesheet],link[as=style],style`):r.firstChild;r.insertBefore(t,i)}U_.set(e,t),q_(t)}}function q_(e){for(let t of H_)J_(e,t)}function J_(e,t){let{sheet:n}=e,r=n.cssRules.length;t.split(`}`).forEach((e,t)=>{e=e.trim(),e&&n.insertRule(e+`}`,r+t)})}var Y_;function X_(){return Y_===void 0&&(Y_=Z_()),Y_}function Z_(){let e=document.querySelector(`meta[name="csp-nonce"]`);if(e&&e.hasAttribute(`content`))return e.getAttribute(`content`);let t=document.querySelector(`script[nonce]`);return t&&t.nonce||``}typeof document<`u`&&K_(document),W_(`:root{--fc-small-font-size:.85em;--fc-page-bg-color:#fff;--fc-neutral-bg-color:hsla(0,0%,82%,.3);--fc-neutral-text-color:grey;--fc-border-color:#ddd;--fc-button-text-color:#fff;--fc-button-bg-color:#2c3e50;--fc-button-border-color:#2c3e50;--fc-button-hover-bg-color:#1e2b37;--fc-button-hover-border-color:#1a252f;--fc-button-active-bg-color:#1a252f;--fc-button-active-border-color:#151e27;--fc-event-bg-color:#3788d8;--fc-event-border-color:#3788d8;--fc-event-text-color:#fff;--fc-event-selected-overlay-color:rgba(0,0,0,.25);--fc-more-link-bg-color:#d0d0d0;--fc-more-link-text-color:inherit;--fc-event-resizer-thickness:8px;--fc-event-resizer-dot-total-width:8px;--fc-event-resizer-dot-border-width:1px;--fc-non-business-color:hsla(0,0%,84%,.3);--fc-bg-event-color:#8fdf82;--fc-bg-event-opacity:0.3;--fc-highlight-color:rgba(188,232,241,.3);--fc-today-bg-color:rgba(255,220,40,.15);--fc-now-indicator-color:red}.fc-not-allowed,.fc-not-allowed .fc-event{cursor:not-allowed}.fc{display:flex;flex-direction:column;font-size:1em}.fc,.fc *,.fc :after,.fc :before{box-sizing:border-box}.fc table{border-collapse:collapse;border-spacing:0;font-size:1em}.fc th{text-align:center}.fc td,.fc th{padding:0;vertical-align:top}.fc a[data-navlink]{cursor:pointer}.fc a[data-navlink]:hover{text-decoration:underline}.fc-direction-ltr{direction:ltr;text-align:left}.fc-direction-rtl{direction:rtl;text-align:right}.fc-theme-standard td,.fc-theme-standard th{border:1px solid var(--fc-border-color)}.fc-liquid-hack td,.fc-liquid-hack th{position:relative}@font-face{font-family:fcicons;font-style:normal;font-weight:400;src:url("data:application/x-font-ttf;charset=utf-8;base64,AAEAAAALAIAAAwAwT1MvMg8SBfAAAAC8AAAAYGNtYXAXVtKNAAABHAAAAFRnYXNwAAAAEAAAAXAAAAAIZ2x5ZgYydxIAAAF4AAAFNGhlYWQUJ7cIAAAGrAAAADZoaGVhB20DzAAABuQAAAAkaG10eCIABhQAAAcIAAAALGxvY2ED4AU6AAAHNAAAABhtYXhwAA8AjAAAB0wAAAAgbmFtZXsr690AAAdsAAABhnBvc3QAAwAAAAAI9AAAACAAAwPAAZAABQAAApkCzAAAAI8CmQLMAAAB6wAzAQkAAAAAAAAAAAAAAAAAAAABEAAAAAAAAAAAAAAAAAAAAABAAADpBgPA/8AAQAPAAEAAAAABAAAAAAAAAAAAAAAgAAAAAAADAAAAAwAAABwAAQADAAAAHAADAAEAAAAcAAQAOAAAAAoACAACAAIAAQAg6Qb//f//AAAAAAAg6QD//f//AAH/4xcEAAMAAQAAAAAAAAAAAAAAAQAB//8ADwABAAAAAAAAAAAAAgAANzkBAAAAAAEAAAAAAAAAAAACAAA3OQEAAAAAAQAAAAAAAAAAAAIAADc5AQAAAAABAWIAjQKeAskAEwAAJSc3NjQnJiIHAQYUFwEWMjc2NCcCnuLiDQ0MJAz/AA0NAQAMJAwNDcni4gwjDQwM/wANIwz/AA0NDCMNAAAAAQFiAI0CngLJABMAACUBNjQnASYiBwYUHwEHBhQXFjI3AZ4BAA0N/wAMJAwNDeLiDQ0MJAyNAQAMIw0BAAwMDSMM4uINIwwNDQAAAAIA4gC3Ax4CngATACcAACUnNzY0JyYiDwEGFB8BFjI3NjQnISc3NjQnJiIPAQYUHwEWMjc2NCcB87e3DQ0MIw3VDQ3VDSMMDQ0BK7e3DQ0MJAzVDQ3VDCQMDQ3zuLcMJAwNDdUNIwzWDAwNIwy4twwkDA0N1Q0jDNYMDA0jDAAAAgDiALcDHgKeABMAJwAAJTc2NC8BJiIHBhQfAQcGFBcWMjchNzY0LwEmIgcGFB8BBwYUFxYyNwJJ1Q0N1Q0jDA0Nt7cNDQwjDf7V1Q0N1QwkDA0Nt7cNDQwkDLfWDCMN1Q0NDCQMt7gMIw0MDNYMIw3VDQ0MJAy3uAwjDQwMAAADAFUAAAOrA1UAMwBoAHcAABMiBgcOAQcOAQcOARURFBYXHgEXHgEXHgEzITI2Nz4BNz4BNz4BNRE0JicuAScuAScuASMFITIWFx4BFx4BFx4BFREUBgcOAQcOAQcOASMhIiYnLgEnLgEnLgE1ETQ2Nz4BNz4BNz4BMxMhMjY1NCYjISIGFRQWM9UNGAwLFQkJDgUFBQUFBQ4JCRULDBgNAlYNGAwLFQkJDgUFBQUFBQ4JCRULDBgN/aoCVgQIBAQHAwMFAQIBAQIBBQMDBwQECAT9qgQIBAQHAwMFAQIBAQIBBQMDBwQECASAAVYRGRkR/qoRGRkRA1UFBAUOCQkVDAsZDf2rDRkLDBUJCA4FBQUFBQUOCQgVDAsZDQJVDRkLDBUJCQ4FBAVVAgECBQMCBwQECAX9qwQJAwQHAwMFAQICAgIBBQMDBwQDCQQCVQUIBAQHAgMFAgEC/oAZEhEZGRESGQAAAAADAFUAAAOrA1UAMwBoAIkAABMiBgcOAQcOAQcOARURFBYXHgEXHgEXHgEzITI2Nz4BNz4BNz4BNRE0JicuAScuAScuASMFITIWFx4BFx4BFx4BFREUBgcOAQcOAQcOASMhIiYnLgEnLgEnLgE1ETQ2Nz4BNz4BNz4BMxMzFRQWMzI2PQEzMjY1NCYrATU0JiMiBh0BIyIGFRQWM9UNGAwLFQkJDgUFBQUFBQ4JCRULDBgNAlYNGAwLFQkJDgUFBQUFBQ4JCRULDBgN/aoCVgQIBAQHAwMFAQIBAQIBBQMDBwQECAT9qgQIBAQHAwMFAQIBAQIBBQMDBwQECASAgBkSEhmAERkZEYAZEhIZgBEZGREDVQUEBQ4JCRUMCxkN/asNGQsMFQkIDgUFBQUFBQ4JCBUMCxkNAlUNGQsMFQkJDgUEBVUCAQIFAwIHBAQIBf2rBAkDBAcDAwUBAgICAgEFAwMHBAMJBAJVBQgEBAcCAwUCAQL+gIASGRkSgBkSERmAEhkZEoAZERIZAAABAOIAjQMeAskAIAAAExcHBhQXFjI/ARcWMjc2NC8BNzY0JyYiDwEnJiIHBhQX4uLiDQ0MJAzi4gwkDA0N4uINDQwkDOLiDCQMDQ0CjeLiDSMMDQ3h4Q0NDCMN4uIMIw0MDOLiDAwNIwwAAAABAAAAAQAAa5n0y18PPPUACwQAAAAAANivOVsAAAAA2K85WwAAAAADqwNVAAAACAACAAAAAAAAAAEAAAPA/8AAAAQAAAAAAAOrAAEAAAAAAAAAAAAAAAAAAAALBAAAAAAAAAAAAAAAAgAAAAQAAWIEAAFiBAAA4gQAAOIEAABVBAAAVQQAAOIAAAAAAAoAFAAeAEQAagCqAOoBngJkApoAAQAAAAsAigADAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAA4ArgABAAAAAAABAAcAAAABAAAAAAACAAcAYAABAAAAAAADAAcANgABAAAAAAAEAAcAdQABAAAAAAAFAAsAFQABAAAAAAAGAAcASwABAAAAAAAKABoAigADAAEECQABAA4ABwADAAEECQACAA4AZwADAAEECQADAA4APQADAAEECQAEAA4AfAADAAEECQAFABYAIAADAAEECQAGAA4AUgADAAEECQAKADQApGZjaWNvbnMAZgBjAGkAYwBvAG4Ac1ZlcnNpb24gMS4wAFYAZQByAHMAaQBvAG4AIAAxAC4AMGZjaWNvbnMAZgBjAGkAYwBvAG4Ac2ZjaWNvbnMAZgBjAGkAYwBvAG4Ac1JlZ3VsYXIAUgBlAGcAdQBsAGEAcmZjaWNvbnMAZgBjAGkAYwBvAG4Ac0ZvbnQgZ2VuZXJhdGVkIGJ5IEljb01vb24uAEYAbwBuAHQAIABnAGUAbgBlAHIAYQB0AGUAZAAgAGIAeQAgAEkAYwBvAE0AbwBvAG4ALgAAAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=") format("truetype")}.fc-icon{speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;display:inline-block;font-family:fcicons!important;font-style:normal;font-variant:normal;font-weight:400;height:1em;line-height:1;text-align:center;text-transform:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;width:1em}.fc-icon-chevron-left:before{content:"\\e900"}.fc-icon-chevron-right:before{content:"\\e901"}.fc-icon-chevrons-left:before{content:"\\e902"}.fc-icon-chevrons-right:before{content:"\\e903"}.fc-icon-minus-square:before{content:"\\e904"}.fc-icon-plus-square:before{content:"\\e905"}.fc-icon-x:before{content:"\\e906"}.fc .fc-button{border-radius:0;font-family:inherit;font-size:inherit;line-height:inherit;margin:0;overflow:visible;text-transform:none}.fc .fc-button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}.fc .fc-button{-webkit-appearance:button}.fc .fc-button:not(:disabled){cursor:pointer}.fc .fc-button{background-color:transparent;border:1px solid transparent;border-radius:.25em;display:inline-block;font-size:1em;font-weight:400;line-height:1.5;padding:.4em .65em;text-align:center;-webkit-user-select:none;-moz-user-select:none;user-select:none;vertical-align:middle}.fc .fc-button:hover{text-decoration:none}.fc .fc-button:focus{box-shadow:0 0 0 .2rem rgba(44,62,80,.25);outline:0}.fc .fc-button:disabled{opacity:.65}.fc .fc-button-primary{background-color:var(--fc-button-bg-color);border-color:var(--fc-button-border-color);color:var(--fc-button-text-color)}.fc .fc-button-primary:hover{background-color:var(--fc-button-hover-bg-color);border-color:var(--fc-button-hover-border-color);color:var(--fc-button-text-color)}.fc .fc-button-primary:disabled{background-color:var(--fc-button-bg-color);border-color:var(--fc-button-border-color);color:var(--fc-button-text-color)}.fc .fc-button-primary:focus{box-shadow:0 0 0 .2rem rgba(76,91,106,.5)}.fc .fc-button-primary:not(:disabled).fc-button-active,.fc .fc-button-primary:not(:disabled):active{background-color:var(--fc-button-active-bg-color);border-color:var(--fc-button-active-border-color);color:var(--fc-button-text-color)}.fc .fc-button-primary:not(:disabled).fc-button-active:focus,.fc .fc-button-primary:not(:disabled):active:focus{box-shadow:0 0 0 .2rem rgba(76,91,106,.5)}.fc .fc-button .fc-icon{font-size:1.5em;vertical-align:middle}.fc .fc-button-group{display:inline-flex;position:relative;vertical-align:middle}.fc .fc-button-group>.fc-button{flex:1 1 auto;position:relative}.fc .fc-button-group>.fc-button.fc-button-active,.fc .fc-button-group>.fc-button:active,.fc .fc-button-group>.fc-button:focus,.fc .fc-button-group>.fc-button:hover{z-index:1}.fc-direction-ltr .fc-button-group>.fc-button:not(:first-child){border-bottom-left-radius:0;border-top-left-radius:0;margin-left:-1px}.fc-direction-ltr .fc-button-group>.fc-button:not(:last-child){border-bottom-right-radius:0;border-top-right-radius:0}.fc-direction-rtl .fc-button-group>.fc-button:not(:first-child){border-bottom-right-radius:0;border-top-right-radius:0;margin-right:-1px}.fc-direction-rtl .fc-button-group>.fc-button:not(:last-child){border-bottom-left-radius:0;border-top-left-radius:0}.fc .fc-toolbar{align-items:center;display:flex;justify-content:space-between}.fc .fc-toolbar.fc-header-toolbar{margin-bottom:1.5em}.fc .fc-toolbar.fc-footer-toolbar{margin-top:1.5em}.fc .fc-toolbar-title{font-size:1.75em;margin:0}.fc-direction-ltr .fc-toolbar>*>:not(:first-child){margin-left:.75em}.fc-direction-rtl .fc-toolbar>*>:not(:first-child){margin-right:.75em}.fc-direction-rtl .fc-toolbar-ltr{flex-direction:row-reverse}.fc .fc-scroller{-webkit-overflow-scrolling:touch;position:relative}.fc .fc-scroller-liquid{height:100%}.fc .fc-scroller-liquid-absolute{bottom:0;left:0;position:absolute;right:0;top:0}.fc .fc-scroller-harness{direction:ltr;overflow:hidden;position:relative}.fc .fc-scroller-harness-liquid{height:100%}.fc-direction-rtl .fc-scroller-harness>.fc-scroller{direction:rtl}.fc-theme-standard .fc-scrollgrid{border:1px solid var(--fc-border-color)}.fc .fc-scrollgrid,.fc .fc-scrollgrid table{table-layout:fixed;width:100%}.fc .fc-scrollgrid table{border-left-style:hidden;border-right-style:hidden;border-top-style:hidden}.fc .fc-scrollgrid{border-bottom-width:0;border-collapse:separate;border-right-width:0}.fc .fc-scrollgrid-liquid{height:100%}.fc .fc-scrollgrid-section,.fc .fc-scrollgrid-section table,.fc .fc-scrollgrid-section>td{height:1px}.fc .fc-scrollgrid-section-liquid>td{height:100%}.fc .fc-scrollgrid-section>*{border-left-width:0;border-top-width:0}.fc .fc-scrollgrid-section-footer>*,.fc .fc-scrollgrid-section-header>*{border-bottom-width:0}.fc .fc-scrollgrid-section-body table,.fc .fc-scrollgrid-section-footer table{border-bottom-style:hidden}.fc .fc-scrollgrid-section-sticky>*{background:var(--fc-page-bg-color);position:sticky;z-index:3}.fc .fc-scrollgrid-section-header.fc-scrollgrid-section-sticky>*{top:0}.fc .fc-scrollgrid-section-footer.fc-scrollgrid-section-sticky>*{bottom:0}.fc .fc-scrollgrid-sticky-shim{height:1px;margin-bottom:-1px}.fc-sticky{position:sticky}.fc .fc-view-harness{flex-grow:1;position:relative}.fc .fc-view-harness-active>.fc-view{bottom:0;left:0;position:absolute;right:0;top:0}.fc .fc-col-header-cell-cushion{display:inline-block;padding:2px 4px}.fc .fc-bg-event,.fc .fc-highlight,.fc .fc-non-business{bottom:0;left:0;position:absolute;right:0;top:0}.fc .fc-non-business{background:var(--fc-non-business-color)}.fc .fc-bg-event{background:var(--fc-bg-event-color);opacity:var(--fc-bg-event-opacity)}.fc .fc-bg-event .fc-event-title{font-size:var(--fc-small-font-size);font-style:italic;margin:.5em}.fc .fc-highlight{background:var(--fc-highlight-color)}.fc .fc-cell-shaded,.fc .fc-day-disabled{background:var(--fc-neutral-bg-color)}a.fc-event,a.fc-event:hover{text-decoration:none}.fc-event.fc-event-draggable,.fc-event[href]{cursor:pointer}.fc-event .fc-event-main{position:relative;z-index:2}.fc-event-dragging:not(.fc-event-selected){opacity:.75}.fc-event-dragging.fc-event-selected{box-shadow:0 2px 7px rgba(0,0,0,.3)}.fc-event .fc-event-resizer{display:none;position:absolute;z-index:4}.fc-event-selected .fc-event-resizer,.fc-event:hover .fc-event-resizer{display:block}.fc-event-selected .fc-event-resizer{background:var(--fc-page-bg-color);border-color:inherit;border-radius:calc(var(--fc-event-resizer-dot-total-width)/2);border-style:solid;border-width:var(--fc-event-resizer-dot-border-width);height:var(--fc-event-resizer-dot-total-width);width:var(--fc-event-resizer-dot-total-width)}.fc-event-selected .fc-event-resizer:before{bottom:-20px;content:"";left:-20px;position:absolute;right:-20px;top:-20px}.fc-event-selected,.fc-event:focus{box-shadow:0 2px 5px rgba(0,0,0,.2)}.fc-event-selected:before,.fc-event:focus:before{bottom:0;content:"";left:0;position:absolute;right:0;top:0;z-index:3}.fc-event-selected:after,.fc-event:focus:after{background:var(--fc-event-selected-overlay-color);bottom:-1px;content:"";left:-1px;position:absolute;right:-1px;top:-1px;z-index:1}.fc-h-event{background-color:var(--fc-event-bg-color);border:1px solid var(--fc-event-border-color);display:block}.fc-h-event .fc-event-main{color:var(--fc-event-text-color)}.fc-h-event .fc-event-main-frame{display:flex}.fc-h-event .fc-event-time{max-width:100%;overflow:hidden}.fc-h-event .fc-event-title-container{flex-grow:1;flex-shrink:1;min-width:0}.fc-h-event .fc-event-title{display:inline-block;left:0;max-width:100%;overflow:hidden;right:0;vertical-align:top}.fc-h-event.fc-event-selected:before{bottom:-10px;top:-10px}.fc-direction-ltr .fc-daygrid-block-event:not(.fc-event-start),.fc-direction-rtl .fc-daygrid-block-event:not(.fc-event-end){border-bottom-left-radius:0;border-left-width:0;border-top-left-radius:0}.fc-direction-ltr .fc-daygrid-block-event:not(.fc-event-end),.fc-direction-rtl .fc-daygrid-block-event:not(.fc-event-start){border-bottom-right-radius:0;border-right-width:0;border-top-right-radius:0}.fc-h-event:not(.fc-event-selected) .fc-event-resizer{bottom:0;top:0;width:var(--fc-event-resizer-thickness)}.fc-direction-ltr .fc-h-event:not(.fc-event-selected) .fc-event-resizer-start,.fc-direction-rtl .fc-h-event:not(.fc-event-selected) .fc-event-resizer-end{cursor:w-resize;left:calc(var(--fc-event-resizer-thickness)*-.5)}.fc-direction-ltr .fc-h-event:not(.fc-event-selected) .fc-event-resizer-end,.fc-direction-rtl .fc-h-event:not(.fc-event-selected) .fc-event-resizer-start{cursor:e-resize;right:calc(var(--fc-event-resizer-thickness)*-.5)}.fc-h-event.fc-event-selected .fc-event-resizer{margin-top:calc(var(--fc-event-resizer-dot-total-width)*-.5);top:50%}.fc-direction-ltr .fc-h-event.fc-event-selected .fc-event-resizer-start,.fc-direction-rtl .fc-h-event.fc-event-selected .fc-event-resizer-end{left:calc(var(--fc-event-resizer-dot-total-width)*-.5)}.fc-direction-ltr .fc-h-event.fc-event-selected .fc-event-resizer-end,.fc-direction-rtl .fc-h-event.fc-event-selected .fc-event-resizer-start{right:calc(var(--fc-event-resizer-dot-total-width)*-.5)}.fc .fc-popover{box-shadow:0 2px 6px rgba(0,0,0,.15);position:absolute;z-index:9999}.fc .fc-popover-header{align-items:center;display:flex;flex-direction:row;justify-content:space-between;padding:3px 4px}.fc .fc-popover-title{margin:0 2px}.fc .fc-popover-close{cursor:pointer;font-size:1.1em;opacity:.65}.fc-theme-standard .fc-popover{background:var(--fc-page-bg-color);border:1px solid var(--fc-border-color)}.fc-theme-standard .fc-popover-header{background:var(--fc-neutral-bg-color)}`);var Q_=class{constructor(e){this.drainedOption=e,this.isRunning=!1,this.isDirty=!1,this.pauseDepths={},this.timeoutId=0}request(e){this.isDirty=!0,this.isPaused()||(this.clearTimeout(),e==null?this.tryDrain():this.timeoutId=setTimeout(this.tryDrain.bind(this),e))}pause(e=``){let{pauseDepths:t}=this;t[e]=(t[e]||0)+1,this.clearTimeout()}resume(e=``,t){let{pauseDepths:n}=this;e in n&&(t?delete n[e]:(--n[e],n[e]<=0&&delete n[e]),this.tryDrain())}isPaused(){return Object.keys(this.pauseDepths).length}tryDrain(){if(!this.isRunning&&!this.isPaused()){for(this.isRunning=!0;this.isDirty;)this.isDirty=!1,this.drained();this.isRunning=!1}}clear(){this.clearTimeout(),this.isDirty=!1,this.pauseDepths={}}clearTimeout(){this.timeoutId&&=(clearTimeout(this.timeoutId),0)}drained(){this.drainedOption&&this.drainedOption()}};function $_(e){e.parentNode&&e.parentNode.removeChild(e)}function ev(e,t){if(e.closest)return e.closest(t);if(!document.documentElement.contains(e))return null;do{if(tv(e,t))return e;e=e.parentElement||e.parentNode}while(e!==null&&e.nodeType===1);return null}function tv(e,t){return(e.matches||e.matchesSelector||e.msMatchesSelector).call(e,t)}function nv(e,t){let n=e instanceof HTMLElement?[e]:e,r=[];for(let e=0;e<n.length;e+=1){let i=n[e].querySelectorAll(t);for(let e=0;e<i.length;e+=1)r.push(i[e])}return r}var rv=/(top|left|right|bottom|width|height)$/i;function iv(e,t){for(let n in t)av(e,n,t[n])}function av(e,t,n){n==null?e.style[t]=``:typeof n==`number`&&rv.test(t)?e.style[t]=`${n}px`:e.style[t]=n}function ov(e){return e.composedPath?.call(e)[0]??e.target}var sv=0;function cv(){return sv+=1,`fc-dom-`+sv}function lv(e,t){return n=>{let r=ev(n.target,e);r&&t.call(r,n,r)}}function uv(e,t,n,r){let i=lv(n,r);return e.addEventListener(t,i),()=>{e.removeEventListener(t,i)}}function dv(e,t,n,r){let i;return uv(e,`mouseover`,t,(e,t)=>{if(t!==i){i=t,n(e,t);let a=e=>{i=null,r(e,t),t.removeEventListener(`mouseleave`,a)};t.addEventListener(`mouseleave`,a)}})}function fv(e){return Object.assign({onClick:e},pv(e))}function pv(e){return{tabIndex:0,onKeyDown(t){(t.key===`Enter`||t.key===` `)&&(e(t),t.preventDefault())}}}var mv=0;function hv(){return mv+=1,String(mv)}function gv(e){let t=[],n=[],r,i;for(typeof e==`string`?n=e.split(/\s*,\s*/):typeof e==`function`?n=[e]:Array.isArray(e)&&(n=e),r=0;r<n.length;r+=1)i=n[r],typeof i==`string`?t.push(i.charAt(0)===`-`?{field:i.substring(1),order:-1}:{field:i,order:1}):typeof i==`function`&&t.push({func:i});return t}function _v(e,t,n){let r,i;for(r=0;r<n.length;r+=1)if(i=vv(e,t,n[r]),i)return i;return 0}function vv(e,t,n){return n.func?n.func(e,t):yv(e[n.field],t[n.field])*(n.order||1)}function yv(e,t){return!e&&!t?0:t==null?-1:e==null?1:typeof e==`string`||typeof t==`string`?String(e).localeCompare(String(t)):e-t}function bv(e,t){let n=String(e);return`000`.substr(0,t-n.length)+n}function xv(e,t,n){return typeof e==`function`?e(...t):typeof e==`string`?t.reduce((e,t,n)=>e.replace(`$`+n,t||``),e):n}function Sv(e){return e%1==0}function Cv(e){let t=e.querySelector(`.fc-scrollgrid-shrink-frame`),n=e.querySelector(`.fc-scrollgrid-shrink-cushion`);if(!t)throw Error(`needs fc-scrollgrid-shrink-frame className`);if(!n)throw Error(`needs fc-scrollgrid-shrink-cushion className`);return e.getBoundingClientRect().width-t.getBoundingClientRect().width+n.getBoundingClientRect().width}var wv=/^(-?)(?:(\d+)\.)?(\d+):(\d\d)(?::(\d\d)(?:\.(\d\d\d))?)?/;function Tv(e,t){return typeof e==`string`?Ev(e):typeof e==`object`&&e?Dv(e):typeof e==`number`?Dv({[t||`milliseconds`]:e}):null}function Ev(e){let t=wv.exec(e);if(t){let e=t[1]?-1:1;return{years:0,months:0,days:e*(t[2]?parseInt(t[2],10):0),milliseconds:e*((t[3]?parseInt(t[3],10):0)*60*60*1e3+(t[4]?parseInt(t[4],10):0)*60*1e3+(t[5]?parseInt(t[5],10):0)*1e3+(t[6]?parseInt(t[6],10):0))}}return null}function Dv(e){let t={years:e.years||e.year||0,months:e.months||e.month||0,days:e.days||e.day||0,milliseconds:(e.hours||e.hour||0)*60*60*1e3+(e.minutes||e.minute||0)*60*1e3+(e.seconds||e.second||0)*1e3+(e.milliseconds||e.millisecond||e.ms||0)},n=e.weeks||e.week;return n&&(t.days+=n*7,t.specifiedWeeks=!0),t}function Ov(e,t){return e.years===t.years&&e.months===t.months&&e.days===t.days&&e.milliseconds===t.milliseconds}function kv(e,t){return{years:e.years-t.years,months:e.months-t.months,days:e.days-t.days,milliseconds:e.milliseconds-t.milliseconds}}function Av(e){return Mv(e)/365}function jv(e){return Mv(e)/30}function Mv(e){return Nv(e)/864e5}function Nv(e){return e.years*31536e6+e.months*2592e6+e.days*864e5+e.milliseconds}function Pv(e){let t=e.milliseconds;if(t){if(t%1e3!=0)return{unit:`millisecond`,value:t};if(t%6e4!=0)return{unit:`second`,value:t/1e3};if(t%36e5!=0)return{unit:`minute`,value:t/6e4};if(t)return{unit:`hour`,value:t/36e5}}return e.days?e.specifiedWeeks&&e.days%7==0?{unit:`week`,value:e.days/7}:{unit:`day`,value:e.days}:e.months?{unit:`month`,value:e.months}:e.years?{unit:`year`,value:e.years}:{unit:`millisecond`,value:0}}function Fv(e,t,n){if(e===t)return!0;let r=e.length,i;if(r!==t.length)return!1;for(i=0;i<r;i+=1)if(!(n?n(e[i],t[i]):e[i]===t[i]))return!1;return!0}var Iv=[`sun`,`mon`,`tue`,`wed`,`thu`,`fri`,`sat`];function Lv(e,t){let n=ry(e);return n[2]+=t*7,iy(n)}function Rv(e,t){let n=ry(e);return n[2]+=t,iy(n)}function zv(e,t){let n=ry(e);return n[6]+=t,iy(n)}function Bv(e,t){return Vv(e,t)/7}function Vv(e,t){return(t.valueOf()-e.valueOf())/864e5}function Hv(e,t){return(t.valueOf()-e.valueOf())/36e5}function Uv(e,t){return(t.valueOf()-e.valueOf())/6e4}function Wv(e,t){return(t.valueOf()-e.valueOf())/1e3}function Gv(e,t){let n=Jv(e),r=Jv(t);return{years:0,months:0,days:Math.round(Vv(n,r)),milliseconds:t.valueOf()-r.valueOf()-(e.valueOf()-n.valueOf())}}function Kv(e,t){let n=qv(e,t);return n!==null&&n%7==0?n/7:null}function qv(e,t){return oy(e)===oy(t)?Math.round(Vv(e,t)):null}function Jv(e){return iy([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()])}function Yv(e){return iy([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours()])}function Xv(e){return iy([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes()])}function Zv(e){return iy([e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds()])}function Qv(e,t,n){let r=e.getUTCFullYear(),i=$v(e,r,t,n);if(i<1)return $v(e,r-1,t,n);let a=$v(e,r+1,t,n);return a>=1?Math.min(i,a):i}function $v(e,t,n,r){let i=iy([t,0,1+ey(t,n,r)]),a=Jv(e),o=Math.round(Vv(i,a));return Math.floor(o/7)+1}function ey(e,t,n){let r=7+t-n;return-((7+iy([e,0,r]).getUTCDay()-t)%7)+r-1}function ty(e){return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()]}function ny(e){return new Date(e[0],e[1]||0,e[2]==null?1:e[2],e[3]||0,e[4]||0,e[5]||0)}function ry(e){return[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()]}function iy(e){return e.length===1&&(e=e.concat([0])),new Date(Date.UTC(...e))}function ay(e){return!isNaN(e.valueOf())}function oy(e){return e.getUTCHours()*1e3*60*60+e.getUTCMinutes()*1e3*60+e.getUTCSeconds()*1e3+e.getUTCMilliseconds()}function sy(e,t,n=!1){let r=e.toISOString();return r=r.replace(`.000`,``),n&&(r=r.replace(`T00:00:00Z`,``)),r.length>10&&(t==null?r=r.replace(`Z`,``):t!==0&&(r=r.replace(`Z`,uy(t,!0)))),r}function cy(e){return e.toISOString().replace(/T.*$/,``)}function ly(e){return e.toISOString().match(/^\d{4}-\d{2}/)[0]}function uy(e,t=!1){let n=e<0?`-`:`+`,r=Math.abs(e),i=Math.floor(r/60),a=Math.round(r%60);return t?`${n+bv(i,2)}:${bv(a,2)}`:`GMT${n}${i}${a?`:${bv(a,2)}`:``}`}function dy(e,t,n){let r,i;return function(...a){if(!r)i=e.apply(this,a);else if(!Fv(r,a)){n&&n(i);let r=e.apply(this,a);(!t||!t(r,i))&&(i=r)}return r=a,i}}function fy(e,t,n){let r,i;return a=>{if(!r)i=e.call(this,a);else if(!Zy(r,a)){n&&n(i);let r=e.call(this,a);(!t||!t(r,i))&&(i=r)}return r=a,i}}var py={week:3,separator:9,omitZeroMinute:9,meridiem:9,omitCommas:9},my={timeZoneName:7,era:6,year:5,month:4,day:2,weekday:2,hour:1,minute:1,second:1},hy=/\s*([ap])\.?m\.?/i,gy=/,/g,_y=/\s+/g,vy=/\u200e/g,yy=/UTC|GMT/,by=class{constructor(e){let t={},n={},r=9;for(let i in e)i in py?(n[i]=e[i],py[i]<9&&(r=Math.min(py[i],r))):(t[i]=e[i],i in my&&(r=Math.min(my[i],r)));this.standardDateProps=t,this.extendedSettings=n,this.smallestUnitNum=r,this.buildFormattingFunc=dy(xy)}format(e,t){return this.buildFormattingFunc(this.standardDateProps,this.extendedSettings,t)(e)}formatRange(e,t,n,r){let{standardDateProps:i,extendedSettings:a}=this,o=Dy(e.marker,t.marker,n.calendarSystem);if(!o)return this.format(e,n);let s=o;s>1&&(i.year===`numeric`||i.year===`2-digit`)&&(i.month===`numeric`||i.month===`2-digit`)&&(i.day===`numeric`||i.day===`2-digit`)&&(s=1);let c=this.format(e,n),l=this.format(t,n);if(c===l)return c;let u=xy(Oy(i,s),a,n),d=u(e),f=u(t),p=ky(c,d,l,f),m=a.separator||r||n.defaultSeparator||``;return p?p.before+d+m+f+p.after:c+m+l}getSmallestUnit(){switch(this.smallestUnitNum){case 7:case 6:case 5:return`year`;case 4:return`month`;case 3:return`week`;case 2:return`day`;default:return`time`}}};function xy(e,t,n){let r=Object.keys(e).length;return r===1&&e.timeZoneName===`short`?e=>uy(e.timeZoneOffset):r===0&&t.week?e=>Ey(n.computeWeekNumber(e.marker),n.weekText,n.weekTextLong,n.locale,t.week):Sy(e,t,n)}function Sy(e,t,n){e=Object.assign({},e),t=Object.assign({},t),Cy(e,t),e.timeZone=`UTC`;let r=new Intl.DateTimeFormat(n.locale.codes,e),i;if(t.omitZeroMinute){let t=Object.assign({},e);delete t.minute,i=new Intl.DateTimeFormat(n.locale.codes,t)}return a=>{let{marker:o}=a,s;return s=i&&!o.getUTCMinutes()?i:r,wy(s.format(o),a,e,t,n)}}function Cy(e,t){e.timeZoneName&&(e.hour||=`2-digit`,e.minute||=`2-digit`),e.timeZoneName===`long`&&(e.timeZoneName=`short`),t.omitZeroMinute&&(e.second||e.millisecond)&&delete t.omitZeroMinute}function wy(e,t,n,r,i){return e=e.replace(vy,``),n.timeZoneName===`short`&&(e=Ty(e,i.timeZone===`UTC`||t.timeZoneOffset==null?`UTC`:uy(t.timeZoneOffset))),r.omitCommas&&(e=e.replace(gy,``).trim()),r.omitZeroMinute&&(e=e.replace(`:00`,``)),r.meridiem===!1?e=e.replace(hy,``).trim():r.meridiem===`narrow`?e=e.replace(hy,(e,t)=>t.toLocaleLowerCase()):r.meridiem===`short`?e=e.replace(hy,(e,t)=>`${t.toLocaleLowerCase()}m`):r.meridiem===`lowercase`&&(e=e.replace(hy,e=>e.toLocaleLowerCase())),e=e.replace(_y,` `),e=e.trim(),e}function Ty(e,t){let n=!1;return e=e.replace(yy,()=>(n=!0,t)),n||(e+=` ${t}`),e}function Ey(e,t,n,r,i){let a=[];return i===`long`?a.push(n):(i===`short`||i===`narrow`)&&a.push(t),(i===`long`||i===`short`)&&a.push(` `),a.push(r.simpleNumberFormat.format(e)),r.options.direction===`rtl`&&a.reverse(),a.join(``)}function Dy(e,t,n){return n.getMarkerYear(e)===n.getMarkerYear(t)?n.getMarkerMonth(e)===n.getMarkerMonth(t)?n.getMarkerDay(e)===n.getMarkerDay(t)?oy(e)===oy(t)?0:1:2:4:5}function Oy(e,t){let n={};for(let r in e)(!(r in my)||my[r]<=t)&&(n[r]=e[r]);return n}function ky(e,t,n,r){let i=0;for(;i<e.length;){let a=e.indexOf(t,i);if(a===-1)break;let o=e.substr(0,a);i=a+t.length;let s=e.substr(i),c=0;for(;c<n.length;){let e=n.indexOf(r,c);if(e===-1)break;let t=n.substr(0,e);c=e+r.length;let i=n.substr(c);if(o===t&&s===i)return{before:o,after:s}}}return null}function Ay(e,t){let n=t.markerToArray(e.marker);return{marker:e.marker,timeZoneOffset:e.timeZoneOffset,array:n,year:n[0],month:n[1],day:n[2],hour:n[3],minute:n[4],second:n[5],millisecond:n[6]}}function jy(e,t,n,r){let i=Ay(e,n.calendarSystem);return{date:i,start:i,end:t?Ay(t,n.calendarSystem):null,timeZone:n.timeZone,localeCodes:n.locale.codes,defaultSeparator:r||n.defaultSeparator}}var My=class{constructor(e){this.cmdStr=e}format(e,t,n){return t.cmdFormatter(this.cmdStr,jy(e,null,t,n))}formatRange(e,t,n,r){return n.cmdFormatter(this.cmdStr,jy(e,t,n,r))}},Ny=class{constructor(e){this.func=e}format(e,t,n){return this.func(jy(e,null,t,n))}formatRange(e,t,n,r){return this.func(jy(e,t,n,r))}};function Py(e){return typeof e==`object`&&e?new by(e):typeof e==`string`?new My(e):typeof e==`function`?new Ny(e):null}var Fy={navLinkDayClick:$,navLinkWeekClick:$,duration:Tv,bootstrapFontAwesome:$,buttonIcons:$,customButtons:$,defaultAllDayEventDuration:Tv,defaultTimedEventDuration:Tv,nextDayThreshold:Tv,scrollTime:Tv,scrollTimeReset:Boolean,slotMinTime:Tv,slotMaxTime:Tv,dayPopoverFormat:Py,slotDuration:Tv,snapDuration:Tv,headerToolbar:$,footerToolbar:$,defaultRangeSeparator:String,titleRangeSeparator:String,forceEventDuration:Boolean,dayHeaders:Boolean,dayHeaderFormat:Py,dayHeaderClassNames:$,dayHeaderContent:$,dayHeaderDidMount:$,dayHeaderWillUnmount:$,dayCellClassNames:$,dayCellContent:$,dayCellDidMount:$,dayCellWillUnmount:$,initialView:String,aspectRatio:Number,weekends:Boolean,weekNumberCalculation:$,weekNumbers:Boolean,weekNumberClassNames:$,weekNumberContent:$,weekNumberDidMount:$,weekNumberWillUnmount:$,editable:Boolean,viewClassNames:$,viewDidMount:$,viewWillUnmount:$,nowIndicator:Boolean,nowIndicatorSnap:$,nowIndicatorClassNames:$,nowIndicatorContent:$,nowIndicatorDidMount:$,nowIndicatorWillUnmount:$,showNonCurrentDates:Boolean,lazyFetching:Boolean,startParam:String,endParam:String,timeZoneParam:String,timeZone:String,locales:$,locale:$,themeSystem:String,dragRevertDuration:Number,dragScroll:Boolean,allDayMaintainDuration:Boolean,unselectAuto:Boolean,dropAccept:$,eventOrder:gv,eventOrderStrict:Boolean,handleWindowResize:Boolean,windowResizeDelay:Number,longPressDelay:Number,eventDragMinDistance:Number,expandRows:Boolean,height:$,contentHeight:$,direction:String,weekNumberFormat:Py,eventResizableFromStart:Boolean,displayEventTime:Boolean,displayEventEnd:Boolean,weekText:String,weekTextLong:String,progressiveEventRendering:Boolean,businessHours:$,initialDate:$,now:$,eventDataTransform:$,stickyHeaderDates:$,stickyFooterScrollbar:$,viewHeight:$,defaultAllDay:Boolean,eventSourceFailure:$,eventSourceSuccess:$,eventDisplay:String,eventStartEditable:Boolean,eventDurationEditable:Boolean,eventOverlap:$,eventConstraint:$,eventAllow:$,eventBackgroundColor:String,eventBorderColor:String,eventTextColor:String,eventColor:String,eventClassNames:$,eventContent:$,eventDidMount:$,eventWillUnmount:$,selectConstraint:$,selectOverlap:$,selectAllow:$,droppable:Boolean,unselectCancel:String,slotLabelFormat:$,slotLaneClassNames:$,slotLaneContent:$,slotLaneDidMount:$,slotLaneWillUnmount:$,slotLabelClassNames:$,slotLabelContent:$,slotLabelDidMount:$,slotLabelWillUnmount:$,dayMaxEvents:$,dayMaxEventRows:$,dayMinWidth:Number,slotLabelInterval:Tv,allDayText:String,allDayClassNames:$,allDayContent:$,allDayDidMount:$,allDayWillUnmount:$,slotMinWidth:Number,navLinks:Boolean,eventTimeFormat:Py,rerenderDelay:Number,moreLinkText:$,moreLinkHint:$,selectMinDistance:Number,selectable:Boolean,selectLongPressDelay:Number,eventLongPressDelay:Number,selectMirror:Boolean,eventMaxStack:Number,eventMinHeight:Number,eventMinWidth:Number,eventShortHeight:Number,slotEventOverlap:Boolean,plugins:$,firstDay:Number,dayCount:Number,dateAlignment:String,dateIncrement:Tv,hiddenDays:$,fixedWeekCount:Boolean,validRange:$,visibleRange:$,titleFormat:$,eventInteractive:Boolean,noEventsText:String,viewHint:$,navLinkHint:$,closeHint:String,timeHint:String,eventHint:String,moreLinkClick:$,moreLinkClassNames:$,moreLinkContent:$,moreLinkDidMount:$,moreLinkWillUnmount:$,monthStartFormat:Py,handleCustomRendering:$,customRenderingMetaMap:$,customRenderingReplaces:Boolean},Iy={eventDisplay:`auto`,defaultRangeSeparator:` - `,titleRangeSeparator:` – `,defaultTimedEventDuration:`01:00:00`,defaultAllDayEventDuration:{day:1},forceEventDuration:!1,nextDayThreshold:`00:00:00`,dayHeaders:!0,initialView:``,aspectRatio:1.35,headerToolbar:{start:`title`,center:``,end:`today prev,next`},weekends:!0,weekNumbers:!1,weekNumberCalculation:`local`,editable:!1,nowIndicator:!1,scrollTime:`06:00:00`,scrollTimeReset:!0,slotMinTime:`00:00:00`,slotMaxTime:`24:00:00`,showNonCurrentDates:!0,lazyFetching:!0,startParam:`start`,endParam:`end`,timeZoneParam:`timeZone`,timeZone:`local`,locales:[],locale:``,themeSystem:`standard`,dragRevertDuration:500,dragScroll:!0,allDayMaintainDuration:!1,unselectAuto:!0,dropAccept:`*`,eventOrder:`start,-duration,allDay,title`,dayPopoverFormat:{month:`long`,day:`numeric`,year:`numeric`},handleWindowResize:!0,windowResizeDelay:100,longPressDelay:1e3,eventDragMinDistance:5,expandRows:!1,navLinks:!1,selectable:!1,eventMinHeight:15,eventMinWidth:30,eventShortHeight:30,monthStartFormat:{month:`long`,day:`numeric`},nowIndicatorSnap:`auto`},Ly={datesSet:$,eventsSet:$,eventAdd:$,eventChange:$,eventRemove:$,windowResize:$,eventClick:$,eventMouseEnter:$,eventMouseLeave:$,select:$,unselect:$,loading:$,_unmount:$,_beforeprint:$,_afterprint:$,_noEventDrop:$,_noEventResize:$,_resize:$,_scrollRequest:$},Ry={buttonText:$,buttonHints:$,views:$,plugins:$,initialEvents:$,events:$,eventSources:$},zy={headerToolbar:By,footerToolbar:By,buttonText:By,buttonHints:By,buttonIcons:By,dateIncrement:By,plugins:Vy,events:Vy,eventSources:Vy,resources:Vy};function By(e,t){return typeof e==`object`&&typeof t==`object`&&e&&t?Zy(e,t):e===t}function Vy(e,t){return Array.isArray(e)&&Array.isArray(t)?Fv(e,t):e===t}var Hy={type:String,component:$,buttonText:String,buttonTextKey:String,dateProfileGeneratorClass:$,usesMinMaxTime:Boolean,classNames:$,content:$,didMount:$,willUnmount:$};function Uy(e){return Ky(e,zy)}function Wy(e,t){let n={},r={};for(let r in t)r in e&&(n[r]=t[r](e[r]));for(let n in e)n in t||(r[n]=e[n]);return{refined:n,extra:r}}function $(e){return e}var{hasOwnProperty:Gy}=Object.prototype;function Ky(e,t){let n={};if(t){for(let r in t)if(t[r]===By){let t=[];for(let i=e.length-1;i>=0;--i){let a=e[i][r];if(typeof a==`object`&&a)t.unshift(a);else if(a!==void 0){n[r]=a;break}}t.length&&(n[r]=Ky(t))}}for(let t=e.length-1;t>=0;--t){let r=e[t];for(let e in r)e in n||(n[e]=r[e])}return n}function qy(e,t){let n={};for(let r in e)t(e[r],r)&&(n[r]=e[r]);return n}function Jy(e,t){let n={};for(let r in e)n[r]=t(e[r],r);return n}function Yy(e){let t={};for(let n of e)t[n]=!0;return t}function Xy(e){let t=[];for(let n in e)t.push(e[n]);return t}function Zy(e,t){if(e===t)return!0;for(let n in e)if(Gy.call(e,n)&&!(n in t))return!1;for(let n in t)if(Gy.call(t,n)&&e[n]!==t[n])return!1;return!0}var Qy=/^on[A-Z]/;function $y(e,t){let n=eb(e,t);for(let e of n)if(!Qy.test(e))return!1;return!0}function eb(e,t){let n=[];for(let r in e)Gy.call(e,r)&&(r in t||n.push(r));for(let r in t)Gy.call(t,r)&&e[r]!==t[r]&&n.push(r);return n}function tb(e,t,n={}){if(e===t)return!0;for(let r in t)if(!(r in e&&nb(e[r],t[r],n[r])))return!1;for(let n in e)if(!(n in t))return!1;return!0}function nb(e,t,n){return e===t||n===!0?!0:n?n(e,t):!1}function rb(e,t=0,n,r=1){let i=[];n??=Object.keys(e).length;for(let a=t;a<n;a+=r){let t=e[a];t!==void 0&&i.push(t)}return i}var ib={};function ab(e,t){ib[e]=t}function ob(e){return new ib[e]}ab(`gregory`,class{getMarkerYear(e){return e.getUTCFullYear()}getMarkerMonth(e){return e.getUTCMonth()}getMarkerDay(e){return e.getUTCDate()}arrayToMarker(e){return iy(e)}markerToArray(e){return ry(e)}});var sb=/^\s*(\d{4})(-?(\d{2})(-?(\d{2})([T ](\d{2}):?(\d{2})(:?(\d{2})(\.(\d+))?)?(Z|(([-+])(\d{2})(:?(\d{2}))?))?)?)?)?$/;function cb(e){let t=sb.exec(e);if(t){let e=new Date(Date.UTC(Number(t[1]),t[3]?Number(t[3])-1:0,Number(t[5]||1),Number(t[7]||0),Number(t[8]||0),Number(t[10]||0),t[12]?Number(`0.${t[12]}`)*1e3:0));if(ay(e)){let n=null;return t[13]&&(n=(t[15]===`-`?-1:1)*(Number(t[16]||0)*60+Number(t[18]||0))),{marker:e,isTimeUnspecified:!t[6],timeZoneOffset:n}}}return null}var lb=class{constructor(e){let t=this.timeZone=e.timeZone,n=t!==`local`&&t!==`UTC`;e.namedTimeZoneImpl&&n&&(this.namedTimeZoneImpl=new e.namedTimeZoneImpl(t)),this.canComputeOffset=!(n&&!this.namedTimeZoneImpl),this.calendarSystem=ob(e.calendarSystem),this.locale=e.locale,this.weekDow=e.locale.week.dow,this.weekDoy=e.locale.week.doy,e.weekNumberCalculation===`ISO`&&(this.weekDow=1,this.weekDoy=4),typeof e.firstDay==`number`&&(this.weekDow=e.firstDay),typeof e.weekNumberCalculation==`function`&&(this.weekNumberFunc=e.weekNumberCalculation),this.weekText=e.weekText==null?e.locale.options.weekText:e.weekText,this.weekTextLong=(e.weekTextLong==null?e.locale.options.weekTextLong:e.weekTextLong)||this.weekText,this.cmdFormatter=e.cmdFormatter,this.defaultSeparator=e.defaultSeparator}createMarker(e){let t=this.createMarkerMeta(e);return t===null?null:t.marker}createNowMarker(){return this.canComputeOffset?this.timestampToMarker(new Date().valueOf()):iy(ty(new Date))}createMarkerMeta(e){if(typeof e==`string`)return this.parse(e);let t=null;return typeof e==`number`?t=this.timestampToMarker(e):e instanceof Date?(e=e.valueOf(),isNaN(e)||(t=this.timestampToMarker(e))):Array.isArray(e)&&(t=iy(e)),t===null||!ay(t)?null:{marker:t,isTimeUnspecified:!1,forcedTzo:null}}parse(e){let t=cb(e);if(t===null)return null;let{marker:n}=t,r=null;return t.timeZoneOffset!==null&&(this.canComputeOffset?n=this.timestampToMarker(n.valueOf()-t.timeZoneOffset*60*1e3):r=t.timeZoneOffset),{marker:n,isTimeUnspecified:t.isTimeUnspecified,forcedTzo:r}}getYear(e){return this.calendarSystem.getMarkerYear(e)}getMonth(e){return this.calendarSystem.getMarkerMonth(e)}getDay(e){return this.calendarSystem.getMarkerDay(e)}add(e,t){let n=this.calendarSystem.markerToArray(e);return n[0]+=t.years,n[1]+=t.months,n[2]+=t.days,n[6]+=t.milliseconds,this.calendarSystem.arrayToMarker(n)}subtract(e,t){let n=this.calendarSystem.markerToArray(e);return n[0]-=t.years,n[1]-=t.months,n[2]-=t.days,n[6]-=t.milliseconds,this.calendarSystem.arrayToMarker(n)}addYears(e,t){let n=this.calendarSystem.markerToArray(e);return n[0]+=t,this.calendarSystem.arrayToMarker(n)}addMonths(e,t){let n=this.calendarSystem.markerToArray(e);return n[1]+=t,this.calendarSystem.arrayToMarker(n)}diffWholeYears(e,t){let{calendarSystem:n}=this;return oy(e)===oy(t)&&n.getMarkerDay(e)===n.getMarkerDay(t)&&n.getMarkerMonth(e)===n.getMarkerMonth(t)?n.getMarkerYear(t)-n.getMarkerYear(e):null}diffWholeMonths(e,t){let{calendarSystem:n}=this;return oy(e)===oy(t)&&n.getMarkerDay(e)===n.getMarkerDay(t)?n.getMarkerMonth(t)-n.getMarkerMonth(e)+(n.getMarkerYear(t)-n.getMarkerYear(e))*12:null}greatestWholeUnit(e,t){let n=this.diffWholeYears(e,t);return n===null?(n=this.diffWholeMonths(e,t),n===null?(n=Kv(e,t),n===null?(n=qv(e,t),n===null?(n=Hv(e,t),Sv(n)?{unit:`hour`,value:n}:(n=Uv(e,t),Sv(n)?{unit:`minute`,value:n}:(n=Wv(e,t),Sv(n)?{unit:`second`,value:n}:{unit:`millisecond`,value:t.valueOf()-e.valueOf()}))):{unit:`day`,value:n}):{unit:`week`,value:n}):{unit:`month`,value:n}):{unit:`year`,value:n}}countDurationsBetween(e,t,n){let r;return n.years&&(r=this.diffWholeYears(e,t),r!==null)?r/Av(n):n.months&&(r=this.diffWholeMonths(e,t),r!==null)?r/jv(n):n.days&&(r=qv(e,t),r!==null)?r/Mv(n):(t.valueOf()-e.valueOf())/Nv(n)}startOf(e,t){return t===`year`?this.startOfYear(e):t===`month`?this.startOfMonth(e):t===`week`?this.startOfWeek(e):t===`day`?Jv(e):t===`hour`?Yv(e):t===`minute`?Xv(e):t===`second`?Zv(e):null}startOfYear(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e)])}startOfMonth(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e),this.calendarSystem.getMarkerMonth(e)])}startOfWeek(e){return this.calendarSystem.arrayToMarker([this.calendarSystem.getMarkerYear(e),this.calendarSystem.getMarkerMonth(e),e.getUTCDate()-(e.getUTCDay()-this.weekDow+7)%7])}computeWeekNumber(e){return this.weekNumberFunc?this.weekNumberFunc(this.toDate(e)):Qv(e,this.weekDow,this.weekDoy)}format(e,t,n={}){return t.format({marker:e,timeZoneOffset:n.forcedTzo==null?this.offsetForMarker(e):n.forcedTzo},this)}formatRange(e,t,n,r={}){return r.isEndExclusive&&(t=zv(t,-1)),n.formatRange({marker:e,timeZoneOffset:r.forcedStartTzo==null?this.offsetForMarker(e):r.forcedStartTzo},{marker:t,timeZoneOffset:r.forcedEndTzo==null?this.offsetForMarker(t):r.forcedEndTzo},this,r.defaultSeparator)}formatIso(e,t={}){let n=null;return t.omitTimeZoneOffset||(n=t.forcedTzo==null?this.offsetForMarker(e):t.forcedTzo),sy(e,n,t.omitTime)}timestampToMarker(e){return this.timeZone===`local`?iy(ty(new Date(e))):this.timeZone===`UTC`||!this.namedTimeZoneImpl?new Date(e):iy(this.namedTimeZoneImpl.timestampToArray(e))}offsetForMarker(e){return this.timeZone===`local`?-ny(ry(e)).getTimezoneOffset():this.timeZone===`UTC`?0:this.namedTimeZoneImpl?this.namedTimeZoneImpl.offsetForArray(ry(e)):null}toDate(e,t){return this.timeZone===`local`?ny(ry(e)):this.timeZone===`UTC`?new Date(e.valueOf()):this.namedTimeZoneImpl?new Date(e.valueOf()-this.namedTimeZoneImpl.offsetForArray(ry(e))*1e3*60):new Date(e.valueOf()-(t||0))}},ub=class{constructor(e){this.iconOverrideOption&&this.setIconOverride(e[this.iconOverrideOption])}setIconOverride(e){let t,n;if(typeof e==`object`&&e){for(n in t=Object.assign({},this.iconClasses),e)t[n]=this.applyIconOverridePrefix(e[n]);this.iconClasses=t}else e===!1&&(this.iconClasses={})}applyIconOverridePrefix(e){let t=this.iconOverridePrefix;return t&&e.indexOf(t)!==0&&(e=t+e),e}getClass(e){return this.classes[e]||``}getIconClass(e,t){let n;return n=t&&this.rtlIconClasses&&this.rtlIconClasses[e]||this.iconClasses[e],n?`${this.baseIconClass} ${n}`:``}getCustomButtonIconClass(e){let t;return this.iconOverrideCustomButtonOption&&(t=e[this.iconOverrideCustomButtonOption],t)?`${this.baseIconClass} ${this.applyIconOverridePrefix(t)}`:``}};ub.prototype.classes={},ub.prototype.iconClasses={},ub.prototype.baseIconClass=``,ub.prototype.iconOverridePrefix=``;function db(e){e();let t=Z.debounceRendering,n=[];function r(e){n.push(e)}for(Z.debounceRendering=r,$g(Q(fb,{}),document.createElement(`div`));n.length;)n.shift()();Z.debounceRendering=t}var fb=class extends Ig{render(){return Q(`div`,{})}componentDidMount(){this.setState({})}};function pb(e){let t=e_(e),n=t.Provider;return t.Provider=function(){let e=!this.getChildContext,t=n.apply(this,arguments);if(e){let e=[];this.shouldComponentUpdate=t=>{this.props.value!==t.value&&e.forEach(e=>{e.context=t.value,e.forceUpdate()})},this.sub=t=>{e.push(t);let n=t.componentWillUnmount;t.componentWillUnmount=()=>{e.splice(e.indexOf(t),1),n&&n.call(t)}}}return t},t}var mb=class{constructor(e,t,n,r){this.execFunc=e,this.emitter=t,this.scrollTime=n,this.scrollTimeReset=r,this.handleScrollRequest=e=>{this.queuedRequest=Object.assign({},this.queuedRequest||{},e),this.drain()},t.on(`_scrollRequest`,this.handleScrollRequest),this.fireInitialScroll()}detach(){this.emitter.off(`_scrollRequest`,this.handleScrollRequest)}update(e){e&&this.scrollTimeReset?this.fireInitialScroll():this.drain()}fireInitialScroll(){this.handleScrollRequest({time:this.scrollTime})}drain(){this.queuedRequest&&this.execFunc(this.queuedRequest)&&(this.queuedRequest=null)}},hb=pb({});function gb(e,t,n,r,i,a,o,s,c,l,u,d,f,p){return{dateEnv:i,nowManager:a,options:n,pluginHooks:s,emitter:u,dispatch:c,getCurrentData:l,calendarApi:d,viewSpec:e,viewApi:t,dateProfileGenerator:r,theme:o,isRtl:n.direction===`rtl`,addResizeHandler(e){u.on(`_resize`,e)},removeResizeHandler(e){u.off(`_resize`,e)},createScrollResponder(e){return new mb(e,u,Tv(n.scrollTime),n.scrollTimeReset)},registerInteractiveComponent:f,unregisterInteractiveComponent:p}}var _b=class extends Ig{shouldComponentUpdate(e,t){return!tb(this.props,e,this.propEquality)||!tb(this.state,t,this.stateEquality)}safeSetState(e){tb(this.state,Object.assign(Object.assign({},this.state),e),this.stateEquality)||this.setState(e)}};_b.addPropsEquality=yb,_b.addStateEquality=bb,_b.contextType=hb,_b.prototype.propEquality={},_b.prototype.stateEquality={};var vb=class extends _b{};vb.contextType=hb;function yb(e){let t=Object.create(this.prototype.propEquality);Object.assign(t,e),this.prototype.propEquality=t}function bb(e){let t=Object.create(this.prototype.stateEquality);Object.assign(t,e),this.prototype.stateEquality=t}function xb(e,t){typeof e==`function`?e(t):e&&(e.current=t)}var Sb=class extends vb{constructor(){super(...arguments),this.id=hv(),this.queuedDomNodes=[],this.currentDomNodes=[],this.handleEl=e=>{let{options:t}=this.context,{generatorName:n}=this.props;(!t.customRenderingReplaces||!Cb(n,t))&&this.updateElRef(e)},this.updateElRef=e=>{this.props.elRef&&xb(this.props.elRef,e)}}render(){let{props:e,context:t}=this,{options:n}=t,{customGenerator:r,defaultGenerator:i,renderProps:a}=e,o=wb(e,[],this.handleEl),s=!1,c,l=[],u;if(r!=null){let e=typeof r==`function`?r(a,Q):r;if(e===!0)s=!0;else{let t=e&&typeof e==`object`;t&&`html`in e?o.dangerouslySetInnerHTML={__html:e.html}:t&&`domNodes`in e?l=Array.prototype.slice.call(e.domNodes):(t?_g(e):typeof e!=`function`)?c=e:u=e}}else s=!Cb(e.generatorName,n);return s&&i&&(c=i(a)),this.queuedDomNodes=l,this.currentGeneratorMeta=u,Q(e.elTag,o,c)}componentDidMount(){this.applyQueueudDomNodes(),this.triggerCustomRendering(!0)}componentDidUpdate(){this.applyQueueudDomNodes(),this.triggerCustomRendering(!0)}componentWillUnmount(){this.triggerCustomRendering(!1)}triggerCustomRendering(e){let{props:t,context:n}=this,{handleCustomRendering:r,customRenderingMetaMap:i}=n.options;if(r){let n=this.currentGeneratorMeta??i?.[t.generatorName];n&&r(Object.assign(Object.assign({id:this.id,isActive:e,containerEl:this.base,reportNewContainerEl:this.updateElRef,generatorMeta:n},t),{elClasses:(t.elClasses||[]).filter(Tb)}))}}applyQueueudDomNodes(){let{queuedDomNodes:e,currentDomNodes:t}=this,n=this.base;if(!Fv(e,t)){t.forEach($_);for(let t of e)n.appendChild(t);this.currentDomNodes=e}}};Sb.addPropsEquality({elClasses:Fv,elStyle:Zy,elAttrs:$y,renderProps:Zy});function Cb(e,t){return!!(t.handleCustomRendering&&e&&t.customRenderingMetaMap?.[e])}function wb(e,t,n){let r=Object.assign(Object.assign({},e.elAttrs),{ref:n});return(e.elClasses||t)&&(r.className=(e.elClasses||[]).concat(t||[]).concat(r.className||[]).filter(Boolean).join(` `)),e.elStyle&&(r.style=e.elStyle),r}function Tb(e){return!!e}var Eb=pb(0),Db=class extends Ig{constructor(){super(...arguments),this.InnerContent=Ob.bind(void 0,this),this.handleEl=e=>{this.el=e,this.props.elRef&&(xb(this.props.elRef,e),e&&this.didMountMisfire&&this.componentDidMount())}}render(){let{props:e}=this,t=kb(e.classNameGenerator,e.renderProps);if(e.children){let n=wb(e,t,this.handleEl),r=e.children(this.InnerContent,e.renderProps,n);return e.elTag?Q(e.elTag,n,r):r}return Q(Sb,Object.assign(Object.assign({},e),{elRef:this.handleEl,elTag:e.elTag||`div`,elClasses:(e.elClasses||[]).concat(t),renderId:this.context}))}componentDidMount(){var e,t;this.el?(t=(e=this.props).didMount)==null||t.call(e,Object.assign(Object.assign({},this.props.renderProps),{el:this.el})):this.didMountMisfire=!0}componentWillUnmount(){var e,t;(t=(e=this.props).willUnmount)==null||t.call(e,Object.assign(Object.assign({},this.props.renderProps),{el:this.el}))}};Db.contextType=Eb;function Ob(e,t){let n=e.props;return Q(Sb,Object.assign({renderProps:n.renderProps,generatorName:n.generatorName,customGenerator:n.customGenerator,defaultGenerator:n.defaultGenerator,renderId:e.context},t))}function kb(e,t){let n=typeof e==`function`?e(t):e||[];return typeof n==`string`?[n]:n}var Ab=class extends vb{render(){let{props:e,context:t}=this,{options:n}=t,r={view:t.viewApi};return Q(Db,{elRef:e.elRef,elTag:e.elTag||`div`,elAttrs:e.elAttrs,elClasses:[...jb(e.viewSpec),...e.elClasses||[]],elStyle:e.elStyle,renderProps:r,classNameGenerator:n.viewClassNames,generatorName:void 0,didMount:n.viewDidMount,willUnmount:n.viewWillUnmount},()=>e.children)}};function jb(e){return[`fc-${e.type}-view`,`fc-view`]}function Mb(e,t){let n=null,r=null;return e.start&&(n=t.createMarker(e.start)),e.end&&(r=t.createMarker(e.end)),!n&&!r||n&&r&&r<n?null:{start:n,end:r}}function Nb(e,t){let n=[],{start:r}=t,i,a;for(e.sort(Pb),i=0;i<e.length;i+=1)a=e[i],a.start>r&&n.push({start:r,end:a.start}),a.end>r&&(r=a.end);return r<t.end&&n.push({start:r,end:t.end}),n}function Pb(e,t){return e.start.valueOf()-t.start.valueOf()}function Fb(e,t){let{start:n,end:r}=e,i=null;return t.start!==null&&(n=n===null?t.start:new Date(Math.max(n.valueOf(),t.start.valueOf()))),t.end!=null&&(r=r===null?t.end:new Date(Math.min(r.valueOf(),t.end.valueOf()))),(n===null||r===null||n<r)&&(i={start:n,end:r}),i}function Ib(e,t){return(e.end===null||t.start===null||e.end>t.start)&&(e.start===null||t.end===null||e.start<t.end)}function Lb(e,t){return(e.start===null||t>=e.start)&&(e.end===null||t<e.end)}function Rb(e,t){return t.start!=null&&e<t.start?t.start:t.end!=null&&e>=t.end?new Date(t.end.valueOf()-1):e}function zb(e){let t=Math.floor(Vv(e.start,e.end))||1,n=Jv(e.start);return{start:n,end:Rv(n,t)}}function Bb(e,t=Tv(0)){let n=null,r=null;if(e.end){r=Jv(e.end);let n=e.end.valueOf()-r.valueOf();n&&n>=Nv(t)&&(r=Rv(r,1))}return e.start&&(n=Jv(e.start),r&&r<=n&&(r=Rv(n,1))),{start:n,end:r}}function Vb(e,t,n,r){return r===`year`?Tv(n.diffWholeYears(e,t),`year`):r===`month`?Tv(n.diffWholeMonths(e,t),`month`):Gv(e,t)}var Hb=class{constructor(e){this.props=e,this.initHiddenDays()}buildPrev(e,t,n){let{dateEnv:r}=this.props,i=r.subtract(r.startOf(t,e.currentRangeUnit),e.dateIncrement);return this.build(i,-1,n)}buildNext(e,t,n){let{dateEnv:r}=this.props,i=r.add(r.startOf(t,e.currentRangeUnit),e.dateIncrement);return this.build(i,1,n)}build(e,t,n=!0){let{props:r}=this,i,a,o,s,c,l;return i=this.buildValidRange(),i=this.trimHiddenDays(i),n&&(e=Rb(e,i)),a=this.buildCurrentRangeInfo(e,t),o=/^(year|month|week|day)$/.test(a.unit),s=this.buildRenderRange(this.trimHiddenDays(a.range),a.unit,o),s=this.trimHiddenDays(s),c=s,r.showNonCurrentDates||(c=Fb(c,a.range)),c=this.adjustActiveRange(c),c=Fb(c,i),l=Ib(a.range,i),Lb(s,e)||(e=s.start),{currentDate:e,validRange:i,currentRange:a.range,currentRangeUnit:a.unit,isRangeAllDay:o,activeRange:c,renderRange:s,slotMinTime:r.slotMinTime,slotMaxTime:r.slotMaxTime,isValid:l,dateIncrement:this.buildDateIncrement(a.duration)}}buildValidRange(){let e=this.props.validRangeInput,t=typeof e==`function`?e.call(this.props.calendarApi,this.props.dateEnv.toDate(this.props.nowManager.getDateMarker())):e;return this.refineRange(t)||{start:null,end:null}}buildCurrentRangeInfo(e,t){let{props:n}=this,r=null,i=null,a=null,o;return n.duration?(r=n.duration,i=n.durationUnit,a=this.buildRangeFromDuration(e,t,r,i)):(o=this.props.dayCount)?(i=`day`,a=this.buildRangeFromDayCount(e,t,o)):(a=this.buildCustomVisibleRange(e))?i=n.dateEnv.greatestWholeUnit(a.start,a.end).unit:(r=this.getFallbackDuration(),i=Pv(r).unit,a=this.buildRangeFromDuration(e,t,r,i)),{duration:r,unit:i,range:a}}getFallbackDuration(){return Tv({day:1})}adjustActiveRange(e){let{dateEnv:t,usesMinMaxTime:n,slotMinTime:r,slotMaxTime:i}=this.props,{start:a,end:o}=e;return n&&(Mv(r)<0&&(a=Jv(a),a=t.add(a,r)),Mv(i)>1&&(o=Jv(o),o=Rv(o,-1),o=t.add(o,i))),{start:a,end:o}}buildRangeFromDuration(e,t,n,r){let{dateEnv:i,dateAlignment:a}=this.props,o,s,c;if(!a){let{dateIncrement:e}=this.props;a=e&&Nv(e)<Nv(n)?Pv(e).unit:r}Mv(n)<=1&&this.isHiddenDay(o)&&(o=this.skipHiddenDays(o,t),o=Jv(o));function l(){o=i.startOf(e,a),s=i.add(o,n),c={start:o,end:s}}return l(),this.trimHiddenDays(c)||(e=this.skipHiddenDays(e,t),l()),c}buildRangeFromDayCount(e,t,n){let{dateEnv:r,dateAlignment:i}=this.props,a=0,o=e,s;i&&(o=r.startOf(o,i)),o=Jv(o),o=this.skipHiddenDays(o,t),s=o;do s=Rv(s,1),this.isHiddenDay(s)||(a+=1);while(a<n);return{start:o,end:s}}buildCustomVisibleRange(e){let{props:t}=this,n=t.visibleRangeInput,r=typeof n==`function`?n.call(t.calendarApi,t.dateEnv.toDate(e)):n,i=this.refineRange(r);return i&&(i.start==null||i.end==null)?null:i}buildRenderRange(e,t,n){return e}buildDateIncrement(e){let{dateIncrement:t}=this.props,n;return t||((n=this.props.dateAlignment)?Tv(1,n):e||Tv({days:1}))}refineRange(e){if(e){let t=Mb(e,this.props.dateEnv);return t&&=Bb(t),t}return null}initHiddenDays(){let e=this.props.hiddenDays||[],t=[],n=0,r;for(this.props.weekends===!1&&e.push(0,6),r=0;r<7;r+=1)(t[r]=e.indexOf(r)!==-1)||(n+=1);if(!n)throw Error(`invalid hiddenDays`);this.isHiddenDayHash=t}trimHiddenDays(e){let{start:t,end:n}=e;return t&&=this.skipHiddenDays(t),n&&=this.skipHiddenDays(n,-1,!0),t==null||n==null||t<n?{start:t,end:n}:null}isHiddenDay(e){return e instanceof Date&&(e=e.getUTCDay()),this.isHiddenDayHash[e]}skipHiddenDays(e,t=1,n=!1){for(;this.isHiddenDayHash[(e.getUTCDay()+(n?t:0)+7)%7];)e=Rv(e,t);return e}};function Ub(e,t,n,r){return{instanceId:hv(),defId:e,range:t,forcedStartTzo:n??null,forcedEndTzo:r??null}}function Wb(e,t,n,r){for(let i=0;i<r.length;i+=1){let a=r[i].parse(e,n);if(a){let{allDay:n}=e;return n??(n=t,n??(n=a.allDayGuess,n??=!1)),{allDay:n,duration:a.duration,typeData:a.typeData,typeId:i}}}return null}function Gb(e,t,n){let{dateEnv:r,pluginHooks:i,options:a}=n,{defs:o,instances:s}=e;s=qy(s,e=>!o[e.defId].recurringDef);for(let e in o){let n=o[e];if(n.recurringDef){let{duration:o}=n.recurringDef;o||=n.allDay?a.defaultAllDayEventDuration:a.defaultTimedEventDuration;let c=Kb(n,o,t,r,i.recurringTypes);for(let t of c){let n=Ub(e,{start:t,end:r.add(t,o)});s[n.instanceId]=n}}}return{defs:o,instances:s}}function Kb(e,t,n,r,i){let a=i[e.recurringDef.typeId].expand(e.recurringDef.typeData,{start:r.subtract(n.start,t),end:n.end},r);return e.allDay&&(a=a.map(Jv)),a}var qb={id:String,groupId:String,title:String,url:String,interactive:Boolean},Jb={start:$,end:$,date:$,allDay:Boolean},Yb=Object.assign(Object.assign(Object.assign({},qb),Jb),{extendedProps:$});function Xb(e,t,n,r,i=Qb(n),a,o){let{refined:s,extra:c}=Zb(e,n,i),l=tx(t,n),u=Wb(s,l,n.dateEnv,n.pluginHooks.recurringTypes);if(u){let e=$b(s,c,t?t.sourceId:``,u.allDay,!!u.duration,n,a);return e.recurringDef={typeId:u.typeId,typeData:u.typeData,duration:u.duration},{def:e,instance:null}}let d=ex(s,l,n,r);if(d){let e=$b(s,c,t?t.sourceId:``,d.allDay,d.hasEnd,n,a),r=Ub(e.defId,d.range,d.forcedStartTzo,d.forcedEndTzo);return o&&e.publicId&&o[e.publicId]&&(r.instanceId=o[e.publicId]),{def:e,instance:r}}return null}function Zb(e,t,n=Qb(t)){return Wy(e,n)}function Qb(e){return Object.assign(Object.assign(Object.assign({},fx),Yb),e.pluginHooks.eventRefiners)}function $b(e,t,n,r,i,a,o){let s={title:e.title||``,groupId:e.groupId||``,publicId:e.id||``,url:e.url||``,recurringDef:null,defId:(o&&e.id?o[e.id]:``)||hv(),sourceId:n,allDay:r,hasEnd:i,interactive:e.interactive,ui:mx(e,a),extendedProps:Object.assign(Object.assign({},e.extendedProps||{}),t)};for(let t of a.pluginHooks.eventDefMemberAdders)Object.assign(s,t(e));return Object.freeze(s.ui.classNames),Object.freeze(s.extendedProps),s}function ex(e,t,n,r){let{allDay:i}=e,a,o=null,s=!1,c,l=null,u=e.start==null?e.date:e.start;if(a=n.dateEnv.createMarkerMeta(u),a)o=a.marker;else if(!r)return null;return e.end!=null&&(c=n.dateEnv.createMarkerMeta(e.end)),i??=t??((!a||a.isTimeUnspecified)&&(!c||c.isTimeUnspecified)),i&&o&&(o=Jv(o)),c&&(l=c.marker,i&&(l=Jv(l)),o&&l<=o&&(l=null)),l?s=!0:r||(s=n.options.forceEventDuration||!1,l=n.dateEnv.add(o,i?n.options.defaultAllDayEventDuration:n.options.defaultTimedEventDuration)),{allDay:i,hasEnd:s,range:{start:o,end:l},forcedStartTzo:a?a.forcedTzo:null,forcedEndTzo:c?c.forcedTzo:null}}function tx(e,t){let n=null;return e&&(n=e.defaultAllDay),n??=t.options.defaultAllDay,n}function nx(e,t,n,r,i,a){let o=ox(),s=Qb(n);for(let c of e){let e=Xb(c,t,n,r,s,i,a);e&&rx(e,o)}return o}function rx(e,t=ox()){return t.defs[e.def.defId]=e.def,e.instance&&(t.instances[e.instance.instanceId]=e.instance),t}function ix(e,t){let n=e.instances[t];if(n){let t=e.defs[n.defId],r=cx(e,e=>ax(t,e));return r.defs[t.defId]=t,r.instances[n.instanceId]=n,r}return ox()}function ax(e,t){return!!(e.groupId&&e.groupId===t.groupId)}function ox(){return{defs:{},instances:{}}}function sx(e,t){return{defs:Object.assign(Object.assign({},e.defs),t.defs),instances:Object.assign(Object.assign({},e.instances),t.instances)}}function cx(e,t){let n=qy(e.defs,t);return{defs:n,instances:qy(e.instances,e=>n[e.defId])}}function lx(e,t){let{defs:n,instances:r}=e,i={},a={};for(let e in n)t.defs[e]||(i[e]=n[e]);for(let e in r)!t.instances[e]&&i[r[e].defId]&&(a[e]=r[e]);return{defs:i,instances:a}}function ux(e,t){return Array.isArray(e)?nx(e,null,t,!0):typeof e==`object`&&e?nx([e],null,t,!0):e==null?null:String(e)}function dx(e){return Array.isArray(e)?e:typeof e==`string`?e.split(/\s+/):[]}var fx={display:String,editable:Boolean,startEditable:Boolean,durationEditable:Boolean,constraint:$,overlap:$,allow:$,className:dx,classNames:dx,color:String,backgroundColor:String,borderColor:String,textColor:String},px={display:null,startEditable:null,durationEditable:null,constraints:[],overlap:null,allows:[],backgroundColor:``,borderColor:``,textColor:``,classNames:[]};function mx(e,t){let n=ux(e.constraint,t);return{display:e.display||null,startEditable:e.startEditable==null?e.editable:e.startEditable,durationEditable:e.durationEditable==null?e.editable:e.durationEditable,constraints:n==null?[]:[n],overlap:e.overlap==null?null:e.overlap,allows:e.allow==null?[]:[e.allow],backgroundColor:e.backgroundColor||e.color||``,borderColor:e.borderColor||e.color||``,textColor:e.textColor||``,classNames:(e.className||[]).concat(e.classNames||[])}}function hx(e){return e.reduce(gx,px)}function gx(e,t){return{display:t.display==null?e.display:t.display,startEditable:t.startEditable==null?e.startEditable:t.startEditable,durationEditable:t.durationEditable==null?e.durationEditable:t.durationEditable,constraints:e.constraints.concat(t.constraints),overlap:typeof t.overlap==`boolean`?t.overlap:e.overlap,allows:e.allows.concat(t.allows),backgroundColor:t.backgroundColor||e.backgroundColor,borderColor:t.borderColor||e.borderColor,textColor:t.textColor||e.textColor,classNames:e.classNames.concat(t.classNames)}}var _x={id:String,defaultAllDay:Boolean,url:String,format:String,events:$,eventDataTransform:$,success:$,failure:$};function vx(e,t,n=yx(t)){let r;if(typeof e==`string`?r={url:e}:typeof e==`function`||Array.isArray(e)?r={events:e}:typeof e==`object`&&e&&(r=e),r){let{refined:i,extra:a}=Wy(r,n),o=bx(i,t);if(o)return{_raw:e,isFetching:!1,latestFetchId:``,fetchRange:null,defaultAllDay:i.defaultAllDay,eventDataTransform:i.eventDataTransform,success:i.success,failure:i.failure,publicId:i.id||``,sourceId:hv(),sourceDefId:o.sourceDefId,meta:o.meta,ui:mx(i,t),extendedProps:a}}return null}function yx(e){return Object.assign(Object.assign(Object.assign({},fx),_x),e.pluginHooks.eventSourceRefiners)}function bx(e,t){let n=t.pluginHooks.eventSourceDefs;for(let t=n.length-1;t>=0;--t){let r=n[t].parseMeta(e);if(r)return{sourceDefId:t,meta:r}}return null}function xx(e,t,n,r,i){switch(t.type){case`RECEIVE_EVENTS`:return Sx(e,n[t.sourceId],t.fetchId,t.fetchRange,t.rawEvents,i);case`RESET_RAW_EVENTS`:return Cx(e,n[t.sourceId],t.rawEvents,r.activeRange,i);case`ADD_EVENTS`:return Ex(e,t.eventStore,r?r.activeRange:null,i);case`RESET_EVENTS`:return t.eventStore;case`MERGE_EVENTS`:return sx(e,t.eventStore);case`PREV`:case`NEXT`:case`CHANGE_DATE`:case`CHANGE_VIEW_TYPE`:return r?Gb(e,r.activeRange,i):e;case`REMOVE_EVENTS`:return lx(e,t.eventStore);case`REMOVE_EVENT_SOURCE`:return Ox(e,t.sourceId);case`REMOVE_ALL_EVENT_SOURCES`:return cx(e,e=>!e.sourceId);case`REMOVE_ALL_EVENTS`:return ox();default:return e}}function Sx(e,t,n,r,i,a){if(t&&n===t.latestFetchId){let n=nx(wx(i,t,a),t,a);return r&&(n=Gb(n,r,a)),sx(Ox(e,t.sourceId),n)}return e}function Cx(e,t,n,r,i){let{defIdMap:a,instanceIdMap:o}=kx(e);return Gb(nx(wx(n,t,i),t,i,!1,a,o),r,i)}function wx(e,t,n){let r=n.options.eventDataTransform,i=t?t.eventDataTransform:null;return i&&(e=Tx(e,i)),r&&(e=Tx(e,r)),e}function Tx(e,t){let n;if(!t)n=e;else{n=[];for(let r of e){let e=t(r);e?n.push(e):e??n.push(r)}}return n}function Ex(e,t,n,r){return n&&(t=Gb(t,n,r)),sx(e,t)}function Dx(e,t,n){let{defs:r}=e;return{defs:r,instances:Jy(e.instances,e=>r[e.defId].allDay?e:Object.assign(Object.assign({},e),{range:{start:n.createMarker(t.toDate(e.range.start,e.forcedStartTzo)),end:n.createMarker(t.toDate(e.range.end,e.forcedEndTzo))},forcedStartTzo:n.canComputeOffset?null:e.forcedStartTzo,forcedEndTzo:n.canComputeOffset?null:e.forcedEndTzo}))}}function Ox(e,t){return cx(e,e=>e.sourceId!==t)}function kx(e){let{defs:t,instances:n}=e,r={},i={};for(let e in t){let{publicId:n}=t[e];n&&(r[n]=e)}for(let e in n){let{publicId:r}=t[n[e].defId];r&&(i[r]=e)}return{defIdMap:r,instanceIdMap:i}}var Ax=class{constructor(){this.handlers={},this.thisContext=null}setThisContext(e){this.thisContext=e}setOptions(e){this.options=e}on(e,t){jx(this.handlers,e,t)}off(e,t){Mx(this.handlers,e,t)}trigger(e,...t){let n=this.handlers[e]||[],r=this.options&&this.options[e],i=[].concat(r||[],n);for(let e of i)e.apply(this.thisContext,t)}hasHandlers(e){return!!(this.handlers[e]&&this.handlers[e].length||this.options&&this.options[e])}};function jx(e,t,n){(e[t]||(e[t]=[])).push(n)}function Mx(e,t,n){n?e[t]&&(e[t]=e[t].filter(e=>e!==n)):delete e[t]}var Nx={startTime:`09:00`,endTime:`17:00`,daysOfWeek:[1,2,3,4,5],display:`inverse-background`,classNames:`fc-non-business`,groupId:`_businessHours`};function Px(e,t){return nx(Fx(e),null,t)}function Fx(e){let t;return t=e===!0?[{}]:Array.isArray(e)?e.filter(e=>e.daysOfWeek):typeof e==`object`&&e?[e]:[],t=t.map(e=>Object.assign(Object.assign({},Nx),e)),t}function Ix(e,t,n){n.emitter.trigger(`select`,Object.assign(Object.assign({},Rx(e,n)),{jsEvent:t?t.origEvent:null,view:n.viewApi||n.calendarApi.view}))}function Lx(e,t){t.emitter.trigger(`unselect`,{jsEvent:e?e.origEvent:null,view:t.viewApi||t.calendarApi.view})}function Rx(e,t){let n={};for(let r of t.pluginHooks.dateSpanTransforms)Object.assign(n,r(e,t));return Object.assign(n,dS(e,t.dateEnv)),n}function zx(e,t,n){let{dateEnv:r,options:i}=n,a=t;return e?(a=Jv(a),a=r.add(a,i.defaultAllDayEventDuration)):a=r.add(a,i.defaultTimedEventDuration),a}function Bx(e,t,n,r){let i=Xx(e.defs,t),a=ox();for(let t in e.defs){let o=e.defs[t];a.defs[t]=Vx(o,i[t],n,r)}for(let t in e.instances){let o=e.instances[t],s=a.defs[o.defId];a.instances[t]=Hx(o,s,i[o.defId],n,r)}return a}function Vx(e,t,n,r){let i=n.standardProps||{};i.hasEnd==null&&t.durationEditable&&(n.startDelta||n.endDelta)&&(i.hasEnd=!0);let a=Object.assign(Object.assign(Object.assign({},e),i),{ui:Object.assign(Object.assign({},e.ui),i.ui)});n.extendedProps&&(a.extendedProps=Object.assign(Object.assign({},a.extendedProps),n.extendedProps));for(let e of r.pluginHooks.eventDefMutationAppliers)e(a,n,r);return!a.hasEnd&&r.options.forceEventDuration&&(a.hasEnd=!0),a}function Hx(e,t,n,r,i){let{dateEnv:a}=i,o=r.standardProps&&r.standardProps.allDay===!0,s=r.standardProps&&r.standardProps.hasEnd===!1,c=Object.assign({},e);return o&&(c.range=zb(c.range)),r.datesDelta&&n.startEditable&&(c.range={start:a.add(c.range.start,r.datesDelta),end:a.add(c.range.end,r.datesDelta)}),r.startDelta&&n.durationEditable&&(c.range={start:a.add(c.range.start,r.startDelta),end:c.range.end}),r.endDelta&&n.durationEditable&&(c.range={start:c.range.start,end:a.add(c.range.end,r.endDelta)}),s&&(c.range={start:c.range.start,end:zx(t.allDay,c.range.start,i)}),t.allDay&&(c.range={start:Jv(c.range.start),end:Jv(c.range.end)}),c.range.end<c.range.start&&(c.range.end=zx(t.allDay,c.range.start,i)),c}var Ux=class{constructor(e,t){this.context=e,this.internalEventSource=t}remove(){this.context.dispatch({type:`REMOVE_EVENT_SOURCE`,sourceId:this.internalEventSource.sourceId})}refetch(){this.context.dispatch({type:`FETCH_EVENT_SOURCES`,sourceIds:[this.internalEventSource.sourceId],isRefetch:!0})}get id(){return this.internalEventSource.publicId}get url(){return this.internalEventSource.meta.url}get format(){return this.internalEventSource.meta.format}},Wx=class e{constructor(e,t,n){this._context=e,this._def=t,this._instance=n||null}setProp(e,t){if(e in Jb)console.warn(`Could not set date-related prop 'name'. Use one of the date-related methods instead.`);else if(e===`id`)t=qb[e](t),this.mutate({standardProps:{publicId:t}});else if(e in qb)t=qb[e](t),this.mutate({standardProps:{[e]:t}});else if(e in fx){let n=fx[e](t);n=e===`color`?{backgroundColor:t,borderColor:t}:e===`editable`?{startEditable:t,durationEditable:t}:{[e]:t},this.mutate({standardProps:{ui:n}})}else console.warn(`Could not set prop '${e}'. Use setExtendedProp instead.`)}setExtendedProp(e,t){this.mutate({extendedProps:{[e]:t}})}setStart(e,t={}){let{dateEnv:n}=this._context,r=n.createMarker(e);if(r&&this._instance){let e=this._instance.range,i=Vb(e.start,r,n,t.granularity);t.maintainDuration?this.mutate({datesDelta:i}):this.mutate({startDelta:i})}}setEnd(e,t={}){let{dateEnv:n}=this._context,r;if(!(e!=null&&(r=n.createMarker(e),!r))&&this._instance){if(r){let e=Vb(this._instance.range.end,r,n,t.granularity);this.mutate({endDelta:e})}else this.mutate({standardProps:{hasEnd:!1}})}}setDates(e,t,n={}){let{dateEnv:r}=this._context,i={allDay:n.allDay},a=r.createMarker(e),o;if(a&&!(t!=null&&(o=r.createMarker(t),!o))&&this._instance){let e=this._instance.range;n.allDay===!0&&(e=zb(e));let t=Vb(e.start,a,r,n.granularity);if(o){let a=Vb(e.end,o,r,n.granularity);Ov(t,a)?this.mutate({datesDelta:t,standardProps:i}):this.mutate({startDelta:t,endDelta:a,standardProps:i})}else i.hasEnd=!1,this.mutate({datesDelta:t,standardProps:i})}}moveStart(e){let t=Tv(e);t&&this.mutate({startDelta:t})}moveEnd(e){let t=Tv(e);t&&this.mutate({endDelta:t})}moveDates(e){let t=Tv(e);t&&this.mutate({datesDelta:t})}setAllDay(e,t={}){let n={allDay:e},{maintainDuration:r}=t;r??=this._context.options.allDayMaintainDuration,this._def.allDay!==e&&(n.hasEnd=r),this.mutate({standardProps:n})}formatRange(e){let{dateEnv:t}=this._context,n=this._instance,r=Py(e);return this._def.hasEnd?t.formatRange(n.range.start,n.range.end,r,{forcedStartTzo:n.forcedStartTzo,forcedEndTzo:n.forcedEndTzo}):t.format(n.range.start,r,{forcedTzo:n.forcedStartTzo})}mutate(t){let n=this._instance;if(n){let r=this._def,i=this._context,{eventStore:a}=i.getCurrentData(),o=ix(a,n.instanceId);o=Bx(o,{"":{display:``,startEditable:!0,durationEditable:!0,constraints:[],overlap:null,allows:[],backgroundColor:``,borderColor:``,textColor:``,classNames:[]}},t,i);let s=new e(i,r,n);this._def=o.defs[r.defId],this._instance=o.instances[n.instanceId],i.dispatch({type:`MERGE_EVENTS`,eventStore:o}),i.emitter.trigger(`eventChange`,{oldEvent:s,event:this,relatedEvents:Kx(o,i,n),revert(){i.dispatch({type:`RESET_EVENTS`,eventStore:a})}})}}remove(){let e=this._context,t=Gx(this);e.dispatch({type:`REMOVE_EVENTS`,eventStore:t}),e.emitter.trigger(`eventRemove`,{event:this,relatedEvents:[],revert(){e.dispatch({type:`MERGE_EVENTS`,eventStore:t})}})}get source(){let{sourceId:e}=this._def;return e?new Ux(this._context,this._context.getCurrentData().eventSources[e]):null}get start(){return this._instance?this._context.dateEnv.toDate(this._instance.range.start):null}get end(){return this._instance&&this._def.hasEnd?this._context.dateEnv.toDate(this._instance.range.end):null}get startStr(){let e=this._instance;return e?this._context.dateEnv.formatIso(e.range.start,{omitTime:this._def.allDay,forcedTzo:e.forcedStartTzo}):``}get endStr(){let e=this._instance;return e&&this._def.hasEnd?this._context.dateEnv.formatIso(e.range.end,{omitTime:this._def.allDay,forcedTzo:e.forcedEndTzo}):``}get id(){return this._def.publicId}get groupId(){return this._def.groupId}get allDay(){return this._def.allDay}get title(){return this._def.title}get url(){return this._def.url}get display(){return this._def.ui.display||`auto`}get startEditable(){return this._def.ui.startEditable}get durationEditable(){return this._def.ui.durationEditable}get constraint(){return this._def.ui.constraints[0]||null}get overlap(){return this._def.ui.overlap}get allow(){return this._def.ui.allows[0]||null}get backgroundColor(){return this._def.ui.backgroundColor}get borderColor(){return this._def.ui.borderColor}get textColor(){return this._def.ui.textColor}get classNames(){return this._def.ui.classNames}get extendedProps(){return this._def.extendedProps}toPlainObject(e={}){let t=this._def,{ui:n}=t,{startStr:r,endStr:i}=this,a={allDay:t.allDay};return t.title&&(a.title=t.title),r&&(a.start=r),i&&(a.end=i),t.publicId&&(a.id=t.publicId),t.groupId&&(a.groupId=t.groupId),t.url&&(a.url=t.url),n.display&&n.display!==`auto`&&(a.display=n.display),e.collapseColor&&n.backgroundColor&&n.backgroundColor===n.borderColor?a.color=n.backgroundColor:(n.backgroundColor&&(a.backgroundColor=n.backgroundColor),n.borderColor&&(a.borderColor=n.borderColor)),n.textColor&&(a.textColor=n.textColor),n.classNames.length&&(a.classNames=n.classNames),Object.keys(t.extendedProps).length&&(e.collapseExtendedProps?Object.assign(a,t.extendedProps):a.extendedProps=t.extendedProps),a}toJSON(){return this.toPlainObject()}};function Gx(e){let t=e._def,n=e._instance;return{defs:{[t.defId]:t},instances:n?{[n.instanceId]:n}:{}}}function Kx(e,t,n){let{defs:r,instances:i}=e,a=[],o=n?n.instanceId:``;for(let e in i){let n=i[e],s=r[n.defId];n.instanceId!==o&&a.push(new Wx(t,s,n))}return a}function qx(e,t,n,r){let i={},a={},o={},s=[],c=[],l=Xx(e.defs,t);for(let t in e.defs){let n=e.defs[t];l[n.defId].display===`inverse-background`&&(n.groupId?(i[n.groupId]=[],o[n.groupId]||(o[n.groupId]=n)):a[t]=[])}for(let t in e.instances){let o=e.instances[t],u=e.defs[o.defId],d=l[u.defId],f=o.range,p=!u.allDay&&r?Bb(f,r):f,m=Fb(p,n);m&&(d.display===`inverse-background`?u.groupId?i[u.groupId].push(m):a[o.defId].push(m):d.display!==`none`&&(d.display===`background`?s:c).push({def:u,ui:d,instance:o,range:m,isStart:p.start&&p.start.valueOf()===m.start.valueOf(),isEnd:p.end&&p.end.valueOf()===m.end.valueOf()}))}for(let e in i){let t=i[e],r=Nb(t,n);for(let t of r){let n=o[e],r=l[n.defId];s.push({def:n,ui:r,instance:null,range:t,isStart:!1,isEnd:!1})}}for(let t in a){let r=a[t],i=Nb(r,n);for(let n of i)s.push({def:e.defs[t],ui:l[t],instance:null,range:n,isStart:!1,isEnd:!1})}return{bg:s,fg:c}}function Jx(e,t){e.fcSeg=t}function Yx(e){return e.fcSeg||e.parentNode.fcSeg||null}function Xx(e,t){return Jy(e,e=>Zx(e,t))}function Zx(e,t){let n=[];return t[``]&&n.push(t[``]),t[e.defId]&&n.push(t[e.defId]),n.push(e.ui),hx(n)}function Qx(e,t){let n=e.map($x);return n.sort((e,n)=>_v(e,n,t)),n.map(e=>e._seg)}function $x(e){let{eventRange:t}=e,n=t.def,r=t.instance?t.instance.range:t.range,i=r.start?r.start.valueOf():0,a=r.end?r.end.valueOf():0;return Object.assign(Object.assign(Object.assign({},n.extendedProps),n),{id:n.publicId,start:i,end:a,duration:a-i,allDay:Number(n.allDay),_seg:e})}function eS(e,t){let{pluginHooks:n}=t,r=n.isDraggableTransformers,{def:i,ui:a}=e.eventRange,o=a.startEditable;for(let e of r)o=e(o,i,a,t);return o}function tS(e,t){return e.isStart&&e.eventRange.ui.durationEditable&&t.options.eventResizableFromStart}function nS(e,t){return e.isEnd&&e.eventRange.ui.durationEditable}function rS(e,t,n,r,i,a,o){let{dateEnv:s,options:c}=n,{displayEventTime:l,displayEventEnd:u}=c,d=e.eventRange.def,f=e.eventRange.instance;l??=r!==!1,u??=i!==!1;let p=f.range.start,m=f.range.end,h=a||e.start||e.eventRange.range.start,g=o||e.end||e.eventRange.range.end,_=Jv(p).valueOf()===Jv(h).valueOf(),v=Jv(zv(m,-1)).valueOf()===Jv(zv(g,-1)).valueOf();return l&&!d.allDay&&(_||v)?(h=_?p:h,g=v?m:g,u&&d.hasEnd?s.formatRange(h,g,t,{forcedStartTzo:a?null:f.forcedStartTzo,forcedEndTzo:o?null:f.forcedEndTzo}):s.format(h,t,{forcedTzo:a?null:f.forcedStartTzo})):``}function iS(e,t,n){let r=e.eventRange.range;return{isPast:r.end<=(n||t.start),isFuture:r.start>=(n||t.end),isToday:t&&Lb(t,r.start)}}function aS(e){let t=[`fc-event`];return e.isMirror&&t.push(`fc-event-mirror`),e.isDraggable&&t.push(`fc-event-draggable`),(e.isStartResizable||e.isEndResizable)&&t.push(`fc-event-resizable`),e.isDragging&&t.push(`fc-event-dragging`),e.isResizing&&t.push(`fc-event-resizing`),e.isSelected&&t.push(`fc-event-selected`),e.isStart&&t.push(`fc-event-start`),e.isEnd&&t.push(`fc-event-end`),e.isPast&&t.push(`fc-event-past`),e.isToday&&t.push(`fc-event-today`),e.isFuture&&t.push(`fc-event-future`),t}function oS(e){return e.instance?e.instance.instanceId:`${e.def.defId}:${e.range.start.toISOString()}`}function sS(e,t){let{def:n,instance:r}=e.eventRange,{url:i}=n;if(i)return{href:i};let{emitter:a,options:o}=t,{eventInteractive:s}=o;return s??(s=n.interactive,s??=!!a.hasHandlers(`eventClick`)),s?pv(e=>{a.trigger(`eventClick`,{el:e.target,event:new Wx(t,n,r),jsEvent:e,view:t.viewApi})}):{}}var cS={start:$,end:$,allDay:Boolean};function lS(e,t,n){let r=uS(e,t),{range:i}=r;if(!i.start)return null;if(!i.end){if(n==null)return null;i.end=t.add(i.start,n)}return r}function uS(e,t){let{refined:n,extra:r}=Wy(e,cS),i=n.start?t.createMarkerMeta(n.start):null,a=n.end?t.createMarkerMeta(n.end):null,{allDay:o}=n;return o??=i&&i.isTimeUnspecified&&(!a||a.isTimeUnspecified),Object.assign({range:{start:i?i.marker:null,end:a?a.marker:null},allDay:o},r)}function dS(e,t){return Object.assign(Object.assign({},pS(e.range,t,e.allDay)),{allDay:e.allDay})}function fS(e,t,n){return Object.assign(Object.assign({},pS(e,t,n)),{timeZone:t.timeZone})}function pS(e,t,n){return{start:t.toDate(e.start),end:t.toDate(e.end),startStr:t.formatIso(e.start,{omitTime:n}),endStr:t.formatIso(e.end,{omitTime:n})}}function mS(e,t,n){let r=Zb({editable:!1},n),i=$b(r.refined,r.extra,``,e.allDay,!0,n);return{def:i,ui:Zx(i,t),instance:Ub(i.defId,e.range),range:e.range,isStart:!0,isEnd:!0}}function hS(e,t,n){let r=!1,i=function(e){r||(r=!0,t(e))},a=function(e){r||(r=!0,n(e))},o=e(i,a);o&&typeof o.then==`function`&&o.then(i,a)}var gS=class extends Error{constructor(e,t){super(e),this.response=t}};function _S(e,t,n){e=e.toUpperCase();let r={method:e};return e===`GET`?t+=(t.indexOf(`?`)===-1?`?`:`&`)+new URLSearchParams(n):(r.body=new URLSearchParams(n),r.headers={"Content-Type":`application/x-www-form-urlencoded`}),fetch(t,r).then(e=>{if(e.ok)return e.json().then(t=>[t,e],()=>{throw new gS(`Failure parsing JSON`,e)});throw new gS(`Request failed`,e)})}var vS;function yS(){return vS??=bS(),vS}function bS(){if(typeof document>`u`)return!0;let e=document.createElement(`div`);e.style.position=`absolute`,e.style.top=`0px`,e.style.left=`0px`,e.innerHTML=`<table><tr><td><div></div></td></tr></table>`,e.querySelector(`table`).style.height=`100px`,e.querySelector(`div`).style.height=`100%`,document.body.appendChild(e);let t=e.querySelector(`div`).offsetHeight>0;return document.body.removeChild(e),t}var xS=class extends vb{constructor(){super(...arguments),this.state={forPrint:!1},this.handleBeforePrint=()=>{db(()=>{this.setState({forPrint:!0})})},this.handleAfterPrint=()=>{db(()=>{this.setState({forPrint:!1})})}}render(){let{props:e}=this,{options:t}=e,{forPrint:n}=this.state,r=n||t.height===`auto`||t.contentHeight===`auto`,i=!r&&t.height!=null?t.height:``,a=[`fc`,n?`fc-media-print`:`fc-media-screen`,`fc-direction-${t.direction}`,e.theme.getClass(`root`)];return yS()||a.push(`fc-liquid-hack`),e.children(a,i,r,n)}componentDidMount(){let{emitter:e}=this.props;e.on(`_beforeprint`,this.handleBeforePrint),e.on(`_afterprint`,this.handleAfterPrint)}componentWillUnmount(){let{emitter:e}=this.props;e.off(`_beforeprint`,this.handleBeforePrint),e.off(`_afterprint`,this.handleAfterPrint)}},SS=class{constructor(e){this.component=e.component,this.isHitComboAllowed=e.isHitComboAllowed||null}destroy(){}};function CS(e,t){return{component:e,el:t.el,useEventCenter:t.useEventCenter==null||t.useEventCenter,isHitComboAllowed:t.isHitComboAllowed||null}}var wS={},TS=class extends Ig{constructor(e,t){super(e,t),this.handleRefresh=()=>{let e=this.computeTiming();e.state.nowDate.valueOf()!==this.state.nowDate.valueOf()&&this.setState(e.state),this.clearTimeout(),this.setTimeout(e.waitMs)},this.handleVisibilityChange=()=>{document.hidden||this.handleRefresh()},this.state=this.computeTiming().state}render(){let{props:e,state:t}=this;return e.children(t.nowDate,t.todayRange)}componentDidMount(){this.setTimeout(),this.context.nowManager.addResetListener(this.handleRefresh),document.addEventListener(`visibilitychange`,this.handleVisibilityChange)}componentDidUpdate(e){e.unit!==this.props.unit&&(this.clearTimeout(),this.setTimeout())}componentWillUnmount(){this.clearTimeout(),this.context.nowManager.removeResetListener(this.handleRefresh),document.removeEventListener(`visibilitychange`,this.handleVisibilityChange)}computeTiming(){let{props:e,context:t}=this,n=t.nowManager.getDateMarker(),{nowIndicatorSnap:r}=t.options;r===`auto`&&(r=/year|month|week|day/.test(e.unit)||(e.unitValue||1)===1);let i,a;return r?(i=t.dateEnv.startOf(n,e.unit),a=t.dateEnv.add(i,Tv(1,e.unit)).valueOf()-n.valueOf()):(i=n,a=6e4),a=Math.min(864e5,a),{state:{nowDate:i,todayRange:ES(i)},waitMs:a}}setTimeout(e=this.computeTiming().waitMs){this.timeoutId=setTimeout(()=>{let e=this.computeTiming();this.setState(e.state,()=>{this.setTimeout(e.waitMs)})},e)}clearTimeout(){this.timeoutId&&clearTimeout(this.timeoutId)}};TS.contextType=hb;function ES(e){let t=Jv(e);return{start:t,end:Rv(t,1)}}var DS=class{getCurrentData(){return this.currentDataManager.getCurrentData()}dispatch(e){this.currentDataManager.dispatch(e)}get view(){return this.getCurrentData().viewApi}batchRendering(e){e()}updateSize(){this.trigger(`_resize`,!0)}setOption(e,t){this.dispatch({type:`SET_OPTION`,optionName:e,rawOptionValue:t})}getOption(e){return this.currentDataManager.currentCalendarOptionsInput[e]}getAvailableLocaleCodes(){return Object.keys(this.getCurrentData().availableRawLocales)}on(e,t){let{currentDataManager:n}=this;n.currentCalendarOptionsRefiners[e]?n.emitter.on(e,t):console.warn(`Unknown listener name '${e}'`)}off(e,t){this.currentDataManager.emitter.off(e,t)}trigger(e,...t){this.currentDataManager.emitter.trigger(e,...t)}changeView(e,t){this.batchRendering(()=>{if(this.unselect(),t){if(t.start&&t.end)this.dispatch({type:`CHANGE_VIEW_TYPE`,viewType:e}),this.dispatch({type:`SET_OPTION`,optionName:`visibleRange`,rawOptionValue:t});else{let{dateEnv:n}=this.getCurrentData();this.dispatch({type:`CHANGE_VIEW_TYPE`,viewType:e,dateMarker:n.createMarker(t)})}}else this.dispatch({type:`CHANGE_VIEW_TYPE`,viewType:e})})}zoomTo(e,t){let n=this.getCurrentData(),r;t||=`day`,r=n.viewSpecs[t]||this.getUnitViewSpec(t),this.unselect(),r?this.dispatch({type:`CHANGE_VIEW_TYPE`,viewType:r.type,dateMarker:e}):this.dispatch({type:`CHANGE_DATE`,dateMarker:e})}getUnitViewSpec(e){let{viewSpecs:t,toolbarConfig:n}=this.getCurrentData(),r=[].concat(n.header?n.header.viewsWithButtons:[],n.footer?n.footer.viewsWithButtons:[]),i,a;for(let e in t)r.push(e);for(i=0;i<r.length;i+=1)if(a=t[r[i]],a&&a.singleUnit===e)return a;return null}prev(){this.unselect(),this.dispatch({type:`PREV`})}next(){this.unselect(),this.dispatch({type:`NEXT`})}prevYear(){let e=this.getCurrentData();this.unselect(),this.dispatch({type:`CHANGE_DATE`,dateMarker:e.dateEnv.addYears(e.currentDate,-1)})}nextYear(){let e=this.getCurrentData();this.unselect(),this.dispatch({type:`CHANGE_DATE`,dateMarker:e.dateEnv.addYears(e.currentDate,1)})}today(){let e=this.getCurrentData();this.unselect(),this.dispatch({type:`CHANGE_DATE`,dateMarker:e.nowManager.getDateMarker()})}gotoDate(e){let t=this.getCurrentData();this.unselect(),this.dispatch({type:`CHANGE_DATE`,dateMarker:t.dateEnv.createMarker(e)})}incrementDate(e){let t=this.getCurrentData(),n=Tv(e);n&&(this.unselect(),this.dispatch({type:`CHANGE_DATE`,dateMarker:t.dateEnv.add(t.currentDate,n)}))}getDate(){let e=this.getCurrentData();return e.dateEnv.toDate(e.currentDate)}formatDate(e,t){let{dateEnv:n}=this.getCurrentData();return n.format(n.createMarker(e),Py(t))}formatRange(e,t,n){let{dateEnv:r}=this.getCurrentData();return r.formatRange(r.createMarker(e),r.createMarker(t),Py(n),n)}formatIso(e,t){let{dateEnv:n}=this.getCurrentData();return n.formatIso(n.createMarker(e),{omitTime:t})}select(e,t){let n;n=t==null?e.start==null?{start:e,end:null}:e:{start:e,end:t};let r=this.getCurrentData(),i=lS(n,r.dateEnv,Tv({days:1}));i&&(this.dispatch({type:`SELECT_DATES`,selection:i}),Ix(i,null,r))}unselect(e){let t=this.getCurrentData();t.dateSelection&&(this.dispatch({type:`UNSELECT_DATES`}),Lx(e,t))}addEvent(e,t){if(e instanceof Wx){let t=e._def,n=e._instance;return this.getCurrentData().eventStore.defs[t.defId]||(this.dispatch({type:`ADD_EVENTS`,eventStore:rx({def:t,instance:n})}),this.triggerEventAdd(e)),e}let n=this.getCurrentData(),r;if(t instanceof Ux)r=t.internalEventSource;else if(typeof t==`boolean`)t&&([r]=Xy(n.eventSources));else if(t!=null){let e=this.getEventSourceById(t);if(!e)return console.warn(`Could not find an event source with ID "${t}"`),null;r=e.internalEventSource}let i=Xb(e,r,n,!1);if(i){let e=new Wx(n,i.def,i.def.recurringDef?null:i.instance);return this.dispatch({type:`ADD_EVENTS`,eventStore:rx(i)}),this.triggerEventAdd(e),e}return null}triggerEventAdd(e){let{emitter:t}=this.getCurrentData();t.trigger(`eventAdd`,{event:e,relatedEvents:[],revert:()=>{this.dispatch({type:`REMOVE_EVENTS`,eventStore:Gx(e)})}})}getEventById(e){let t=this.getCurrentData(),{defs:n,instances:r}=t.eventStore;e=String(e);for(let i in n){let a=n[i];if(a.publicId===e){if(a.recurringDef)return new Wx(t,a,null);for(let e in r){let n=r[e];if(n.defId===a.defId)return new Wx(t,a,n)}}}return null}getEvents(){let e=this.getCurrentData();return Kx(e.eventStore,e)}removeAllEvents(){this.dispatch({type:`REMOVE_ALL_EVENTS`})}getEventSources(){let e=this.getCurrentData(),t=e.eventSources,n=[];for(let r in t)n.push(new Ux(e,t[r]));return n}getEventSourceById(e){let t=this.getCurrentData(),n=t.eventSources;e=String(e);for(let r in n)if(n[r].publicId===e)return new Ux(t,n[r]);return null}addEventSource(e){let t=this.getCurrentData();if(e instanceof Ux)return t.eventSources[e.internalEventSource.sourceId]||this.dispatch({type:`ADD_EVENT_SOURCES`,sources:[e.internalEventSource]}),e;let n=vx(e,t);return n?(this.dispatch({type:`ADD_EVENT_SOURCES`,sources:[n]}),new Ux(t,n)):null}removeAllEventSources(){this.dispatch({type:`REMOVE_ALL_EVENT_SOURCES`})}refetchEvents(){this.dispatch({type:`FETCH_EVENT_SOURCES`,isRefetch:!0})}scrollToTime(e){let t=Tv(e);t&&this.trigger(`_scrollRequest`,{time:t})}};function OS(e,t){let n={left:Math.max(e.left,t.left),right:Math.min(e.right,t.right),top:Math.max(e.top,t.top),bottom:Math.min(e.bottom,t.bottom)};return n.left<n.right&&n.top<n.bottom&&n}function kS(e,t,n,r){return{dow:e.getUTCDay(),isDisabled:!(!r||r.activeRange&&Lb(r.activeRange,e)),isOther:!(!r||Lb(r.currentRange,e)),isToday:!!(t&&Lb(t,e)),isPast:!!(n?e<n:t&&e<t.start),isFuture:!!(n?e>n:t&&e>=t.end)}}function AS(e,t){let n=[`fc-day`,`fc-day-${Iv[e.dow]}`];return e.isDisabled?n.push(`fc-day-disabled`):(e.isToday&&(n.push(`fc-day-today`),n.push(t.getClass(`today`))),e.isPast&&n.push(`fc-day-past`),e.isFuture&&n.push(`fc-day-future`),e.isOther&&n.push(`fc-day-other`)),n}var jS=Py({year:`numeric`,month:`long`,day:`numeric`}),MS=Py({week:`long`});function NS(e,t,n=`day`,r=!0){let{dateEnv:i,options:a,calendarApi:o}=e,s=i.format(t,n===`week`?MS:jS);if(a.navLinks){let e=i.toDate(t),c=e=>{let r=n===`day`?a.navLinkDayClick:n===`week`?a.navLinkWeekClick:null;typeof r==`function`?r.call(o,i.toDate(t),e):(typeof r==`string`&&(n=r),o.zoomTo(t,n))};return Object.assign({title:xv(a.navLinkHint,[s,e],s),"data-navlink":``},r?fv(c):{onClick:c})}return{"aria-label":s}}var PS;function FS(){return PS||=IS(),PS}function IS(){let e=document.createElement(`div`);e.style.overflow=`scroll`,e.style.position=`absolute`,e.style.top=`-9999px`,e.style.left=`-9999px`,document.body.appendChild(e);let t=LS(e);return document.body.removeChild(e),t}function LS(e){return{x:e.offsetHeight-e.clientHeight,y:e.offsetWidth-e.clientWidth}}function RS(e){let t=zS(e),n=e.getBoundingClientRect();for(let e of t){let t=OS(n,e.getBoundingClientRect());if(t)n=t;else return null}return n}function zS(e){let t=[];for(;e instanceof HTMLElement;){let n=window.getComputedStyle(e);if(n.position===`fixed`)break;/(auto|scroll)/.test(n.overflow+n.overflowY+n.overflowX)&&t.push(e),e=e.parentNode}return t}var BS=class{constructor(e,t,n,r){this.els=t;let i=this.originClientRect=e.getBoundingClientRect();n&&this.buildElHorizontals(i.left),r&&this.buildElVerticals(i.top)}buildElHorizontals(e){let t=[],n=[];for(let r of this.els){let i=r.getBoundingClientRect();t.push(i.left-e),n.push(i.right-e)}this.lefts=t,this.rights=n}buildElVerticals(e){let t=[],n=[];for(let r of this.els){let i=r.getBoundingClientRect();t.push(i.top-e),n.push(i.bottom-e)}this.tops=t,this.bottoms=n}leftToIndex(e){let{lefts:t,rights:n}=this,r=t.length,i=0;for(;i<r;i+=1)if(e>=t[i]&&e<n[i])return i}topToIndex(e){let{tops:t,bottoms:n}=this,r=t.length,i=0;for(;i<r;i+=1)if(e>=t[i]&&e<n[i])return i}getWidth(e){return this.rights[e]-this.lefts[e]}getHeight(e){return this.bottoms[e]-this.tops[e]}similarTo(e){return VS(this.tops||[],e.tops||[])&&VS(this.bottoms||[],e.bottoms||[])&&VS(this.lefts||[],e.lefts||[])&&VS(this.rights||[],e.rights||[])}};function VS(e,t){let n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r++)if(Math.round(e[r])!==Math.round(t[r]))return!1;return!0}var HS=class extends vb{constructor(){super(...arguments),this.uid=hv()}prepareHits(){}queryHit(e,t,n,r){return null}isValidSegDownEl(e){return!this.props.eventDrag&&!this.props.eventResize&&!ev(e,`.fc-event-mirror`)}isValidDateDownEl(e){return!ev(e,`.fc-event:not(.fc-bg-event)`)&&!ev(e,`.fc-more-link`)&&!ev(e,`a[data-navlink]`)&&!ev(e,`.fc-popover`)}},US=class{constructor(e=e=>e.thickness||1){this.getEntryThickness=e,this.strictOrder=!1,this.allowReslicing=!1,this.maxCoord=-1,this.maxStackCnt=-1,this.levelCoords=[],this.entriesByLevel=[],this.stackCnts={}}addSegs(e){let t=[];for(let n of e)this.insertEntry(n,t);return t}insertEntry(e,t){let n=this.findInsertion(e);this.isInsertionValid(n,e)?this.insertEntryAt(e,n):this.handleInvalidInsertion(n,e,t)}isInsertionValid(e,t){return(this.maxCoord===-1||e.levelCoord+this.getEntryThickness(t)<=this.maxCoord)&&(this.maxStackCnt===-1||e.stackCnt<this.maxStackCnt)}handleInvalidInsertion(e,t,n){if(this.allowReslicing&&e.touchingEntry){let r=Object.assign(Object.assign({},t),{span:KS(t.span,e.touchingEntry.span)});n.push(r),this.splitEntry(t,e.touchingEntry,n)}else n.push(t)}splitEntry(e,t,n){let r=e.span,i=t.span;r.start<i.start&&this.insertEntry({index:e.index,thickness:e.thickness,span:{start:r.start,end:i.start}},n),r.end>i.end&&this.insertEntry({index:e.index,thickness:e.thickness,span:{start:i.end,end:r.end}},n)}insertEntryAt(e,t){let{entriesByLevel:n,levelCoords:r}=this;t.lateral===-1?(qS(r,t.level,t.levelCoord),qS(n,t.level,[e])):qS(n[t.level],t.lateral,e),this.stackCnts[GS(e)]=t.stackCnt}findInsertion(e){let{levelCoords:t,entriesByLevel:n,strictOrder:r,stackCnts:i}=this,a=t.length,o=0,s=-1,c=-1,l=null,u=0;for(let d=0;d<a;d+=1){let a=t[d];if(!r&&a>=o+this.getEntryThickness(e))break;let f=n[d],p,m=JS(f,e.span.start,WS),h=m[0]+m[1];for(;(p=f[h])&&p.span.start<e.span.end;){let e=a+this.getEntryThickness(p);e>o&&(o=e,l=p,s=d,c=h),e===o&&(u=Math.max(u,i[GS(p)]+1)),h+=1}}let d=0;if(l)for(d=s+1;d<a&&t[d]<o;)d+=1;let f=-1;return d<a&&t[d]===o&&(f=JS(n[d],e.span.end,WS)[0]),{touchingLevel:s,touchingLateral:c,touchingEntry:l,stackCnt:u,levelCoord:o,level:d,lateral:f}}toRects(){let{entriesByLevel:e,levelCoords:t}=this,n=e.length,r=[];for(let i=0;i<n;i+=1){let n=e[i],a=t[i];for(let e of n)r.push(Object.assign(Object.assign({},e),{thickness:this.getEntryThickness(e),levelCoord:a}))}return r}};function WS(e){return e.span.end}function GS(e){return e.index+`:`+e.span.start}function KS(e,t){let n=Math.max(e.start,t.start),r=Math.min(e.end,t.end);return n<r?{start:n,end:r}:null}function qS(e,t,n){e.splice(t,0,n)}function JS(e,t,n){let r=0,i=e.length;if(!i||t<n(e[r]))return[0,0];if(t>n(e[i-1]))return[i,0];for(;r<i;){let a=Math.floor(r+(i-r)/2),o=n(e[a]);if(t<o)i=a;else if(t>o)r=a+1;else return[a,1]}return[r,0]}function YS(e,t){return Py(!e||t>10?{weekday:`short`}:t>1?{weekday:`short`,month:`numeric`,day:`numeric`,omitCommas:!0}:{weekday:`long`})}var XS=`fc-col-header-cell`;function ZS(e){return e.text}var QS=class extends vb{render(){let{dateEnv:e,options:t,theme:n,viewApi:r}=this.context,{props:i}=this,{date:a,dateProfile:o}=i,s=kS(a,i.todayRange,null,o),c=[XS].concat(AS(s,n)),l=e.format(a,i.dayHeaderFormat),u=!s.isDisabled&&i.colCnt>1?NS(this.context,a):{},d=e.toDate(a);e.namedTimeZoneImpl&&(d=zv(d,36e5));let f=Object.assign(Object.assign(Object.assign({date:d,view:r},i.extraRenderProps),{text:l}),s);return Q(Db,{elTag:`th`,elClasses:c,elAttrs:Object.assign({role:`columnheader`,colSpan:i.colSpan,"data-date":s.isDisabled?void 0:cy(a)},i.extraDataAttrs),renderProps:f,generatorName:`dayHeaderContent`,customGenerator:t.dayHeaderContent,defaultGenerator:ZS,classNameGenerator:t.dayHeaderClassNames,didMount:t.dayHeaderDidMount,willUnmount:t.dayHeaderWillUnmount},e=>Q(`div`,{className:`fc-scrollgrid-sync-inner`},!s.isDisabled&&Q(e,{elTag:`a`,elAttrs:u,elClasses:[`fc-col-header-cell-cushion`,i.isSticky&&`fc-sticky`]})))}},$S=Py({weekday:`long`}),eC=class extends vb{render(){let{props:e}=this,{dateEnv:t,theme:n,viewApi:r,options:i}=this.context,a=Rv(new Date(2592e5),e.dow),o={dow:e.dow,isDisabled:!1,isFuture:!1,isPast:!1,isToday:!1,isOther:!1},s=t.format(a,e.dayHeaderFormat),c=Object.assign(Object.assign(Object.assign(Object.assign({date:a},o),{view:r}),e.extraRenderProps),{text:s});return Q(Db,{elTag:`th`,elClasses:[XS,...AS(o,n),...e.extraClassNames||[]],elAttrs:Object.assign({role:`columnheader`,colSpan:e.colSpan},e.extraDataAttrs),renderProps:c,generatorName:`dayHeaderContent`,customGenerator:i.dayHeaderContent,defaultGenerator:ZS,classNameGenerator:i.dayHeaderClassNames,didMount:i.dayHeaderDidMount,willUnmount:i.dayHeaderWillUnmount},n=>Q(`div`,{className:`fc-scrollgrid-sync-inner`},Q(n,{elTag:`a`,elClasses:[`fc-col-header-cell-cushion`,e.isSticky&&`fc-sticky`],elAttrs:{"aria-label":t.format(a,$S)}})))}},tC=class extends vb{constructor(){super(...arguments),this.createDayHeaderFormatter=dy(nC)}render(){let{context:e}=this,{dates:t,dateProfile:n,datesRepDistinctDays:r,renderIntro:i}=this.props,a=this.createDayHeaderFormatter(e.options.dayHeaderFormat,r,t.length);return Q(TS,{unit:`day`},(e,o)=>Q(`tr`,{role:`row`},i&&i(`day`),t.map(e=>r?Q(QS,{key:e.toISOString(),date:e,dateProfile:n,todayRange:o,colCnt:t.length,dayHeaderFormat:a}):Q(eC,{key:e.getUTCDay(),dow:e.getUTCDay(),dayHeaderFormat:a}))))}};function nC(e,t,n){return e||YS(t,n)}var rC=class{constructor(e,t){let n=e.start,{end:r}=e,i=[],a=[],o=-1;for(;n<r;)t.isHiddenDay(n)?i.push(o+.5):(o+=1,i.push(o),a.push(n)),n=Rv(n,1);this.dates=a,this.indices=i,this.cnt=a.length}sliceRange(e){let t=this.getDateDayIndex(e.start),n=this.getDateDayIndex(Rv(e.end,-1)),r=Math.max(0,t),i=Math.min(this.cnt-1,n);return r=Math.ceil(r),i=Math.floor(i),r<=i?{firstIndex:r,lastIndex:i,isStart:t===r,isEnd:n===i}:null}getDateDayIndex(e){let{indices:t}=this,n=Math.floor(Vv(this.dates[0],e));return n<0?t[0]-1:n>=t.length?t[t.length-1]+1:t[n]}},iC=class{constructor(e,t){let{dates:n}=e,r,i,a;if(t){for(i=n[0].getUTCDay(),r=1;r<n.length&&n[r].getUTCDay()!==i;r+=1);a=Math.ceil(n.length/r)}else a=1,r=n.length;this.rowCnt=a,this.colCnt=r,this.daySeries=e,this.cells=this.buildCells(),this.headerDates=this.buildHeaderDates()}buildCells(){let e=[];for(let t=0;t<this.rowCnt;t+=1){let n=[];for(let e=0;e<this.colCnt;e+=1)n.push(this.buildCell(t,e));e.push(n)}return e}buildCell(e,t){let n=this.daySeries.dates[e*this.colCnt+t];return{key:n.toISOString(),date:n}}buildHeaderDates(){let e=[];for(let t=0;t<this.colCnt;t+=1)e.push(this.cells[0][t].date);return e}sliceRange(e){let{colCnt:t}=this,n=this.daySeries.sliceRange(e),r=[];if(n){let{firstIndex:e,lastIndex:i}=n,a=e;for(;a<=i;){let o=Math.floor(a/t),s=Math.min((o+1)*t,i+1);r.push({row:o,firstCol:a%t,lastCol:(s-1)%t,isStart:n.isStart&&a===e,isEnd:n.isEnd&&s-1===i}),a=s}}return r}},aC=class{constructor(){this.sliceBusinessHours=dy(this._sliceBusinessHours),this.sliceDateSelection=dy(this._sliceDateSpan),this.sliceEventStore=dy(this._sliceEventStore),this.sliceEventDrag=dy(this._sliceInteraction),this.sliceEventResize=dy(this._sliceInteraction),this.forceDayIfListItem=!1}sliceProps(e,t,n,r,...i){let{eventUiBases:a}=e,o=this.sliceEventStore(e.eventStore,a,t,n,...i);return{dateSelectionSegs:this.sliceDateSelection(e.dateSelection,t,n,a,r,...i),businessHourSegs:this.sliceBusinessHours(e.businessHours,t,n,r,...i),fgEventSegs:o.fg,bgEventSegs:o.bg,eventDrag:this.sliceEventDrag(e.eventDrag,a,t,n,...i),eventResize:this.sliceEventResize(e.eventResize,a,t,n,...i),eventSelection:e.eventSelection}}sliceNowDate(e,t,n,r,...i){return this._sliceDateSpan({range:{start:e,end:zv(e,1)},allDay:!1},t,n,{},r,...i)}_sliceBusinessHours(e,t,n,r,...i){return e?this._sliceEventStore(Gb(e,oC(t,!!n),r),{},t,n,...i).bg:[]}_sliceEventStore(e,t,n,r,...i){if(e){let a=qx(e,t,oC(n,!!r),r);return{bg:this.sliceEventRanges(a.bg,i),fg:this.sliceEventRanges(a.fg,i)}}return{bg:[],fg:[]}}_sliceInteraction(e,t,n,r,...i){if(!e)return null;let a=qx(e.mutatedEvents,t,oC(n,!!r),r);return{segs:this.sliceEventRanges(a.fg,i),affectedInstances:e.affectedEvents.instances,isEvent:e.isEvent}}_sliceDateSpan(e,t,n,r,i,...a){if(!e)return[];let o=oC(t,!!n),s=Fb(e.range,o);if(s){e=Object.assign(Object.assign({},e),{range:s});let t=mS(e,r,i),n=this.sliceRange(e.range,...a);for(let e of n)e.eventRange=t;return n}return[]}sliceEventRanges(e,t){let n=[];for(let r of e)n.push(...this.sliceEventRange(r,t));return n}sliceEventRange(e,t){let n=e.range;this.forceDayIfListItem&&e.ui.display===`list-item`&&(n={start:n.start,end:Rv(n.start,1)});let r=this.sliceRange(n,...t);for(let t of r)t.eventRange=e,t.isStart=e.isStart&&t.isStart,t.isEnd=e.isEnd&&t.isEnd;return r}};function oC(e,t){let n=e.activeRange;return t?n:{start:zv(n.start,e.slotMinTime.milliseconds),end:zv(n.end,e.slotMaxTime.milliseconds-864e5)}}var sC=/^(visible|hidden)$/,cC=class extends vb{constructor(){super(...arguments),this.handleEl=e=>{this.el=e,xb(this.props.elRef,e)}}render(){let{props:e}=this,{liquid:t,liquidIsAbsolute:n}=e,r=t&&n,i=[`fc-scroller`];return t&&(n?i.push(`fc-scroller-liquid-absolute`):i.push(`fc-scroller-liquid`)),Q(`div`,{ref:this.handleEl,className:i.join(` `),style:{overflowX:e.overflowX,overflowY:e.overflowY,left:r&&-(e.overcomeLeft||0)||``,right:r&&-(e.overcomeRight||0)||``,bottom:r&&-(e.overcomeBottom||0)||``,marginLeft:!r&&-(e.overcomeLeft||0)||``,marginRight:!r&&-(e.overcomeRight||0)||``,marginBottom:!r&&-(e.overcomeBottom||0)||``,maxHeight:e.maxHeight||``}},e.children)}needsXScrolling(){if(sC.test(this.props.overflowX))return!1;let{el:e}=this,t=this.el.getBoundingClientRect().width-this.getYScrollbarWidth(),{children:n}=e;for(let e=0;e<n.length;e+=1)if(n[e].getBoundingClientRect().width>t)return!0;return!1}needsYScrolling(){if(sC.test(this.props.overflowY))return!1;let{el:e}=this,t=this.el.getBoundingClientRect().height-this.getXScrollbarWidth(),{children:n}=e;for(let e=0;e<n.length;e+=1)if(n[e].getBoundingClientRect().height>t)return!0;return!1}getXScrollbarWidth(){return sC.test(this.props.overflowX)?0:this.el.offsetHeight-this.el.clientHeight}getYScrollbarWidth(){return sC.test(this.props.overflowY)?0:this.el.offsetWidth-this.el.clientWidth}},lC=class{constructor(e){this.masterCallback=e,this.currentMap={},this.depths={},this.callbackMap={},this.handleValue=(e,t)=>{let{depths:n,currentMap:r}=this,i=!1,a=!1;e===null?(--n[t],n[t]||(delete r[t],delete this.callbackMap[t],i=!0)):(i=t in r,r[t]=e,n[t]=(n[t]||0)+1,a=!0),this.masterCallback&&(i&&this.masterCallback(null,String(t)),a&&this.masterCallback(e,String(t)))}}createRef(e){let t=this.callbackMap[e];return t||=this.callbackMap[e]=t=>{this.handleValue(t,String(e))},t}collect(e,t,n){return rb(this.currentMap,e,t,n)}getAll(){return Xy(this.currentMap)}};function uC(e){let t=nv(e,`.fc-scrollgrid-shrink`),n=0;for(let e of t)n=Math.max(n,Cv(e));return Math.ceil(n)}function dC(e,t){return e.liquid&&t.liquid}function fC(e,t){return t.maxHeight!=null||dC(e,t)}function pC(e,t,n,r){let{expandRows:i}=n;return typeof t.content==`function`?t.content(n):Q(`table`,{role:`presentation`,className:[t.tableClassName,e.syncRowHeights?`fc-scrollgrid-sync-table`:``].join(` `),style:{minWidth:n.tableMinWidth,width:n.clientWidth,height:i?n.clientHeight:``}},n.tableColGroupNode,Q(r?`thead`:`tbody`,{role:`presentation`},typeof t.rowContent==`function`?t.rowContent(n):t.rowContent))}function mC(e,t){return Fv(e,t,Zy)}function hC(e,t){let n=[];for(let r of e){let e=r.span||1;for(let i=0;i<e;i+=1)n.push(Q(`col`,{style:{width:r.width===`shrink`?gC(t):r.width||``,minWidth:r.minWidth||``}}))}return Q(`colgroup`,{},...n)}function gC(e){return e??4}function _C(e){for(let t of e)if(t.width===`shrink`)return!0;return!1}function vC(e,t){let n=[`fc-scrollgrid`,t.theme.getClass(`table`)];return e&&n.push(`fc-scrollgrid-liquid`),n}function yC(e,t){let n=[`fc-scrollgrid-section`,`fc-scrollgrid-section-${e.type}`,e.className];return t&&e.liquid&&e.maxHeight==null&&n.push(`fc-scrollgrid-section-liquid`),e.isSticky&&n.push(`fc-scrollgrid-section-sticky`),n}function bC(e){return Q(`div`,{className:`fc-scrollgrid-sticky-shim`,style:{width:e.clientWidth,minWidth:e.tableMinWidth}})}function xC(e){let{stickyHeaderDates:t}=e;return(t==null||t===`auto`)&&(t=e.height===`auto`||e.viewHeight===`auto`),t}function SC(e){let{stickyFooterScrollbar:t}=e;return(t==null||t===`auto`)&&(t=e.height===`auto`||e.viewHeight===`auto`),t}var CC=class extends vb{constructor(){super(...arguments),this.processCols=dy(e=>e,mC),this.renderMicroColGroup=dy(hC),this.scrollerRefs=new lC,this.scrollerElRefs=new lC(this._handleScrollerEl.bind(this)),this.state={shrinkWidth:null,forceYScrollbars:!1,scrollerClientWidths:{},scrollerClientHeights:{}},this.handleSizing=()=>{this.safeSetState(Object.assign({shrinkWidth:this.computeShrinkWidth()},this.computeScrollerDims()))}}render(){let{props:e,state:t,context:n}=this,r=e.sections||[],i=this.processCols(e.cols),a=this.renderMicroColGroup(i,t.shrinkWidth),o=vC(e.liquid,n);e.collapsibleWidth&&o.push(`fc-scrollgrid-collapsible`);let s=r.length,c=0,l,u=[],d=[],f=[];for(;c<s&&(l=r[c]).type===`header`;)u.push(this.renderSection(l,a,!0)),c+=1;for(;c<s&&(l=r[c]).type===`body`;)d.push(this.renderSection(l,a,!1)),c+=1;for(;c<s&&(l=r[c]).type===`footer`;)f.push(this.renderSection(l,a,!0)),c+=1;let p=!yS(),m={role:`rowgroup`};return Q(`table`,{role:`grid`,className:o.join(` `),style:{height:e.height}},!(p||!u.length)&&Q(`thead`,m,...u),!(p||!d.length)&&Q(`tbody`,m,...d),!(p||!f.length)&&Q(`tfoot`,m,...f),p&&Q(`tbody`,m,...u,...d,...f))}renderSection(e,t,n){return`outerContent`in e?Q(Ag,{key:e.key},e.outerContent):Q(`tr`,{key:e.key,role:`presentation`,className:yC(e,this.props.liquid).join(` `)},this.renderChunkTd(e,t,e.chunk,n))}renderChunkTd(e,t,n,r){if(`outerContent`in n)return n.outerContent;let{props:i}=this,{forceYScrollbars:a,scrollerClientWidths:o,scrollerClientHeights:s}=this.state,c=fC(i,e),l=dC(i,e),u=i.liquid?a?`scroll`:c?`auto`:`hidden`:`visible`,d=e.key,f=pC(e,n,{tableColGroupNode:t,tableMinWidth:``,clientWidth:!i.collapsibleWidth&&o[d]!==void 0?o[d]:null,clientHeight:s[d]===void 0?null:s[d],expandRows:e.expandRows,syncRowHeights:!1,rowSyncHeights:[],reportRowHeightChange:()=>{}},r);return Q(r?`th`:`td`,{ref:n.elRef,role:`presentation`},Q(`div`,{className:`fc-scroller-harness${l?` fc-scroller-harness-liquid`:``}`},Q(cC,{ref:this.scrollerRefs.createRef(d),elRef:this.scrollerElRefs.createRef(d),overflowY:u,overflowX:i.liquid?`hidden`:`visible`,maxHeight:e.maxHeight,liquid:l,liquidIsAbsolute:!0},f)))}_handleScrollerEl(e,t){let n=wC(this.props.sections,t);n&&xb(n.chunk.scrollerElRef,e)}componentDidMount(){this.handleSizing(),this.context.addResizeHandler(this.handleSizing)}componentDidUpdate(){this.handleSizing()}componentWillUnmount(){this.context.removeResizeHandler(this.handleSizing)}computeShrinkWidth(){return _C(this.props.cols)?uC(this.scrollerElRefs.getAll()):0}computeScrollerDims(){let e=FS(),{scrollerRefs:t,scrollerElRefs:n}=this,r=!1,i={},a={};for(let e in t.currentMap){let n=t.currentMap[e];if(n&&n.needsYScrolling()){r=!0;break}}for(let t of this.props.sections){let o=t.key,s=n.currentMap[o];if(s){let t=s.parentNode;i[o]=Math.floor(t.getBoundingClientRect().width-(r?e.y:0)),a[o]=Math.floor(t.getBoundingClientRect().height)}}return{forceYScrollbars:r,scrollerClientWidths:i,scrollerClientHeights:a}}};CC.addStateEquality({scrollerClientWidths:Zy,scrollerClientHeights:Zy});function wC(e,t){for(let n of e)if(n.key===t)return n;return null}var TC=class extends vb{constructor(){super(...arguments),this.buildPublicEvent=dy((e,t,n)=>new Wx(e,t,n)),this.handleEl=e=>{this.el=e,xb(this.props.elRef,e),e&&Jx(e,this.props.seg)}}render(){let{props:e,context:t}=this,{options:n}=t,{seg:r}=e,{eventRange:i}=r,{ui:a}=i,o={event:this.buildPublicEvent(t,i.def,i.instance),view:t.viewApi,timeText:e.timeText,textColor:a.textColor,backgroundColor:a.backgroundColor,borderColor:a.borderColor,isDraggable:!e.disableDragging&&eS(r,t),isStartResizable:!e.disableResizing&&tS(r,t),isEndResizable:!e.disableResizing&&nS(r),isMirror:!!(e.isDragging||e.isResizing||e.isDateSelecting),isStart:!!r.isStart,isEnd:!!r.isEnd,isPast:!!e.isPast,isFuture:!!e.isFuture,isToday:!!e.isToday,isSelected:!!e.isSelected,isDragging:!!e.isDragging,isResizing:!!e.isResizing};return Q(Db,{elRef:this.handleEl,elTag:e.elTag,elAttrs:e.elAttrs,elClasses:[...aS(o),...r.eventRange.ui.classNames,...e.elClasses||[]],elStyle:e.elStyle,renderProps:o,generatorName:`eventContent`,customGenerator:n.eventContent,defaultGenerator:e.defaultGenerator,classNameGenerator:n.eventClassNames,didMount:n.eventDidMount,willUnmount:n.eventWillUnmount},e.children)}componentDidUpdate(e){this.el&&this.props.seg!==e.seg&&Jx(this.el,this.props.seg)}},EC=class extends vb{render(){let{props:e,context:t}=this,{options:n}=t,{seg:r}=e,{ui:i}=r.eventRange,a=rS(r,n.eventTimeFormat||e.defaultTimeFormat,t,e.defaultDisplayEventTime,e.defaultDisplayEventEnd);return Q(TC,Object.assign({},e,{elTag:`a`,elStyle:{borderColor:i.borderColor,backgroundColor:i.backgroundColor},elAttrs:sS(r,t),defaultGenerator:DC,timeText:a}),(e,t)=>Q(Ag,null,Q(e,{elTag:`div`,elClasses:[`fc-event-main`],elStyle:{color:t.textColor}}),!!t.isStartResizable&&Q(`div`,{className:`fc-event-resizer fc-event-resizer-start`}),!!t.isEndResizable&&Q(`div`,{className:`fc-event-resizer fc-event-resizer-end`})))}};EC.addPropsEquality({seg:Zy});function DC(e){return Q(`div`,{className:`fc-event-main-frame`},e.timeText&&Q(`div`,{className:`fc-event-time`},e.timeText),Q(`div`,{className:`fc-event-title-container`},Q(`div`,{className:`fc-event-title fc-sticky`},e.event.title||Q(Ag,null,`\xA0`))))}var OC=Py({day:`numeric`}),kC=class extends vb{constructor(){super(...arguments),this.refineRenderProps=fy(jC)}render(){let{props:e,context:t}=this,{options:n}=t,r=this.refineRenderProps({date:e.date,dateProfile:e.dateProfile,todayRange:e.todayRange,isMonthStart:e.isMonthStart||!1,showDayNumber:e.showDayNumber,extraRenderProps:e.extraRenderProps,viewApi:t.viewApi,dateEnv:t.dateEnv,monthStartFormat:n.monthStartFormat});return Q(Db,{elRef:e.elRef,elTag:e.elTag,elAttrs:Object.assign(Object.assign({},e.elAttrs),r.isDisabled?{}:{"data-date":cy(e.date)}),elClasses:[...AS(r,t.theme),...e.elClasses||[]],elStyle:e.elStyle,renderProps:r,generatorName:`dayCellContent`,customGenerator:n.dayCellContent,defaultGenerator:e.defaultGenerator,classNameGenerator:r.isDisabled?void 0:n.dayCellClassNames,didMount:n.dayCellDidMount,willUnmount:n.dayCellWillUnmount},e.children)}};function AC(e){return!!(e.dayCellContent||Cb(`dayCellContent`,e))}function jC(e){let{date:t,dateEnv:n,dateProfile:r,isMonthStart:i}=e,a=kS(t,e.todayRange,null,r),o=e.showDayNumber?n.format(t,i?e.monthStartFormat:OC):``;return Object.assign(Object.assign(Object.assign({date:n.toDate(t),view:e.viewApi},a),{isMonthStart:i,dayNumberText:o}),e.extraRenderProps)}var MC=class extends vb{render(){let{props:e}=this,{seg:t}=e;return Q(TC,{elTag:`div`,elClasses:[`fc-bg-event`],elStyle:{backgroundColor:t.eventRange.ui.backgroundColor},defaultGenerator:NC,seg:t,timeText:``,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:!1,isPast:e.isPast,isFuture:e.isFuture,isToday:e.isToday,disableDragging:!0,disableResizing:!0})}};function NC(e){let{title:t}=e.event;return t&&Q(`div`,{className:`fc-event-title`},e.event.title)}function PC(e){return Q(`div`,{className:`fc-${e}`})}var FC=e=>Q(hb.Consumer,null,t=>{let{dateEnv:n,options:r}=t,{date:i}=e,a=r.weekNumberFormat||e.defaultFormat,o={num:n.computeWeekNumber(i),text:n.format(i,a),date:i};return Q(Db,{elRef:e.elRef,elTag:e.elTag,elAttrs:e.elAttrs,elClasses:e.elClasses,elStyle:e.elStyle,renderProps:o,generatorName:`weekNumberContent`,customGenerator:r.weekNumberContent,defaultGenerator:IC,classNameGenerator:r.weekNumberClassNames,didMount:r.weekNumberDidMount,willUnmount:r.weekNumberWillUnmount},e.children)});function IC(e){return e.text}var LC=10,RC=class extends vb{constructor(){super(...arguments),this.state={titleId:cv()},this.handleRootEl=e=>{this.rootEl=e,this.props.elRef&&xb(this.props.elRef,e)},this.handleDocumentMouseDown=e=>{let t=ov(e);this.rootEl.contains(t)||this.handleCloseClick()},this.handleDocumentKeyDown=e=>{e.key===`Escape`&&this.handleCloseClick()},this.handleCloseClick=()=>{let{onClose:e}=this.props;e&&e()}}render(){let{theme:e,options:t}=this.context,{props:n,state:r}=this,i=[`fc-popover`,e.getClass(`popover`)].concat(n.extraClassNames||[]);return A_(Q(`div`,Object.assign({},n.extraAttrs,{id:n.id,className:i.join(` `),"aria-labelledby":r.titleId,ref:this.handleRootEl}),Q(`div`,{className:`fc-popover-header `+e.getClass(`popoverHeader`)},Q(`span`,{className:`fc-popover-title`,id:r.titleId},n.title),Q(`span`,{className:`fc-popover-close `+e.getIconClass(`close`),title:t.closeHint,onClick:this.handleCloseClick})),Q(`div`,{className:`fc-popover-body `+e.getClass(`popoverContent`)},n.children)),n.parentEl)}componentDidMount(){document.addEventListener(`mousedown`,this.handleDocumentMouseDown),document.addEventListener(`keydown`,this.handleDocumentKeyDown),this.updateSize()}componentWillUnmount(){document.removeEventListener(`mousedown`,this.handleDocumentMouseDown),document.removeEventListener(`keydown`,this.handleDocumentKeyDown)}updateSize(){let{isRtl:e}=this.context,{alignmentEl:t,alignGridTop:n}=this.props,{rootEl:r}=this,i=RS(t);if(i){let a=r.getBoundingClientRect(),o=n?ev(t,`.fc-scrollgrid`).getBoundingClientRect().top:i.top,s=e?i.right-a.width:i.left;o=Math.max(o,LC),s=Math.min(s,document.documentElement.clientWidth-LC-a.width),s=Math.max(s,LC);let c=r.offsetParent.getBoundingClientRect();iv(r,{top:o-c.top,left:s-c.left})}}},zC=class extends HS{constructor(){super(...arguments),this.handleRootEl=e=>{this.rootEl=e,e?this.context.registerInteractiveComponent(this,{el:e,useEventCenter:!1}):this.context.unregisterInteractiveComponent(this)}}render(){let{options:e,dateEnv:t}=this.context,{props:n}=this,{startDate:r,todayRange:i,dateProfile:a}=n,o=t.format(r,e.dayPopoverFormat);return Q(kC,{elRef:this.handleRootEl,date:r,dateProfile:a,todayRange:i},(t,r,i)=>Q(RC,{elRef:i.ref,id:n.id,title:o,extraClassNames:[`fc-more-popover`].concat(i.className||[]),extraAttrs:i,parentEl:n.parentEl,alignmentEl:n.alignmentEl,alignGridTop:n.alignGridTop,onClose:n.onClose},AC(e)&&Q(t,{elTag:`div`,elClasses:[`fc-more-popover-misc`]}),n.children))}queryHit(e,t,n,r){let{rootEl:i,props:a}=this;return e>=0&&e<n&&t>=0&&t<r?{dateProfile:a.dateProfile,dateSpan:Object.assign({allDay:!a.forceTimed,range:{start:a.startDate,end:a.endDate}},a.extraDateSpan),dayEl:i,rect:{left:0,top:0,right:n,bottom:r},layer:1}:null}},BC=class extends vb{constructor(){super(...arguments),this.state={isPopoverOpen:!1,popoverId:cv()},this.handleLinkEl=e=>{this.linkEl=e,this.props.elRef&&xb(this.props.elRef,e)},this.handleClick=e=>{let{props:t,context:n}=this,{moreLinkClick:r}=n.options,i=HC(t).start;function a(e){let{def:t,instance:r,range:i}=e.eventRange;return{event:new Wx(n,t,r),start:n.dateEnv.toDate(i.start),end:n.dateEnv.toDate(i.end),isStart:e.isStart,isEnd:e.isEnd}}typeof r==`function`&&(r=r({date:i,allDay:!!t.allDayDate,allSegs:t.allSegs.map(a),hiddenSegs:t.hiddenSegs.map(a),jsEvent:e,view:n.viewApi})),!r||r===`popover`?this.setState({isPopoverOpen:!0}):typeof r==`string`&&n.calendarApi.zoomTo(i,r)},this.handlePopoverClose=()=>{this.setState({isPopoverOpen:!1})}}render(){let{props:e,state:t}=this;return Q(hb.Consumer,null,n=>{let{viewApi:r,options:i,calendarApi:a}=n,{moreLinkText:o}=i,{moreCnt:s}=e,c=HC(e),l=typeof o==`function`?o.call(a,s):`+${s} ${o}`,u=xv(i.moreLinkHint,[s],l),d={num:s,shortText:`+${s}`,text:l,view:r};return Q(Ag,null,!!e.moreCnt&&Q(Db,{elTag:e.elTag||`a`,elRef:this.handleLinkEl,elClasses:[...e.elClasses||[],`fc-more-link`],elStyle:e.elStyle,elAttrs:Object.assign(Object.assign(Object.assign({},e.elAttrs),fv(this.handleClick)),{title:u,"aria-expanded":t.isPopoverOpen,"aria-controls":t.isPopoverOpen?t.popoverId:``}),renderProps:d,generatorName:`moreLinkContent`,customGenerator:i.moreLinkContent,defaultGenerator:e.defaultGenerator||VC,classNameGenerator:i.moreLinkClassNames,didMount:i.moreLinkDidMount,willUnmount:i.moreLinkWillUnmount},e.children),t.isPopoverOpen&&Q(zC,{id:t.popoverId,startDate:c.start,endDate:c.end,dateProfile:e.dateProfile,todayRange:e.todayRange,extraDateSpan:e.extraDateSpan,parentEl:this.parentEl,alignmentEl:e.alignmentElRef?e.alignmentElRef.current:this.linkEl,alignGridTop:e.alignGridTop,forceTimed:e.forceTimed,onClose:this.handlePopoverClose},e.popoverContent()))})}componentDidMount(){this.updateParentEl()}componentDidUpdate(){this.updateParentEl()}updateParentEl(){this.linkEl&&(this.parentEl=ev(this.linkEl,`.fc-view-harness`))}};function VC(e){return e.text}function HC(e){if(e.allDayDate)return{start:e.allDayDate,end:Rv(e.allDayDate,1)};let{hiddenSegs:t}=e;return{start:UC(t),end:GC(t)}}function UC(e){return e.reduce(WC).eventRange.range.start}function WC(e,t){return e.eventRange.range.start<t.eventRange.range.start?e:t}function GC(e){return e.reduce(KC).eventRange.range.end}function KC(e,t){return e.eventRange.range.end>t.eventRange.range.end?e:t}var qC=class{constructor(){this.handlers=[]}set(e){this.currentValue=e;for(let t of this.handlers)t(e)}subscribe(e){this.handlers.push(e),this.currentValue!==void 0&&e(this.currentValue)}},JC=class extends qC{constructor(){super(...arguments),this.map=new Map}handle(e){let{map:t}=this,n=!1;e.isActive?(t.set(e.id,e),n=!0):t.has(e.id)&&(t.delete(e.id),n=!0),n&&this.set(t)}},YC=[],XC={code:`en`,week:{dow:0,doy:4},direction:`ltr`,buttonText:{prev:`prev`,next:`next`,prevYear:`prev year`,nextYear:`next year`,year:`year`,today:`today`,month:`month`,week:`week`,day:`day`,list:`list`},weekText:`W`,weekTextLong:`Week`,closeHint:`Close`,timeHint:`Time`,eventHint:`Event`,allDayText:`all-day`,moreLinkText:`more`,noEventsText:`No events to display`},ZC=Object.assign(Object.assign({},XC),{buttonHints:{prev:`Previous $0`,next:`Next $0`,today(e,t){return t===`day`?`Today`:`This ${e}`}},viewHint:`$0 view`,navLinkHint:`Go to $0`,moreLinkHint(e){return`Show ${e} more event${e===1?``:`s`}`}});function QC(e){let t=e.length>0?e[0].code:`en`,n=YC.concat(e),r={en:ZC};for(let e of n)r[e.code]=e;return{map:r,defaultCode:t}}function $C(e,t){return typeof e==`object`&&!Array.isArray(e)?nw(e.code,[e.code],e):ew(e,t)}function ew(e,t){let n=[].concat(e||[]);return nw(e,n,tw(n,t)||ZC)}function tw(e,t){for(let n=0;n<e.length;n+=1){let r=e[n].toLocaleLowerCase().split(`-`);for(let e=r.length;e>0;--e){let n=r.slice(0,e).join(`-`);if(t[n])return t[n]}}return null}function nw(e,t,n){let r=Ky([XC,n],[`buttonText`]);delete r.code;let{week:i}=r;return delete r.week,{codeArg:e,codes:t,week:i,simpleNumberFormat:new Intl.NumberFormat(e),options:r}}function rw(e){return{id:hv(),name:e.name,premiumReleaseDate:e.premiumReleaseDate?new Date(e.premiumReleaseDate):void 0,deps:e.deps||[],reducers:e.reducers||[],isLoadingFuncs:e.isLoadingFuncs||[],contextInit:[].concat(e.contextInit||[]),eventRefiners:e.eventRefiners||{},eventDefMemberAdders:e.eventDefMemberAdders||[],eventSourceRefiners:e.eventSourceRefiners||{},isDraggableTransformers:e.isDraggableTransformers||[],eventDragMutationMassagers:e.eventDragMutationMassagers||[],eventDefMutationAppliers:e.eventDefMutationAppliers||[],dateSelectionTransformers:e.dateSelectionTransformers||[],datePointTransforms:e.datePointTransforms||[],dateSpanTransforms:e.dateSpanTransforms||[],views:e.views||{},viewPropsTransformers:e.viewPropsTransformers||[],isPropsValid:e.isPropsValid||null,externalDefTransforms:e.externalDefTransforms||[],viewContainerAppends:e.viewContainerAppends||[],eventDropTransformers:e.eventDropTransformers||[],componentInteractions:e.componentInteractions||[],calendarInteractions:e.calendarInteractions||[],themeClasses:e.themeClasses||{},eventSourceDefs:e.eventSourceDefs||[],cmdFormatter:e.cmdFormatter,recurringTypes:e.recurringTypes||[],namedTimeZonedImpl:e.namedTimeZonedImpl,initialView:e.initialView||``,elementDraggingImpl:e.elementDraggingImpl,optionChangeHandlers:e.optionChangeHandlers||{},scrollGridImpl:e.scrollGridImpl||null,listenerRefiners:e.listenerRefiners||{},optionRefiners:e.optionRefiners||{},propSetHandlers:e.propSetHandlers||{}}}function iw(e,t){let n={},r={premiumReleaseDate:void 0,reducers:[],isLoadingFuncs:[],contextInit:[],eventRefiners:{},eventDefMemberAdders:[],eventSourceRefiners:{},isDraggableTransformers:[],eventDragMutationMassagers:[],eventDefMutationAppliers:[],dateSelectionTransformers:[],datePointTransforms:[],dateSpanTransforms:[],views:{},viewPropsTransformers:[],isPropsValid:null,externalDefTransforms:[],viewContainerAppends:[],eventDropTransformers:[],componentInteractions:[],calendarInteractions:[],themeClasses:{},eventSourceDefs:[],cmdFormatter:null,recurringTypes:[],namedTimeZonedImpl:null,initialView:``,elementDraggingImpl:null,optionChangeHandlers:{},scrollGridImpl:null,listenerRefiners:{},optionRefiners:{},propSetHandlers:{}};function i(e){for(let t of e){let e=t.name,a=n[e];a===void 0?(n[e]=t.id,i(t.deps),r=ow(r,t)):a!==t.id&&console.warn(`Duplicate plugin '${e}'`)}}return e&&i(e),i(t),r}function aw(){let e=[],t=[],n;return(r,i)=>((!n||!Fv(r,e)||!Fv(i,t))&&(n=iw(r,i)),e=r,t=i,n)}function ow(e,t){return{premiumReleaseDate:sw(e.premiumReleaseDate,t.premiumReleaseDate),reducers:e.reducers.concat(t.reducers),isLoadingFuncs:e.isLoadingFuncs.concat(t.isLoadingFuncs),contextInit:e.contextInit.concat(t.contextInit),eventRefiners:Object.assign(Object.assign({},e.eventRefiners),t.eventRefiners),eventDefMemberAdders:e.eventDefMemberAdders.concat(t.eventDefMemberAdders),eventSourceRefiners:Object.assign(Object.assign({},e.eventSourceRefiners),t.eventSourceRefiners),isDraggableTransformers:e.isDraggableTransformers.concat(t.isDraggableTransformers),eventDragMutationMassagers:e.eventDragMutationMassagers.concat(t.eventDragMutationMassagers),eventDefMutationAppliers:e.eventDefMutationAppliers.concat(t.eventDefMutationAppliers),dateSelectionTransformers:e.dateSelectionTransformers.concat(t.dateSelectionTransformers),datePointTransforms:e.datePointTransforms.concat(t.datePointTransforms),dateSpanTransforms:e.dateSpanTransforms.concat(t.dateSpanTransforms),views:Object.assign(Object.assign({},e.views),t.views),viewPropsTransformers:e.viewPropsTransformers.concat(t.viewPropsTransformers),isPropsValid:t.isPropsValid||e.isPropsValid,externalDefTransforms:e.externalDefTransforms.concat(t.externalDefTransforms),viewContainerAppends:e.viewContainerAppends.concat(t.viewContainerAppends),eventDropTransformers:e.eventDropTransformers.concat(t.eventDropTransformers),calendarInteractions:e.calendarInteractions.concat(t.calendarInteractions),componentInteractions:e.componentInteractions.concat(t.componentInteractions),themeClasses:Object.assign(Object.assign({},e.themeClasses),t.themeClasses),eventSourceDefs:e.eventSourceDefs.concat(t.eventSourceDefs),cmdFormatter:t.cmdFormatter||e.cmdFormatter,recurringTypes:e.recurringTypes.concat(t.recurringTypes),namedTimeZonedImpl:t.namedTimeZonedImpl||e.namedTimeZonedImpl,initialView:e.initialView||t.initialView,elementDraggingImpl:e.elementDraggingImpl||t.elementDraggingImpl,optionChangeHandlers:Object.assign(Object.assign({},e.optionChangeHandlers),t.optionChangeHandlers),scrollGridImpl:t.scrollGridImpl||e.scrollGridImpl,listenerRefiners:Object.assign(Object.assign({},e.listenerRefiners),t.listenerRefiners),optionRefiners:Object.assign(Object.assign({},e.optionRefiners),t.optionRefiners),propSetHandlers:Object.assign(Object.assign({},e.propSetHandlers),t.propSetHandlers)}}function sw(e,t){return e===void 0?t:t===void 0?e:new Date(Math.max(e.valueOf(),t.valueOf()))}var cw=class extends ub{};cw.prototype.classes={root:`fc-theme-standard`,tableCellShaded:`fc-cell-shaded`,buttonGroup:`fc-button-group`,button:`fc-button fc-button-primary`,buttonActive:`fc-button-active`},cw.prototype.baseIconClass=`fc-icon`,cw.prototype.iconClasses={close:`fc-icon-x`,prev:`fc-icon-chevron-left`,next:`fc-icon-chevron-right`,prevYear:`fc-icon-chevrons-left`,nextYear:`fc-icon-chevrons-right`},cw.prototype.rtlIconClasses={prev:`fc-icon-chevron-right`,next:`fc-icon-chevron-left`,prevYear:`fc-icon-chevrons-right`,nextYear:`fc-icon-chevrons-left`},cw.prototype.iconOverrideOption=`buttonIcons`,cw.prototype.iconOverrideCustomButtonOption=`icon`,cw.prototype.iconOverridePrefix=`fc-icon-`;function lw(e,t){let n={},r;for(r in e)uw(r,n,e,t);for(r in t)uw(r,n,e,t);return n}function uw(e,t,n,r){if(t[e])return t[e];let i=dw(e,t,n,r);return i&&(t[e]=i),i}function dw(e,t,n,r){let i=n[e],a=r[e],o=e=>i&&i[e]!==null?i[e]:a&&a[e]!==null?a[e]:null,s=o(`component`),c=o(`superType`),l=null;if(c){if(c===e)throw Error(`Can't have a custom view type that references itself`);l=uw(c,t,n,r)}return!s&&l&&(s=l.component),s?{type:e,component:s,defaults:Object.assign(Object.assign({},l?l.defaults:{}),i?i.rawOptions:{}),overrides:Object.assign(Object.assign({},l?l.overrides:{}),a?a.rawOptions:{})}:null}function fw(e){return Jy(e,pw)}function pw(e){let t=typeof e==`function`?{component:e}:e,{component:n}=t;return t.content?n=mw(t):n&&!(n.prototype instanceof vb)&&(n=mw(Object.assign(Object.assign({},t),{content:n}))),{superType:t.type,component:n,rawOptions:t}}function mw(e){return t=>Q(hb.Consumer,null,n=>Q(Db,{elTag:`div`,elClasses:jb(n.viewSpec),renderProps:Object.assign(Object.assign({},t),{nextDayThreshold:n.options.nextDayThreshold}),generatorName:void 0,customGenerator:e.content,classNameGenerator:e.classNames,didMount:e.didMount,willUnmount:e.willUnmount}))}function hw(e,t,n,r){let i=fw(e),a=fw(t.views);return Jy(lw(i,a),e=>gw(e,a,t,n,r))}function gw(e,t,n,r,i){let a=e.overrides.duration||e.defaults.duration||r.duration||n.duration,o=null,s=``,c=``,l={};if(a&&(o=vw(a),o)){let e=Pv(o);s=e.unit,e.value===1&&(c=s,l=t[s]?t[s].rawOptions:{})}let u=t=>{let n=t.buttonText||{},r=e.defaults.buttonTextKey;return r!=null&&n[r]!=null?n[r]:n[e.type]==null?n[c]==null?null:n[c]:n[e.type]},d=t=>{let n=t.buttonHints||{},r=e.defaults.buttonTextKey;return r!=null&&n[r]!=null?n[r]:n[e.type]==null?n[c]==null?null:n[c]:n[e.type]};return{type:e.type,component:e.component,duration:o,durationUnit:s,singleUnit:c,optionDefaults:e.defaults,optionOverrides:Object.assign(Object.assign({},l),e.overrides),buttonTextOverride:u(r)||u(n)||e.overrides.buttonText,buttonTextDefault:u(i)||e.defaults.buttonText||u(Iy)||e.type,buttonTitleOverride:d(r)||d(n)||e.overrides.buttonHint,buttonTitleDefault:d(i)||e.defaults.buttonHint||d(Iy)}}var _w={};function vw(e){let t=JSON.stringify(e),n=_w[t];return n===void 0&&(n=Tv(e),_w[t]=n),n}function yw(e,t){return t.type===`CHANGE_VIEW_TYPE`&&(e=t.viewType),e}function bw(e,t){switch(t.type){case`CHANGE_DATE`:return t.dateMarker;default:return e}}function xw(e,t,n){let r=e.initialDate;return r==null?n.getDateMarker():t.createMarker(r)}function Sw(e,t){switch(t.type){case`SET_OPTION`:return Object.assign(Object.assign({},e),{[t.optionName]:t.rawOptionValue});default:return e}}function Cw(e,t,n,r){let i;switch(t.type){case`CHANGE_VIEW_TYPE`:return r.build(t.dateMarker||n);case`CHANGE_DATE`:return r.build(t.dateMarker);case`PREV`:if(i=r.buildPrev(e,n),i.isValid)return i;break;case`NEXT`:if(i=r.buildNext(e,n),i.isValid)return i}return e}function ww(e,t,n){let r=t?t.activeRange:null;return Ow({},Iw(e,n),r,n)}function Tw(e,t,n,r){let i=n?n.activeRange:null;switch(t.type){case`ADD_EVENT_SOURCES`:return Ow(e,t.sources,i,r);case`REMOVE_EVENT_SOURCE`:return kw(e,t.sourceId);case`PREV`:case`NEXT`:case`CHANGE_DATE`:case`CHANGE_VIEW_TYPE`:return n?Aw(e,i,r):e;case`FETCH_EVENT_SOURCES`:return Mw(e,t.sourceIds?Yy(t.sourceIds):Fw(e,r),i,t.isRefetch||!1,r);case`RECEIVE_EVENTS`:case`RECEIVE_EVENT_ERROR`:return Pw(e,t.sourceId,t.fetchId,t.fetchRange);case`REMOVE_ALL_EVENT_SOURCES`:return{};default:return e}}function Ew(e,t,n){let r=t?t.activeRange:null;return Mw(e,Fw(e,n),r,!0,n)}function Dw(e){for(let t in e)if(e[t].isFetching)return!0;return!1}function Ow(e,t,n,r){let i={};for(let e of t)i[e.sourceId]=e;return n&&(i=Aw(i,n,r)),Object.assign(Object.assign({},e),i)}function kw(e,t){return qy(e,e=>e.sourceId!==t)}function Aw(e,t,n){return Mw(e,qy(e,e=>jw(e,t,n)),t,!1,n)}function jw(e,t,n){return Lw(e,n)?!n.options.lazyFetching||!e.fetchRange||e.isFetching||t.start<e.fetchRange.start||t.end>e.fetchRange.end:!e.latestFetchId}function Mw(e,t,n,r,i){let a={};for(let o in e){let s=e[o];a[o]=t[o]?Nw(s,n,r,i):s}return a}function Nw(e,t,n,r){let{options:i,calendarApi:a}=r,o=r.pluginHooks.eventSourceDefs[e.sourceDefId],s=hv();return o.fetch({eventSource:e,range:t,isRefetch:n,context:r},n=>{let{rawEvents:o}=n;i.eventSourceSuccess&&(o=i.eventSourceSuccess.call(a,o,n.response)||o),e.success&&(o=e.success.call(a,o,n.response)||o),r.dispatch({type:`RECEIVE_EVENTS`,sourceId:e.sourceId,fetchId:s,fetchRange:t,rawEvents:o})},n=>{let o=!1;i.eventSourceFailure&&(i.eventSourceFailure.call(a,n),o=!0),e.failure&&(e.failure(n),o=!0),o||console.warn(n.message,n),r.dispatch({type:`RECEIVE_EVENT_ERROR`,sourceId:e.sourceId,fetchId:s,fetchRange:t,error:n})}),Object.assign(Object.assign({},e),{isFetching:!0,latestFetchId:s})}function Pw(e,t,n,r){let i=e[t];return i&&n===i.latestFetchId?Object.assign(Object.assign({},e),{[t]:Object.assign(Object.assign({},i),{isFetching:!1,fetchRange:r})}):e}function Fw(e,t){return qy(e,e=>Lw(e,t))}function Iw(e,t){let n=yx(t),r=[].concat(e.eventSources||[]),i=[];e.initialEvents&&r.unshift(e.initialEvents),e.events&&r.unshift(e.events);for(let e of r){let r=vx(e,t,n);r&&i.push(r)}return i}function Lw(e,t){return!t.pluginHooks.eventSourceDefs[e.sourceDefId].ignoreRange}function Rw(e,t){switch(t.type){case`UNSELECT_DATES`:return null;case`SELECT_DATES`:return t.selection;default:return e}}function zw(e,t){switch(t.type){case`UNSELECT_EVENT`:return``;case`SELECT_EVENT`:return t.eventInstanceId;default:return e}}function Bw(e,t){let n;switch(t.type){case`UNSET_EVENT_DRAG`:return null;case`SET_EVENT_DRAG`:return n=t.state,{affectedEvents:n.affectedEvents,mutatedEvents:n.mutatedEvents,isEvent:n.isEvent};default:return e}}function Vw(e,t){let n;switch(t.type){case`UNSET_EVENT_RESIZE`:return null;case`SET_EVENT_RESIZE`:return n=t.state,{affectedEvents:n.affectedEvents,mutatedEvents:n.mutatedEvents,isEvent:n.isEvent};default:return e}}function Hw(e,t,n,r,i){return{header:e.headerToolbar?Uw(e.headerToolbar,e,t,n,r,i):null,footer:e.footerToolbar?Uw(e.footerToolbar,e,t,n,r,i):null}}function Uw(e,t,n,r,i,a){let o={},s=[],c=!1;for(let l in e){let u=e[l],d=Ww(u,t,n,r,i,a);o[l]=d.widgets,s.push(...d.viewsWithButtons),c||=d.hasTitle}return{sectionWidgets:o,viewsWithButtons:s,hasTitle:c}}function Ww(e,t,n,r,i,a){let o=t.direction===`rtl`,s=t.customButtons||{},c=n.buttonText||{},l=t.buttonText||{},u=n.buttonHints||{},d=t.buttonHints||{},f=e?e.split(` `):[],p=[],m=!1;return{widgets:f.map(e=>e.split(`,`).map(e=>{if(e===`title`)return m=!0,{buttonName:e};let n,f,h,g,_,v;if(n=s[e])h=e=>{n.click&&n.click.call(e.target,e,e.target)},(g=r.getCustomButtonIconClass(n))||(g=r.getIconClass(e,o))||(_=n.text),v=n.hint||n.text;else if(f=i[e]){p.push(e),h=()=>{a.changeView(e)},(_=f.buttonTextOverride)||(g=r.getIconClass(e,o))||(_=f.buttonTextDefault);let n=f.buttonTextOverride||f.buttonTextDefault;v=xv(f.buttonTitleOverride||f.buttonTitleDefault||t.viewHint,[n,e],n)}else if(a[e]){if(h=()=>{a[e]()},(_=c[e])||(g=r.getIconClass(e,o))||(_=l[e]),e===`prevYear`||e===`nextYear`){let t=e===`prevYear`?`prev`:`next`;v=xv(u[t]||d[t],[l.year||`year`,`year`],l[e])}else v=t=>xv(u[e]||d[e],[l[t]||t,t],l[e])}return{buttonName:e,buttonClick:h,buttonIcon:g,buttonText:_,buttonHint:v}})),viewsWithButtons:p,hasTitle:m}}var Gw=class{constructor(e,t,n){this.type=e,this.getCurrentData=t,this.dateEnv=n}get calendar(){return this.getCurrentData().calendarApi}get title(){return this.getCurrentData().viewTitle}get activeStart(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.activeRange.start)}get activeEnd(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.activeRange.end)}get currentStart(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.currentRange.start)}get currentEnd(){return this.dateEnv.toDate(this.getCurrentData().dateProfile.currentRange.end)}getOption(e){return this.getCurrentData().options[e]}},Kw=rw({name:`array-event-source`,eventSourceDefs:[{ignoreRange:!0,parseMeta(e){return Array.isArray(e.events)?e.events:null},fetch(e,t){t({rawEvents:e.eventSource.meta})}}]}),qw=rw({name:`func-event-source`,eventSourceDefs:[{parseMeta(e){return typeof e.events==`function`?e.events:null},fetch(e,t,n){let{dateEnv:r}=e.context,i=e.eventSource.meta;hS(i.bind(null,fS(e.range,r)),e=>t({rawEvents:e}),n)}}]}),Jw=rw({name:`json-event-source`,eventSourceRefiners:{method:String,extraParams:$,startParam:String,endParam:String,timeZoneParam:String},eventSourceDefs:[{parseMeta(e){return e.url&&(e.format===`json`||!e.format)?{url:e.url,format:`json`,method:(e.method||`GET`).toUpperCase(),extraParams:e.extraParams,startParam:e.startParam,endParam:e.endParam,timeZoneParam:e.timeZoneParam}:null},fetch(e,t,n){let{meta:r}=e.eventSource,i=Yw(r,e.range,e.context);_S(r.method,r.url,i).then(([e,n])=>{t({rawEvents:e,response:n})},n)}}]});function Yw(e,t,n){let{dateEnv:r,options:i}=n,a,o,s,c,l={};return a=e.startParam,a??=i.startParam,o=e.endParam,o??=i.endParam,s=e.timeZoneParam,s??=i.timeZoneParam,c=typeof e.extraParams==`function`?e.extraParams():e.extraParams||{},Object.assign(l,c),l[a]=r.formatIso(t.start),l[o]=r.formatIso(t.end),r.timeZone!==`local`&&(l[s]=r.timeZone),l}var Xw=rw({name:`simple-recurring-event`,recurringTypes:[{parse(e,t){if(e.daysOfWeek||e.startTime||e.endTime||e.startRecur||e.endRecur){let n={daysOfWeek:e.daysOfWeek||null,startTime:e.startTime||null,endTime:e.endTime||null,startRecur:e.startRecur?t.createMarker(e.startRecur):null,endRecur:e.endRecur?t.createMarker(e.endRecur):null,dateEnv:t},r;return e.duration&&(r=e.duration),!r&&e.startTime&&e.endTime&&(r=kv(e.endTime,e.startTime)),{allDayGuess:!e.startTime&&!e.endTime,duration:r,typeData:n}}return null},expand(e,t,n){let r=Fb(t,{start:e.startRecur,end:e.endRecur});return r?Zw(e.daysOfWeek,e.startTime,e.dateEnv,n,r):[]}}],eventRefiners:{daysOfWeek:$,startTime:Tv,endTime:Tv,duration:Tv,startRecur:$,endRecur:$}});function Zw(e,t,n,r,i){let a=e?Yy(e):null,o=Jv(i.start),s=i.end,c=[];for(t&&(t.milliseconds<0?s=Rv(s,1):t.milliseconds>=864e5&&(o=Rv(o,-1)));o<s;){let e;(!a||a[o.getUTCDay()])&&(e=t?r.add(o,t):o,c.push(r.createMarker(n.toDate(e)))),o=Rv(o,1)}return c}var Qw=rw({name:`change-handler`,optionChangeHandlers:{events(e,t){$w([e],t)},eventSources:$w}});function $w(e,t){let n=Xy(t.getCurrentData().eventSources);if(n.length===1&&e.length===1&&Array.isArray(n[0]._raw)&&Array.isArray(e[0])){t.dispatch({type:`RESET_RAW_EVENTS`,sourceId:n[0].sourceId,rawEvents:e[0]});return}let r=[];for(let t of e){let e=!1;for(let r=0;r<n.length;r+=1)if(n[r]._raw===t){n.splice(r,1),e=!0;break}e||r.push(t)}for(let e of n)t.dispatch({type:`REMOVE_EVENT_SOURCE`,sourceId:e.sourceId});for(let e of r)t.calendarApi.addEventSource(e)}function eT(e,t){t.emitter.trigger(`datesSet`,Object.assign(Object.assign({},fS(e.activeRange,t.dateEnv)),{view:t.viewApi}))}function tT(e,t){let{emitter:n}=t;n.hasHandlers(`eventsSet`)&&n.trigger(`eventsSet`,Kx(e,t))}var nT=[Kw,qw,Jw,Xw,Qw,rw({name:`misc`,isLoadingFuncs:[e=>Dw(e.eventSources)],propSetHandlers:{dateProfile:eT,eventStore:tT}})],rT=class{constructor(e,t){this.runTaskOption=e,this.drainedOption=t,this.queue=[],this.delayedRunner=new Q_(this.drain.bind(this))}request(e,t){this.queue.push(e),this.delayedRunner.request(t)}pause(e){this.delayedRunner.pause(e)}resume(e,t){this.delayedRunner.resume(e,t)}drain(){let{queue:e}=this;for(;e.length;){let t=[],n;for(;n=e.shift();)this.runTask(n),t.push(n);this.drained(t)}}runTask(e){this.runTaskOption&&this.runTaskOption(e)}drained(e){this.drainedOption&&this.drainedOption(e)}};function iT(e,t,n){let r;return r=/^(year|month)$/.test(e.currentRangeUnit)?e.currentRange:e.activeRange,n.formatRange(r.start,r.end,Py(t.titleFormat||aT(e)),{isEndExclusive:e.isRangeAllDay,defaultSeparator:t.titleRangeSeparator})}function aT(e){let{currentRangeUnit:t}=e;if(t===`year`)return{year:`numeric`};if(t===`month`)return{year:`numeric`,month:`long`};let n=qv(e.currentRange.start,e.currentRange.end);return n!==null&&n>1?{year:`numeric`,month:`short`,day:`numeric`}:{year:`numeric`,month:`long`,day:`numeric`}}var oT=class{constructor(){this.resetListeners=new Set}handleInput(e,t){let n=this.dateEnv;if(e!==n&&(typeof t==`function`?this.nowFn=t:n||(this.nowAnchorDate=e.toDate(t?e.createMarker(t):e.createNowMarker()),this.nowAnchorQueried=Date.now()),this.dateEnv=e,n))for(let e of this.resetListeners.values())e()}getDateMarker(){return this.nowAnchorDate?this.dateEnv.timestampToMarker(this.nowAnchorDate.valueOf()+(Date.now()-this.nowAnchorQueried)):this.dateEnv.createMarker(this.nowFn())}addResetListener(e){this.resetListeners.add(e)}removeResetListener(e){this.resetListeners.delete(e)}},sT=class{constructor(e){this.computeCurrentViewData=dy(this._computeCurrentViewData),this.organizeRawLocales=dy(QC),this.buildLocale=dy($C),this.buildPluginHooks=aw(),this.buildDateEnv=dy(cT),this.buildTheme=dy(lT),this.parseToolbars=dy(Hw),this.buildViewSpecs=dy(hw),this.buildDateProfileGenerator=fy(uT),this.buildViewApi=dy(dT),this.buildViewUiProps=fy(mT),this.buildEventUiBySource=dy(fT,Zy),this.buildEventUiBases=dy(pT),this.parseContextBusinessHours=fy(gT),this.buildTitle=dy(iT),this.nowManager=new oT,this.emitter=new Ax,this.actionRunner=new rT(this._handleAction.bind(this),this.updateData.bind(this)),this.currentCalendarOptionsInput={},this.currentCalendarOptionsRefined={},this.currentViewOptionsInput={},this.currentViewOptionsRefined={},this.currentCalendarOptionsRefiners={},this.optionsForRefining=[],this.optionsForHandling=[],this.getCurrentData=()=>this.data,this.dispatch=e=>{this.actionRunner.request(e)},this.props=e,this.actionRunner.pause(),this.nowManager=new oT;let t={},n=this.computeOptionsData(e.optionOverrides,t,e.calendarApi),r=n.calendarOptions.initialView||n.pluginHooks.initialView,i=this.computeCurrentViewData(r,n,e.optionOverrides,t);e.calendarApi.currentDataManager=this,this.emitter.setThisContext(e.calendarApi),this.emitter.setOptions(i.options);let a={nowManager:this.nowManager,dateEnv:n.dateEnv,options:n.calendarOptions,pluginHooks:n.pluginHooks,calendarApi:e.calendarApi,dispatch:this.dispatch,emitter:this.emitter,getCurrentData:this.getCurrentData},o=xw(n.calendarOptions,n.dateEnv,this.nowManager),s=i.dateProfileGenerator.build(o);Lb(s.activeRange,o)||(o=s.currentRange.start);for(let e of n.pluginHooks.contextInit)e(a);let c=ww(n.calendarOptions,s,a),l={dynamicOptionOverrides:t,currentViewType:r,currentDate:o,dateProfile:s,businessHours:this.parseContextBusinessHours(a),eventSources:c,eventUiBases:{},eventStore:ox(),renderableEventStore:ox(),dateSelection:null,eventSelection:``,eventDrag:null,eventResize:null,selectionConfig:this.buildViewUiProps(a).selectionConfig},u=Object.assign(Object.assign({},a),l);for(let e of n.pluginHooks.reducers)Object.assign(l,e(null,null,u));hT(l,a)&&this.emitter.trigger(`loading`,!0),this.state=l,this.updateData(),this.actionRunner.resume()}resetOptions(e,t){let{props:n}=this;t===void 0?n.optionOverrides=e:(n.optionOverrides=Object.assign(Object.assign({},n.optionOverrides||{}),e),this.optionsForRefining.push(...t)),(t===void 0||t.length)&&this.actionRunner.request({type:`NOTHING`})}_handleAction(e){let{props:t,state:n,emitter:r}=this,i=Sw(n.dynamicOptionOverrides,e),a=this.computeOptionsData(t.optionOverrides,i,t.calendarApi),o=yw(n.currentViewType,e),s=this.computeCurrentViewData(o,a,t.optionOverrides,i);t.calendarApi.currentDataManager=this,r.setThisContext(t.calendarApi),r.setOptions(s.options);let c={nowManager:this.nowManager,dateEnv:a.dateEnv,options:a.calendarOptions,pluginHooks:a.pluginHooks,calendarApi:t.calendarApi,dispatch:this.dispatch,emitter:r,getCurrentData:this.getCurrentData},{currentDate:l,dateProfile:u}=n;this.data&&this.data.dateProfileGenerator!==s.dateProfileGenerator&&(u=s.dateProfileGenerator.build(l)),l=bw(l,e),u=Cw(u,e,l,s.dateProfileGenerator),(e.type===`PREV`||e.type===`NEXT`||!Lb(u.currentRange,l))&&(l=u.currentRange.start);let d=Tw(n.eventSources,e,u,c),f=xx(n.eventStore,e,d,u,c),p=Dw(d)&&!s.options.progressiveEventRendering&&n.renderableEventStore||f,{eventUiSingleBase:m,selectionConfig:h}=this.buildViewUiProps(c),g=this.buildEventUiBySource(d),_=this.buildEventUiBases(p.defs,m,g),v={dynamicOptionOverrides:i,currentViewType:o,currentDate:l,dateProfile:u,eventSources:d,eventStore:f,renderableEventStore:p,selectionConfig:h,eventUiBases:_,businessHours:this.parseContextBusinessHours(c),dateSelection:Rw(n.dateSelection,e),eventSelection:zw(n.eventSelection,e),eventDrag:Bw(n.eventDrag,e),eventResize:Vw(n.eventResize,e)},y=Object.assign(Object.assign({},c),v);for(let t of a.pluginHooks.reducers)Object.assign(v,t(n,e,y));let b=hT(n,c),x=hT(v,c);!b&&x?r.trigger(`loading`,!0):b&&!x&&r.trigger(`loading`,!1),this.state=v,t.onAction&&t.onAction(e)}updateData(){let{props:e,state:t}=this,n=this.data,r=this.computeOptionsData(e.optionOverrides,t.dynamicOptionOverrides,e.calendarApi),i=this.computeCurrentViewData(t.currentViewType,r,e.optionOverrides,t.dynamicOptionOverrides),a=this.data=Object.assign(Object.assign(Object.assign({nowManager:this.nowManager,viewTitle:this.buildTitle(t.dateProfile,i.options,r.dateEnv),calendarApi:e.calendarApi,dispatch:this.dispatch,emitter:this.emitter,getCurrentData:this.getCurrentData},r),i),t),o=r.pluginHooks.optionChangeHandlers,s=n&&n.calendarOptions,c=r.calendarOptions;if(s&&s!==c){s.timeZone!==c.timeZone&&(t.eventSources=a.eventSources=Ew(a.eventSources,t.dateProfile,a),t.eventStore=a.eventStore=Dx(a.eventStore,n.dateEnv,a.dateEnv),t.renderableEventStore=a.renderableEventStore=Dx(a.renderableEventStore,n.dateEnv,a.dateEnv));for(let e in o)(this.optionsForHandling.indexOf(e)!==-1||s[e]!==c[e])&&o[e](c[e],a)}this.optionsForHandling=[],e.onData&&e.onData(a)}computeOptionsData(e,t,n){if(!this.optionsForRefining.length&&e===this.stableOptionOverrides&&t===this.stableDynamicOptionOverrides)return this.stableCalendarOptionsData;let{refinedOptions:r,pluginHooks:i,localeDefaults:a,availableLocaleData:o,extra:s}=this.processRawCalendarOptions(e,t);_T(s);let c=this.buildDateEnv(r.timeZone,r.locale,r.weekNumberCalculation,r.firstDay,r.weekText,i,o,r.defaultRangeSeparator),l=this.buildViewSpecs(i.views,this.stableOptionOverrides,this.stableDynamicOptionOverrides,a),u=this.buildTheme(r,i),d=this.parseToolbars(r,this.stableOptionOverrides,u,l,n);return this.stableCalendarOptionsData={calendarOptions:r,pluginHooks:i,dateEnv:c,viewSpecs:l,theme:u,toolbarConfig:d,localeDefaults:a,availableRawLocales:o.map}}processRawCalendarOptions(e,t){let{locales:n,locale:r}=Uy([Iy,e,t]),i=this.organizeRawLocales(n),a=i.map,o=this.buildLocale(r||i.defaultCode,a).options,s=this.buildPluginHooks(e.plugins||[],nT),c=this.currentCalendarOptionsRefiners=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Fy),Ly),Ry),s.listenerRefiners),s.optionRefiners),l={},u=Uy([Iy,o,e,t]),d={},f=this.currentCalendarOptionsInput,p=this.currentCalendarOptionsRefined,m=!1;for(let e in u)this.optionsForRefining.indexOf(e)===-1&&(u[e]===f[e]||zy[e]&&e in f&&zy[e](f[e],u[e]))?d[e]=p[e]:c[e]?(d[e]=c[e](u[e]),m=!0):l[e]=f[e];return m&&(this.currentCalendarOptionsInput=u,this.currentCalendarOptionsRefined=d,this.stableOptionOverrides=e,this.stableDynamicOptionOverrides=t),this.optionsForHandling.push(...this.optionsForRefining),this.optionsForRefining=[],{rawOptions:this.currentCalendarOptionsInput,refinedOptions:this.currentCalendarOptionsRefined,pluginHooks:s,availableLocaleData:i,localeDefaults:o,extra:l}}_computeCurrentViewData(e,t,n,r){let i=t.viewSpecs[e];if(!i)throw Error(`viewType "${e}" is not available. Please make sure you've loaded all neccessary plugins`);let{refinedOptions:a,extra:o}=this.processRawViewOptions(i,t.pluginHooks,t.localeDefaults,n,r);return _T(o),this.nowManager.handleInput(t.dateEnv,a.now),{viewSpec:i,options:a,dateProfileGenerator:this.buildDateProfileGenerator({dateProfileGeneratorClass:i.optionDefaults.dateProfileGeneratorClass,nowManager:this.nowManager,duration:i.duration,durationUnit:i.durationUnit,usesMinMaxTime:i.optionDefaults.usesMinMaxTime,dateEnv:t.dateEnv,calendarApi:this.props.calendarApi,slotMinTime:a.slotMinTime,slotMaxTime:a.slotMaxTime,showNonCurrentDates:a.showNonCurrentDates,dayCount:a.dayCount,dateAlignment:a.dateAlignment,dateIncrement:a.dateIncrement,hiddenDays:a.hiddenDays,weekends:a.weekends,validRangeInput:a.validRange,visibleRangeInput:a.visibleRange,fixedWeekCount:a.fixedWeekCount}),viewApi:this.buildViewApi(e,this.getCurrentData,t.dateEnv)}}processRawViewOptions(e,t,n,r,i){let a=Uy([Iy,e.optionDefaults,n,r,e.optionOverrides,i]),o=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},Fy),Ly),Ry),Hy),t.listenerRefiners),t.optionRefiners),s={},c=this.currentViewOptionsInput,l=this.currentViewOptionsRefined,u=!1,d={};for(let e in a)a[e]===c[e]||zy[e]&&zy[e](a[e],c[e])?s[e]=l[e]:(a[e]===this.currentCalendarOptionsInput[e]||zy[e]&&zy[e](a[e],this.currentCalendarOptionsInput[e])?e in this.currentCalendarOptionsRefined&&(s[e]=this.currentCalendarOptionsRefined[e]):o[e]?s[e]=o[e](a[e]):d[e]=a[e],u=!0);return u&&(this.currentViewOptionsInput=a,this.currentViewOptionsRefined=s),{rawOptions:this.currentViewOptionsInput,refinedOptions:this.currentViewOptionsRefined,extra:d}}};function cT(e,t,n,r,i,a,o,s){let c=$C(t||o.defaultCode,o.map);return new lb({calendarSystem:`gregory`,timeZone:e,namedTimeZoneImpl:a.namedTimeZonedImpl,locale:c,weekNumberCalculation:n,firstDay:r,weekText:i,cmdFormatter:a.cmdFormatter,defaultSeparator:s})}function lT(e,t){return new(t.themeClasses[e.themeSystem]||cw)(e)}function uT(e){return new(e.dateProfileGeneratorClass||Hb)(e)}function dT(e,t,n){return new Gw(e,t,n)}function fT(e){return Jy(e,e=>e.ui)}function pT(e,t,n){let r={"":t};for(let t in e){let i=e[t];i.sourceId&&n[i.sourceId]&&(r[t]=n[i.sourceId])}return r}function mT(e){let{options:t}=e;return{eventUiSingleBase:mx({display:t.eventDisplay,editable:t.editable,startEditable:t.eventStartEditable,durationEditable:t.eventDurationEditable,constraint:t.eventConstraint,overlap:typeof t.eventOverlap==`boolean`?t.eventOverlap:void 0,allow:t.eventAllow,backgroundColor:t.eventBackgroundColor,borderColor:t.eventBorderColor,textColor:t.eventTextColor,color:t.eventColor},e),selectionConfig:mx({constraint:t.selectConstraint,overlap:typeof t.selectOverlap==`boolean`?t.selectOverlap:void 0,allow:t.selectAllow},e)}}function hT(e,t){for(let n of t.pluginHooks.isLoadingFuncs)if(n(e))return!0;return!1}function gT(e){return Px(e.options.businessHours,e)}function _T(e,t){for(let n in e)console.warn(`Unknown option '${n}'`+(t?` for view '${t}'`:``))}var vT=class extends vb{render(){return Q(`div`,{className:`fc-toolbar-chunk`},...this.props.widgetGroups.map(e=>this.renderWidgetGroup(e)))}renderWidgetGroup(e){let{props:t}=this,{theme:n}=this.context,r=[],i=!0;for(let a of e){let{buttonName:e,buttonClick:o,buttonText:s,buttonIcon:c,buttonHint:l}=a;if(e===`title`)i=!1,r.push(Q(`h2`,{className:`fc-toolbar-title`,id:t.titleId},t.title));else{let i=e===t.activeButton,a=!t.isTodayEnabled&&e===`today`||!t.isPrevEnabled&&e===`prev`||!t.isNextEnabled&&e===`next`,u=[`fc-${e}-button`,n.getClass(`button`)];i&&u.push(n.getClass(`buttonActive`)),r.push(Q(`button`,{type:`button`,title:typeof l==`function`?l(t.navUnit):l,disabled:a,"aria-pressed":i,className:u.join(` `),onClick:o},s||(c?Q(`span`,{className:c,role:`img`}):``)))}}return r.length>1?Q(`div`,{className:i&&n.getClass(`buttonGroup`)||``},...r):r[0]}},yT=class extends vb{render(){let{model:e,extraClassName:t}=this.props,n=!1,r,i,a=e.sectionWidgets,o=a.center;return a.left?(n=!0,r=a.left):r=a.start,a.right?(n=!0,i=a.right):i=a.end,Q(`div`,{className:[t||``,`fc-toolbar`,n?`fc-toolbar-ltr`:``].join(` `)},this.renderSection(`start`,r||[]),this.renderSection(`center`,o||[]),this.renderSection(`end`,i||[]))}renderSection(e,t){let{props:n}=this;return Q(vT,{key:e,widgetGroups:t,title:n.title,navUnit:n.navUnit,activeButton:n.activeButton,isTodayEnabled:n.isTodayEnabled,isPrevEnabled:n.isPrevEnabled,isNextEnabled:n.isNextEnabled,titleId:n.titleId})}},bT=class extends vb{constructor(){super(...arguments),this.state={availableWidth:null},this.handleEl=e=>{this.el=e,xb(this.props.elRef,e),this.updateAvailableWidth()},this.handleResize=()=>{this.updateAvailableWidth()}}render(){let{props:e,state:t}=this,{aspectRatio:n}=e,r=[`fc-view-harness`,n||e.liquid||e.height?`fc-view-harness-active`:`fc-view-harness-passive`],i=``,a=``;return n?t.availableWidth===null?a=`${1/n*100}%`:i=t.availableWidth/n:i=e.height||``,Q(`div`,{"aria-labelledby":e.labeledById,ref:this.handleEl,className:r.join(` `),style:{height:i,paddingBottom:a}},e.children)}componentDidMount(){this.context.addResizeHandler(this.handleResize)}componentWillUnmount(){this.context.removeResizeHandler(this.handleResize)}updateAvailableWidth(){this.el&&this.props.aspectRatio&&this.setState({availableWidth:this.el.offsetWidth})}},xT=class extends SS{constructor(e){super(e),this.handleSegClick=(e,t)=>{let{component:n}=this,{context:r}=n,i=Yx(t);if(i&&n.isValidSegDownEl(e.target)){let a=ev(e.target,`.fc-event-forced-url`),o=a?a.querySelector(`a[href]`).href:``;r.emitter.trigger(`eventClick`,{el:t,event:new Wx(n.context,i.eventRange.def,i.eventRange.instance),jsEvent:e,view:r.viewApi}),o&&!e.defaultPrevented&&(window.location.href=o)}},this.destroy=uv(e.el,`click`,`.fc-event`,this.handleSegClick)}},ST=class extends SS{constructor(e){super(e),this.handleEventElRemove=e=>{e===this.currentSegEl&&this.handleSegLeave(null,this.currentSegEl)},this.handleSegEnter=(e,t)=>{Yx(t)&&(this.currentSegEl=t,this.triggerEvent(`eventMouseEnter`,e,t))},this.handleSegLeave=(e,t)=>{this.currentSegEl&&(this.currentSegEl=null,this.triggerEvent(`eventMouseLeave`,e,t))},this.removeHoverListeners=dv(e.el,`.fc-event`,this.handleSegEnter,this.handleSegLeave)}destroy(){this.removeHoverListeners()}triggerEvent(e,t,n){let{component:r}=this,{context:i}=r,a=Yx(n);(!t||r.isValidSegDownEl(t.target))&&i.emitter.trigger(e,{el:n,event:new Wx(i,a.eventRange.def,a.eventRange.instance),jsEvent:t,view:i.viewApi})}},CT=class extends _b{constructor(){super(...arguments),this.buildViewContext=dy(gb),this.buildViewPropTransformers=dy(TT),this.buildToolbarProps=dy(wT),this.headerRef=kg(),this.footerRef=kg(),this.interactionsStore={},this.state={viewLabelId:cv()},this.registerInteractiveComponent=(e,t)=>{let n=CS(e,t),r=[xT,ST].concat(this.props.pluginHooks.componentInteractions).map(e=>new e(n));this.interactionsStore[e.uid]=r,wS[e.uid]=n},this.unregisterInteractiveComponent=e=>{let t=this.interactionsStore[e.uid];if(t){for(let e of t)e.destroy();delete this.interactionsStore[e.uid]}delete wS[e.uid]},this.resizeRunner=new Q_(()=>{this.props.emitter.trigger(`_resize`,!0),this.props.emitter.trigger(`windowResize`,{view:this.props.viewApi})}),this.handleWindowResize=e=>{let{options:t}=this.props;t.handleWindowResize&&e.target===window&&this.resizeRunner.request(t.windowResizeDelay)}}render(){let{props:e}=this,{toolbarConfig:t,options:n}=e,r=!1,i=``,a;e.isHeightAuto||e.forPrint?i=``:n.height==null?n.contentHeight==null?a=Math.max(n.aspectRatio,.5):i=n.contentHeight:r=!0;let o=this.buildViewContext(e.viewSpec,e.viewApi,e.options,e.dateProfileGenerator,e.dateEnv,e.nowManager,e.theme,e.pluginHooks,e.dispatch,e.getCurrentData,e.emitter,e.calendarApi,this.registerInteractiveComponent,this.unregisterInteractiveComponent),s=t.header&&t.header.hasTitle?this.state.viewLabelId:void 0;return Q(hb.Provider,{value:o},Q(TS,{unit:`day`},n=>{let o=this.buildToolbarProps(e.viewSpec,e.dateProfile,e.dateProfileGenerator,e.currentDate,n,e.viewTitle);return Q(Ag,null,t.header&&Q(yT,Object.assign({ref:this.headerRef,extraClassName:`fc-header-toolbar`,model:t.header,titleId:s},o)),Q(bT,{liquid:r,height:i,aspectRatio:a,labeledById:s},this.renderView(e),this.buildAppendContent()),t.footer&&Q(yT,Object.assign({ref:this.footerRef,extraClassName:`fc-footer-toolbar`,model:t.footer,titleId:``},o)))}))}componentDidMount(){let{props:e}=this;this.calendarInteractions=e.pluginHooks.calendarInteractions.map(t=>new t(e)),window.addEventListener(`resize`,this.handleWindowResize);let{propSetHandlers:t}=e.pluginHooks;for(let n in t)t[n](e[n],e)}componentDidUpdate(e){let{props:t}=this,{propSetHandlers:n}=t.pluginHooks;for(let r in n)t[r]!==e[r]&&n[r](t[r],t)}componentWillUnmount(){window.removeEventListener(`resize`,this.handleWindowResize),this.resizeRunner.clear();for(let e of this.calendarInteractions)e.destroy();this.props.emitter.trigger(`_unmount`)}buildAppendContent(){let{props:e}=this;return Q(Ag,{},...e.pluginHooks.viewContainerAppends.map(t=>t(e)))}renderView(e){let{pluginHooks:t}=e,{viewSpec:n}=e,r={dateProfile:e.dateProfile,businessHours:e.businessHours,eventStore:e.renderableEventStore,eventUiBases:e.eventUiBases,dateSelection:e.dateSelection,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,isHeightAuto:e.isHeightAuto,forPrint:e.forPrint},i=this.buildViewPropTransformers(t.viewPropsTransformers);for(let t of i)Object.assign(r,t.transform(r,e));let a=n.component;return Q(a,Object.assign({},r))}};function wT(e,t,n,r,i,a){let o=n.build(i,void 0,!1),s=n.buildPrev(t,r,!1),c=n.buildNext(t,r,!1);return{title:a,activeButton:e.type,navUnit:e.singleUnit,isTodayEnabled:o.isValid&&!Lb(t.currentRange,i),isPrevEnabled:s.isValid,isNextEnabled:c.isValid}}function TT(e){return e.map(e=>new e)}var ET=class extends DS{constructor(e,t={}){super(),this.isRendering=!1,this.isRendered=!1,this.currentClassNames=[],this.customContentRenderId=0,this.handleAction=e=>{switch(e.type){case`SET_EVENT_DRAG`:case`SET_EVENT_RESIZE`:this.renderRunner.tryDrain()}},this.handleData=e=>{this.currentData=e,this.renderRunner.request(e.calendarOptions.rerenderDelay)},this.handleRenderRequest=()=>{if(this.isRendering){this.isRendered=!0;let{currentData:e}=this;db(()=>{$g(Q(xS,{options:e.calendarOptions,theme:e.theme,emitter:e.emitter},(t,n,r,i)=>(this.setClassNames(t),this.setHeight(n),Q(Eb.Provider,{value:this.customContentRenderId},Q(CT,Object.assign({isHeightAuto:r,forPrint:i},e))))),this.el)})}else this.isRendered&&(this.isRendered=!1,$g(null,this.el),this.setClassNames([]),this.setHeight(``))},G_(e),this.el=e,this.renderRunner=new Q_(this.handleRenderRequest),new sT({optionOverrides:t,calendarApi:this,onAction:this.handleAction,onData:this.handleData})}render(){let e=this.isRendering;e?this.customContentRenderId+=1:this.isRendering=!0,this.renderRunner.request(),e&&this.updateSize()}destroy(){this.isRendering&&(this.isRendering=!1,this.renderRunner.request())}updateSize(){db(()=>{super.updateSize()})}batchRendering(e){this.renderRunner.pause(`batchRendering`),e(),this.renderRunner.resume(`batchRendering`)}pauseRendering(){this.renderRunner.pause(`pauseRendering`)}resumeRendering(){this.renderRunner.resume(`pauseRendering`,!0)}resetOptions(e,t){this.currentDataManager.resetOptions(e,t)}setClassNames(e){if(!Fv(e,this.currentClassNames)){let{classList:t}=this.el;for(let e of this.currentClassNames)t.remove(e);for(let n of e)t.add(n);this.currentClassNames=e}}setHeight(e){av(this.el,`height`,e)}},DT=parseInt(`19.2.8`.split(`.`)[0])<18,OT=class extends C.Component{constructor(){super(...arguments),this.elRef=(0,C.createRef)(),this.isUpdating=!1,this.isUnmounting=!1,this.state={customRenderingMap:new Map},this.requestResize=()=>{this.isUnmounting||(this.cancelResize(),this.resizeId=requestAnimationFrame(()=>{this.doResize()}))}}render(){let e=[];for(let t of this.state.customRenderingMap.values())e.push(C.createElement(kT,{key:t.id,customRendering:t}));return C.createElement(`div`,{ref:this.elRef},e)}componentDidMount(){this.isUnmounting=!1;let e=new JC;this.handleCustomRendering=e.handle.bind(e),this.calendar=new ET(this.elRef.current,Object.assign(Object.assign({},this.props),{handleCustomRendering:this.handleCustomRendering})),this.calendar.render(),this.calendar.on(`_beforeprint`,()=>{(0,pe.flushSync)(()=>{})});let t;e.subscribe(e=>{let n=Date.now(),r=!t;(DT||r||this.isUpdating||this.isUnmounting||n-t<100?AT:pe.flushSync)(()=>{this.setState({customRenderingMap:e},()=>{t=n,r?this.doResize():this.requestResize()})})})}componentDidUpdate(){this.isUpdating=!0,this.calendar.resetOptions(Object.assign(Object.assign({},this.props),{handleCustomRendering:this.handleCustomRendering})),this.isUpdating=!1}componentWillUnmount(){this.isUnmounting=!0,this.cancelResize(),this.calendar.destroy()}doResize(){this.calendar.updateSize()}cancelResize(){this.resizeId!==void 0&&(cancelAnimationFrame(this.resizeId),this.resizeId=void 0)}getApi(){return this.calendar}};OT.act=AT;var kT=class extends C.PureComponent{render(){let{customRendering:e}=this.props,{generatorMeta:t}=e,n=typeof t==`function`?t(e.renderProps):t;return(0,pe.createPortal)(n,e.containerEl)}};function AT(e){e()}var jT=class extends HS{constructor(){super(...arguments),this.headerElRef=kg()}renderSimpleLayout(e,t){let{props:n,context:r}=this,i=[],a=xC(r.options);return e&&i.push({type:`header`,key:`header`,isSticky:a,chunk:{elRef:this.headerElRef,tableClassName:`fc-col-header`,rowContent:e}}),i.push({type:`body`,key:`body`,liquid:!0,chunk:{content:t}}),Q(Ab,{elClasses:[`fc-daygrid`],viewSpec:r.viewSpec},Q(CC,{liquid:!n.isHeightAuto&&!n.forPrint,collapsibleWidth:n.forPrint,cols:[],sections:i}))}renderHScrollLayout(e,t,n,r){let i=this.context.pluginHooks.scrollGridImpl;if(!i)throw Error(`No ScrollGrid implementation`);let{props:a,context:o}=this,s=!a.forPrint&&xC(o.options),c=!a.forPrint&&SC(o.options),l=[];return e&&l.push({type:`header`,key:`header`,isSticky:s,chunks:[{key:`main`,elRef:this.headerElRef,tableClassName:`fc-col-header`,rowContent:e}]}),l.push({type:`body`,key:`body`,liquid:!0,chunks:[{key:`main`,content:t}]}),c&&l.push({type:`footer`,key:`footer`,isSticky:!0,chunks:[{key:`main`,content:bC}]}),Q(Ab,{elClasses:[`fc-daygrid`],viewSpec:o.viewSpec},Q(i,{liquid:!a.isHeightAuto&&!a.forPrint,forPrint:a.forPrint,collapsibleWidth:a.forPrint,colGroups:[{cols:[{span:n,minWidth:r}]}],sections:l}))}};function MT(e,t){let n=[];for(let e=0;e<t;e+=1)n[e]=[];for(let t of e)n[t.row].push(t);return n}function NT(e,t){let n=[];for(let e=0;e<t;e+=1)n[e]=[];for(let t of e)n[t.firstCol].push(t);return n}function PT(e,t){let n=[];if(e){for(let r=0;r<t;r+=1)n[r]={affectedInstances:e.affectedInstances,isEvent:e.isEvent,segs:[]};for(let t of e.segs)n[t.row].segs.push(t)}else for(let e=0;e<t;e+=1)n[e]=null;return n}var FT=Py({hour:`numeric`,minute:`2-digit`,omitZeroMinute:!0,meridiem:`narrow`});function IT(e){let{display:t}=e.eventRange.ui;return t===`list-item`||t===`auto`&&!e.eventRange.def.allDay&&e.firstCol===e.lastCol&&e.isStart&&e.isEnd}var LT=class extends vb{render(){let{props:e}=this;return Q(EC,Object.assign({},e,{elClasses:[`fc-daygrid-event`,`fc-daygrid-block-event`,`fc-h-event`],defaultTimeFormat:FT,defaultDisplayEventEnd:e.defaultDisplayEventEnd,disableResizing:!e.seg.eventRange.def.allDay}))}},RT=class extends vb{render(){let{props:e,context:t}=this,{options:n}=t,{seg:r}=e,i=rS(r,n.eventTimeFormat||FT,t,!0,e.defaultDisplayEventEnd);return Q(TC,Object.assign({},e,{elTag:`a`,elClasses:[`fc-daygrid-event`,`fc-daygrid-dot-event`],elAttrs:sS(e.seg,t),defaultGenerator:zT,timeText:i,isResizing:!1,isDateSelecting:!1}))}};function zT(e){return Q(Ag,null,Q(`div`,{className:`fc-daygrid-event-dot`,style:{borderColor:e.borderColor||e.backgroundColor}}),e.timeText&&Q(`div`,{className:`fc-event-time`},e.timeText),Q(`div`,{className:`fc-event-title`},e.event.title||Q(Ag,null,`\xA0`)))}var BT=class extends vb{constructor(){super(...arguments),this.compileSegs=dy(VT)}render(){let{props:e}=this,{allSegs:t,invisibleSegs:n}=this.compileSegs(e.singlePlacements);return Q(BC,{elClasses:[`fc-daygrid-more-link`],dateProfile:e.dateProfile,todayRange:e.todayRange,allDayDate:e.allDayDate,moreCnt:e.moreCnt,allSegs:t,hiddenSegs:n,alignmentElRef:e.alignmentElRef,alignGridTop:e.alignGridTop,extraDateSpan:e.extraDateSpan,popoverContent:()=>{let n=(e.eventDrag?e.eventDrag.affectedInstances:null)||(e.eventResize?e.eventResize.affectedInstances:null)||{};return Q(Ag,null,t.map(t=>{let r=t.eventRange.instance.instanceId;return Q(`div`,{className:`fc-daygrid-event-harness`,key:r,style:{visibility:n[r]?`hidden`:``}},IT(t)?Q(RT,Object.assign({seg:t,isDragging:!1,isSelected:r===e.eventSelection,defaultDisplayEventEnd:!1},iS(t,e.todayRange))):Q(LT,Object.assign({seg:t,isDragging:!1,isResizing:!1,isDateSelecting:!1,isSelected:r===e.eventSelection,defaultDisplayEventEnd:!1},iS(t,e.todayRange))))}))}})}};function VT(e){let t=[],n=[];for(let r of e)t.push(r.seg),r.isVisible||n.push(r.seg);return{allSegs:t,invisibleSegs:n}}var HT=Py({week:`narrow`}),UT=class extends HS{constructor(){super(...arguments),this.rootElRef=kg(),this.state={dayNumberId:cv()},this.handleRootEl=e=>{xb(this.rootElRef,e),xb(this.props.elRef,e)}}render(){let{context:e,props:t,state:n,rootElRef:r}=this,{options:i,dateEnv:a}=e,{date:o,dateProfile:s}=t,c=t.showDayNumber&>(o,s.currentRange,a);return Q(kC,{elTag:`td`,elRef:this.handleRootEl,elClasses:[`fc-daygrid-day`,...t.extraClassNames||[]],elAttrs:Object.assign(Object.assign(Object.assign({},t.extraDataAttrs),t.showDayNumber?{"aria-labelledby":n.dayNumberId}:{}),{role:`gridcell`}),defaultGenerator:WT,date:o,dateProfile:s,todayRange:t.todayRange,showDayNumber:t.showDayNumber,isMonthStart:c,extraRenderProps:t.extraRenderProps},(a,s)=>Q(`div`,{ref:t.innerElRef,className:`fc-daygrid-day-frame fc-scrollgrid-sync-inner`,style:{minHeight:t.minHeight}},t.showWeekNumber&&Q(FC,{elTag:`a`,elClasses:[`fc-daygrid-week-number`],elAttrs:NS(e,o,`week`),date:o,defaultFormat:HT}),!s.isDisabled&&(t.showDayNumber||AC(i)||t.forceDayTop)?Q(`div`,{className:`fc-daygrid-day-top`},Q(a,{elTag:`a`,elClasses:[`fc-daygrid-day-number`,c&&`fc-daygrid-month-start`],elAttrs:Object.assign(Object.assign({},NS(e,o)),{id:n.dayNumberId})})):t.showDayNumber?Q(`div`,{className:`fc-daygrid-day-top`,style:{visibility:`hidden`}},Q(`a`,{className:`fc-daygrid-day-number`},`\xA0`)):void 0,Q(`div`,{className:`fc-daygrid-day-events`,ref:t.fgContentElRef},t.fgContent,Q(`div`,{className:`fc-daygrid-day-bottom`,style:{marginTop:t.moreMarginTop}},Q(BT,{allDayDate:o,singlePlacements:t.singlePlacements,moreCnt:t.moreCnt,alignmentElRef:r,alignGridTop:!t.showDayNumber,extraDateSpan:t.extraDateSpan,dateProfile:t.dateProfile,eventSelection:t.eventSelection,eventDrag:t.eventDrag,eventResize:t.eventResize,todayRange:t.todayRange}))),Q(`div`,{className:`fc-daygrid-day-bg`},t.bgContent)))}};function WT(e){return e.dayNumberText||Q(Ag,null,`\xA0`)}function GT(e,t,n){let{start:r,end:i}=t,a=zv(i,-1),o=n.getYear(r),s=n.getMonth(r),c=n.getYear(a),l=n.getMonth(a);return(o!==c||s!==l)&&(e.valueOf()===r.valueOf()||n.getDay(e)===1&&e.valueOf()<i.valueOf())}function KT(e){return e.eventRange.instance.instanceId+`:`+e.firstCol}function qT(e){return KT(e)+`:`+e.lastCol}function JT(e,t,n,r,i,a,o){let s=new QT(t=>i[e[t.index].eventRange.instance.instanceId+`:`+t.span.start+`:`+(t.span.end-1)]||1);s.allowReslicing=!0,s.strictOrder=r,t===!0||n===!0?(s.maxCoord=a,s.hiddenConsumes=!0):typeof t==`number`?s.maxStackCnt=t:typeof n==`number`&&(s.maxStackCnt=n,s.hiddenConsumes=!0);let c=[],l=[];for(let t=0;t<e.length;t+=1){let n=e[t];i[qT(n)]==null?l.push(n):c.push({index:t,span:{start:n.firstCol,end:n.lastCol+1}})}let u=s.addSegs(c),{singleColPlacements:d,multiColPlacements:f,leftoverMargins:p}=YT(s.toRects(),e,o),m=[],h=[];for(let e of l){f[e.firstCol].push({seg:e,isVisible:!1,isAbsolute:!0,absoluteTop:0,marginTop:0});for(let t=e.firstCol;t<=e.lastCol;t+=1)d[t].push({seg:ZT(e,t,t+1,o),isVisible:!1,isAbsolute:!1,absoluteTop:0,marginTop:0})}for(let e=0;e<o.length;e+=1)m.push(0);for(let t of u){let n=e[t.index],r=t.span;f[r.start].push({seg:ZT(n,r.start,r.end,o),isVisible:!1,isAbsolute:!0,absoluteTop:0,marginTop:0});for(let e=r.start;e<r.end;e+=1)m[e]+=1,d[e].push({seg:ZT(n,e,e+1,o),isVisible:!1,isAbsolute:!1,absoluteTop:0,marginTop:0})}for(let e=0;e<o.length;e+=1)h.push(p[e]);return{singleColPlacements:d,multiColPlacements:f,moreCnts:m,moreMarginTops:h}}function YT(e,t,n){let r=XT(e,n.length),i=[],a=[],o=[];for(let e=0;e<n.length;e+=1){let s=r[e],c=[],l=0,u=0;for(let r of s){let i=t[r.index];c.push({seg:ZT(i,e,e+1,n),isVisible:!0,isAbsolute:!1,absoluteTop:r.levelCoord,marginTop:r.levelCoord-l}),l=r.levelCoord+r.thickness}let d=[];l=0,u=0;for(let r of s){let i=t[r.index],a=r.span.end-r.span.start>1,o=r.span.start===e;u+=r.levelCoord-l,l=r.levelCoord+r.thickness,a?(u+=r.thickness,o&&d.push({seg:ZT(i,r.span.start,r.span.end,n),isVisible:!0,isAbsolute:!0,absoluteTop:r.levelCoord,marginTop:0})):o&&(d.push({seg:ZT(i,r.span.start,r.span.end,n),isVisible:!0,isAbsolute:!1,absoluteTop:r.levelCoord,marginTop:u}),u=0)}i.push(c),a.push(d),o.push(u)}return{singleColPlacements:i,multiColPlacements:a,leftoverMargins:o}}function XT(e,t){let n=[];for(let e=0;e<t;e+=1)n.push([]);for(let t of e)for(let e=t.span.start;e<t.span.end;e+=1)n[e].push(t);return n}function ZT(e,t,n,r){if(e.firstCol===t&&e.lastCol===n-1)return e;let i=e.eventRange,a=i.range,o=Fb(a,{start:r[t].date,end:Rv(r[n-1].date,1)});return Object.assign(Object.assign({},e),{firstCol:t,lastCol:n-1,eventRange:{def:i.def,ui:Object.assign(Object.assign({},i.ui),{durationEditable:!1}),instance:i.instance,range:o},isStart:e.isStart&&o.start.valueOf()===a.start.valueOf(),isEnd:e.isEnd&&o.end.valueOf()===a.end.valueOf()})}var QT=class extends US{constructor(){super(...arguments),this.hiddenConsumes=!1,this.forceHidden={}}addSegs(e){let t=super.addSegs(e),{entriesByLevel:n}=this,r=e=>!this.forceHidden[GS(e)];for(let e=0;e<n.length;e+=1)n[e]=n[e].filter(r);return t}handleInvalidInsertion(e,t,n){let{entriesByLevel:r,forceHidden:i}=this,{touchingEntry:a,touchingLevel:o,touchingLateral:s}=e;if(this.hiddenConsumes&&a){let e=GS(a);if(!i[e]){if(this.allowReslicing){let e=Object.assign(Object.assign({},a),{span:KS(a.span,t.span)}),c=GS(e);i[c]=!0,r[o][s]=e,n.push(e),this.splitEntry(a,t,n)}else i[e]=!0,n.push(a)}}super.handleInvalidInsertion(e,t,n)}},$T=class extends HS{constructor(){super(...arguments),this.cellElRefs=new lC,this.frameElRefs=new lC,this.fgElRefs=new lC,this.segHarnessRefs=new lC,this.rootElRef=kg(),this.state={framePositions:null,maxContentHeight:null,segHeights:{}},this.handleResize=e=>{e&&this.updateSizing(!0)}}render(){let{props:e,state:t,context:n}=this,{options:r}=n,i=e.cells.length,a=NT(e.businessHourSegs,i),o=NT(e.bgEventSegs,i),s=NT(this.getHighlightSegs(),i),c=NT(this.getMirrorSegs(),i),{singleColPlacements:l,multiColPlacements:u,moreCnts:d,moreMarginTops:f}=JT(Qx(e.fgEventSegs,r.eventOrder),e.dayMaxEvents,e.dayMaxEventRows,r.eventOrderStrict,t.segHeights,t.maxContentHeight,e.cells),p=e.eventDrag&&e.eventDrag.affectedInstances||e.eventResize&&e.eventResize.affectedInstances||{};return Q(`tr`,{ref:this.rootElRef,role:`row`},e.renderIntro&&e.renderIntro(),e.cells.map((t,n)=>{let r=this.renderFgSegs(n,e.forPrint?l[n]:u[n],e.todayRange,p),i=this.renderFgSegs(n,eE(c[n],u),e.todayRange,{},!!e.eventDrag,!!e.eventResize,!1);return Q(UT,{key:t.key,elRef:this.cellElRefs.createRef(t.key),innerElRef:this.frameElRefs.createRef(t.key),dateProfile:e.dateProfile,date:t.date,showDayNumber:e.showDayNumbers,showWeekNumber:e.showWeekNumbers&&n===0,forceDayTop:e.showWeekNumbers,todayRange:e.todayRange,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,extraRenderProps:t.extraRenderProps,extraDataAttrs:t.extraDataAttrs,extraClassNames:t.extraClassNames,extraDateSpan:t.extraDateSpan,moreCnt:d[n],moreMarginTop:f[n],singlePlacements:l[n],fgContentElRef:this.fgElRefs.createRef(t.key),fgContent:Q(Ag,null,Q(Ag,null,r),Q(Ag,null,i)),bgContent:Q(Ag,null,this.renderFillSegs(s[n],`highlight`),this.renderFillSegs(a[n],`non-business`),this.renderFillSegs(o[n],`bg-event`)),minHeight:e.cellMinHeight})}))}componentDidMount(){this.updateSizing(!0),this.context.addResizeHandler(this.handleResize)}componentDidUpdate(e,t){let n=this.props;this.updateSizing(!Zy(e,n))}componentWillUnmount(){this.context.removeResizeHandler(this.handleResize)}getHighlightSegs(){let{props:e}=this;return e.eventDrag&&e.eventDrag.segs.length?e.eventDrag.segs:e.eventResize&&e.eventResize.segs.length?e.eventResize.segs:e.dateSelectionSegs}getMirrorSegs(){let{props:e}=this;return e.eventResize&&e.eventResize.segs.length?e.eventResize.segs:[]}renderFgSegs(e,t,n,r,i,a,o){let{context:s}=this,{eventSelection:c}=this.props,{framePositions:l}=this.state,u=this.props.cells.length===1,d=i||a||o,f=[];if(l)for(let e of t){let{seg:t}=e,{instanceId:p}=t.eventRange.instance,m=e.isVisible&&!r[p],h=e.isAbsolute,g=``,_=``;h&&(s.isRtl?(_=0,g=l.lefts[t.lastCol]-l.lefts[t.firstCol]):(g=0,_=l.rights[t.firstCol]-l.rights[t.lastCol])),f.push(Q(`div`,{className:`fc-daygrid-event-harness`+(h?` fc-daygrid-event-harness-abs`:``),key:KT(t),ref:d?null:this.segHarnessRefs.createRef(qT(t)),style:{visibility:m?``:`hidden`,marginTop:h?``:e.marginTop,top:h?e.absoluteTop:``,left:g,right:_}},IT(t)?Q(RT,Object.assign({seg:t,isDragging:i,isSelected:p===c,defaultDisplayEventEnd:u},iS(t,n))):Q(LT,Object.assign({seg:t,isDragging:i,isResizing:a,isDateSelecting:o,isSelected:p===c,defaultDisplayEventEnd:u},iS(t,n)))))}return f}renderFillSegs(e,t){let{isRtl:n}=this.context,{todayRange:r}=this.props,{framePositions:i}=this.state,a=[];if(i)for(let o of e){let e=n?{right:0,left:i.lefts[o.lastCol]-i.lefts[o.firstCol]}:{left:0,right:i.rights[o.firstCol]-i.rights[o.lastCol]};a.push(Q(`div`,{key:oS(o.eventRange),className:`fc-daygrid-bg-harness`,style:e},t===`bg-event`?Q(MC,Object.assign({seg:o},iS(o,r))):PC(t)))}return Q(Ag,{},...a)}updateSizing(e){let{props:t,state:n,frameElRefs:r}=this;if(!t.forPrint&&t.clientWidth!==null){if(e){let e=t.cells.map(e=>r.currentMap[e.key]);if(e.length){let t=this.rootElRef.current,r=new BS(t,e,!0,!1);(!n.framePositions||!n.framePositions.similarTo(r))&&this.setState({framePositions:new BS(t,e,!0,!1)})}}let i=this.state.segHeights,a=this.querySegHeights(),o=t.dayMaxEvents===!0||t.dayMaxEventRows===!0;this.safeSetState({segHeights:Object.assign(Object.assign({},i),a),maxContentHeight:o?this.computeMaxContentHeight():null})}}querySegHeights(){let e=this.segHarnessRefs.currentMap,t={};for(let n in e){let r=Math.round(e[n].getBoundingClientRect().height);t[n]=Math.max(t[n]||0,r)}return t}computeMaxContentHeight(){let e=this.props.cells[0].key,t=this.cellElRefs.currentMap[e],n=this.fgElRefs.currentMap[e];return t.getBoundingClientRect().bottom-n.getBoundingClientRect().top}getCellEls(){let e=this.cellElRefs.currentMap;return this.props.cells.map(t=>e[t.key])}};$T.addStateEquality({segHeights:Zy});function eE(e,t){if(!e.length)return[];let n=tE(t);return e.map(e=>({seg:e,isVisible:!0,isAbsolute:!0,absoluteTop:n[e.eventRange.instance.instanceId],marginTop:0}))}function tE(e){let t={};for(let n of e)for(let e of n)t[e.seg.eventRange.instance.instanceId]=e.absoluteTop;return t}var nE=class extends HS{constructor(){super(...arguments),this.splitBusinessHourSegs=dy(MT),this.splitBgEventSegs=dy(rE),this.splitFgEventSegs=dy(MT),this.splitDateSelectionSegs=dy(MT),this.splitEventDrag=dy(PT),this.splitEventResize=dy(PT),this.rowRefs=new lC}render(){let{props:e,context:t}=this,n=e.cells.length,r=this.splitBusinessHourSegs(e.businessHourSegs,n),i=this.splitBgEventSegs(e.bgEventSegs,n),a=this.splitFgEventSegs(e.fgEventSegs,n),o=this.splitDateSelectionSegs(e.dateSelectionSegs,n),s=this.splitEventDrag(e.eventDrag,n),c=this.splitEventResize(e.eventResize,n),l=n>=7&&e.clientWidth?e.clientWidth/t.options.aspectRatio/6:null;return Q(TS,{unit:`day`},(t,u)=>Q(Ag,null,e.cells.map((t,d)=>Q($T,{ref:this.rowRefs.createRef(d),key:t.length?t[0].date.toISOString():d,showDayNumbers:n>1,showWeekNumbers:e.showWeekNumbers,todayRange:u,dateProfile:e.dateProfile,cells:t,renderIntro:e.renderRowIntro,businessHourSegs:r[d],eventSelection:e.eventSelection,bgEventSegs:i[d],fgEventSegs:a[d],dateSelectionSegs:o[d],eventDrag:s[d],eventResize:c[d],dayMaxEvents:e.dayMaxEvents,dayMaxEventRows:e.dayMaxEventRows,clientWidth:e.clientWidth,clientHeight:e.clientHeight,cellMinHeight:l,forPrint:e.forPrint}))))}componentDidMount(){this.registerInteractiveComponent()}componentDidUpdate(){this.registerInteractiveComponent()}registerInteractiveComponent(){if(!this.rootEl){let e=this.rowRefs.currentMap[0].getCellEls()[0],t=e?e.closest(`.fc-daygrid-body`):null;t&&(this.rootEl=t,this.context.registerInteractiveComponent(this,{el:t,isHitComboAllowed:this.props.isHitComboAllowed}))}}componentWillUnmount(){this.rootEl&&=(this.context.unregisterInteractiveComponent(this),null)}prepareHits(){this.rowPositions=new BS(this.rootEl,this.rowRefs.collect().map(e=>e.getCellEls()[0]),!1,!0),this.colPositions=new BS(this.rootEl,this.rowRefs.currentMap[0].getCellEls(),!0,!1)}queryHit(e,t){let{colPositions:n,rowPositions:r}=this,i=n.leftToIndex(e),a=r.topToIndex(t);if(a!=null&&i!=null){let e=this.props.cells[a][i];return{dateProfile:this.props.dateProfile,dateSpan:Object.assign({range:this.getCellRange(a,i),allDay:!0},e.extraDateSpan),dayEl:this.getCellEl(a,i),rect:{left:n.lefts[i],right:n.rights[i],top:r.tops[a],bottom:r.bottoms[a]},layer:0}}return null}getCellEl(e,t){return this.rowRefs.currentMap[e].getCellEls()[t]}getCellRange(e,t){let n=this.props.cells[e][t].date;return{start:n,end:Rv(n,1)}}};function rE(e,t){return MT(e.filter(iE),t)}function iE(e){return e.eventRange.def.allDay}var aE=class extends HS{constructor(){super(...arguments),this.elRef=kg(),this.needsScrollReset=!1}render(){let{props:e}=this,{dayMaxEventRows:t,dayMaxEvents:n,expandRows:r}=e,i=n===!0||t===!0;i&&!r&&(i=!1,t=null,n=null);let a=[`fc-daygrid-body`,i?`fc-daygrid-body-balanced`:`fc-daygrid-body-unbalanced`,r?``:`fc-daygrid-body-natural`];return Q(`div`,{ref:this.elRef,className:a.join(` `),style:{width:e.clientWidth,minWidth:e.tableMinWidth}},Q(`table`,{role:`presentation`,className:`fc-scrollgrid-sync-table`,style:{width:e.clientWidth,minWidth:e.tableMinWidth,height:r?e.clientHeight:``}},e.colGroupNode,Q(`tbody`,{role:`presentation`},Q(nE,{dateProfile:e.dateProfile,cells:e.cells,renderRowIntro:e.renderRowIntro,showWeekNumbers:e.showWeekNumbers,clientWidth:e.clientWidth,clientHeight:e.clientHeight,businessHourSegs:e.businessHourSegs,bgEventSegs:e.bgEventSegs,fgEventSegs:e.fgEventSegs,dateSelectionSegs:e.dateSelectionSegs,eventSelection:e.eventSelection,eventDrag:e.eventDrag,eventResize:e.eventResize,dayMaxEvents:n,dayMaxEventRows:t,forPrint:e.forPrint,isHitComboAllowed:e.isHitComboAllowed}))))}componentDidMount(){this.requestScrollReset()}componentDidUpdate(e){e.dateProfile===this.props.dateProfile?this.flushScrollReset():this.requestScrollReset()}requestScrollReset(){this.needsScrollReset=!0,this.flushScrollReset()}flushScrollReset(){if(this.needsScrollReset&&this.props.clientWidth){let e=oE(this.elRef.current,this.props.dateProfile);if(e){let t=e.closest(`.fc-daygrid-body`),n=t.closest(`.fc-scroller`),r=e.getBoundingClientRect().top-t.getBoundingClientRect().top;n.scrollTop=r?r+1:0}this.needsScrollReset=!1}}};function oE(e,t){let n;return t.currentRangeUnit.match(/year|month/)&&(n=e.querySelector(`[data-date="${ly(t.currentDate)}-01"]`)),n||=e.querySelector(`[data-date="${cy(t.currentDate)}"]`),n}var sE=class extends aC{constructor(){super(...arguments),this.forceDayIfListItem=!0}sliceRange(e,t){return t.sliceRange(e)}},cE=class extends HS{constructor(){super(...arguments),this.slicer=new sE,this.tableRef=kg()}render(){let{props:e,context:t}=this;return Q(aE,Object.assign({ref:this.tableRef},this.slicer.sliceProps(e,e.dateProfile,e.nextDayThreshold,t,e.dayTableModel),{dateProfile:e.dateProfile,cells:e.dayTableModel.cells,colGroupNode:e.colGroupNode,tableMinWidth:e.tableMinWidth,renderRowIntro:e.renderRowIntro,dayMaxEvents:e.dayMaxEvents,dayMaxEventRows:e.dayMaxEventRows,showWeekNumbers:e.showWeekNumbers,expandRows:e.expandRows,headerAlignElRef:e.headerAlignElRef,clientWidth:e.clientWidth,clientHeight:e.clientHeight,forPrint:e.forPrint}))}},lE=class extends jT{constructor(){super(...arguments),this.buildDayTableModel=dy(uE),this.headerRef=kg(),this.tableRef=kg()}render(){let{options:e,dateProfileGenerator:t}=this.context,{props:n}=this,r=this.buildDayTableModel(n.dateProfile,t),i=e.dayHeaders&&Q(tC,{ref:this.headerRef,dateProfile:n.dateProfile,dates:r.headerDates,datesRepDistinctDays:r.rowCnt===1}),a=t=>Q(cE,{ref:this.tableRef,dateProfile:n.dateProfile,dayTableModel:r,businessHours:n.businessHours,dateSelection:n.dateSelection,eventStore:n.eventStore,eventUiBases:n.eventUiBases,eventSelection:n.eventSelection,eventDrag:n.eventDrag,eventResize:n.eventResize,nextDayThreshold:e.nextDayThreshold,colGroupNode:t.tableColGroupNode,tableMinWidth:t.tableMinWidth,dayMaxEvents:e.dayMaxEvents,dayMaxEventRows:e.dayMaxEventRows,showWeekNumbers:e.weekNumbers,expandRows:!n.isHeightAuto,headerAlignElRef:this.headerElRef,clientWidth:t.clientWidth,clientHeight:t.clientHeight,forPrint:n.forPrint});return e.dayMinWidth?this.renderHScrollLayout(i,a,r.colCnt,e.dayMinWidth):this.renderSimpleLayout(i,a)}};function uE(e,t){return new iC(new rC(e.renderRange,t),/year|month|week/.test(e.currentRangeUnit))}var dE=class extends Hb{buildRenderRange(e,t,n){let r=super.buildRenderRange(e,t,n),{props:i}=this;return fE({currentRange:r,snapToWeek:/^(year|month)$/.test(t),fixedWeekCount:i.fixedWeekCount,dateEnv:i.dateEnv})}};function fE(e){let{dateEnv:t,currentRange:n}=e,{start:r,end:i}=n,a;if(e.snapToWeek&&(r=t.startOfWeek(r),a=t.startOfWeek(i),a.valueOf()!==i.valueOf()&&(i=Lv(a,1))),e.fixedWeekCount){let e=t.startOfWeek(t.startOfMonth(Rv(n.end,-1))),r=Math.ceil(Bv(e,i));i=Lv(i,6-r)}return{start:r,end:i}}W_(`:root{--fc-daygrid-event-dot-width:8px}.fc-daygrid-day-events:after,.fc-daygrid-day-events:before,.fc-daygrid-day-frame:after,.fc-daygrid-day-frame:before,.fc-daygrid-event-harness:after,.fc-daygrid-event-harness:before{clear:both;content:"";display:table}.fc .fc-daygrid-body{position:relative;z-index:1}.fc .fc-daygrid-day.fc-day-today{background-color:var(--fc-today-bg-color)}.fc .fc-daygrid-day-frame{min-height:100%;position:relative}.fc .fc-daygrid-day-top{display:flex;flex-direction:row-reverse}.fc .fc-day-other .fc-daygrid-day-top{opacity:.3}.fc .fc-daygrid-day-number{padding:4px;position:relative;z-index:4}.fc .fc-daygrid-month-start{font-size:1.1em;font-weight:700}.fc .fc-daygrid-day-events{margin-top:1px}.fc .fc-daygrid-body-balanced .fc-daygrid-day-events{left:0;position:absolute;right:0}.fc .fc-daygrid-body-unbalanced .fc-daygrid-day-events{min-height:2em;position:relative}.fc .fc-daygrid-body-natural .fc-daygrid-day-events{margin-bottom:1em}.fc .fc-daygrid-event-harness{position:relative}.fc .fc-daygrid-event-harness-abs{left:0;position:absolute;right:0;top:0}.fc .fc-daygrid-bg-harness{bottom:0;position:absolute;top:0}.fc .fc-daygrid-day-bg .fc-non-business{z-index:1}.fc .fc-daygrid-day-bg .fc-bg-event{z-index:2}.fc .fc-daygrid-day-bg .fc-highlight{z-index:3}.fc .fc-daygrid-event{margin-top:1px;z-index:6}.fc .fc-daygrid-event.fc-event-mirror{z-index:7}.fc .fc-daygrid-day-bottom{font-size:.85em;margin:0 2px}.fc .fc-daygrid-day-bottom:after,.fc .fc-daygrid-day-bottom:before{clear:both;content:"";display:table}.fc .fc-daygrid-more-link{border-radius:3px;cursor:pointer;line-height:1;margin-top:1px;max-width:100%;overflow:hidden;padding:2px;position:relative;white-space:nowrap;z-index:4}.fc .fc-daygrid-more-link:hover{background-color:rgba(0,0,0,.1)}.fc .fc-daygrid-week-number{background-color:var(--fc-neutral-bg-color);color:var(--fc-neutral-text-color);min-width:1.5em;padding:2px;position:absolute;text-align:center;top:0;z-index:5}.fc .fc-more-popover .fc-popover-body{min-width:220px;padding:10px}.fc-direction-ltr .fc-daygrid-event.fc-event-start,.fc-direction-rtl .fc-daygrid-event.fc-event-end{margin-left:2px}.fc-direction-ltr .fc-daygrid-event.fc-event-end,.fc-direction-rtl .fc-daygrid-event.fc-event-start{margin-right:2px}.fc-direction-ltr .fc-daygrid-more-link{float:left}.fc-direction-ltr .fc-daygrid-week-number{border-radius:0 0 3px 0;left:0}.fc-direction-rtl .fc-daygrid-more-link{float:right}.fc-direction-rtl .fc-daygrid-week-number{border-radius:0 0 0 3px;right:0}.fc-liquid-hack .fc-daygrid-day-frame{position:static}.fc-daygrid-event{border-radius:3px;font-size:var(--fc-small-font-size);position:relative;white-space:nowrap}.fc-daygrid-block-event .fc-event-time{font-weight:700}.fc-daygrid-block-event .fc-event-time,.fc-daygrid-block-event .fc-event-title{padding:1px}.fc-daygrid-dot-event{align-items:center;display:flex;padding:2px 0}.fc-daygrid-dot-event .fc-event-title{flex-grow:1;flex-shrink:1;font-weight:700;min-width:0;overflow:hidden}.fc-daygrid-dot-event.fc-event-mirror,.fc-daygrid-dot-event:hover{background:rgba(0,0,0,.1)}.fc-daygrid-dot-event.fc-event-selected:before{bottom:-10px;top:-10px}.fc-daygrid-event-dot{border:calc(var(--fc-daygrid-event-dot-width)/2) solid var(--fc-event-border-color);border-radius:calc(var(--fc-daygrid-event-dot-width)/2);box-sizing:content-box;height:0;margin:0 4px;width:0}.fc-direction-ltr .fc-daygrid-event .fc-event-time{margin-right:3px}.fc-direction-rtl .fc-daygrid-event .fc-event-time{margin-left:3px}`);var pE=rw({name:`@fullcalendar/daygrid`,initialView:`dayGridMonth`,views:{dayGrid:{component:lE,dateProfileGeneratorClass:dE},dayGridDay:{type:`dayGrid`,duration:{days:1}},dayGridWeek:{type:`dayGrid`,duration:{weeks:1}},dayGridMonth:{type:`dayGrid`,duration:{months:1},fixedWeekCount:!0},dayGridYear:{type:`dayGrid`,duration:{years:1}}}});function mE({cards:e,onOpen:t}){let n=(0,C.useMemo)(()=>On(e),[e]);function r(e){let n=En(e);n&&t(n)}return(0,G.jsx)(`div`,{className:`pk-calendar h-full min-h-0 p-2`,children:(0,G.jsx)(OT,{plugins:[pE],initialView:`dayGridMonth`,headerToolbar:{left:`prev`,center:`title`,right:`next`},events:n,editable:!1,selectable:!1,height:`100%`,expandRows:!0,fixedWeekCount:!1,dayMaxEvents:!0,eventContent:e=>{let n=En(e.event.extendedProps);return!n||(0,G.jsx)(`button`,{type:`button`,className:`fc-event-key`,title:e.event.title,onClick:e=>{e.preventDefault(),e.stopPropagation(),t(n)},children:n})},eventClick:e=>{e.jsEvent.preventDefault(),r(e.event.extendedProps)}})})}function hE(e){return e.key?`${e.jump.kind}:${e.key}`:e.label}function gE({presets:e,epics:t,cards:n,favouriteKeys:r,onPick:i,onClose:a}){let[o,s]=(0,C.useState)(``),[c,l]=(0,C.useState)(0),u=Jt({presets:e,query:o,epics:t,cards:n,favouriteKeys:r}),d=u.flatMap(e=>e.rows),f=d.length?Math.min(c,d.length-1):0;function p(e){d.length&&l(t=>(Math.min(t,d.length-1)+e+d.length)%d.length)}function m(e){if(e.key===`ArrowDown`){e.preventDefault(),p(1);return}if(e.key===`ArrowUp`){e.preventDefault(),p(-1);return}if(e.key===`Enter`){e.preventDefault();let t=d[f];t&&i(Yt(t))}}let h=0;return(0,G.jsx)(`div`,{className:`fixed inset-0 z-50 flex items-start justify-center bg-black/40 pt-[18vh]`,onMouseDown:a,children:(0,G.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,"aria-label":`Command`,className:`bg-popover text-popover-foreground h-fit w-full max-w-lg overflow-hidden rounded-xl border shadow-md`,onMouseDown:e=>e.stopPropagation(),children:[(0,G.jsxs)(`div`,{className:`flex h-11 items-center gap-2 border-b px-3`,children:[(0,G.jsx)(z,{className:`text-muted-foreground size-3.5 shrink-0`}),(0,G.jsx)(`input`,{autoFocus:!0,value:o,onChange:e=>{s(e.target.value),l(0)},onKeyDown:m,"aria-label":`Command`,placeholder:`Jump to Epic, Card, or Action`,className:`placeholder:text-muted-foreground h-11 min-w-0 flex-1 bg-transparent text-[13px] outline-none`}),o?null:(0,G.jsx)(`kbd`,{className:`text-muted-foreground rounded border px-1.5 py-0.5 text-[11px]`,children:`⌘K`})]}),u.length?(0,G.jsx)(`div`,{className:`max-h-[min(20rem,calc(82vh-3rem))] overflow-auto p-1`,children:u.map(e=>{let t=h;return h+=e.rows.length,(0,G.jsxs)(`div`,{children:[(0,G.jsx)(`div`,{className:`text-muted-foreground px-2 py-1.5 text-[11px] font-medium`,children:e.title}),e.rows.map((e,n)=>{let r=t+n;return(0,G.jsxs)(`button`,{type:`button`,"aria-label":e.key?`${e.key} ${e.label}`:e.label,className:W(`flex h-8 w-full items-center gap-2 rounded-lg px-2 text-left text-[13px]`,r===f?`bg-primary/20 text-foreground shadow-[inset_0_0_0_1px_var(--ring)]`:`hover:bg-foreground/5`),"aria-current":r===f?`true`:void 0,onMouseDown:e=>e.preventDefault(),onMouseEnter:()=>l(r),onClick:()=>i(Yt(e)),children:[e.key?(0,G.jsx)(`span`,{className:`text-muted-foreground shrink-0 text-[12px] font-medium tabular-nums`,children:e.key}):null,(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,children:e.label}),e.starred?(0,G.jsx)(ce,{className:`size-3.5 shrink-0 fill-current`}):null]},hE(e))})]},e.id)})}):null]})})}function _E({className:e,type:t,...n}){return(0,G.jsx)(`input`,{type:t,"data-slot":`input`,className:W(`border-input focus-visible:border-ring focus-visible:ring-ring/50 h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs outline-none focus-visible:ring-[3px] disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30`,`placeholder:text-muted-foreground`,e),...n})}function vE({draft:e,catalog:t,busy:n,error:r,onChange:i,onSubmit:a,onClose:o,onDraftWithAi:s}){let c=en(e,t),l=un(e,n);function u(t){let r=pn(t,e,n);if(r===`close`){t.preventDefault(),o();return}r===`submit`&&(t.preventDefault(),a())}return(0,G.jsx)(`div`,{className:`fixed inset-0 z-50 flex items-start justify-center bg-black/40 pt-[18vh]`,onMouseDown:o,children:(0,G.jsxs)(`div`,{role:`dialog`,"aria-modal":`true`,"aria-label":e.mode===`edit`?`Edit issue`:`Create issue`,className:`bg-popover text-popover-foreground w-full max-w-lg overflow-hidden rounded-xl border shadow-md`,onMouseDown:e=>e.stopPropagation(),onKeyDown:u,children:[(0,G.jsxs)(`div`,{className:`flex items-center gap-2 border-b px-3 py-2`,children:[(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-[13px] font-medium`,children:e.mode===`edit`?`Edit ${e.key}`:`Create issue`}),e.mode===`create`&&s?(0,G.jsxs)(q,{type:`button`,variant:`ghost`,size:`sm`,className:`h-7 text-[12px]`,onClick:s,children:[(0,G.jsx)(oe,{className:`size-3.5`}),`Draft with AI`]}):null]}),(0,G.jsxs)(`div`,{className:`flex flex-col gap-3 p-3`,children:[(0,G.jsx)(_E,{autoFocus:!0,value:e.title,onChange:t=>i({...e,title:t.target.value}),placeholder:`Issue title`,"aria-label":`Title`,className:`h-9 text-[13px]`}),(0,G.jsx)(`textarea`,{value:e.description,onChange:t=>i({...e,description:t.target.value}),placeholder:`Description`,"aria-label":`Description`,className:`border-input placeholder:text-muted-foreground min-h-24 w-full resize-y rounded-md border bg-transparent px-3 py-2 text-[13px] outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]`}),e.labels.length?(0,G.jsx)(`div`,{className:`flex flex-wrap gap-1.5`,children:e.labels.map(t=>(0,G.jsxs)(`span`,{className:`text-muted-foreground inline-flex h-6 items-center gap-1 rounded-full border px-2 text-[12px]`,children:[t,(0,G.jsx)(`button`,{type:`button`,"aria-label":`Remove ${t}`,className:`hover:text-foreground`,onClick:()=>i(rn(e,t)),children:(0,G.jsx)(de,{className:`size-3`})})]},t))}):null,c.length?(0,G.jsxs)(`div`,{className:`flex flex-col gap-1.5`,children:[(0,G.jsx)(`span`,{className:`text-muted-foreground text-[11px] font-medium`,children:`Suggested`}),(0,G.jsx)(`div`,{className:`flex flex-wrap gap-1.5`,children:c.map(t=>(0,G.jsxs)(`span`,{className:`inline-flex h-6 items-center gap-1 rounded-full border px-2 text-[12px]`,children:[t,(0,G.jsx)(`button`,{type:`button`,className:`text-primary text-[11px] font-medium`,onClick:()=>i(tn(e,t)),children:`Accept`}),(0,G.jsx)(`button`,{type:`button`,className:`text-muted-foreground text-[11px]`,onClick:()=>i(nn(e,t)),children:`Dismiss`})]},t))})]}):null,e.status?(0,G.jsxs)(`p`,{className:`text-muted-foreground text-[12px]`,children:[`Creates in `,e.status]}):null,e.epic?(0,G.jsxs)(`p`,{className:`text-muted-foreground text-[12px]`,children:[`Epic `,e.epic]}):null,r?(0,G.jsx)(`p`,{className:`text-destructive text-[13px] whitespace-pre-wrap`,children:r}):null]}),(0,G.jsxs)(`div`,{className:`flex items-center justify-end gap-2 border-t px-3 py-2`,children:[(0,G.jsx)(q,{type:`button`,variant:`ghost`,size:`sm`,onClick:o,children:`Cancel`}),(0,G.jsx)(q,{type:`button`,size:`sm`,disabled:!l,className:W(!l&&`opacity-50`),onClick:a,children:e.mode===`edit`?`Save`:`Create issue`})]})]})})}function yE({theme:e,...t}){return(0,G.jsx)(Ge,{theme:e,className:`toaster group`,position:`bottom-right`,style:{"--normal-bg":`var(--popover)`,"--normal-text":`var(--popover-foreground)`,"--normal-border":`var(--border)`},...t})}function bE({className:e,...t}){return(0,G.jsx)(L,{role:`status`,"aria-label":`Loading`,className:W(`size-4 animate-spin`,e),...t})}function xE(){var e=[...arguments];return(0,C.useMemo)(()=>t=>{e.forEach(e=>e(t))},e)}var SE=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function CE(e){let t=Object.prototype.toString.call(e);return t===`[object Window]`||t===`[object global]`}function wE(e){return`nodeType`in e}function TE(e){return e?CE(e)?e:wE(e)?e.ownerDocument?.defaultView??window:window:window}function EE(e){let{Document:t}=TE(e);return e instanceof t}function DE(e){return!CE(e)&&e instanceof TE(e).HTMLElement}function OE(e){return e instanceof TE(e).SVGElement}function kE(e){return e?CE(e)?e.document:wE(e)?EE(e)?e:DE(e)||OE(e)?e.ownerDocument:document:document:document}var AE=SE?C.useLayoutEffect:C.useEffect;function jE(e){let t=(0,C.useRef)(e);return AE(()=>{t.current=e}),(0,C.useCallback)(function(){var e=[...arguments];return t.current==null?void 0:t.current(...e)},[])}function ME(){let e=(0,C.useRef)(null);return[(0,C.useCallback)((t,n)=>{e.current=setInterval(t,n)},[]),(0,C.useCallback)(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[])]}function NE(e,t){t===void 0&&(t=[e]);let n=(0,C.useRef)(e);return AE(()=>{n.current!==e&&(n.current=e)},t),n}function PE(e,t){let n=(0,C.useRef)();return(0,C.useMemo)(()=>{let t=e(n.current);return n.current=t,t},[...t])}function FE(e){let t=jE(e),n=(0,C.useRef)(null);return[n,(0,C.useCallback)(e=>{e!==n.current&&t?.(e,n.current),n.current=e},[])]}function IE(e){let t=(0,C.useRef)();return(0,C.useEffect)(()=>{t.current=e},[e]),t.current}var LE={};function RE(e,t){return(0,C.useMemo)(()=>{if(t)return t;let n=LE[e]==null?0:LE[e]+1;return LE[e]=n,e+`-`+n},[e,t])}function zE(e){return function(t){return[...arguments].slice(1).reduce((t,n)=>{let r=Object.entries(n);for(let[n,i]of r){let r=t[n];r!=null&&(t[n]=r+e*i)}return t},{...t})}}var BE=zE(1),VE=zE(-1);function HE(e){return`clientX`in e&&`clientY`in e}function UE(e){if(!e)return!1;let{KeyboardEvent:t}=TE(e.target);return t&&e instanceof t}function WE(e){if(!e)return!1;let{TouchEvent:t}=TE(e.target);return t&&e instanceof t}function GE(e){if(WE(e)){if(e.touches&&e.touches.length){let{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}if(e.changedTouches&&e.changedTouches.length){let{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return HE(e)?{x:e.clientX,y:e.clientY}:null}var KE=Object.freeze({Translate:{toString(e){if(!e)return;let{x:t,y:n}=e;return`translate3d(`+(t?Math.round(t):0)+`px, `+(n?Math.round(n):0)+`px, 0)`}},Scale:{toString(e){if(!e)return;let{scaleX:t,scaleY:n}=e;return`scaleX(`+t+`) scaleY(`+n+`)`}},Transform:{toString(e){if(e)return[KE.Translate.toString(e),KE.Scale.toString(e)].join(` `)}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+` `+n+`ms `+r}}}),qE=`a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]`;function JE(e){return e.matches(qE)?e:e.querySelector(qE)}var YE={display:`none`};function XE(e){let{id:t,value:n}=e;return C.createElement(`div`,{id:t,style:YE},n)}function ZE(e){let{id:t,announcement:n,ariaLiveType:r=`assertive`}=e;return C.createElement(`div`,{id:t,style:{position:`fixed`,top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:`hidden`,clip:`rect(0 0 0 0)`,clipPath:`inset(100%)`,whiteSpace:`nowrap`},role:`status`,"aria-live":r,"aria-atomic":!0},n)}function QE(){let[e,t]=(0,C.useState)(``);return{announce:(0,C.useCallback)(e=>{e!=null&&t(e)},[]),announcement:e}}var $E=(0,C.createContext)(null);function eD(e){let t=(0,C.useContext)($E);(0,C.useEffect)(()=>{if(!t)throw Error(`useDndMonitor must be used within a children of <DndContext>`);return t(e)},[e,t])}function tD(){let[e]=(0,C.useState)(()=>new Set),t=(0,C.useCallback)(t=>(e.add(t),()=>e.delete(t)),[e]);return[(0,C.useCallback)(t=>{let{type:n,event:r}=t;e.forEach(e=>e[n]?.call(e,r))},[e]),t]}var nD={draggable:`
|
|
53
|
+
To pick up a draggable item, press the space bar.
|
|
54
|
+
While dragging, use the arrow keys to move the item.
|
|
55
|
+
Press space again to drop the item in its new position, or press escape to cancel.
|
|
56
|
+
`},rD={onDragStart(e){let{active:t}=e;return`Picked up draggable item `+t.id+`.`},onDragOver(e){let{active:t,over:n}=e;return n?`Draggable item `+t.id+` was moved over droppable area `+n.id+`.`:`Draggable item `+t.id+` is no longer over a droppable area.`},onDragEnd(e){let{active:t,over:n}=e;return n?`Draggable item `+t.id+` was dropped over droppable area `+n.id:`Draggable item `+t.id+` was dropped.`},onDragCancel(e){let{active:t}=e;return`Dragging was cancelled. Draggable item `+t.id+` was dropped.`}};function iD(e){let{announcements:t=rD,container:n,hiddenTextDescribedById:r,screenReaderInstructions:i=nD}=e,{announce:a,announcement:o}=QE(),s=RE(`DndLiveRegion`),[c,l]=(0,C.useState)(!1);if((0,C.useEffect)(()=>{l(!0)},[]),eD((0,C.useMemo)(()=>({onDragStart(e){let{active:n}=e;a(t.onDragStart({active:n}))},onDragMove(e){let{active:n,over:r}=e;t.onDragMove&&a(t.onDragMove({active:n,over:r}))},onDragOver(e){let{active:n,over:r}=e;a(t.onDragOver({active:n,over:r}))},onDragEnd(e){let{active:n,over:r}=e;a(t.onDragEnd({active:n,over:r}))},onDragCancel(e){let{active:n,over:r}=e;a(t.onDragCancel({active:n,over:r}))}}),[a,t])),!c)return null;let u=C.createElement(C.Fragment,null,C.createElement(XE,{id:r,value:i.draggable}),C.createElement(ZE,{id:s,announcement:o}));return n?(0,pe.createPortal)(u,n):u}var aD;(function(e){e.DragStart=`dragStart`,e.DragMove=`dragMove`,e.DragEnd=`dragEnd`,e.DragCancel=`dragCancel`,e.DragOver=`dragOver`,e.RegisterDroppable=`registerDroppable`,e.SetDroppableDisabled=`setDroppableDisabled`,e.UnregisterDroppable=`unregisterDroppable`})(aD||={});function oD(){}function sD(e,t){return(0,C.useMemo)(()=>({sensor:e,options:t??{}}),[e,t])}function cD(){var e=[...arguments];return(0,C.useMemo)(()=>[...e].filter(e=>e!=null),[...e])}var lD=Object.freeze({x:0,y:0});function uD(e,t){return Math.sqrt((e.x-t.x)**2+(e.y-t.y)**2)}function dD(e,t){let n=GE(e);if(!n)return`0 0`;let r={x:(n.x-t.left)/t.width*100,y:(n.y-t.top)/t.height*100};return r.x+`% `+r.y+`%`}function fD(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return n-r}function pD(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return r-n}function mD(e){let{left:t,top:n,height:r,width:i}=e;return[{x:t,y:n},{x:t+i,y:n},{x:t,y:n+r},{x:t+i,y:n+r}]}function hD(e,t){if(!e||e.length===0)return null;let[n]=e;return t?n[t]:n}var gD=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e,i=mD(t),a=[];for(let e of r){let{id:t}=e,r=n.get(t);if(r){let n=mD(r),o=i.reduce((e,t,r)=>e+uD(n[r],t),0),s=Number((o/4).toFixed(4));a.push({id:t,data:{droppableContainer:e,value:s}})}}return a.sort(fD)};function _D(e,t){let n=Math.max(t.top,e.top),r=Math.max(t.left,e.left),i=Math.min(t.left+t.width,e.left+e.width),a=Math.min(t.top+t.height,e.top+e.height),o=i-r,s=a-n;if(r<i&&n<a){let n=t.width*t.height,r=e.width*e.height,i=o*s,a=i/(n+r-i);return Number(a.toFixed(4))}return 0}var vD=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e,i=[];for(let e of r){let{id:r}=e,a=n.get(r);if(a){let n=_D(a,t);n>0&&i.push({id:r,data:{droppableContainer:e,value:n}})}}return i.sort(pD)};function yD(e,t,n){return{...e,scaleX:t&&n?t.width/n.width:1,scaleY:t&&n?t.height/n.height:1}}function bD(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:lD}function xD(e){return function(t){return[...arguments].slice(1).reduce((t,n)=>({...t,top:t.top+e*n.y,bottom:t.bottom+e*n.y,left:t.left+e*n.x,right:t.right+e*n.x}),{...t})}}var SD=xD(1);function CD(e){if(e.startsWith(`matrix3d(`)){let t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}if(e.startsWith(`matrix(`)){let t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}function wD(e,t,n){let r=CD(t);if(!r)return e;let{scaleX:i,scaleY:a,x:o,y:s}=r,c=e.left-o-(1-i)*parseFloat(n),l=e.top-s-(1-a)*parseFloat(n.slice(n.indexOf(` `)+1)),u=i?e.width/i:e.width,d=a?e.height/a:e.height;return{width:u,height:d,top:l,right:c+u,bottom:l+d,left:c}}var TD={ignoreTransform:!1};function ED(e,t){t===void 0&&(t=TD);let n=e.getBoundingClientRect();if(t.ignoreTransform){let{transform:t,transformOrigin:r}=TE(e).getComputedStyle(e);t&&(n=wD(n,t,r))}let{top:r,left:i,width:a,height:o,bottom:s,right:c}=n;return{top:r,left:i,width:a,height:o,bottom:s,right:c}}function DD(e){return ED(e,{ignoreTransform:!0})}function OD(e){let t=e.innerWidth,n=e.innerHeight;return{top:0,left:0,right:t,bottom:n,width:t,height:n}}function kD(e,t){return t===void 0&&(t=TE(e).getComputedStyle(e)),t.position===`fixed`}function AD(e,t){t===void 0&&(t=TE(e).getComputedStyle(e));let n=/(auto|scroll|overlay)/;return[`overflow`,`overflowX`,`overflowY`].some(e=>{let r=t[e];return typeof r==`string`&&n.test(r)})}function jD(e,t){let n=[];function r(i){if(t!=null&&n.length>=t||!i)return n;if(EE(i)&&i.scrollingElement!=null&&!n.includes(i.scrollingElement))return n.push(i.scrollingElement),n;if(!DE(i)||OE(i)||n.includes(i))return n;let a=TE(e).getComputedStyle(i);return i!==e&&AD(i,a)&&n.push(i),kD(i,a)?n:r(i.parentNode)}return e?r(e):n}function MD(e){let[t]=jD(e,1);return t??null}function ND(e){return!SE||!e?null:CE(e)?e:wE(e)?EE(e)||e===kE(e).scrollingElement?window:DE(e)?e:null:null}function PD(e){return CE(e)?e.scrollX:e.scrollLeft}function FD(e){return CE(e)?e.scrollY:e.scrollTop}function ID(e){return{x:PD(e),y:FD(e)}}var LD;(function(e){e[e.Forward=1]=`Forward`,e[e.Backward=-1]=`Backward`})(LD||={});function RD(e){return!SE||!e?!1:e===document.scrollingElement}function zD(e){let t={x:0,y:0},n=RD(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},r={x:e.scrollWidth-n.width,y:e.scrollHeight-n.height};return{isTop:e.scrollTop<=t.y,isLeft:e.scrollLeft<=t.x,isBottom:e.scrollTop>=r.y,isRight:e.scrollLeft>=r.x,maxScroll:r,minScroll:t}}var BD={x:.2,y:.2};function VD(e,t,n,r,i){let{top:a,left:o,right:s,bottom:c}=n;r===void 0&&(r=10),i===void 0&&(i=BD);let{isTop:l,isBottom:u,isLeft:d,isRight:f}=zD(e),p={x:0,y:0},m={x:0,y:0},h={height:t.height*i.y,width:t.width*i.x};return!l&&a<=t.top+h.height?(p.y=LD.Backward,m.y=r*Math.abs((t.top+h.height-a)/h.height)):!u&&c>=t.bottom-h.height&&(p.y=LD.Forward,m.y=r*Math.abs((t.bottom-h.height-c)/h.height)),!f&&s>=t.right-h.width?(p.x=LD.Forward,m.x=r*Math.abs((t.right-h.width-s)/h.width)):!d&&o<=t.left+h.width&&(p.x=LD.Backward,m.x=r*Math.abs((t.left+h.width-o)/h.width)),{direction:p,speed:m}}function HD(e){if(e===document.scrollingElement){let{innerWidth:e,innerHeight:t}=window;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}let{top:t,left:n,right:r,bottom:i}=e.getBoundingClientRect();return{top:t,left:n,right:r,bottom:i,width:e.clientWidth,height:e.clientHeight}}function UD(e){return e.reduce((e,t)=>BE(e,ID(t)),lD)}function WD(e){return e.reduce((e,t)=>e+PD(t),0)}function GD(e){return e.reduce((e,t)=>e+FD(t),0)}function KD(e,t){if(t===void 0&&(t=ED),!e)return;let{top:n,left:r,bottom:i,right:a}=t(e);MD(e)&&(i<=0||a<=0||n>=window.innerHeight||r>=window.innerWidth)&&e.scrollIntoView({block:`center`,inline:`center`})}var qD=[[`x`,[`left`,`right`],WD],[`y`,[`top`,`bottom`],GD]],JD=class{constructor(e,t){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;let n=jD(t),r=UD(n);this.rect={...e},this.width=e.width,this.height=e.height;for(let[e,t,i]of qD)for(let a of t)Object.defineProperty(this,a,{get:()=>{let t=i(n),o=r[e]-t;return this.rect[a]+o},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}},YD=class{constructor(e){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(e=>this.target?.removeEventListener(...e))},this.target=e}add(e,t,n){var r;(r=this.target)==null||r.addEventListener(e,t,n),this.listeners.push([e,t,n])}};function XD(e){let{EventTarget:t}=TE(e);return e instanceof t?e:kE(e)}function ZD(e,t){let n=Math.abs(e.x),r=Math.abs(e.y);return typeof t==`number`?Math.sqrt(n**2+r**2)>t:`x`in t&&`y`in t?n>t.x&&r>t.y:`x`in t?n>t.x:`y`in t&&r>t.y}var QD;(function(e){e.Click=`click`,e.DragStart=`dragstart`,e.Keydown=`keydown`,e.ContextMenu=`contextmenu`,e.Resize=`resize`,e.SelectionChange=`selectionchange`,e.VisibilityChange=`visibilitychange`})(QD||={});function $D(e){e.preventDefault()}function eO(e){e.stopPropagation()}var tO;(function(e){e.Space=`Space`,e.Down=`ArrowDown`,e.Right=`ArrowRight`,e.Left=`ArrowLeft`,e.Up=`ArrowUp`,e.Esc=`Escape`,e.Enter=`Enter`,e.Tab=`Tab`})(tO||={});var nO={start:[tO.Space,tO.Enter],cancel:[tO.Esc],end:[tO.Space,tO.Enter,tO.Tab]},rO=(e,t)=>{let{currentCoordinates:n}=t;switch(e.code){case tO.Right:return{...n,x:n.x+25};case tO.Left:return{...n,x:n.x-25};case tO.Down:return{...n,y:n.y+25};case tO.Up:return{...n,y:n.y-25}}},iO=class{constructor(e){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=e;let{event:{target:t}}=e;this.props=e,this.listeners=new YD(kE(t)),this.windowListeners=new YD(TE(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(QD.Resize,this.handleCancel),this.windowListeners.add(QD.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(QD.Keydown,this.handleKeyDown))}handleStart(){let{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&KD(n),t(lD)}handleKeyDown(e){if(UE(e)){let{active:t,context:n,options:r}=this.props,{keyboardCodes:i=nO,coordinateGetter:a=rO,scrollBehavior:o=`smooth`}=r,{code:s}=e;if(i.end.includes(s)){this.handleEnd(e);return}if(i.cancel.includes(s)){this.handleCancel(e);return}let{collisionRect:c}=n.current,l=c?{x:c.left,y:c.top}:lD;this.referenceCoordinates||=l;let u=a(e,{active:t,context:n.current,currentCoordinates:l});if(u){let t=VE(u,l),r={x:0,y:0},{scrollableAncestors:i}=n.current;for(let n of i){let i=e.code,{isTop:a,isRight:s,isLeft:c,isBottom:l,maxScroll:d,minScroll:f}=zD(n),p=HD(n),m={x:Math.min(i===tO.Right?p.right-p.width/2:p.right,Math.max(i===tO.Right?p.left:p.left+p.width/2,u.x)),y:Math.min(i===tO.Down?p.bottom-p.height/2:p.bottom,Math.max(i===tO.Down?p.top:p.top+p.height/2,u.y))},h=i===tO.Right&&!s||i===tO.Left&&!c,g=i===tO.Down&&!l||i===tO.Up&&!a;if(h&&m.x!==u.x){let e=n.scrollLeft+t.x,a=i===tO.Right&&e<=d.x||i===tO.Left&&e>=f.x;if(a&&!t.y){n.scrollTo({left:e,behavior:o});return}r.x=a?n.scrollLeft-e:i===tO.Right?n.scrollLeft-d.x:n.scrollLeft-f.x,r.x&&n.scrollBy({left:-r.x,behavior:o});break}if(g&&m.y!==u.y){let e=n.scrollTop+t.y,a=i===tO.Down&&e<=d.y||i===tO.Up&&e>=f.y;if(a&&!t.x){n.scrollTo({top:e,behavior:o});return}r.y=a?n.scrollTop-e:i===tO.Down?n.scrollTop-d.y:n.scrollTop-f.y,r.y&&n.scrollBy({top:-r.y,behavior:o});break}}this.handleMove(e,BE(VE(u,this.referenceCoordinates),r))}}}handleMove(e,t){let{onMove:n}=this.props;e.preventDefault(),n(t)}handleEnd(e){let{onEnd:t}=this.props;e.preventDefault(),this.detach(),t()}handleCancel(e){let{onCancel:t}=this.props;e.preventDefault(),this.detach(),t()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}};iO.activators=[{eventName:`onKeyDown`,handler:(e,t,n)=>{let{keyboardCodes:r=nO,onActivation:i}=t,{active:a}=n,{code:o}=e.nativeEvent;if(r.start.includes(o)){let t=a.activatorNode.current;return t&&e.target!==t?!1:(e.preventDefault(),i?.({event:e.nativeEvent}),!0)}return!1}}];function aO(e){return!!(e&&`distance`in e)}function oO(e){return!!(e&&`delay`in e)}var sO=class{constructor(e,t,n){n===void 0&&(n=XD(e.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=e,this.events=t;let{event:r}=e,{target:i}=r;this.props=e,this.events=t,this.document=kE(i),this.documentListeners=new YD(this.document),this.listeners=new YD(n),this.windowListeners=new YD(TE(i)),this.initialCoordinates=GE(r)??lD,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){let{events:e,props:{options:{activationConstraint:t,bypassActivationConstraint:n}}}=this;if(this.listeners.add(e.move.name,this.handleMove,{passive:!1}),this.listeners.add(e.end.name,this.handleEnd),e.cancel&&this.listeners.add(e.cancel.name,this.handleCancel),this.windowListeners.add(QD.Resize,this.handleCancel),this.windowListeners.add(QD.DragStart,$D),this.windowListeners.add(QD.VisibilityChange,this.handleCancel),this.windowListeners.add(QD.ContextMenu,$D),this.documentListeners.add(QD.Keydown,this.handleKeydown),t){if(n!=null&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(oO(t)){this.timeoutId=setTimeout(this.handleStart,t.delay),this.handlePending(t);return}if(aO(t)){this.handlePending(t);return}}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),this.timeoutId!==null&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handlePending(e,t){let{active:n,onPending:r}=this.props;r(n,e,this.initialCoordinates,t)}handleStart(){let{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(QD.Click,eO,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(QD.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){let{activated:t,initialCoordinates:n,props:r}=this,{onMove:i,options:{activationConstraint:a}}=r;if(!n)return;let o=GE(e)??lD,s=VE(n,o);if(!t&&a){if(aO(a)){if(a.tolerance!=null&&ZD(s,a.tolerance))return this.handleCancel();if(ZD(s,a.distance))return this.handleStart()}if(oO(a)&&ZD(s,a.tolerance))return this.handleCancel();this.handlePending(a,s);return}e.cancelable&&e.preventDefault(),i(o)}handleEnd(){let{onAbort:e,onEnd:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleCancel(){let{onAbort:e,onCancel:t}=this.props;this.detach(),this.activated||e(this.props.active),t()}handleKeydown(e){e.code===tO.Esc&&this.handleCancel()}removeTextSelection(){var e;(e=this.document.getSelection())==null||e.removeAllRanges()}},cO={cancel:{name:`pointercancel`},move:{name:`pointermove`},end:{name:`pointerup`}},lO=class extends sO{constructor(e){let{event:t}=e,n=kE(t.target);super(e,cO,n)}};lO.activators=[{eventName:`onPointerDown`,handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return!n.isPrimary||n.button!==0?!1:(r?.({event:n}),!0)}}];var uO={move:{name:`mousemove`},end:{name:`mouseup`}},dO;(function(e){e[e.RightClick=2]=`RightClick`})(dO||={});var fO=class extends sO{constructor(e){super(e,uO,kE(e.event.target))}};fO.activators=[{eventName:`onMouseDown`,handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return n.button!==dO.RightClick&&(r?.({event:n}),!0)}}];var pO={cancel:{name:`touchcancel`},move:{name:`touchmove`},end:{name:`touchend`}},mO=class extends sO{constructor(e){super(e,pO)}static setup(){return window.addEventListener(pO.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(pO.move.name,e)};function e(){}}};mO.activators=[{eventName:`onTouchStart`,handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t,{touches:i}=n;return i.length>1?!1:(r?.({event:n}),!0)}}];var hO;(function(e){e[e.Pointer=0]=`Pointer`,e[e.DraggableRect=1]=`DraggableRect`})(hO||={});var gO;(function(e){e[e.TreeOrder=0]=`TreeOrder`,e[e.ReversedTreeOrder=1]=`ReversedTreeOrder`})(gO||={});function _O(e){let{acceleration:t,activator:n=hO.Pointer,canScroll:r,draggingRect:i,enabled:a,interval:o=5,order:s=gO.TreeOrder,pointerCoordinates:c,scrollableAncestors:l,scrollableAncestorRects:u,delta:d,threshold:f}=e,p=yO({delta:d,disabled:!a}),[m,h]=ME(),g=(0,C.useRef)({x:0,y:0}),_=(0,C.useRef)({x:0,y:0}),v=(0,C.useMemo)(()=>{switch(n){case hO.Pointer:return c?{top:c.y,bottom:c.y,left:c.x,right:c.x}:null;case hO.DraggableRect:return i}},[n,i,c]),y=(0,C.useRef)(null),b=(0,C.useCallback)(()=>{let e=y.current;if(!e)return;let t=g.current.x*_.current.x,n=g.current.y*_.current.y;e.scrollBy(t,n)},[]),x=(0,C.useMemo)(()=>s===gO.TreeOrder?[...l].reverse():l,[s,l]);(0,C.useEffect)(()=>{if(!a||!l.length||!v){h();return}for(let e of x){if(r?.(e)===!1)continue;let n=l.indexOf(e),i=u[n];if(!i)continue;let{direction:a,speed:s}=VD(e,i,v,t,f);for(let e of[`x`,`y`])p[e][a[e]]||(s[e]=0,a[e]=0);if(s.x>0||s.y>0){h(),y.current=e,m(b,o),g.current=s,_.current=a;return}}g.current={x:0,y:0},_.current={x:0,y:0},h()},[t,b,r,h,a,o,JSON.stringify(v),JSON.stringify(p),m,l,x,u,JSON.stringify(f)])}var vO={x:{[LD.Backward]:!1,[LD.Forward]:!1},y:{[LD.Backward]:!1,[LD.Forward]:!1}};function yO(e){let{delta:t,disabled:n}=e,r=IE(t);return PE(e=>{if(n||!r||!e)return vO;let i={x:Math.sign(t.x-r.x),y:Math.sign(t.y-r.y)};return{x:{[LD.Backward]:e.x[LD.Backward]||i.x===-1,[LD.Forward]:e.x[LD.Forward]||i.x===1},y:{[LD.Backward]:e.y[LD.Backward]||i.y===-1,[LD.Forward]:e.y[LD.Forward]||i.y===1}}},[n,t,r])}function bO(e,t){let n=t==null?void 0:e.get(t),r=n?n.node.current:null;return PE(e=>t==null?null:r??e??null,[r,t])}function xO(e,t){return(0,C.useMemo)(()=>e.reduce((e,n)=>{let{sensor:r}=n,i=r.activators.map(e=>({eventName:e.eventName,handler:t(e.handler,n)}));return[...e,...i]},[]),[e,t])}var SO;(function(e){e[e.Always=0]=`Always`,e[e.BeforeDragging=1]=`BeforeDragging`,e[e.WhileDragging=2]=`WhileDragging`})(SO||={});var CO;(function(e){e.Optimized=`optimized`})(CO||={});var wO=new Map;function TO(e,t){let{dragging:n,dependencies:r,config:i}=t,[a,o]=(0,C.useState)(null),{frequency:s,measure:c,strategy:l}=i,u=(0,C.useRef)(e),d=g(),f=NE(d),p=(0,C.useCallback)(function(e){e===void 0&&(e=[]),!f.current&&o(t=>t===null?e:t.concat(e.filter(e=>!t.includes(e))))},[f]),m=(0,C.useRef)(null),h=PE(t=>{if(d&&!n)return wO;if(!t||t===wO||u.current!==e||a!=null){let t=new Map;for(let n of e){if(!n)continue;if(a&&a.length>0&&!a.includes(n.id)&&n.rect.current){t.set(n.id,n.rect.current);continue}let e=n.node.current,r=e?new JD(c(e),e):null;n.rect.current=r,r&&t.set(n.id,r)}return t}return t},[e,a,n,d,c]);return(0,C.useEffect)(()=>{u.current=e},[e]),(0,C.useEffect)(()=>{d||p()},[n,d]),(0,C.useEffect)(()=>{a&&a.length>0&&o(null)},[JSON.stringify(a)]),(0,C.useEffect)(()=>{d||typeof s!=`number`||m.current!==null||(m.current=setTimeout(()=>{p(),m.current=null},s))},[s,d,p,...r]),{droppableRects:h,measureDroppableContainers:p,measuringScheduled:a!=null};function g(){switch(l){case SO.Always:return!1;case SO.BeforeDragging:return n;default:return!n}}}function EO(e,t){return PE(n=>e?n||(typeof t==`function`?t(e):e):null,[t,e])}function DO(e,t){return EO(e,t)}function OO(e){let{callback:t,disabled:n}=e,r=jE(t),i=(0,C.useMemo)(()=>{if(n||typeof window>`u`||window.MutationObserver===void 0)return;let{MutationObserver:e}=window;return new e(r)},[r,n]);return(0,C.useEffect)(()=>()=>i?.disconnect(),[i]),i}function kO(e){let{callback:t,disabled:n}=e,r=jE(t),i=(0,C.useMemo)(()=>{if(n||typeof window>`u`||window.ResizeObserver===void 0)return;let{ResizeObserver:e}=window;return new e(r)},[n]);return(0,C.useEffect)(()=>()=>i?.disconnect(),[i]),i}function AO(e){return new JD(ED(e),e)}function jO(e,t,n){t===void 0&&(t=AO);let[r,i]=(0,C.useState)(null);function a(){i(r=>{if(!e)return null;if(e.isConnected===!1)return r??n??null;let i=t(e);return JSON.stringify(r)===JSON.stringify(i)?r:i})}let o=OO({callback(t){if(e)for(let n of t){let{type:t,target:r}=n;if(t===`childList`&&r instanceof HTMLElement&&r.contains(e)){a();break}}}}),s=kO({callback:a});return AE(()=>{a(),e?(s?.observe(e),o?.observe(document.body,{childList:!0,subtree:!0})):(s?.disconnect(),o?.disconnect())},[e]),r}function MO(e){return bD(e,EO(e))}var NO=[];function PO(e){let t=(0,C.useRef)(e),n=PE(n=>e?n&&n!==NO&&e&&t.current&&e.parentNode===t.current.parentNode?n:jD(e):NO,[e]);return(0,C.useEffect)(()=>{t.current=e},[e]),n}function FO(e){let[t,n]=(0,C.useState)(null),r=(0,C.useRef)(e),i=(0,C.useCallback)(e=>{let t=ND(e.target);t&&n(e=>e?(e.set(t,ID(t)),new Map(e)):null)},[]);return(0,C.useEffect)(()=>{let t=r.current;if(e!==t){a(t);let o=e.map(e=>{let t=ND(e);return t?(t.addEventListener(`scroll`,i,{passive:!0}),[t,ID(t)]):null}).filter(e=>e!=null);n(o.length?new Map(o):null),r.current=e}return()=>{a(e),a(t)};function a(e){e.forEach(e=>{ND(e)?.removeEventListener(`scroll`,i)})}},[i,e]),(0,C.useMemo)(()=>e.length?t?Array.from(t.values()).reduce((e,t)=>BE(e,t),lD):UD(e):lD,[e,t])}function IO(e,t){t===void 0&&(t=[]);let n=(0,C.useRef)(null);return(0,C.useEffect)(()=>{n.current=null},t),(0,C.useEffect)(()=>{let t=e!==lD;t&&!n.current&&(n.current=e),!t&&n.current&&(n.current=null)},[e]),n.current?VE(e,n.current):lD}function LO(e){(0,C.useEffect)(()=>{if(!SE)return;let t=e.map(e=>{let{sensor:t}=e;return t.setup==null?void 0:t.setup()});return()=>{for(let e of t)e?.()}},e.map(e=>{let{sensor:t}=e;return t}))}function RO(e,t){return(0,C.useMemo)(()=>e.reduce((e,n)=>{let{eventName:r,handler:i}=n;return e[r]=e=>{i(e,t)},e},{}),[e,t])}function zO(e){return(0,C.useMemo)(()=>e?OD(e):null,[e])}var BO=[];function VO(e,t){t===void 0&&(t=ED);let[n]=e,r=zO(n?TE(n):null),[i,a]=(0,C.useState)(BO);function o(){a(()=>e.length?e.map(e=>RD(e)?r:new JD(t(e),e)):BO)}let s=kO({callback:o});return AE(()=>{s?.disconnect(),o(),e.forEach(e=>s?.observe(e))},[e]),i}function HO(e){if(!e)return null;if(e.children.length>1)return e;let t=e.children[0];return DE(t)?t:e}function UO(e){let{measure:t}=e,[n,r]=(0,C.useState)(null),i=kO({callback:(0,C.useCallback)(e=>{for(let{target:n}of e)if(DE(n)){r(e=>{let r=t(n);return e?{...e,width:r.width,height:r.height}:r});break}},[t])}),[a,o]=FE((0,C.useCallback)(e=>{let n=HO(e);i?.disconnect(),n&&i?.observe(n),r(n?t(n):null)},[t,i]));return(0,C.useMemo)(()=>({nodeRef:a,rect:n,setRef:o}),[n,a,o])}var WO=[{sensor:lO,options:{}},{sensor:iO,options:{}}],GO={current:{}},KO={draggable:{measure:DD},droppable:{measure:DD,strategy:SO.WhileDragging,frequency:CO.Optimized},dragOverlay:{measure:ED}},qO=class extends Map{get(e){return e==null?void 0:super.get(e)??void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter(e=>{let{disabled:t}=e;return!t})}getNodeFor(e){return this.get(e)?.node.current??void 0}},JO={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new qO,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:oD},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:KO,measureDroppableContainers:oD,windowRect:null,measuringScheduled:!1},YO={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:``},dispatch:oD,draggableNodes:new Map,over:null,measureDroppableContainers:oD},XO=(0,C.createContext)(YO),ZO=(0,C.createContext)(JO);function QO(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new qO}}}function $O(e,t){switch(t.type){case aD.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case aD.DragMove:return e.draggable.active==null?e:{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}};case aD.DragEnd:case aD.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case aD.RegisterDroppable:{let{element:n}=t,{id:r}=n,i=new qO(e.droppable.containers);return i.set(r,n),{...e,droppable:{...e.droppable,containers:i}}}case aD.SetDroppableDisabled:{let{id:n,key:r,disabled:i}=t,a=e.droppable.containers.get(n);if(!a||r!==a.key)return e;let o=new qO(e.droppable.containers);return o.set(n,{...a,disabled:i}),{...e,droppable:{...e.droppable,containers:o}}}case aD.UnregisterDroppable:{let{id:n,key:r}=t,i=e.droppable.containers.get(n);if(!i||r!==i.key)return e;let a=new qO(e.droppable.containers);return a.delete(n),{...e,droppable:{...e.droppable,containers:a}}}default:return e}}function ek(e){let{disabled:t}=e,{active:n,activatorEvent:r,draggableNodes:i}=(0,C.useContext)(XO),a=IE(r),o=IE(n?.id);return(0,C.useEffect)(()=>{if(!t&&!r&&a&&o!=null){if(!UE(a)||document.activeElement===a.target)return;let e=i.get(o);if(!e)return;let{activatorNode:t,node:n}=e;if(!t.current&&!n.current)return;requestAnimationFrame(()=>{for(let e of[t.current,n.current]){if(!e)continue;let t=JE(e);if(t){t.focus();break}}})}},[r,t,i,o,a]),null}function tk(e,t){let{transform:n,...r}=t;return e!=null&&e.length?e.reduce((e,t)=>t({transform:e,...r}),n):n}function nk(e){return(0,C.useMemo)(()=>({draggable:{...KO.draggable,...e?.draggable},droppable:{...KO.droppable,...e?.droppable},dragOverlay:{...KO.dragOverlay,...e?.dragOverlay}}),[e?.draggable,e?.droppable,e?.dragOverlay])}function rk(e){let{activeNode:t,measure:n,initialRect:r,config:i=!0}=e,a=(0,C.useRef)(!1),{x:o,y:s}=typeof i==`boolean`?{x:i,y:i}:i;AE(()=>{if(!o&&!s||!t){a.current=!1;return}if(a.current||!r)return;let e=t?.node.current;if(!e||e.isConnected===!1)return;let i=bD(n(e),r);if(o||(i.x=0),s||(i.y=0),a.current=!0,Math.abs(i.x)>0||Math.abs(i.y)>0){let t=MD(e);t&&t.scrollBy({top:i.y,left:i.x})}},[t,o,s,r,n])}var ik=(0,C.createContext)({...lD,scaleX:1,scaleY:1}),ak;(function(e){e[e.Uninitialized=0]=`Uninitialized`,e[e.Initializing=1]=`Initializing`,e[e.Initialized=2]=`Initialized`})(ak||={});var ok=(0,C.memo)(function(e){let{id:t,accessibility:n,autoScroll:r=!0,children:i,sensors:a=WO,collisionDetection:o=vD,measuring:s,modifiers:c,...l}=e,[u,d]=(0,C.useReducer)($O,void 0,QO),[f,p]=tD(),[m,h]=(0,C.useState)(ak.Uninitialized),g=m===ak.Initialized,{draggable:{active:_,nodes:v,translate:y},droppable:{containers:b}}=u,x=_==null?null:v.get(_),S=(0,C.useRef)({initial:null,translated:null}),w=(0,C.useMemo)(()=>_==null?null:{id:_,data:x?.data??GO,rect:S},[_,x]),T=(0,C.useRef)(null),[E,D]=(0,C.useState)(null),[O,ee]=(0,C.useState)(null),k=NE(l,Object.values(l)),A=RE(`DndDescribedBy`,t),j=(0,C.useMemo)(()=>b.getEnabled(),[b]),M=nk(s),{droppableRects:te,measureDroppableContainers:N,measuringScheduled:P}=TO(j,{dragging:g,dependencies:[y.x,y.y],config:M.droppable}),F=bO(v,_),ne=(0,C.useMemo)(()=>O?GE(O):null,[O]),re=Ae(),ie=DO(F,M.draggable.measure);rk({activeNode:_==null?null:v.get(_),config:re.layoutShiftCompensation,initialRect:ie,measure:M.draggable.measure});let I=jO(F,M.draggable.measure,ie),L=jO(F?F.parentElement:null),R=(0,C.useRef)({activatorEvent:null,active:null,activeNode:F,collisionRect:null,collisions:null,droppableRects:te,draggableNodes:v,draggingNode:null,draggingNodeRect:null,droppableContainers:b,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),ae=b.getNodeFor(R.current.over?.id),z=UO({measure:M.dragOverlay.measure}),B=z.nodeRef.current??F,oe=g?z.rect??I:null,se=!!(z.nodeRef.current&&z.rect),ce=MO(se?null:I),le=zO(B?TE(B):null),ue=PO(g?ae??F:null),de=VO(ue),fe=tk(c,{transform:{x:y.x-ce.x,y:y.y-ce.y,scaleX:1,scaleY:1},activatorEvent:O,active:w,activeNodeRect:I,containerNodeRect:L,draggingNodeRect:oe,over:R.current.over,overlayNodeRect:z.rect,scrollableAncestors:ue,scrollableAncestorRects:de,windowRect:le}),me=ne?BE(ne,y):null,he=FO(ue),ge=IO(he),_e=IO(he,[I]),ve=BE(fe,ge),ye=oe?SD(oe,fe):null,be=w&&ye?o({active:w,collisionRect:ye,droppableRects:te,droppableContainers:j,pointerCoordinates:me}):null,xe=hD(be,`id`),[Se,Ce]=(0,C.useState)(null),we=yD(se?fe:BE(fe,_e),Se?.rect??null,I),Te=(0,C.useRef)(null),Ee=(0,C.useCallback)((e,t)=>{let{sensor:n,options:r}=t;if(T.current==null)return;let i=v.get(T.current);if(!i)return;let a=e.nativeEvent,o=new n({active:T.current,activeNode:i,event:a,options:r,context:R,onAbort(e){if(!v.get(e))return;let{onDragAbort:t}=k.current,n={id:e};t?.(n),f({type:`onDragAbort`,event:n})},onPending(e,t,n,r){if(!v.get(e))return;let{onDragPending:i}=k.current,a={id:e,constraint:t,initialCoordinates:n,offset:r};i?.(a),f({type:`onDragPending`,event:a})},onStart(e){let t=T.current;if(t==null)return;let n=v.get(t);if(!n)return;let{onDragStart:r}=k.current,i={activatorEvent:a,active:{id:t,data:n.data,rect:S}};(0,pe.unstable_batchedUpdates)(()=>{r?.(i),h(ak.Initializing),d({type:aD.DragStart,initialCoordinates:e,active:t}),f({type:`onDragStart`,event:i}),D(Te.current),ee(a)})},onMove(e){d({type:aD.DragMove,coordinates:e})},onEnd:s(aD.DragEnd),onCancel:s(aD.DragCancel)});Te.current=o;function s(e){return async function(){let{active:t,collisions:n,over:r,scrollAdjustedTranslate:i}=R.current,o=null;if(t&&i){let{cancelDrop:s}=k.current;o={activatorEvent:a,active:t,collisions:n,delta:i,over:r},e===aD.DragEnd&&typeof s==`function`&&await Promise.resolve(s(o))&&(e=aD.DragCancel)}T.current=null,(0,pe.unstable_batchedUpdates)(()=>{d({type:e}),h(ak.Uninitialized),Ce(null),D(null),ee(null),Te.current=null;let t=e===aD.DragEnd?`onDragEnd`:`onDragCancel`;if(o){let e=k.current[t];e?.(o),f({type:t,event:o})}})}}},[v]),De=xO(a,(0,C.useCallback)((e,t)=>(n,r)=>{let i=n.nativeEvent,a=v.get(r);if(T.current!==null||!a||i.dndKit||i.defaultPrevented)return;let o={active:a};e(n,t.options,o)===!0&&(i.dndKit={capturedBy:t.sensor},T.current=r,Ee(n,t))},[v,Ee]));LO(a),AE(()=>{I&&m===ak.Initializing&&h(ak.Initialized)},[I,m]),(0,C.useEffect)(()=>{let{onDragMove:e}=k.current,{active:t,activatorEvent:n,collisions:r,over:i}=R.current;if(!t||!n)return;let a={active:t,activatorEvent:n,collisions:r,delta:{x:ve.x,y:ve.y},over:i};(0,pe.unstable_batchedUpdates)(()=>{e?.(a),f({type:`onDragMove`,event:a})})},[ve.x,ve.y]),(0,C.useEffect)(()=>{let{active:e,activatorEvent:t,collisions:n,droppableContainers:r,scrollAdjustedTranslate:i}=R.current;if(!e||T.current==null||!t||!i)return;let{onDragOver:a}=k.current,o=r.get(xe),s=o&&o.rect.current?{id:o.id,rect:o.rect.current,data:o.data,disabled:o.disabled}:null,c={active:e,activatorEvent:t,collisions:n,delta:{x:i.x,y:i.y},over:s};(0,pe.unstable_batchedUpdates)(()=>{Ce(s),a?.(c),f({type:`onDragOver`,event:c})})},[xe]),AE(()=>{R.current={activatorEvent:O,active:w,activeNode:F,collisionRect:ye,collisions:be,droppableRects:te,draggableNodes:v,draggingNode:B,draggingNodeRect:oe,droppableContainers:b,over:Se,scrollableAncestors:ue,scrollAdjustedTranslate:ve},S.current={initial:oe,translated:ye}},[w,F,be,ye,v,B,oe,te,b,Se,ue,ve]),_O({...re,delta:y,draggingRect:ye,pointerCoordinates:me,scrollableAncestors:ue,scrollableAncestorRects:de});let Oe=(0,C.useMemo)(()=>({active:w,activeNode:F,activeNodeRect:I,activatorEvent:O,collisions:be,containerNodeRect:L,dragOverlay:z,draggableNodes:v,droppableContainers:b,droppableRects:te,over:Se,measureDroppableContainers:N,scrollableAncestors:ue,scrollableAncestorRects:de,measuringConfiguration:M,measuringScheduled:P,windowRect:le}),[w,F,I,O,be,L,z,v,b,te,Se,N,ue,de,M,P,le]),ke=(0,C.useMemo)(()=>({activatorEvent:O,activators:De,active:w,activeNodeRect:I,ariaDescribedById:{draggable:A},dispatch:d,draggableNodes:v,over:Se,measureDroppableContainers:N}),[O,De,w,I,d,A,v,Se,N]);return C.createElement($E.Provider,{value:p},C.createElement(XO.Provider,{value:ke},C.createElement(ZO.Provider,{value:Oe},C.createElement(ik.Provider,{value:we},i)),C.createElement(ek,{disabled:n?.restoreFocus===!1})),C.createElement(iD,{...n,hiddenTextDescribedById:A}));function Ae(){let e=E?.autoScrollEnabled===!1,t=typeof r==`object`?r.enabled===!1:r===!1,n=g&&!e&&!t;return typeof r==`object`?{...r,enabled:n}:{enabled:n}}}),sk=(0,C.createContext)(null),ck=`button`,lk=`Draggable`;function uk(e){let{id:t,data:n,disabled:r=!1,attributes:i}=e,a=RE(lk),{activators:o,activatorEvent:s,active:c,activeNodeRect:l,ariaDescribedById:u,draggableNodes:d,over:f}=(0,C.useContext)(XO),{role:p=ck,roleDescription:m=`draggable`,tabIndex:h=0}=i??{},g=c?.id===t,_=(0,C.useContext)(g?ik:sk),[v,y]=FE(),[b,x]=FE(),S=RO(o,t),w=NE(n);return AE(()=>(d.set(t,{id:t,key:a,node:v,activatorNode:b,data:w}),()=>{let e=d.get(t);e&&e.key===a&&d.delete(t)}),[d,t]),{active:c,activatorEvent:s,activeNodeRect:l,attributes:(0,C.useMemo)(()=>({role:p,tabIndex:h,"aria-disabled":r,"aria-pressed":g&&p===ck?!0:void 0,"aria-roledescription":m,"aria-describedby":u.draggable}),[r,p,h,g,m,u.draggable]),isDragging:g,listeners:r?void 0:S,node:v,over:f,setNodeRef:y,setActivatorNodeRef:x,transform:_}}function dk(){return(0,C.useContext)(ZO)}var fk=`Droppable`,pk={timeout:25};function mk(e){let{data:t,disabled:n=!1,id:r,resizeObserverConfig:i}=e,a=RE(fk),{active:o,dispatch:s,over:c,measureDroppableContainers:l}=(0,C.useContext)(XO),u=(0,C.useRef)({disabled:n}),d=(0,C.useRef)(!1),f=(0,C.useRef)(null),p=(0,C.useRef)(null),{disabled:m,updateMeasurementsFor:h,timeout:g}={...pk,...i},_=NE(h??r),v=kO({callback:(0,C.useCallback)(()=>{if(!d.current){d.current=!0;return}p.current!=null&&clearTimeout(p.current),p.current=setTimeout(()=>{l(Array.isArray(_.current)?_.current:[_.current]),p.current=null},g)},[g]),disabled:m||!o}),[y,b]=FE((0,C.useCallback)((e,t)=>{v&&(t&&(v.unobserve(t),d.current=!1),e&&v.observe(e))},[v])),x=NE(t);return(0,C.useEffect)(()=>{v&&y.current&&(v.disconnect(),d.current=!1,v.observe(y.current))},[y,v]),(0,C.useEffect)(()=>(s({type:aD.RegisterDroppable,element:{id:r,key:a,disabled:n,node:y,rect:f,data:x}}),()=>s({type:aD.UnregisterDroppable,key:a,id:r})),[r]),(0,C.useEffect)(()=>{n!==u.current.disabled&&(s({type:aD.SetDroppableDisabled,id:r,key:a,disabled:n}),u.current.disabled=n)},[r,a,n,s]),{active:o,rect:f,isOver:c?.id===r,node:y,over:c,setNodeRef:b}}function hk(e){let{animation:t,children:n}=e,[r,i]=(0,C.useState)(null),[a,o]=(0,C.useState)(null),s=IE(n);return!n&&!r&&s&&i(s),AE(()=>{if(!a)return;let e=r?.key,n=r?.props.id;if(e==null||n==null){i(null);return}Promise.resolve(t(n,a)).then(()=>{i(null)})},[t,r,a]),C.createElement(C.Fragment,null,n,r?(0,C.cloneElement)(r,{ref:o}):null)}var gk={x:0,y:0,scaleX:1,scaleY:1};function _k(e){let{children:t}=e;return C.createElement(XO.Provider,{value:YO},C.createElement(ik.Provider,{value:gk},t))}var vk={position:`fixed`,touchAction:`none`},yk=e=>UE(e)?`transform 250ms ease`:void 0,bk=(0,C.forwardRef)((e,t)=>{let{as:n,activatorEvent:r,adjustScale:i,children:a,className:o,rect:s,style:c,transform:l,transition:u=yk}=e;if(!s)return null;let d=i?l:{...l,scaleX:1,scaleY:1},f={...vk,width:s.width,height:s.height,top:s.top,left:s.left,transform:KE.Transform.toString(d),transformOrigin:i&&r?dD(r,s):void 0,transition:typeof u==`function`?u(r):u,...c};return C.createElement(n,{className:o,style:f,ref:t},a)}),xk=e=>t=>{let{active:n,dragOverlay:r}=t,i={},{styles:a,className:o}=e;if(a!=null&&a.active)for(let[e,t]of Object.entries(a.active))t!==void 0&&(i[e]=n.node.style.getPropertyValue(e),n.node.style.setProperty(e,t));if(a!=null&&a.dragOverlay)for(let[e,t]of Object.entries(a.dragOverlay))t!==void 0&&r.node.style.setProperty(e,t);return o!=null&&o.active&&n.node.classList.add(o.active),o!=null&&o.dragOverlay&&r.node.classList.add(o.dragOverlay),function(){for(let[e,t]of Object.entries(i))n.node.style.setProperty(e,t);o!=null&&o.active&&n.node.classList.remove(o.active)}},Sk={duration:250,easing:`ease`,keyframes:e=>{let{transform:{initial:t,final:n}}=e;return[{transform:KE.Transform.toString(t)},{transform:KE.Transform.toString(n)}]},sideEffects:xk({styles:{active:{opacity:`0`}}})};function Ck(e){let{config:t,draggableNodes:n,droppableContainers:r,measuringConfiguration:i}=e;return jE((e,a)=>{if(t===null)return;let o=n.get(e);if(!o)return;let s=o.node.current;if(!s)return;let c=HO(a);if(!c)return;let{transform:l}=TE(a).getComputedStyle(a),u=CD(l);if(!u)return;let d=typeof t==`function`?t:wk(t);return KD(s,i.draggable.measure),d({active:{id:e,data:o.data,node:s,rect:i.draggable.measure(s)},draggableNodes:n,dragOverlay:{node:a,rect:i.dragOverlay.measure(c)},droppableContainers:r,measuringConfiguration:i,transform:u})})}function wk(e){let{duration:t,easing:n,sideEffects:r,keyframes:i}={...Sk,...e};return e=>{let{active:a,dragOverlay:o,transform:s,...c}=e;if(!t)return;let l={x:o.rect.left-a.rect.left,y:o.rect.top-a.rect.top},u={scaleX:s.scaleX===1?1:a.rect.width*s.scaleX/o.rect.width,scaleY:s.scaleY===1?1:a.rect.height*s.scaleY/o.rect.height},d={x:s.x-l.x,y:s.y-l.y,...u},f=i({...c,active:a,dragOverlay:o,transform:{initial:s,final:d}}),[p]=f,m=f[f.length-1];if(JSON.stringify(p)===JSON.stringify(m))return;let h=r?.({active:a,dragOverlay:o,...c}),g=o.node.animate(f,{duration:t,easing:n,fill:`forwards`});return new Promise(e=>{g.onfinish=()=>{h?.(),e()}})}}var Tk=0;function Ek(e){return(0,C.useMemo)(()=>{if(e!=null)return Tk++,Tk},[e])}var Dk=C.memo(e=>{let{adjustScale:t=!1,children:n,dropAnimation:r,style:i,transition:a,modifiers:o,wrapperElement:s=`div`,className:c,zIndex:l=999}=e,{activatorEvent:u,active:d,activeNodeRect:f,containerNodeRect:p,draggableNodes:m,droppableContainers:h,dragOverlay:g,over:_,measuringConfiguration:v,scrollableAncestors:y,scrollableAncestorRects:b,windowRect:x}=dk(),S=(0,C.useContext)(ik),w=Ek(d?.id),T=tk(o,{activatorEvent:u,active:d,activeNodeRect:f,containerNodeRect:p,draggingNodeRect:g.rect,over:_,overlayNodeRect:g.rect,scrollableAncestors:y,scrollableAncestorRects:b,transform:S,windowRect:x}),E=EO(f),D=Ck({config:r,draggableNodes:m,droppableContainers:h,measuringConfiguration:v}),O=E?g.setRef:void 0;return C.createElement(_k,null,C.createElement(hk,{animation:D},d&&w?C.createElement(bk,{key:w,id:d.id,ref:O,as:s,activatorEvent:u,adjustScale:t,className:c,transition:a,rect:E,style:{zIndex:l,...i},transform:T},n):null))});function Ok(e,t,n){let r=e.slice();return r.splice(n<0?r.length+n:n,0,r.splice(t,1)[0]),r}function kk(e,t){return e.reduce((e,n,r)=>{let i=t.get(n);return i&&(e[r]=i),e},Array(e.length))}function Ak(e){return e!==null&&e>=0}function jk(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function Mk(e){return typeof e==`boolean`?{draggable:e,droppable:e}:e}var Nk=e=>{let{rects:t,activeIndex:n,overIndex:r,index:i}=e,a=Ok(t,r,n),o=t[i],s=a[i];return!s||!o?null:{x:s.left-o.left,y:s.top-o.top,scaleX:s.width/o.width,scaleY:s.height/o.height}},Pk={scaleX:1,scaleY:1},Fk=e=>{let{activeIndex:t,activeNodeRect:n,index:r,rects:i,overIndex:a}=e,o=i[t]??n;if(!o)return null;if(r===t){let e=i[a];return e?{x:0,y:t<a?e.top+e.height-(o.top+o.height):e.top-o.top,...Pk}:null}let s=Ik(i,r,t);return r>t&&r<=a?{x:0,y:-o.height-s,...Pk}:r<t&&r>=a?{x:0,y:o.height+s,...Pk}:{x:0,y:0,...Pk}};function Ik(e,t,n){let r=e[t],i=e[t-1],a=e[t+1];return r?n<t?i?r.top-(i.top+i.height):a?a.top-(r.top+r.height):0:a?a.top-(r.top+r.height):i?r.top-(i.top+i.height):0:0}var Lk=`Sortable`,Rk=C.createContext({activeIndex:-1,containerId:Lk,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:Nk,disabled:{draggable:!1,droppable:!1}});function zk(e){let{children:t,id:n,items:r,strategy:i=Nk,disabled:a=!1}=e,{active:o,dragOverlay:s,droppableRects:c,over:l,measureDroppableContainers:u}=dk(),d=RE(Lk,n),f=s.rect!==null,p=(0,C.useMemo)(()=>r.map(e=>typeof e==`object`&&`id`in e?e.id:e),[r]),m=o!=null,h=o?p.indexOf(o.id):-1,g=l?p.indexOf(l.id):-1,_=(0,C.useRef)(p),v=!jk(p,_.current),y=g!==-1&&h===-1||v,b=Mk(a);AE(()=>{v&&m&&u(p)},[v,p,m,u]),(0,C.useEffect)(()=>{_.current=p},[p]);let x=(0,C.useMemo)(()=>({activeIndex:h,containerId:d,disabled:b,disableTransforms:y,items:p,overIndex:g,useDragOverlay:f,sortedRects:kk(p,c),strategy:i}),[h,d,b.draggable,b.droppable,y,p,g,c,f,i]);return C.createElement(Rk.Provider,{value:x},t)}var Bk=e=>{let{id:t,items:n,activeIndex:r,overIndex:i}=e;return Ok(n,r,i).indexOf(t)},Vk=e=>{let{containerId:t,isSorting:n,wasDragging:r,index:i,items:a,newIndex:o,previousItems:s,previousContainerId:c,transition:l}=e;return!l||!r||s!==a&&i===o?!1:n?!0:o!==i&&t===c},Hk={duration:200,easing:`ease`},Uk=`transform`,Wk=KE.Transition.toString({property:Uk,duration:0,easing:`linear`}),Gk={roleDescription:`sortable`};function Kk(e){let{disabled:t,index:n,node:r,rect:i}=e,[a,o]=(0,C.useState)(null),s=(0,C.useRef)(n);return AE(()=>{if(!t&&n!==s.current&&r.current){let e=i.current;if(e){let t=ED(r.current,{ignoreTransform:!0}),n={x:e.left-t.left,y:e.top-t.top,scaleX:e.width/t.width,scaleY:e.height/t.height};(n.x||n.y)&&o(n)}}n!==s.current&&(s.current=n)},[t,n,r,i]),(0,C.useEffect)(()=>{a&&o(null)},[a]),a}function qk(e){let{animateLayoutChanges:t=Vk,attributes:n,disabled:r,data:i,getNewIndex:a=Bk,id:o,strategy:s,resizeObserverConfig:c,transition:l=Hk}=e,{items:u,containerId:d,activeIndex:f,disabled:p,disableTransforms:m,sortedRects:h,overIndex:g,useDragOverlay:_,strategy:v}=(0,C.useContext)(Rk),y=Jk(r,p),b=u.indexOf(o),x=(0,C.useMemo)(()=>({sortable:{containerId:d,index:b,items:u},...i}),[d,i,b,u]),S=(0,C.useMemo)(()=>u.slice(u.indexOf(o)),[u,o]),{rect:w,node:T,isOver:E,setNodeRef:D}=mk({id:o,data:x,disabled:y.droppable,resizeObserverConfig:{updateMeasurementsFor:S,...c}}),{active:O,activatorEvent:ee,activeNodeRect:k,attributes:A,setNodeRef:j,listeners:M,isDragging:te,over:N,setActivatorNodeRef:P,transform:F}=uk({id:o,data:x,attributes:{...Gk,...n},disabled:y.draggable}),ne=xE(D,j),re=!!O,ie=re&&!m&&Ak(f)&&Ak(g),I=!_&&te,L=ie?(I&&ie?F:null)??(s??v)({rects:h,activeNodeRect:k,activeIndex:f,overIndex:g,index:b}):null,R=Ak(f)&&Ak(g)?a({id:o,items:u,activeIndex:f,overIndex:g}):b,ae=O?.id,z=(0,C.useRef)({activeId:ae,items:u,newIndex:R,containerId:d}),B=u!==z.current.items,oe=t({active:O,containerId:d,isDragging:te,isSorting:re,id:o,index:b,items:u,newIndex:z.current.newIndex,previousItems:z.current.items,previousContainerId:z.current.containerId,transition:l,wasDragging:z.current.activeId!=null}),se=Kk({disabled:!oe,index:b,node:T,rect:w});return(0,C.useEffect)(()=>{re&&z.current.newIndex!==R&&(z.current.newIndex=R),d!==z.current.containerId&&(z.current.containerId=d),u!==z.current.items&&(z.current.items=u)},[re,R,d,u]),(0,C.useEffect)(()=>{if(ae===z.current.activeId)return;if(ae!=null&&z.current.activeId==null){z.current.activeId=ae;return}let e=setTimeout(()=>{z.current.activeId=ae},50);return()=>clearTimeout(e)},[ae]),{active:O,activeIndex:f,attributes:A,data:x,rect:w,index:b,newIndex:R,items:u,isOver:E,isSorting:re,isDragging:te,listeners:M,node:T,overIndex:g,over:N,setNodeRef:ne,setActivatorNodeRef:P,setDroppableNodeRef:D,setDraggableNodeRef:j,transform:se??L,transition:ce()};function ce(){if(se||B&&z.current.newIndex===b)return Wk;if(!(I&&!UE(ee)||!l)&&(re||oe))return KE.Transition.toString({...l,property:Uk})}}function Jk(e,t){return typeof e==`boolean`?{draggable:e,droppable:!1}:{draggable:e?.draggable??t.draggable,droppable:e?.droppable??t.droppable}}function Yk(e){if(!e)return!1;let t=e.data.current;return!!(t&&`sortable`in t&&typeof t.sortable==`object`&&`containerId`in t.sortable&&`items`in t.sortable&&`index`in t.sortable)}var Xk=[tO.Down,tO.Right,tO.Up,tO.Left],Zk=(e,t)=>{let{context:{active:n,collisionRect:r,droppableRects:i,droppableContainers:a,over:o,scrollableAncestors:s}}=t;if(Xk.includes(e.code)){if(e.preventDefault(),!n||!r)return;let t=[];a.getEnabled().forEach(n=>{if(!n||n!=null&&n.disabled)return;let a=i.get(n.id);if(a)switch(e.code){case tO.Down:r.top<a.top&&t.push(n);break;case tO.Up:r.top>a.top&&t.push(n);break;case tO.Left:r.left>a.left&&t.push(n);break;case tO.Right:r.left<a.left&&t.push(n)}});let c=gD({active:n,collisionRect:r,droppableRects:i,droppableContainers:t,pointerCoordinates:null}),l=hD(c,`id`);if(l===o?.id&&c.length>1&&(l=c[1].id),l!=null){let e=a.get(n.id),t=a.get(l),o=t?i.get(t.id):null,c=t?.node.current;if(c&&o&&e&&t){let n=jD(c).some((e,t)=>s[t]!==e),i=Qk(e,t),a=$k(e,t),l=n||!i?{x:0,y:0}:{x:a?r.width-o.width:0,y:a?r.height-o.height:0},u={x:o.left,y:o.top};return l.x&&l.y?u:VE(u,l)}}}};function Qk(e,t){return!Yk(e)||!Yk(t)?!1:e.data.current.sortable.containerId===t.data.current.sortable.containerId}function $k(e,t){return!Yk(e)||!Yk(t)||!Qk(e,t)?!1:e.data.current.sortable.index<t.data.current.sortable.index}var eA=(0,C.createContext)({columns:{},setColumns:()=>{},getItemId:()=>``,columnIds:[],activeId:null,setActiveId:()=>{},findContainer:()=>void 0,isColumn:()=>!1,modifiers:void 0}),tA=(0,C.createContext)({attributes:{},listeners:void 0,isDragging:!1,disabled:!1}),nA=(0,C.createContext)({listeners:void 0,isDragging:!1,disabled:!1}),rA=(0,C.createContext)(!1),iA=e=>Vk({...e,wasDragging:!0}),aA={sideEffects:xk({styles:{active:{opacity:`0.4`}}})},oA=()=>()=>{},sA=()=>!0,cA=()=>!1,lA={activationConstraint:{distance:10}},uA={activationConstraint:{delay:250,tolerance:5}},dA={coordinateGetter:Zk},fA={droppable:{strategy:SO.Always}};function pA({value:e,onValueChange:t,getItemValue:n,children:r,className:i,asChild:a=!1,onMove:o,onValueCommit:s,restoreOnCancel:c=!1,onDragStart:l,onDragEnd:u,onDragCancel:d,accessibility:f,modifiers:p,...m}){let h=e,g=t,[_,v]=(0,C.useState)(null),y=(0,C.useRef)(e),b=(0,C.useRef)(n);(0,C.useLayoutEffect)(()=>{y.current=e,b.current=n});let x=(0,C.useRef)(null),S=cD(sD(fO,lA),sD(mO,uA),sD(iO,dA)),w=(0,C.useMemo)(()=>Object.keys(h),[h,n]),T=(0,C.useCallback)(e=>w.includes(e),[w]),E=(0,C.useCallback)(e=>T(e)?e:w.find(t=>h[t].some(t=>n(t)===e)),[h,w,n,T]),D=(0,C.useCallback)((e,t,n)=>{if(!s)return;let r=x.current;if(!r)return;let i=t.active.id;if(n===`column`){let n=Object.keys(e).indexOf(i);if(n===-1||n===r.index)return;s(e,{kind:`column`,event:t,activeContainer:i,activeIndex:r.index,overContainer:String(t.over?.id??i),overIndex:n,previousValue:r.value});return}let a=b.current,o,c=-1;for(let t of Object.keys(e)){let n=e[t].findIndex(e=>a(e)===i);if(n!==-1){o=t,c=n;break}}o!==void 0&&(o!==r.container||c!==r.index)&&s(e,{kind:`item`,event:t,activeContainer:r.container??o,activeIndex:r.index,overContainer:o,overIndex:c,previousValue:r.value})},[s]),O=(0,C.useCallback)(e=>{if(v(e.active.id),l?.(e),s||c){let t=y.current,n=e.active.id,r=Object.keys(t);if(r.includes(n))x.current={value:t,container:n,index:r.indexOf(n)};else{let e=b.current,i,a=-1;for(let o of r){let r=t[o].findIndex(t=>e(t)===n);if(r!==-1){i=o,a=r;break}}x.current={value:t,container:i,index:a}}}},[l,s,c]),ee=(0,C.useCallback)(e=>{if(o)return;let{active:t,over:r}=e;if(!r||T(t.id))return;let i=E(t.id),a=E(r.id);if(i&&a){if(i!==a){let e=h[i],o=h[a],s=e.findIndex(e=>n(e)===t.id),c=o.findIndex(e=>n(e)===r.id);T(r.id)&&(c=o.length);let l=[...e],u=[...o],[d]=l.splice(s,1);u.splice(c,0,d),g({...h,[i]:l,[a]:u})}else{let e=i,a=h[e].findIndex(e=>n(e)===t.id),o=h[e].findIndex(e=>n(e)===r.id);a!==o&&g({...h,[e]:Ok(h[e],a,o)})}}},[E,n,T,g,h,o]),k=(0,C.useCallback)(e=>{let t=x.current;c&&t&&!o?g(t.value):s&&t&&!o&&D(y.current,e,`item`),x.current=null,v(null),d?.(e)},[c,o,s,g,d,D]),A=(0,C.useCallback)(e=>{let{active:t,over:r}=e;if(v(null),u?.(e),!r){D(y.current,e,`item`),x.current=null;return}if(o&&!T(t.id)){let i=E(t.id),a=E(r.id);i&&a&&o({event:e,activeContainer:i,activeIndex:h[i].findIndex(e=>n(e)===t.id),overContainer:a,overIndex:T(r.id)?h[a].length:h[a].findIndex(e=>n(e)===r.id)}),x.current=null;return}if(T(t.id)&&T(r.id)){let n=w.indexOf(t.id),i=w.indexOf(r.id);if(n!==i){let t=Ok(Object.keys(h),n,i),r={};t.forEach(e=>{r[e]=h[e]}),g(r),D(r,e,`column`)}x.current=null;return}if(T(t.id)){x.current=null;return}let i=E(t.id),a=E(r.id);if(i&&a&&i===a){let a=i,o=h[a].findIndex(e=>n(e)===t.id),s=h[a].findIndex(e=>n(e)===r.id);if(o!==s){let t={...h,[a]:Ok(h[a],o,s)};g(t),D(t,e,`item`)}else D(h,e,`item`)}else D(h,e,`item`);x.current=null},[w,h,E,n,T,g,o,u,D]),j=(0,C.useMemo)(()=>({columns:h,setColumns:g,getItemId:n,columnIds:w,activeId:_,setActiveId:v,findContainer:E,isColumn:T,modifiers:p}),[h,g,n,w,_,E,T,p]),M=a?K:`div`;return(0,G.jsx)(eA.Provider,{value:j,children:(0,G.jsx)(ok,{sensors:S,modifiers:p,accessibility:f,measuring:fA,onDragStart:O,onDragOver:ee,onDragEnd:A,onDragCancel:k,children:(0,G.jsx)(M,{"data-slot":`kanban`,"data-dragging":_!==null,className:W(_!==null&&`cursor-grabbing!`,i),...m,children:r})})})}function mA({className:e,asChild:t=!1,children:n,...r}){let{columnIds:i}=(0,C.useContext)(eA);return(0,G.jsx)(zk,{items:i,strategy:Nk,children:(0,G.jsx)(t?K:`div`,{"data-slot":`kanban-board`,className:W(`grid auto-rows-fr gap-4`,e),...r,children:n})})}function hA({value:e,className:t,asChild:n=!1,disabled:r,children:i,...a}){let o=(0,C.useContext)(rA),{setNodeRef:s,transform:c,transition:l,attributes:u,listeners:d,isDragging:f}=qk({id:e,disabled:r||o,animateLayoutChanges:iA}),{activeId:p,isColumn:m}=(0,C.useContext)(eA),h=p?m(p):!1,g={transition:l,transform:KE.Transform.toString(c)},_=n?K:`div`;return o?(0,G.jsx)(tA.Provider,{value:{attributes:{},listeners:void 0,isDragging:!0,disabled:!1},children:(0,G.jsx)(_,{"data-slot":`kanban-column`,"data-value":e,"data-dragging":!0,className:W(`group/kanban-column flex flex-col`,t),...a,children:i})}):(0,G.jsx)(tA.Provider,{value:{attributes:u,listeners:d,isDragging:h,disabled:r},children:(0,G.jsx)(_,{"data-slot":`kanban-column`,"data-value":e,"data-dragging":f,"data-disabled":r,ref:s,style:g,className:W(`group/kanban-column flex flex-col`,f&&`z-50 opacity-50`,r&&`opacity-50`,t),...a,children:i})})}function gA({className:e,asChild:t=!1,cursor:n=!0,children:r,...i}){let{attributes:a,listeners:o,isDragging:s,disabled:c}=(0,C.useContext)(tA);return(0,G.jsx)(t?K:`div`,{"data-slot":`kanban-column-handle`,"data-dragging":s,"data-disabled":c,...a,...o,className:W(`opacity-0 transition-opacity group-hover/kanban-column:opacity-100`,n&&(s?`cursor-grabbing!`:`cursor-grab!`),e),...i,children:r})}function _A({value:e,className:t,asChild:n=!1,disabled:r,children:i,...a}){let o=(0,C.useContext)(rA),{setNodeRef:s,transform:c,transition:l,attributes:u,listeners:d,isDragging:f}=qk({id:e,disabled:r||o,animateLayoutChanges:iA}),{activeId:p,isColumn:m}=(0,C.useContext)(eA),h=p?!m(p):!1,g={transition:l,transform:KE.Transform.toString(c)},_=n?K:`div`;return o?(0,G.jsx)(nA.Provider,{value:{listeners:void 0,isDragging:!0,disabled:!1},children:(0,G.jsx)(_,{"data-slot":`kanban-item`,"data-value":e,"data-dragging":!0,className:W(t),...a,children:i})}):(0,G.jsx)(nA.Provider,{value:{listeners:d,isDragging:h,disabled:r},children:(0,G.jsx)(_,{"data-slot":`kanban-item`,"data-value":e,"data-dragging":f,"data-disabled":r,ref:s,style:g,...u,className:W(`outline-none focus-visible:ring-2 focus-visible:ring-ring/50`,f&&`z-50 opacity-50`,r&&`opacity-50`,t),...a,children:i})})}function vA({className:e,asChild:t=!1,cursor:n=!0,children:r,...i}){let{listeners:a,isDragging:o,disabled:s}=(0,C.useContext)(nA);return(0,G.jsx)(t?K:`div`,{"data-slot":`kanban-item-handle`,"data-dragging":o,"data-disabled":s,...a,className:W(n&&(o?`cursor-grabbing!`:`cursor-grab!`),e),...i,children:r})}function yA({value:e,className:t,asChild:n=!1,children:r,...i}){let{columns:a,getItemId:o}=(0,C.useContext)(eA),s=(0,C.useMemo)(()=>{let t=a[e];if(!t)throw Error(`KanbanColumnContent: column "${e}" was not found in the Kanban value. Available columns: ${Object.keys(a).join(`, `)||`(none)`}.`);return t.map(o)},[a,o,e]);return(0,G.jsx)(zk,{items:s,strategy:Fk,children:(0,G.jsx)(n?K:`div`,{"data-slot":`kanban-column-content`,className:W(`flex flex-col gap-2`,t),...i,children:r})})}function bA({children:e,className:t,...n}){let{activeId:r,isColumn:i,modifiers:a}=(0,C.useContext)(eA),o=(0,C.useSyncExternalStore)(oA,sA,cA),s=r&&i(r)?`column`:`item`,c=r&&e?typeof e==`function`?e({value:r,variant:s}):e:null;return o?(0,pe.createPortal)((0,G.jsx)(Dk,{dropAnimation:aA,modifiers:a,className:W(`z-50`,r&&`cursor-grabbing`,t),...n,children:(0,G.jsx)(rA.Provider,{value:!0,children:c})}),document.body):null}function xA({className:e,...t}){return(0,G.jsx)(`div`,{"data-slot":`input-group`,role:`group`,className:W(`group/input-group border-input dark:bg-input/30 relative flex h-9 w-full min-w-0 items-center rounded-md border shadow-xs outline-none`,`has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot=input-group-control]:focus-visible]:ring-[3px]`,e),...t})}var SA=mi(`text-muted-foreground flex h-auto cursor-text items-center justify-center gap-2 py-1.5 text-sm select-none [&>svg:not([class*='size-'])]:size-4`,{variants:{align:{"inline-start":`order-first pl-3`,"inline-end":`order-last pr-3`}},defaultVariants:{align:`inline-start`}});function CA({className:e,align:t=`inline-start`,...n}){return(0,G.jsx)(`div`,{"data-slot":`input-group-addon`,className:W(SA({align:t}),e),onClick:e=>{e.target.closest(`button`)||e.currentTarget.parentElement?.querySelector(`input`)?.focus()},...n})}function wA({className:e,...t}){return(0,G.jsx)(_E,{"data-slot":`input-group-control`,className:W(`flex-1 rounded-none border-0 bg-transparent shadow-none focus-visible:ring-0 dark:bg-transparent`,e),...t})}var TA=`collapsed-columns`,EA=`collapsed-epic-statuses`,DA=`collapsed-favourite-folders`,OA=`board-chrome`,kA=`board-opener`,AA=`favourite-epics`,jA=`board-presets`,MA=`board-sidebar-open`,NA=`board-column-order`,PA=[`In Progress`,`Completed`,`Cancelled`,`Canceled`],FA=[`created`,`targetEnd`,`priority`,`labels`,`assignee`,`dueDate`],IA={filter:{},sort:`payload`,hide:[],shown:[...FA]},LA={keys:[],folders:[],projects:void 0};function RA(e=TA,t=[]){try{let n=localStorage.getItem(e);if(n===null)return new Set(t);let r=JSON.parse(n);return new Set(Array.isArray(r)?r.filter(e=>typeof e==`string`):t)}catch{return new Set(t)}}function zA(e,t=TA){localStorage.setItem(t,JSON.stringify([...e]))}function BA(e,t){let n=t.toLowerCase();return[...e].some(e=>e.toLowerCase()===n)}function VA(e){if(!e||typeof e!=`object`)return{};let t={};for(let[n,r]of Object.entries(e))n!==`priorities`&&n!==`assignees`&&Array.isArray(r)&&(t[n]=r.filter(e=>typeof e==`string`));return Array.isArray(e.priorities)&&!t.priority&&(t.priority=e.priorities.filter(e=>typeof e==`string`)),Array.isArray(e.assignees)&&!t.assignee&&(t.assignee=e.assignees.filter(e=>typeof e==`string`)),t}function HA(){try{let e=localStorage.getItem(OA);if(e===null)return IA;let t=JSON.parse(e),n=Array.isArray(t.shown)?t.shown.filter(e=>FA.includes(e)):[...FA];return{filter:VA(t.filter),sort:t.sort===`priority`||t.sort===`age`||t.sort===`due`||t.sort===`key`?t.sort:`payload`,hide:Array.isArray(t.hide)?t.hide.filter(e=>typeof e==`string`):[],shown:n.length?n:[...FA]}}catch{return IA}}function UA(e){localStorage.setItem(OA,JSON.stringify(e))}function WA(){try{let e=localStorage.getItem(AA);if(e===null)return LA;let t=JSON.parse(e);if(Array.isArray(t)&&t.every(e=>typeof e==`string`))return{keys:t,folders:[]};if(t&&typeof t==`object`){let e=t;return{keys:Array.isArray(e.keys)?e.keys.filter(e=>typeof e==`string`):[],folders:Array.isArray(e.folders)?e.folders.flatMap(e=>{if(!e||typeof e!=`object`)return[];let t=e;return typeof t.name!=`string`||!t.name.trim()?[]:[{name:t.name,keys:Array.isArray(t.keys)?t.keys.filter(e=>typeof e==`string`):[]}]}):[],projects:Array.isArray(e.projects)?e.projects.filter(e=>typeof e==`string`):void 0}}return LA}catch{return LA}}function GA(e){localStorage.setItem(AA,JSON.stringify(e))}function KA(){try{let e=localStorage.getItem(jA);if(e===null)return[];let t=JSON.parse(e);return Array.isArray(t)?t.flatMap(e=>{if(!e||typeof e!=`object`)return[];let t=e;return typeof t.name!=`string`||!t.name.trim()?[]:[{name:t.name,filter:VA(t.filter),sort:t.sort===`priority`||t.sort===`age`||t.sort===`due`||t.sort===`key`?t.sort:`payload`,hide:Array.isArray(t.hide)?t.hide.filter(e=>typeof e==`string`):[]}]}):[]}catch{return[]}}function qA(e){localStorage.setItem(jA,JSON.stringify(e))}function JA(e,t){let n=(e??[]).slice().sort(),r=(t??[]).slice().sort();return n.length===r.length&&n.every((e,t)=>e===r[t])}function YA(e,t){return!t.length||JA(e.projects,t)?e:{keys:[],folders:[],projects:t}}function XA(e,t){return t.length?e.filter(e=>JA(e.projects,t)):e}function ZA(){try{let e=localStorage.getItem(kA);return e===`epics`||e===`combined`?e:`stories`}catch{return`stories`}}function QA(e){localStorage.setItem(kA,e)}function $A(){try{let e=localStorage.getItem(MA);return e===null||e===`true`}catch{return!0}}function ej(e){localStorage.setItem(MA,e?`true`:`false`)}function tj(){try{let e=localStorage.getItem(NA);if(e===null)return{};let t=JSON.parse(e);return!t||typeof t!=`object`?{}:Object.fromEntries(Object.entries(t).map(([e,t])=>[e,Array.isArray(t)?t.filter(e=>typeof e==`string`):[]]))}catch{return{}}}function nj(e){localStorage.setItem(NA,JSON.stringify(e))}function rj(e,t){let n=[{label:`Key`,value:e.key},{label:`Summary`,value:e.summary}];return t&&n.push({label:`Jira URL`,value:t}),e.priority&&n.push({label:`Priority`,value:e.priority}),e.assignee&&n.push({label:`Assignee`,value:e.assignee}),e.dueDate&&n.push({label:`Due date`,value:e.dueDate}),e.targetEnd&&n.push({label:`Target end`,value:e.targetEnd}),e.labels?.length&&n.push({label:`Labels`,value:e.labels.join(`, `),pills:e.labels}),n}async function ij(e,t){return(await fetch(e,{headers:{"content-type":`application/json`},...t})).json()}function aj(e){return Object.fromEntries(e.map(e=>[e.title,e.cards]))}function oj(){return typeof document>`u`?`light`:document.documentElement.classList.contains(`dark`)?`dark`:`light`}function sj(e){document.documentElement.classList.toggle(`dark`,e===`dark`),localStorage.setItem(`theme`,e)}var cj={done:`green`,complete:`green`,completed:`green`,closed:`green`,resolved:`green`,progress:`yellow`,review:`yellow`,doing:`yellow`,cancelled:`gray`,canceled:`gray`};function lj(e){if(!e)return`var(--primary)`;let t=e.toLowerCase(),n=Object.keys(cj).find(e=>t.includes(e));return`var(--kanban-board-circle-${n?cj[n]:`gray`})`}function uj(e){let t=(e??``).toLowerCase();return t===`high`||t===`highest`||t===`critical`?`text-red-500`:t===`medium`?`text-orange-400`:`text-yellow-500`}function dj(e,t){return e.includes(t)?e.filter(e=>e!==t):[...e,t]}function fj(e,t){return e.includes(t)?e.filter(e=>e!==t):[...e,t]}function pj(e){let t=[];for(let n of e){let e=t.at(-1);n.group&&e?.group===n.group?e.facets.push(n):t.push({group:n.group,facets:[n]})}return t}function mj({facet:e,selected:t,onToggle:n}){return(0,G.jsxs)(G.Fragment,{children:[e.label===e.group?null:(0,G.jsx)(Ep,{children:e.label}),e.values.map(e=>(0,G.jsx)(Op,{checked:t.includes(e),onCheckedChange:()=>n(e),children:e},e))]})}function hj({facets:e,filter:t,onToggle:n,onClear:r}){let[i,a]=(0,C.useState)({});return(0,G.jsxs)(Tp,{align:`end`,className:`w-56 max-h-[min(70vh,28rem)]`,children:[pj(e).map((e,r)=>{let o=e.facets.map(e=>(0,G.jsx)(mj,{facet:e,selected:t[e.key]??[],onToggle:t=>n(e.key,t)},e.key));return(0,G.jsxs)(C.Fragment,{children:[r>0?(0,G.jsx)(jp,{}):null,e.group?(0,G.jsxs)(cg,{open:i[e.group]!==!1,onOpenChange:t=>a(n=>({...n,[e.group]:t})),className:`flex flex-col`,children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsxs)(`button`,{type:`button`,className:`text-muted-foreground hover:text-foreground flex w-full items-center gap-1.5 px-2 py-1.5 text-left text-[11px] font-medium`,onPointerDown:e=>e.preventDefault(),children:[(0,G.jsx)(j,{className:W(`size-3.5 shrink-0 transition-transform`,i[e.group]===!1&&`-rotate-90`)}),e.group]})}),(0,G.jsx)(ug,{className:`flex flex-col`,children:o})]}):o]},e.group??e.facets[0]?.key)}),e.length?(0,G.jsx)(jp,{}):null,(0,G.jsx)(Dp,{onClick:r,children:`Clear Filter, Sort, and Hide`})]})}function gj({card:e,asHandle:t,isOverlay:n,disabled:r,selected:i,onClick:a,onDoubleClick:o,variant:s=`story`,shown:c}){let l=s===`epic`||(e.type??``).toLowerCase()===`epic`,u=e=>c?.has(e)??!0,d=u(`created`)?qe(e.created):void 0,f=u(`targetEnd`)?Je(e.targetEnd):void 0,p=f?(()=>{let t=/^(\d{4})-(\d{2})-(\d{2})/.exec(e.targetEnd??``),n=t?Date.UTC(Number(t[1]),Number(t[2])-1,Number(t[3])):Date.parse(e.targetEnd??``);return!Number.isNaN(n)&&n<Date.now()})():!1,m=f?(()=>{let t=/^(\d{4})-(\d{2})-(\d{2})/.exec(e.targetEnd??``),n=t?Date.UTC(Number(t[1]),Number(t[2])-1,Number(t[3])):Date.parse(e.targetEnd??``);if(Number.isNaN(n)||n<Date.now())return!1;let r=new Date,i=Date.UTC(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate());return Math.round((n-i)/864e5)<=3})():!1,h=u(`priority`)&&e.priority||u(`labels`)&&e.labels?.length||u(`assignee`)&&e.assignee||u(`dueDate`)&&e.dueDate||f,g=(0,G.jsxs)(`div`,{className:W(`bg-card hover:bg-foreground/5 rounded-[9px] border px-3 pt-2 pb-3`,i&&`ring-primary ring-2`,l&&`bg-muted/40 border-l-4 border-l-primary`),children:[(0,G.jsxs)(`div`,{className:`flex h-[22px] items-center justify-between gap-2`,children:[(0,G.jsxs)(`span`,{className:`flex min-w-0 items-baseline gap-1.5`,children:[(0,G.jsx)(`span`,{className:`text-muted-foreground text-[12px] font-medium tabular-nums`,children:e.key}),(e.type??``).toLowerCase()===`epic`?(0,G.jsx)(`span`,{className:`text-muted-foreground/60 text-[11px] font-normal`,children:`Epic`}):null]}),d?(0,G.jsx)(`span`,{className:`text-muted-foreground text-[11px] tabular-nums`,children:d}):null]}),(0,G.jsx)(`p`,{className:`mt-0.5 truncate text-[13px] leading-[18px]`,children:e.summary}),h?(0,G.jsxs)(`div`,{className:`mt-auto flex flex-wrap items-center gap-2 pt-2`,children:[u(`priority`)&&e.priority?(0,G.jsx)(`span`,{className:W(`inline-flex h-6 shrink-0 items-center rounded-full border px-2 text-[12px] font-medium capitalize`,uj(e.priority)),children:e.priority}):null,u(`labels`)?e.labels?.map(e=>(0,G.jsx)(`span`,{className:`text-muted-foreground inline-flex h-6 shrink-0 items-center rounded-full border px-2 text-[12px]`,children:e},e)):null,(0,G.jsx)(`span`,{className:`flex-1`}),f?(0,G.jsx)(`span`,{className:W(`shrink-0 text-[11px] tabular-nums`,p&&`text-destructive font-medium`,m&&!p&&`text-amber-500 dark:text-amber-400`,!p&&!m&&`text-muted-foreground`),title:e.targetEnd,children:f}):null,u(`dueDate`)&&e.dueDate?(0,G.jsx)(`time`,{className:`text-muted-foreground shrink-0 text-[11px] tabular-nums`,children:e.dueDate}):null,u(`assignee`)&&e.assignee?(0,G.jsx)(`span`,{className:`text-muted-foreground shrink-0 text-[12px]`,children:e.assignee}):null]}):null]});return(0,G.jsx)(_A,{value:e.key,disabled:r,children:t&&!n?(0,G.jsx)(vA,{onClick:a,onDoubleClick:o,children:g}):g})}function _j({title:e,cards:t,isOverlay:n,disabled:r,selected:i,onClick:a,onDoubleClick:o,onCreate:s,onHide:c,shown:l}){let[u,d]=(0,C.useState)(()=>n||!RA().has(e));function f(t){if(d(t),n)return;let r=RA();t?r.delete(e):r.add(e),zA(r)}return(0,G.jsx)(hA,{value:e,className:`group h-full min-h-0`,children:(0,G.jsx)(cg,{open:u,onOpenChange:f,className:W(`flex h-full min-h-0 flex-col`,!u&&`h-auto`),children:(0,G.jsxs)(`div`,{className:W(`flex flex-col`,u?`h-full min-h-0`:`h-auto`),children:[(0,G.jsxs)(`div`,{className:`flex items-center gap-2 px-3 pt-[13px] pb-5`,children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsxs)(`button`,{type:`button`,className:`flex min-w-0 flex-1 items-center gap-2 text-left`,children:[(0,G.jsx)(`span`,{className:`size-3.5 shrink-0 rounded-full`,style:{backgroundColor:lj(e)}}),(0,G.jsx)(`span`,{className:`truncate text-[13px] font-medium`,children:e}),(0,G.jsx)(`span`,{className:`text-muted-foreground text-[12px] tabular-nums`,children:t.length}),(0,G.jsx)(j,{className:W(`text-muted-foreground size-3.5 shrink-0 transition-transform`,!u&&`-rotate-90`)})]})}),s?(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":`Create issue in ${e}`,title:`Create issue`,onPointerDown:e=>e.stopPropagation(),onClick:()=>s(e),children:(0,G.jsx)(ae,{})}):null,c?(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":`Hide ${e}`,onClick:c,children:(0,G.jsx)(ne,{})}):null,(0,G.jsx)(gA,{className:`opacity-0 transition-opacity group-hover:opacity-60`,children:(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,tabIndex:-1,type:`button`,children:(0,G.jsx)(ie,{})})})]}),(0,G.jsx)(ug,{className:`min-h-0 flex-1 overflow-hidden`,children:(0,G.jsxs)(yA,{value:e,className:`flex h-full flex-col gap-2 overflow-auto px-2 pb-2`,children:[t.map(e=>(0,G.jsx)(gj,{card:e,asHandle:!n,isOverlay:n,disabled:r,selected:i?.has(e.key),variant:(e.type??``).toLowerCase()===`epic`?`epic`:`story`,shown:l,onClick:t=>a?.(e.key,t),onDoubleClick:t=>o?.(e.key,t)},e.key)),s?(0,G.jsxs)(`button`,{type:`button`,className:`text-muted-foreground hover:bg-foreground/5 hover:text-foreground flex min-h-8 w-full shrink-0 items-center gap-1.5 rounded-md px-2 text-[12px]`,"aria-label":`Create issue in ${e}`,onPointerDown:e=>e.stopPropagation(),onClick:()=>s(e),children:[(0,G.jsx)(ae,{className:`size-3.5`}),`Create`]}):null]})})]})})})}function vj(e,t){return[...new Set(e.map(e=>e.status?.trim()).filter(e=>!!e))].filter(e=>e!==t)}function yj({epic:e,selected:t,count:n,favourited:r,folders:i,moveTo:a,onSelect:o,onToggleFavourite:s,onFile:c,onMove:l,onOpen:u}){let d=a??[],f=!!(c&&r),p=!!u||f||d.length>0;return(0,G.jsxs)(`div`,{className:W(`flex h-14 w-full items-center gap-1 rounded-lg pr-1`,t?`bg-sidebar-accent text-sidebar-accent-foreground`:`hover:bg-foreground/5`),children:[(0,G.jsxs)(`button`,{type:`button`,className:`flex min-w-0 flex-1 items-center gap-3 px-3 text-left`,onClick:()=>void o(e.key),children:[(0,G.jsx)(`span`,{className:`size-2 shrink-0 rounded-full`,style:{backgroundColor:lj(e.status)}}),(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-[13px] leading-[18px]`,children:e.summary}),(0,G.jsx)(`span`,{className:`text-muted-foreground text-[11px] font-medium tabular-nums`,children:e.key}),(0,G.jsx)(`span`,{className:`text-muted-foreground text-[11px] tabular-nums`,children:n})]}),p?(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":f?`File ${e.key}`:d.length?`Move ${e.key}`:`Open ${e.key}`,children:(0,G.jsx)(F,{})})}),(0,G.jsxs)(Tp,{align:`end`,children:[u?(0,G.jsx)(Dp,{onClick:()=>u(e.key),children:`Open`}):null,f?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Dp,{onClick:()=>c?.(e.key,null),children:`Unfiled`}),i?.map(t=>(0,G.jsx)(Dp,{onClick:()=>c?.(e.key,t),children:t},t))]}):null,f&&d.length?(0,G.jsxs)(Mp,{children:[(0,G.jsx)(Np,{children:`Move`}),(0,G.jsx)(Pp,{children:d.map(t=>(0,G.jsx)(Dp,{onClick:()=>l?.(e.key,t),children:t},t))})]}):null,f?null:d.map(t=>(0,G.jsx)(Dp,{onClick:()=>l?.(e.key,t),children:t},t))]})]}):null,(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":r?`Unfavourite ${e.key}`:`Favourite ${e.key}`,onClick:t=>{t.stopPropagation(),s(e.key)},children:(0,G.jsx)(ce,{className:W(r&&`fill-current`)})})]})}function bj({status:e,epics:t,selectedEpic:n,childCount:r,favourites:i,listedEpics:a,onSelect:o,onToggleFavourite:s,onMove:c,onOpen:l}){let[u,d]=(0,C.useState)(()=>!BA(RA(EA,PA),e));function f(t){d(t);let n=RA(EA,PA);if(t)for(let t of[...n])t.toLowerCase()===e.toLowerCase()&&n.delete(t);else n.add(e);zA(n,EA)}return(0,G.jsxs)(cg,{open:u,onOpenChange:f,className:`flex flex-col`,children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsxs)(`button`,{type:`button`,className:`text-muted-foreground hover:text-foreground flex h-7 items-center gap-1.5 px-3 text-left`,children:[(0,G.jsx)(j,{className:W(`size-3.5 shrink-0 transition-transform`,!u&&`-rotate-90`)}),(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-[12px] font-medium`,children:e}),(0,G.jsx)(`span`,{className:`text-[11px] tabular-nums`,children:t.length})]})}),(0,G.jsx)(ug,{className:`flex flex-col gap-0.5`,children:t.map(e=>(0,G.jsx)(yj,{epic:e,selected:n===e.key,count:r(e.key),favourited:i.keys.includes(e.key),onSelect:o,onToggleFavourite:s,moveTo:vj(a,e.status),onMove:c,onOpen:l},e.key))})]})}function xj({fields:e}){return(0,G.jsx)(`dl`,{className:`flex flex-col gap-3 p-4 text-[13px]`,children:e.map(e=>(0,G.jsxs)(`div`,{className:`flex flex-col gap-1`,children:[(0,G.jsx)(`dt`,{className:`text-muted-foreground text-[11px] font-medium`,children:e.label}),(0,G.jsx)(`dd`,{className:`whitespace-pre-wrap`,children:e.label===`Jira URL`?(0,G.jsx)(`a`,{className:`text-foreground font-medium underline-offset-4 hover:underline`,href:e.value,target:`_blank`,rel:`noreferrer`,children:e.value}):e.pills?.length?(0,G.jsx)(`span`,{className:`flex flex-wrap gap-1`,children:e.pills.map(e=>(0,G.jsx)(`span`,{className:`text-muted-foreground inline-flex h-6 items-center rounded-full border px-2 text-[12px]`,children:e},e))}):e.value})]},e.label))})}function Sj(){let[e,t]=(0,C.useState)({}),[n,r]=(0,C.useState)([]),[i,a]=(0,C.useState)(null),[o,s]=(0,C.useState)(!1),[c,l]=(0,C.useState)(null),[u,d]=(0,C.useState)(null),[f,p]=(0,C.useState)(!1),[m,h]=(0,C.useState)(``),[g,_]=(0,C.useState)(null),[v,y]=(0,C.useState)(null),[b,x]=(0,C.useState)(null),[S,w]=(0,C.useState)([]),[T,E]=(0,C.useState)(``),[D,ee]=(0,C.useState)(``),[A,j]=(0,C.useState)(``),[P,F]=(0,C.useState)(``),[ne,ie]=(0,C.useState)(!1),[L,ae]=(0,C.useState)(oj),[B,oe]=(0,C.useState)(HA),se=(0,C.useMemo)(()=>Qe(D).projects,[D]),[ce,ue]=(0,C.useState)(()=>YA(WA(),se)),[fe,pe]=(0,C.useState)(()=>XA(KA(),se)),[me,he]=(0,C.useState)(``),[ge,_e]=(0,C.useState)(``),[ve,ye]=(0,C.useState)(``),[be,xe]=(0,C.useState)(``),[Se,Ce]=(0,C.useState)(ZA),[we,Te]=(0,C.useState)(Cn),[Ee,De]=(0,C.useState)(()=>$A()),Oe=Bh(),ke=(0,C.useRef)(null),[je,Me]=(0,C.useState)(null),[Ne,Pe]=(0,C.useState)(!1),Fe=(0,C.useRef)(!1),Ie=(0,C.useRef)(null),Le=bn(t,r),[Re,ze]=(0,C.useState)(new Set),Be={...B,epics:n},Ve=(0,C.useMemo)(()=>new Set(B.shown),[B.shown]),He=Se===`epics`,Ue=(0,C.useMemo)(()=>Se===`combined`?bt(e,n,A,Be):xt(He?e:yt(e,je?.children,A),He?null:g,A,Be),[e,g,A,B,n,He,je,Se]),We=(0,C.useMemo)(()=>Object.values(e).flat(),[e]),Ge=i??We,Ke=(0,C.useMemo)(()=>{let e=new Map;for(let t of je?.columns.flatMap(e=>e.cards)??[])e.set(t.key,t);for(let t of Ge)e.has(t.key)||e.set(t.key,t);return[...e.values()]},[je,Ge]),qe=(0,C.useMemo)(()=>Dt(n,Ge,A,B.filter),[n,Ge,A,B.filter]),Je=(0,C.useMemo)(()=>Ot(qe),[qe]),Xe=(0,C.useMemo)(()=>Ft(n,ce,A,Ge,B.filter),[n,ce,A,Ge,B.filter]),Ze=Object.keys(Ue),$e=`${Se}:${[...se].sort().join(`,`)}`,et=v?[`cards`,`open`]:[`cards`],tt=Ph({id:`shell`,panelIds:[`epics`,`board`],onlySaveAfterUserInteractions:!0}),rt=Ph({id:`board-open`,panelIds:et,onlySaveAfterUserInteractions:!0}),it=Ph({id:`columns`,panelIds:Ze,onlySaveAfterUserInteractions:!0}),at=b?xn(b,window.location.origin):null,ot=ft(We,n),st=Object.keys(e),ct=(0,C.useMemo)(()=>Qt([...We,...n,...Ke]),[We,n,Ke]),lt=Xe.unfiled.length>0||Xe.folders.length>0;function ut(e){oe(e),UA(e)}function dt(e){let t=se.length?{...e,projects:se}:e;ue(t),GA(t)}function pt(e){pe(e),qA(e)}function mt(){ze(new Set)}function ht(e,n){ke.current=e,Me(e);let i=e.epics??[];r(i);let o=tj()[`${n}:${[...se].sort().join(`,`)}`];t(At(aj(n===`epics`?Ye(i):e.columns),o)),a(e.children?Object.values(e.children).flat():null),e.error&&F(e.error)}function gt(e){mt(),ke.current=e,Me(e);let n=e.epics??[];r(n);let i=tj()[$e];t(At(aj(Se===`epics`?Ye(n):e.columns),i)),a(e.children?Object.values(e.children).flat():null),_(t=>t&&(e.epics??[]).some(e=>e.key===t)?t:null),e.error&&F(e.error)}async function _t(){let e=await ij(`/api/board`);gt(e),e.flags&&ee(e.flags)}(0,C.useEffect)(()=>{_t()},[]),(0,C.useEffect)(()=>{Ee||Oe.current?.collapse()},[]),(0,C.useEffect)(()=>{let e=tj()[$e];e?.length&&t(t=>At(t,e))},[$e]),(0,C.useEffect)(()=>{function e(e){if((e.metaKey||e.ctrlKey)&&!e.altKey&&!e.shiftKey&&e.key.toLowerCase()===`k`){if(e.preventDefault(),Fe.current){Fe.current=!1,Pe(!1),Ie.current?.focus();return}Ie.current=document.activeElement instanceof HTMLElement?document.activeElement:null,Fe.current=!0,Pe(!0);return}e.key===`Escape`&&Fe.current&&(e.preventDefault(),Fe.current=!1,Pe(!1),Ie.current?.focus())}return window.addEventListener(`keydown`,e,!0),()=>window.removeEventListener(`keydown`,e,!0)},[]);async function vt(){ie(!0),F(``),console.info(`[pipe-kan] Refresh`,D);let e=Ae.loading(`Refreshing…`,{description:`Listing Issues and Epics`});try{let t=await ij(`/api/refresh`,{method:`POST`,body:JSON.stringify({flags:D})});gt(t),t.error?(console.info(`[pipe-kan] Refresh error`,t.error),Ae.error(`Refresh failed`,{id:e,description:t.error})):(console.info(`[pipe-kan] Refreshed`,t.epics.length,`epics`),Ae.success(`Refreshed`,{id:e,description:`${t.epics.length} epics`}))}catch(t){let n=t instanceof Error?t.message:`Refresh failed`;console.info(`[pipe-kan] Refresh failed`,n),F(n),Ae.error(`Refresh failed`,{id:e,description:n})}finally{ie(!1)}}function St(t){for(let[n,r]of Object.entries(e))if(r.some(e=>e.key===t))return n;return``}function Ct(e,i,a){F(``);let o=n.find(t=>t.key===e);if(o){let n=a??o.status??`To Do`;r(n=>{let r=n.findIndex(t=>t.key===e);if(r===-1)return n;let a=[...n];return a[r]={...a[r],status:i},Se===`epics`&&t(At(aj(Ye(a)),tj()[$e])),a}),Le.move({key:e,target:i,source:n,kind:`epic`});return}let s=a??St(e);Le.move({key:e,target:i,source:s,kind:`card`})}function wt(e,t){if(t.ctrlKey||t.metaKey){t.preventDefault(),t.stopPropagation(),ze(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n});return}mt(),Xt(e)}function Tt(e,t){t.preventDefault(),t.stopPropagation(),mt(),Jt(e)}function kt(e){return{...e?{status:e}:{},selectedEpic:g,boardKind:Se}}function Pt(e){h(``),p(!1),d(sn(kt(e)))}function Vt(e){l(vn(e)),s(!0)}function Ht(e){let{draft:t,seed:n}=cn(kt(e));h(``),p(!1),d(t),l(n),s(!0)}async function Jt(e){let t=We.find(t=>t.key===e)??Ke.find(t=>t.key===e),r=n.find(t=>t.key===e),i=St(e)||r?.status;h(``),p(!1),d(ln({key:e,summary:t?.summary??r?.summary??``,labels:t?.labels??r?.labels??[],...i?{status:i}:{},...t?.epic?{epic:t.epic}:{},...t?.type||r?{type:t?.type??`Epic`}:{},...v===e&&S.length?{fields:S}:{}}));try{let t=await ij(`/api/open`,{method:`POST`,body:JSON.stringify({key:e})});if(t.error||!t.fields?.length)return;d(n=>n?.mode===`edit`&&n.key===e?_n(n,t.fields):n)}catch{}}async function Yt(){if(u&&un(u,f)){p(!0),h(``);try{if(u.mode===`create`){let e=dn(u);if(!e)return;let t=await ij(`/api/issue/create`,{method:`POST`,body:JSON.stringify(e)});if(!t.ok){let e=t.error??`Create failed`;h(e),Ae.error(`Create failed`,{description:e});return}t.board&>(t.board),Ae.success(`Created`,{description:t.key??u.title.trim()}),d(null);return}let e=fn(u);if(!e)return;let t=await ij(`/api/issue/edit`,{method:`POST`,body:JSON.stringify(e)});if(!t.ok){let e=t.error??`Edit failed`;h(e),Ae.error(`Edit failed`,{description:e});return}t.board&>(t.board),Ae.success(`Saved`,{description:u.key});let n=u.key;d(null),v===n&&Xt(n)}catch(e){let t=e instanceof Error?e.message:`Save failed`;h(t),Ae.error(`Save failed`,{description:t})}finally{p(!1)}}}async function Xt(e){let t=ke.current?.columns.flatMap(e=>e.cards)??[],r=We.find(t=>t.key===e)??t.find(t=>t.key===e),i=n.find(t=>t.key===e),a=r??(i?{key:i.key,summary:i.summary,priority:i.priority,assignee:i.assignee,dueDate:i.dueDate,labels:i.labels}:void 0),o=`/browse/${e}`;y(e),x(o),E(``),w(a?rj(a,o):[{label:`Jira URL`,value:o}]);let s=await ij(`/api/open`,{method:`POST`,body:JSON.stringify({key:e})});if(x(s.url),s.error){E(s.error),w(a?rj(a,s.url):[{label:`Jira URL`,value:s.url}]);return}w(s.fields)}function Zt(e,t){let n=[];for(let[r,i]of Object.entries(t))for(let t of i)Re.has(t.key)&&n.push({key:t.key,target:e,source:r,kind:`card`});return n}function $t(e,n){if(B.hide.includes(n.overContainer)){t(e=>Mt(n.previousValue,e,g,A,Be));return}if(n.kind===`column`){let n=Object.keys(e),r=tj();r[$e]=n,nj(r),t(e=>At(e,n));return}if(n.activeContainer===n.overContainer)return;let r=String(n.event.active.id);if(Re.has(r)&&Re.size>1){let e=Zt(n.overContainer,n.previousValue);if(e.length===0)return;t(e=>{let t={},r=[];for(let[n,i]of Object.entries(e)){let e=[];for(let t of i)Re.has(t.key)?r.push(t):e.push(t);t[n]=e}return t[n.overContainer]=[...t[n.overContainer]??[],...r],t}),mt(),Le.move(e);return}let i=Object.entries(n.previousValue).find(([,e])=>e.some(e=>e.key===r))?.[0];i&&(mt(),Ct(r,n.overContainer,i))}function en(){let e=L===`dark`?`light`:`dark`;sj(e),ae(e)}function tn(e){return Et(Ge,e,A,B.filter,n)}function nn(){QA(`stories`),Ce(`stories`),_(null),ke.current&&ht(ke.current,`stories`)}function rn(){QA(`epics`),Ce(`epics`),_(null),ke.current&&ht(ke.current,`epics`)}function an(){QA(`combined`),Ce(`combined`),_(null),ke.current&&ht(ke.current,`combined`)}function on(e){wn(e),Te(e)}function pn(){Tn(),Te(`calendar`)}async function mn(e){let r=Se===`epics`||Se===`combined`;if(r&&nn(),_(e),!e||!n.some(t=>t.key===e)||(r&&ke.current?ke.current.columns.flatMap(e=>e.cards):We).filter(t=>t.epic===e&&nt(t,A)).length>0)return;ie(!0),F(``);let i=Ae.loading(`Listing children…`);try{let n=await ij(`/api/epic`,{method:`POST`,body:JSON.stringify({key:e})});t(t=>Nt(t,aj(n.columns),e)),Ae.success(`Listed children`,{id:i})}catch(e){let t=e instanceof Error?e.message:`Epic list failed`;F(t),Ae.error(`Epic list failed`,{id:i,description:t})}finally{ie(!1)}}function hn(){let e=Lt(ce,me);if(!e.ok){_e(`Folder names must be unique`);return}he(``),_e(``),dt(e.state)}function gn(){let e=Ut(fe,ve,{...B,boardKind:Se,projects:se});if(!e.ok){xe(`Preset names must be unique`);return}ye(``),xe(``),pt(e.presets)}function yn(e){let t=Wt(fe,e);if(!t.ok||se.length&&!JA(t.chrome.projects,se))return;ut({...B,...t.chrome});let n=t.chrome.boardKind??`stories`;n===`combined`?an():n===`epics`?rn():Se!==`stories`&&nn()}function Sn(e){Fe.current=!1,Pe(!1),j(``),e.kind===`all-stories`?nn():e.kind===`all-epics`?rn():e.kind===`all-combined`?an():e.kind===`refresh`?vt():e.kind===`agent`?s(!0):e.kind===`create`?Pt():e.kind===`create-ai`?Ht():e.kind===`preset`?yn(e.name):e.kind===`epic`?(y(null),x(null),w([]),E(``),mn(e.key)):e.kind===`card`&&(e.epic?mn(e.epic):nn(),Xt(e.key))}function En(e){let t=Gt(fe,e,{...B,boardKind:Se,projects:se});t.ok&&pt(t.presets)}function Dn(e,t){let n=Kt(fe,e,t);if(!n.ok){xe(`Preset names must be unique`);return}xe(``),pt(n.presets)}return(0,G.jsxs)(`div`,{className:`bg-sidebar flex h-screen`,children:[(0,G.jsxs)(Uh,{id:`shell`,orientation:`horizontal`,className:`min-h-0 flex-1`,defaultLayout:tt.defaultLayout,onLayoutChanged:(e,t)=>{if(tt.onLayoutChanged(e,t),!t.isUserInteraction)return;let n=(e.epics??0)<=0;De(!n),ej(!n)},children:[(0,G.jsx)(Wh,{id:`epics`,panelRef:Oe,defaultSize:`244px`,minSize:`12rem`,maxSize:`40%`,collapsible:!0,collapsedSize:0,className:`min-h-0 overflow-hidden`,children:(0,G.jsxs)(`aside`,{className:`text-sidebar-foreground flex h-full min-h-0 flex-col`,children:[(0,G.jsxs)(`div`,{className:`flex h-10 items-center justify-between px-4`,children:[(0,G.jsx)(`span`,{className:`text-[13px] font-medium`,children:`pipe-kan`}),(0,G.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,G.jsx)(`span`,{className:`text-muted-foreground text-[12px] tabular-nums`,children:qe.length}),(0,G.jsx)(q,{variant:`ghost`,size:`icon-xs`,"aria-label":`Collapse sidebar`,title:`Collapse sidebar`,onClick:()=>{De(!1),ej(!1),Oe.current?.collapse()},children:(0,G.jsx)(M,{className:`size-4`})})]})]}),(0,G.jsxs)(`nav`,{className:`flex flex-1 flex-col gap-0.5 overflow-auto px-2 pb-2`,children:[(0,G.jsx)(`button`,{type:`button`,className:W(`h-8 rounded-lg px-3 text-left text-[13px]`,Se===`stories`&&g===null?`bg-sidebar-accent text-sidebar-accent-foreground`:`hover:bg-foreground/5`),onClick:nn,children:`All stories`}),(0,G.jsx)(`button`,{type:`button`,className:W(`h-8 rounded-lg px-3 text-left text-[13px]`,Se===`epics`?`bg-sidebar-accent text-sidebar-accent-foreground`:`hover:bg-foreground/5`),onClick:rn,children:`All epics`}),(0,G.jsx)(`button`,{type:`button`,className:W(`h-8 rounded-lg px-3 text-left text-[13px]`,Se===`combined`?`bg-sidebar-accent text-sidebar-accent-foreground`:`hover:bg-foreground/5`),onClick:an,children:`Combined`}),(0,G.jsx)(`button`,{type:`button`,className:W(`h-8 rounded-lg px-3 text-left text-[13px]`,we===`calendar`?`bg-sidebar-accent text-sidebar-accent-foreground`:`hover:bg-foreground/5`),onClick:pn,children:`Calendar`}),lt?(0,G.jsx)(Cj,{pane:Xe,selectedEpic:g,childCount:tn,favourites:ce,folderName:me,folderError:ge,onFolderName:he,onCreateFolder:hn,onRenameFolder:(e,t)=>{let n=Rt(ce,e,t);if(!n.ok){_e(`Folder names must be unique`);return}_e(``),dt(n.state)},onDeleteFolder:e=>dt(zt(ce,e)),listedEpics:n,onSelect:mn,onToggleFavourite:e=>dt(It(ce,e)),onFile:(e,t)=>dt(Bt(ce,e,t)),onMove:Ct,onOpen:Xt}):null,(0,G.jsx)(Tj,{presets:fe,presetName:ve,presetError:be,onPresetName:ye,onCreatePreset:gn,onApplyPreset:yn,onOverwritePreset:En,onRenamePreset:Dn,onDeletePreset:e=>pt(qt(fe,e))}),(0,G.jsx)(`div`,{className:`text-muted-foreground px-3 pt-3 pb-1 text-[11px] font-medium`,children:`Epics`}),Je.map(e=>e.status?(0,G.jsx)(bj,{status:e.status,epics:e.epics,selectedEpic:g,childCount:tn,favourites:ce,listedEpics:n,onSelect:mn,onToggleFavourite:e=>dt(It(ce,e)),onMove:Ct,onOpen:Xt},e.status):e.epics.map(e=>(0,G.jsx)(yj,{epic:e,selected:g===e.key,count:tn(e.key),favourited:ce.keys.includes(e.key),moveTo:vj(n,e.status),onSelect:mn,onToggleFavourite:e=>dt(It(ce,e)),onMove:Ct,onOpen:Xt},e.key)))]})]})}),(0,G.jsx)(Gh,{className:W(!Ee&&`hidden`)}),(0,G.jsx)(Wh,{id:`board`,defaultSize:`80%`,minSize:`24rem`,className:`min-h-0`,children:(0,G.jsx)(`div`,{className:`flex h-full min-h-0 flex-col p-2 pl-0`,children:(0,G.jsxs)(`div`,{className:`bg-background flex min-h-0 flex-1 flex-col overflow-hidden rounded-xl border`,children:[(0,G.jsxs)(`header`,{className:`flex min-h-11 shrink-0 flex-wrap items-center gap-2 px-3`,children:[Ee?null:(0,G.jsx)(q,{variant:`ghost`,size:`icon-xs`,"aria-label":`Expand sidebar`,title:`Expand sidebar`,onClick:()=>{De(!0),ej(!0),Oe.current?.expand()},children:(0,G.jsx)(te,{className:`size-4`})}),(0,G.jsxs)(`div`,{role:`tablist`,"aria-label":`Board or Calendar`,className:`flex items-center gap-0.5`,children:[(0,G.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":we===`board`,className:W(`h-7 rounded-md px-2 text-[13px] font-medium`,we===`board`?`bg-muted text-foreground`:`text-muted-foreground hover:text-foreground`),onClick:()=>on(`board`),children:`Board`}),(0,G.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":we===`calendar`,className:W(`h-7 rounded-md px-2 text-[13px] font-medium`,we===`calendar`?`bg-muted text-foreground`:`text-muted-foreground hover:text-foreground`),onClick:()=>on(`calendar`),children:`Calendar`})]}),(0,G.jsx)(`span`,{className:`bg-primary/10 text-primary inline-flex items-center rounded-full px-2 py-0.5 text-[11px] font-medium`,children:(()=>{let{projects:e}=Qe(D);return e.length>0?e.join(`, `):`DEMO`})()}),(0,G.jsxs)(xA,{className:`h-7 max-w-72 min-w-40 flex-1 border-transparent bg-muted shadow-none`,children:[(0,G.jsx)(CA,{children:(0,G.jsx)(z,{className:`size-3.5`})}),(0,G.jsx)(wA,{value:A,onChange:e=>j(e.target.value),placeholder:`Search Epics and Cards`,"aria-label":`Search`,className:`h-7 text-[13px]`}),A?(0,G.jsx)(CA,{align:`inline-end`,children:(0,G.jsx)(`button`,{type:`button`,"aria-label":`Clear search`,onClick:()=>j(``),children:(0,G.jsx)(de,{className:`size-3.5`})})}):null]}),(0,G.jsx)(`input`,{className:`placeholder:text-muted-foreground h-7 min-w-40 flex-1 rounded-md bg-muted px-2.5 text-[13px] outline-none`,value:D,onChange:e=>ee(e.target.value),placeholder:`Scope flags`,spellCheck:!1,"aria-label":`Scope flags`}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`ghost`,size:`sm`,children:[(0,G.jsx)(I,{}),`Filter`]})}),(0,G.jsx)(hj,{facets:ot,filter:B.filter,onToggle:(e,t)=>ut({...B,filter:{...B.filter,[e]:dj(B.filter[e]??[],t)}}),onClear:()=>ut(IA)})]}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`ghost`,size:`sm`,children:[(0,G.jsx)(O,{}),`Sort`]})}),(0,G.jsx)(Tp,{align:`end`,children:(0,G.jsxs)(kp,{value:B.sort,onValueChange:e=>ut({...B,sort:e}),children:[(0,G.jsx)(Ap,{value:`payload`,children:`Payload order`}),(0,G.jsx)(Ap,{value:`priority`,children:`Priority`}),(0,G.jsx)(Ap,{value:`age`,children:`Age`}),(0,G.jsx)(Ap,{value:`due`,children:`Due date`}),(0,G.jsx)(Ap,{value:`key`,children:`Key`})]})})]}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`ghost`,size:`sm`,children:[(0,G.jsx)(N,{}),`Columns`]})}),(0,G.jsx)(Tp,{align:`end`,children:st.map(e=>(0,G.jsx)(Op,{checked:!B.hide.includes(e),onCheckedChange:t=>ut({...B,hide:t?B.hide.filter(t=>t!==e):[...B.hide,e]}),children:e},e))})]}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsxs)(q,{variant:`ghost`,size:`sm`,children:[(0,G.jsx)(re,{}),`Display`]})}),(0,G.jsxs)(Tp,{align:`end`,className:`w-44`,children:[(0,G.jsx)(Ep,{children:`Card properties`}),FA.map(e=>(0,G.jsxs)(Op,{checked:B.shown.includes(e),onCheckedChange:()=>ut({...B,shown:fj(B.shown,e)}),children:[e===`created`&&`Age`,e===`targetEnd`&&`Target end`,e===`priority`&&`Priority`,e===`labels`&&`Labels`,e===`assignee`&&`Assignee`,e===`dueDate`&&`Due date`]},e))]})]}),(0,G.jsxs)(q,{variant:`ghost`,size:`sm`,onClick:()=>void vt(),disabled:ne,"aria-busy":ne,children:[ne?(0,G.jsx)(bE,{className:`size-3.5`}):null,`Refresh`]}),(0,G.jsxs)(q,{variant:`ghost`,size:`sm`,onClick:()=>s(e=>!e),"aria-pressed":o,children:[(0,G.jsx)(k,{className:`mr-1 size-4`}),`Agent`]}),(0,G.jsx)(q,{variant:`ghost`,size:`icon-xs`,onClick:en,"aria-label":L===`dark`?`Switch to light mode`:`Switch to dark mode`,children:L===`dark`?(0,G.jsx)(le,{}):(0,G.jsx)(R,{})}),P?(0,G.jsx)(`p`,{className:`text-destructive w-full text-[13px] whitespace-pre-wrap`,children:P}):null]}),(0,G.jsxs)(Uh,{id:`board-open`,orientation:`horizontal`,className:`min-h-0 flex-1`,defaultLayout:rt.defaultLayout,onLayoutChanged:rt.onLayoutChanged,children:[(0,G.jsx)(Wh,{id:`cards`,defaultSize:v?`70%`:`100%`,minSize:`16rem`,className:`min-h-0`,children:(0,G.jsx)(`main`,{className:W(`h-full min-h-0 min-w-0 px-2 pb-2`,we===`calendar`?`overflow-hidden`:`overflow-auto`),children:we===`calendar`?(0,G.jsx)(mE,{cards:Object.values(Ue).flat(),onOpen:e=>void Xt(e)}):(0,G.jsxs)(pA,{className:`h-full min-h-0`,value:Ue,onValueChange:e=>t(t=>jt(e,t,g,A,Be)),getItemValue:e=>e.key,restoreOnCancel:!0,onValueCommit:$t,children:[(0,G.jsx)(mA,{className:`grid h-full min-h-0 grid-cols-1 auto-rows-fr gap-3`,children:Ze.length?(0,G.jsx)(Uh,{id:`columns`,orientation:`horizontal`,className:`min-h-0`,defaultLayout:it.defaultLayout,onLayoutChanged:it.onLayoutChanged,children:Object.entries(Ue).map(([e,t],n,r)=>(0,G.jsxs)(C.Fragment,{children:[n>0?(0,G.jsx)(Gh,{}):null,(0,G.jsx)(Wh,{id:e,defaultSize:`${100/Math.max(r.length,1)}%`,minSize:`16rem`,className:`min-h-0 min-w-0`,children:(0,G.jsx)(_j,{title:e,cards:t,disabled:ne,selected:Re,shown:Ve,onClick:wt,onDoubleClick:Tt,onCreate:Pt,onHide:()=>ut({...B,hide:[...B.hide,e]})})})]},e))}):null}),(0,G.jsx)(bA,{children:({value:e,variant:t})=>{if(t===`column`)return(0,G.jsx)(_j,{title:String(e),cards:Ue[String(e)]??[],isOverlay:!0,shown:Ve});let n=Object.values(Ue).flat().find(t=>t.key===e);if(!n)return null;let r=Re.has(n.key)?Re.size:1;return(0,G.jsxs)(`div`,{className:`relative`,children:[(0,G.jsx)(gj,{card:n,isOverlay:!0,variant:(n.type??``).toLowerCase()===`epic`?`epic`:`story`,shown:Ve}),r>1?(0,G.jsx)(`span`,{className:`absolute -top-2 -right-2 flex h-5 min-w-5 items-center justify-center rounded-full bg-primary px-1.5 text-[11px] font-medium text-primary-foreground`,children:r}):null]})}})]})})}),v?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Gh,{}),(0,G.jsx)(Wh,{id:`open`,defaultSize:`30%`,minSize:`16rem`,className:`min-h-0`,children:(0,G.jsxs)(`aside`,{className:`flex h-full min-h-0 flex-col border-l`,children:[(0,G.jsxs)(`div`,{className:`flex h-10 items-center gap-2 px-3`,children:[(0,G.jsx)(`a`,{className:`min-w-0 flex-1 truncate text-[13px] font-medium underline-offset-4 hover:underline`,href:b??void 0,target:`_blank`,rel:`noreferrer`,children:v}),(0,G.jsx)(q,{variant:`ghost`,size:`sm`,className:`h-7 text-[12px]`,type:`button`,onClick:()=>{v&&Jt(v)},children:`Edit`}),(0,G.jsx)(q,{variant:`ghost`,size:`icon-xs`,"aria-label":`Close issue`,onClick:()=>{y(null),x(null),w([]),E(``)},children:(0,G.jsx)(de,{})})]}),(0,G.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-auto`,children:[T?(0,G.jsx)(`p`,{className:`text-destructive px-4 pt-3 text-[13px] whitespace-pre-wrap`,children:T}):null,(0,G.jsx)(xj,{fields:S}),at?(0,G.jsx)(`iframe`,{title:v??`Issue`,src:at,className:`min-h-64 w-full border-0 bg-background`}):b?(0,G.jsx)(`div`,{className:`text-muted-foreground px-4 pb-6 text-[13px]`,children:`Jira refuses to embed this page.`}):null]})]})})]}):null]})]})})}),o?(0,G.jsxs)(G.Fragment,{children:[(0,G.jsx)(Gh,{}),(0,G.jsx)(mg,{open:o,onClose:()=>s(!1),selectedIssueKey:v??g??void 0,boardView:{scope:`view`,kind:Se,selectedEpic:He?null:g,search:A,filter:B.filter,sort:B.sort,hide:B.hide,columns:Object.entries(Ue).map(([e,t])=>({title:e,cards:t.map(e=>({key:e.key,summary:e.summary,epic:e.epic,assignee:e.assignee,priority:e.priority,labels:e.labels,dueDate:e.dueDate,targetEnd:e.targetEnd}))})),epics:qe.map(e=>({key:e.key,summary:e.summary,status:e.status}))},pipeView:je?{scope:`pipe`,kind:`stories`,selectedEpic:null,search:``,filter:{},sort:`payload`,hide:[],columns:je.columns.map(e=>({title:e.title,cards:e.cards.map(e=>({key:e.key,summary:e.summary,epic:e.epic,assignee:e.assignee,priority:e.priority,labels:e.labels,dueDate:e.dueDate,targetEnd:e.targetEnd}))})),epics:je.epics.map(e=>({key:e.key,summary:e.summary,status:e.status}))}:void 0,onApplyPreset:yn,onSetFilter:e=>ut({...B,filter:e}),onBoardMutated:()=>{_t()},seedPrompt:c,onSeedConsumed:()=>l(null)})]}):null]}),(0,G.jsx)(yE,{theme:L}),u?(0,G.jsx)(vE,{draft:u,catalog:ct,busy:f,error:m,onChange:d,onSubmit:()=>void Yt(),onClose:()=>{f||(d(null),h(``))},onDraftWithAi:u.mode===`create`?()=>Vt(u):void 0}):null,Ne?(0,G.jsx)(gE,{presets:fe.map(e=>e.name),epics:je?.epics??n,cards:Ke,favouriteKeys:ce.keys,onPick:Sn,onClose:()=>{Fe.current=!1,Pe(!1),Ie.current?.focus()}}):null]})}function Cj({pane:e,selectedEpic:t,childCount:n,favourites:r,folderName:i,folderError:a,onFolderName:o,onCreateFolder:s,onRenameFolder:c,onDeleteFolder:l,listedEpics:u,onSelect:d,onToggleFavourite:f,onFile:p,onMove:m,onOpen:h}){let[g,_]=(0,C.useState)(()=>!BA(RA(EA,PA),`Favourites`));function v(e){_(e);let t=RA(EA,PA);if(e)for(let e of[...t])e.toLowerCase()===`favourites`&&t.delete(e);else t.add(`Favourites`);zA(t,EA)}let y=r.folders.map(e=>e.name);return(0,G.jsxs)(cg,{open:g,onOpenChange:v,className:`flex flex-col`,children:[(0,G.jsxs)(`div`,{className:`flex items-center gap-1 px-1`,children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsxs)(`button`,{type:`button`,className:`text-muted-foreground hover:text-foreground flex h-7 min-w-0 flex-1 items-center gap-1.5 px-2 text-left`,children:[(0,G.jsx)(j,{className:W(`size-3.5 shrink-0 transition-transform`,!g&&`-rotate-90`)}),(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-[12px] font-medium`,children:`Favourites`})]})}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":`Favourite Folders`,children:(0,G.jsx)(F,{})})}),(0,G.jsxs)(Tp,{align:`start`,className:`w-56`,children:[(0,G.jsx)(Ep,{children:`Create Folder`}),(0,G.jsxs)(`div`,{className:`px-2 pb-2`,children:[(0,G.jsx)(`input`,{className:`border-input h-7 w-full rounded-md border bg-transparent px-2 text-[13px] outline-none`,value:i,onChange:e=>o(e.target.value),placeholder:`Name`,"aria-label":`Folder name`,onKeyDown:e=>{e.key===`Enter`&&s()}}),a?(0,G.jsx)(`p`,{className:`text-destructive pt-1 text-[11px]`,children:a}):null]}),(0,G.jsx)(Dp,{onClick:s,children:`Create`}),y.length?(0,G.jsx)(jp,{}):null,y.map(e=>(0,G.jsxs)(Dp,{onClick:()=>{let t=window.prompt(`Rename Folder`,e);t!=null&&c(e,t)},children:[`Rename `,e]},`rename-${e}`)),y.map(e=>(0,G.jsxs)(Dp,{onClick:()=>l(e),children:[`Delete `,e]},`delete-${e}`))]})]})]}),(0,G.jsxs)(ug,{className:`flex flex-col gap-0.5`,children:[e.unfiled.map(e=>(0,G.jsx)(yj,{epic:e,selected:t===e.key,count:n(e.key),favourited:!0,folders:y,onSelect:d,onToggleFavourite:f,onFile:p,moveTo:vj(u,e.status),onMove:m,onOpen:h},e.key)),e.folders.map(e=>(0,G.jsx)(wj,{folder:e,selectedEpic:t,childCount:n,folderNames:y,listedEpics:u,onSelect:d,onToggleFavourite:f,onFile:p,onMove:m,onOpen:h},e.name))]})]})}function wj({folder:e,selectedEpic:t,childCount:n,folderNames:r,listedEpics:i,onSelect:a,onToggleFavourite:o,onFile:s,onMove:c,onOpen:l}){let[u,d]=(0,C.useState)(()=>!BA(RA(DA),e.name));function f(t){d(t);let n=RA(DA);if(t)for(let t of[...n])t.toLowerCase()===e.name.toLowerCase()&&n.delete(t);else n.add(e.name);zA(n,DA)}return(0,G.jsxs)(cg,{open:u,onOpenChange:f,className:`flex flex-col`,children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsxs)(`button`,{type:`button`,className:`text-muted-foreground hover:text-foreground flex h-7 items-center gap-1.5 px-3 text-left`,children:[(0,G.jsx)(j,{className:W(`size-3.5 shrink-0 transition-transform`,!u&&`-rotate-90`)}),(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-[12px] font-medium`,children:e.name}),(0,G.jsx)(`span`,{className:`text-[11px] tabular-nums`,children:e.epics.length})]})}),(0,G.jsx)(ug,{className:`flex flex-col gap-0.5`,children:e.epics.map(e=>(0,G.jsx)(yj,{epic:e,selected:t===e.key,count:n(e.key),favourited:!0,folders:r,onSelect:a,onToggleFavourite:o,onFile:s,moveTo:vj(i,e.status),onMove:c,onOpen:l},e.key))})]})}function Tj({presets:e,presetName:t,presetError:n,onPresetName:r,onCreatePreset:i,onApplyPreset:a,onOverwritePreset:o,onRenamePreset:s,onDeletePreset:c}){let[l,u]=(0,C.useState)(()=>!BA(RA(EA,PA),`Presets`));function d(e){u(e);let t=RA(EA,PA);if(e)for(let e of[...t])e.toLowerCase()===`presets`&&t.delete(e);else t.add(`Presets`);zA(t,EA)}return(0,G.jsxs)(cg,{open:l,onOpenChange:d,className:`flex flex-col`,children:[(0,G.jsxs)(`div`,{className:`flex items-center gap-1 px-1`,children:[(0,G.jsx)(lg,{asChild:!0,children:(0,G.jsxs)(`button`,{type:`button`,className:`text-muted-foreground hover:text-foreground flex h-7 min-w-0 flex-1 items-center gap-1.5 px-2 text-left`,children:[(0,G.jsx)(j,{className:W(`size-3.5 shrink-0 transition-transform`,!l&&`-rotate-90`)}),(0,G.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-[12px] font-medium`,children:`Presets`})]})}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":`Presets`,children:(0,G.jsx)(F,{})})}),(0,G.jsxs)(Tp,{align:`start`,className:`w-56`,children:[(0,G.jsx)(Ep,{children:`Save Preset`}),(0,G.jsxs)(`div`,{className:`px-2 pb-2`,children:[(0,G.jsx)(`input`,{className:`border-input h-7 w-full rounded-md border bg-transparent px-2 text-[13px] outline-none`,value:t,onChange:e=>r(e.target.value),placeholder:`Name`,"aria-label":`Preset name`,onKeyDown:e=>{e.key===`Enter`&&i()}}),n?(0,G.jsx)(`p`,{className:`text-destructive pt-1 text-[11px]`,children:n}):null]}),(0,G.jsx)(Dp,{onClick:i,children:`Save`})]})]})]}),(0,G.jsx)(ug,{className:`flex flex-col gap-0.5`,children:e.map(e=>(0,G.jsxs)(`div`,{className:`flex items-center gap-1`,children:[(0,G.jsx)(`button`,{type:`button`,className:`hover:bg-foreground/5 flex h-7 min-w-0 flex-1 items-center rounded-lg px-[7px] text-left text-[13px] font-medium`,onClick:()=>a(e.name),children:(0,G.jsx)(`span`,{className:`min-w-0 truncate`,children:e.name})}),(0,G.jsxs)(Cp,{children:[(0,G.jsx)(wp,{asChild:!0,children:(0,G.jsx)(q,{size:`icon-xs`,variant:`ghost`,type:`button`,"aria-label":`Preset ${e.name}`,children:(0,G.jsx)(F,{})})}),(0,G.jsxs)(Tp,{align:`end`,children:[(0,G.jsx)(Dp,{onClick:()=>o(e.name),children:`Save over`}),(0,G.jsx)(Dp,{onClick:()=>{let t=window.prompt(`Rename Preset`,e.name);t!=null&&s(e.name,t)},children:`Rename`}),(0,G.jsx)(Dp,{onClick:()=>c(e.name),children:`Delete`})]})]})]},e.name))})]})}(0,fe.createRoot)(document.getElementById(`root`)).render((0,G.jsx)(C.StrictMode,{children:(0,G.jsx)(Sj,{})}));
|